about summary refs log tree commit diff
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
parente87aef06e00c42b26789321454d7bd609548cc12 (diff)
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
-rw-r--r--pkgs/applications/accessibility/contrast/default.nix4
-rw-r--r--pkgs/applications/accessibility/mousetweaks/default.nix4
-rw-r--r--pkgs/applications/audio/a2jmidid/default.nix4
-rw-r--r--pkgs/applications/audio/aacgain/default.nix4
-rw-r--r--pkgs/applications/audio/abcde/default.nix4
-rw-r--r--pkgs/applications/audio/adlplug/default.nix4
-rw-r--r--pkgs/applications/audio/airwave/default.nix4
-rw-r--r--pkgs/applications/audio/aj-snapshot/default.nix4
-rw-r--r--pkgs/applications/audio/ams-lv2/default.nix4
-rw-r--r--pkgs/applications/audio/ams/default.nix4
-rw-r--r--pkgs/applications/audio/ardour/5.nix4
-rw-r--r--pkgs/applications/audio/ardour/default.nix4
-rw-r--r--pkgs/applications/audio/artyFX/default.nix4
-rw-r--r--pkgs/applications/audio/ashuffle/default.nix4
-rw-r--r--pkgs/applications/audio/aucatctl/default.nix4
-rw-r--r--pkgs/applications/audio/audacity/default.nix4
-rw-r--r--pkgs/applications/audio/audio-recorder/default.nix4
-rw-r--r--pkgs/applications/audio/autotalent/default.nix4
-rw-r--r--pkgs/applications/audio/axoloti/default.nix4
-rw-r--r--pkgs/applications/audio/axoloti/dfu-util.nix4
-rw-r--r--pkgs/applications/audio/axoloti/libusb1.nix2
-rw-r--r--pkgs/applications/audio/bambootracker/default.nix4
-rw-r--r--pkgs/applications/audio/baudline/default.nix4
-rw-r--r--pkgs/applications/audio/bchoppr/default.nix4
-rw-r--r--pkgs/applications/audio/bitmeter/default.nix4
-rw-r--r--pkgs/applications/audio/bitwig-studio/bitwig-studio1.nix2
-rw-r--r--pkgs/applications/audio/bitwig-studio/bitwig-studio3.nix2
-rw-r--r--pkgs/applications/audio/bjumblr/default.nix4
-rw-r--r--pkgs/applications/audio/bristol/default.nix4
-rw-r--r--pkgs/applications/audio/bschaffl/default.nix4
-rw-r--r--pkgs/applications/audio/bsequencer/default.nix4
-rw-r--r--pkgs/applications/audio/bshapr/default.nix4
-rw-r--r--pkgs/applications/audio/bslizr/default.nix4
-rw-r--r--pkgs/applications/audio/calf/default.nix4
-rw-r--r--pkgs/applications/audio/carla/default.nix4
-rw-r--r--pkgs/applications/audio/caudec/default.nix4
-rw-r--r--pkgs/applications/audio/cava/default.nix4
-rw-r--r--pkgs/applications/audio/cd-discid/default.nix4
-rw-r--r--pkgs/applications/audio/cdparanoia/default.nix4
-rw-r--r--pkgs/applications/audio/clementine/default.nix6
-rw-r--r--pkgs/applications/audio/clerk/default.nix4
-rw-r--r--pkgs/applications/audio/cmt/default.nix4
-rw-r--r--pkgs/applications/audio/cmus/default.nix4
-rw-r--r--pkgs/applications/audio/cmusfm/default.nix4
-rw-r--r--pkgs/applications/audio/cozy-audiobooks/default.nix4
-rw-r--r--pkgs/applications/audio/csa/default.nix4
-rw-r--r--pkgs/applications/audio/csound/csound-qt/default.nix4
-rw-r--r--pkgs/applications/audio/csound/default.nix4
-rw-r--r--pkgs/applications/audio/curseradio/default.nix4
-rw-r--r--pkgs/applications/audio/deadbeef/default.nix4
-rw-r--r--pkgs/applications/audio/deadbeef/plugins/headerbar-gtk3.nix4
-rw-r--r--pkgs/applications/audio/deadbeef/plugins/infobar.nix4
-rw-r--r--pkgs/applications/audio/deadbeef/plugins/lyricbar.nix4
-rw-r--r--pkgs/applications/audio/deadbeef/plugins/mpris2.nix4
-rw-r--r--pkgs/applications/audio/denemo/default.nix4
-rw-r--r--pkgs/applications/audio/dfasma/default.nix8
-rw-r--r--pkgs/applications/audio/dirt/default.nix4
-rw-r--r--pkgs/applications/audio/distrho/default.nix4
-rw-r--r--pkgs/applications/audio/dr14_tmeter/default.nix4
-rw-r--r--pkgs/applications/audio/dragonfly-reverb/default.nix4
-rw-r--r--pkgs/applications/audio/drumgizmo/default.nix4
-rw-r--r--pkgs/applications/audio/dsf2flac/default.nix4
-rw-r--r--pkgs/applications/audio/easytag/default.nix4
-rw-r--r--pkgs/applications/audio/ekho/default.nix4
-rw-r--r--pkgs/applications/audio/ensemble-chorus/default.nix4
-rw-r--r--pkgs/applications/audio/espeak-ng/default.nix2
-rw-r--r--pkgs/applications/audio/espeak/default.nix4
-rw-r--r--pkgs/applications/audio/espeak/edit.nix4
-rw-r--r--pkgs/applications/audio/eteroj.lv2/default.nix4
-rw-r--r--pkgs/applications/audio/faust/faust1.nix4
-rw-r--r--pkgs/applications/audio/faust/faust2.nix4
-rw-r--r--pkgs/applications/audio/faust/faustlive.nix4
-rw-r--r--pkgs/applications/audio/fdkaac/default.nix4
-rw-r--r--pkgs/applications/audio/flac/default.nix4
-rw-r--r--pkgs/applications/audio/flac123/default.nix4
-rw-r--r--pkgs/applications/audio/flacon/default.nix2
-rw-r--r--pkgs/applications/audio/fomp/default.nix4
-rw-r--r--pkgs/applications/audio/foo-yc20/default.nix4
-rw-r--r--pkgs/applications/audio/freqtweak/default.nix4
-rw-r--r--pkgs/applications/audio/ft2-clone/default.nix4
-rw-r--r--pkgs/applications/audio/fverb/default.nix4
-rw-r--r--pkgs/applications/audio/game-music-emu/default.nix4
-rw-r--r--pkgs/applications/audio/gbsplay/default.nix4
-rw-r--r--pkgs/applications/audio/geonkick/default.nix4
-rw-r--r--pkgs/applications/audio/giada/default.nix4
-rw-r--r--pkgs/applications/audio/gigedit/default.nix4
-rw-r--r--pkgs/applications/audio/gjay/default.nix4
-rw-r--r--pkgs/applications/audio/gmpc/default.nix4
-rw-r--r--pkgs/applications/audio/gnome-podcasts/default.nix4
-rw-r--r--pkgs/applications/audio/google-musicmanager/default.nix4
-rw-r--r--pkgs/applications/audio/gpodder/default.nix4
-rw-r--r--pkgs/applications/audio/gradio/default.nix4
-rw-r--r--pkgs/applications/audio/greg/default.nix4
-rw-r--r--pkgs/applications/audio/gtkpod/default.nix4
-rw-r--r--pkgs/applications/audio/guitarix/default.nix4
-rw-r--r--pkgs/applications/audio/gwc/default.nix4
-rw-r--r--pkgs/applications/audio/gxmatcheq-lv2/default.nix4
-rw-r--r--pkgs/applications/audio/gxplugins-lv2/default.nix4
-rw-r--r--pkgs/applications/audio/helio-workstation/default.nix4
-rw-r--r--pkgs/applications/audio/helm/default.nix4
-rw-r--r--pkgs/applications/audio/hybridreverb2/default.nix4
-rw-r--r--pkgs/applications/audio/hydrogen/0.nix4
-rw-r--r--pkgs/applications/audio/hydrogen/default.nix4
-rw-r--r--pkgs/applications/audio/id3v2/default.nix4
-rw-r--r--pkgs/applications/audio/infamousPlugins/default.nix4
-rw-r--r--pkgs/applications/audio/ingen/default.nix4
-rw-r--r--pkgs/applications/audio/ir.lv2/default.nix4
-rw-r--r--pkgs/applications/audio/jaaa/default.nix4
-rw-r--r--pkgs/applications/audio/jack-capture/default.nix4
-rw-r--r--pkgs/applications/audio/jack-oscrolloscope/default.nix4
-rw-r--r--pkgs/applications/audio/jalv/default.nix4
-rw-r--r--pkgs/applications/audio/jamin/default.nix4
-rw-r--r--pkgs/applications/audio/kapitonov-plugins-pack/default.nix4
-rw-r--r--pkgs/applications/audio/keyfinder-cli/default.nix4
-rw-r--r--pkgs/applications/audio/keyfinder/default.nix4
-rw-r--r--pkgs/applications/audio/kid3/default.nix4
-rw-r--r--pkgs/applications/audio/klystrack/default.nix4
-rw-r--r--pkgs/applications/audio/kmetronome/default.nix4
-rw-r--r--pkgs/applications/audio/ladspa-plugins/default.nix4
-rw-r--r--pkgs/applications/audio/lash/default.nix4
-rw-r--r--pkgs/applications/audio/librespot/default.nix4
-rw-r--r--pkgs/applications/audio/linuxsampler/default.nix4
-rw-r--r--pkgs/applications/audio/littlegptracker/default.nix4
-rw-r--r--pkgs/applications/audio/lmms/default.nix4
-rw-r--r--pkgs/applications/audio/ltc-tools/default.nix4
-rw-r--r--pkgs/applications/audio/luppp/default.nix4
-rw-r--r--pkgs/applications/audio/lv2-cpp-tools/default.nix4
-rw-r--r--pkgs/applications/audio/lv2bm/default.nix4
-rw-r--r--pkgs/applications/audio/mamba/default.nix4
-rw-r--r--pkgs/applications/audio/mda-lv2/default.nix4
-rw-r--r--pkgs/applications/audio/melmatcheq.lv2/default.nix4
-rw-r--r--pkgs/applications/audio/meterbridge/default.nix4
-rw-r--r--pkgs/applications/audio/mhwaveedit/default.nix4
-rw-r--r--pkgs/applications/audio/mid2key/default.nix4
-rw-r--r--pkgs/applications/audio/midas/generic.nix2
-rw-r--r--pkgs/applications/audio/midi-visualizer/default.nix4
-rw-r--r--pkgs/applications/audio/midisheetmusic/default.nix4
-rw-r--r--pkgs/applications/audio/milkytracker/default.nix4
-rw-r--r--pkgs/applications/audio/mixxx/default.nix4
-rw-r--r--pkgs/applications/audio/moc/default.nix4
-rw-r--r--pkgs/applications/audio/mod-distortion/default.nix4
-rw-r--r--pkgs/applications/audio/molot-lite/default.nix4
-rw-r--r--pkgs/applications/audio/monkeys-audio/default.nix4
-rw-r--r--pkgs/applications/audio/mopidy/gmusic.nix4
-rw-r--r--pkgs/applications/audio/mopidy/iris.nix4
-rw-r--r--pkgs/applications/audio/mopidy/moped.nix4
-rw-r--r--pkgs/applications/audio/mopidy/mopidy.nix4
-rw-r--r--pkgs/applications/audio/mopidy/mopify.nix4
-rw-r--r--pkgs/applications/audio/mopidy/mpd.nix4
-rw-r--r--pkgs/applications/audio/mopidy/mpris.nix4
-rw-r--r--pkgs/applications/audio/mopidy/musicbox-webclient.nix4
-rw-r--r--pkgs/applications/audio/mopidy/scrobbler.nix4
-rw-r--r--pkgs/applications/audio/mopidy/somafm.nix4
-rw-r--r--pkgs/applications/audio/mopidy/soundcloud.nix4
-rw-r--r--pkgs/applications/audio/mopidy/spotify-tunigo.nix4
-rw-r--r--pkgs/applications/audio/mopidy/spotify.nix4
-rw-r--r--pkgs/applications/audio/mopidy/tunein.nix4
-rw-r--r--pkgs/applications/audio/mopidy/youtube.nix4
-rw-r--r--pkgs/applications/audio/mp3blaster/default.nix4
-rw-r--r--pkgs/applications/audio/mp3gain/default.nix4
-rw-r--r--pkgs/applications/audio/mp3splt/default.nix4
-rw-r--r--pkgs/applications/audio/mpc/default.nix4
-rw-r--r--pkgs/applications/audio/mpg321/default.nix4
-rw-r--r--pkgs/applications/audio/munt/default.nix4
-rw-r--r--pkgs/applications/audio/mup/default.nix4
-rw-r--r--pkgs/applications/audio/muse/default.nix4
-rw-r--r--pkgs/applications/audio/musescore/darwin.nix2
-rw-r--r--pkgs/applications/audio/musescore/default.nix2
-rw-r--r--pkgs/applications/audio/musikcube/default.nix4
-rw-r--r--pkgs/applications/audio/musly/default.nix4
-rw-r--r--pkgs/applications/audio/ncmpc/default.nix4
-rw-r--r--pkgs/applications/audio/ncpamixer/default.nix4
-rw-r--r--pkgs/applications/audio/new-session-manager/default.nix4
-rw-r--r--pkgs/applications/audio/ninjas2/default.nix4
-rw-r--r--pkgs/applications/audio/noise-repellent/default.nix4
-rw-r--r--pkgs/applications/audio/noisetorch/default.nix4
-rw-r--r--pkgs/applications/audio/nootka/default.nix4
-rw-r--r--pkgs/applications/audio/nootka/unstable.nix4
-rw-r--r--pkgs/applications/audio/normalize/default.nix4
-rw-r--r--pkgs/applications/audio/nova-filters/default.nix4
-rw-r--r--pkgs/applications/audio/ocenaudio/default.nix2
-rw-r--r--pkgs/applications/audio/openmpt123/default.nix4
-rw-r--r--pkgs/applications/audio/opusfile/default.nix4
-rw-r--r--pkgs/applications/audio/orca-c/default.nix4
-rw-r--r--pkgs/applications/audio/osmid/default.nix4
-rw-r--r--pkgs/applications/audio/padthv1/default.nix4
-rw-r--r--pkgs/applications/audio/pamix/default.nix4
-rw-r--r--pkgs/applications/audio/pamixer/default.nix4
-rw-r--r--pkgs/applications/audio/paprefs/default.nix4
-rw-r--r--pkgs/applications/audio/parlatype/default.nix4
-rw-r--r--pkgs/applications/audio/paulstretch/default.nix4
-rw-r--r--pkgs/applications/audio/pavucontrol/default.nix4
-rw-r--r--pkgs/applications/audio/petrifoo/default.nix4
-rw-r--r--pkgs/applications/audio/pianobar/default.nix4
-rw-r--r--pkgs/applications/audio/pianobooster/default.nix4
-rw-r--r--pkgs/applications/audio/picard/default.nix4
-rw-r--r--pkgs/applications/audio/picoloop/default.nix4
-rw-r--r--pkgs/applications/audio/pithos/default.nix4
-rw-r--r--pkgs/applications/audio/playbar2/default.nix4
-rw-r--r--pkgs/applications/audio/plugin-torture/default.nix4
-rw-r--r--pkgs/applications/audio/plujain-ramp/default.nix4
-rw-r--r--pkgs/applications/audio/pmidi/default.nix4
-rw-r--r--pkgs/applications/audio/polyphone/default.nix4
-rw-r--r--pkgs/applications/audio/ponymix/default.nix4
-rw-r--r--pkgs/applications/audio/pt2-clone/default.nix4
-rw-r--r--pkgs/applications/audio/ptcollab/default.nix4
-rw-r--r--pkgs/applications/audio/puddletag/default.nix4
-rw-r--r--pkgs/applications/audio/pulseaudio-ctl/default.nix4
-rw-r--r--pkgs/applications/audio/pulseaudio-dlna/default.nix4
-rw-r--r--pkgs/applications/audio/pulseaudio-dlna/zeroconf.nix4
-rw-r--r--pkgs/applications/audio/pulseaudio-modules-bt/default.nix2
-rw-r--r--pkgs/applications/audio/pulseeffects/default.nix4
-rw-r--r--pkgs/applications/audio/puredata/default.nix4
-rw-r--r--pkgs/applications/audio/qjackctl/default.nix4
-rw-r--r--pkgs/applications/audio/qmidiarp/default.nix4
-rw-r--r--pkgs/applications/audio/qmidiroute/default.nix4
-rw-r--r--pkgs/applications/audio/qmmp/default.nix4
-rw-r--r--pkgs/applications/audio/qsampler/default.nix4
-rw-r--r--pkgs/applications/audio/qsynth/default.nix4
-rw-r--r--pkgs/applications/audio/qtractor/default.nix4
-rw-r--r--pkgs/applications/audio/quodlibet/default.nix4
-rw-r--r--pkgs/applications/audio/radiotray-ng/default.nix4
-rw-r--r--pkgs/applications/audio/rakarrack/default.nix4
-rw-r--r--pkgs/applications/audio/real_time_config_quick_scan/default.nix4
-rw-r--r--pkgs/applications/audio/reaper/default.nix4
-rw-r--r--pkgs/applications/audio/rhythmbox/default.nix4
-rw-r--r--pkgs/applications/audio/rkrlv2/default.nix4
-rw-r--r--pkgs/applications/audio/rosegarden/default.nix4
-rw-r--r--pkgs/applications/audio/rubyripper/default.nix4
-rw-r--r--pkgs/applications/audio/sc68/default.nix4
-rw-r--r--pkgs/applications/audio/schismtracker/default.nix4
-rw-r--r--pkgs/applications/audio/seq24/default.nix4
-rw-r--r--pkgs/applications/audio/seq66/default.nix4
-rw-r--r--pkgs/applications/audio/setbfree/default.nix4
-rw-r--r--pkgs/applications/audio/sfizz/default.nix4
-rw-r--r--pkgs/applications/audio/sfxr/default.nix4
-rw-r--r--pkgs/applications/audio/shortwave/default.nix4
-rw-r--r--pkgs/applications/audio/sisco.lv2/default.nix4
-rw-r--r--pkgs/applications/audio/sndpeek/default.nix4
-rw-r--r--pkgs/applications/audio/sonic-lineup/default.nix4
-rw-r--r--pkgs/applications/audio/sonic-visualiser/default.nix4
-rw-r--r--pkgs/applications/audio/sooperlooper/default.nix4
-rw-r--r--pkgs/applications/audio/sorcer/default.nix4
-rw-r--r--pkgs/applications/audio/sound-juicer/default.nix4
-rw-r--r--pkgs/applications/audio/soundtracker/default.nix4
-rw-r--r--pkgs/applications/audio/spectmorph/default.nix4
-rw-r--r--pkgs/applications/audio/speech-denoiser/default.nix4
-rw-r--r--pkgs/applications/audio/spek/default.nix4
-rw-r--r--pkgs/applications/audio/split2flac/default.nix4
-rw-r--r--pkgs/applications/audio/spotify-cli-linux/default.nix4
-rw-r--r--pkgs/applications/audio/spotify-tui/default.nix4
-rw-r--r--pkgs/applications/audio/spotify/default.nix4
-rw-r--r--pkgs/applications/audio/spotifyd/default.nix4
-rw-r--r--pkgs/applications/audio/spotifywm/default.nix4
-rw-r--r--pkgs/applications/audio/squeezelite/default.nix4
-rw-r--r--pkgs/applications/audio/squishyball/default.nix4
-rw-r--r--pkgs/applications/audio/ssrc/default.nix4
-rw-r--r--pkgs/applications/audio/stochas/default.nix4
-rw-r--r--pkgs/applications/audio/stone-phaser/default.nix4
-rw-r--r--pkgs/applications/audio/streamripper/default.nix4
-rw-r--r--pkgs/applications/audio/string-machine/default.nix4
-rw-r--r--pkgs/applications/audio/sunvox/default.nix4
-rw-r--r--pkgs/applications/audio/surge/default.nix4
-rw-r--r--pkgs/applications/audio/svox/default.nix4
-rw-r--r--pkgs/applications/audio/swh-lv2/default.nix4
-rw-r--r--pkgs/applications/audio/synthv1/default.nix4
-rw-r--r--pkgs/applications/audio/talentedhack/default.nix4
-rw-r--r--pkgs/applications/audio/tambura/default.nix4
-rw-r--r--pkgs/applications/audio/tamgamp.lv2/default.nix4
-rw-r--r--pkgs/applications/audio/tetraproc/default.nix4
-rw-r--r--pkgs/applications/audio/tony/default.nix4
-rw-r--r--pkgs/applications/audio/transcode/default.nix4
-rw-r--r--pkgs/applications/audio/traverso/default.nix4
-rw-r--r--pkgs/applications/audio/tree-from-tags/default.nix4
-rw-r--r--pkgs/applications/audio/tunefish/default.nix4
-rw-r--r--pkgs/applications/audio/uade123/default.nix4
-rw-r--r--pkgs/applications/audio/uhhyou.lv2/default.nix4
-rw-r--r--pkgs/applications/audio/vcv-rack/default.nix4
-rw-r--r--pkgs/applications/audio/vimpc/default.nix4
-rw-r--r--pkgs/applications/audio/virtual-ans/default.nix4
-rw-r--r--pkgs/applications/audio/vkeybd/default.nix4
-rw-r--r--pkgs/applications/audio/vocal/default.nix4
-rw-r--r--pkgs/applications/audio/vocproc/default.nix4
-rw-r--r--pkgs/applications/audio/vorbis-tools/default.nix4
-rw-r--r--pkgs/applications/audio/waon/default.nix4
-rw-r--r--pkgs/applications/audio/whipper/default.nix4
-rw-r--r--pkgs/applications/audio/wolf-shaper/default.nix4
-rw-r--r--pkgs/applications/audio/x42-avldrums/default.nix4
-rw-r--r--pkgs/applications/audio/x42-gmsynth/default.nix4
-rw-r--r--pkgs/applications/audio/xmp/default.nix4
-rw-r--r--pkgs/applications/audio/xsynth-dssi/default.nix4
-rw-r--r--pkgs/applications/audio/xtuner/default.nix4
-rw-r--r--pkgs/applications/audio/yoshimi/default.nix4
-rw-r--r--pkgs/applications/audio/zam-plugins/default.nix4
-rw-r--r--pkgs/applications/audio/zita-ajbridge/default.nix4
-rw-r--r--pkgs/applications/audio/zita-at1/default.nix4
-rw-r--r--pkgs/applications/audio/zita-njbridge/default.nix4
-rw-r--r--pkgs/applications/audio/zynaddsubfx/mruby-zest/default.nix4
-rw-r--r--pkgs/applications/backup/areca/default.nix4
-rw-r--r--pkgs/applications/backup/deja-dup/default.nix4
-rw-r--r--pkgs/applications/backup/vdmfec/default.nix4
-rw-r--r--pkgs/applications/blockchains/aeon/default.nix4
-rw-r--r--pkgs/applications/blockchains/bitcoin-knots.nix4
-rw-r--r--pkgs/applications/blockchains/cgminer/default.nix4
-rw-r--r--pkgs/applications/blockchains/ergo/default.nix4
-rw-r--r--pkgs/applications/blockchains/ethabi.nix4
-rw-r--r--pkgs/applications/blockchains/exodus/default.nix2
-rw-r--r--pkgs/applications/blockchains/go-ethereum.nix4
-rw-r--r--pkgs/applications/blockchains/ledger-live-desktop/default.nix4
-rw-r--r--pkgs/applications/blockchains/monero/default.nix4
-rw-r--r--pkgs/applications/blockchains/parity-ui/default.nix4
-rw-r--r--pkgs/applications/blockchains/pivx.nix4
-rw-r--r--pkgs/applications/blockchains/quorum.nix4
-rw-r--r--pkgs/applications/blockchains/stellar-core.nix4
-rw-r--r--pkgs/applications/blockchains/tessera.nix4
-rw-r--r--pkgs/applications/blockchains/turbo-geth.nix4
-rw-r--r--pkgs/applications/blockchains/wasabibackend/default.nix4
-rw-r--r--pkgs/applications/blockchains/wasabiwallet/default.nix4
-rw-r--r--pkgs/applications/blockchains/whirlpool-gui/default.nix4
-rw-r--r--pkgs/applications/display-managers/lightdm-enso-os-greeter/default.nix4
-rw-r--r--pkgs/applications/display-managers/lightdm-mini-greeter/default.nix4
-rw-r--r--pkgs/applications/display-managers/lightdm-tiny-greeter/default.nix4
-rw-r--r--pkgs/applications/display-managers/lightdm/gtk-greeter.nix4
-rw-r--r--pkgs/applications/editors/amp/default.nix4
-rw-r--r--pkgs/applications/editors/android-studio/common.nix3
-rw-r--r--pkgs/applications/editors/apostrophe/default.nix4
-rw-r--r--pkgs/applications/editors/atom/default.nix4
-rw-r--r--pkgs/applications/editors/bless/default.nix4
-rw-r--r--pkgs/applications/editors/bluefish/default.nix4
-rw-r--r--pkgs/applications/editors/bluej/default.nix4
-rw-r--r--pkgs/applications/editors/bonzomatic/default.nix4
-rw-r--r--pkgs/applications/editors/bvi/default.nix4
-rw-r--r--pkgs/applications/editors/bviplus/default.nix4
-rw-r--r--pkgs/applications/editors/code-browser/default.nix4
-rw-r--r--pkgs/applications/editors/deadpixi-sam/default.nix4
-rw-r--r--pkgs/applications/editors/dit/default.nix2
-rw-r--r--pkgs/applications/editors/eclipse/plugins.nix52
-rw-r--r--pkgs/applications/editors/edbrowse/default.nix4
-rw-r--r--pkgs/applications/editors/edit/default.nix4
-rw-r--r--pkgs/applications/editors/emacs-modes/color-theme-solarized/default.nix4
-rw-r--r--pkgs/applications/editors/emacs-modes/sv-kalender/default.nix4
-rw-r--r--pkgs/applications/editors/emacs/generic.nix2
-rw-r--r--pkgs/applications/editors/emacs/macport.nix4
-rw-r--r--pkgs/applications/editors/featherpad/default.nix4
-rw-r--r--pkgs/applications/editors/flpsed/default.nix4
-rw-r--r--pkgs/applications/editors/focuswriter/default.nix4
-rw-r--r--pkgs/applications/editors/fte/default.nix4
-rw-r--r--pkgs/applications/editors/geany/default.nix4
-rw-r--r--pkgs/applications/editors/ghostwriter/default.nix4
-rw-r--r--pkgs/applications/editors/gnome-builder/default.nix4
-rw-r--r--pkgs/applications/editors/gnome-latex/default.nix4
-rw-r--r--pkgs/applications/editors/gobby/default.nix4
-rw-r--r--pkgs/applications/editors/greenfoot/default.nix4
-rw-r--r--pkgs/applications/editors/hecate/default.nix4
-rw-r--r--pkgs/applications/editors/hexdino/default.nix4
-rw-r--r--pkgs/applications/editors/jedit/default.nix4
-rw-r--r--pkgs/applications/editors/jetbrains/default.nix20
-rw-r--r--pkgs/applications/editors/joe/default.nix4
-rw-r--r--pkgs/applications/editors/jupp/default.nix4
-rw-r--r--pkgs/applications/editors/kakoune/plugins/case.kak.nix4
-rw-r--r--pkgs/applications/editors/kakoune/plugins/kak-ansi.nix4
-rw-r--r--pkgs/applications/editors/kakoune/plugins/kak-plumb.nix4
-rw-r--r--pkgs/applications/editors/kakoune/plugins/openscad.kak.nix4
-rw-r--r--pkgs/applications/editors/kdevelop5/kdevelop-pg-qt.nix4
-rw-r--r--pkgs/applications/editors/kibi/default.nix4
-rw-r--r--pkgs/applications/editors/kodestudio/default.nix2
-rw-r--r--pkgs/applications/editors/leafpad/default.nix4
-rw-r--r--pkgs/applications/editors/lighttable/default.nix2
-rw-r--r--pkgs/applications/editors/lite/default.nix4
-rw-r--r--pkgs/applications/editors/marker/default.nix4
-rw-r--r--pkgs/applications/editors/mg/default.nix4
-rw-r--r--pkgs/applications/editors/mindforger/default.nix4
-rw-r--r--pkgs/applications/editors/mle/default.nix4
-rw-r--r--pkgs/applications/editors/moe/default.nix4
-rw-r--r--pkgs/applications/editors/monodevelop/default.nix4
-rw-r--r--pkgs/applications/editors/music/tuxguitar/default.nix4
-rw-r--r--pkgs/applications/editors/ne/default.nix4
-rw-r--r--pkgs/applications/editors/nedit/default.nix4
-rw-r--r--pkgs/applications/editors/neovim/gnvim/default.nix4
-rw-r--r--pkgs/applications/editors/neovim/qt.nix4
-rw-r--r--pkgs/applications/editors/okteta/default.nix4
-rw-r--r--pkgs/applications/editors/quilter/default.nix4
-rw-r--r--pkgs/applications/editors/qxmledit/default.nix4
-rw-r--r--pkgs/applications/editors/qxw/default.nix4
-rw-r--r--pkgs/applications/editors/rehex/default.nix4
-rw-r--r--pkgs/applications/editors/retext/default.nix4
-rw-r--r--pkgs/applications/editors/scite/default.nix4
-rw-r--r--pkgs/applications/editors/sigil/default.nix4
-rw-r--r--pkgs/applications/editors/spacevim/default.nix4
-rw-r--r--pkgs/applications/editors/standardnotes/default.nix4
-rw-r--r--pkgs/applications/editors/sublime/3/common.nix4
-rw-r--r--pkgs/applications/editors/supertux-editor/default.nix4
-rw-r--r--pkgs/applications/editors/tecoc/default.nix4
-rw-r--r--pkgs/applications/editors/textadept/10/default.nix2
-rw-r--r--pkgs/applications/editors/textadept/11/default.nix2
-rw-r--r--pkgs/applications/editors/thonny/default.nix4
-rw-r--r--pkgs/applications/editors/tiled/default.nix4
-rw-r--r--pkgs/applications/editors/tweak/default.nix4
-rw-r--r--pkgs/applications/editors/vim/macvim.nix4
-rw-r--r--pkgs/applications/editors/vim/vimacs.nix4
-rw-r--r--pkgs/applications/editors/vis/default.nix4
-rw-r--r--pkgs/applications/editors/viw/default.nix4
-rw-r--r--pkgs/applications/editors/vscode/vscode.nix2
-rw-r--r--pkgs/applications/editors/vscode/vscodium.nix4
-rw-r--r--pkgs/applications/editors/wily/default.nix4
-rw-r--r--pkgs/applications/editors/xmlcopyeditor/default.nix4
-rw-r--r--pkgs/applications/editors/yi/wrapper.nix4
-rw-r--r--pkgs/applications/editors/zile/default.nix4
-rw-r--r--pkgs/applications/gis/gmt/dcw.nix4
-rw-r--r--pkgs/applications/gis/gmt/default.nix4
-rw-r--r--pkgs/applications/gis/gmt/gshhg.nix4
-rw-r--r--pkgs/applications/gis/openorienteering-mapper/default.nix4
-rw-r--r--pkgs/applications/gis/whitebox-tools/default.nix4
-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
-rw-r--r--pkgs/applications/logging/humioctl/default.nix4
-rw-r--r--pkgs/applications/misc/1password/default.nix4
-rw-r--r--pkgs/applications/misc/ArchiSteamFarm/default.nix4
-rw-r--r--pkgs/applications/misc/OSCAR/default.nix4
-rw-r--r--pkgs/applications/misc/airtame/default.nix2
-rw-r--r--pkgs/applications/misc/almanah/default.nix4
-rw-r--r--pkgs/applications/misc/antfs-cli/default.nix4
-rw-r--r--pkgs/applications/misc/ape/clex.nix4
-rw-r--r--pkgs/applications/misc/ape/default.nix6
-rw-r--r--pkgs/applications/misc/appeditor/default.nix4
-rw-r--r--pkgs/applications/misc/apvlv/default.nix4
-rw-r--r--pkgs/applications/misc/archivy/default.nix2
-rw-r--r--pkgs/applications/misc/artha/default.nix4
-rw-r--r--pkgs/applications/misc/asciiquarium/default.nix4
-rw-r--r--pkgs/applications/misc/audio/wavrsocvt/default.nix4
-rw-r--r--pkgs/applications/misc/ausweisapp2/default.nix4
-rw-r--r--pkgs/applications/misc/autospotting/default.nix4
-rw-r--r--pkgs/applications/misc/avrdudess/default.nix4
-rw-r--r--pkgs/applications/misc/batsignal/default.nix4
-rw-r--r--pkgs/applications/misc/bicon/default.nix4
-rw-r--r--pkgs/applications/misc/bleachbit/default.nix4
-rw-r--r--pkgs/applications/misc/blender/default.nix2
-rw-r--r--pkgs/applications/misc/blogc/default.nix4
-rw-r--r--pkgs/applications/misc/blugon/default.nix4
-rw-r--r--pkgs/applications/misc/break-time/default.nix4
-rw-r--r--pkgs/applications/misc/buku/default.nix4
-rw-r--r--pkgs/applications/misc/calcurse/default.nix4
-rw-r--r--pkgs/applications/misc/candle/default.nix4
-rw-r--r--pkgs/applications/misc/cardpeek/default.nix4
-rw-r--r--pkgs/applications/misc/cataract/build.nix4
-rw-r--r--pkgs/applications/misc/catclock/default.nix4
-rw-r--r--pkgs/applications/misc/cbatticon/default.nix4
-rw-r--r--pkgs/applications/misc/cheat/default.nix4
-rw-r--r--pkgs/applications/misc/chewing-editor/default.nix4
-rw-r--r--pkgs/applications/misc/cipher/default.nix4
-rw-r--r--pkgs/applications/misc/clipit/default.nix4
-rw-r--r--pkgs/applications/misc/clipmenu/default.nix2
-rw-r--r--pkgs/applications/misc/cmatrix/default.nix4
-rw-r--r--pkgs/applications/misc/colort/default.nix4
-rw-r--r--pkgs/applications/misc/corectrl/default.nix4
-rw-r--r--pkgs/applications/misc/coursera-dl/default.nix4
-rw-r--r--pkgs/applications/misc/cpu-x/default.nix4
-rw-r--r--pkgs/applications/misc/ctodo/default.nix4
-rw-r--r--pkgs/applications/misc/cum/default.nix4
-rw-r--r--pkgs/applications/misc/cura/lulzbot/libarcus.nix4
-rw-r--r--pkgs/applications/misc/cura/lulzbot/libsavitar.nix4
-rw-r--r--pkgs/applications/misc/cura/lulzbot/uranium.nix4
-rw-r--r--pkgs/applications/misc/cura/plugins.nix4
-rw-r--r--pkgs/applications/misc/cura/stable.nix4
-rw-r--r--pkgs/applications/misc/curaengine/default.nix4
-rw-r--r--pkgs/applications/misc/curaengine/stable.nix4
-rw-r--r--pkgs/applications/misc/dasel/default.nix4
-rw-r--r--pkgs/applications/misc/dbeaver/default.nix4
-rw-r--r--pkgs/applications/misc/ddgr/default.nix4
-rw-r--r--pkgs/applications/misc/deadd-notification-center/default.nix4
-rw-r--r--pkgs/applications/misc/deco/default.nix4
-rw-r--r--pkgs/applications/misc/devdocs-desktop/default.nix4
-rw-r--r--pkgs/applications/misc/devilspie2/default.nix4
-rw-r--r--pkgs/applications/misc/diff-pdf/default.nix4
-rw-r--r--pkgs/applications/misc/ding/default.nix4
-rw-r--r--pkgs/applications/misc/djvulibre/default.nix4
-rw-r--r--pkgs/applications/misc/dmensamenu/default.nix4
-rw-r--r--pkgs/applications/misc/dmenu/default.nix4
-rw-r--r--pkgs/applications/misc/dmenu/wayland.nix4
-rw-r--r--pkgs/applications/misc/dockbarx/default.nix8
-rw-r--r--pkgs/applications/misc/doomseeker/default.nix4
-rw-r--r--pkgs/applications/misc/dotfiles/default.nix4
-rw-r--r--pkgs/applications/misc/dstask/default.nix4
-rw-r--r--pkgs/applications/misc/dupeguru/default.nix4
-rw-r--r--pkgs/applications/misc/eaglemode/default.nix4
-rw-r--r--pkgs/applications/misc/effitask/default.nix4
-rw-r--r--pkgs/applications/misc/electrum/dash.nix4
-rw-r--r--pkgs/applications/misc/electrum/default.nix4
-rw-r--r--pkgs/applications/misc/electrum/ltc.nix4
-rw-r--r--pkgs/applications/misc/elfx86exts/default.nix4
-rw-r--r--pkgs/applications/misc/emem/default.nix4
-rw-r--r--pkgs/applications/misc/epdfview/default.nix4
-rw-r--r--pkgs/applications/misc/et/default.nix4
-rw-r--r--pkgs/applications/misc/eureka-editor/default.nix4
-rw-r--r--pkgs/applications/misc/evtest/default.nix4
-rw-r--r--pkgs/applications/misc/exercism/default.nix4
-rw-r--r--pkgs/applications/misc/far2l/default.nix4
-rw-r--r--pkgs/applications/misc/fbmenugen/default.nix4
-rw-r--r--pkgs/applications/misc/fbreader/default.nix4
-rw-r--r--pkgs/applications/misc/fehlstart/default.nix4
-rw-r--r--pkgs/applications/misc/fff/default.nix4
-rw-r--r--pkgs/applications/misc/filet/default.nix4
-rw-r--r--pkgs/applications/misc/firestarter/default.nix4
-rw-r--r--pkgs/applications/misc/flamerobin/default.nix4
-rw-r--r--pkgs/applications/misc/fme/default.nix4
-rw-r--r--pkgs/applications/misc/font-manager/default.nix4
-rw-r--r--pkgs/applications/misc/fontpreview/default.nix2
-rw-r--r--pkgs/applications/misc/formatter/default.nix4
-rw-r--r--pkgs/applications/misc/foxtrotgps/default.nix4
-rw-r--r--pkgs/applications/misc/freemind/default.nix4
-rw-r--r--pkgs/applications/misc/fsv/default.nix4
-rw-r--r--pkgs/applications/misc/fusee-interfacee-tk/default.nix4
-rw-r--r--pkgs/applications/misc/gImageReader/default.nix4
-rw-r--r--pkgs/applications/misc/galculator/default.nix4
-rw-r--r--pkgs/applications/misc/ganttproject-bin/default.nix4
-rw-r--r--pkgs/applications/misc/gcstar/default.nix4
-rw-r--r--pkgs/applications/misc/geoipupdate/default.nix4
-rw-r--r--pkgs/applications/misc/getxbook/default.nix4
-rw-r--r--pkgs/applications/misc/girara/default.nix4
-rw-r--r--pkgs/applications/misc/glava/default.nix4
-rw-r--r--pkgs/applications/misc/glom/default.nix4
-rw-r--r--pkgs/applications/misc/gmrun/default.nix4
-rw-r--r--pkgs/applications/misc/gnome-firmware-updater/default.nix4
-rw-r--r--pkgs/applications/misc/gnome-multi-writer/default.nix4
-rw-r--r--pkgs/applications/misc/gnome-passwordsafe/default.nix4
-rw-r--r--pkgs/applications/misc/gnome-recipes/default.nix4
-rw-r--r--pkgs/applications/misc/gnome-usage/default.nix4
-rw-r--r--pkgs/applications/misc/go-jira/default.nix4
-rw-r--r--pkgs/applications/misc/golden-cheetah/default.nix4
-rw-r--r--pkgs/applications/misc/goldendict/default.nix4
-rw-r--r--pkgs/applications/misc/gollum/default.nix4
-rw-r--r--pkgs/applications/misc/googleearth/default.nix4
-rw-r--r--pkgs/applications/misc/googler/default.nix4
-rw-r--r--pkgs/applications/misc/gosmore/default.nix4
-rw-r--r--pkgs/applications/misc/gpa/default.nix4
-rw-r--r--pkgs/applications/misc/gphoto2/default.nix4
-rw-r--r--pkgs/applications/misc/gphoto2/gphotofs.nix4
-rw-r--r--pkgs/applications/misc/gpsbabel/default.nix2
-rw-r--r--pkgs/applications/misc/gpsbabel/gui.nix4
-rw-r--r--pkgs/applications/misc/gpscorrelate/default.nix4
-rw-r--r--pkgs/applications/misc/gpsprune/default.nix4
-rw-r--r--pkgs/applications/misc/gpx-viewer/default.nix4
-rw-r--r--pkgs/applications/misc/gpxsee/default.nix4
-rw-r--r--pkgs/applications/misc/gramps/default.nix4
-rw-r--r--pkgs/applications/misc/green-pdfviewer/default.nix4
-rw-r--r--pkgs/applications/misc/gremlin-console/default.nix4
-rw-r--r--pkgs/applications/misc/grsync/default.nix4
-rw-r--r--pkgs/applications/misc/gsctl/default.nix4
-rw-r--r--pkgs/applications/misc/gtk2fontsel/default.nix4
-rw-r--r--pkgs/applications/misc/gxneur/default.nix4
-rw-r--r--pkgs/applications/misc/hamster/default.nix4
-rw-r--r--pkgs/applications/misc/haxor-news/default.nix4
-rw-r--r--pkgs/applications/misc/hello/default.nix4
-rw-r--r--pkgs/applications/misc/hivemind/default.nix4
-rw-r--r--pkgs/applications/misc/hr/default.nix4
-rw-r--r--pkgs/applications/misc/hubstaff/default.nix4
-rw-r--r--pkgs/applications/misc/hugo/default.nix4
-rw-r--r--pkgs/applications/misc/imag/default.nix4
-rw-r--r--pkgs/applications/misc/ipmicfg/default.nix4
-rw-r--r--pkgs/applications/misc/ipmiview/default.nix4
-rw-r--r--pkgs/applications/misc/j4-dmenu-desktop/default.nix4
-rw-r--r--pkgs/applications/misc/jgmenu/default.nix4
-rw-r--r--pkgs/applications/misc/joplin-desktop/default.nix4
-rw-r--r--pkgs/applications/misc/josm/default.nix4
-rw-r--r--pkgs/applications/misc/jotta-cli/default.nix4
-rw-r--r--pkgs/applications/misc/jp2a/default.nix4
-rw-r--r--pkgs/applications/misc/jrnl/default.nix4
-rw-r--r--pkgs/applications/misc/k2pdfopt/default.nix4
-rw-r--r--pkgs/applications/misc/k4dirstat/default.nix4
-rw-r--r--pkgs/applications/misc/kanboard/default.nix4
-rw-r--r--pkgs/applications/misc/kapow/default.nix4
-rw-r--r--pkgs/applications/misc/keepass-plugins/keepassrpc/default.nix4
-rw-r--r--pkgs/applications/misc/keeweb/default.nix4
-rw-r--r--pkgs/applications/misc/khal/default.nix4
-rw-r--r--pkgs/applications/misc/kjv/default.nix4
-rw-r--r--pkgs/applications/misc/kondo/default.nix4
-rw-r--r--pkgs/applications/misc/koreader/default.nix4
-rw-r--r--pkgs/applications/misc/kupfer/default.nix4
-rw-r--r--pkgs/applications/misc/lenmus/default.nix4
-rw-r--r--pkgs/applications/misc/libosmocore/default.nix4
-rw-r--r--pkgs/applications/misc/librecad/default.nix5
-rw-r--r--pkgs/applications/misc/lifelines/default.nix4
-rw-r--r--pkgs/applications/misc/lighthouse/default.nix4
-rw-r--r--pkgs/applications/misc/llpp/default.nix2
-rw-r--r--pkgs/applications/misc/loxodo/default.nix4
-rw-r--r--pkgs/applications/misc/ltwheelconf/default.nix4
-rw-r--r--pkgs/applications/misc/madonctl/default.nix4
-rw-r--r--pkgs/applications/misc/makeself/default.nix4
-rw-r--r--pkgs/applications/misc/mako/default.nix4
-rw-r--r--pkgs/applications/misc/masterpdfeditor/default.nix2
-rw-r--r--pkgs/applications/misc/mdp/default.nix4
-rw-r--r--pkgs/applications/misc/mediaelch/default.nix4
-rw-r--r--pkgs/applications/misc/mediainfo-gui/default.nix4
-rw-r--r--pkgs/applications/misc/mediainfo/default.nix4
-rw-r--r--pkgs/applications/misc/megacmd/default.nix4
-rw-r--r--pkgs/applications/misc/megasync/default.nix4
-rw-r--r--pkgs/applications/misc/mencal/default.nix4
-rw-r--r--pkgs/applications/misc/menumaker/default.nix4
-rw-r--r--pkgs/applications/misc/metamorphose2/default.nix4
-rw-r--r--pkgs/applications/misc/metar/default.nix4
-rw-r--r--pkgs/applications/misc/minder/default.nix4
-rw-r--r--pkgs/applications/misc/minergate-cli/default.nix4
-rw-r--r--pkgs/applications/misc/minergate/default.nix4
-rw-r--r--pkgs/applications/misc/mkgmap/default.nix4
-rw-r--r--pkgs/applications/misc/mkgmap/splitter/default.nix4
-rw-r--r--pkgs/applications/misc/moonlight-embedded/default.nix4
-rw-r--r--pkgs/applications/misc/mop/default.nix4
-rw-r--r--pkgs/applications/misc/mpvc/default.nix4
-rw-r--r--pkgs/applications/misc/mqtt-bench/default.nix4
-rw-r--r--pkgs/applications/misc/mucommander/default.nix4
-rw-r--r--pkgs/applications/misc/multibootusb/default.nix4
-rw-r--r--pkgs/applications/misc/mupdf/1.17.nix2
-rw-r--r--pkgs/applications/misc/mupdf/default.nix2
-rw-r--r--pkgs/applications/misc/mwic/default.nix4
-rw-r--r--pkgs/applications/misc/mysql-workbench/default.nix4
-rw-r--r--pkgs/applications/misc/mystem/default.nix4
-rw-r--r--pkgs/applications/misc/neap/default.nix4
-rw-r--r--pkgs/applications/misc/nix-tour/default.nix4
-rw-r--r--pkgs/applications/misc/nixnote2/default.nix4
-rw-r--r--pkgs/applications/misc/notejot/default.nix4
-rw-r--r--pkgs/applications/misc/notify-osd-customizable/default.nix4
-rw-r--r--pkgs/applications/misc/notify-osd/default.nix4
-rw-r--r--pkgs/applications/misc/nrsc5/default.nix4
-rw-r--r--pkgs/applications/misc/nut/default.nix4
-rw-r--r--pkgs/applications/misc/nwg-launchers/default.nix4
-rw-r--r--pkgs/applications/misc/obinskit/default.nix2
-rw-r--r--pkgs/applications/misc/ocropus/default.nix4
-rw-r--r--pkgs/applications/misc/octoprint/default.nix2
-rw-r--r--pkgs/applications/misc/octoprint/plugins.nix32
-rw-r--r--pkgs/applications/misc/ola/default.nix4
-rw-r--r--pkgs/applications/misc/olifant/default.nix4
-rw-r--r--pkgs/applications/misc/omegat.nix4
-rw-r--r--pkgs/applications/misc/onboard/default.nix4
-rw-r--r--pkgs/applications/misc/oneko/default.nix4
-rw-r--r--pkgs/applications/misc/openbrf/default.nix4
-rw-r--r--pkgs/applications/misc/opentx/default.nix4
-rw-r--r--pkgs/applications/misc/orca/default.nix4
-rw-r--r--pkgs/applications/misc/osm2xmap/default.nix4
-rw-r--r--pkgs/applications/misc/osmctools/default.nix4
-rw-r--r--pkgs/applications/misc/osmium-tool/default.nix4
-rw-r--r--pkgs/applications/misc/pastel/default.nix4
-rw-r--r--pkgs/applications/misc/pbpst/default.nix4
-rw-r--r--pkgs/applications/misc/pcmanfm/default.nix4
-rw-r--r--pkgs/applications/misc/pcmanx-gtk2/default.nix4
-rw-r--r--pkgs/applications/misc/pdf-quench/default.nix4
-rw-r--r--pkgs/applications/misc/pdfdiff/default.nix4
-rw-r--r--pkgs/applications/misc/pdfmod/default.nix2
-rw-r--r--pkgs/applications/misc/pdfpc/default.nix4
-rw-r--r--pkgs/applications/misc/pdfsam-basic/default.nix4
-rw-r--r--pkgs/applications/misc/peaclock/default.nix4
-rw-r--r--pkgs/applications/misc/pell/default.nix4
-rw-r--r--pkgs/applications/misc/pgadmin/default.nix4
-rw-r--r--pkgs/applications/misc/pgmanage/default.nix4
-rw-r--r--pkgs/applications/misc/pgmodeler/default.nix2
-rw-r--r--pkgs/applications/misc/pinfo/default.nix4
-rw-r--r--pkgs/applications/misc/pipr/default.nix2
-rw-r--r--pkgs/applications/misc/plank/default.nix4
-rw-r--r--pkgs/applications/misc/plasma-applet-volumewin7mixer/default.nix4
-rw-r--r--pkgs/applications/misc/playonlinux/default.nix4
-rw-r--r--pkgs/applications/misc/plover/default.nix6
-rw-r--r--pkgs/applications/misc/polybar/default.nix4
-rw-r--r--pkgs/applications/misc/posterazor/default.nix4
-rw-r--r--pkgs/applications/misc/prevo/data.nix4
-rw-r--r--pkgs/applications/misc/prevo/default.nix4
-rw-r--r--pkgs/applications/misc/prevo/tools.nix4
-rw-r--r--pkgs/applications/misc/printrun/default.nix4
-rw-r--r--pkgs/applications/misc/procmail/default.nix4
-rw-r--r--pkgs/applications/misc/projectlibre/default.nix4
-rw-r--r--pkgs/applications/misc/prusa-slicer/default.nix2
-rw-r--r--pkgs/applications/misc/prusa-slicer/super-slicer.nix2
-rw-r--r--pkgs/applications/misc/pstree/default.nix4
-rw-r--r--pkgs/applications/misc/ptask/default.nix4
-rw-r--r--pkgs/applications/misc/pwsafe/default.nix4
-rw-r--r--pkgs/applications/misc/pydf/default.nix4
-rw-r--r--pkgs/applications/misc/pyditz/cerberus.nix4
-rw-r--r--pkgs/applications/misc/pyditz/default.nix4
-rw-r--r--pkgs/applications/misc/pytrainer/default.nix4
-rw-r--r--pkgs/applications/misc/qMasterPassword/default.nix4
-rw-r--r--pkgs/applications/misc/qcad/default.nix4
-rw-r--r--pkgs/applications/misc/qdirstat/default.nix4
-rw-r--r--pkgs/applications/misc/qlandkartegt/garmindev.nix4
-rw-r--r--pkgs/applications/misc/qlcplus/default.nix4
-rw-r--r--pkgs/applications/misc/qmetro/default.nix4
-rw-r--r--pkgs/applications/misc/qsudo/default.nix4
-rw-r--r--pkgs/applications/misc/qt-box-editor/default.nix4
-rw-r--r--pkgs/applications/misc/qtbitcointrader/default.nix4
-rw-r--r--pkgs/applications/misc/redshift-plasma-applet/default.nix4
-rw-r--r--pkgs/applications/misc/redshift/default.nix4
-rw-r--r--pkgs/applications/misc/regextester/default.nix4
-rw-r--r--pkgs/applications/misc/remarkable/remarkable-mouse/default.nix4
-rw-r--r--pkgs/applications/misc/remarkable/rmapi/default.nix4
-rw-r--r--pkgs/applications/misc/rofi-file-browser/default.nix4
-rw-r--r--pkgs/applications/misc/rofi-menugen/default.nix4
-rw-r--r--pkgs/applications/misc/rootbar/default.nix4
-rw-r--r--pkgs/applications/misc/rsclock/default.nix4
-rw-r--r--pkgs/applications/misc/rss-bridge-cli/default.nix4
-rw-r--r--pkgs/applications/misc/rtv/default.nix4
-rw-r--r--pkgs/applications/misc/sc-im/default.nix4
-rw-r--r--pkgs/applications/misc/sdcv/default.nix4
-rw-r--r--pkgs/applications/misc/sent/default.nix4
-rw-r--r--pkgs/applications/misc/sequeler/default.nix4
-rw-r--r--pkgs/applications/misc/sidequest/default.nix2
-rw-r--r--pkgs/applications/misc/simplenote/default.nix2
-rw-r--r--pkgs/applications/misc/slade/default.nix4
-rw-r--r--pkgs/applications/misc/slade/git.nix4
-rw-r--r--pkgs/applications/misc/sleepyhead/default.nix2
-rw-r--r--pkgs/applications/misc/slic3r/default.nix2
-rw-r--r--pkgs/applications/misc/smos/default.nix4
-rw-r--r--pkgs/applications/misc/snowsql/default.nix4
-rw-r--r--pkgs/applications/misc/speedread/default.nix4
-rw-r--r--pkgs/applications/misc/sqliteman/default.nix4
-rw-r--r--pkgs/applications/misc/ssocr/default.nix4
-rw-r--r--pkgs/applications/misc/ssw/default.nix4
-rw-r--r--pkgs/applications/misc/stog/default.nix4
-rw-r--r--pkgs/applications/misc/stretchly/default.nix2
-rw-r--r--pkgs/applications/misc/styx/default.nix4
-rw-r--r--pkgs/applications/misc/subsurface/default.nix8
-rw-r--r--pkgs/applications/misc/swappy/default.nix4
-rw-r--r--pkgs/applications/misc/synapse/default.nix4
-rw-r--r--pkgs/applications/misc/syncthing-tray/default.nix4
-rw-r--r--pkgs/applications/misc/systembus-notify/default.nix4
-rw-r--r--pkgs/applications/misc/tabula/default.nix4
-rw-r--r--pkgs/applications/misc/tasknc/default.nix4
-rw-r--r--pkgs/applications/misc/taskopen/default.nix4
-rw-r--r--pkgs/applications/misc/tasksh/default.nix4
-rw-r--r--pkgs/applications/misc/taskwarrior-tui/default.nix4
-rw-r--r--pkgs/applications/misc/taskwarrior/default.nix4
-rw-r--r--pkgs/applications/misc/tdrop/default.nix2
-rw-r--r--pkgs/applications/misc/termdown/default.nix4
-rw-r--r--pkgs/applications/misc/terminal-parrot/default.nix4
-rw-r--r--pkgs/applications/misc/terminal-typeracer/default.nix4
-rw-r--r--pkgs/applications/misc/termpdf.py/default.nix4
-rw-r--r--pkgs/applications/misc/thinking-rock/default.nix4
-rw-r--r--pkgs/applications/misc/tickrs/default.nix4
-rw-r--r--pkgs/applications/misc/timewarrior/default.nix4
-rw-r--r--pkgs/applications/misc/tint2/default.nix4
-rw-r--r--pkgs/applications/misc/tipp10/default.nix4
-rw-r--r--pkgs/applications/misc/tippecanoe/default.nix4
-rw-r--r--pkgs/applications/misc/tiramisu/default.nix4
-rw-r--r--pkgs/applications/misc/tiv/default.nix4
-rw-r--r--pkgs/applications/misc/tnef/default.nix4
-rw-r--r--pkgs/applications/misc/todiff/default.nix4
-rw-r--r--pkgs/applications/misc/todolist/default.nix4
-rw-r--r--pkgs/applications/misc/tomboy/default.nix2
-rw-r--r--pkgs/applications/misc/toot/default.nix4
-rw-r--r--pkgs/applications/misc/tootle/default.nix4
-rw-r--r--pkgs/applications/misc/topydo/default.nix4
-rw-r--r--pkgs/applications/misc/translate-shell/default.nix4
-rw-r--r--pkgs/applications/misc/tthsum/default.nix4
-rw-r--r--pkgs/applications/misc/tty-share/default.nix4
-rw-r--r--pkgs/applications/misc/tty-solitaire/default.nix4
-rw-r--r--pkgs/applications/misc/tut/default.nix4
-rw-r--r--pkgs/applications/misc/tvbrowser/bin.nix4
-rw-r--r--pkgs/applications/misc/tzupdate/default.nix4
-rw-r--r--pkgs/applications/misc/udiskie/default.nix4
-rw-r--r--pkgs/applications/misc/ulauncher/default.nix4
-rw-r--r--pkgs/applications/misc/upwork/default.nix4
-rw-r--r--pkgs/applications/misc/urlscan/default.nix4
-rw-r--r--pkgs/applications/misc/urlview/default.nix4
-rw-r--r--pkgs/applications/misc/usync/default.nix4
-rw-r--r--pkgs/applications/misc/verbiste/default.nix4
-rw-r--r--pkgs/applications/misc/vifm/default.nix2
-rw-r--r--pkgs/applications/misc/viking/default.nix4
-rw-r--r--pkgs/applications/misc/volnoti/default.nix4
-rw-r--r--pkgs/applications/misc/vp/default.nix4
-rw-r--r--pkgs/applications/misc/vym/default.nix4
-rw-r--r--pkgs/applications/misc/waybar/default.nix4
-rw-r--r--pkgs/applications/misc/wcalc/default.nix4
-rw-r--r--pkgs/applications/misc/weather/default.nix4
-rw-r--r--pkgs/applications/misc/web-media-controller/default.nix4
-rw-r--r--pkgs/applications/misc/worker/default.nix4
-rw-r--r--pkgs/applications/misc/workrave/default.nix4
-rw-r--r--pkgs/applications/misc/xastir/default.nix4
-rw-r--r--pkgs/applications/misc/xautoclick/default.nix4
-rw-r--r--pkgs/applications/misc/xbattbar/default.nix4
-rw-r--r--pkgs/applications/misc/xchm/default.nix4
-rw-r--r--pkgs/applications/misc/xcruiser/default.nix4
-rw-r--r--pkgs/applications/misc/xdgmenumaker/default.nix4
-rw-r--r--pkgs/applications/misc/xdragon/default.nix4
-rw-r--r--pkgs/applications/misc/xiphos/default.nix4
-rw-r--r--pkgs/applications/misc/xkbd/default.nix4
-rw-r--r--pkgs/applications/misc/xkblayout-state/default.nix4
-rw-r--r--pkgs/applications/misc/xkbmon/default.nix4
-rw-r--r--pkgs/applications/misc/xmenu/default.nix4
-rw-r--r--pkgs/applications/misc/xmind/default.nix2
-rw-r--r--pkgs/applications/misc/xneur/default.nix4
-rw-r--r--pkgs/applications/misc/xpad/default.nix4
-rw-r--r--pkgs/applications/misc/xpdf/default.nix4
-rw-r--r--pkgs/applications/misc/xpdf/libxpdf.nix4
-rw-r--r--pkgs/applications/misc/xrandr-invert-colors/default.nix4
-rw-r--r--pkgs/applications/misc/xscope/default.nix4
-rw-r--r--pkgs/applications/misc/xsw/default.nix2
-rw-r--r--pkgs/applications/misc/xteddy/default.nix4
-rw-r--r--pkgs/applications/misc/xygrib/default.nix4
-rw-r--r--pkgs/applications/misc/yarssr/default.nix2
-rw-r--r--pkgs/applications/misc/yokadi/default.nix4
-rw-r--r--pkgs/applications/misc/yubioath-desktop/default.nix4
-rw-r--r--pkgs/applications/misc/zathura/djvu/default.nix4
-rw-r--r--pkgs/applications/misc/zola/default.nix4
-rw-r--r--pkgs/applications/misc/zscroll/default.nix4
-rw-r--r--pkgs/applications/networking/3proxy/default.nix4
-rw-r--r--pkgs/applications/networking/apache-directory-studio/default.nix4
-rw-r--r--pkgs/applications/networking/appgate-sdp/default.nix2
-rw-r--r--pkgs/applications/networking/brig/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/asuka/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/brave/default.nix2
-rw-r--r--pkgs/applications/networking/browsers/browsh/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/castor/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/dillo/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/elinks/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/eolie/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/ephemeral/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/falkon/default.nix2
-rw-r--r--pkgs/applications/networking/browsers/firefox-bin/default.nix2
-rw-r--r--pkgs/applications/networking/browsers/links2/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/luakit/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/lynx/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/midori/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/browser.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/buildsystem.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libcss.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libdom.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libhubbub.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libnsbmp.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libnsfb.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libnsgif.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libnslog.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libnspsl.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libnsutils.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libparserutils.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libsvgtiny.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libutf8proc.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/libwapcaplet.nix4
-rw-r--r--pkgs/applications/networking/browsers/netsurf/nsgenbind.nix4
-rw-r--r--pkgs/applications/networking/browsers/nyxt/default.nix2
-rw-r--r--pkgs/applications/networking/browsers/qutebrowser/default.nix2
-rw-r--r--pkgs/applications/networking/browsers/surf/default.nix2
-rw-r--r--pkgs/applications/networking/browsers/tor-browser-bundle-bin/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/vivaldi/default.nix4
-rw-r--r--pkgs/applications/networking/browsers/vivaldi/ffmpeg-codecs.nix4
-rw-r--r--pkgs/applications/networking/browsers/vivaldi/widevine.nix4
-rw-r--r--pkgs/applications/networking/c14/default.nix4
-rw-r--r--pkgs/applications/networking/calls/default.nix4
-rw-r--r--pkgs/applications/networking/cawbird/default.nix4
-rw-r--r--pkgs/applications/networking/charles/default.nix4
-rw-r--r--pkgs/applications/networking/cloudflared/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/atlantis/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/click/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/docker-machine/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/docker-machine/kvm.nix4
-rw-r--r--pkgs/applications/networking/cluster/docker-machine/xhyve.nix4
-rw-r--r--pkgs/applications/networking/cluster/flink/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/fluxcd/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/fluxctl/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/habitat/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/hadoop/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/helm/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/k9s/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/kops/default.nix2
-rw-r--r--pkgs/applications/networking/cluster/kubeless/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/kubelogin/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/kubernix/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/linkerd/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/minikube/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/node-problem-detector/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/octant/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/openshift/default.nix2
-rw-r--r--pkgs/applications/networking/cluster/pig/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/popeye/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/ssm-agent/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-inventory/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/ansible/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/cloudfoundry/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/elasticsearch/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/gandi/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/hcloud/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/keycloak/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/libvirt/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/linuxbox/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/lxd/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/shell/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/vercel/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform-providers/vpsadmin/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/terraform/default.nix2
-rw-r--r--pkgs/applications/networking/cluster/terranix/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/tilt/default.nix4
-rw-r--r--pkgs/applications/networking/cluster/velero/default.nix4
-rw-r--r--pkgs/applications/networking/compactor/default.nix4
-rw-r--r--pkgs/applications/networking/datovka/default.nix4
-rw-r--r--pkgs/applications/networking/davmail/default.nix4
-rw-r--r--pkgs/applications/networking/dsvpn/default.nix4
-rw-r--r--pkgs/applications/networking/dyndns/cfdyndns/default.nix4
-rw-r--r--pkgs/applications/networking/esniper/default.nix4
-rw-r--r--pkgs/applications/networking/feedreaders/canto-daemon/default.nix4
-rw-r--r--pkgs/applications/networking/feedreaders/castget/default.nix2
-rw-r--r--pkgs/applications/networking/feedreaders/feedreader/default.nix4
-rw-r--r--pkgs/applications/networking/feedreaders/newsboat/default.nix4
-rw-r--r--pkgs/applications/networking/feedreaders/rawdog/default.nix4
-rw-r--r--pkgs/applications/networking/feedreaders/rssguard/default.nix4
-rw-r--r--pkgs/applications/networking/feedreaders/rsstail/default.nix4
-rw-r--r--pkgs/applications/networking/firehol/default.nix2
-rw-r--r--pkgs/applications/networking/firehol/iprange.nix4
-rw-r--r--pkgs/applications/networking/flent/default.nix4
-rw-r--r--pkgs/applications/networking/flent/http-getter.nix4
-rw-r--r--pkgs/applications/networking/ftp/filezilla/default.nix4
-rw-r--r--pkgs/applications/networking/ftp/taxi/default.nix4
-rw-r--r--pkgs/applications/networking/gdrive/default.nix4
-rw-r--r--pkgs/applications/networking/gmailctl/default.nix4
-rw-r--r--pkgs/applications/networking/gnome-network-displays/default.nix4
-rw-r--r--pkgs/applications/networking/gns3/server.nix2
-rw-r--r--pkgs/applications/networking/gopher/gopher/default.nix4
-rw-r--r--pkgs/applications/networking/gopher/sacc/default.nix4
-rw-r--r--pkgs/applications/networking/ids/suricata/default.nix2
-rw-r--r--pkgs/applications/networking/ids/zeek/default.nix4
-rw-r--r--pkgs/applications/networking/ike/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/SkypeExport/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/blink/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/bluejeans/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/cordless/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/coyim/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/dino/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/discord/base.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/element/element-desktop.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/ferdi/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/fractal/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/franz/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/freetalk/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/gitter/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/gomuks/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/hipchat/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/jitsi-meet-electron/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/jitsi/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/mattermost-desktop/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/mcabber/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/mikutter/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/mirage/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/mm/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/neochat/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/nheko/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/carbons/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/otr/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-latex/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-opensteamworks/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-osd/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-skypeweb/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-xmpp-receipts/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-discord/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-facebook/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-hangouts/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-lurch/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-matrix/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-plugin-pack/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-slack/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-xmpp-http-upload/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/sipe/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/telegram-purple/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/tox-prpl/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin-plugins/window-merge/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/pidgin/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/pybitmessage/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/qtox/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/rambox/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/rambox/pro.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/ricochet/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/ring-daemon/default.nix6
-rw-r--r--pkgs/applications/networking/instant-messengers/ring-daemon/restbed.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/salut-a-toi/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/salut-a-toi/requirements.nix6
-rw-r--r--pkgs/applications/networking/instant-messengers/scudcloud/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/skypeforlinux/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/slack-term/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/slack/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/stride/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/swift-im/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/teams/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/teamspeak/client.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/teamspeak/server.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/telepathy/gabble/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/telepathy/logger/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/telepathy/mission-control/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/telepathy/salut/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/tensor/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/torchat/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/toxic/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/turses/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/twinkle/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/utox/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/vacuum/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/vk-messenger/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/wavebox/default.nix4
-rw-r--r--pkgs/applications/networking/instant-messengers/wire-desktop/default.nix2
-rw-r--r--pkgs/applications/networking/instant-messengers/xmpp-client/default.nix4
-rw-r--r--pkgs/applications/networking/ipfs-cluster/default.nix4
-rw-r--r--pkgs/applications/networking/ipfs/default.nix4
-rw-r--r--pkgs/applications/networking/ipget/default.nix4
-rw-r--r--pkgs/applications/networking/iptraf-ng/default.nix4
-rw-r--r--pkgs/applications/networking/irc/communi/default.nix4
-rw-r--r--pkgs/applications/networking/irc/epic5/default.nix4
-rw-r--r--pkgs/applications/networking/irc/glowing-bear/default.nix4
-rw-r--r--pkgs/applications/networking/irc/hexchat/default.nix4
-rw-r--r--pkgs/applications/networking/irc/quassel/default.nix4
-rw-r--r--pkgs/applications/networking/irc/qweechat/default.nix4
-rw-r--r--pkgs/applications/networking/irc/weechat/scripts/wee-slack/default.nix4
-rw-r--r--pkgs/applications/networking/irc/weechat/scripts/weechat-autosort/default.nix4
-rw-r--r--pkgs/applications/networking/irc/weechat/scripts/weechat-matrix-bridge/default.nix4
-rw-r--r--pkgs/applications/networking/irc/weechat/scripts/weechat-matrix/default.nix4
-rw-r--r--pkgs/applications/networking/irc/weechat/scripts/weechat-notify-send/default.nix4
-rw-r--r--pkgs/applications/networking/irc/weechat/scripts/weechat-otr/default.nix4
-rw-r--r--pkgs/applications/networking/jmeter/default.nix4
-rw-r--r--pkgs/applications/networking/jnetmap/default.nix4
-rw-r--r--pkgs/applications/networking/libcoap/default.nix4
-rw-r--r--pkgs/applications/networking/lieer/default.nix4
-rw-r--r--pkgs/applications/networking/linssid/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/aerc/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/afew/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/alpine/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/astroid/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/balsa/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/evolution/evolution-ews/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/lumail/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/mailnag/goa-plugin.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/mailpile/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/mailspring/default.nix2
-rw-r--r--pkgs/applications/networking/mailreaders/meli/default.nix2
-rw-r--r--pkgs/applications/networking/mailreaders/mlarchive2maildir/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/mmh/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/msgviewer/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/neomutt/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/notmuch-addrlookup/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/notmuch-bower/default.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/thunderbird-bin/68.nix4
-rw-r--r--pkgs/applications/networking/mailreaders/thunderbird/68.nix2
-rw-r--r--pkgs/applications/networking/mkchromecast/default.nix4
-rw-r--r--pkgs/applications/networking/modem-manager-gui/default.nix4
-rw-r--r--pkgs/applications/networking/msmtp/default.nix2
-rw-r--r--pkgs/applications/networking/mullvad-vpn/default.nix2
-rw-r--r--pkgs/applications/networking/ndppd/default.nix4
-rw-r--r--pkgs/applications/networking/newsreaders/liferea/default.nix4
-rw-r--r--pkgs/applications/networking/newsreaders/pan/default.nix4
-rw-r--r--pkgs/applications/networking/newsreaders/quiterss/default.nix4
-rw-r--r--pkgs/applications/networking/newsreaders/slrn/default.nix4
-rw-r--r--pkgs/applications/networking/offrss/default.nix4
-rw-r--r--pkgs/applications/networking/omping/default.nix4
-rw-r--r--pkgs/applications/networking/openbazaar/client.nix4
-rw-r--r--pkgs/applications/networking/openbazaar/default.nix4
-rw-r--r--pkgs/applications/networking/owamp/default.nix4
-rw-r--r--pkgs/applications/networking/owncloud-client/default.nix2
-rw-r--r--pkgs/applications/networking/p2p/deluge/1.nix4
-rw-r--r--pkgs/applications/networking/p2p/deluge/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/eiskaltdcpp/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/frostwire/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/frostwire/frostwire-bin.nix4
-rw-r--r--pkgs/applications/networking/p2p/gnunet/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/ncdc/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/opentracker/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/retroshare/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/stig/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/synapse-bt/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/tixati/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/torrential/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/transmission-remote-gtk/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/tremc/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/tribler/default.nix2
-rw-r--r--pkgs/applications/networking/p2p/vuze/default.nix4
-rw-r--r--pkgs/applications/networking/p2p/zeronet/default.nix4
-rw-r--r--pkgs/applications/networking/pcloud/default.nix4
-rw-r--r--pkgs/applications/networking/ping/default.nix4
-rw-r--r--pkgs/applications/networking/pjsip/default.nix4
-rw-r--r--pkgs/applications/networking/protocol/default.nix4
-rw-r--r--pkgs/applications/networking/ps2client/default.nix4
-rw-r--r--pkgs/applications/networking/pyload/default.nix4
-rw-r--r--pkgs/applications/networking/qv2ray/default.nix4
-rw-r--r--pkgs/applications/networking/remote/anydesk/default.nix4
-rw-r--r--pkgs/applications/networking/remote/nice-dcv-client/default.nix4
-rw-r--r--pkgs/applications/networking/remote/vmware-horizon-client/default.nix4
-rw-r--r--pkgs/applications/networking/remote/waypipe/default.nix4
-rw-r--r--pkgs/applications/networking/remote/wayvnc/default.nix4
-rw-r--r--pkgs/applications/networking/remote/x2goclient/default.nix4
-rw-r--r--pkgs/applications/networking/remote/x2goserver/default.nix2
-rw-r--r--pkgs/applications/networking/remote/xrdp/default.nix4
-rw-r--r--pkgs/applications/networking/resilio-sync/default.nix4
-rw-r--r--pkgs/applications/networking/scaleft/default.nix4
-rw-r--r--pkgs/applications/networking/shellhub-agent/default.nix4
-rw-r--r--pkgs/applications/networking/sieve-connect/default.nix4
-rw-r--r--pkgs/applications/networking/sniffers/etherape/default.nix4
-rw-r--r--pkgs/applications/networking/sniffers/ettercap/default.nix4
-rw-r--r--pkgs/applications/networking/sniffers/kismet/default.nix4
-rw-r--r--pkgs/applications/networking/sniffers/sngrep/default.nix4
-rw-r--r--pkgs/applications/networking/sniffers/whsniff/default.nix4
-rw-r--r--pkgs/applications/networking/sniffers/wireshark/default.nix4
-rw-r--r--pkgs/applications/networking/sniproxy/default.nix4
-rw-r--r--pkgs/applications/networking/soapui/default.nix4
-rw-r--r--pkgs/applications/networking/super-productivity/default.nix4
-rw-r--r--pkgs/applications/networking/sync/acd_cli/default.nix4
-rw-r--r--pkgs/applications/networking/sync/casync/default.nix4
-rw-r--r--pkgs/applications/networking/sync/desync/default.nix4
-rw-r--r--pkgs/applications/networking/sync/lsyncd/default.nix4
-rw-r--r--pkgs/applications/networking/sync/onedrive/default.nix2
-rw-r--r--pkgs/applications/networking/sync/rclone/browser.nix4
-rw-r--r--pkgs/applications/networking/sync/rclone/default.nix4
-rw-r--r--pkgs/applications/networking/sync/rsync/base.nix4
-rw-r--r--pkgs/applications/networking/sync/rsync/default.nix4
-rw-r--r--pkgs/applications/networking/sync/rsync/rrsync.nix4
-rw-r--r--pkgs/applications/networking/syncthing-gtk/default.nix4
-rw-r--r--pkgs/applications/networking/termius/default.nix2
-rw-r--r--pkgs/applications/networking/testssl/default.nix2
-rw-r--r--pkgs/applications/networking/tsung/default.nix2
-rw-r--r--pkgs/applications/networking/umurmur/default.nix4
-rw-r--r--pkgs/applications/networking/versus/default.nix4
-rw-r--r--pkgs/applications/networking/vnstat/default.nix4
-rw-r--r--pkgs/applications/networking/weather/meteo/default.nix4
-rw-r--r--pkgs/applications/networking/znc/default.nix4
-rw-r--r--pkgs/applications/networking/znc/modules.nix14
-rw-r--r--pkgs/applications/office/abiword/default.nix4
-rw-r--r--pkgs/applications/office/aesop/default.nix4
-rw-r--r--pkgs/applications/office/agenda/default.nix4
-rw-r--r--pkgs/applications/office/atlassian-cli/default.nix4
-rw-r--r--pkgs/applications/office/beamerpresenter/default.nix4
-rw-r--r--pkgs/applications/office/bookworm/default.nix4
-rw-r--r--pkgs/applications/office/cb2bib/default.nix4
-rw-r--r--pkgs/applications/office/docear/default.nix4
-rw-r--r--pkgs/applications/office/elementary-planner/default.nix4
-rw-r--r--pkgs/applications/office/envelope/default.nix4
-rw-r--r--pkgs/applications/office/espanso/default.nix4
-rw-r--r--pkgs/applications/office/flexibee/default.nix4
-rw-r--r--pkgs/applications/office/gnumeric/default.nix4
-rw-r--r--pkgs/applications/office/grisbi/default.nix4
-rw-r--r--pkgs/applications/office/gtg/default.nix4
-rw-r--r--pkgs/applications/office/homebank/default.nix4
-rw-r--r--pkgs/applications/office/ib/controller/default.nix4
-rw-r--r--pkgs/applications/office/ib/tws/default.nix4
-rw-r--r--pkgs/applications/office/jabref/default.nix4
-rw-r--r--pkgs/applications/office/jameica/default.nix4
-rw-r--r--pkgs/applications/office/khronos/default.nix4
-rw-r--r--pkgs/applications/office/ledger-autosync/default.nix4
-rw-r--r--pkgs/applications/office/marp/default.nix4
-rw-r--r--pkgs/applications/office/mendeley/default.nix4
-rw-r--r--pkgs/applications/office/moneyplex/default.nix4
-rw-r--r--pkgs/applications/office/mytetra/default.nix4
-rw-r--r--pkgs/applications/office/notes-up/default.nix4
-rw-r--r--pkgs/applications/office/osmo/default.nix4
-rw-r--r--pkgs/applications/office/p3x-onenote/default.nix4
-rw-r--r--pkgs/applications/office/pinpoint/default.nix4
-rw-r--r--pkgs/applications/office/planner/default.nix4
-rw-r--r--pkgs/applications/office/portfolio/default.nix4
-rw-r--r--pkgs/applications/office/scribus/unstable.nix4
-rw-r--r--pkgs/applications/office/skanlite/default.nix4
-rw-r--r--pkgs/applications/office/softmaker/generic.nix4
-rw-r--r--pkgs/applications/office/spice-up/default.nix4
-rw-r--r--pkgs/applications/office/tagainijisho/default.nix4
-rw-r--r--pkgs/applications/office/timekeeper/default.nix2
-rw-r--r--pkgs/applications/office/timetable/default.nix4
-rw-r--r--pkgs/applications/office/timeular/default.nix4
-rw-r--r--pkgs/applications/office/todoman/default.nix4
-rw-r--r--pkgs/applications/office/treesheets/default.nix4
-rw-r--r--pkgs/applications/office/trilium/default.nix4
-rw-r--r--pkgs/applications/office/tudu/default.nix4
-rw-r--r--pkgs/applications/office/watson/default.nix4
-rw-r--r--pkgs/applications/office/wordgrinder/default.nix4
-rw-r--r--pkgs/applications/office/zim/default.nix4
-rw-r--r--pkgs/applications/office/zotero/default.nix4
-rw-r--r--pkgs/applications/qubes/qubes-core-vchan-xen/default.nix4
-rw-r--r--pkgs/applications/radio/airspy/default.nix2
-rw-r--r--pkgs/applications/radio/aldo/default.nix4
-rw-r--r--pkgs/applications/radio/chirp/default.nix4
-rw-r--r--pkgs/applications/radio/cubicsdr/default.nix4
-rw-r--r--pkgs/applications/radio/dablin/default.nix4
-rw-r--r--pkgs/applications/radio/dabtools/default.nix4
-rw-r--r--pkgs/applications/radio/dmrconfig/default.nix4
-rw-r--r--pkgs/applications/radio/dsd/default.nix4
-rw-r--r--pkgs/applications/radio/dump1090/default.nix4
-rw-r--r--pkgs/applications/radio/ebook2cw/default.nix4
-rw-r--r--pkgs/applications/radio/gnss-sdr/default.nix4
-rw-r--r--pkgs/applications/radio/gnuradio/ais.nix4
-rw-r--r--pkgs/applications/radio/gnuradio/gsm.nix4
-rw-r--r--pkgs/applications/radio/gnuradio/limesdr.nix4
-rw-r--r--pkgs/applications/radio/gnuradio/nacl.nix4
-rw-r--r--pkgs/applications/radio/gnuradio/osmosdr.nix4
-rw-r--r--pkgs/applications/radio/gnuradio/rds.nix4
-rw-r--r--pkgs/applications/radio/gqrx/default.nix4
-rw-r--r--pkgs/applications/radio/hackrf/default.nix4
-rw-r--r--pkgs/applications/radio/kalibrate-hackrf/default.nix4
-rw-r--r--pkgs/applications/radio/kalibrate-rtl/default.nix4
-rw-r--r--pkgs/applications/radio/limesuite/default.nix4
-rw-r--r--pkgs/applications/radio/multimon-ng/default.nix4
-rw-r--r--pkgs/applications/radio/qradiolink/default.nix4
-rw-r--r--pkgs/applications/radio/qsstv/default.nix4
-rw-r--r--pkgs/applications/radio/quisk/default.nix4
-rw-r--r--pkgs/applications/radio/rtl-ais/default.nix4
-rw-r--r--pkgs/applications/radio/rtl-sdr/default.nix4
-rw-r--r--pkgs/applications/radio/rtl_433/default.nix4
-rw-r--r--pkgs/applications/radio/soapyairspy/default.nix4
-rw-r--r--pkgs/applications/radio/soapyaudio/default.nix4
-rw-r--r--pkgs/applications/radio/soapybladerf/default.nix4
-rw-r--r--pkgs/applications/radio/soapyhackrf/default.nix4
-rw-r--r--pkgs/applications/radio/soapyremote/default.nix4
-rw-r--r--pkgs/applications/radio/soapyrtlsdr/default.nix4
-rw-r--r--pkgs/applications/radio/soapysdr/default.nix2
-rw-r--r--pkgs/applications/radio/soapyuhd/default.nix4
-rw-r--r--pkgs/applications/radio/soundmodem/default.nix4
-rw-r--r--pkgs/applications/radio/svxlink/default.nix4
-rw-r--r--pkgs/applications/radio/tlf/default.nix4
-rw-r--r--pkgs/applications/radio/tqsl/default.nix4
-rw-r--r--pkgs/applications/radio/uhd/default.nix4
-rw-r--r--pkgs/applications/radio/unixcw/default.nix4
-rw-r--r--pkgs/applications/radio/wsjtx/default.nix4
-rw-r--r--pkgs/applications/radio/xlog/default.nix4
-rw-r--r--pkgs/applications/science/astronomy/gpredict/default.nix4
-rw-r--r--pkgs/applications/science/astronomy/phd2/default.nix4
-rw-r--r--pkgs/applications/science/astronomy/siril/default.nix4
-rw-r--r--pkgs/applications/science/astronomy/xearth/default.nix4
-rw-r--r--pkgs/applications/science/astronomy/xplanet/default.nix4
-rw-r--r--pkgs/applications/science/biology/EZminc/default.nix4
-rw-r--r--pkgs/applications/science/biology/N3/default.nix4
-rw-r--r--pkgs/applications/science/biology/ants/default.nix4
-rw-r--r--pkgs/applications/science/biology/aragorn/default.nix4
-rw-r--r--pkgs/applications/science/biology/bayescan/default.nix4
-rw-r--r--pkgs/applications/science/biology/bcftools/default.nix4
-rw-r--r--pkgs/applications/science/biology/bedtools/default.nix4
-rw-r--r--pkgs/applications/science/biology/bftools/default.nix2
-rw-r--r--pkgs/applications/science/biology/blast/default.nix2
-rw-r--r--pkgs/applications/science/biology/bowtie/default.nix4
-rw-r--r--pkgs/applications/science/biology/bowtie2/default.nix4
-rw-r--r--pkgs/applications/science/biology/bwa/default.nix4
-rw-r--r--pkgs/applications/science/biology/cd-hit/default.nix4
-rw-r--r--pkgs/applications/science/biology/clustal-omega/default.nix4
-rw-r--r--pkgs/applications/science/biology/cmtk/default.nix4
-rw-r--r--pkgs/applications/science/biology/conglomerate/default.nix4
-rw-r--r--pkgs/applications/science/biology/dcm2niix/default.nix4
-rw-r--r--pkgs/applications/science/biology/delly/default.nix4
-rw-r--r--pkgs/applications/science/biology/diamond/default.nix4
-rw-r--r--pkgs/applications/science/biology/ecopcr/default.nix4
-rw-r--r--pkgs/applications/science/biology/eggnog-mapper/default.nix4
-rw-r--r--pkgs/applications/science/biology/est-sfs/default.nix4
-rw-r--r--pkgs/applications/science/biology/exonerate/default.nix4
-rw-r--r--pkgs/applications/science/biology/fastp/default.nix4
-rw-r--r--pkgs/applications/science/biology/freebayes/default.nix4
-rw-r--r--pkgs/applications/science/biology/hisat2/default.nix4
-rw-r--r--pkgs/applications/science/biology/hmmer/default.nix4
-rw-r--r--pkgs/applications/science/biology/igv/default.nix4
-rw-r--r--pkgs/applications/science/biology/inormalize/default.nix4
-rw-r--r--pkgs/applications/science/biology/itsx/default.nix4
-rw-r--r--pkgs/applications/science/biology/kallisto/default.nix4
-rw-r--r--pkgs/applications/science/biology/kent/default.nix4
-rw-r--r--pkgs/applications/science/biology/kssd/default.nix4
-rw-r--r--pkgs/applications/science/biology/last/default.nix4
-rw-r--r--pkgs/applications/science/biology/lumpy/default.nix4
-rw-r--r--pkgs/applications/science/biology/macse/default.nix4
-rw-r--r--pkgs/applications/science/biology/manta/default.nix4
-rw-r--r--pkgs/applications/science/biology/megahit/default.nix4
-rw-r--r--pkgs/applications/science/biology/minc-tools/default.nix4
-rw-r--r--pkgs/applications/science/biology/minc-widgets/default.nix4
-rw-r--r--pkgs/applications/science/biology/minia/default.nix4
-rw-r--r--pkgs/applications/science/biology/minimap2/default.nix4
-rw-r--r--pkgs/applications/science/biology/mni_autoreg/default.nix4
-rw-r--r--pkgs/applications/science/biology/mosdepth/default.nix4
-rw-r--r--pkgs/applications/science/biology/mrbayes/default.nix4
-rw-r--r--pkgs/applications/science/biology/muscle/default.nix4
-rw-r--r--pkgs/applications/science/biology/neuron/default.nix4
-rw-r--r--pkgs/applications/science/biology/niftyreg/default.nix4
-rw-r--r--pkgs/applications/science/biology/niftyseg/default.nix4
-rw-r--r--pkgs/applications/science/biology/octopus/default.nix4
-rw-r--r--pkgs/applications/science/biology/picard-tools/default.nix4
-rw-r--r--pkgs/applications/science/biology/platypus/default.nix4
-rw-r--r--pkgs/applications/science/biology/prodigal/default.nix4
-rw-r--r--pkgs/applications/science/biology/raxml/default.nix4
-rw-r--r--pkgs/applications/science/biology/sambamba/default.nix4
-rw-r--r--pkgs/applications/science/biology/samblaster/default.nix4
-rw-r--r--pkgs/applications/science/biology/samtools/default.nix4
-rw-r--r--pkgs/applications/science/biology/samtools/samtools_0_1_19.nix4
-rw-r--r--pkgs/applications/science/biology/seaview/default.nix4
-rw-r--r--pkgs/applications/science/biology/snpeff/default.nix4
-rw-r--r--pkgs/applications/science/biology/somatic-sniper/default.nix4
-rw-r--r--pkgs/applications/science/biology/sortmerna/default.nix4
-rw-r--r--pkgs/applications/science/biology/spades/default.nix4
-rw-r--r--pkgs/applications/science/biology/star/default.nix4
-rw-r--r--pkgs/applications/science/biology/strelka/default.nix4
-rw-r--r--pkgs/applications/science/biology/sumatools/default.nix4
-rw-r--r--pkgs/applications/science/biology/svaba/default.nix4
-rw-r--r--pkgs/applications/science/biology/tebreak/default.nix4
-rwxr-xr-xpkgs/applications/science/biology/trimal/default.nix4
-rw-r--r--pkgs/applications/science/biology/varscan/default.nix4
-rwxr-xr-xpkgs/applications/science/biology/vcftools/default.nix4
-rw-r--r--pkgs/applications/science/biology/whisper/default.nix4
-rw-r--r--pkgs/applications/science/chemistry/d-seams/default.nix2
-rw-r--r--pkgs/applications/science/chemistry/jmol/default.nix2
-rw-r--r--pkgs/applications/science/chemistry/molden/default.nix4
-rw-r--r--pkgs/applications/science/chemistry/octopus/default.nix4
-rw-r--r--pkgs/applications/science/chemistry/openmolcas/default.nix4
-rw-r--r--pkgs/applications/science/chemistry/quantum-espresso/default.nix4
-rw-r--r--pkgs/applications/science/chemistry/siesta/default.nix4
-rw-r--r--pkgs/applications/science/electronics/alliance/default.nix4
-rw-r--r--pkgs/applications/science/electronics/bitscope/common.nix4
-rw-r--r--pkgs/applications/science/electronics/csxcad/default.nix4
-rw-r--r--pkgs/applications/science/electronics/diylc/default.nix4
-rw-r--r--pkgs/applications/science/electronics/dsview/libsigrok4dsl.nix4
-rw-r--r--pkgs/applications/science/electronics/dsview/libsigrokdecode4dsl.nix4
-rw-r--r--pkgs/applications/science/electronics/eagle/eagle.nix4
-rw-r--r--pkgs/applications/science/electronics/eagle/eagle7.nix4
-rw-r--r--pkgs/applications/science/electronics/fparser/default.nix4
-rw-r--r--pkgs/applications/science/electronics/geda/default.nix4
-rw-r--r--pkgs/applications/science/electronics/gerbv/default.nix4
-rw-r--r--pkgs/applications/science/electronics/hal-hardware-analyzer/default.nix4
-rw-r--r--pkgs/applications/science/electronics/hyp2mat/default.nix4
-rw-r--r--pkgs/applications/science/electronics/kicad/i18n.nix4
-rw-r--r--pkgs/applications/science/electronics/librepcb/default.nix2
-rw-r--r--pkgs/applications/science/electronics/magic-vlsi/default.nix4
-rw-r--r--pkgs/applications/science/electronics/ngspice/default.nix4
-rw-r--r--pkgs/applications/science/electronics/pcb/default.nix4
-rw-r--r--pkgs/applications/science/electronics/verilator/default.nix4
-rw-r--r--pkgs/applications/science/electronics/verilog/default.nix4
-rw-r--r--pkgs/applications/science/electronics/vhd2vl/default.nix4
-rw-r--r--pkgs/applications/science/electronics/xcircuit/default.nix4
-rw-r--r--pkgs/applications/science/geometry/antiprism/default.nix4
-rw-r--r--pkgs/applications/science/geometry/drgeo/default.nix4
-rw-r--r--pkgs/applications/science/logic/abc/default.nix4
-rw-r--r--pkgs/applications/science/logic/acgtk/default.nix4
-rw-r--r--pkgs/applications/science/logic/aspino/default.nix4
-rw-r--r--pkgs/applications/science/logic/boolector/default.nix2
-rw-r--r--pkgs/applications/science/logic/btor2tools/default.nix4
-rw-r--r--pkgs/applications/science/logic/cadical/default.nix4
-rw-r--r--pkgs/applications/science/logic/cedille/default.nix2
-rw-r--r--pkgs/applications/science/logic/celf/default.nix4
-rw-r--r--pkgs/applications/science/logic/clprover/clprover.nix4
-rw-r--r--pkgs/applications/science/logic/coq/default.nix6
-rw-r--r--pkgs/applications/science/logic/coq2html/default.nix4
-rw-r--r--pkgs/applications/science/logic/cryptominisat/default.nix4
-rw-r--r--pkgs/applications/science/logic/cubicle/default.nix4
-rw-r--r--pkgs/applications/science/logic/cvc3/default.nix4
-rw-r--r--pkgs/applications/science/logic/cvc4/default.nix4
-rw-r--r--pkgs/applications/science/logic/drat-trim/default.nix4
-rw-r--r--pkgs/applications/science/logic/eprover/default.nix4
-rw-r--r--pkgs/applications/science/logic/fast-downward/default.nix2
-rw-r--r--pkgs/applications/science/logic/glucose/default.nix4
-rw-r--r--pkgs/applications/science/logic/glucose/syrup.nix4
-rw-r--r--pkgs/applications/science/logic/hol/default.nix4
-rw-r--r--pkgs/applications/science/logic/hol_light/default.nix4
-rw-r--r--pkgs/applications/science/logic/iprover/default.nix4
-rw-r--r--pkgs/applications/science/logic/isabelle/default.nix4
-rw-r--r--pkgs/applications/science/logic/key/default.nix4
-rw-r--r--pkgs/applications/science/logic/lean/default.nix4
-rw-r--r--pkgs/applications/science/logic/lean2/default.nix4
-rw-r--r--pkgs/applications/science/logic/leo2/default.nix4
-rw-r--r--pkgs/applications/science/logic/lingeling/default.nix4
-rw-r--r--pkgs/applications/science/logic/mcrl2/default.nix4
-rw-r--r--pkgs/applications/science/logic/metis-prover/default.nix4
-rw-r--r--pkgs/applications/science/logic/minisat/default.nix4
-rw-r--r--pkgs/applications/science/logic/open-wbo/default.nix4
-rw-r--r--pkgs/applications/science/logic/opensmt/default.nix4
-rw-r--r--pkgs/applications/science/logic/poly/default.nix4
-rw-r--r--pkgs/applications/science/logic/prooftree/default.nix4
-rw-r--r--pkgs/applications/science/logic/spass/default.nix4
-rw-r--r--pkgs/applications/science/logic/stp/default.nix4
-rw-r--r--pkgs/applications/science/logic/tptp/default.nix4
-rw-r--r--pkgs/applications/science/logic/vampire/default.nix4
-rw-r--r--pkgs/applications/science/logic/verit/default.nix4
-rw-r--r--pkgs/applications/science/logic/why3/default.nix4
-rw-r--r--pkgs/applications/science/logic/yices/default.nix4
-rw-r--r--pkgs/applications/science/machine-learning/fasttext/default.nix4
-rw-r--r--pkgs/applications/science/machine-learning/finalfrontier/default.nix2
-rw-r--r--pkgs/applications/science/machine-learning/finalfusion-utils/default.nix2
-rw-r--r--pkgs/applications/science/machine-learning/labelimg/default.nix4
-rw-r--r--pkgs/applications/science/machine-learning/shogun/default.nix2
-rw-r--r--pkgs/applications/science/math/R/default.nix4
-rw-r--r--pkgs/applications/science/math/almonds/default.nix4
-rw-r--r--pkgs/applications/science/math/bliss/default.nix4
-rw-r--r--pkgs/applications/science/math/caffe/default.nix2
-rw-r--r--pkgs/applications/science/math/calculix/default.nix4
-rw-r--r--pkgs/applications/science/math/cemu/default.nix4
-rw-r--r--pkgs/applications/science/math/clp/default.nix4
-rw-r--r--pkgs/applications/science/math/colpack/default.nix4
-rw-r--r--pkgs/applications/science/math/cplex/default.nix4
-rw-r--r--pkgs/applications/science/math/form/default.nix4
-rw-r--r--pkgs/applications/science/math/geogebra/default.nix4
-rw-r--r--pkgs/applications/science/math/getdp/default.nix4
-rw-r--r--pkgs/applications/science/math/giac/default.nix2
-rw-r--r--pkgs/applications/science/math/ginac/default.nix4
-rw-r--r--pkgs/applications/science/math/gretl/default.nix4
-rw-r--r--pkgs/applications/science/math/gurobi/default.nix2
-rw-r--r--pkgs/applications/science/math/hmetis/default.nix4
-rw-r--r--pkgs/applications/science/math/jags/default.nix4
-rw-r--r--pkgs/applications/science/math/lp_solve/default.nix4
-rw-r--r--pkgs/applications/science/math/lrcalc/default.nix4
-rw-r--r--pkgs/applications/science/math/mathematica/default.nix4
-rw-r--r--pkgs/applications/science/math/mxnet/default.nix2
-rw-r--r--pkgs/applications/science/math/nasc/default.nix4
-rw-r--r--pkgs/applications/science/math/palp/default.nix4
-rw-r--r--pkgs/applications/science/math/pari/default.nix4
-rw-r--r--pkgs/applications/science/math/pari/gp2c.nix4
-rw-r--r--pkgs/applications/science/math/pynac/default.nix4
-rw-r--r--pkgs/applications/science/math/qalculate-gtk/default.nix4
-rw-r--r--pkgs/applications/science/math/ries/default.nix4
-rw-r--r--pkgs/applications/science/math/rofi-calc/default.nix4
-rw-r--r--pkgs/applications/science/math/sage/sage.nix4
-rw-r--r--pkgs/applications/science/math/wxmaxima/default.nix4
-rw-r--r--pkgs/applications/science/math/zegrapher/default.nix4
-rw-r--r--pkgs/applications/science/misc/convertall/default.nix4
-rw-r--r--pkgs/applications/science/misc/gephi/default.nix4
-rw-r--r--pkgs/applications/science/misc/gplates/default.nix4
-rw-r--r--pkgs/applications/science/misc/netlogo/default.nix4
-rw-r--r--pkgs/applications/science/misc/openmodelica/default.nix4
-rw-r--r--pkgs/applications/science/misc/openmvs/default.nix4
-rw-r--r--pkgs/applications/science/misc/rink/default.nix4
-rw-r--r--pkgs/applications/science/misc/root/5.nix4
-rw-r--r--pkgs/applications/science/misc/root/default.nix2
-rw-r--r--pkgs/applications/science/misc/snakemake/default.nix4
-rw-r--r--pkgs/applications/science/molecular-dynamics/dl-poly-classic/default.nix4
-rw-r--r--pkgs/applications/science/molecular-dynamics/gromacs/default.nix4
-rw-r--r--pkgs/applications/science/molecular-dynamics/lammps/default.nix4
-rw-r--r--pkgs/applications/science/molecular-dynamics/viennarna/default.nix4
-rw-r--r--pkgs/applications/science/physics/elmerfem/default.nix4
-rw-r--r--pkgs/applications/science/physics/quantomatic/default.nix4
-rw-r--r--pkgs/applications/science/physics/sherpa/default.nix4
-rw-r--r--pkgs/applications/science/physics/xfitter/default.nix4
-rw-r--r--pkgs/applications/science/programming/fdr/default.nix4
-rw-r--r--pkgs/applications/science/programming/groove/default.nix4
-rw-r--r--pkgs/applications/science/programming/plm/default.nix4
-rw-r--r--pkgs/applications/science/robotics/betaflight-configurator/default.nix4
-rw-r--r--pkgs/applications/science/robotics/mission-planner/default.nix4
-rw-r--r--pkgs/applications/science/robotics/sumorobot-manager/default.nix4
-rw-r--r--pkgs/applications/search/grepcidr/default.nix4
-rw-r--r--pkgs/applications/search/grepm/default.nix4
-rw-r--r--pkgs/applications/search/recoll/default.nix2
-rw-r--r--pkgs/applications/system/monitor/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/eterm/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/evilvte/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/germinal/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/guake/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/havoc/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/iterm2/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/kitty/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/lilyterm/default.nix2
-rw-r--r--pkgs/applications/terminal-emulators/mrxvt/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/nimmm/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/roxterm/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-autocomplete-all-the-things/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-font-size/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perl/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perls/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-resize-font/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-tabbedex/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-theme-switch/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-vtwheel/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/rxvt/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/sakura/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/stupidterm/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/terminator/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/termite/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/tilda/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/tilix/default.nix4
-rw-r--r--pkgs/applications/terminal-emulators/x3270/default.nix4
-rw-r--r--pkgs/applications/version-management/bcompare/default.nix2
-rw-r--r--pkgs/applications/version-management/blackbox/default.nix4
-rw-r--r--pkgs/applications/version-management/cvs/default.nix4
-rw-r--r--pkgs/applications/version-management/fossil/default.nix4
-rw-r--r--pkgs/applications/version-management/gerrit/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/bfg-repo-cleaner/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/bump2version/default.nix2
-rw-r--r--pkgs/applications/version-management/git-and-tools/diff-so-fancy/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/fast-export/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/ghorg/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-absorb/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-annex-metadata-gui/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-annex-remote-rclone/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-bug/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-bz/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-cola/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-crypt/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-dit/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-extras/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-fame/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-filter-repo/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-gone/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-hub/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-ignore/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-interactive-rebase-tool/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-my/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-open/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-radar/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-recent/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-remote-gcrypt/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-reparent/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-secrets/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-standup/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-subrepo/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-subset/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-test/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-trim/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-vanity-hash/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-when-merged/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/git-workspace/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/gitbatch/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/gitflow/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/gitin/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/gitstatus/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/gitui/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/grv/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/hub/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/lefthook/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/pass-git-helper/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/radicle-upstream/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/scmpuff/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/stgit/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/svn-all-fast-export/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/tig/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/topgit/default.nix4
-rw-r--r--pkgs/applications/version-management/git-and-tools/transcrypt/default.nix4
-rw-r--r--pkgs/applications/version-management/git-backup/default.nix4
-rw-r--r--pkgs/applications/version-management/git-lfs/1.nix4
-rw-r--r--pkgs/applications/version-management/git-lfs/default.nix4
-rw-r--r--pkgs/applications/version-management/git-repo/default.nix4
-rw-r--r--pkgs/applications/version-management/git-up/default.nix4
-rw-r--r--pkgs/applications/version-management/gitinspector/default.nix4
-rw-r--r--pkgs/applications/version-management/gitlab/gitaly/default.nix4
-rw-r--r--pkgs/applications/version-management/gitlab/gitlab-shell/default.nix4
-rw-r--r--pkgs/applications/version-management/gitlab/gitlab-workhorse/default.nix4
-rw-r--r--pkgs/applications/version-management/gitless/default.nix4
-rw-r--r--pkgs/applications/version-management/gitolite/default.nix2
-rw-r--r--pkgs/applications/version-management/gitoxide/default.nix4
-rw-r--r--pkgs/applications/version-management/gitstats/default.nix4
-rw-r--r--pkgs/applications/version-management/gource/default.nix4
-rw-r--r--pkgs/applications/version-management/meld/default.nix4
-rw-r--r--pkgs/applications/version-management/monotone/default.nix4
-rw-r--r--pkgs/applications/version-management/peru/default.nix4
-rw-r--r--pkgs/applications/version-management/pijul/default.nix4
-rw-r--r--pkgs/applications/version-management/redmine/default.nix4
-rw-r--r--pkgs/applications/version-management/sit/default.nix4
-rw-r--r--pkgs/applications/version-management/smartgithg/default.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/builds.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/core.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/dispatch.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/git.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/hg.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/hub.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/lists.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/man.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/meta.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/paste.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/scm.nix4
-rw-r--r--pkgs/applications/version-management/sourcehut/todo.nix4
-rw-r--r--pkgs/applications/version-management/src/default.nix4
-rw-r--r--pkgs/applications/version-management/sublime-merge/common.nix4
-rw-r--r--pkgs/applications/version-management/subversion/default.nix4
-rw-r--r--pkgs/applications/version-management/vcprompt/default.nix4
-rw-r--r--pkgs/applications/version-management/vcsh/default.nix4
-rw-r--r--pkgs/applications/video/avidemux/default.nix2
-rw-r--r--pkgs/applications/video/avxsynth/default.nix4
-rw-r--r--pkgs/applications/video/bombono/default.nix4
-rw-r--r--pkgs/applications/video/byzanz/default.nix4
-rw-r--r--pkgs/applications/video/celluloid/default.nix4
-rw-r--r--pkgs/applications/video/clipgrab/default.nix4
-rw-r--r--pkgs/applications/video/devede/default.nix4
-rw-r--r--pkgs/applications/video/droidcam/default.nix4
-rw-r--r--pkgs/applications/video/dvdauthor/default.nix4
-rw-r--r--pkgs/applications/video/dvdstyler/default.nix4
-rw-r--r--pkgs/applications/video/electronplayer/electronplayer.nix4
-rw-r--r--pkgs/applications/video/filebot/default.nix4
-rw-r--r--pkgs/applications/video/gnome-mplayer/default.nix4
-rw-r--r--pkgs/applications/video/gpac/default.nix4
-rw-r--r--pkgs/applications/video/handbrake/default.nix2
-rw-r--r--pkgs/applications/video/hdhomerun-config-gui/default.nix4
-rw-r--r--pkgs/applications/video/jellyfin-mpv-shim/default.nix4
-rw-r--r--pkgs/applications/video/jellyfin-mpv-shim/shader-pack.nix4
-rw-r--r--pkgs/applications/video/jftui/default.nix4
-rw-r--r--pkgs/applications/video/kazam/default.nix4
-rw-r--r--pkgs/applications/video/kodi/default.nix2
-rw-r--r--pkgs/applications/video/kodi/plugins.nix6
-rw-r--r--pkgs/applications/video/makemkv/default.nix4
-rw-r--r--pkgs/applications/video/mapmap/default.nix4
-rw-r--r--pkgs/applications/video/mediathekview/default.nix4
-rw-r--r--pkgs/applications/video/mjpg-streamer/default.nix4
-rw-r--r--pkgs/applications/video/mkclean/default.nix4
-rw-r--r--pkgs/applications/video/mkvtoolnix/default.nix4
-rw-r--r--pkgs/applications/video/motion/default.nix4
-rw-r--r--pkgs/applications/video/mpc-qt/default.nix4
-rw-r--r--pkgs/applications/video/mpv/default.nix4
-rw-r--r--pkgs/applications/video/mpv/scripts/mpris.nix4
-rw-r--r--pkgs/applications/video/mpv/scripts/simple-mpv-webui.nix4
-rw-r--r--pkgs/applications/video/mpv/scripts/sponsorblock.nix4
-rw-r--r--pkgs/applications/video/mythtv/default.nix4
-rw-r--r--pkgs/applications/video/natron/default.nix2
-rw-r--r--pkgs/applications/video/obs-studio/default.nix4
-rw-r--r--pkgs/applications/video/obs-studio/obs-ndi.nix4
-rw-r--r--pkgs/applications/video/obs-studio/wlrobs.nix2
-rw-r--r--pkgs/applications/video/olive-editor/default.nix4
-rw-r--r--pkgs/applications/video/openshot-qt/default.nix4
-rw-r--r--pkgs/applications/video/peek/default.nix4
-rw-r--r--pkgs/applications/video/pitivi/default.nix4
-rw-r--r--pkgs/applications/video/plex-media-player/default.nix4
-rw-r--r--pkgs/applications/video/plex-mpv-shim/default.nix4
-rw-r--r--pkgs/applications/video/pyca/default.nix4
-rw-r--r--pkgs/applications/video/qmediathekview/default.nix4
-rw-r--r--pkgs/applications/video/qmplay2/default.nix4
-rw-r--r--pkgs/applications/video/qstopmotion/default.nix4
-rw-r--r--pkgs/applications/video/shotcut/default.nix4
-rw-r--r--pkgs/applications/video/simplescreenrecorder/default.nix4
-rw-r--r--pkgs/applications/video/streamlink-twitch-gui/bin.nix2
-rw-r--r--pkgs/applications/video/tivodecode/default.nix4
-rw-r--r--pkgs/applications/video/uvccapture/default.nix4
-rw-r--r--pkgs/applications/video/vdr/plugins.nix16
-rw-r--r--pkgs/applications/video/vlc/default.nix4
-rw-r--r--pkgs/applications/video/vokoscreen/default.nix4
-rw-r--r--pkgs/applications/video/webtorrent_desktop/default.nix4
-rw-r--r--pkgs/applications/video/wf-recorder/default.nix4
-rw-r--r--pkgs/applications/video/wxcam/default.nix4
-rw-r--r--pkgs/applications/video/xine-ui/default.nix4
-rw-r--r--pkgs/applications/video/xscast/default.nix4
-rw-r--r--pkgs/applications/video/xvidcap/default.nix4
-rw-r--r--pkgs/applications/virtualization/8086tiny/default.nix4
-rw-r--r--pkgs/applications/virtualization/aqemu/default.nix4
-rw-r--r--pkgs/applications/virtualization/cntr/default.nix4
-rw-r--r--pkgs/applications/virtualization/conmon/default.nix4
-rw-r--r--pkgs/applications/virtualization/cri-o/default.nix4
-rw-r--r--pkgs/applications/virtualization/docker-compose/default.nix4
-rw-r--r--pkgs/applications/virtualization/docker-slim/default.nix4
-rw-r--r--pkgs/applications/virtualization/docker/distribution.nix4
-rw-r--r--pkgs/applications/virtualization/docker/proxy.nix4
-rw-r--r--pkgs/applications/virtualization/driver/win-pvdrivers/default.nix4
-rw-r--r--pkgs/applications/virtualization/driver/win-qemu/default.nix4
-rw-r--r--pkgs/applications/virtualization/driver/win-signed-gplpv-drivers/default.nix4
-rw-r--r--pkgs/applications/virtualization/driver/win-spice/default.nix4
-rw-r--r--pkgs/applications/virtualization/driver/win-virtio/default.nix4
-rw-r--r--pkgs/applications/virtualization/dumb-init/default.nix4
-rw-r--r--pkgs/applications/virtualization/dynamips/default.nix4
-rw-r--r--pkgs/applications/virtualization/ecs-agent/default.nix4
-rw-r--r--pkgs/applications/virtualization/firecracker/default.nix4
-rw-r--r--pkgs/applications/virtualization/firectl/default.nix4
-rw-r--r--pkgs/applications/virtualization/gvisor/default.nix4
-rw-r--r--pkgs/applications/virtualization/hercules/default.nix4
-rw-r--r--pkgs/applications/virtualization/lkl/default.nix4
-rw-r--r--pkgs/applications/virtualization/looking-glass-client/default.nix4
-rw-r--r--pkgs/applications/virtualization/open-vm-tools/default.nix2
-rw-r--r--pkgs/applications/virtualization/podman/default.nix4
-rw-r--r--pkgs/applications/virtualization/qemu/default.nix8
-rw-r--r--pkgs/applications/virtualization/qtemu/default.nix4
-rw-r--r--pkgs/applications/virtualization/remotebox/default.nix4
-rw-r--r--pkgs/applications/virtualization/seabios/default.nix4
-rw-r--r--pkgs/applications/virtualization/singularity/default.nix2
-rw-r--r--pkgs/applications/virtualization/spike/default.nix4
-rw-r--r--pkgs/applications/virtualization/tini/default.nix4
-rw-r--r--pkgs/applications/virtualization/virt-manager/default.nix4
-rw-r--r--pkgs/applications/virtualization/virt-top/default.nix4
-rw-r--r--pkgs/applications/virtualization/vpcs/default.nix4
-rw-r--r--pkgs/applications/window-managers/2bwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/afterstep/default.nix4
-rw-r--r--pkgs/applications/window-managers/awesome/default.nix4
-rw-r--r--pkgs/applications/window-managers/berry/default.nix4
-rw-r--r--pkgs/applications/window-managers/bevelbar/default.nix4
-rw-r--r--pkgs/applications/window-managers/bspwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/btops/default.nix4
-rw-r--r--pkgs/applications/window-managers/cage/default.nix4
-rw-r--r--pkgs/applications/window-managers/cagebreak/default.nix4
-rw-r--r--pkgs/applications/window-managers/clfswm/default.nix4
-rw-r--r--pkgs/applications/window-managers/cwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/dwm/dwm-status.nix2
-rw-r--r--pkgs/applications/window-managers/dwm/git.nix4
-rw-r--r--pkgs/applications/window-managers/evilwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/fbpanel/default.nix4
-rw-r--r--pkgs/applications/window-managers/hikari/default.nix4
-rw-r--r--pkgs/applications/window-managers/i3/blocks-gaps.nix4
-rw-r--r--pkgs/applications/window-managers/i3/default.nix4
-rw-r--r--pkgs/applications/window-managers/i3/easyfocus.nix4
-rw-r--r--pkgs/applications/window-managers/i3/gaps.nix4
-rw-r--r--pkgs/applications/window-managers/i3/i3ipc-glib.nix4
-rw-r--r--pkgs/applications/window-managers/i3/layout-manager.nix4
-rw-r--r--pkgs/applications/window-managers/i3/lock-color.nix4
-rw-r--r--pkgs/applications/window-managers/i3/lock-fancy-rapid.nix4
-rw-r--r--pkgs/applications/window-managers/i3/lock-fancy.nix4
-rw-r--r--pkgs/applications/window-managers/i3/lock.nix4
-rw-r--r--pkgs/applications/window-managers/i3/pystatus.nix4
-rw-r--r--pkgs/applications/window-managers/i3/status-rust.nix4
-rw-r--r--pkgs/applications/window-managers/i3/wk-switch.nix4
-rw-r--r--pkgs/applications/window-managers/i3/wmfocus.nix4
-rw-r--r--pkgs/applications/window-managers/icewm/default.nix4
-rw-r--r--pkgs/applications/window-managers/jwm/jwm-settings-manager.nix4
-rw-r--r--pkgs/applications/window-managers/leftwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/lemonbar/default.nix4
-rw-r--r--pkgs/applications/window-managers/lwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/neocomp/default.nix4
-rw-r--r--pkgs/applications/window-managers/notion/default.nix4
-rw-r--r--pkgs/applications/window-managers/pekwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/qtile/default.nix4
-rw-r--r--pkgs/applications/window-managers/ratpoison/default.nix4
-rw-r--r--pkgs/applications/window-managers/sawfish/default.nix4
-rw-r--r--pkgs/applications/window-managers/spectrwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/stalonetray/default.nix4
-rw-r--r--pkgs/applications/window-managers/stumpish/default.nix4
-rw-r--r--pkgs/applications/window-managers/stumpwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/sway/bg.nix4
-rw-r--r--pkgs/applications/window-managers/sway/contrib.nix4
-rw-r--r--pkgs/applications/window-managers/sway/default.nix4
-rw-r--r--pkgs/applications/window-managers/sway/idle.nix4
-rw-r--r--pkgs/applications/window-managers/sway/lock-effects.nix4
-rw-r--r--pkgs/applications/window-managers/sway/lock-fancy.nix4
-rw-r--r--pkgs/applications/window-managers/sway/lock.nix4
-rw-r--r--pkgs/applications/window-managers/sxhkd/default.nix4
-rw-r--r--pkgs/applications/window-managers/trayer/default.nix4
-rw-r--r--pkgs/applications/window-managers/vwm/default.nix4
-rw-r--r--pkgs/applications/window-managers/windowchef/default.nix4
-rw-r--r--pkgs/applications/window-managers/windowmaker/default.nix4
-rw-r--r--pkgs/applications/window-managers/windowmaker/dockapps/AlsaMixer-app.nix4
-rw-r--r--pkgs/applications/window-managers/windowmaker/dockapps/libdockapp.nix4
-rw-r--r--pkgs/applications/window-managers/windowmaker/dockapps/wmCalClock.nix4
-rw-r--r--pkgs/applications/window-managers/windowmaker/dockapps/wmsm-app.nix4
-rw-r--r--pkgs/applications/window-managers/windowmaker/dockapps/wmsystemtray.nix4
-rw-r--r--pkgs/applications/window-managers/wio/default.nix4
-rw-r--r--pkgs/applications/window-managers/wmfs/default.nix4
-rw-r--r--pkgs/applications/window-managers/xmonad/log-applet/default.nix4
-rw-r--r--pkgs/applications/window-managers/yabar/build.nix2
-rw-r--r--pkgs/build-support/build-fhs-userenv/chrootenv/default.nix4
-rw-r--r--pkgs/build-support/templaterpm/default.nix4
-rw-r--r--pkgs/data/documentation/anarchism/default.nix4
-rw-r--r--pkgs/data/documentation/gnome-user-docs/default.nix4
-rw-r--r--pkgs/data/documentation/man-pages/default.nix4
-rw-r--r--pkgs/data/documentation/scheme-manpages/default.nix4
-rw-r--r--pkgs/data/documentation/stdman/default.nix4
-rw-r--r--pkgs/data/documentation/zeal/default.nix4
-rw-r--r--pkgs/data/fonts/alegreya-sans/default.nix4
-rw-r--r--pkgs/data/fonts/alegreya/default.nix4
-rw-r--r--pkgs/data/fonts/cherry/default.nix4
-rw-r--r--pkgs/data/fonts/clearlyU/default.nix4
-rw-r--r--pkgs/data/fonts/comic-neue/default.nix4
-rw-r--r--pkgs/data/fonts/corefonts/default.nix4
-rw-r--r--pkgs/data/fonts/creep/default.nix4
-rw-r--r--pkgs/data/fonts/dina/default.nix4
-rw-r--r--pkgs/data/fonts/emojione/default.nix4
-rw-r--r--pkgs/data/fonts/envypn-font/default.nix4
-rw-r--r--pkgs/data/fonts/et-book/default.nix4
-rw-r--r--pkgs/data/fonts/fira-code/default.nix4
-rw-r--r--pkgs/data/fonts/fira-code/symbols.nix4
-rw-r--r--pkgs/data/fonts/fira-mono/default.nix4
-rw-r--r--pkgs/data/fonts/go-font/default.nix4
-rw-r--r--pkgs/data/fonts/gohufont/default.nix4
-rw-r--r--pkgs/data/fonts/google-fonts/default.nix4
-rw-r--r--pkgs/data/fonts/gubbi/default.nix4
-rw-r--r--pkgs/data/fonts/inconsolata/default.nix4
-rw-r--r--pkgs/data/fonts/inconsolata/lgc.nix4
-rw-r--r--pkgs/data/fonts/input-fonts/default.nix4
-rw-r--r--pkgs/data/fonts/iosevka/default.nix2
-rw-r--r--pkgs/data/fonts/jost/default.nix4
-rw-r--r--pkgs/data/fonts/joypixels/default.nix4
-rw-r--r--pkgs/data/fonts/kanji-stroke-order-font/default.nix4
-rw-r--r--pkgs/data/fonts/liberation-fonts/default.nix4
-rw-r--r--pkgs/data/fonts/liberation-sans-narrow/default.nix4
-rw-r--r--pkgs/data/fonts/libertine/default.nix4
-rw-r--r--pkgs/data/fonts/libre-caslon/default.nix4
-rw-r--r--pkgs/data/fonts/lobster-two/default.nix4
-rw-r--r--pkgs/data/fonts/meslo-lgs-nf/default.nix4
-rw-r--r--pkgs/data/fonts/migmix/default.nix4
-rw-r--r--pkgs/data/fonts/migu/default.nix4
-rw-r--r--pkgs/data/fonts/monoid/default.nix4
-rw-r--r--pkgs/data/fonts/nerdfonts/default.nix2
-rw-r--r--pkgs/data/fonts/noto-fonts/default.nix2
-rw-r--r--pkgs/data/fonts/paratype-pt/mono.nix4
-rw-r--r--pkgs/data/fonts/paratype-pt/sans.nix4
-rw-r--r--pkgs/data/fonts/paratype-pt/serif.nix4
-rw-r--r--pkgs/data/fonts/profont/default.nix4
-rw-r--r--pkgs/data/fonts/proggyfonts/default.nix4
-rw-r--r--pkgs/data/fonts/ricty/default.nix4
-rw-r--r--pkgs/data/fonts/rictydiminished-with-firacode/default.nix4
-rw-r--r--pkgs/data/fonts/roboto-mono/default.nix4
-rw-r--r--pkgs/data/fonts/roboto-slab/default.nix4
-rw-r--r--pkgs/data/fonts/siji/default.nix4
-rw-r--r--pkgs/data/fonts/tamsyn/default.nix4
-rw-r--r--pkgs/data/fonts/tamzen/default.nix4
-rw-r--r--pkgs/data/fonts/terminus-font/default.nix4
-rw-r--r--pkgs/data/fonts/tewi/default.nix4
-rw-r--r--pkgs/data/fonts/tex-gyre-math/default.nix4
-rw-r--r--pkgs/data/fonts/tex-gyre/default.nix4
-rw-r--r--pkgs/data/fonts/tlwg/default.nix4
-rw-r--r--pkgs/data/fonts/ttf-tw-moe/default.nix4
-rw-r--r--pkgs/data/fonts/twemoji-color-font/default.nix4
-rw-r--r--pkgs/data/fonts/twitter-color-emoji/default.nix4
-rw-r--r--pkgs/data/fonts/ucs-fonts/default.nix4
-rw-r--r--pkgs/data/fonts/unifont/default.nix4
-rw-r--r--pkgs/data/fonts/uw-ttyp0/default.nix4
-rw-r--r--pkgs/data/fonts/xits-math/default.nix4
-rw-r--r--pkgs/data/icons/arc-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/capitaine-cursors/default.nix4
-rw-r--r--pkgs/data/icons/elementary-xfce-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/faba-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/faba-mono-icons/default.nix4
-rw-r--r--pkgs/data/icons/flat-remix-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/gnome-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/hicolor-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/humanity-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/iconpack-jade/default.nix4
-rw-r--r--pkgs/data/icons/iconpack-obsidian/default.nix4
-rw-r--r--pkgs/data/icons/iso-flags/default.nix4
-rw-r--r--pkgs/data/icons/kora-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/luna-icons/default.nix4
-rw-r--r--pkgs/data/icons/maia-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/moka-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/numix-cursor-theme/default.nix4
-rw-r--r--pkgs/data/icons/numix-icon-theme-circle/default.nix4
-rw-r--r--pkgs/data/icons/numix-icon-theme-square/default.nix4
-rw-r--r--pkgs/data/icons/numix-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/paper-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/papirus-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/papirus-maia-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/pop-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/qogir-icon-theme/default.nix4
-rw-r--r--pkgs/data/icons/zafiro-icons/default.nix4
-rw-r--r--pkgs/data/misc/adapta-backgrounds/default.nix4
-rw-r--r--pkgs/data/misc/brise/default.nix4
-rw-r--r--pkgs/data/misc/cldr-emoji-annotation/default.nix4
-rw-r--r--pkgs/data/misc/combinatorial_designs/default.nix4
-rw-r--r--pkgs/data/misc/conway_polynomials/default.nix4
-rw-r--r--pkgs/data/misc/ddccontrol-db/default.nix4
-rw-r--r--pkgs/data/misc/elliptic_curves/default.nix4
-rw-r--r--pkgs/data/misc/freepats/default.nix4
-rw-r--r--pkgs/data/misc/geolite-legacy/default.nix4
-rw-r--r--pkgs/data/misc/graphs/default.nix4
-rw-r--r--pkgs/data/misc/iana-etc/default.nix4
-rw-r--r--pkgs/data/misc/libkkc-data/default.nix4
-rw-r--r--pkgs/data/misc/media-player-info/default.nix4
-rw-r--r--pkgs/data/misc/mime-types/default.nix4
-rw-r--r--pkgs/data/misc/miscfiles/default.nix4
-rw-r--r--pkgs/data/misc/mobile-broadband-provider-info/default.nix4
-rw-r--r--pkgs/data/misc/nixos-artwork/wallpapers.nix4
-rw-r--r--pkgs/data/misc/osinfo-db/default.nix4
-rw-r--r--pkgs/data/misc/pari-galdata/default.nix4
-rw-r--r--pkgs/data/misc/pari-seadata-small/default.nix4
-rw-r--r--pkgs/data/misc/polytopes_db/default.nix4
-rw-r--r--pkgs/data/misc/poppler-data/default.nix4
-rw-r--r--pkgs/data/misc/shared-desktop-ontologies/default.nix4
-rw-r--r--pkgs/data/misc/shared-mime-info/default.nix4
-rw-r--r--pkgs/data/misc/sound-theme-freedesktop/default.nix4
-rw-r--r--pkgs/data/misc/tzdata/default.nix4
-rw-r--r--pkgs/data/misc/unicode-character-database/default.nix4
-rw-r--r--pkgs/data/misc/unicode-emoji/default.nix2
-rw-r--r--pkgs/data/misc/unihan-database/default.nix4
-rw-r--r--pkgs/data/misc/wireless-regdb/default.nix4
-rw-r--r--pkgs/data/soundfonts/fluid/default.nix4
-rw-r--r--pkgs/data/themes/adapta/default.nix4
-rw-r--r--pkgs/data/themes/adementary/default.nix4
-rw-r--r--pkgs/data/themes/amber/default.nix4
-rw-r--r--pkgs/data/themes/ant-theme/ant-bloody.nix4
-rw-r--r--pkgs/data/themes/ant-theme/ant-nebula.nix4
-rw-r--r--pkgs/data/themes/ant-theme/ant.nix4
-rw-r--r--pkgs/data/themes/arc/default.nix4
-rw-r--r--pkgs/data/themes/canta/default.nix4
-rw-r--r--pkgs/data/themes/cdetheme/default.nix4
-rw-r--r--pkgs/data/themes/clearlooks-phenix/default.nix4
-rw-r--r--pkgs/data/themes/dracula-theme/default.nix4
-rw-r--r--pkgs/data/themes/equilux-theme/default.nix4
-rw-r--r--pkgs/data/themes/greybird/default.nix4
-rw-r--r--pkgs/data/themes/jade1/default.nix4
-rw-r--r--pkgs/data/themes/lounge/default.nix4
-rw-r--r--pkgs/data/themes/marwaita-manjaro/default.nix4
-rw-r--r--pkgs/data/themes/marwaita-peppermint/default.nix4
-rw-r--r--pkgs/data/themes/marwaita-pop_os/default.nix4
-rw-r--r--pkgs/data/themes/marwaita-ubuntu/default.nix4
-rw-r--r--pkgs/data/themes/marwaita/default.nix4
-rw-r--r--pkgs/data/themes/matcha/default.nix4
-rw-r--r--pkgs/data/themes/materia-theme/default.nix4
-rw-r--r--pkgs/data/themes/mojave/default.nix4
-rw-r--r--pkgs/data/themes/nordic-polar/default.nix4
-rw-r--r--pkgs/data/themes/nordic/default.nix4
-rw-r--r--pkgs/data/themes/numix-solarized/default.nix4
-rw-r--r--pkgs/data/themes/obsidian2/default.nix4
-rw-r--r--pkgs/data/themes/onestepback/default.nix4
-rw-r--r--pkgs/data/themes/paper-gtk/default.nix4
-rw-r--r--pkgs/data/themes/plano/default.nix4
-rw-r--r--pkgs/data/themes/plata/default.nix4
-rw-r--r--pkgs/data/themes/pop-gtk/default.nix4
-rw-r--r--pkgs/data/themes/qogir/default.nix4
-rw-r--r--pkgs/data/themes/shades-of-gray/default.nix4
-rw-r--r--pkgs/data/themes/sierra/default.nix4
-rw-r--r--pkgs/data/themes/skeu/default.nix4
-rw-r--r--pkgs/data/themes/snowblind/default.nix4
-rw-r--r--pkgs/data/themes/solarc/default.nix4
-rw-r--r--pkgs/data/themes/stilo/default.nix4
-rw-r--r--pkgs/data/themes/sweet/default.nix4
-rw-r--r--pkgs/data/themes/ubuntu-themes/default.nix4
-rw-r--r--pkgs/data/themes/venta/default.nix4
-rw-r--r--pkgs/data/themes/vertex/default.nix4
-rw-r--r--pkgs/data/themes/vimix/default.nix4
-rw-r--r--pkgs/data/themes/yaru/default.nix4
-rw-r--r--pkgs/data/themes/zuki/default.nix4
-rw-r--r--pkgs/desktops/cdesktopenv/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-common/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-common/libcroco.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-control-center/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-desktop/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-menus/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-screensaver/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-session/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-settings-daemon/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cinnamon-translations/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/cjs/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/mint-themes/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/mint-x-icons/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/mint-y-icons/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/muffin/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/nemo/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/warpinator/default.nix4
-rw-r--r--pkgs/desktops/cinnamon/xapps/default.nix4
-rw-r--r--pkgs/desktops/enlightenment/efl/default.nix4
-rw-r--r--pkgs/desktops/enlightenment/enlightenment/default.nix4
-rw-r--r--pkgs/desktops/enlightenment/evisum/default.nix4
-rw-r--r--pkgs/desktops/gnome-2/bindings/gnome-python-desktop/default.nix4
-rw-r--r--pkgs/desktops/gnome-2/bindings/gnome-python/default.nix4
-rw-r--r--pkgs/desktops/gnome-2/desktop/mail-notification/default.nix4
-rw-r--r--pkgs/desktops/gnome-2/platform/GConf/default.nix4
-rw-r--r--pkgs/desktops/gnome-2/platform/ORBit2/default.nix4
-rw-r--r--pkgs/desktops/gnome-2/platform/gtkglext/default.nix4
-rw-r--r--pkgs/desktops/gnome-2/platform/libgnomeprint/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/accerciser/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/cheese/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/evolution/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/file-roller/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gedit/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/ghex/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-books/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-boxes/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-calendar/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-characters/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-clocks/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-connections/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-documents/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-getting-started-docs/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-logs/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-maps/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-music/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-nettool/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-notes/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-power-manager/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-sound-recorder/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-todo/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/gnome-weather/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/polari/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/seahorse/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/apps/vinagre/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/adwaita-icon-theme/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/baobab/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/caribou/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/dconf-editor/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/empathy/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/eog/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/epiphany/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/evince/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/evolution-data-server/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gdm/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-backgrounds/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-bluetooth/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-calculator/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-color-manager/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-common/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-contacts/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-control-center/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-desktop/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-dictionary/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-disk-utility/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-font-viewer/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-initial-setup/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-keyring/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-online-miners/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-remote-desktop/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-screenshot/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-session/ctl.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-session/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-settings-daemon/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-shell-extensions/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-shell/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-software/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-system-monitor/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-terminal/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-themes-extra/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-tour/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gnome-user-share/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/gucharmap/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/mutter/3.34/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/mutter/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/nautilus/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/rygel/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/simple-scan/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/sushi/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/totem/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/yelp-xsl/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/yelp/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/core/zenity/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/devtools/anjuta/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/devtools/devhelp/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/devtools/gnome-devel-docs/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/EasyScreenCast/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/appindicator/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/arc-menu/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/caffeine/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/chrome-gnome-shell/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/clipboard-indicator/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/dash-to-dock/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/dash-to-panel/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/draw-on-your-screen/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/drop-down-terminal/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/emoji-selector/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/freon/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/gsconnect/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/icon-hider/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/impatience/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/material-shell/default.nix2
-rw-r--r--pkgs/desktops/gnome-3/extensions/mpris-indicator-button/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/night-theme-switcher/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/no-title-bar/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/paperwm/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/pidgin-im-integration/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/remove-dropdown-arrows/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/sound-output-device-chooser/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/system-monitor/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/taskwhisperer/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/tilingnome/default.nix2
-rw-r--r--pkgs/desktops/gnome-3/extensions/timepp/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/topicons-plus/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/window-corner-preview/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/window-is-ready-remover/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/extensions/workspace-matrix/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/aisleriot/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/atomix/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/five-or-more/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/four-in-a-row/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-chess/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-klotski/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-mahjongg/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-mines/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-nibbles/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-robots/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-sudoku/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-taquin/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/gnome-tetravex/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/hitori/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/iagno/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/lightsoff/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/quadrapassel/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/swell-foop/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/games/tali/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/geary/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gitg/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gnome-applets/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gnome-autoar/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gnome-flashback/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gnome-packagekit/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gnome-panel/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gpaste/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/gtkhtml/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/libgnome-games-support/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/metacity/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/nautilus-python/default.nix4
-rw-r--r--pkgs/desktops/gnome-3/misc/pomodoro/default.nix4
-rw-r--r--pkgs/desktops/lumina/lumina-calculator/default.nix4
-rw-r--r--pkgs/desktops/lumina/lumina-pdf/default.nix4
-rw-r--r--pkgs/desktops/lumina/lumina/default.nix4
-rw-r--r--pkgs/desktops/lxde/core/lxappearance/default.nix4
-rw-r--r--pkgs/desktops/lxde/core/lxrandr/default.nix4
-rw-r--r--pkgs/desktops/mate/atril/default.nix4
-rw-r--r--pkgs/desktops/mate/caja-dropbox/default.nix4
-rw-r--r--pkgs/desktops/mate/caja-extensions/default.nix4
-rw-r--r--pkgs/desktops/mate/libmatekbd/default.nix4
-rw-r--r--pkgs/desktops/mate/libmatemixer/default.nix4
-rw-r--r--pkgs/desktops/mate/libmateweather/default.nix4
-rw-r--r--pkgs/desktops/mate/marco/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-applets/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-backgrounds/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-calc/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-control-center/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-desktop/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-indicator-applet/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-media/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-menus/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-netbook/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-notification-daemon/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-panel/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-polkit/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-power-manager/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-screensaver/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-sensors-applet/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-session-manager/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-settings-daemon/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-system-monitor/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-terminal/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-tweak/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-user-guide/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-user-share/default.nix4
-rw-r--r--pkgs/desktops/mate/mate-utils/default.nix4
-rw-r--r--pkgs/desktops/mate/mozo/default.nix4
-rw-r--r--pkgs/desktops/mate/python-caja/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/appcenter/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-calculator/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-calendar/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-camera/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-code/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-dock/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-feedback/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-files/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-music/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-screenshot-tool/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-terminal/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/elementary-videos/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/sideload/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/a11y/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/about/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/applications/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/bluetooth/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/datetime/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/display/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/keyboard/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/mouse-touchpad/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/network/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/notifications/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/onlineaccounts/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/pantheon-shell/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/power/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/printers/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/security-privacy/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/sharing/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard-plugs/sound/default.nix4
-rw-r--r--pkgs/desktops/pantheon/apps/switchboard/default.nix4
-rw-r--r--pkgs/desktops/pantheon/artwork/elementary-gtk-theme/default.nix4
-rw-r--r--pkgs/desktops/pantheon/artwork/elementary-icon-theme/default.nix4
-rw-r--r--pkgs/desktops/pantheon/artwork/elementary-redacted-script/default.nix4
-rw-r--r--pkgs/desktops/pantheon/artwork/elementary-sound-theme/default.nix4
-rw-r--r--pkgs/desktops/pantheon/artwork/elementary-wallpapers/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/elementary-default-settings/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/elementary-greeter/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/elementary-onboarding/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/elementary-print-shim/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/elementary-session-settings/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/elementary-shortcut-overlay/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/extra-elementary-contracts/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/applications-menu/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/bluetooth/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/datetime/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/keyboard/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/network/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/nightlight/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/notifications/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/power/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/session/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel-indicators/sound/default.nix4
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel/default.nix4
-rw-r--r--pkgs/desktops/pantheon/granite/default.nix4
-rw-r--r--pkgs/desktops/pantheon/services/contractor/default.nix4
-rw-r--r--pkgs/desktops/pantheon/services/elementary-capnet-assist/default.nix4
-rw-r--r--pkgs/desktops/pantheon/services/elementary-dpms-helper/default.nix4
-rw-r--r--pkgs/desktops/pantheon/services/elementary-notifications/default.nix4
-rw-r--r--pkgs/desktops/pantheon/services/elementary-settings-daemon/default.nix4
-rw-r--r--pkgs/desktops/pantheon/services/pantheon-agent-geoclue2/default.nix4
-rw-r--r--pkgs/desktops/pantheon/services/pantheon-agent-polkit/default.nix4
-rw-r--r--pkgs/desktops/rox/rox-filer/default.nix4
-rw-r--r--pkgs/desktops/surf-display/default.nix4
-rw-r--r--pkgs/desktops/xfce/applications/catfish/default.nix4
-rw-r--r--pkgs/desktops/xfce/applications/orage/default.nix4
-rw-r--r--pkgs/desktops/xfce/art/xfce4-icon-theme.nix4
-rw-r--r--pkgs/desktops/xfce/art/xfwm4-themes.nix4
-rw-r--r--pkgs/desktops/xfce/mkXfceDerivation.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-namebar-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/appmenu-gtk-module.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix4
-rw-r--r--pkgs/desktops/xfce/thunar-plugins/archive/default.nix4
-rw-r--r--pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix4
-rw-r--r--pkgs/development/arduino/arduino-ci/default.nix4
-rw-r--r--pkgs/development/arduino/arduino-cli/default.nix4
-rw-r--r--pkgs/development/arduino/arduino-core/default.nix2
-rw-r--r--pkgs/development/arduino/platformio/core.nix2
-rw-r--r--pkgs/development/dotnet-modules/python-language-server/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-cairo/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-fibers/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-gnome/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-lib/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-ncurses/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-opengl/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-reader/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-sdl/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-sdl2/default.nix4
-rw-r--r--pkgs/development/guile-modules/guile-xcb/default.nix4
-rw-r--r--pkgs/development/java-modules/jogl/default.nix4
-rw-r--r--pkgs/development/java-modules/postgresql_jdbc/default.nix4
-rw-r--r--pkgs/development/lua-modules/generated-packages.nix172
-rw-r--r--pkgs/development/misc/avr/libc/default.nix4
-rw-r--r--pkgs/development/misc/avr8-burn-omat/default.nix4
-rw-r--r--pkgs/development/misc/h3/default.nix4
-rw-r--r--pkgs/development/misc/loc/default.nix4
-rw-r--r--pkgs/development/misc/msp430/mspdebug.nix4
-rw-r--r--pkgs/development/misc/rappel/default.nix4
-rw-r--r--pkgs/development/misc/resholve/resholve.nix4
-rw-r--r--pkgs/development/misc/rpiboot/unstable.nix4
-rw-r--r--pkgs/development/misc/stm32/betaflight/default.nix4
-rw-r--r--pkgs/development/misc/stm32/inav/default.nix4
-rw-r--r--pkgs/development/misc/yelp-tools/default.nix4
-rw-r--r--pkgs/development/mobile/abootimg/default.nix4
-rw-r--r--pkgs/development/mobile/adb-sync/default.nix4
-rw-r--r--pkgs/development/mobile/adbfs-rootless/default.nix4
-rw-r--r--pkgs/development/mobile/imgpatchtools/default.nix4
-rw-r--r--pkgs/development/mobile/webos/cmake-modules.nix4
-rw-r--r--pkgs/development/mobile/webos/novacom.nix4
-rw-r--r--pkgs/development/mobile/webos/novacomd.nix4
-rw-r--r--pkgs/development/mobile/xpwn/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/afl-persistent/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/ansiterminal/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/atd/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/bap/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/bin_prot/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/biniou/1.0.nix4
-rw-r--r--pkgs/development/ocaml-modules/biocaml/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/bolt/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/camlimages/4.0.nix4
-rw-r--r--pkgs/development/ocaml-modules/camlpdf/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/camlzip/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/cfstream/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/cil/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/cmdliner/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/comparelib/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/cpdf/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/cpu/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/crowbar/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/cstruct/1.9.0.nix4
-rw-r--r--pkgs/development/ocaml-modules/csv/1.5.nix4
-rw-r--r--pkgs/development/ocaml-modules/ctypes/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/curses/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/dtoa/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/dum/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/easy-format/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/eigen/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/estring/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/ezxmlm/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/faillib/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/fieldslib/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/fix/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/fmt/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/functory/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/gg/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/gsl/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/herelib/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/higlo/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/http/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/async-rpc-kernel.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/bin_prot.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/core_bench.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/fieldslib.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/js-build-tools.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-assert.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-bench.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-bin-prot.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-compare.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-custom-printf.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-enumerate.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-expect.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-fields-conv.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-here.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-inline-test.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-jane.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-let.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-optcomp.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-pipebang.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-sexp-conv.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-sexp-message.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-sexp-value.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-typerep-conv.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/ppx-variants-conv.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/sexplib.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/typerep.nix4
-rw-r--r--pkgs/development/ocaml-modules/janestreet/variantslib.nix4
-rw-r--r--pkgs/development/ocaml-modules/javalib/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/kafka/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/lablgl/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/lablgtk/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/lacaml/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/logs/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/macaque/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/menhir/default.nix2
-rw-r--r--pkgs/development/ocaml-modules/menhir/generic.nix4
-rw-r--r--pkgs/development/ocaml-modules/ocaml-libvirt/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/ocaml-syntax-shims/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/ocf/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/odn/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/opti/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/otfm/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/pa_bench/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/pa_ounit/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/parany/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/pcre/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/phylogenetics/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/pipebang/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/piqi-ocaml/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/piqi/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/pprint/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/ppx_gen_rec/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/ppx_tools/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/react/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/reactivedata/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/sawja/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/secp256k1/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/sodium/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/sqlite3EZ/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/syslog/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/tsdl/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/twt/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/type_conv/108.08.00.nix4
-rw-r--r--pkgs/development/ocaml-modules/typerep/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/uucd/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/uucp/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/uuidm/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/uunf/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/uuseg/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/uutf/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/variantslib/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/wtf8/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/xmlm/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/xtmpl/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/yojson/default.nix4
-rw-r--r--pkgs/development/ocaml-modules/zarith/default.nix4
-rw-r--r--pkgs/development/perl-modules/MNI/default.nix4
-rw-r--r--pkgs/development/perl-modules/Percona-Toolkit/default.nix4
-rw-r--r--pkgs/development/perl-modules/strip-nondeterminism/default.nix4
-rw-r--r--pkgs/development/pharo/launcher/default.nix4
-rw-r--r--pkgs/development/pharo/vm/build-vm-legacy.nix4
-rw-r--r--pkgs/development/pharo/vm/build-vm.nix4
-rw-r--r--pkgs/development/pharo/vm/vms.nix1
-rw-r--r--pkgs/development/python-modules/FormEncode/default.nix4
-rw-r--r--pkgs/development/python-modules/HTSeq/default.nix4
-rw-r--r--pkgs/development/python-modules/IPy/default.nix4
-rw-r--r--pkgs/development/python-modules/PyLD/default.nix4
-rw-r--r--pkgs/development/python-modules/ROPGadget/default.nix4
-rw-r--r--pkgs/development/python-modules/Rtree/default.nix4
-rw-r--r--pkgs/development/python-modules/Theano/default.nix4
-rw-r--r--pkgs/development/python-modules/Wand/default.nix4
-rw-r--r--pkgs/development/python-modules/WazeRouteCalculator/default.nix4
-rw-r--r--pkgs/development/python-modules/aadict/default.nix4
-rw-r--r--pkgs/development/python-modules/aafigure/default.nix4
-rw-r--r--pkgs/development/python-modules/acebinf/default.nix4
-rw-r--r--pkgs/development/python-modules/acme-tiny/default.nix4
-rw-r--r--pkgs/development/python-modules/actdiag/default.nix4
-rw-r--r--pkgs/development/python-modules/adal/default.nix4
-rw-r--r--pkgs/development/python-modules/afdko/default.nix4
-rw-r--r--pkgs/development/python-modules/agate-dbf/default.nix4
-rw-r--r--pkgs/development/python-modules/agate-sql/default.nix4
-rw-r--r--pkgs/development/python-modules/aiodns/default.nix4
-rw-r--r--pkgs/development/python-modules/aioeventlet/default.nix4
-rw-r--r--pkgs/development/python-modules/aioredis/default.nix4
-rw-r--r--pkgs/development/python-modules/aiozeroconf/default.nix4
-rw-r--r--pkgs/development/python-modules/ajpy/default.nix4
-rw-r--r--pkgs/development/python-modules/alabaster/default.nix4
-rw-r--r--pkgs/development/python-modules/alarmdecoder/default.nix4
-rw-r--r--pkgs/development/python-modules/alembic/default.nix4
-rw-r--r--pkgs/development/python-modules/alerta-server/default.nix4
-rw-r--r--pkgs/development/python-modules/alerta/default.nix4
-rw-r--r--pkgs/development/python-modules/alot/default.nix2
-rw-r--r--pkgs/development/python-modules/altair/default.nix4
-rw-r--r--pkgs/development/python-modules/amazon_kclpy/default.nix4
-rw-r--r--pkgs/development/python-modules/amply/default.nix4
-rw-r--r--pkgs/development/python-modules/amqp/default.nix4
-rw-r--r--pkgs/development/python-modules/amqplib/default.nix4
-rw-r--r--pkgs/development/python-modules/aniso8601/default.nix4
-rw-r--r--pkgs/development/python-modules/annoy/default.nix4
-rw-r--r--pkgs/development/python-modules/anonip/default.nix2
-rw-r--r--pkgs/development/python-modules/ansicolor/default.nix4
-rw-r--r--pkgs/development/python-modules/ansicolors/default.nix4
-rw-r--r--pkgs/development/python-modules/ansiconv/default.nix4
-rw-r--r--pkgs/development/python-modules/apipkg/default.nix4
-rw-r--r--pkgs/development/python-modules/approvaltests/default.nix4
-rw-r--r--pkgs/development/python-modules/apsw/default.nix4
-rw-r--r--pkgs/development/python-modules/argh/default.nix4
-rw-r--r--pkgs/development/python-modules/args/default.nix4
-rw-r--r--pkgs/development/python-modules/aria2p/default.nix4
-rw-r--r--pkgs/development/python-modules/asana/default.nix4
-rw-r--r--pkgs/development/python-modules/asgi-csrf/default.nix4
-rw-r--r--pkgs/development/python-modules/asgiref/default.nix2
-rw-r--r--pkgs/development/python-modules/asn1ate/default.nix4
-rw-r--r--pkgs/development/python-modules/astral/default.nix4
-rw-r--r--pkgs/development/python-modules/astunparse/default.nix4
-rw-r--r--pkgs/development/python-modules/asyncssh/default.nix4
-rw-r--r--pkgs/development/python-modules/atomiclong/default.nix4
-rw-r--r--pkgs/development/python-modules/atomicwrites/default.nix4
-rw-r--r--pkgs/development/python-modules/atomman/default.nix4
-rw-r--r--pkgs/development/python-modules/atsim_potentials/default.nix4
-rw-r--r--pkgs/development/python-modules/attrdict/default.nix4
-rw-r--r--pkgs/development/python-modules/authlib/default.nix4
-rw-r--r--pkgs/development/python-modules/authres/default.nix4
-rw-r--r--pkgs/development/python-modules/autograd/default.nix4
-rw-r--r--pkgs/development/python-modules/autologging/default.nix4
-rw-r--r--pkgs/development/python-modules/automat/default.nix4
-rw-r--r--pkgs/development/python-modules/autopep8/default.nix4
-rw-r--r--pkgs/development/python-modules/avro/default.nix4
-rw-r--r--pkgs/development/python-modules/avro3k/default.nix4
-rw-r--r--pkgs/development/python-modules/awesome-slugify/default.nix4
-rw-r--r--pkgs/development/python-modules/b2sdk/default.nix4
-rw-r--r--pkgs/development/python-modules/babelfish/default.nix4
-rw-r--r--pkgs/development/python-modules/backports-shutil-which/default.nix4
-rw-r--r--pkgs/development/python-modules/backports_csv/default.nix4
-rw-r--r--pkgs/development/python-modules/backports_os/default.nix4
-rw-r--r--pkgs/development/python-modules/backports_unittest-mock/default.nix4
-rw-r--r--pkgs/development/python-modules/backports_weakref/default.nix4
-rw-r--r--pkgs/development/python-modules/bacpypes/default.nix4
-rw-r--r--pkgs/development/python-modules/bap/default.nix4
-rw-r--r--pkgs/development/python-modules/base58/default.nix4
-rw-r--r--pkgs/development/python-modules/basemap/default.nix4
-rw-r--r--pkgs/development/python-modules/batinfo/default.nix4
-rw-r--r--pkgs/development/python-modules/bayespy/default.nix4
-rw-r--r--pkgs/development/python-modules/bcdoc/default.nix4
-rw-r--r--pkgs/development/python-modules/beautifulsoup4/default.nix4
-rw-r--r--pkgs/development/python-modules/bedup/default.nix4
-rw-r--r--pkgs/development/python-modules/behave/default.nix4
-rw-r--r--pkgs/development/python-modules/bellows/default.nix4
-rw-r--r--pkgs/development/python-modules/bespon/default.nix4
-rw-r--r--pkgs/development/python-modules/betamax-matchers/default.nix4
-rw-r--r--pkgs/development/python-modules/betamax-serializers/default.nix4
-rw-r--r--pkgs/development/python-modules/betamax/default.nix4
-rw-r--r--pkgs/development/python-modules/billiard/default.nix4
-rw-r--r--pkgs/development/python-modules/binwalk/default.nix4
-rw-r--r--pkgs/development/python-modules/bitbucket-api/default.nix4
-rw-r--r--pkgs/development/python-modules/bitbucket-cli/default.nix4
-rw-r--r--pkgs/development/python-modules/bitmath/default.nix4
-rw-r--r--pkgs/development/python-modules/bitstring/default.nix4
-rw-r--r--pkgs/development/python-modules/bjoern/default.nix4
-rw-r--r--pkgs/development/python-modules/black-macchiato/default.nix4
-rw-r--r--pkgs/development/python-modules/bleak/default.nix4
-rw-r--r--pkgs/development/python-modules/blessed/default.nix4
-rw-r--r--pkgs/development/python-modules/blessings/default.nix4
-rw-r--r--pkgs/development/python-modules/blinker/default.nix4
-rw-r--r--pkgs/development/python-modules/blis/default.nix4
-rw-r--r--pkgs/development/python-modules/blist/default.nix4
-rw-r--r--pkgs/development/python-modules/blivet/default.nix4
-rw-r--r--pkgs/development/python-modules/block-io/default.nix4
-rw-r--r--pkgs/development/python-modules/blockdiag/default.nix4
-rw-r--r--pkgs/development/python-modules/bluepy/default.nix4
-rw-r--r--pkgs/development/python-modules/boltons/default.nix4
-rw-r--r--pkgs/development/python-modules/boltztrap2/default.nix4
-rw-r--r--pkgs/development/python-modules/bottle/default.nix4
-rw-r--r--pkgs/development/python-modules/box2d/default.nix4
-rw-r--r--pkgs/development/python-modules/bpython/default.nix4
-rw-r--r--pkgs/development/python-modules/bsddb3/default.nix4
-rw-r--r--pkgs/development/python-modules/bsdiff4/default.nix4
-rw-r--r--pkgs/development/python-modules/bt-proximity/default.nix4
-rw-r--r--pkgs/development/python-modules/btchip/default.nix4
-rw-r--r--pkgs/development/python-modules/btrees/default.nix4
-rw-r--r--pkgs/development/python-modules/btrfs/default.nix4
-rw-r--r--pkgs/development/python-modules/bugsnag/default.nix4
-rw-r--r--pkgs/development/python-modules/bugwarrior/default.nix4
-rw-r--r--pkgs/development/python-modules/bugz/default.nix4
-rw-r--r--pkgs/development/python-modules/bugzilla/default.nix4
-rw-r--r--pkgs/development/python-modules/buildout/default.nix4
-rw-r--r--pkgs/development/python-modules/bumps/default.nix4
-rw-r--r--pkgs/development/python-modules/bunch/default.nix4
-rw-r--r--pkgs/development/python-modules/bwapy/default.nix4
-rw-r--r--pkgs/development/python-modules/cachecontrol/default.nix4
-rw-r--r--pkgs/development/python-modules/cachelib/default.nix4
-rw-r--r--pkgs/development/python-modules/cachetools/default.nix4
-rw-r--r--pkgs/development/python-modules/cairosvg/1_x.nix4
-rw-r--r--pkgs/development/python-modules/cairosvg/default.nix4
-rw-r--r--pkgs/development/python-modules/canonicaljson/default.nix4
-rw-r--r--pkgs/development/python-modules/capstone/default.nix4
-rw-r--r--pkgs/development/python-modules/carbon/default.nix4
-rw-r--r--pkgs/development/python-modules/carrot/default.nix4
-rw-r--r--pkgs/development/python-modules/case/default.nix4
-rw-r--r--pkgs/development/python-modules/casttube/default.nix4
-rw-r--r--pkgs/development/python-modules/catalogue/default.nix4
-rw-r--r--pkgs/development/python-modules/cbor/default.nix4
-rw-r--r--pkgs/development/python-modules/cccolutils/default.nix4
-rw-r--r--pkgs/development/python-modules/cddb/default.nix4
-rw-r--r--pkgs/development/python-modules/cdecimal/default.nix4
-rw-r--r--pkgs/development/python-modules/cement/default.nix4
-rw-r--r--pkgs/development/python-modules/cerberus/default.nix4
-rw-r--r--pkgs/development/python-modules/certipy/default.nix4
-rw-r--r--pkgs/development/python-modules/cffi/default.nix4
-rw-r--r--pkgs/development/python-modules/cgroup-utils/default.nix4
-rw-r--r--pkgs/development/python-modules/chai/default.nix4
-rw-r--r--pkgs/development/python-modules/chainmap/default.nix4
-rw-r--r--pkgs/development/python-modules/chameleon/default.nix4
-rw-r--r--pkgs/development/python-modules/channels-redis/default.nix4
-rw-r--r--pkgs/development/python-modules/channels/default.nix4
-rw-r--r--pkgs/development/python-modules/chardet/default.nix4
-rw-r--r--pkgs/development/python-modules/check-manifest/default.nix4
-rw-r--r--pkgs/development/python-modules/cherrypy/17.nix4
-rw-r--r--pkgs/development/python-modules/cherrypy/default.nix4
-rw-r--r--pkgs/development/python-modules/cjson/default.nix4
-rw-r--r--pkgs/development/python-modules/ckcc-protocol/default.nix2
-rw-r--r--pkgs/development/python-modules/cld2-cffi/default.nix4
-rw-r--r--pkgs/development/python-modules/clf/default.nix4
-rw-r--r--pkgs/development/python-modules/cliapp/default.nix4
-rw-r--r--pkgs/development/python-modules/click-completion/default.nix4
-rw-r--r--pkgs/development/python-modules/click-didyoumean/default.nix4
-rw-r--r--pkgs/development/python-modules/click-help-colors/default.nix4
-rw-r--r--pkgs/development/python-modules/click-log/default.nix4
-rw-r--r--pkgs/development/python-modules/click-plugins/default.nix4
-rw-r--r--pkgs/development/python-modules/click-repl/default.nix4
-rw-r--r--pkgs/development/python-modules/clickclick/default.nix2
-rw-r--r--pkgs/development/python-modules/cligj/default.nix4
-rw-r--r--pkgs/development/python-modules/clint/default.nix4
-rw-r--r--pkgs/development/python-modules/clize/default.nix4
-rw-r--r--pkgs/development/python-modules/closure-linter/default.nix4
-rw-r--r--pkgs/development/python-modules/cloudpickle/default.nix4
-rw-r--r--pkgs/development/python-modules/clustershell/default.nix4
-rw-r--r--pkgs/development/python-modules/cmd2/default.nix4
-rw-r--r--pkgs/development/python-modules/cmdline/default.nix4
-rw-r--r--pkgs/development/python-modules/cmdtest/default.nix4
-rw-r--r--pkgs/development/python-modules/cocotb/default.nix4
-rw-r--r--pkgs/development/python-modules/cogapp/default.nix4
-rw-r--r--pkgs/development/python-modules/coilmq/default.nix4
-rw-r--r--pkgs/development/python-modules/colanderalchemy/default.nix4
-rw-r--r--pkgs/development/python-modules/colorama/default.nix4
-rw-r--r--pkgs/development/python-modules/colorcet/default.nix4
-rw-r--r--pkgs/development/python-modules/colorclass/default.nix4
-rw-r--r--pkgs/development/python-modules/colored/default.nix4
-rw-r--r--pkgs/development/python-modules/colorlog/default.nix4
-rw-r--r--pkgs/development/python-modules/colour/default.nix4
-rw-r--r--pkgs/development/python-modules/configobj/default.nix4
-rw-r--r--pkgs/development/python-modules/configparser/4.nix4
-rw-r--r--pkgs/development/python-modules/configparser/default.nix4
-rw-r--r--pkgs/development/python-modules/configshell/default.nix4
-rw-r--r--pkgs/development/python-modules/confluent-kafka/default.nix4
-rw-r--r--pkgs/development/python-modules/constantly/default.nix4
-rw-r--r--pkgs/development/python-modules/construct/default.nix4
-rw-r--r--pkgs/development/python-modules/consul/default.nix4
-rw-r--r--pkgs/development/python-modules/contexter/default.nix4
-rw-r--r--pkgs/development/python-modules/convertdate/default.nix4
-rw-r--r--pkgs/development/python-modules/cookiecutter/default.nix4
-rw-r--r--pkgs/development/python-modules/cookies/default.nix4
-rw-r--r--pkgs/development/python-modules/coreapi/default.nix4
-rw-r--r--pkgs/development/python-modules/coreschema/default.nix4
-rw-r--r--pkgs/development/python-modules/cornice/default.nix4
-rw-r--r--pkgs/development/python-modules/cot/default.nix4
-rw-r--r--pkgs/development/python-modules/cov-core/default.nix4
-rw-r--r--pkgs/development/python-modules/cppheaderparser/default.nix4
-rw-r--r--pkgs/development/python-modules/crate/default.nix4
-rw-r--r--pkgs/development/python-modules/crayons/default.nix4
-rw-r--r--pkgs/development/python-modules/crc16/default.nix4
-rw-r--r--pkgs/development/python-modules/crccheck/default.nix4
-rw-r--r--pkgs/development/python-modules/crcmod/default.nix4
-rw-r--r--pkgs/development/python-modules/credstash/default.nix4
-rw-r--r--pkgs/development/python-modules/cryptacular/default.nix4
-rw-r--r--pkgs/development/python-modules/cryptography/3.3.nix4
-rw-r--r--pkgs/development/python-modules/cryptography/default.nix4
-rw-r--r--pkgs/development/python-modules/cssmin/default.nix4
-rw-r--r--pkgs/development/python-modules/cssselect/default.nix4
-rw-r--r--pkgs/development/python-modules/cssutils/default.nix4
-rw-r--r--pkgs/development/python-modules/cupy/default.nix4
-rw-r--r--pkgs/development/python-modules/curtsies/default.nix4
-rw-r--r--pkgs/development/python-modules/curve25519-donna/default.nix4
-rw-r--r--pkgs/development/python-modules/cx_freeze/default.nix4
-rw-r--r--pkgs/development/python-modules/cx_oracle/default.nix4
-rw-r--r--pkgs/development/python-modules/cymem/default.nix4
-rw-r--r--pkgs/development/python-modules/cypari2/default.nix4
-rw-r--r--pkgs/development/python-modules/daemonize/default.nix4
-rw-r--r--pkgs/development/python-modules/daphne/default.nix4
-rw-r--r--pkgs/development/python-modules/darcsver/default.nix4
-rw-r--r--pkgs/development/python-modules/dask-glm/default.nix4
-rw-r--r--pkgs/development/python-modules/dask-image/default.nix4
-rw-r--r--pkgs/development/python-modules/dask-jobqueue/default.nix4
-rw-r--r--pkgs/development/python-modules/dask-ml/default.nix4
-rw-r--r--pkgs/development/python-modules/dask-mpi/default.nix4
-rw-r--r--pkgs/development/python-modules/dask-xgboost/default.nix4
-rw-r--r--pkgs/development/python-modules/databricks-cli/default.nix4
-rw-r--r--pkgs/development/python-modules/dataclasses/default.nix4
-rw-r--r--pkgs/development/python-modules/datadiff/default.nix4
-rw-r--r--pkgs/development/python-modules/datamodeldict/default.nix4
-rw-r--r--pkgs/development/python-modules/dateutil/default.nix4
-rw-r--r--pkgs/development/python-modules/datrie/default.nix4
-rw-r--r--pkgs/development/python-modules/dbf/default.nix4
-rw-r--r--pkgs/development/python-modules/dbfread/default.nix4
-rw-r--r--pkgs/development/python-modules/dbus-next/default.nix4
-rw-r--r--pkgs/development/python-modules/dbutils/default.nix4
-rw-r--r--pkgs/development/python-modules/dcmstack/default.nix4
-rw-r--r--pkgs/development/python-modules/deap/default.nix4
-rw-r--r--pkgs/development/python-modules/deluge-client/default.nix4
-rw-r--r--pkgs/development/python-modules/demjson/default.nix4
-rw-r--r--pkgs/development/python-modules/dependency-injector/default.nix4
-rw-r--r--pkgs/development/python-modules/deprecated/default.nix4
-rw-r--r--pkgs/development/python-modules/derpconf/default.nix4
-rw-r--r--pkgs/development/python-modules/descartes/default.nix4
-rw-r--r--pkgs/development/python-modules/deskcon/default.nix4
-rw-r--r--pkgs/development/python-modules/diff_cover/default.nix4
-rw-r--r--pkgs/development/python-modules/digi-xbee/default.nix2
-rw-r--r--pkgs/development/python-modules/digitalocean/default.nix4
-rw-r--r--pkgs/development/python-modules/discid/default.nix4
-rw-r--r--pkgs/development/python-modules/discogs_client/default.nix4
-rw-r--r--pkgs/development/python-modules/distlib/default.nix4
-rw-r--r--pkgs/development/python-modules/distorm3/default.nix4
-rw-r--r--pkgs/development/python-modules/distro/default.nix4
-rw-r--r--pkgs/development/python-modules/distutils_extra/default.nix4
-rw-r--r--pkgs/development/python-modules/dj-email-url/default.nix4
-rw-r--r--pkgs/development/python-modules/dj-search-url/default.nix4
-rw-r--r--pkgs/development/python-modules/django-allauth/default.nix4
-rw-r--r--pkgs/development/python-modules/django-anymail/default.nix4
-rw-r--r--pkgs/development/python-modules/django-auth-ldap/default.nix4
-rw-r--r--pkgs/development/python-modules/django-cache-url/default.nix4
-rw-r--r--pkgs/development/python-modules/django-cleanup/default.nix4
-rw-r--r--pkgs/development/python-modules/django-compat/default.nix4
-rw-r--r--pkgs/development/python-modules/django-configurations/default.nix4
-rw-r--r--pkgs/development/python-modules/django-csp/default.nix4
-rw-r--r--pkgs/development/python-modules/django-discover-runner/default.nix4
-rw-r--r--pkgs/development/python-modules/django-dynamic-preferences/default.nix4
-rw-r--r--pkgs/development/python-modules/django-filter/default.nix4
-rw-r--r--pkgs/development/python-modules/django-gravatar2/default.nix4
-rw-r--r--pkgs/development/python-modules/django-hijack-admin/default.nix4
-rw-r--r--pkgs/development/python-modules/django-hijack/default.nix4
-rw-r--r--pkgs/development/python-modules/django-logentry-admin/default.nix4
-rw-r--r--pkgs/development/python-modules/django-mailman3/default.nix4
-rw-r--r--pkgs/development/python-modules/django-maintenance-mode/default.nix4
-rw-r--r--pkgs/development/python-modules/django-oauth-toolkit/default.nix4
-rw-r--r--pkgs/development/python-modules/django-paintstore/default.nix4
-rw-r--r--pkgs/development/python-modules/django-postgresql-netfields/default.nix4
-rw-r--r--pkgs/development/python-modules/django-q/default.nix4
-rw-r--r--pkgs/development/python-modules/django-ranged-response/default.nix4
-rw-r--r--pkgs/development/python-modules/django-raster/default.nix4
-rw-r--r--pkgs/development/python-modules/django-storages/default.nix4
-rw-r--r--pkgs/development/python-modules/django-versatileimagefield/default.nix4
-rw-r--r--pkgs/development/python-modules/django-widget-tweaks/default.nix4
-rw-r--r--pkgs/development/python-modules/django/2.nix4
-rw-r--r--pkgs/development/python-modules/django/3.nix4
-rw-r--r--pkgs/development/python-modules/django_appconf/default.nix4
-rw-r--r--pkgs/development/python-modules/django_classytags/default.nix4
-rw-r--r--pkgs/development/python-modules/django_colorful/default.nix4
-rw-r--r--pkgs/development/python-modules/django_compressor/default.nix4
-rw-r--r--pkgs/development/python-modules/django_contrib_comments/default.nix4
-rw-r--r--pkgs/development/python-modules/django_environ/default.nix4
-rw-r--r--pkgs/development/python-modules/django_evolution/default.nix4
-rw-r--r--pkgs/development/python-modules/django_guardian/default.nix4
-rw-r--r--pkgs/development/python-modules/django_modelcluster/default.nix4
-rw-r--r--pkgs/development/python-modules/django_nose/default.nix4
-rw-r--r--pkgs/development/python-modules/django_redis/default.nix4
-rw-r--r--pkgs/development/python-modules/django_reversion/default.nix4
-rw-r--r--pkgs/development/python-modules/django_silk/default.nix4
-rw-r--r--pkgs/development/python-modules/django_taggit/default.nix4
-rw-r--r--pkgs/development/python-modules/django_treebeard/default.nix4
-rw-r--r--pkgs/development/python-modules/djangorestframework/default.nix4
-rw-r--r--pkgs/development/python-modules/dkimpy/default.nix4
-rw-r--r--pkgs/development/python-modules/docker-pycreds/default.nix4
-rw-r--r--pkgs/development/python-modules/dockerfile-parse/default.nix4
-rw-r--r--pkgs/development/python-modules/dockerpty/default.nix4
-rw-r--r--pkgs/development/python-modules/docopt/default.nix4
-rw-r--r--pkgs/development/python-modules/doctest-ignore-unicode/default.nix4
-rw-r--r--pkgs/development/python-modules/dogpile.cache/default.nix4
-rw-r--r--pkgs/development/python-modules/dogpile.core/default.nix4
-rw-r--r--pkgs/development/python-modules/dot2tex/default.nix4
-rw-r--r--pkgs/development/python-modules/dpath/default.nix4
-rw-r--r--pkgs/development/python-modules/dpkt/default.nix4
-rw-r--r--pkgs/development/python-modules/drf-yasg/default.nix4
-rw-r--r--pkgs/development/python-modules/dropbox/default.nix4
-rw-r--r--pkgs/development/python-modules/dtopt/default.nix4
-rw-r--r--pkgs/development/python-modules/dufte/default.nix4
-rw-r--r--pkgs/development/python-modules/dulwich/0_19.nix4
-rw-r--r--pkgs/development/python-modules/dulwich/default.nix4
-rw-r--r--pkgs/development/python-modules/dyn/default.nix4
-rw-r--r--pkgs/development/python-modules/dynd/default.nix4
-rw-r--r--pkgs/development/python-modules/easygui/default.nix4
-rw-r--r--pkgs/development/python-modules/easyprocess/default.nix4
-rw-r--r--pkgs/development/python-modules/ecdsa/default.nix4
-rw-r--r--pkgs/development/python-modules/ed25519/default.nix4
-rw-r--r--pkgs/development/python-modules/editorconfig/default.nix4
-rw-r--r--pkgs/development/python-modules/edward/default.nix4
-rw-r--r--pkgs/development/python-modules/eggdeps/default.nix4
-rw-r--r--pkgs/development/python-modules/elasticsearch-dsl/default.nix4
-rw-r--r--pkgs/development/python-modules/elasticsearch/default.nix4
-rw-r--r--pkgs/development/python-modules/eliot/default.nix4
-rw-r--r--pkgs/development/python-modules/emcee/default.nix4
-rw-r--r--pkgs/development/python-modules/emv/default.nix4
-rw-r--r--pkgs/development/python-modules/enum/default.nix4
-rw-r--r--pkgs/development/python-modules/enum34/default.nix4
-rw-r--r--pkgs/development/python-modules/epc/default.nix4
-rw-r--r--pkgs/development/python-modules/ephem/default.nix4
-rw-r--r--pkgs/development/python-modules/et_xmlfile/default.nix4
-rw-r--r--pkgs/development/python-modules/etcd/default.nix4
-rw-r--r--pkgs/development/python-modules/etebase/default.nix4
-rw-r--r--pkgs/development/python-modules/eve/default.nix4
-rw-r--r--pkgs/development/python-modules/eventlib/default.nix4
-rw-r--r--pkgs/development/python-modules/evernote/default.nix4
-rw-r--r--pkgs/development/python-modules/exchangelib/default.nix4
-rw-r--r--pkgs/development/python-modules/execnet/default.nix2
-rw-r--r--pkgs/development/python-modules/exifread/default.nix4
-rw-r--r--pkgs/development/python-modules/eyed3/default.nix2
-rw-r--r--pkgs/development/python-modules/ezdxf/default.nix4
-rw-r--r--pkgs/development/python-modules/face/default.nix4
-rw-r--r--pkgs/development/python-modules/face_recognition/default.nix4
-rw-r--r--pkgs/development/python-modules/face_recognition_models/default.nix4
-rw-r--r--pkgs/development/python-modules/fake-useragent/default.nix4
-rw-r--r--pkgs/development/python-modules/fake_factory/default.nix4
-rw-r--r--pkgs/development/python-modules/falcon/default.nix4
-rw-r--r--pkgs/development/python-modules/fasteners/default.nix4
-rw-r--r--pkgs/development/python-modules/fastentrypoints/default.nix4
-rw-r--r--pkgs/development/python-modules/fastimport/default.nix4
-rw-r--r--pkgs/development/python-modules/fastpair/default.nix4
-rw-r--r--pkgs/development/python-modules/fastpbkdf2/default.nix4
-rw-r--r--pkgs/development/python-modules/fastprogress/default.nix4
-rw-r--r--pkgs/development/python-modules/fastrlock/default.nix4
-rw-r--r--pkgs/development/python-modules/fasttext/default.nix4
-rw-r--r--pkgs/development/python-modules/fdint/default.nix4
-rw-r--r--pkgs/development/python-modules/feedgen/default.nix4
-rw-r--r--pkgs/development/python-modules/feedgenerator/default.nix4
-rw-r--r--pkgs/development/python-modules/feedparser/5.nix4
-rw-r--r--pkgs/development/python-modules/feedparser/default.nix4
-rw-r--r--pkgs/development/python-modules/filebrowser_safe/default.nix4
-rw-r--r--pkgs/development/python-modules/filebytes/default.nix4
-rw-r--r--pkgs/development/python-modules/filelock/default.nix4
-rw-r--r--pkgs/development/python-modules/filterpy/default.nix4
-rw-r--r--pkgs/development/python-modules/fints/default.nix4
-rw-r--r--pkgs/development/python-modules/fire/default.nix4
-rw-r--r--pkgs/development/python-modules/first/default.nix4
-rw-r--r--pkgs/development/python-modules/flake8/default.nix4
-rw-r--r--pkgs/development/python-modules/flaky/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-babel/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-common/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-compress/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-cors/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-elastic/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-jwt-extended/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-ldap-login/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-limiter/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-login/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-reverse-proxy-fix/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-silk/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-sqlalchemy/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-swagger-ui/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-swagger/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-testing/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-versioned/default.nix4
-rw-r--r--pkgs/development/python-modules/flask-wtf/default.nix4
-rw-r--r--pkgs/development/python-modules/flask/default.nix4
-rw-r--r--pkgs/development/python-modules/flaskbabel/default.nix4
-rw-r--r--pkgs/development/python-modules/flowlogs_reader/default.nix4
-rw-r--r--pkgs/development/python-modules/flup/default.nix4
-rw-r--r--pkgs/development/python-modules/flux-led/default.nix4
-rw-r--r--pkgs/development/python-modules/foolscap/default.nix4
-rw-r--r--pkgs/development/python-modules/forbiddenfruit/default.nix4
-rw-r--r--pkgs/development/python-modules/foxdot/default.nix4
-rw-r--r--pkgs/development/python-modules/freezegun/0.3.nix4
-rw-r--r--pkgs/development/python-modules/freezegun/default.nix4
-rw-r--r--pkgs/development/python-modules/fritzconnection/default.nix4
-rw-r--r--pkgs/development/python-modules/frozendict/default.nix4
-rw-r--r--pkgs/development/python-modules/ftfy/default.nix4
-rw-r--r--pkgs/development/python-modules/fudge/default.nix4
-rw-r--r--pkgs/development/python-modules/funcparserlib/default.nix4
-rw-r--r--pkgs/development/python-modules/funcsigs/default.nix4
-rw-r--r--pkgs/development/python-modules/functools32/default.nix4
-rw-r--r--pkgs/development/python-modules/funcy/default.nix4
-rw-r--r--pkgs/development/python-modules/furl/default.nix4
-rw-r--r--pkgs/development/python-modules/fuse-python/default.nix4
-rw-r--r--pkgs/development/python-modules/fusepy/default.nix4
-rw-r--r--pkgs/development/python-modules/fuzzywuzzy/default.nix4
-rw-r--r--pkgs/development/python-modules/gast/default.nix4
-rw-r--r--pkgs/development/python-modules/gateone/default.nix4
-rw-r--r--pkgs/development/python-modules/gcovr/default.nix4
-rw-r--r--pkgs/development/python-modules/gdata/default.nix4
-rw-r--r--pkgs/development/python-modules/gdrivefs/default.nix4
-rw-r--r--pkgs/development/python-modules/geeknote/default.nix4
-rw-r--r--pkgs/development/python-modules/genanki/default.nix4
-rw-r--r--pkgs/development/python-modules/genshi/default.nix4
-rw-r--r--pkgs/development/python-modules/genzshcomp/default.nix4
-rw-r--r--pkgs/development/python-modules/geoalchemy2/default.nix4
-rw-r--r--pkgs/development/python-modules/geographiclib/default.nix4
-rw-r--r--pkgs/development/python-modules/geopandas/default.nix4
-rw-r--r--pkgs/development/python-modules/geopy/2.nix4
-rw-r--r--pkgs/development/python-modules/geopy/default.nix4
-rw-r--r--pkgs/development/python-modules/gevent-socketio/default.nix4
-rw-r--r--pkgs/development/python-modules/gevent-websocket/default.nix4
-rw-r--r--pkgs/development/python-modules/gevent/default.nix4
-rw-r--r--pkgs/development/python-modules/geventhttpclient/default.nix4
-rw-r--r--pkgs/development/python-modules/ghdiff/default.nix4
-rw-r--r--pkgs/development/python-modules/gipc/default.nix4
-rw-r--r--pkgs/development/python-modules/git-annex-adapter/default.nix4
-rw-r--r--pkgs/development/python-modules/git-sweep/default.nix4
-rw-r--r--pkgs/development/python-modules/globre/default.nix4
-rw-r--r--pkgs/development/python-modules/glom/default.nix4
-rw-r--r--pkgs/development/python-modules/glymur/default.nix4
-rw-r--r--pkgs/development/python-modules/gmpy2/default.nix4
-rw-r--r--pkgs/development/python-modules/gmusicapi/default.nix4
-rw-r--r--pkgs/development/python-modules/gnureadline/default.nix4
-rw-r--r--pkgs/development/python-modules/gnutls/default.nix4
-rw-r--r--pkgs/development/python-modules/goobook/default.nix4
-rw-r--r--pkgs/development/python-modules/goocalendar/default.nix4
-rw-r--r--pkgs/development/python-modules/google-apputils/default.nix4
-rw-r--r--pkgs/development/python-modules/google-auth/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-asset/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-automl/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-bigquery-datatransfer/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-bigquery/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-bigtable/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-container/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-core/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-dataproc/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-datastore/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-dlp/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-dns/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-error-reporting/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-firestore/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-iot/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-kms/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-language/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-logging/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-monitoring/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-pubsub/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-redis/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-resource-manager/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-runtimeconfig/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-securitycenter/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-spanner/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-speech/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-tasks/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-testutils/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-texttospeech/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-trace/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-translate/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-videointelligence/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-vision/default.nix4
-rw-r--r--pkgs/development/python-modules/google-cloud-websecurityscanner/default.nix4
-rw-r--r--pkgs/development/python-modules/googleapis_common_protos/default.nix4
-rw-r--r--pkgs/development/python-modules/googlemaps/default.nix4
-rw-r--r--pkgs/development/python-modules/gorilla/default.nix4
-rw-r--r--pkgs/development/python-modules/gpapi/default.nix4
-rw-r--r--pkgs/development/python-modules/gphoto2/default.nix4
-rw-r--r--pkgs/development/python-modules/gplaycli/default.nix4
-rw-r--r--pkgs/development/python-modules/gpsoauth/default.nix4
-rw-r--r--pkgs/development/python-modules/gpy/default.nix4
-rw-r--r--pkgs/development/python-modules/gpyopt/default.nix4
-rw-r--r--pkgs/development/python-modules/gradient_sdk/default.nix4
-rw-r--r--pkgs/development/python-modules/gradient_statsd/default.nix2
-rw-r--r--pkgs/development/python-modules/graphite-web/default.nix4
-rw-r--r--pkgs/development/python-modules/graphite_beacon/default.nix4
-rw-r--r--pkgs/development/python-modules/grappelli_safe/default.nix4
-rw-r--r--pkgs/development/python-modules/grequests/default.nix4
-rw-r--r--pkgs/development/python-modules/grip/default.nix4
-rw-r--r--pkgs/development/python-modules/grpc_google_iam_v1/default.nix4
-rw-r--r--pkgs/development/python-modules/grpcio-gcp/default.nix4
-rw-r--r--pkgs/development/python-modules/grpcio-tools/default.nix4
-rw-r--r--pkgs/development/python-modules/grpcio/default.nix4
-rw-r--r--pkgs/development/python-modules/gsd/1.7.nix4
-rw-r--r--pkgs/development/python-modules/gspread/default.nix4
-rw-r--r--pkgs/development/python-modules/gtimelog/default.nix4
-rw-r--r--pkgs/development/python-modules/guestfs/default.nix4
-rw-r--r--pkgs/development/python-modules/gunicorn/19.nix4
-rw-r--r--pkgs/development/python-modules/gunicorn/default.nix4
-rw-r--r--pkgs/development/python-modules/guzzle_sphinx_theme/default.nix4
-rw-r--r--pkgs/development/python-modules/gyp/default.nix4
-rw-r--r--pkgs/development/python-modules/h2/default.nix4
-rw-r--r--pkgs/development/python-modules/h3/default.nix4
-rw-r--r--pkgs/development/python-modules/ha-ffmpeg/default.nix4
-rw-r--r--pkgs/development/python-modules/handout/default.nix4
-rw-r--r--pkgs/development/python-modules/hawkauthlib/default.nix4
-rw-r--r--pkgs/development/python-modules/hbmqtt/default.nix4
-rw-r--r--pkgs/development/python-modules/hcs_utils/default.nix4
-rw-r--r--pkgs/development/python-modules/hdmedians/default.nix4
-rw-r--r--pkgs/development/python-modules/heapdict/default.nix4
-rw-r--r--pkgs/development/python-modules/helper/default.nix4
-rw-r--r--pkgs/development/python-modules/hetzner/default.nix4
-rw-r--r--pkgs/development/python-modules/heudiconv/default.nix4
-rw-r--r--pkgs/development/python-modules/hg-evolve/default.nix4
-rw-r--r--pkgs/development/python-modules/hg-git/default.nix4
-rw-r--r--pkgs/development/python-modules/hglib/default.nix4
-rw-r--r--pkgs/development/python-modules/hgsvn/default.nix4
-rw-r--r--pkgs/development/python-modules/hidapi/default.nix4
-rw-r--r--pkgs/development/python-modules/hieroglyph/default.nix4
-rw-r--r--pkgs/development/python-modules/hiredis/default.nix4
-rw-r--r--pkgs/development/python-modules/hiro/default.nix4
-rw-r--r--pkgs/development/python-modules/hjson/default.nix4
-rw-r--r--pkgs/development/python-modules/hkdf/default.nix4
-rw-r--r--pkgs/development/python-modules/hocr-tools/default.nix4
-rw-r--r--pkgs/development/python-modules/holidays/default.nix4
-rw-r--r--pkgs/development/python-modules/hoomd-blue/default.nix4
-rw-r--r--pkgs/development/python-modules/hpack/default.nix4
-rw-r--r--pkgs/development/python-modules/hsaudiotag/default.nix4
-rw-r--r--pkgs/development/python-modules/hsaudiotag3k/default.nix4
-rw-r--r--pkgs/development/python-modules/html2text/2018.nix4
-rw-r--r--pkgs/development/python-modules/html5-parser/default.nix4
-rw-r--r--pkgs/development/python-modules/htmllaundry/default.nix4
-rw-r--r--pkgs/development/python-modules/httmock/default.nix4
-rw-r--r--pkgs/development/python-modules/http_signature/default.nix4
-rw-r--r--pkgs/development/python-modules/httpauth/default.nix4
-rw-r--r--pkgs/development/python-modules/httpbin/default.nix4
-rw-r--r--pkgs/development/python-modules/httpretty/0.nix4
-rw-r--r--pkgs/development/python-modules/httpretty/default.nix4
-rw-r--r--pkgs/development/python-modules/humanize/default.nix4
-rw-r--r--pkgs/development/python-modules/hyperframe/default.nix4
-rw-r--r--pkgs/development/python-modules/hyperopt/default.nix4
-rw-r--r--pkgs/development/python-modules/i3-py/default.nix4
-rw-r--r--pkgs/development/python-modules/i3ipc/default.nix4
-rw-r--r--pkgs/development/python-modules/icalendar/default.nix4
-rw-r--r--pkgs/development/python-modules/ics/default.nix4
-rw-r--r--pkgs/development/python-modules/ifaddr/default.nix4
-rw-r--r--pkgs/development/python-modules/ifconfig-parser/default.nix4
-rw-r--r--pkgs/development/python-modules/ifcopenshell/default.nix4
-rw-r--r--pkgs/development/python-modules/ijson/default.nix4
-rw-r--r--pkgs/development/python-modules/image-match/default.nix4
-rw-r--r--pkgs/development/python-modules/imagecorruptions/default.nix4
-rw-r--r--pkgs/development/python-modules/imageio/default.nix4
-rw-r--r--pkgs/development/python-modules/imagesize/default.nix4
-rw-r--r--pkgs/development/python-modules/imapclient/default.nix4
-rw-r--r--pkgs/development/python-modules/imbalanced-learn/0.4.nix4
-rw-r--r--pkgs/development/python-modules/imbalanced-learn/default.nix4
-rw-r--r--pkgs/development/python-modules/imgaug/default.nix4
-rw-r--r--pkgs/development/python-modules/imgsize/default.nix4
-rw-r--r--pkgs/development/python-modules/importmagic/default.nix4
-rw-r--r--pkgs/development/python-modules/imread/default.nix4
-rw-r--r--pkgs/development/python-modules/imutils/default.nix4
-rw-r--r--pkgs/development/python-modules/influxdb/default.nix4
-rw-r--r--pkgs/development/python-modules/influxgraph/default.nix4
-rw-r--r--pkgs/development/python-modules/infoqscraper/default.nix4
-rw-r--r--pkgs/development/python-modules/inifile/default.nix4
-rw-r--r--pkgs/development/python-modules/iniparse/default.nix4
-rw-r--r--pkgs/development/python-modules/inquirer/default.nix4
-rw-r--r--pkgs/development/python-modules/interruptingcow/default.nix4
-rw-r--r--pkgs/development/python-modules/intervaltree/default.nix4
-rw-r--r--pkgs/development/python-modules/ipaddr/default.nix4
-rw-r--r--pkgs/development/python-modules/ipaddress/default.nix4
-rw-r--r--pkgs/development/python-modules/ipdb/default.nix4
-rw-r--r--pkgs/development/python-modules/ipdbplugin/default.nix4
-rw-r--r--pkgs/development/python-modules/ipfsapi/default.nix4
-rw-r--r--pkgs/development/python-modules/iptools/default.nix4
-rw-r--r--pkgs/development/python-modules/iso3166/default.nix4
-rw-r--r--pkgs/development/python-modules/isodate/default.nix4
-rw-r--r--pkgs/development/python-modules/itsdangerous/default.nix4
-rw-r--r--pkgs/development/python-modules/itypes/default.nix4
-rw-r--r--pkgs/development/python-modules/j2cli/default.nix4
-rw-r--r--pkgs/development/python-modules/jabberbot/default.nix4
-rw-r--r--pkgs/development/python-modules/jc/default.nix4
-rw-r--r--pkgs/development/python-modules/jdatetime/default.nix4
-rw-r--r--pkgs/development/python-modules/jedi/default.nix4
-rw-r--r--pkgs/development/python-modules/jenkinsapi/default.nix4
-rw-r--r--pkgs/development/python-modules/jinja2/default.nix4
-rw-r--r--pkgs/development/python-modules/jinja2_pluralize/default.nix4
-rw-r--r--pkgs/development/python-modules/jinja2_time/default.nix4
-rw-r--r--pkgs/development/python-modules/jmespath/default.nix4
-rw-r--r--pkgs/development/python-modules/jpylyzer/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonfield/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonpath_rw/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonpointer/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonref/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonrpc-async/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonrpc-base/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonrpc-websocket/default.nix4
-rw-r--r--pkgs/development/python-modules/jsonwatch/default.nix4
-rw-r--r--pkgs/development/python-modules/jug/default.nix4
-rw-r--r--pkgs/development/python-modules/junos-eznc/default.nix4
-rw-r--r--pkgs/development/python-modules/jupyter-repo2docker/default.nix4
-rw-r--r--pkgs/development/python-modules/jupyter-telemetry/default.nix2
-rw-r--r--pkgs/development/python-modules/jupyter/default.nix4
-rw-r--r--pkgs/development/python-modules/jupyterlab-git/default.nix4
-rw-r--r--pkgs/development/python-modules/jupyterlab_server/default.nix4
-rw-r--r--pkgs/development/python-modules/kaa-base/default.nix4
-rw-r--r--pkgs/development/python-modules/kaa-metadata/default.nix4
-rw-r--r--pkgs/development/python-modules/kafka-python/default.nix4
-rw-r--r--pkgs/development/python-modules/kaitaistruct/default.nix4
-rw-r--r--pkgs/development/python-modules/kajiki/default.nix4
-rw-r--r--pkgs/development/python-modules/kaptan/default.nix4
-rw-r--r--pkgs/development/python-modules/kazoo/default.nix4
-rw-r--r--pkgs/development/python-modules/keep/default.nix4
-rw-r--r--pkgs/development/python-modules/keepalive/default.nix4
-rw-r--r--pkgs/development/python-modules/keepkey/default.nix4
-rw-r--r--pkgs/development/python-modules/keepkey_agent/default.nix4
-rw-r--r--pkgs/development/python-modules/keras/default.nix4
-rw-r--r--pkgs/development/python-modules/kerberos/default.nix4
-rw-r--r--pkgs/development/python-modules/keyring/2.nix4
-rw-r--r--pkgs/development/python-modules/keyrings-alt/default.nix4
-rw-r--r--pkgs/development/python-modules/kitchen/default.nix4
-rw-r--r--pkgs/development/python-modules/korean-lunar-calendar/default.nix4
-rw-r--r--pkgs/development/python-modules/kubernetes/default.nix4
-rw-r--r--pkgs/development/python-modules/larch/default.nix4
-rw-r--r--pkgs/development/python-modules/lasagne/default.nix4
-rw-r--r--pkgs/development/python-modules/lazy-object-proxy/default.nix4
-rw-r--r--pkgs/development/python-modules/lazy_import/default.nix4
-rw-r--r--pkgs/development/python-modules/ldap/default.nix4
-rw-r--r--pkgs/development/python-modules/ldap3/default.nix4
-rw-r--r--pkgs/development/python-modules/le/default.nix4
-rw-r--r--pkgs/development/python-modules/leather/default.nix4
-rw-r--r--pkgs/development/python-modules/ledger_agent/default.nix4
-rw-r--r--pkgs/development/python-modules/ledgerblue/default.nix4
-rw-r--r--pkgs/development/python-modules/ledgerwallet/default.nix4
-rw-r--r--pkgs/development/python-modules/libagent/default.nix4
-rw-r--r--pkgs/development/python-modules/libais/default.nix4
-rw-r--r--pkgs/development/python-modules/libarchive-c/default.nix4
-rw-r--r--pkgs/development/python-modules/libarcus/default.nix4
-rw-r--r--pkgs/development/python-modules/libasyncns/default.nix4
-rw-r--r--pkgs/development/python-modules/libevdev/default.nix4
-rw-r--r--pkgs/development/python-modules/libgpuarray/default.nix2
-rw-r--r--pkgs/development/python-modules/libkeepass/default.nix4
-rw-r--r--pkgs/development/python-modules/liblarch/default.nix4
-rw-r--r--pkgs/development/python-modules/libmr/default.nix4
-rw-r--r--pkgs/development/python-modules/libnacl/default.nix4
-rw-r--r--pkgs/development/python-modules/librosa/default.nix4
-rw-r--r--pkgs/development/python-modules/libsavitar/default.nix4
-rw-r--r--pkgs/development/python-modules/libsoundtouch/default.nix2
-rw-r--r--pkgs/development/python-modules/libthumbor/default.nix4
-rw-r--r--pkgs/development/python-modules/libtmux/default.nix4
-rw-r--r--pkgs/development/python-modules/libusb1/default.nix4
-rw-r--r--pkgs/development/python-modules/libversion/default.nix4
-rw-r--r--pkgs/development/python-modules/libvirt/5.9.0.nix4
-rw-r--r--pkgs/development/python-modules/libvirt/default.nix4
-rw-r--r--pkgs/development/python-modules/lightblue/default.nix4
-rw-r--r--pkgs/development/python-modules/lightgbm/default.nix4
-rw-r--r--pkgs/development/python-modules/lightning/default.nix4
-rw-r--r--pkgs/development/python-modules/limits/default.nix4
-rw-r--r--pkgs/development/python-modules/limnoria/default.nix4
-rw-r--r--pkgs/development/python-modules/linecache2/default.nix4
-rw-r--r--pkgs/development/python-modules/linode/default.nix4
-rw-r--r--pkgs/development/python-modules/livelossplot/default.nix4
-rw-r--r--pkgs/development/python-modules/livestreamer-curses/default.nix4
-rw-r--r--pkgs/development/python-modules/livestreamer/default.nix4
-rw-r--r--pkgs/development/python-modules/llfuse/default.nix4
-rw-r--r--pkgs/development/python-modules/lmdb/default.nix4
-rw-r--r--pkgs/development/python-modules/lmtpd/default.nix4
-rw-r--r--pkgs/development/python-modules/localzone/default.nix4
-rw-r--r--pkgs/development/python-modules/locket/default.nix4
-rw-r--r--pkgs/development/python-modules/logilab/common.nix4
-rw-r--r--pkgs/development/python-modules/logilab/constraint.nix4
-rw-r--r--pkgs/development/python-modules/logilab_astng/default.nix4
-rw-r--r--pkgs/development/python-modules/loguru/default.nix4
-rw-r--r--pkgs/development/python-modules/logutils/default.nix4
-rw-r--r--pkgs/development/python-modules/lpod/default.nix4
-rw-r--r--pkgs/development/python-modules/lsi/default.nix4
-rw-r--r--pkgs/development/python-modules/lxc/default.nix4
-rw-r--r--pkgs/development/python-modules/lyricwikia/default.nix4
-rw-r--r--pkgs/development/python-modules/m2crypto/default.nix2
-rw-r--r--pkgs/development/python-modules/m2r/default.nix4
-rw-r--r--pkgs/development/python-modules/maestral/default.nix4
-rw-r--r--pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix4
-rw-r--r--pkgs/development/python-modules/magic-wormhole/default.nix4
-rw-r--r--pkgs/development/python-modules/magic/default.nix4
-rw-r--r--pkgs/development/python-modules/mahotas/default.nix4
-rw-r--r--pkgs/development/python-modules/mailcap-fix/default.nix4
-rw-r--r--pkgs/development/python-modules/mailchimp/default.nix4
-rw-r--r--pkgs/development/python-modules/mailman-hyperkitty/default.nix4
-rw-r--r--pkgs/development/python-modules/mailman-rss/default.nix4
-rw-r--r--pkgs/development/python-modules/mailmanclient/default.nix4
-rw-r--r--pkgs/development/python-modules/manhole/default.nix4
-rw-r--r--pkgs/development/python-modules/manuel/default.nix4
-rw-r--r--pkgs/development/python-modules/mapsplotlib/default.nix4
-rw-r--r--pkgs/development/python-modules/marionette-harness/mozinfo.nix4
-rw-r--r--pkgs/development/python-modules/marisa/default.nix4
-rw-r--r--pkgs/development/python-modules/markdown-macros/default.nix4
-rw-r--r--pkgs/development/python-modules/markdown2/default.nix4
-rw-r--r--pkgs/development/python-modules/markerlib/default.nix4
-rw-r--r--pkgs/development/python-modules/markupsafe/default.nix4
-rw-r--r--pkgs/development/python-modules/matplotlib/2.nix4
-rw-r--r--pkgs/development/python-modules/matplotlib/default.nix4
-rw-r--r--pkgs/development/python-modules/matrix-client/default.nix4
-rw-r--r--pkgs/development/python-modules/maya/default.nix4
-rw-r--r--pkgs/development/python-modules/mccabe/default.nix4
-rw-r--r--pkgs/development/python-modules/mdp/default.nix4
-rw-r--r--pkgs/development/python-modules/mechanize/default.nix4
-rw-r--r--pkgs/development/python-modules/meinheld/default.nix4
-rw-r--r--pkgs/development/python-modules/meld3/default.nix4
-rw-r--r--pkgs/development/python-modules/meliae/default.nix4
-rw-r--r--pkgs/development/python-modules/memcached/default.nix4
-rw-r--r--pkgs/development/python-modules/memory_profiler/default.nix4
-rw-r--r--pkgs/development/python-modules/mergedeep/default.nix4
-rw-r--r--pkgs/development/python-modules/mesa/default.nix4
-rw-r--r--pkgs/development/python-modules/metaphone/default.nix4
-rw-r--r--pkgs/development/python-modules/micawber/default.nix4
-rw-r--r--pkgs/development/python-modules/midiutil/default.nix4
-rw-r--r--pkgs/development/python-modules/milc/default.nix4
-rw-r--r--pkgs/development/python-modules/minimock/default.nix4
-rw-r--r--pkgs/development/python-modules/miniupnpc/default.nix4
-rw-r--r--pkgs/development/python-modules/mitmproxy/default.nix4
-rw-r--r--pkgs/development/python-modules/mlflow/default.nix4
-rw-r--r--pkgs/development/python-modules/mlrose/default.nix4
-rw-r--r--pkgs/development/python-modules/mlxtend/default.nix4
-rw-r--r--pkgs/development/python-modules/mmpython/default.nix4
-rw-r--r--pkgs/development/python-modules/mockito/default.nix4
-rw-r--r--pkgs/development/python-modules/modestmaps/default.nix4
-rw-r--r--pkgs/development/python-modules/mongodict/default.nix4
-rw-r--r--pkgs/development/python-modules/monotonic/default.nix4
-rw-r--r--pkgs/development/python-modules/moretools/default.nix4
-rw-r--r--pkgs/development/python-modules/moviepy/default.nix4
-rw-r--r--pkgs/development/python-modules/mox/default.nix4
-rw-r--r--pkgs/development/python-modules/mox3/default.nix4
-rw-r--r--pkgs/development/python-modules/mozsvc/default.nix4
-rw-r--r--pkgs/development/python-modules/mpd/default.nix4
-rw-r--r--pkgs/development/python-modules/mpd2/default.nix4
-rw-r--r--pkgs/development/python-modules/mpmath/default.nix4
-rw-r--r--pkgs/development/python-modules/mpv/default.nix4
-rw-r--r--pkgs/development/python-modules/mrbob/default.nix4
-rw-r--r--pkgs/development/python-modules/msgpack-numpy/default.nix4
-rw-r--r--pkgs/development/python-modules/msrplib/default.nix4
-rw-r--r--pkgs/development/python-modules/multi_key_dict/default.nix4
-rw-r--r--pkgs/development/python-modules/munch/default.nix4
-rw-r--r--pkgs/development/python-modules/munkres/default.nix4
-rw-r--r--pkgs/development/python-modules/murmurhash/default.nix4
-rw-r--r--pkgs/development/python-modules/musicbrainzngs/default.nix4
-rw-r--r--pkgs/development/python-modules/mutag/default.nix4
-rw-r--r--pkgs/development/python-modules/muttils/default.nix4
-rw-r--r--pkgs/development/python-modules/mwclient/default.nix4
-rw-r--r--pkgs/development/python-modules/mwlib-ext/default.nix4
-rw-r--r--pkgs/development/python-modules/mwlib-rl/default.nix4
-rw-r--r--pkgs/development/python-modules/mwlib/default.nix4
-rw-r--r--pkgs/development/python-modules/mwparserfromhell/default.nix4
-rw-r--r--pkgs/development/python-modules/mygpoclient/default.nix4
-rw-r--r--pkgs/development/python-modules/mypy-protobuf/default.nix4
-rw-r--r--pkgs/development/python-modules/mypy/default.nix4
-rw-r--r--pkgs/development/python-modules/mypy/extensions.nix4
-rw-r--r--pkgs/development/python-modules/mysqlclient/default.nix4
-rw-r--r--pkgs/development/python-modules/namebench/default.nix4
-rw-r--r--pkgs/development/python-modules/nameparser/default.nix4
-rw-r--r--pkgs/development/python-modules/nanoleaf/default.nix4
-rw-r--r--pkgs/development/python-modules/nanomsg-python/default.nix4
-rw-r--r--pkgs/development/python-modules/nbclient/default.nix4
-rw-r--r--pkgs/development/python-modules/nbxmpp/default.nix4
-rw-r--r--pkgs/development/python-modules/ncclient/default.nix4
-rw-r--r--pkgs/development/python-modules/ndg-httpsclient/default.nix4
-rw-r--r--pkgs/development/python-modules/netaddr/default.nix4
-rw-r--r--pkgs/development/python-modules/netcdf4/default.nix2
-rw-r--r--pkgs/development/python-modules/netdisco/default.nix4
-rw-r--r--pkgs/development/python-modules/netifaces/default.nix4
-rw-r--r--pkgs/development/python-modules/neuronpy/default.nix4
-rw-r--r--pkgs/development/python-modules/nevow/default.nix4
-rw-r--r--pkgs/development/python-modules/nimfa/default.nix4
-rw-r--r--pkgs/development/python-modules/nine/default.nix4
-rw-r--r--pkgs/development/python-modules/nipy/default.nix4
-rw-r--r--pkgs/development/python-modules/nipype/default.nix4
-rw-r--r--pkgs/development/python-modules/nixpkgs/default.nix4
-rw-r--r--pkgs/development/python-modules/node-semver/default.nix4
-rw-r--r--pkgs/development/python-modules/noise/default.nix4
-rw-r--r--pkgs/development/python-modules/nose-cover3/default.nix4
-rw-r--r--pkgs/development/python-modules/nose-cprof/default.nix4
-rw-r--r--pkgs/development/python-modules/nose-focus/default.nix4
-rw-r--r--pkgs/development/python-modules/nose-of-yeti/default.nix4
-rw-r--r--pkgs/development/python-modules/nose-pattern-exclude/default.nix4
-rw-r--r--pkgs/development/python-modules/nose/default.nix4
-rw-r--r--pkgs/development/python-modules/nose2/default.nix4
-rw-r--r--pkgs/development/python-modules/nose_progressive/default.nix4
-rw-r--r--pkgs/development/python-modules/nosejs/default.nix4
-rw-r--r--pkgs/development/python-modules/nosexcover/default.nix4
-rw-r--r--pkgs/development/python-modules/notify/default.nix4
-rw-r--r--pkgs/development/python-modules/notmuch/2.nix4
-rw-r--r--pkgs/development/python-modules/notmuch/default.nix4
-rw-r--r--pkgs/development/python-modules/ntplib/default.nix4
-rw-r--r--pkgs/development/python-modules/nuitka/default.nix4
-rw-r--r--pkgs/development/python-modules/numericalunits/default.nix4
-rw-r--r--pkgs/development/python-modules/nvchecker/default.nix4
-rw-r--r--pkgs/development/python-modules/nwdiag/default.nix4
-rw-r--r--pkgs/development/python-modules/nxt-python/default.nix4
-rw-r--r--pkgs/development/python-modules/oath/default.nix4
-rw-r--r--pkgs/development/python-modules/oauth/default.nix4
-rw-r--r--pkgs/development/python-modules/oauth2/default.nix4
-rw-r--r--pkgs/development/python-modules/oauthlib/3.1.nix4
-rw-r--r--pkgs/development/python-modules/oauthlib/default.nix4
-rw-r--r--pkgs/development/python-modules/obfsproxy/default.nix4
-rw-r--r--pkgs/development/python-modules/objgraph/default.nix4
-rw-r--r--pkgs/development/python-modules/offtrac/default.nix4
-rw-r--r--pkgs/development/python-modules/ofxclient/default.nix4
-rw-r--r--pkgs/development/python-modules/ofxhome/default.nix4
-rw-r--r--pkgs/development/python-modules/ofxparse/default.nix4
-rw-r--r--pkgs/development/python-modules/ofxtools/default.nix4
-rw-r--r--pkgs/development/python-modules/olefile/default.nix4
-rw-r--r--pkgs/development/python-modules/omegaconf/default.nix4
-rw-r--r--pkgs/development/python-modules/onkyo-eiscp/default.nix4
-rw-r--r--pkgs/development/python-modules/openant/default.nix4
-rw-r--r--pkgs/development/python-modules/openidc-client/default.nix4
-rw-r--r--pkgs/development/python-modules/openrazer/common.nix4
-rw-r--r--pkgs/development/python-modules/openrazer/daemon.nix5
-rw-r--r--pkgs/development/python-modules/openrazer/pylib.nix5
-rw-r--r--pkgs/development/python-modules/opuslib/default.nix4
-rw-r--r--pkgs/development/python-modules/ordereddict/default.nix4
-rw-r--r--pkgs/development/python-modules/orderedmultidict/default.nix4
-rw-r--r--pkgs/development/python-modules/orderedset/default.nix4
-rw-r--r--pkgs/development/python-modules/osc/default.nix4
-rwxr-xr-xpkgs/development/python-modules/osmnx/default.nix4
-rw-r--r--pkgs/development/python-modules/ovito/default.nix4
-rw-r--r--pkgs/development/python-modules/packaging/2.nix4
-rw-r--r--pkgs/development/python-modules/packaging/default.nix4
-rw-r--r--pkgs/development/python-modules/pagelabels/default.nix4
-rw-r--r--pkgs/development/python-modules/pagerduty/default.nix4
-rw-r--r--pkgs/development/python-modules/palettable/default.nix4
-rw-r--r--pkgs/development/python-modules/pamela/default.nix4
-rw-r--r--pkgs/development/python-modules/pamqp/default.nix4
-rw-r--r--pkgs/development/python-modules/pandas-datareader/default.nix4
-rw-r--r--pkgs/development/python-modules/pandas/default.nix4
-rw-r--r--pkgs/development/python-modules/pandocfilters/default.nix4
-rw-r--r--pkgs/development/python-modules/paperspace/default.nix4
-rw-r--r--pkgs/development/python-modules/parameterized/default.nix4
-rw-r--r--pkgs/development/python-modules/paramz/default.nix4
-rw-r--r--pkgs/development/python-modules/parse-type/default.nix4
-rw-r--r--pkgs/development/python-modules/parse/default.nix4
-rw-r--r--pkgs/development/python-modules/parsedatetime/default.nix4
-rw-r--r--pkgs/development/python-modules/parsimonious/default.nix4
-rw-r--r--pkgs/development/python-modules/paste/default.nix4
-rw-r--r--pkgs/development/python-modules/pastedeploy/default.nix4
-rw-r--r--pkgs/development/python-modules/pastescript/default.nix4
-rw-r--r--pkgs/development/python-modules/patator/default.nix4
-rw-r--r--pkgs/development/python-modules/patch-ng/default.nix4
-rw-r--r--pkgs/development/python-modules/patch/default.nix4
-rw-r--r--pkgs/development/python-modules/path-and-address/default.nix4
-rw-r--r--pkgs/development/python-modules/pathos/default.nix4
-rw-r--r--pkgs/development/python-modules/pathtools/default.nix4
-rw-r--r--pkgs/development/python-modules/paver/default.nix4
-rw-r--r--pkgs/development/python-modules/pbkdf2/default.nix4
-rw-r--r--pkgs/development/python-modules/pc-ble-driver-py/default.nix4
-rw-r--r--pkgs/development/python-modules/pcpp/default.nix4
-rw-r--r--pkgs/development/python-modules/pdf2image/default.nix4
-rw-r--r--pkgs/development/python-modules/pdfkit/default.nix4
-rw-r--r--pkgs/development/python-modules/pdfminer_six/default.nix4
-rw-r--r--pkgs/development/python-modules/pdfposter/default.nix4
-rw-r--r--pkgs/development/python-modules/pdfrw/default.nix4
-rw-r--r--pkgs/development/python-modules/pdfx/default.nix4
-rw-r--r--pkgs/development/python-modules/pecan/default.nix4
-rw-r--r--pkgs/development/python-modules/pelican/default.nix4
-rw-r--r--pkgs/development/python-modules/pep257/default.nix4
-rw-r--r--pkgs/development/python-modules/pep8/default.nix4
-rw-r--r--pkgs/development/python-modules/peppercorn/default.nix4
-rw-r--r--pkgs/development/python-modules/persisting-theory/default.nix4
-rw-r--r--pkgs/development/python-modules/pex/default.nix4
-rw-r--r--pkgs/development/python-modules/pexif/default.nix4
-rw-r--r--pkgs/development/python-modules/pg8000/1_12.nix4
-rw-r--r--pkgs/development/python-modules/pg8000/default.nix4
-rw-r--r--pkgs/development/python-modules/pgpdump/default.nix4
-rw-r--r--pkgs/development/python-modules/pgsanity/default.nix4
-rw-r--r--pkgs/development/python-modules/pgspecial/default.nix4
-rw-r--r--pkgs/development/python-modules/phe/default.nix4
-rw-r--r--pkgs/development/python-modules/phonopy/default.nix4
-rw-r--r--pkgs/development/python-modules/phx-class-registry/default.nix4
-rw-r--r--pkgs/development/python-modules/pickleshare/default.nix4
-rw-r--r--pkgs/development/python-modules/pid/default.nix4
-rw-r--r--pkgs/development/python-modules/piep/default.nix4
-rw-r--r--pkgs/development/python-modules/piexif/default.nix4
-rw-r--r--pkgs/development/python-modules/pika-pool/default.nix4
-rw-r--r--pkgs/development/python-modules/pika/default.nix4
-rw-r--r--pkgs/development/python-modules/pikepdf/default.nix4
-rw-r--r--pkgs/development/python-modules/pilkit/default.nix4
-rw-r--r--pkgs/development/python-modules/pillow/6.nix4
-rw-r--r--pkgs/development/python-modules/pillow/default.nix4
-rw-r--r--pkgs/development/python-modules/pillowfight/default.nix4
-rw-r--r--pkgs/development/python-modules/pims/default.nix4
-rw-r--r--pkgs/development/python-modules/pip-tools/default.nix4
-rw-r--r--pkgs/development/python-modules/pivy/default.nix4
-rw-r--r--pkgs/development/python-modules/pkginfo/default.nix4
-rw-r--r--pkgs/development/python-modules/pkuseg/default.nix4
-rw-r--r--pkgs/development/python-modules/plac/default.nix4
-rw-r--r--pkgs/development/python-modules/pluginbase/default.nix4
-rw-r--r--pkgs/development/python-modules/plyvel/default.nix4
-rw-r--r--pkgs/development/python-modules/pocket/default.nix4
-rw-r--r--pkgs/development/python-modules/polib/default.nix4
-rw-r--r--pkgs/development/python-modules/pomegranate/default.nix4
-rw-r--r--pkgs/development/python-modules/pony/default.nix4
-rw-r--r--pkgs/development/python-modules/pooch/default.nix4
-rw-r--r--pkgs/development/python-modules/poppler-qt5/default.nix4
-rw-r--r--pkgs/development/python-modules/portend/default.nix4
-rw-r--r--pkgs/development/python-modules/posix_ipc/default.nix4
-rw-r--r--pkgs/development/python-modules/potr/default.nix4
-rw-r--r--pkgs/development/python-modules/power/default.nix4
-rw-r--r--pkgs/development/python-modules/pox/default.nix4
-rw-r--r--pkgs/development/python-modules/poyo/default.nix4
-rw-r--r--pkgs/development/python-modules/ppft/default.nix4
-rw-r--r--pkgs/development/python-modules/ppscore/default.nix4
-rw-r--r--pkgs/development/python-modules/praw/6.3.nix4
-rw-r--r--pkgs/development/python-modules/praw/default.nix4
-rw-r--r--pkgs/development/python-modules/prawcore/default.nix4
-rw-r--r--pkgs/development/python-modules/preggy/default.nix4
-rw-r--r--pkgs/development/python-modules/preshed/default.nix4
-rw-r--r--pkgs/development/python-modules/pretend/default.nix4
-rw-r--r--pkgs/development/python-modules/prettytable/1.nix4
-rw-r--r--pkgs/development/python-modules/prettytable/default.nix4
-rw-r--r--pkgs/development/python-modules/proboscis/default.nix4
-rw-r--r--pkgs/development/python-modules/process-tests/default.nix4
-rw-r--r--pkgs/development/python-modules/proglog/default.nix4
-rw-r--r--pkgs/development/python-modules/progress/default.nix4
-rw-r--r--pkgs/development/python-modules/progressbar/default.nix4
-rw-r--r--pkgs/development/python-modules/progressbar2/default.nix4
-rw-r--r--pkgs/development/python-modules/progressbar231/default.nix4
-rw-r--r--pkgs/development/python-modules/progressbar33/default.nix4
-rw-r--r--pkgs/development/python-modules/proto-plus/default.nix4
-rw-r--r--pkgs/development/python-modules/prov/default.nix4
-rw-r--r--pkgs/development/python-modules/ptable/default.nix4
-rw-r--r--pkgs/development/python-modules/ptest/default.nix4
-rw-r--r--pkgs/development/python-modules/ptpython/default.nix2
-rw-r--r--pkgs/development/python-modules/publicsuffix/default.nix4
-rw-r--r--pkgs/development/python-modules/publicsuffix2/default.nix4
-rw-r--r--pkgs/development/python-modules/pudb/default.nix4
-rw-r--r--pkgs/development/python-modules/pulp/default.nix4
-rw-r--r--pkgs/development/python-modules/pure-pcapy3/default.nix4
-rw-r--r--pkgs/development/python-modules/purepng/default.nix4
-rw-r--r--pkgs/development/python-modules/pushover/default.nix4
-rw-r--r--pkgs/development/python-modules/pvlib/default.nix4
-rw-r--r--pkgs/development/python-modules/pweave/default.nix4
-rw-r--r--pkgs/development/python-modules/pwntools/default.nix4
-rw-r--r--pkgs/development/python-modules/pxml/default.nix4
-rw-r--r--pkgs/development/python-modules/py-radix/default.nix4
-rw-r--r--pkgs/development/python-modules/py/default.nix4
-rw-r--r--pkgs/development/python-modules/py3buddy/default.nix4
-rw-r--r--pkgs/development/python-modules/py3dns/default.nix4
-rw-r--r--pkgs/development/python-modules/py3status/default.nix4
-rw-r--r--pkgs/development/python-modules/py4j/default.nix4
-rw-r--r--pkgs/development/python-modules/pyGithub/default.nix4
-rw-r--r--pkgs/development/python-modules/py_scrypt/default.nix4
-rw-r--r--pkgs/development/python-modules/pyacoustid/default.nix4
-rw-r--r--pkgs/development/python-modules/pyalgotrade/default.nix4
-rw-r--r--pkgs/development/python-modules/pyamf/default.nix4
-rw-r--r--pkgs/development/python-modules/pyannotate/default.nix4
-rw-r--r--pkgs/development/python-modules/pyasn1-modules/default.nix4
-rw-r--r--pkgs/development/python-modules/pyasn1/default.nix4
-rw-r--r--pkgs/development/python-modules/pyatspi/default.nix4
-rw-r--r--pkgs/development/python-modules/pyatv/default.nix4
-rw-r--r--pkgs/development/python-modules/pyaudio/default.nix4
-rw-r--r--pkgs/development/python-modules/pyaxmlparser/default.nix4
-rw-r--r--pkgs/development/python-modules/pybase64/default.nix4
-rw-r--r--pkgs/development/python-modules/pybindgen/default.nix4
-rw-r--r--pkgs/development/python-modules/pyblock/default.nix4
-rw-r--r--pkgs/development/python-modules/pyblosxom/default.nix4
-rw-r--r--pkgs/development/python-modules/pybluez/default.nix4
-rw-r--r--pkgs/development/python-modules/pybotvac/default.nix4
-rw-r--r--pkgs/development/python-modules/pybrowserid/default.nix4
-rw-r--r--pkgs/development/python-modules/pycallgraph/default.nix4
-rw-r--r--pkgs/development/python-modules/pycangjie/default.nix4
-rw-r--r--pkgs/development/python-modules/pycapnp/default.nix4
-rw-r--r--pkgs/development/python-modules/pycarddav/default.nix4
-rw-r--r--pkgs/development/python-modules/pycares/default.nix4
-rw-r--r--pkgs/development/python-modules/pycdio/default.nix4
-rw-r--r--pkgs/development/python-modules/pychart/default.nix4
-rw-r--r--pkgs/development/python-modules/pychef/default.nix4
-rw-r--r--pkgs/development/python-modules/pyclipper/default.nix4
-rw-r--r--pkgs/development/python-modules/pycm/default.nix4
-rw-r--r--pkgs/development/python-modules/pycoin/default.nix4
-rw-r--r--pkgs/development/python-modules/pycollada/default.nix4
-rw-r--r--pkgs/development/python-modules/pycontracts/default.nix4
-rw-r--r--pkgs/development/python-modules/pycountry/default.nix4
-rw-r--r--pkgs/development/python-modules/pycparser/default.nix4
-rw-r--r--pkgs/development/python-modules/pycryptopp/default.nix4
-rw-r--r--pkgs/development/python-modules/pycuda/default.nix4
-rw-r--r--pkgs/development/python-modules/pydenticon/default.nix4
-rw-r--r--pkgs/development/python-modules/pydicom/default.nix4
-rw-r--r--pkgs/development/python-modules/pydispatcher/default.nix4
-rw-r--r--pkgs/development/python-modules/pydns/default.nix4
-rw-r--r--pkgs/development/python-modules/pydotplus/default.nix4
-rw-r--r--pkgs/development/python-modules/pydub/default.nix4
-rw-r--r--pkgs/development/python-modules/pyechonest/default.nix4
-rw-r--r--pkgs/development/python-modules/pyelftools/default.nix4
-rw-r--r--pkgs/development/python-modules/pyemd/default.nix4
-rw-r--r--pkgs/development/python-modules/pyenchant/default.nix4
-rw-r--r--pkgs/development/python-modules/pyexcelerator/default.nix4
-rw-r--r--pkgs/development/python-modules/pyext/default.nix4
-rw-r--r--pkgs/development/python-modules/pyface/default.nix4
-rw-r--r--pkgs/development/python-modules/pyfakefs/default.nix4
-rw-r--r--pkgs/development/python-modules/pyfantom/default.nix4
-rw-r--r--pkgs/development/python-modules/pyfftw/default.nix4
-rw-r--r--pkgs/development/python-modules/pyfiglet/default.nix4
-rw-r--r--pkgs/development/python-modules/pyflakes/default.nix4
-rw-r--r--pkgs/development/python-modules/pyfribidi/default.nix4
-rw-r--r--pkgs/development/python-modules/pyftpdlib/default.nix4
-rw-r--r--pkgs/development/python-modules/pyfttt/default.nix4
-rw-r--r--pkgs/development/python-modules/pygal/default.nix4
-rw-r--r--pkgs/development/python-modules/pygame_sdl2/default.nix4
-rw-r--r--pkgs/development/python-modules/pygccxml/default.nix4
-rw-r--r--pkgs/development/python-modules/pygeoip/default.nix4
-rw-r--r--pkgs/development/python-modules/pyglet/default.nix4
-rw-r--r--pkgs/development/python-modules/pygments-better-html/default.nix4
-rw-r--r--pkgs/development/python-modules/pygments-markdown-lexer/default.nix4
-rw-r--r--pkgs/development/python-modules/pygmt/default.nix4
-rw-r--r--pkgs/development/python-modules/pygobject/3.36.nix4
-rw-r--r--pkgs/development/python-modules/pygobject/3.nix4
-rw-r--r--pkgs/development/python-modules/pygpgme/default.nix4
-rw-r--r--pkgs/development/python-modules/pygraphviz/default.nix4
-rw-r--r--pkgs/development/python-modules/pygreat/default.nix4
-rw-r--r--pkgs/development/python-modules/pygtk/default.nix4
-rw-r--r--pkgs/development/python-modules/pyhamcrest/1.nix4
-rw-r--r--pkgs/development/python-modules/pyhamcrest/default.nix4
-rw-r--r--pkgs/development/python-modules/pyhomematic/default.nix4
-rw-r--r--pkgs/development/python-modules/pyicu/default.nix4
-rw-r--r--pkgs/development/python-modules/pyinotify/default.nix4
-rw-r--r--pkgs/development/python-modules/pyinputevent/default.nix4
-rw-r--r--pkgs/development/python-modules/pykdtree/default.nix4
-rw-r--r--pkgs/development/python-modules/pykerberos/default.nix4
-rw-r--r--pkgs/development/python-modules/pykickstart/default.nix4
-rw-r--r--pkgs/development/python-modules/pylast/default.nix4
-rw-r--r--pkgs/development/python-modules/pylibconfig2/default.nix4
-rw-r--r--pkgs/development/python-modules/pyliblo/default.nix4
-rw-r--r--pkgs/development/python-modules/pylibmc/default.nix4
-rw-r--r--pkgs/development/python-modules/pymaging/default.nix4
-rw-r--r--pkgs/development/python-modules/pymaging_png/default.nix4
-rw-r--r--pkgs/development/python-modules/pymatgen/default.nix4
-rw-r--r--pkgs/development/python-modules/pymediainfo/default.nix4
-rw-r--r--pkgs/development/python-modules/pymeeus/default.nix4
-rw-r--r--pkgs/development/python-modules/pymemoize/default.nix4
-rw-r--r--pkgs/development/python-modules/pymetar/default.nix4
-rw-r--r--pkgs/development/python-modules/pymetno/default.nix4
-rw-r--r--pkgs/development/python-modules/pympler/default.nix4
-rw-r--r--pkgs/development/python-modules/pymsgbox/default.nix4
-rw-r--r--pkgs/development/python-modules/pymupdf/default.nix4
-rw-r--r--pkgs/development/python-modules/pymysqlsa/default.nix4
-rw-r--r--pkgs/development/python-modules/pynac/default.nix4
-rw-r--r--pkgs/development/python-modules/pynacl/default.nix4
-rw-r--r--pkgs/development/python-modules/pync/default.nix4
-rw-r--r--pkgs/development/python-modules/pynest2d/default.nix4
-rw-r--r--pkgs/development/python-modules/pynisher/default.nix4
-rw-r--r--pkgs/development/python-modules/pynput/default.nix4
-rw-r--r--pkgs/development/python-modules/pynzb/default.nix4
-rw-r--r--pkgs/development/python-modules/pyodbc/default.nix4
-rw-r--r--pkgs/development/python-modules/pyopencl/default.nix4
-rw-r--r--pkgs/development/python-modules/pyopengl/default.nix4
-rw-r--r--pkgs/development/python-modules/pypandoc/default.nix4
-rw-r--r--pkgs/development/python-modules/pyparted/default.nix4
-rw-r--r--pkgs/development/python-modules/pypdf/default.nix4
-rw-r--r--pkgs/development/python-modules/pypdf2/default.nix4
-rw-r--r--pkgs/development/python-modules/pypeg2/default.nix4
-rw-r--r--pkgs/development/python-modules/pyphen/default.nix4
-rw-r--r--pkgs/development/python-modules/pypillowfight/default.nix4
-rw-r--r--pkgs/development/python-modules/pyplatec/default.nix4
-rw-r--r--pkgs/development/python-modules/pypoppler/default.nix4
-rw-r--r--pkgs/development/python-modules/pyprind/default.nix4
-rw-r--r--pkgs/development/python-modules/pyptlib/default.nix4
-rw-r--r--pkgs/development/python-modules/pypugjs/default.nix4
-rw-r--r--pkgs/development/python-modules/pyqtgraph/default.nix4
-rw-r--r--pkgs/development/python-modules/pyquery/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid_beaker/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid_chameleon/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid_exclog/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid_hawkauth/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid_jinja2/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid_mako/default.nix4
-rw-r--r--pkgs/development/python-modules/pyramid_multiauth/default.nix4
-rw-r--r--pkgs/development/python-modules/pyreport/default.nix4
-rw-r--r--pkgs/development/python-modules/pyres/default.nix4
-rw-r--r--pkgs/development/python-modules/pyrfc3339/default.nix4
-rw-r--r--pkgs/development/python-modules/pyro4/default.nix2
-rw-r--r--pkgs/development/python-modules/pyroma/default.nix4
-rw-r--r--pkgs/development/python-modules/pyroute2/default.nix4
-rw-r--r--pkgs/development/python-modules/pyrr/default.nix4
-rw-r--r--pkgs/development/python-modules/pyrsistent/default.nix4
-rw-r--r--pkgs/development/python-modules/pyrss2gen/default.nix4
-rw-r--r--pkgs/development/python-modules/pysaml2/default.nix4
-rw-r--r--pkgs/development/python-modules/pyscss/default.nix4
-rw-r--r--pkgs/development/python-modules/pysendfile/default.nix4
-rw-r--r--pkgs/development/python-modules/pysensors/default.nix4
-rw-r--r--pkgs/development/python-modules/pyserial-asyncio/default.nix4
-rw-r--r--pkgs/development/python-modules/pysftp/default.nix4
-rw-r--r--pkgs/development/python-modules/pyshp/default.nix4
-rw-r--r--pkgs/development/python-modules/pyside2-tools/default.nix4
-rw-r--r--pkgs/development/python-modules/pyside2/default.nix4
-rw-r--r--pkgs/development/python-modules/pysigset/default.nix4
-rw-r--r--pkgs/development/python-modules/pysmbc/default.nix4
-rw-r--r--pkgs/development/python-modules/pysmf/default.nix4
-rw-r--r--pkgs/development/python-modules/pysmi/default.nix4
-rw-r--r--pkgs/development/python-modules/pysnmp/default.nix4
-rw-r--r--pkgs/development/python-modules/pysocks/default.nix4
-rw-r--r--pkgs/development/python-modules/pyspark/default.nix4
-rw-r--r--pkgs/development/python-modules/pyspice/default.nix4
-rw-r--r--pkgs/development/python-modules/pyspotify/default.nix4
-rw-r--r--pkgs/development/python-modules/pyspread/default.nix4
-rw-r--r--pkgs/development/python-modules/pysqlite/default.nix4
-rw-r--r--pkgs/development/python-modules/pysqueezebox/default.nix4
-rw-r--r--pkgs/development/python-modules/pysrt/default.nix4
-rw-r--r--pkgs/development/python-modules/pyssim/default.nix4
-rw-r--r--pkgs/development/python-modules/pystache/default.nix4
-rw-r--r--pkgs/development/python-modules/pystemd/default.nix4
-rw-r--r--pkgs/development/python-modules/pystemmer/default.nix4
-rw-r--r--pkgs/development/python-modules/pysvn/default.nix2
-rw-r--r--pkgs/development/python-modules/pytabix/default.nix4
-rw-r--r--pkgs/development/python-modules/pytado/default.nix4
-rw-r--r--pkgs/development/python-modules/pyte/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-aiohttp/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-annotate/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-ansible/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-asyncio/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-bdd/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-catchlog/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-celery/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-check/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-cov/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-datadir/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-datafiles/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-dependency/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-django/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-factoryboy/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-fixture-config/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-flakes/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-flask/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-helpers-namespace/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-html/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-metadata/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-mpl/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-pep257/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-quickcheck/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-raisesregexp/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-random-order/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-relaxed/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-rerunfailures/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-server-fixtures/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-shutil/default.nix2
-rw-r--r--pkgs/development/python-modules/pytest-subtesthack/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-virtualenv/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest-xdist/1.nix4
-rw-r--r--pkgs/development/python-modules/pytest-xdist/default.nix4
-rw-r--r--pkgs/development/python-modules/pytest/4.nix4
-rw-r--r--pkgs/development/python-modules/pytest/5.nix4
-rw-r--r--pkgs/development/python-modules/pytest/default.nix4
-rw-r--r--pkgs/development/python-modules/pytestcache/default.nix4
-rw-r--r--pkgs/development/python-modules/pytestrunner/default.nix4
-rw-r--r--pkgs/development/python-modules/python-doi/default.nix4
-rw-r--r--pkgs/development/python-modules/python-editor/default.nix4
-rw-r--r--pkgs/development/python-modules/python-efl/default.nix4
-rw-r--r--pkgs/development/python-modules/python-engineio/default.nix4
-rw-r--r--pkgs/development/python-modules/python-etcd/default.nix4
-rw-r--r--pkgs/development/python-modules/python-forecastio/default.nix4
-rw-r--r--pkgs/development/python-modules/python-frontmatter/default.nix2
-rw-r--r--pkgs/development/python-modules/python-gitlab/default.nix4
-rw-r--r--pkgs/development/python-modules/python-gnupg/default.nix4
-rw-r--r--pkgs/development/python-modules/python-hosts/default.nix4
-rw-r--r--pkgs/development/python-modules/python-jose/default.nix4
-rw-r--r--pkgs/development/python-modules/python-json-logger/default.nix4
-rw-r--r--pkgs/development/python-modules/python-jsonrpc-server/default.nix4
-rw-r--r--pkgs/development/python-modules/python-language-server/default.nix4
-rw-r--r--pkgs/development/python-modules/python-ldap-test/default.nix4
-rw-r--r--pkgs/development/python-modules/python-levenshtein/default.nix4
-rw-r--r--pkgs/development/python-modules/python-ly/default.nix4
-rw-r--r--pkgs/development/python-modules/python-lzf/default.nix4
-rw-r--r--pkgs/development/python-modules/python-mapnik/default.nix4
-rw-r--r--pkgs/development/python-modules/python-miio/default.nix4
-rw-r--r--pkgs/development/python-modules/python-mnist/default.nix4
-rw-r--r--pkgs/development/python-modules/python-nomad/default.nix4
-rw-r--r--pkgs/development/python-modules/python-otr/default.nix4
-rw-r--r--pkgs/development/python-modules/python-packer/default.nix4
-rw-r--r--pkgs/development/python-modules/python-pipedrive/default.nix4
-rw-r--r--pkgs/development/python-modules/python-ptrace/default.nix4
-rw-r--r--pkgs/development/python-modules/python-rapidjson/default.nix4
-rw-r--r--pkgs/development/python-modules/python-redis-lock/default.nix4
-rw-r--r--pkgs/development/python-modules/python-simple-hipchat/default.nix4
-rw-r--r--pkgs/development/python-modules/python-slugify/default.nix4
-rw-r--r--pkgs/development/python-modules/python-socketio/default.nix4
-rw-r--r--pkgs/development/python-modules/python-telegram-bot/default.nix4
-rw-r--r--pkgs/development/python-modules/python-twitter/default.nix4
-rw-r--r--pkgs/development/python-modules/python-u2flib-host/default.nix4
-rw-r--r--pkgs/development/python-modules/python-uinput/default.nix4
-rw-r--r--pkgs/development/python-modules/python-unshare/default.nix4
-rw-r--r--pkgs/development/python-modules/python-vipaccess/default.nix4
-rw-r--r--pkgs/development/python-modules/python-wifi/default.nix4
-rw-r--r--pkgs/development/python-modules/python-xmp-toolkit/default.nix4
-rw-r--r--pkgs/development/python-modules/python2-pythondialog/default.nix4
-rw-r--r--pkgs/development/python-modules/python3-openid/default.nix4
-rw-r--r--pkgs/development/python-modules/python_fedora/default.nix4
-rw-r--r--pkgs/development/python-modules/python_keyczar/default.nix4
-rw-r--r--pkgs/development/python-modules/python_mimeparse/default.nix4
-rw-r--r--pkgs/development/python-modules/python_openzwave/default.nix4
-rw-r--r--pkgs/development/python-modules/python_statsd/default.nix4
-rw-r--r--pkgs/development/python-modules/pythondialog/default.nix4
-rw-r--r--pkgs/development/python-modules/pythonirclib/default.nix4
-rw-r--r--pkgs/development/python-modules/pythonix/default.nix4
-rw-r--r--pkgs/development/python-modules/pythonocc-core/default.nix4
-rw-r--r--pkgs/development/python-modules/pytidylib/default.nix4
-rw-r--r--pkgs/development/python-modules/pytimeparse/default.nix4
-rw-r--r--pkgs/development/python-modules/pytoml/default.nix4
-rw-r--r--pkgs/development/python-modules/pytorch/bin.nix4
-rw-r--r--pkgs/development/python-modules/pytrends/default.nix4
-rw-r--r--pkgs/development/python-modules/pytricia/default.nix4
-rw-r--r--pkgs/development/python-modules/pytun/default.nix4
-rw-r--r--pkgs/development/python-modules/pytzdata/default.nix4
-rw-r--r--pkgs/development/python-modules/pyunifi/default.nix4
-rw-r--r--pkgs/development/python-modules/pyupdate/default.nix4
-rw-r--r--pkgs/development/python-modules/pyusb/default.nix4
-rw-r--r--pkgs/development/python-modules/pyutil/default.nix4
-rw-r--r--pkgs/development/python-modules/pyuv/default.nix4
-rw-r--r--pkgs/development/python-modules/pyvoro/default.nix4
-rw-r--r--pkgs/development/python-modules/pywatchman/default.nix4
-rw-r--r--pkgs/development/python-modules/pywebdav/default.nix4
-rw-r--r--pkgs/development/python-modules/pyx/default.nix4
-rw-r--r--pkgs/development/python-modules/pyzufall/default.nix4
-rw-r--r--pkgs/development/python-modules/qpid-python/default.nix4
-rw-r--r--pkgs/development/python-modules/qrcode/default.nix4
-rw-r--r--pkgs/development/python-modules/qscintilla/default.nix4
-rw-r--r--pkgs/development/python-modules/qserve/default.nix4
-rw-r--r--pkgs/development/python-modules/qtawesome/default.nix4
-rw-r--r--pkgs/development/python-modules/qtpy/default.nix4
-rw-r--r--pkgs/development/python-modules/querystring-parser/default.nix4
-rw-r--r--pkgs/development/python-modules/queuelib/default.nix4
-rw-r--r--pkgs/development/python-modules/r2pipe/default.nix2
-rw-r--r--pkgs/development/python-modules/rabbitpy/default.nix4
-rw-r--r--pkgs/development/python-modules/radicale_infcloud/default.nix4
-rw-r--r--pkgs/development/python-modules/rainbowstream/default.nix4
-rw-r--r--pkgs/development/python-modules/ramlfications/default.nix4
-rw-r--r--pkgs/development/python-modules/random2/default.nix4
-rw-r--r--pkgs/development/python-modules/rarfile/default.nix4
-rw-r--r--pkgs/development/python-modules/ratelimiter/default.nix4
-rw-r--r--pkgs/development/python-modules/rawkit/default.nix4
-rw-r--r--pkgs/development/python-modules/rbtools/default.nix4
-rw-r--r--pkgs/development/python-modules/rcssmin/default.nix4
-rw-r--r--pkgs/development/python-modules/readchar/default.nix4
-rw-r--r--pkgs/development/python-modules/readme/default.nix4
-rw-r--r--pkgs/development/python-modules/rebulk/default.nix4
-rw-r--r--pkgs/development/python-modules/recaptcha_client/default.nix4
-rw-r--r--pkgs/development/python-modules/rednose/default.nix4
-rw-r--r--pkgs/development/python-modules/reedsolo/default.nix4
-rw-r--r--pkgs/development/python-modules/remotecv/default.nix4
-rw-r--r--pkgs/development/python-modules/rencode/default.nix4
-rw-r--r--pkgs/development/python-modules/repeated_test/default.nix4
-rw-r--r--pkgs/development/python-modules/repocheck/default.nix4
-rw-r--r--pkgs/development/python-modules/repoze_lru/default.nix4
-rw-r--r--pkgs/development/python-modules/repoze_sphinx_autointerface/default.nix4
-rw-r--r--pkgs/development/python-modules/repoze_who/default.nix4
-rw-r--r--pkgs/development/python-modules/requests-cache/default.nix4
-rw-r--r--pkgs/development/python-modules/requests-http-signature/default.nix4
-rw-r--r--pkgs/development/python-modules/requests-kerberos/default.nix4
-rw-r--r--pkgs/development/python-modules/requests-oauthlib/default.nix4
-rw-r--r--pkgs/development/python-modules/requests/default.nix4
-rw-r--r--pkgs/development/python-modules/resampy/default.nix4
-rw-r--r--pkgs/development/python-modules/rethinkdb/default.nix4
-rw-r--r--pkgs/development/python-modules/retry_decorator/default.nix4
-rw-r--r--pkgs/development/python-modules/retrying/default.nix4
-rw-r--r--pkgs/development/python-modules/rfc-bibtex/default.nix4
-rw-r--r--pkgs/development/python-modules/rfc3986/default.nix4
-rw-r--r--pkgs/development/python-modules/rfc3987/default.nix4
-rw-r--r--pkgs/development/python-modules/rich/default.nix4
-rw-r--r--pkgs/development/python-modules/rjsmin/default.nix4
-rw-r--r--pkgs/development/python-modules/rl-coach/default.nix2
-rw-r--r--pkgs/development/python-modules/robomachine/default.nix4
-rw-r--r--pkgs/development/python-modules/robot-detection/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework-databaselibrary/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework-requests/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework-ride/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework-selenium2library/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework-seleniumlibrary/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework-sshlibrary/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework-tools/default.nix4
-rw-r--r--pkgs/development/python-modules/robotframework/default.nix4
-rw-r--r--pkgs/development/python-modules/robotstatuschecker/default.nix4
-rw-r--r--pkgs/development/python-modules/robotsuite/default.nix4
-rw-r--r--pkgs/development/python-modules/roku/default.nix4
-rw-r--r--pkgs/development/python-modules/roman/default.nix4
-rw-r--r--pkgs/development/python-modules/rope/default.nix4
-rw-r--r--pkgs/development/python-modules/ropper/default.nix4
-rw-r--r--pkgs/development/python-modules/routes/default.nix4
-rw-r--r--pkgs/development/python-modules/rpdb/default.nix4
-rw-r--r--pkgs/development/python-modules/rpkg/default.nix4
-rw-r--r--pkgs/development/python-modules/rply/default.nix4
-rw-r--r--pkgs/development/python-modules/rpmfluff/default.nix4
-rw-r--r--pkgs/development/python-modules/rpyc/default.nix4
-rw-r--r--pkgs/development/python-modules/rq/default.nix4
-rw-r--r--pkgs/development/python-modules/rsa/4_0.nix4
-rw-r--r--pkgs/development/python-modules/rsa/default.nix4
-rw-r--r--pkgs/development/python-modules/rtslib/default.nix4
-rw-r--r--pkgs/development/python-modules/ruamel_base/default.nix4
-rw-r--r--pkgs/development/python-modules/ruamel_ordereddict/default.nix4
-rw-r--r--pkgs/development/python-modules/ruamel_yaml_clib/default.nix4
-rw-r--r--pkgs/development/python-modules/rubymarshal/default.nix4
-rw-r--r--pkgs/development/python-modules/ruffus/default.nix4
-rw-r--r--pkgs/development/python-modules/runsnakerun/default.nix4
-rw-r--r--pkgs/development/python-modules/s3fs/default.nix4
-rw-r--r--pkgs/development/python-modules/sacremoses/default.nix4
-rw-r--r--pkgs/development/python-modules/safe/default.nix4
-rw-r--r--pkgs/development/python-modules/salmon-mail/default.nix4
-rw-r--r--pkgs/development/python-modules/samplerate/default.nix4
-rw-r--r--pkgs/development/python-modules/sandboxlib/default.nix4
-rw-r--r--pkgs/development/python-modules/sapi-python-client/default.nix4
-rw-r--r--pkgs/development/python-modules/scales/default.nix4
-rw-r--r--pkgs/development/python-modules/schedule/default.nix4
-rw-r--r--pkgs/development/python-modules/schema/default.nix4
-rw-r--r--pkgs/development/python-modules/scikit-bio/default.nix4
-rw-r--r--pkgs/development/python-modules/scikitlearn/0.20.nix4
-rw-r--r--pkgs/development/python-modules/scikitlearn/default.nix2
-rw-r--r--pkgs/development/python-modules/scikits-odes/default.nix2
-rw-r--r--pkgs/development/python-modules/scp/default.nix4
-rw-r--r--pkgs/development/python-modules/scrapy-deltafetch/default.nix4
-rw-r--r--pkgs/development/python-modules/scrapy-fake-useragent/default.nix4
-rw-r--r--pkgs/development/python-modules/scrapy-splash/default.nix4
-rw-r--r--pkgs/development/python-modules/scrapy/default.nix4
-rw-r--r--pkgs/development/python-modules/screeninfo/default.nix4
-rw-r--r--pkgs/development/python-modules/scripttest/default.nix4
-rw-r--r--pkgs/development/python-modules/sdnotify/default.nix4
-rw-r--r--pkgs/development/python-modules/seabreeze/default.nix4
-rw-r--r--pkgs/development/python-modules/seekpath/default.nix4
-rw-r--r--pkgs/development/python-modules/selectors2/default.nix4
-rw-r--r--pkgs/development/python-modules/selectors34/default.nix4
-rw-r--r--pkgs/development/python-modules/semantic/default.nix4
-rw-r--r--pkgs/development/python-modules/semver/default.nix4
-rw-r--r--pkgs/development/python-modules/send2trash/default.nix4
-rw-r--r--pkgs/development/python-modules/sentry-sdk/default.nix4
-rw-r--r--pkgs/development/python-modules/sepaxml/default.nix4
-rw-r--r--pkgs/development/python-modules/seqdiag/default.nix4
-rw-r--r--pkgs/development/python-modules/serpent/default.nix2
-rw-r--r--pkgs/development/python-modules/serversyncstorage/default.nix4
-rw-r--r--pkgs/development/python-modules/setproctitle/default.nix4
-rw-r--r--pkgs/development/python-modules/setuptools-git/default.nix4
-rw-r--r--pkgs/development/python-modules/setuptools-lint/default.nix4
-rw-r--r--pkgs/development/python-modules/setuptools-rust/default.nix4
-rw-r--r--pkgs/development/python-modules/setuptools-scm-git-archive/default.nix4
-rw-r--r--pkgs/development/python-modules/setuptools/44.0.nix2
-rw-r--r--pkgs/development/python-modules/setuptools/default.nix2
-rw-r--r--pkgs/development/python-modules/setuptools_scm/default.nix4
-rw-r--r--pkgs/development/python-modules/setuptoolsdarcs/default.nix4
-rw-r--r--pkgs/development/python-modules/setuptoolstrial/default.nix4
-rw-r--r--pkgs/development/python-modules/sexpdata/default.nix4
-rw-r--r--pkgs/development/python-modules/shap/default.nix4
-rw-r--r--pkgs/development/python-modules/shapely/default.nix4
-rw-r--r--pkgs/development/python-modules/shellingham/default.nix4
-rw-r--r--pkgs/development/python-modules/shiboken2/default.nix4
-rw-r--r--pkgs/development/python-modules/shippai/default.nix4
-rw-r--r--pkgs/development/python-modules/shortuuid/default.nix4
-rw-r--r--pkgs/development/python-modules/should-dsl/default.nix4
-rw-r--r--pkgs/development/python-modules/shouldbe/default.nix4
-rw-r--r--pkgs/development/python-modules/signedjson/default.nix4
-rw-r--r--pkgs/development/python-modules/sigtools/default.nix4
-rw-r--r--pkgs/development/python-modules/simanneal/default.nix4
-rw-r--r--pkgs/development/python-modules/simple-websocket-server/default.nix4
-rw-r--r--pkgs/development/python-modules/simpleai/default.nix4
-rw-r--r--pkgs/development/python-modules/simplebayes/default.nix4
-rw-r--r--pkgs/development/python-modules/simpleparse/default.nix4
-rw-r--r--pkgs/development/python-modules/skein/default.nix2
-rw-r--r--pkgs/development/python-modules/sklearn-deap/default.nix4
-rw-r--r--pkgs/development/python-modules/slackclient/default.nix4
-rw-r--r--pkgs/development/python-modules/sleekxmpp/default.nix4
-rw-r--r--pkgs/development/python-modules/slicer/default.nix4
-rw-r--r--pkgs/development/python-modules/slicerator/default.nix4
-rw-r--r--pkgs/development/python-modules/slob/default.nix4
-rw-r--r--pkgs/development/python-modules/slowaes/default.nix4
-rw-r--r--pkgs/development/python-modules/smartdc/default.nix4
-rw-r--r--pkgs/development/python-modules/smartypants/default.nix4
-rw-r--r--pkgs/development/python-modules/snakeviz/default.nix4
-rw-r--r--pkgs/development/python-modules/snapcast/default.nix4
-rw-r--r--pkgs/development/python-modules/snappergui/default.nix4
-rw-r--r--pkgs/development/python-modules/snowballstemmer/default.nix4
-rw-r--r--pkgs/development/python-modules/socksipy-branch/default.nix4
-rw-r--r--pkgs/development/python-modules/somajo/default.nix4
-rw-r--r--pkgs/development/python-modules/sopel/default.nix4
-rw-r--r--pkgs/development/python-modules/sorl_thumbnail/default.nix4
-rw-r--r--pkgs/development/python-modules/sortedcollections/default.nix4
-rw-r--r--pkgs/development/python-modules/spacy/models.nix2
-rw-r--r--pkgs/development/python-modules/spark_parser/default.nix4
-rw-r--r--pkgs/development/python-modules/sparqlwrapper/default.nix4
-rw-r--r--pkgs/development/python-modules/speaklater/default.nix4
-rw-r--r--pkgs/development/python-modules/spglib/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinx_pypi_upload/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinx_rtd_theme/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-applehelp/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-autoapi/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-blockdiag/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-devhelp/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-htmlhelp/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-jsmath/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-openapi/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-qthelp/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-serializinghtml/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib-spelling/default.nix2
-rw-r--r--pkgs/development/python-modules/sphinxcontrib_httpdomain/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib_newsfeed/default.nix4
-rw-r--r--pkgs/development/python-modules/sphinxcontrib_plantuml/default.nix4
-rw-r--r--pkgs/development/python-modules/spyder-kernels/default.nix4
-rw-r--r--pkgs/development/python-modules/spyder/3.nix4
-rw-r--r--pkgs/development/python-modules/spyder/default.nix4
-rw-r--r--pkgs/development/python-modules/sqlalchemy-imageattach/default.nix4
-rw-r--r--pkgs/development/python-modules/sqlalchemy-migrate/default.nix4
-rw-r--r--pkgs/development/python-modules/sqlite3dbm/default.nix4
-rw-r--r--pkgs/development/python-modules/sqlobject/default.nix4
-rw-r--r--pkgs/development/python-modules/squaremap/default.nix4
-rw-r--r--pkgs/development/python-modules/srptools/default.nix4
-rw-r--r--pkgs/development/python-modules/srsly/default.nix2
-rw-r--r--pkgs/development/python-modules/srvlookup/default.nix4
-rw-r--r--pkgs/development/python-modules/ssdeep/default.nix4
-rw-r--r--pkgs/development/python-modules/ssdp/default.nix4
-rw-r--r--pkgs/development/python-modules/sseclient/default.nix4
-rw-r--r--pkgs/development/python-modules/sslib/default.nix4
-rw-r--r--pkgs/development/python-modules/statsd/default.nix4
-rw-r--r--pkgs/development/python-modules/stompclient/default.nix4
-rw-r--r--pkgs/development/python-modules/strict-rfc3339/default.nix4
-rw-r--r--pkgs/development/python-modules/stringcase/default.nix4
-rw-r--r--pkgs/development/python-modules/subdownloader/default.nix4
-rw-r--r--pkgs/development/python-modules/suds-jurko/default.nix4
-rw-r--r--pkgs/development/python-modules/suds/default.nix4
-rw-r--r--pkgs/development/python-modules/sumo/default.nix4
-rw-r--r--pkgs/development/python-modules/sure/default.nix4
-rw-r--r--pkgs/development/python-modules/survey/default.nix4
-rw-r--r--pkgs/development/python-modules/svg-path/default.nix4
-rw-r--r--pkgs/development/python-modules/svg2tikz/default.nix4
-rw-r--r--pkgs/development/python-modules/swagger-ui-bundle/default.nix4
-rw-r--r--pkgs/development/python-modules/swspotify/default.nix2
-rw-r--r--pkgs/development/python-modules/sybase/default.nix4
-rw-r--r--pkgs/development/python-modules/systemd/default.nix4
-rw-r--r--pkgs/development/python-modules/sysv_ipc/default.nix4
-rw-r--r--pkgs/development/python-modules/tarman/default.nix4
-rw-r--r--pkgs/development/python-modules/taskw/default.nix4
-rw-r--r--pkgs/development/python-modules/tatsu/default.nix4
-rw-r--r--pkgs/development/python-modules/tblib/default.nix4
-rw-r--r--pkgs/development/python-modules/telegram/default.nix4
-rw-r--r--pkgs/development/python-modules/tensorflow-estimator/default.nix4
-rw-r--r--pkgs/development/python-modules/tensorflow/bin.nix2
-rw-r--r--pkgs/development/python-modules/tensorflow/default.nix2
-rw-r--r--pkgs/development/python-modules/termcolor/default.nix4
-rw-r--r--pkgs/development/python-modules/terminaltables/default.nix4
-rw-r--r--pkgs/development/python-modules/testpath/default.nix4
-rw-r--r--pkgs/development/python-modules/testrepository/default.nix4
-rw-r--r--pkgs/development/python-modules/testscenarios/default.nix4
-rw-r--r--pkgs/development/python-modules/thinc/default.nix2
-rw-r--r--pkgs/development/python-modules/threadpool/default.nix4
-rw-r--r--pkgs/development/python-modules/thrift/default.nix4
-rw-r--r--pkgs/development/python-modules/thumborpexif/default.nix4
-rw-r--r--pkgs/development/python-modules/tilestache/default.nix4
-rw-r--r--pkgs/development/python-modules/timelib/default.nix4
-rw-r--r--pkgs/development/python-modules/timeout-decorator/default.nix4
-rw-r--r--pkgs/development/python-modules/tissue/default.nix4
-rw-r--r--pkgs/development/python-modules/tld/default.nix4
-rw-r--r--pkgs/development/python-modules/tlsh/default.nix4
-rw-r--r--pkgs/development/python-modules/tlslite-ng/default.nix4
-rw-r--r--pkgs/development/python-modules/tlslite/default.nix4
-rw-r--r--pkgs/development/python-modules/toggl-cli/default.nix4
-rw-r--r--pkgs/development/python-modules/tokenizers/default.nix4
-rw-r--r--pkgs/development/python-modules/tokenlib/default.nix4
-rw-r--r--pkgs/development/python-modules/toml/default.nix4
-rw-r--r--pkgs/development/python-modules/toposort/default.nix4
-rw-r--r--pkgs/development/python-modules/torchvision/default.nix4
-rw-r--r--pkgs/development/python-modules/traceback2/default.nix4
-rw-r--r--pkgs/development/python-modules/tracing/default.nix4
-rw-r--r--pkgs/development/python-modules/trackpy/default.nix4
-rw-r--r--pkgs/development/python-modules/traits/default.nix4
-rw-r--r--pkgs/development/python-modules/transaction/default.nix4
-rw-r--r--pkgs/development/python-modules/transformers/default.nix4
-rw-r--r--pkgs/development/python-modules/transip/default.nix4
-rw-r--r--pkgs/development/python-modules/transitions/default.nix4
-rw-r--r--pkgs/development/python-modules/translationstring/default.nix4
-rw-r--r--pkgs/development/python-modules/transmissionrpc/default.nix4
-rw-r--r--pkgs/development/python-modules/treq/default.nix4
-rw-r--r--pkgs/development/python-modules/trezor_agent/default.nix4
-rw-r--r--pkgs/development/python-modules/trollius/default.nix2
-rw-r--r--pkgs/development/python-modules/trueskill/default.nix4
-rw-r--r--pkgs/development/python-modules/ttystatus/default.nix4
-rw-r--r--pkgs/development/python-modules/tvdb_api/default.nix4
-rw-r--r--pkgs/development/python-modules/tvnamer/default.nix4
-rw-r--r--pkgs/development/python-modules/twiggy/default.nix4
-rw-r--r--pkgs/development/python-modules/twilio/default.nix4
-rw-r--r--pkgs/development/python-modules/twisted/default.nix4
-rw-r--r--pkgs/development/python-modules/twitter-common-collections/default.nix4
-rw-r--r--pkgs/development/python-modules/twitter-common-confluence/default.nix4
-rw-r--r--pkgs/development/python-modules/twitter-common-dirutil/default.nix4
-rw-r--r--pkgs/development/python-modules/twitter-common-lang/default.nix4
-rw-r--r--pkgs/development/python-modules/twitter-common-log/default.nix4
-rw-r--r--pkgs/development/python-modules/twitter-common-options/default.nix4
-rw-r--r--pkgs/development/python-modules/twitter/default.nix4
-rw-r--r--pkgs/development/python-modules/txaio/default.nix4
-rw-r--r--pkgs/development/python-modules/txamqp/default.nix4
-rw-r--r--pkgs/development/python-modules/txdbus/default.nix4
-rw-r--r--pkgs/development/python-modules/txgithub/default.nix4
-rw-r--r--pkgs/development/python-modules/txrequests/default.nix4
-rw-r--r--pkgs/development/python-modules/typeguard/default.nix4
-rw-r--r--pkgs/development/python-modules/typogrify/default.nix4
-rw-r--r--pkgs/development/python-modules/tzlocal/default.nix4
-rw-r--r--pkgs/development/python-modules/ua-parser/default.nix4
-rw-r--r--pkgs/development/python-modules/ujson/2.nix4
-rw-r--r--pkgs/development/python-modules/ujson/default.nix4
-rw-r--r--pkgs/development/python-modules/umalqurra/default.nix4
-rw-r--r--pkgs/development/python-modules/umemcache/default.nix4
-rw-r--r--pkgs/development/python-modules/uncertainties/default.nix4
-rw-r--r--pkgs/development/python-modules/uncompyle6/default.nix4
-rw-r--r--pkgs/development/python-modules/unicode-slugify/default.nix4
-rw-r--r--pkgs/development/python-modules/unicodecsv/default.nix4
-rw-r--r--pkgs/development/python-modules/unicorn/default.nix4
-rw-r--r--pkgs/development/python-modules/unidecode/default.nix4
-rw-r--r--pkgs/development/python-modules/unifi/default.nix4
-rw-r--r--pkgs/development/python-modules/unittest2/default.nix4
-rw-r--r--pkgs/development/python-modules/unpaddedbase64/default.nix4
-rw-r--r--pkgs/development/python-modules/upass/default.nix4
-rw-r--r--pkgs/development/python-modules/update_checker/default.nix4
-rw-r--r--pkgs/development/python-modules/uproot3-methods/default.nix4
-rw-r--r--pkgs/development/python-modules/uptime/default.nix4
-rw-r--r--pkgs/development/python-modules/uranium/default.nix4
-rw-r--r--pkgs/development/python-modules/uritools/default.nix4
-rw-r--r--pkgs/development/python-modules/urlgrabber/default.nix4
-rw-r--r--pkgs/development/python-modules/urllib3/default.nix4
-rw-r--r--pkgs/development/python-modules/urwid/default.nix4
-rw-r--r--pkgs/development/python-modules/urwidtrees/default.nix4
-rw-r--r--pkgs/development/python-modules/usbtmc/default.nix4
-rw-r--r--pkgs/development/python-modules/user-agents/default.nix4
-rw-r--r--pkgs/development/python-modules/validate-email/default.nix4
-rw-r--r--pkgs/development/python-modules/validictory/default.nix4
-rw-r--r--pkgs/development/python-modules/vcversioner/default.nix4
-rw-r--r--pkgs/development/python-modules/vdf/default.nix4
-rw-r--r--pkgs/development/python-modules/vdirsyncer/default.nix4
-rw-r--r--pkgs/development/python-modules/vega/default.nix4
-rw-r--r--pkgs/development/python-modules/venusian/default.nix4
-rw-r--r--pkgs/development/python-modules/versioneer/default.nix4
-rw-r--r--pkgs/development/python-modules/versiontools/default.nix4
-rw-r--r--pkgs/development/python-modules/veryprettytable/default.nix4
-rw-r--r--pkgs/development/python-modules/vidstab/default.nix4
-rw-r--r--pkgs/development/python-modules/vine/default.nix4
-rw-r--r--pkgs/development/python-modules/virtualenv-clone/default.nix4
-rw-r--r--pkgs/development/python-modules/virtualenvwrapper/default.nix4
-rw-r--r--pkgs/development/python-modules/vmprof/default.nix4
-rw-r--r--pkgs/development/python-modules/vncdo/default.nix4
-rw-r--r--pkgs/development/python-modules/voluptuous-serialize/default.nix4
-rw-r--r--pkgs/development/python-modules/voluptuous/default.nix4
-rw-r--r--pkgs/development/python-modules/vultr/default.nix4
-rw-r--r--pkgs/development/python-modules/vulture/default.nix4
-rw-r--r--pkgs/development/python-modules/vxi11/default.nix4
-rw-r--r--pkgs/development/python-modules/w3lib/default.nix4
-rw-r--r--pkgs/development/python-modules/waitress/default.nix4
-rw-r--r--pkgs/development/python-modules/wakeonlan/default.nix4
-rw-r--r--pkgs/development/python-modules/warlock/default.nix4
-rw-r--r--pkgs/development/python-modules/wasabi/default.nix4
-rw-r--r--pkgs/development/python-modules/watchdog/default.nix4
-rw-r--r--pkgs/development/python-modules/weasyprint/default.nix4
-rw-r--r--pkgs/development/python-modules/web/default.nix4
-rw-r--r--pkgs/development/python-modules/webapp2/default.nix4
-rw-r--r--pkgs/development/python-modules/webhelpers/default.nix4
-rw-r--r--pkgs/development/python-modules/webob/default.nix4
-rw-r--r--pkgs/development/python-modules/websockify/default.nix4
-rw-r--r--pkgs/development/python-modules/webtest/default.nix4
-rw-r--r--pkgs/development/python-modules/werkzeug/default.nix4
-rw-r--r--pkgs/development/python-modules/whisper/default.nix4
-rw-r--r--pkgs/development/python-modules/whitenoise/default.nix4
-rw-r--r--pkgs/development/python-modules/whoosh/default.nix4
-rw-r--r--pkgs/development/python-modules/willow/default.nix4
-rw-r--r--pkgs/development/python-modules/word2vec/default.nix4
-rw-r--r--pkgs/development/python-modules/wordcloud/default.nix4
-rw-r--r--pkgs/development/python-modules/worldengine/default.nix4
-rw-r--r--pkgs/development/python-modules/wrapio/default.nix4
-rw-r--r--pkgs/development/python-modules/ws4py/default.nix4
-rw-r--r--pkgs/development/python-modules/wsgiproxy/default.nix4
-rw-r--r--pkgs/development/python-modules/wsgiproxy2/default.nix4
-rw-r--r--pkgs/development/python-modules/wtforms/default.nix4
-rw-r--r--pkgs/development/python-modules/x11_hash/default.nix4
-rw-r--r--pkgs/development/python-modules/x256/default.nix4
-rw-r--r--pkgs/development/python-modules/xapp/default.nix4
-rw-r--r--pkgs/development/python-modules/xattr/default.nix4
-rw-r--r--pkgs/development/python-modules/xcaplib/default.nix4
-rw-r--r--pkgs/development/python-modules/xcffib/default.nix4
-rw-r--r--pkgs/development/python-modules/xhtml2pdf/default.nix4
-rw-r--r--pkgs/development/python-modules/xkcdpass/default.nix4
-rw-r--r--pkgs/development/python-modules/xlib/default.nix4
-rw-r--r--pkgs/development/python-modules/xlrd/default.nix4
-rw-r--r--pkgs/development/python-modules/xlsx2csv/default.nix4
-rw-r--r--pkgs/development/python-modules/xml2rfc/default.nix4
-rw-r--r--pkgs/development/python-modules/xmodem/default.nix4
-rw-r--r--pkgs/development/python-modules/xmpppy/default.nix4
-rw-r--r--pkgs/development/python-modules/xvfbwrapper/default.nix4
-rw-r--r--pkgs/development/python-modules/xxhash/default.nix4
-rw-r--r--pkgs/development/python-modules/yamllint/default.nix4
-rw-r--r--pkgs/development/python-modules/yanc/default.nix4
-rw-r--r--pkgs/development/python-modules/yapf/default.nix4
-rw-r--r--pkgs/development/python-modules/yapsy/default.nix4
-rw-r--r--pkgs/development/python-modules/yarl/default.nix2
-rw-r--r--pkgs/development/python-modules/ydiff/default.nix4
-rw-r--r--pkgs/development/python-modules/yowsup/default.nix4
-rw-r--r--pkgs/development/python-modules/z3c-checkversions/default.nix4
-rw-r--r--pkgs/development/python-modules/zake/default.nix4
-rw-r--r--pkgs/development/python-modules/zbaemon/default.nix4
-rw-r--r--pkgs/development/python-modules/zbase32/default.nix4
-rw-r--r--pkgs/development/python-modules/zc_lockfile/default.nix4
-rw-r--r--pkgs/development/python-modules/zconfig/default.nix4
-rw-r--r--pkgs/development/python-modules/zdaemon/default.nix4
-rw-r--r--pkgs/development/python-modules/zerobin/default.nix4
-rw-r--r--pkgs/development/python-modules/zeroc-ice/default.nix4
-rw-r--r--pkgs/development/python-modules/zfec/default.nix4
-rw-r--r--pkgs/development/python-modules/zict/default.nix4
-rw-r--r--pkgs/development/python-modules/zigpy-znp/default.nix4
-rw-r--r--pkgs/development/python-modules/zodb/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_broken/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_component/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_configuration/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_contenttype/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_deprecation/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_dottedname/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_event/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_exceptions/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_filerepresentation/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_i18nmessageid/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_interface/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_lifecycleevent/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_location/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_proxy/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_schema/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_size/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_testing/default.nix4
-rw-r--r--pkgs/development/python-modules/zope_testrunner/default.nix4
-rw-r--r--pkgs/development/python-modules/zstd/default.nix4
-rw-r--r--pkgs/development/ruby-modules/rbenv/default.nix4
-rw-r--r--pkgs/development/tools/ameba/default.nix2
-rw-r--r--pkgs/development/tools/async/default.nix4
-rw-r--r--pkgs/development/tools/cmake-language-server/default.nix4
-rw-r--r--pkgs/development/tools/dapr/cli/default.nix4
-rw-r--r--pkgs/development/tools/dep2nix/default.nix4
-rw-r--r--pkgs/development/tools/dot-http/default.nix4
-rw-r--r--pkgs/development/tools/eclipse-mat/default.nix2
-rw-r--r--pkgs/development/tools/eliot-tree/default.nix4
-rw-r--r--pkgs/development/tools/ginkgo/default.nix4
-rw-r--r--pkgs/development/tools/gir/default.nix4
-rw-r--r--pkgs/development/tools/glade/default.nix4
-rw-r--r--pkgs/development/tools/global-platform-pro/default.nix4
-rw-r--r--pkgs/development/tools/glpaper/default.nix4
-rw-r--r--pkgs/development/tools/go-junit-report/default.nix4
-rw-r--r--pkgs/development/tools/go-migrate/default.nix4
-rw-r--r--pkgs/development/tools/gojsontoyaml/default.nix4
-rw-r--r--pkgs/development/tools/gomplate/default.nix4
-rw-r--r--pkgs/development/tools/gopls/default.nix4
-rw-r--r--pkgs/development/tools/gore/default.nix4
-rw-r--r--pkgs/development/tools/gotestsum/default.nix4
-rw-r--r--pkgs/development/tools/hobbes/default.nix4
-rw-r--r--pkgs/development/tools/jpexs/default.nix4
-rw-r--r--pkgs/development/tools/jtc/default.nix4
-rw-r--r--pkgs/development/tools/kcli/default.nix4
-rw-r--r--pkgs/development/tools/knightos/genkfs/default.nix4
-rw-r--r--pkgs/development/tools/knightos/kcc/default.nix4
-rw-r--r--pkgs/development/tools/knightos/kimg/default.nix4
-rw-r--r--pkgs/development/tools/knightos/kpack/default.nix4
-rw-r--r--pkgs/development/tools/knightos/mkrom/default.nix4
-rw-r--r--pkgs/development/tools/knightos/mktiupgrade/default.nix4
-rw-r--r--pkgs/development/tools/knightos/patchrom/default.nix4
-rw-r--r--pkgs/development/tools/knightos/scas/default.nix4
-rw-r--r--pkgs/development/tools/knightos/z80e/default.nix4
-rw-r--r--pkgs/development/tools/krew/default.nix4
-rw-r--r--pkgs/development/tools/kubeprompt/default.nix4
-rw-r--r--pkgs/development/tools/kubie/default.nix4
-rw-r--r--pkgs/development/tools/lc3tools/default.nix4
-rw-r--r--pkgs/development/tools/metals/default.nix2
-rw-r--r--pkgs/development/tools/micronaut/default.nix4
-rw-r--r--pkgs/development/tools/mmixware/default.nix4
-rw-r--r--pkgs/development/tools/msgpack-tools/default.nix4
-rw-r--r--pkgs/development/tools/nailgun/default.nix4
-rw-r--r--pkgs/development/tools/nemiver/default.nix4
-rw-r--r--pkgs/development/tools/nsis/default.nix4
-rw-r--r--pkgs/development/tools/ocaml/ocamlscript/default.nix4
-rwxr-xr-xpkgs/development/tools/ocaml/opam/opam.nix.pl2
-rw-r--r--pkgs/development/tools/ofono-phonesim/default.nix4
-rw-r--r--pkgs/development/tools/osslsigncode/default.nix4
-rw-r--r--pkgs/development/tools/out-of-tree/default.nix4
-rw-r--r--pkgs/development/tools/packer/default.nix4
-rw-r--r--pkgs/development/tools/packet-cli/default.nix4
-rw-r--r--pkgs/development/tools/parinfer-rust/default.nix4
-rw-r--r--pkgs/development/tools/parse-cli-bin/default.nix4
-rw-r--r--pkgs/development/tools/parsing/antlr/2.7.7.nix4
-rw-r--r--pkgs/development/tools/parsing/antlr/3.4.nix4
-rw-r--r--pkgs/development/tools/parsing/antlr/3.5.nix4
-rw-r--r--pkgs/development/tools/parsing/antlr/4.8.nix6
-rw-r--r--pkgs/development/tools/parsing/bisonc++/default.nix4
-rw-r--r--pkgs/development/tools/parsing/byacc/default.nix4
-rw-r--r--pkgs/development/tools/parsing/flex/2.5.35.nix4
-rw-r--r--pkgs/development/tools/parsing/flex/2.6.1.nix4
-rw-r--r--pkgs/development/tools/parsing/flex/default.nix4
-rw-r--r--pkgs/development/tools/parsing/flexc++/default.nix4
-rw-r--r--pkgs/development/tools/parsing/hammer/default.nix4
-rw-r--r--pkgs/development/tools/parsing/jikespg/default.nix4
-rw-r--r--pkgs/development/tools/parsing/lemon/default.nix4
-rw-r--r--pkgs/development/tools/parsing/peg/default.nix4
-rw-r--r--pkgs/development/tools/parsing/ragel/default.nix4
-rw-r--r--pkgs/development/tools/parsing/re2c/default.nix4
-rw-r--r--pkgs/development/tools/pax-rs/default.nix4
-rw-r--r--pkgs/development/tools/pew/default.nix4
-rw-r--r--pkgs/development/tools/pgformatter/default.nix4
-rw-r--r--pkgs/development/tools/pgloader/default.nix4
-rw-r--r--pkgs/development/tools/phantomjs2/default.nix4
-rw-r--r--pkgs/development/tools/postiats-utilities/default.nix4
-rw-r--r--pkgs/development/tools/profiling/pprof/default.nix4
-rw-r--r--pkgs/development/tools/profiling/sysprof/default.nix2
-rw-r--r--pkgs/development/tools/pxview/default.nix4
-rw-r--r--pkgs/development/tools/py-spy/default.nix4
-rw-r--r--pkgs/development/tools/quicktemplate/default.nix4
-rw-r--r--pkgs/development/tools/rdbtools/default.nix4
-rw-r--r--pkgs/development/tools/rdocker/default.nix4
-rw-r--r--pkgs/development/tools/react-native-debugger/default.nix4
-rw-r--r--pkgs/development/tools/remarshal/default.nix4
-rw-r--r--pkgs/development/tools/renderizer/default.nix4
-rw-r--r--pkgs/development/tools/reno/default.nix4
-rw-r--r--pkgs/development/tools/rep/default.nix4
-rw-r--r--pkgs/development/tools/repository-managers/nexus/default.nix4
-rw-r--r--pkgs/development/tools/richgo/default.nix4
-rw-r--r--pkgs/development/tools/rucksack/default.nix4
-rw-r--r--pkgs/development/tools/run/default.nix4
-rw-r--r--pkgs/development/tools/rund/default.nix2
-rw-r--r--pkgs/development/tools/rust/bindgen/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-asm/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-cache/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-crev/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-fund/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-fuzz/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-generate/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-make/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-raze/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-sweep/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-sync-readme/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-udeps/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-wipe/default.nix4
-rw-r--r--pkgs/development/tools/rust/cargo-xbuild/default.nix4
-rw-r--r--pkgs/development/tools/rust/cbindgen/default.nix4
-rw-r--r--pkgs/development/tools/rust/maturin/default.nix4
-rw-r--r--pkgs/development/tools/rust/racer/default.nix4
-rw-r--r--pkgs/development/tools/rust/racerd/default.nix4
-rw-r--r--pkgs/development/tools/rust/rust-analyzer/generic.nix2
-rw-r--r--pkgs/development/tools/rust/rustup/default.nix2
-rw-r--r--pkgs/development/tools/rust/svd2rust/default.nix4
-rw-r--r--pkgs/development/tools/sassc/default.nix4
-rw-r--r--pkgs/development/tools/scalafix/default.nix4
-rw-r--r--pkgs/development/tools/scalafmt/default.nix4
-rw-r--r--pkgs/development/tools/selenium/chromedriver/default.nix4
-rw-r--r--pkgs/development/tools/sigrok-cli/default.nix4
-rw-r--r--pkgs/development/tools/simavr/default.nix4
-rw-r--r--pkgs/development/tools/skopeo/default.nix4
-rw-r--r--pkgs/development/tools/so/default.nix4
-rw-r--r--pkgs/development/tools/sourcetrail/default.nix4
-rw-r--r--pkgs/development/tools/sourcetrail/jedi.nix4
-rw-r--r--pkgs/development/tools/spirv-tools/default.nix4
-rw-r--r--pkgs/development/tools/spring-boot-cli/default.nix4
-rw-r--r--pkgs/development/tools/sqsh/default.nix4
-rw-r--r--pkgs/development/tools/sslmate/default.nix4
-rw-r--r--pkgs/development/tools/stagit/default.nix4
-rw-r--r--pkgs/development/tools/sunxi-tools/default.nix4
-rw-r--r--pkgs/development/tools/textql/default.nix4
-rw-r--r--pkgs/development/tools/the-way/default.nix4
-rw-r--r--pkgs/development/tools/thrust/default.nix4
-rw-r--r--pkgs/development/tools/toluapp/default.nix4
-rw-r--r--pkgs/development/tools/tracy/default.nix2
-rw-r--r--pkgs/development/tools/tradcpp/default.nix4
-rw-r--r--pkgs/development/tools/trellis/default.nix4
-rw-r--r--pkgs/development/tools/udis86/default.nix4
-rw-r--r--pkgs/development/tools/unity3d/default.nix2
-rw-r--r--pkgs/development/tools/unityhub/default.nix4
-rw-r--r--pkgs/development/tools/vala-language-server/default.nix4
-rw-r--r--pkgs/development/tools/vala-lint/default.nix4
-rw-r--r--pkgs/development/tools/vcstool/default.nix4
-rw-r--r--pkgs/development/tools/vend/default.nix4
-rw-r--r--pkgs/development/tools/vulkan-validation-layers/default.nix4
-rw-r--r--pkgs/development/tools/vultr-cli/default.nix4
-rw-r--r--pkgs/development/tools/wabt/default.nix4
-rw-r--r--pkgs/development/tools/wasm-pack/default.nix4
-rw-r--r--pkgs/development/tools/wiiload/default.nix4
-rw-r--r--pkgs/development/tools/winpdb/default.nix4
-rw-r--r--pkgs/development/tools/wllvm/default.nix4
-rw-r--r--pkgs/development/tools/wrangler/default.nix4
-rw-r--r--pkgs/development/tools/ws/default.nix4
-rw-r--r--pkgs/development/tools/wxformbuilder/default.nix4
-rw-r--r--pkgs/development/tools/xcbuild/default.nix4
-rw-r--r--pkgs/development/tools/xib2nib/default.nix4
-rw-r--r--pkgs/development/tools/xqilla/default.nix4
-rw-r--r--pkgs/development/tools/yaml2json/default.nix4
-rw-r--r--pkgs/development/tools/yarn/default.nix4
-rw-r--r--pkgs/development/tools/yj/default.nix4
-rw-r--r--pkgs/development/tools/yuicompressor/default.nix4
-rw-r--r--pkgs/development/web/csslint/default.nix4
-rw-r--r--pkgs/development/web/cypress/default.nix2
-rw-r--r--pkgs/development/web/deno/default.nix4
-rw-r--r--pkgs/development/web/grails/default.nix4
-rw-r--r--pkgs/development/web/insomnia/default.nix4
-rw-r--r--pkgs/development/web/kcgi/default.nix4
-rw-r--r--pkgs/development/web/kore/default.nix4
-rw-r--r--pkgs/development/web/now-cli/default.nix2
-rw-r--r--pkgs/development/web/postman/default.nix4
-rw-r--r--pkgs/development/web/shopify-themekit/default.nix4
-rw-r--r--pkgs/development/web/valum/default.nix4
-rw-r--r--pkgs/development/web/wml/default.nix4
-rw-r--r--pkgs/development/web/woff2/default.nix4
-rw-r--r--pkgs/games/0ad/data.nix4
-rw-r--r--pkgs/games/0ad/game.nix2
-rw-r--r--pkgs/games/1oom/default.nix4
-rw-r--r--pkgs/games/2048-in-terminal/default.nix4
-rw-r--r--pkgs/games/20kly/default.nix4
-rw-r--r--pkgs/games/90secondportraits/default.nix4
-rw-r--r--pkgs/games/abbaye-des-morts/default.nix4
-rw-r--r--pkgs/games/adom/default.nix4
-rw-r--r--pkgs/games/airstrike/default.nix4
-rw-r--r--pkgs/games/alephone/default.nix4
-rw-r--r--pkgs/games/alienarena/default.nix4
-rw-r--r--pkgs/games/amoeba/data.nix4
-rw-r--r--pkgs/games/amoeba/default.nix4
-rw-r--r--pkgs/games/among-sus/default.nix4
-rw-r--r--pkgs/games/angband/default.nix4
-rw-r--r--pkgs/games/armagetronad/default.nix4
-rw-r--r--pkgs/games/asc/default.nix4
-rw-r--r--pkgs/games/atanks/default.nix4
-rw-r--r--pkgs/games/augustus/default.nix4
-rw-r--r--pkgs/games/banner/default.nix4
-rw-r--r--pkgs/games/bastet/default.nix4
-rw-r--r--pkgs/games/beret/default.nix4
-rw-r--r--pkgs/games/boohu/default.nix4
-rw-r--r--pkgs/games/braincurses/default.nix4
-rw-r--r--pkgs/games/brogue/default.nix4
-rw-r--r--pkgs/games/btanks/default.nix4
-rw-r--r--pkgs/games/cataclysm-dda/common.nix4
-rw-r--r--pkgs/games/chessx/default.nix4
-rw-r--r--pkgs/games/chiaki/default.nix4
-rw-r--r--pkgs/games/ckan/default.nix4
-rw-r--r--pkgs/games/colobot/data.nix2
-rw-r--r--pkgs/games/colobot/default.nix4
-rw-r--r--pkgs/games/commandergenius/default.nix4
-rw-r--r--pkgs/games/crawl/default.nix2
-rw-r--r--pkgs/games/curseofwar/default.nix4
-rw-r--r--pkgs/games/cutemaze/default.nix4
-rw-r--r--pkgs/games/devilutionx/default.nix4
-rw-r--r--pkgs/games/dhewm3/default.nix4
-rw-r--r--pkgs/games/duckmarines/default.nix4
-rw-r--r--pkgs/games/dwarf-fortress/dfhack/default.nix2
-rw-r--r--pkgs/games/dwarf-fortress/dwarf-therapist/default.nix4
-rw-r--r--pkgs/games/dwarf-fortress/unfuck.nix2
-rw-r--r--pkgs/games/dxx-rebirth/assets.nix4
-rw-r--r--pkgs/games/dxx-rebirth/default.nix4
-rw-r--r--pkgs/games/dxx-rebirth/full.nix4
-rw-r--r--pkgs/games/easyrpg-player/default.nix4
-rw-r--r--pkgs/games/eduke32/default.nix4
-rw-r--r--pkgs/games/eidolon/default.nix4
-rw-r--r--pkgs/games/endless-sky/default.nix4
-rw-r--r--pkgs/games/ezquake/default.nix4
-rw-r--r--pkgs/games/flare/engine.nix4
-rw-r--r--pkgs/games/flare/game.nix4
-rw-r--r--pkgs/games/flightgear/default.nix4
-rw-r--r--pkgs/games/fltrator/default.nix4
-rw-r--r--pkgs/games/freeciv/default.nix4
-rw-r--r--pkgs/games/freedroidrpg/default.nix4
-rw-r--r--pkgs/games/freenukum/default.nix4
-rw-r--r--pkgs/games/freeorion/default.nix4
-rw-r--r--pkgs/games/freesweep/default.nix4
-rw-r--r--pkgs/games/frogatto/data.nix4
-rw-r--r--pkgs/games/frogatto/default.nix4
-rw-r--r--pkgs/games/frogatto/engine.nix4
-rw-r--r--pkgs/games/frotz/default.nix4
-rw-r--r--pkgs/games/gambatte/default.nix4
-rw-r--r--pkgs/games/garden-of-coloured-lights/default.nix4
-rw-r--r--pkgs/games/gargoyle/default.nix4
-rw-r--r--pkgs/games/gcs/default.nix4
-rw-r--r--pkgs/games/gemrb/default.nix4
-rw-r--r--pkgs/games/gl-117/default.nix4
-rw-r--r--pkgs/games/globulation/default.nix4
-rw-r--r--pkgs/games/gnome-hexgl/default.nix4
-rw-r--r--pkgs/games/gnujump/default.nix4
-rw-r--r--pkgs/games/gnushogi/default.nix4
-rw-r--r--pkgs/games/gscrabble/default.nix4
-rw-r--r--pkgs/games/gshogi/default.nix4
-rw-r--r--pkgs/games/gtypist/default.nix4
-rw-r--r--pkgs/games/gweled/default.nix4
-rw-r--r--pkgs/games/gzdoom/default.nix4
-rw-r--r--pkgs/games/harmonist/default.nix4
-rw-r--r--pkgs/games/holdingnuts/default.nix4
-rw-r--r--pkgs/games/hyperrogue/default.nix4
-rw-r--r--pkgs/games/instead-launcher/default.nix4
-rw-r--r--pkgs/games/instead/default.nix4
-rw-r--r--pkgs/games/iortcw/sp.nix4
-rw-r--r--pkgs/games/ivan/default.nix4
-rw-r--r--pkgs/games/julius/default.nix4
-rw-r--r--pkgs/games/katago/default.nix2
-rw-r--r--pkgs/games/keeperrl/default.nix4
-rw-r--r--pkgs/games/klavaro/default.nix4
-rw-r--r--pkgs/games/lbreakout2/default.nix4
-rw-r--r--pkgs/games/leela-zero/default.nix4
-rw-r--r--pkgs/games/lgogdownloader/default.nix4
-rw-r--r--pkgs/games/liberal-crime-squad/default.nix4
-rw-r--r--pkgs/games/lincity/default.nix4
-rw-r--r--pkgs/games/lincity/ng.nix4
-rw-r--r--pkgs/games/liquidwar/5.nix4
-rw-r--r--pkgs/games/liquidwar/default.nix4
-rw-r--r--pkgs/games/ltris/default.nix4
-rw-r--r--pkgs/games/mar1d/default.nix4
-rw-r--r--pkgs/games/mari0/default.nix4
-rw-r--r--pkgs/games/mars/default.nix4
-rw-r--r--pkgs/games/meritous/default.nix4
-rw-r--r--pkgs/games/mindustry/default.nix4
-rw-r--r--pkgs/games/minecraft-server/default.nix4
-rw-r--r--pkgs/games/minecraft/default.nix4
-rw-r--r--pkgs/games/minetest/default.nix4
-rw-r--r--pkgs/games/mrrescue/default.nix4
-rw-r--r--pkgs/games/mudlet/default.nix4
-rw-r--r--pkgs/games/multimc/default.nix4
-rw-r--r--pkgs/games/nethack/default.nix2
-rw-r--r--pkgs/games/netris/default.nix4
-rw-r--r--pkgs/games/newtonwars/default.nix4
-rw-r--r--pkgs/games/ninvaders/default.nix4
-rw-r--r--pkgs/games/nottetris2/default.nix4
-rw-r--r--pkgs/games/nudoku/default.nix4
-rw-r--r--pkgs/games/onscripter-en/default.nix4
-rw-r--r--pkgs/games/openclonk/default.nix4
-rw-r--r--pkgs/games/opendune/default.nix2
-rw-r--r--pkgs/games/opendungeons/default.nix4
-rw-r--r--pkgs/games/openjk/default.nix4
-rw-r--r--pkgs/games/openmw/default.nix4
-rw-r--r--pkgs/games/openmw/tes3mp.nix4
-rw-r--r--pkgs/games/openrct2/default.nix4
-rw-r--r--pkgs/games/openrw/default.nix4
-rw-r--r--pkgs/games/openspades/default.nix4
-rw-r--r--pkgs/games/openttd/default.nix4
-rw-r--r--pkgs/games/openxray/default.nix6
-rw-r--r--pkgs/games/orthorobot/default.nix4
-rw-r--r--pkgs/games/pacvim/default.nix4
-rw-r--r--pkgs/games/performous/default.nix4
-rw-r--r--pkgs/games/pioneer/default.nix4
-rw-r--r--pkgs/games/pioneers/default.nix4
-rw-r--r--pkgs/games/planetaryannihilation/default.nix4
-rw-r--r--pkgs/games/privateer/default.nix4
-rw-r--r--pkgs/games/pro-office-calculator/default.nix4
-rw-r--r--pkgs/games/pysolfc/default.nix4
-rw-r--r--pkgs/games/qqwing/default.nix4
-rw-r--r--pkgs/games/quake2/yquake2/default.nix2
-rw-r--r--pkgs/games/quake2/yquake2/games.nix2
-rw-r--r--pkgs/games/quake3/content/demo.nix4
-rw-r--r--pkgs/games/quake3/content/pointrelease.nix4
-rw-r--r--pkgs/games/quake3/ioquake/default.nix4
-rw-r--r--pkgs/games/quake3/quake3e/default.nix4
-rw-r--r--pkgs/games/quakespasm/vulkan.nix4
-rw-r--r--pkgs/games/r2mod_cli/default.nix4
-rw-r--r--pkgs/games/redeclipse/default.nix4
-rw-r--r--pkgs/games/riko4/default.nix6
-rw-r--r--pkgs/games/rimshot/default.nix4
-rw-r--r--pkgs/games/rocksndiamonds/default.nix4
-rw-r--r--pkgs/games/rogue/default.nix4
-rw-r--r--pkgs/games/rrootage/default.nix4
-rw-r--r--pkgs/games/sauerbraten/default.nix4
-rw-r--r--pkgs/games/scid-vs-pc/default.nix4
-rw-r--r--pkgs/games/scorched3d/default.nix4
-rw-r--r--pkgs/games/scummvm/default.nix4
-rw-r--r--pkgs/games/scummvm/games.nix2
-rw-r--r--pkgs/games/sfrotz/default.nix4
-rw-r--r--pkgs/games/sgt-puzzles/default.nix4
-rw-r--r--pkgs/games/shattered-pixel-dungeon/default.nix4
-rw-r--r--pkgs/games/sienna/default.nix4
-rw-r--r--pkgs/games/simutrans/default.nix4
-rw-r--r--pkgs/games/sm64ex/default.nix4
-rw-r--r--pkgs/games/snake4/default.nix4
-rw-r--r--pkgs/games/snipes/default.nix4
-rw-r--r--pkgs/games/soi/default.nix4
-rw-r--r--pkgs/games/space-orbit/default.nix4
-rw-r--r--pkgs/games/spring/default.nix4
-rw-r--r--pkgs/games/spring/springlobby.nix4
-rw-r--r--pkgs/games/stardust/default.nix4
-rw-r--r--pkgs/games/steam/runtime.nix4
-rw-r--r--pkgs/games/steam/steam.nix4
-rw-r--r--pkgs/games/steam/steamcmd.nix4
-rw-r--r--pkgs/games/stockfish/default.nix4
-rw-r--r--pkgs/games/stuntrally/default.nix4
-rw-r--r--pkgs/games/supertux/default.nix4
-rw-r--r--pkgs/games/t4kcommon/default.nix4
-rw-r--r--pkgs/games/taisei/default.nix4
-rw-r--r--pkgs/games/tennix/default.nix4
-rw-r--r--pkgs/games/the-butterfly-effect/default.nix4
-rw-r--r--pkgs/games/the-powder-toy/default.nix4
-rw-r--r--pkgs/games/tintin/default.nix2
-rw-r--r--pkgs/games/tome2/default.nix4
-rw-r--r--pkgs/games/tome4/default.nix4
-rw-r--r--pkgs/games/toppler/default.nix4
-rw-r--r--pkgs/games/tremulous/default.nix4
-rw-r--r--pkgs/games/tuxtype/default.nix4
-rw-r--r--pkgs/games/typespeed/default.nix4
-rw-r--r--pkgs/games/ultrastardx/default.nix4
-rw-r--r--pkgs/games/unnethack/default.nix4
-rw-r--r--pkgs/games/urbanterror/default.nix4
-rw-r--r--pkgs/games/ut2004/demo.nix4
-rw-r--r--pkgs/games/vapor/default.nix4
-rw-r--r--pkgs/games/vassal/default.nix4
-rw-r--r--pkgs/games/vessel/default.nix4
-rw-r--r--pkgs/games/voxelands/default.nix4
-rw-r--r--pkgs/games/warmux/default.nix4
-rw-r--r--pkgs/games/warsow/default.nix4
-rw-r--r--pkgs/games/warsow/engine.nix2
-rw-r--r--pkgs/games/warzone2100/default.nix4
-rw-r--r--pkgs/games/wesnoth/default.nix4
-rw-r--r--pkgs/games/widelands/default.nix4
-rw-r--r--pkgs/games/worldofgoo/default.nix4
-rw-r--r--pkgs/games/wyvern/default.nix4
-rw-r--r--pkgs/games/xbomb/default.nix4
-rw-r--r--pkgs/games/xconq/default.nix4
-rw-r--r--pkgs/games/xcowsay/default.nix4
-rw-r--r--pkgs/games/xjump/default.nix4
-rw-r--r--pkgs/games/xmage/default.nix4
-rw-r--r--pkgs/games/xmoto/default.nix4
-rw-r--r--pkgs/games/xpilot/bloodspilot-server.nix4
-rw-r--r--pkgs/games/xpilot/default.nix4
-rw-r--r--pkgs/games/xsokoban/default.nix4
-rw-r--r--pkgs/games/xtris/default.nix4
-rw-r--r--pkgs/games/zandronum/default.nix2
-rw-r--r--pkgs/games/zandronum/fmod.nix2
-rw-r--r--pkgs/games/zaz/default.nix4
-rw-r--r--pkgs/games/zdoom/bcc-git.nix4
-rw-r--r--pkgs/games/zdoom/default.nix4
-rw-r--r--pkgs/games/zdoom/zdbsp.nix4
-rw-r--r--pkgs/games/zoom/default.nix4
-rw-r--r--pkgs/misc/acpilight/default.nix4
-rw-r--r--pkgs/misc/apulse/default.nix4
-rw-r--r--pkgs/misc/beep/default.nix4
-rw-r--r--pkgs/misc/brightnessctl/default.nix4
-rw-r--r--pkgs/misc/calaos/installer/default.nix4
-rw-r--r--pkgs/misc/cups/cups-pk-helper.nix4
-rw-r--r--pkgs/misc/cups/drivers/brlaser/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/canon/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/estudio/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/fxlinuxprint/default.nix2
-rw-r--r--pkgs/misc/cups/drivers/googlecloudprint/default.nix2
-rw-r--r--pkgs/misc/cups/drivers/hll2340dw/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/hll2390dw-cups/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/mfcj6510dwcupswrapper/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/mfcj6510dwlpr/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/samsung/1.00.36/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/samsung/1.00.37.nix4
-rw-r--r--pkgs/misc/cups/drivers/samsung/4.00.39/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/samsung/4.01.17.nix4
-rw-r--r--pkgs/misc/cups/drivers/splix/default.nix4
-rw-r--r--pkgs/misc/cups/drivers/zj-58/default.nix4
-rw-r--r--pkgs/misc/doge/default.nix4
-rw-r--r--pkgs/misc/drivers/epson-201106w/default.nix4
-rw-r--r--pkgs/misc/drivers/epson-alc1100/default.nix4
-rw-r--r--pkgs/misc/drivers/epson-escpr/default.nix4
-rw-r--r--pkgs/misc/drivers/epson-escpr2/default.nix4
-rw-r--r--pkgs/misc/drivers/epson_201207w/default.nix4
-rw-r--r--pkgs/misc/drivers/foo2zjs/default.nix4
-rw-r--r--pkgs/misc/drivers/gutenprint/default.nix2
-rw-r--r--pkgs/misc/drivers/hplip/3.16.11.nix4
-rw-r--r--pkgs/misc/drivers/hplip/3.18.5.nix4
-rw-r--r--pkgs/misc/drivers/hplip/default.nix4
-rw-r--r--pkgs/misc/drivers/m33-linux/default.nix4
-rw-r--r--pkgs/misc/drivers/moltengamepad/default.nix4
-rw-r--r--pkgs/misc/drivers/pentablet-driver/default.nix4
-rw-r--r--pkgs/misc/drivers/postscript-lexmark/default.nix4
-rw-r--r--pkgs/misc/drivers/steamcontroller/default.nix2
-rw-r--r--pkgs/misc/drivers/utsushi/default.nix4
-rw-r--r--pkgs/misc/drivers/xboxdrv/default.nix4
-rw-r--r--pkgs/misc/drivers/xow/default.nix4
-rw-r--r--pkgs/misc/dumb/default.nix4
-rw-r--r--pkgs/misc/emulators/atari++/default.nix4
-rw-r--r--pkgs/misc/emulators/attract-mode/default.nix4
-rw-r--r--pkgs/misc/emulators/caprice32/default.nix4
-rw-r--r--pkgs/misc/emulators/ccemux/default.nix4
-rw-r--r--pkgs/misc/emulators/cdemu/base.nix4
-rw-r--r--pkgs/misc/emulators/cdemu/vhba.nix4
-rw-r--r--pkgs/misc/emulators/citra/default.nix2
-rw-r--r--pkgs/misc/emulators/craftos-pc/default.nix4
-rw-r--r--pkgs/misc/emulators/dgen-sdl/default.nix4
-rw-r--r--pkgs/misc/emulators/emu2/default.nix4
-rw-r--r--pkgs/misc/emulators/gens-gs/default.nix4
-rw-r--r--pkgs/misc/emulators/gxemul/default.nix4
-rw-r--r--pkgs/misc/emulators/higan/default.nix4
-rw-r--r--pkgs/misc/emulators/kega-fusion/default.nix2
-rw-r--r--pkgs/misc/emulators/lambda-delta/default.nix4
-rw-r--r--pkgs/misc/emulators/libdsk/default.nix4
-rw-r--r--pkgs/misc/emulators/mednafen/default.nix4
-rw-r--r--pkgs/misc/emulators/mednafen/server.nix4
-rw-r--r--pkgs/misc/emulators/melonDS/default.nix4
-rw-r--r--pkgs/misc/emulators/mgba/default.nix4
-rw-r--r--pkgs/misc/emulators/mupen64plus/default.nix4
-rw-r--r--pkgs/misc/emulators/pcsx2/default.nix4
-rw-r--r--pkgs/misc/emulators/pcsxr/default.nix4
-rw-r--r--pkgs/misc/emulators/qmc2/default.nix4
-rw-r--r--pkgs/misc/emulators/reicast/default.nix4
-rw-r--r--pkgs/misc/emulators/retroarch/cores.nix4
-rw-r--r--pkgs/misc/emulators/retrofe/default.nix4
-rw-r--r--pkgs/misc/emulators/ruffle/default.nix4
-rw-r--r--pkgs/misc/emulators/ryujinx/default.nix4
-rw-r--r--pkgs/misc/emulators/sameboy/default.nix4
-rw-r--r--pkgs/misc/emulators/simh/default.nix4
-rw-r--r--pkgs/misc/emulators/simplenes/default.nix4
-rw-r--r--pkgs/misc/emulators/snes9x-gtk/default.nix4
-rw-r--r--pkgs/misc/emulators/tilem/default.nix2
-rw-r--r--pkgs/misc/emulators/wine/vkd3d.nix4
-rw-r--r--pkgs/misc/emulators/yabause/default.nix4
-rw-r--r--pkgs/misc/emulators/yuzu/default.nix4
-rw-r--r--pkgs/misc/gnuk/generic.nix4
-rw-r--r--pkgs/misc/hdt/default.nix4
-rw-r--r--pkgs/misc/jackaudio/jack1.nix4
-rw-r--r--pkgs/misc/lguf-brightness/default.nix4
-rw-r--r--pkgs/misc/lightspark/default.nix4
-rw-r--r--pkgs/misc/lilypond/fonts.nix4
-rw-r--r--pkgs/misc/logging/beats/6.x.nix2
-rw-r--r--pkgs/misc/logging/beats/7.x.nix2
-rw-r--r--pkgs/misc/mxt-app/default.nix4
-rw-r--r--pkgs/misc/ptouch-print/default.nix4
-rw-r--r--pkgs/misc/rkdeveloptool/default.nix4
-rw-r--r--pkgs/misc/sailsd/default.nix4
-rw-r--r--pkgs/misc/scrcpy/default.nix4
-rw-r--r--pkgs/misc/screensavers/alock/default.nix4
-rw-r--r--pkgs/misc/screensavers/betterlockscreen/default.nix4
-rw-r--r--pkgs/misc/screensavers/electricsheep/default.nix4
-rw-r--r--pkgs/misc/screensavers/i3lock-pixeled/default.nix4
-rw-r--r--pkgs/misc/screensavers/light-locker/default.nix4
-rw-r--r--pkgs/misc/screensavers/multilockscreen/default.nix4
-rw-r--r--pkgs/misc/screensavers/physlock/default.nix4
-rw-r--r--pkgs/misc/screensavers/pipes/default.nix4
-rw-r--r--pkgs/misc/screensavers/vlock/default.nix4
-rw-r--r--pkgs/misc/screensavers/xautolock/default.nix4
-rw-r--r--pkgs/misc/screensavers/xss-lock/default.nix4
-rw-r--r--pkgs/misc/seafile-shared/default.nix4
-rw-r--r--pkgs/misc/sndio/default.nix4
-rw-r--r--pkgs/misc/sound-of-sorting/default.nix4
-rw-r--r--pkgs/misc/tmux-plugins/default.nix8
-rw-r--r--pkgs/misc/urbit/default.nix4
-rw-r--r--pkgs/misc/vim-plugins/overrides.nix6
-rw-r--r--pkgs/misc/vscode-extensions/cpptools/default.nix4
-rw-r--r--pkgs/misc/vscode-extensions/default.nix18
-rw-r--r--pkgs/misc/vscode-extensions/remote-ssh/default.nix4
-rw-r--r--pkgs/misc/vscode-extensions/wakatime/default.nix4
-rw-r--r--pkgs/misc/xosd/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-sdk/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/CarbonHeaders/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/CommonCrypto/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/Csu/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/IOKit/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/Librpcsvc/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/dyld/default.nix4
-rw-r--r--pkgs/os-specific/darwin/apple-source-releases/libunwind/default.nix4
-rw-r--r--pkgs/os-specific/darwin/chunkwm/default.nix4
-rw-r--r--pkgs/os-specific/darwin/goku/default.nix4
-rw-r--r--pkgs/os-specific/darwin/iproute2mac/default.nix4
-rw-r--r--pkgs/os-specific/darwin/khd/default.nix4
-rw-r--r--pkgs/os-specific/darwin/kwm/default.nix4
-rw-r--r--pkgs/os-specific/darwin/m-cli/default.nix4
-rw-r--r--pkgs/os-specific/darwin/noah/default.nix4
-rw-r--r--pkgs/os-specific/darwin/osx-cpu-temp/default.nix4
-rw-r--r--pkgs/os-specific/darwin/osxfuse/default.nix4
-rw-r--r--pkgs/os-specific/darwin/qes/default.nix4
-rw-r--r--pkgs/os-specific/darwin/reattach-to-user-namespace/default.nix4
-rw-r--r--pkgs/os-specific/darwin/skhd/default.nix4
-rw-r--r--pkgs/os-specific/darwin/spacebar/default.nix4
-rw-r--r--pkgs/os-specific/darwin/xcode/default.nix2
-rw-r--r--pkgs/os-specific/darwin/yabai/default.nix4
-rw-r--r--pkgs/os-specific/linux/915resolution/default.nix4
-rw-r--r--pkgs/os-specific/linux/acpi-call/default.nix4
-rw-r--r--pkgs/os-specific/linux/acpi/default.nix4
-rw-r--r--pkgs/os-specific/linux/acpid/default.nix4
-rw-r--r--pkgs/os-specific/linux/alsa-lib/default.nix4
-rw-r--r--pkgs/os-specific/linux/alsa-oss/default.nix4
-rw-r--r--pkgs/os-specific/linux/alsa-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/alsa-topology-conf/default.nix4
-rw-r--r--pkgs/os-specific/linux/alsa-ucm-conf/default.nix4
-rw-r--r--pkgs/os-specific/linux/alsa-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/amdgpu-pro/default.nix4
-rw-r--r--pkgs/os-specific/linux/anbox/default.nix4
-rw-r--r--pkgs/os-specific/linux/anbox/kmod.nix4
-rw-r--r--pkgs/os-specific/linux/android-udev-rules/default.nix4
-rw-r--r--pkgs/os-specific/linux/asus-wmi-sensors/default.nix4
-rw-r--r--pkgs/os-specific/linux/ati-drivers/default.nix2
-rw-r--r--pkgs/os-specific/linux/atop/default.nix4
-rw-r--r--pkgs/os-specific/linux/bbswitch/default.nix4
-rw-r--r--pkgs/os-specific/linux/bcc/default.nix4
-rw-r--r--pkgs/os-specific/linux/bluez/default.nix2
-rw-r--r--pkgs/os-specific/linux/bolt/default.nix4
-rw-r--r--pkgs/os-specific/linux/bpftool/default.nix4
-rw-r--r--pkgs/os-specific/linux/bpftrace/default.nix4
-rw-r--r--pkgs/os-specific/linux/brillo/default.nix4
-rw-r--r--pkgs/os-specific/linux/btfs/default.nix4
-rw-r--r--pkgs/os-specific/linux/busybox/default.nix2
-rw-r--r--pkgs/os-specific/linux/cachefilesd/default.nix4
-rw-r--r--pkgs/os-specific/linux/can-isotp/default.nix4
-rw-r--r--pkgs/os-specific/linux/can-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/checksec/default.nix4
-rw-r--r--pkgs/os-specific/linux/cifs-utils/default.nix2
-rw-r--r--pkgs/os-specific/linux/compsize/default.nix4
-rw-r--r--pkgs/os-specific/linux/conky/default.nix4
-rw-r--r--pkgs/os-specific/linux/conntrack-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/consoletools/default.nix4
-rw-r--r--pkgs/os-specific/linux/cpufrequtils/default.nix4
-rw-r--r--pkgs/os-specific/linux/cpupower/default.nix4
-rw-r--r--pkgs/os-specific/linux/cpuset/default.nix4
-rw-r--r--pkgs/os-specific/linux/cramfsprogs/default.nix4
-rw-r--r--pkgs/os-specific/linux/cramfsswap/default.nix4
-rw-r--r--pkgs/os-specific/linux/crda/default.nix4
-rw-r--r--pkgs/os-specific/linux/criu/default.nix2
-rw-r--r--pkgs/os-specific/linux/dbus-broker/default.nix4
-rw-r--r--pkgs/os-specific/linux/ddcci/default.nix4
-rw-r--r--pkgs/os-specific/linux/devmem2/default.nix4
-rw-r--r--pkgs/os-specific/linux/digimend/default.nix4
-rw-r--r--pkgs/os-specific/linux/directvnc/default.nix4
-rw-r--r--pkgs/os-specific/linux/displaylink/default.nix2
-rw-r--r--pkgs/os-specific/linux/dmidecode/default.nix4
-rw-r--r--pkgs/os-specific/linux/dmtcp/default.nix4
-rw-r--r--pkgs/os-specific/linux/drbd/default.nix4
-rw-r--r--pkgs/os-specific/linux/dropwatch/default.nix4
-rw-r--r--pkgs/os-specific/linux/dstat/default.nix4
-rw-r--r--pkgs/os-specific/linux/earlyoom/default.nix4
-rw-r--r--pkgs/os-specific/linux/ebtables/default.nix4
-rw-r--r--pkgs/os-specific/linux/edac-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/ell/default.nix4
-rw-r--r--pkgs/os-specific/linux/ena/default.nix4
-rw-r--r--pkgs/os-specific/linux/erofs-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/evdi/default.nix4
-rw-r--r--pkgs/os-specific/linux/extrace/default.nix4
-rw-r--r--pkgs/os-specific/linux/facetimehd/default.nix2
-rw-r--r--pkgs/os-specific/linux/fatrace/default.nix4
-rw-r--r--pkgs/os-specific/linux/fbterm/default.nix2
-rw-r--r--pkgs/os-specific/linux/ffado/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/b43-firmware/6.30.163.46.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/broadcom-bt-firmware/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/bt-fw-converter/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/facetimehd-firmware/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/fwupd/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/openelec-dvb-firmware/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/raspberrypi-wireless/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/raspberrypi/armstubs.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/rt5677/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/rtl8723bs-firmware/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/rtl8761b-firmware/default.nix4
-rw-r--r--pkgs/os-specific/linux/firmware/sof-firmware/default.nix4
-rw-r--r--pkgs/os-specific/linux/flashbench/default.nix4
-rw-r--r--pkgs/os-specific/linux/freefall/default.nix4
-rw-r--r--pkgs/os-specific/linux/fscrypt/default.nix4
-rw-r--r--pkgs/os-specific/linux/fscryptctl/default.nix4
-rw-r--r--pkgs/os-specific/linux/ftop/default.nix4
-rw-r--r--pkgs/os-specific/linux/fuse/common.nix4
-rw-r--r--pkgs/os-specific/linux/fwts/default.nix4
-rw-r--r--pkgs/os-specific/linux/fwts/module.nix4
-rw-r--r--pkgs/os-specific/linux/fxload/default.nix4
-rw-r--r--pkgs/os-specific/linux/gcadapter-oc-kmod/default.nix4
-rw-r--r--pkgs/os-specific/linux/gobi_loader/default.nix4
-rw-r--r--pkgs/os-specific/linux/gogoclient/default.nix4
-rw-r--r--pkgs/os-specific/linux/gradm/default.nix4
-rw-r--r--pkgs/os-specific/linux/guvcview/default.nix6
-rw-r--r--pkgs/os-specific/linux/hal-flash/default.nix4
-rw-r--r--pkgs/os-specific/linux/hd-idle/default.nix4
-rw-r--r--pkgs/os-specific/linux/hdparm/default.nix4
-rw-r--r--pkgs/os-specific/linux/hostapd/default.nix4
-rw-r--r--pkgs/os-specific/linux/hyperv-daemons/default.nix2
-rw-r--r--pkgs/os-specific/linux/i2c-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/ifmetric/default.nix4
-rw-r--r--pkgs/os-specific/linux/iio-sensor-proxy/default.nix4
-rw-r--r--pkgs/os-specific/linux/input-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/intel-compute-runtime/default.nix4
-rw-r--r--pkgs/os-specific/linux/intel-speed-select/default.nix4
-rw-r--r--pkgs/os-specific/linux/ioport/default.nix4
-rw-r--r--pkgs/os-specific/linux/iotop/default.nix4
-rw-r--r--pkgs/os-specific/linux/iproute/default.nix4
-rw-r--r--pkgs/os-specific/linux/iproute/mptcp.nix4
-rw-r--r--pkgs/os-specific/linux/ipsec-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/ipset/default.nix4
-rw-r--r--pkgs/os-specific/linux/iptstate/default.nix4
-rw-r--r--pkgs/os-specific/linux/ipvsadm/default.nix4
-rw-r--r--pkgs/os-specific/linux/it87/default.nix4
-rw-r--r--pkgs/os-specific/linux/iwd/default.nix4
-rw-r--r--pkgs/os-specific/linux/ixgbevf/default.nix4
-rw-r--r--pkgs/os-specific/linux/jfbview/default.nix4
-rw-r--r--pkgs/os-specific/linux/jool/cli.nix4
-rw-r--r--pkgs/os-specific/linux/jool/default.nix4
-rw-r--r--pkgs/os-specific/linux/kbd/default.nix4
-rw-r--r--pkgs/os-specific/linux/kbdlight/default.nix4
-rw-r--r--pkgs/os-specific/linux/kexectools/default.nix4
-rw-r--r--pkgs/os-specific/linux/keyutils/default.nix4
-rw-r--r--pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix4
-rw-r--r--pkgs/os-specific/linux/kmod/default.nix2
-rw-r--r--pkgs/os-specific/linux/kmscon/default.nix4
-rw-r--r--pkgs/os-specific/linux/kmscube/default.nix4
-rw-r--r--pkgs/os-specific/linux/ledger-udev-rules/default.nix4
-rw-r--r--pkgs/os-specific/linux/libatasmart/default.nix4
-rw-r--r--pkgs/os-specific/linux/libbpf/default.nix4
-rw-r--r--pkgs/os-specific/linux/libevdevc/default.nix4
-rw-r--r--pkgs/os-specific/linux/libfabric/default.nix4
-rw-r--r--pkgs/os-specific/linux/libgestures/default.nix4
-rw-r--r--pkgs/os-specific/linux/libpsm2/default.nix4
-rw-r--r--pkgs/os-specific/linux/libratbag/default.nix4
-rw-r--r--pkgs/os-specific/linux/libsepol/default.nix4
-rw-r--r--pkgs/os-specific/linux/libsmbios/default.nix4
-rw-r--r--pkgs/os-specific/linux/libudev0-shim/default.nix4
-rw-r--r--pkgs/os-specific/linux/libvolume_id/default.nix4
-rw-r--r--pkgs/os-specific/linux/linuxptp/default.nix4
-rw-r--r--pkgs/os-specific/linux/lksctp-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/lm-sensors/default.nix4
-rw-r--r--pkgs/os-specific/linux/logitech-udev-rules/default.nix4
-rw-r--r--pkgs/os-specific/linux/lsscsi/default.nix4
-rw-r--r--pkgs/os-specific/linux/lttng-modules/default.nix4
-rw-r--r--pkgs/os-specific/linux/lvm2/default.nix4
-rw-r--r--pkgs/os-specific/linux/macchanger/default.nix4
-rw-r--r--pkgs/os-specific/linux/mba6x_bl/default.nix4
-rw-r--r--pkgs/os-specific/linux/mcelog/default.nix4
-rw-r--r--pkgs/os-specific/linux/mdadm/default.nix4
-rw-r--r--pkgs/os-specific/linux/metastore/default.nix4
-rw-r--r--pkgs/os-specific/linux/microcode/amd.nix4
-rw-r--r--pkgs/os-specific/linux/microcode/intel.nix4
-rw-r--r--pkgs/os-specific/linux/microcode/iucode-tool.nix4
-rw-r--r--pkgs/os-specific/linux/mingetty/default.nix4
-rw-r--r--pkgs/os-specific/linux/miraclecast/default.nix4
-rw-r--r--pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/mmc-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/molly-guard/default.nix4
-rw-r--r--pkgs/os-specific/linux/msr-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/mstpd/default.nix4
-rw-r--r--pkgs/os-specific/linux/multipath-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/mxu11x0/default.nix4
-rw-r--r--pkgs/os-specific/linux/net-tools/mptcp.nix4
-rw-r--r--pkgs/os-specific/linux/nfs-utils/default.nix2
-rw-r--r--pkgs/os-specific/linux/nmon/default.nix4
-rw-r--r--pkgs/os-specific/linux/nss_ldap/default.nix4
-rw-r--r--pkgs/os-specific/linux/numactl/default.nix4
-rw-r--r--pkgs/os-specific/linux/numad/default.nix4
-rw-r--r--pkgs/os-specific/linux/numatop/default.nix4
-rw-r--r--pkgs/os-specific/linux/numworks-udev-rules/default.nix4
-rw-r--r--pkgs/os-specific/linux/nvidia-x11/generic.nix4
-rw-r--r--pkgs/os-specific/linux/nvidia-x11/persistenced.nix2
-rw-r--r--pkgs/os-specific/linux/nvidia-x11/settings.nix2
-rw-r--r--pkgs/os-specific/linux/nvidiabl/default.nix4
-rw-r--r--pkgs/os-specific/linux/oci-seccomp-bpf-hook/default.nix4
-rw-r--r--pkgs/os-specific/linux/odp-dpdk/default.nix4
-rw-r--r--pkgs/os-specific/linux/ofp/default.nix4
-rw-r--r--pkgs/os-specific/linux/open-iscsi/default.nix4
-rw-r--r--pkgs/os-specific/linux/openrazer/driver.nix3
-rw-r--r--pkgs/os-specific/linux/openvswitch/default.nix4
-rw-r--r--pkgs/os-specific/linux/openvswitch/lts.nix4
-rw-r--r--pkgs/os-specific/linux/pagemon/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam_ccreds/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam_gnupg/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam_krb5/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam_mount/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam_p11/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam_pgsql/default.nix4
-rw-r--r--pkgs/os-specific/linux/pam_u2f/default.nix4
-rw-r--r--pkgs/os-specific/linux/paxctl/default.nix4
-rw-r--r--pkgs/os-specific/linux/paxtest/default.nix4
-rw-r--r--pkgs/os-specific/linux/pcimem/default.nix4
-rw-r--r--pkgs/os-specific/linux/pcm/default.nix4
-rw-r--r--pkgs/os-specific/linux/perf-tools/default.nix4
-rw-r--r--pkgs/os-specific/linux/phc-intel/default.nix4
-rw-r--r--pkgs/os-specific/linux/piper/default.nix4
-rw-r--r--pkgs/os-specific/linux/pktgen/default.nix2
-rw-r--r--pkgs/os-specific/linux/ply/default.nix4
-rw-r--r--pkgs/os-specific/linux/plymouth/default.nix2
-rw-r--r--pkgs/os-specific/linux/policycoreutils/default.nix4
-rw-r--r--pkgs/os-specific/linux/powertop/default.nix4
-rw-r--r--pkgs/os-specific/linux/prl-tools/default.nix2
-rw-r--r--pkgs/os-specific/linux/procdump/default.nix4
-rw-r--r--pkgs/os-specific/linux/pscircle/default.nix4
-rw-r--r--pkgs/os-specific/linux/psftools/default.nix4
-rw-r--r--pkgs/os-specific/linux/psmisc/default.nix4
-rw-r--r--pkgs/os-specific/linux/radeontools/default.nix4
-rw-r--r--pkgs/os-specific/linux/radeontop/default.nix4
-rw-r--r--pkgs/os-specific/linux/rdma-core/default.nix4
-rw-r--r--pkgs/os-specific/linux/read-edid/default.nix2
-rw-r--r--pkgs/os-specific/linux/regionset/default.nix4
-rw-r--r--pkgs/os-specific/linux/rewritefs/default.nix4
-rw-r--r--pkgs/os-specific/linux/rfkill/udev.nix4
-rw-r--r--pkgs/os-specific/linux/rtkit/default.nix4
-rw-r--r--pkgs/os-specific/linux/rtl8812au/default.nix4
-rw-r--r--pkgs/os-specific/linux/rtl8814au/default.nix4
-rw-r--r--pkgs/os-specific/linux/rtl8821au/default.nix4
-rw-r--r--pkgs/os-specific/linux/rtl8821ce/default.nix4
-rw-r--r--pkgs/os-specific/linux/rtl8821cu/default.nix4
-rw-r--r--pkgs/os-specific/linux/rtl88x2bu/default.nix4
-rw-r--r--pkgs/os-specific/linux/rtl88xxau-aircrack/default.nix4
-rw-r--r--pkgs/os-specific/linux/schedtool/default.nix4
-rw-r--r--pkgs/os-specific/linux/sd-switch/default.nix4
-rw-r--r--pkgs/os-specific/linux/sdparm/default.nix4
-rw-r--r--pkgs/os-specific/linux/semodule-utils/default.nix4
-rw-r--r--pkgs/os-specific/linux/sepolgen/default.nix4
-rw-r--r--pkgs/os-specific/linux/service-wrapper/default.nix4
-rw-r--r--pkgs/os-specific/linux/shadow/default.nix4
-rw-r--r--pkgs/os-specific/linux/sssd/default.nix4
-rw-r--r--pkgs/os-specific/linux/syscall_limiter/default.nix4
-rw-r--r--pkgs/os-specific/linux/sysklogd/default.nix4
-rw-r--r--pkgs/os-specific/linux/syslinux/default.nix4
-rw-r--r--pkgs/os-specific/linux/system76-acpi/default.nix4
-rw-r--r--pkgs/os-specific/linux/system76-io/default.nix4
-rw-r--r--pkgs/os-specific/linux/system76/default.nix4
-rw-r--r--pkgs/os-specific/linux/targetcli/default.nix4
-rw-r--r--pkgs/os-specific/linux/tiptop/default.nix4
-rw-r--r--pkgs/os-specific/linux/tmon/default.nix4
-rw-r--r--pkgs/os-specific/linux/tomb/default.nix2
-rw-r--r--pkgs/os-specific/linux/trace-cmd/default.nix4
-rw-r--r--pkgs/os-specific/linux/trace-cmd/kernelshark.nix4
-rw-r--r--pkgs/os-specific/linux/trezor-udev-rules/default.nix4
-rw-r--r--pkgs/os-specific/linux/trinity/default.nix4
-rw-r--r--pkgs/os-specific/linux/turbostat/default.nix4
-rw-r--r--pkgs/os-specific/linux/tuxedo-keyboard/default.nix4
-rw-r--r--pkgs/os-specific/linux/uclibc/default.nix4
-rw-r--r--pkgs/os-specific/linux/udisks/1-default.nix4
-rw-r--r--pkgs/os-specific/linux/udisks/2-default.nix4
-rw-r--r--pkgs/os-specific/linux/undervolt/default.nix4
-rw-r--r--pkgs/os-specific/linux/untie/default.nix4
-rw-r--r--pkgs/os-specific/linux/upower/default.nix4
-rw-r--r--pkgs/os-specific/linux/usbip/default.nix2
-rw-r--r--pkgs/os-specific/linux/usbtop/default.nix4
-rw-r--r--pkgs/os-specific/linux/usbutils/default.nix4
-rw-r--r--pkgs/os-specific/linux/uvcdynctrl/default.nix4
-rw-r--r--pkgs/os-specific/linux/v4l-utils/default.nix2
-rw-r--r--pkgs/os-specific/linux/v4l2loopback/default.nix4
-rw-r--r--pkgs/os-specific/linux/v86d/default.nix4
-rw-r--r--pkgs/os-specific/linux/wireguard/default.nix4
-rw-r--r--pkgs/os-specific/linux/wooting-udev-rules/default.nix4
-rw-r--r--pkgs/os-specific/linux/wpa_supplicant/default.nix4
-rw-r--r--pkgs/os-specific/linux/wpa_supplicant/gui.nix4
-rw-r--r--pkgs/os-specific/linux/x86_energy_perf_policy/default.nix4
-rw-r--r--pkgs/os-specific/linux/xf86-input-cmt/default.nix4
-rw-r--r--pkgs/os-specific/linux/xf86-input-wacom/default.nix4
-rw-r--r--pkgs/os-specific/linux/xf86-video-nested/default.nix4
-rw-r--r--pkgs/os-specific/linux/zenmonitor/default.nix4
-rw-r--r--pkgs/os-specific/linux/zenpower/default.nix4
-rw-r--r--pkgs/os-specific/linux/zenstates/default.nix4
-rw-r--r--pkgs/os-specific/linux/zsa-udev-rules/default.nix4
-rw-r--r--pkgs/os-specific/windows/pthread-w32/default.nix4
-rw-r--r--pkgs/servers/adguardhome/default.nix4
-rw-r--r--pkgs/servers/adminer/default.nix4
-rw-r--r--pkgs/servers/amqp/qpid-cpp/default.nix4
-rw-r--r--pkgs/servers/apache-kafka/default.nix4
-rw-r--r--pkgs/servers/apcupsd/default.nix4
-rw-r--r--pkgs/servers/asterisk/default.nix2
-rw-r--r--pkgs/servers/asterisk/sccp/default.nix4
-rw-r--r--pkgs/servers/atlassian/crowd.nix4
-rw-r--r--pkgs/servers/atlassian/jira.nix2
-rw-r--r--pkgs/servers/beanstalkd/default.nix4
-rw-r--r--pkgs/servers/blockbook/default.nix4
-rw-r--r--pkgs/servers/caddy/default.nix4
-rw-r--r--pkgs/servers/clickhouse/default.nix4
-rw-r--r--pkgs/servers/cloud-print-connector/default.nix4
-rw-r--r--pkgs/servers/code-server/default.nix4
-rw-r--r--pkgs/servers/computing/slurm-spank-x11/default.nix4
-rw-r--r--pkgs/servers/computing/slurm/default.nix4
-rw-r--r--pkgs/servers/computing/storm/default.nix2
-rw-r--r--pkgs/servers/computing/torque/default.nix4
-rw-r--r--pkgs/servers/confluent-platform/default.nix2
-rw-r--r--pkgs/servers/consul/default.nix4
-rw-r--r--pkgs/servers/coturn/default.nix4
-rw-r--r--pkgs/servers/dante/default.nix4
-rw-r--r--pkgs/servers/demoit/default.nix4
-rw-r--r--pkgs/servers/dico/default.nix4
-rw-r--r--pkgs/servers/dict/default.nix4
-rw-r--r--pkgs/servers/dict/libmaa.nix4
-rw-r--r--pkgs/servers/diod/default.nix4
-rw-r--r--pkgs/servers/dns/bind/default.nix2
-rw-r--r--pkgs/servers/dns/coredns/default.nix4
-rw-r--r--pkgs/servers/dns/dnsdist/default.nix4
-rw-r--r--pkgs/servers/dns/https-dns-proxy/default.nix4
-rw-r--r--pkgs/servers/dns/knot-dns/default.nix4
-rw-r--r--pkgs/servers/dns/knot-resolver/default.nix4
-rw-r--r--pkgs/servers/dns/nsd/default.nix4
-rw-r--r--pkgs/servers/dns/powerdns/default.nix4
-rw-r--r--pkgs/servers/domoticz/default.nix4
-rw-r--r--pkgs/servers/elasticmq-server-bin/default.nix4
-rw-r--r--pkgs/servers/endlessh/default.nix4
-rw-r--r--pkgs/servers/exhibitor/default.nix4
-rw-r--r--pkgs/servers/fcgiwrap/default.nix4
-rw-r--r--pkgs/servers/felix/default.nix4
-rw-r--r--pkgs/servers/fileshare/default.nix2
-rw-r--r--pkgs/servers/fingerd/bsd-fingerd/default.nix4
-rw-r--r--pkgs/servers/foundationdb/cmake.nix2
-rw-r--r--pkgs/servers/freeradius/default.nix4
-rw-r--r--pkgs/servers/ftp/bftpd/default.nix4
-rw-r--r--pkgs/servers/ftp/pure-ftpd/default.nix4
-rw-r--r--pkgs/servers/ftp/vsftpd/default.nix4
-rw-r--r--pkgs/servers/gerbera/default.nix4
-rw-r--r--pkgs/servers/gopher/gofish/default.nix4
-rw-r--r--pkgs/servers/gotify/default.nix2
-rw-r--r--pkgs/servers/gotty/default.nix4
-rw-r--r--pkgs/servers/gpm/default.nix4
-rw-r--r--pkgs/servers/gpsd/default.nix2
-rw-r--r--pkgs/servers/grocy/default.nix4
-rw-r--r--pkgs/servers/h2/default.nix4
-rw-r--r--pkgs/servers/hashi-ui/default.nix4
-rw-r--r--pkgs/servers/hbase/default.nix4
-rw-r--r--pkgs/servers/headphones/default.nix4
-rw-r--r--pkgs/servers/hitch/default.nix4
-rw-r--r--pkgs/servers/http/apache-httpd/2.4.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_auth_mellon/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_ca/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_crl/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_csr/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_dnssd/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_ocsp/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_pkcs12/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_scep/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_spkac/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_tile/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/mod_timestamp/default.nix4
-rw-r--r--pkgs/servers/http/apache-modules/tomcat-connectors/default.nix4
-rw-r--r--pkgs/servers/http/apt-cacher-ng/default.nix4
-rw-r--r--pkgs/servers/http/couchdb/2.0.0.nix4
-rw-r--r--pkgs/servers/http/couchdb/3.nix4
-rw-r--r--pkgs/servers/http/couchdb/default.nix4
-rw-r--r--pkgs/servers/http/darkhttpd/default.nix4
-rw-r--r--pkgs/servers/http/gatling/default.nix4
-rw-r--r--pkgs/servers/http/h2o/default.nix4
-rw-r--r--pkgs/servers/http/hiawatha/default.nix4
-rw-r--r--pkgs/servers/http/hyp/default.nix4
-rw-r--r--pkgs/servers/http/jboss/default.nix4
-rw-r--r--pkgs/servers/http/lighttpd/default.nix4
-rw-r--r--pkgs/servers/http/lwan/default.nix4
-rw-r--r--pkgs/servers/http/micro-httpd/default.nix4
-rw-r--r--pkgs/servers/http/spawn-fcgi/default.nix4
-rw-r--r--pkgs/servers/http/tomcat/tomcat-native.nix4
-rw-r--r--pkgs/servers/http/webfs/default.nix4
-rw-r--r--pkgs/servers/http/yaws/default.nix4
-rw-r--r--pkgs/servers/hydron/default.nix4
-rw-r--r--pkgs/servers/icecream/default.nix4
-rw-r--r--pkgs/servers/identd/nullidentdmod/default.nix4
-rw-r--r--pkgs/servers/identd/oidentd/default.nix4
-rw-r--r--pkgs/servers/irc/atheme/default.nix4
-rw-r--r--pkgs/servers/irc/charybdis/default.nix4
-rw-r--r--pkgs/servers/irc/robustirc-bridge/default.nix4
-rw-r--r--pkgs/servers/irc/solanum/default.nix4
-rw-r--r--pkgs/servers/irker/default.nix4
-rw-r--r--pkgs/servers/isso/default.nix4
-rw-r--r--pkgs/servers/jackett/default.nix2
-rw-r--r--pkgs/servers/jetbrains/youtrack.nix4
-rw-r--r--pkgs/servers/jicofo/default.nix4
-rw-r--r--pkgs/servers/jitsi-videobridge/default.nix4
-rw-r--r--pkgs/servers/kapowbang/default.nix4
-rw-r--r--pkgs/servers/keycloak/default.nix2
-rw-r--r--pkgs/servers/kippo/default.nix6
-rw-r--r--pkgs/servers/ldap/389/default.nix4
-rw-r--r--pkgs/servers/lidarr/default.nix4
-rw-r--r--pkgs/servers/limesurvey/default.nix4
-rw-r--r--pkgs/servers/livepeer/default.nix4
-rw-r--r--pkgs/servers/ma1sd/default.nix4
-rw-r--r--pkgs/servers/mail/archiveopteryx/default.nix4
-rw-r--r--pkgs/servers/mail/clamsmtp/default.nix4
-rw-r--r--pkgs/servers/mail/dkimproxy/default.nix4
-rw-r--r--pkgs/servers/mail/dovecot/plugins/fts_xapian/default.nix4
-rw-r--r--pkgs/servers/mail/dovecot/plugins/pigeonhole/default.nix4
-rw-r--r--pkgs/servers/mail/exim/default.nix4
-rw-r--r--pkgs/servers/mail/mailhog/default.nix4
-rw-r--r--pkgs/servers/mail/mlmmj/default.nix4
-rw-r--r--pkgs/servers/mail/opensmtpd/default.nix4
-rw-r--r--pkgs/servers/mail/opensmtpd/extras.nix4
-rw-r--r--pkgs/servers/mail/postgrey/default.nix2
-rw-r--r--pkgs/servers/mail/postsrsd/default.nix4
-rw-r--r--pkgs/servers/mail/rspamd/default.nix2
-rw-r--r--pkgs/servers/mail/sympa/default.nix4
-rw-r--r--pkgs/servers/mail/system-sendmail/default.nix4
-rw-r--r--pkgs/servers/martin/default.nix4
-rw-r--r--pkgs/servers/matrix-synapse/default.nix2
-rw-r--r--pkgs/servers/matterbridge/default.nix4
-rw-r--r--pkgs/servers/mattermost/default.nix4
-rw-r--r--pkgs/servers/mattermost/matterircd.nix4
-rw-r--r--pkgs/servers/mautrix-whatsapp/default.nix4
-rw-r--r--pkgs/servers/mediatomb/default.nix4
-rw-r--r--pkgs/servers/memcached/default.nix4
-rw-r--r--pkgs/servers/metabase/default.nix4
-rw-r--r--pkgs/servers/microserver/default.nix4
-rw-r--r--pkgs/servers/miniflux/default.nix4
-rw-r--r--pkgs/servers/minio/default.nix4
-rw-r--r--pkgs/servers/misc/airsonic/default.nix4
-rw-r--r--pkgs/servers/misc/oven-media-engine/default.nix4
-rw-r--r--pkgs/servers/misc/qremotecontrol-server/default.nix4
-rw-r--r--pkgs/servers/misc/subsonic/default.nix4
-rw-r--r--pkgs/servers/monitoring/alertmanager-bot/default.nix4
-rw-r--r--pkgs/servers/monitoring/cadvisor/default.nix4
-rw-r--r--pkgs/servers/monitoring/consul-alerts/default.nix4
-rw-r--r--pkgs/servers/monitoring/fusion-inventory/default.nix2
-rw-r--r--pkgs/servers/monitoring/lcdproc/default.nix4
-rw-r--r--pkgs/servers/monitoring/loki/default.nix2
-rw-r--r--pkgs/servers/monitoring/longview/default.nix4
-rw-r--r--pkgs/servers/monitoring/munin/default.nix4
-rw-r--r--pkgs/servers/monitoring/nagios/plugins/check_ssl_cert.nix4
-rw-r--r--pkgs/servers/monitoring/net-snmp/default.nix4
-rw-r--r--pkgs/servers/monitoring/newrelic-sysmond/default.nix4
-rw-r--r--pkgs/servers/monitoring/plugins/esxi.nix4
-rw-r--r--pkgs/servers/monitoring/plugins/labs_consol_de.nix4
-rw-r--r--pkgs/servers/monitoring/plugins/uptime.nix4
-rw-r--r--pkgs/servers/monitoring/plugins/wmic-bin.nix2
-rw-r--r--pkgs/servers/monitoring/plugins/wmiplus/default.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/alertmanager.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/apcupsd-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/aws-s3-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/bind-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/bird-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/blackbox-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/collectd-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/consul-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/dnsmasq-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/dovecot-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/fritzbox-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/gitlab-ci-pipelines-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/haproxy-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/jmx-httpserver.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/keylight-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/lnd-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/mail-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/mesos-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/mikrotik-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/minio-exporter/default.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/modemmanager-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/mysqld-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/nginx-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/nginxlog-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/node-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/openvpn-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/process-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/prom2json.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/promscale.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/pushgateway.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/rabbitmq-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/redis-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/smokeping-prober.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/snmp-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/sql-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/statsd-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/surfboard-exporter.nix4
-rw-r--r--pkgs/servers/monitoring/prometheus/unifi-exporter/default.nix4
-rw-r--r--pkgs/servers/monitoring/riemann/default.nix4
-rw-r--r--pkgs/servers/monitoring/seyren/default.nix4
-rw-r--r--pkgs/servers/monitoring/thanos/default.nix4
-rw-r--r--pkgs/servers/monitoring/uchiwa/default.nix4
-rw-r--r--pkgs/servers/monitoring/unifi-poller/default.nix4
-rw-r--r--pkgs/servers/monitoring/zabbix/agent.nix4
-rw-r--r--pkgs/servers/monitoring/zabbix/proxy.nix4
-rw-r--r--pkgs/servers/monitoring/zabbix/server.nix4
-rw-r--r--pkgs/servers/monitoring/zabbix/web.nix4
-rw-r--r--pkgs/servers/monitoring/zipkin/default.nix4
-rw-r--r--pkgs/servers/mpd/clientlib.nix4
-rw-r--r--pkgs/servers/mpd/default.nix4
-rw-r--r--pkgs/servers/mqtt/mosquitto/default.nix2
-rw-r--r--pkgs/servers/mtprotoproxy/default.nix4
-rw-r--r--pkgs/servers/mxisd/default.nix4
-rw-r--r--pkgs/servers/nas/default.nix4
-rw-r--r--pkgs/servers/neard/default.nix4
-rw-r--r--pkgs/servers/nextcloud/default.nix4
-rw-r--r--pkgs/servers/nfs-ganesha/default.nix4
-rw-r--r--pkgs/servers/nginx-sso/default.nix4
-rw-r--r--pkgs/servers/nosql/aerospike/default.nix4
-rw-r--r--pkgs/servers/nosql/cassandra/generic.nix4
-rw-r--r--pkgs/servers/nosql/neo4j/default.nix4
-rw-r--r--pkgs/servers/nosql/redis/default.nix4
-rw-r--r--pkgs/servers/nzbhydra2/default.nix2
-rw-r--r--pkgs/servers/openafs/1.8/default.nix4
-rw-r--r--pkgs/servers/openafs/1.8/module.nix4
-rw-r--r--pkgs/servers/openafs/1.9/default.nix4
-rw-r--r--pkgs/servers/openafs/1.9/module.nix4
-rw-r--r--pkgs/servers/openbgpd/default.nix4
-rw-r--r--pkgs/servers/p910nd/default.nix4
-rw-r--r--pkgs/servers/plex/raw.nix4
-rw-r--r--pkgs/servers/polipo/default.nix4
-rw-r--r--pkgs/servers/pounce/default.nix4
-rw-r--r--pkgs/servers/pulseaudio/hsphfpd.nix4
-rw-r--r--pkgs/servers/quagga/default.nix4
-rw-r--r--pkgs/servers/radarr/default.nix4
-rw-r--r--pkgs/servers/radicale/1.x.nix4
-rw-r--r--pkgs/servers/radicale/2.x.nix4
-rw-r--r--pkgs/servers/rainloop/default.nix4
-rw-r--r--pkgs/servers/rippled/default.nix4
-rw-r--r--pkgs/servers/routinator/default.nix4
-rw-r--r--pkgs/servers/rpcbind/default.nix4
-rw-r--r--pkgs/servers/rtsp-simple-server/default.nix4
-rw-r--r--pkgs/servers/sabnzbd/default.nix4
-rw-r--r--pkgs/servers/samba/4.x.nix4
-rw-r--r--pkgs/servers/scylladb/default.nix4
-rw-r--r--pkgs/servers/search/elasticsearch/plugins.nix2
-rw-r--r--pkgs/servers/search/groonga/default.nix4
-rw-r--r--pkgs/servers/search/meilisearch/default.nix4
-rw-r--r--pkgs/servers/search/solr/default.nix4
-rw-r--r--pkgs/servers/serf/default.nix4
-rw-r--r--pkgs/servers/serviio/default.nix4
-rw-r--r--pkgs/servers/shairplay/default.nix4
-rw-r--r--pkgs/servers/shairport-sync/default.nix4
-rw-r--r--pkgs/servers/shellinabox/default.nix4
-rw-r--r--pkgs/servers/sickbeard/default.nix4
-rw-r--r--pkgs/servers/sickbeard/sickgear.nix4
-rw-r--r--pkgs/servers/sickbeard/sickrage.nix4
-rw-r--r--pkgs/servers/simplehttp2server/default.nix4
-rw-r--r--pkgs/servers/sks/default.nix4
-rw-r--r--pkgs/servers/slimserver/default.nix4
-rw-r--r--pkgs/servers/smcroute/default.nix4
-rw-r--r--pkgs/servers/softether/4.25.nix4
-rw-r--r--pkgs/servers/softether/4.29.nix4
-rw-r--r--pkgs/servers/sozu/default.nix4
-rw-r--r--pkgs/servers/sql/cockroachdb/default.nix4
-rw-r--r--pkgs/servers/sql/mariadb/galera/default.nix4
-rw-r--r--pkgs/servers/sql/monetdb/default.nix4
-rw-r--r--pkgs/servers/sql/mysql/5.7.x.nix4
-rw-r--r--pkgs/servers/sql/percona/5.6.x.nix4
-rw-r--r--pkgs/servers/sql/pgbouncer/default.nix4
-rw-r--r--pkgs/servers/sql/pgpool/default.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/age.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/cstore_fdw.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/periods.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_bigm.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_cron.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_ed25519.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_hll.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_partman.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_repack.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_safeupdate.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pg_topn.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pgjwt.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pgroonga.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pgrouting.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pgtap.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/pipelinedb.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/plpgsql_check.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/plv8.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/postgis.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/repmgr.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/smlar.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/tds_fdw.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/temporal_tables.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/timescaledb.nix4
-rw-r--r--pkgs/servers/sql/postgresql/ext/tsearch_extras.nix4
-rw-r--r--pkgs/servers/sql/sqlite/jdbc/default.nix4
-rw-r--r--pkgs/servers/sql/virtuoso/6.x.nix4
-rw-r--r--pkgs/servers/sql/virtuoso/7.x.nix4
-rw-r--r--pkgs/servers/squid/default.nix4
-rw-r--r--pkgs/servers/sslh/default.nix4
-rw-r--r--pkgs/servers/tacacsplus/default.nix4
-rw-r--r--pkgs/servers/tarssh/default.nix4
-rw-r--r--pkgs/servers/tegola/default.nix4
-rw-r--r--pkgs/servers/tmate-ssh-server/default.nix4
-rw-r--r--pkgs/servers/traefik/default.nix4
-rw-r--r--pkgs/servers/trezord/default.nix4
-rw-r--r--pkgs/servers/trickster/trickster.nix4
-rw-r--r--pkgs/servers/tt-rss/default.nix4
-rw-r--r--pkgs/servers/tt-rss/plugin-auth-ldap/default.nix4
-rw-r--r--pkgs/servers/tt-rss/plugin-ff-instagram/default.nix4
-rw-r--r--pkgs/servers/tt-rss/plugin-tumblr-gdpr/default.nix4
-rw-r--r--pkgs/servers/tt-rss/theme-feedly/default.nix4
-rw-r--r--pkgs/servers/tvheadend/default.nix4
-rw-r--r--pkgs/servers/u9fs/default.nix4
-rw-r--r--pkgs/servers/uhub/default.nix4
-rw-r--r--pkgs/servers/unifi/default.nix4
-rw-r--r--pkgs/servers/unpfs/default.nix4
-rw-r--r--pkgs/servers/ursadb/default.nix4
-rw-r--r--pkgs/servers/urserver/default.nix4
-rw-r--r--pkgs/servers/uwsgi/default.nix2
-rw-r--r--pkgs/servers/varnish/default.nix4
-rw-r--r--pkgs/servers/varnish/digest.nix4
-rw-r--r--pkgs/servers/varnish/dynamic.nix4
-rw-r--r--pkgs/servers/varnish/modules.nix4
-rw-r--r--pkgs/servers/web-apps/dokuwiki/default.nix4
-rw-r--r--pkgs/servers/web-apps/engelsystem/default.nix4
-rw-r--r--pkgs/servers/web-apps/fileshelter/default.nix4
-rw-r--r--pkgs/servers/web-apps/hedgedoc/default.nix4
-rw-r--r--pkgs/servers/web-apps/jirafeau/default.nix4
-rw-r--r--pkgs/servers/web-apps/jitsi-meet/default.nix4
-rw-r--r--pkgs/servers/web-apps/matomo/default.nix4
-rw-r--r--pkgs/servers/web-apps/mediawiki/default.nix4
-rw-r--r--pkgs/servers/web-apps/moodle/default.nix2
-rw-r--r--pkgs/servers/web-apps/morty/default.nix4
-rw-r--r--pkgs/servers/web-apps/pgpkeyserver-lite/default.nix4
-rw-r--r--pkgs/servers/web-apps/restya-board/default.nix4
-rw-r--r--pkgs/servers/web-apps/selfoss/default.nix4
-rw-r--r--pkgs/servers/web-apps/shaarli/default.nix4
-rw-r--r--pkgs/servers/web-apps/shiori/default.nix4
-rw-r--r--pkgs/servers/web-apps/wallabag/default.nix4
-rw-r--r--pkgs/servers/web-apps/wordpress/default.nix4
-rw-r--r--pkgs/servers/webmetro/default.nix4
-rw-r--r--pkgs/servers/wsdd/default.nix4
-rw-r--r--pkgs/servers/x11/quartz-wm/default.nix4
-rw-r--r--pkgs/servers/x11/xorg/xcb-util-xrm.nix4
-rw-r--r--pkgs/servers/x11/xquartz/default.nix4
-rw-r--r--pkgs/servers/xandikos/default.nix4
-rw-r--r--pkgs/servers/xmpp/biboumi/default.nix4
-rw-r--r--pkgs/servers/xmpp/ejabberd/default.nix2
-rw-r--r--pkgs/servers/xmpp/pyIRCt/default.nix4
-rw-r--r--pkgs/servers/xmpp/pyMAILt/default.nix4
-rw-r--r--pkgs/servers/zoneminder/default.nix2
-rw-r--r--pkgs/servers/zookeeper/default.nix4
-rw-r--r--pkgs/shells/any-nix-shell/default.nix4
-rw-r--r--pkgs/shells/bash/4.4.nix4
-rw-r--r--pkgs/shells/bash/5.1.nix4
-rw-r--r--pkgs/shells/bash/bash-completion/default.nix4
-rw-r--r--pkgs/shells/bash/nix-bash-completions/default.nix4
-rw-r--r--pkgs/shells/dash/default.nix4
-rw-r--r--pkgs/shells/dgsh/default.nix4
-rw-r--r--pkgs/shells/elvish/default.nix4
-rw-r--r--pkgs/shells/es/default.nix4
-rw-r--r--pkgs/shells/ion/default.nix4
-rw-r--r--pkgs/shells/jush/default.nix4
-rw-r--r--pkgs/shells/ksh/default.nix4
-rw-r--r--pkgs/shells/liquidprompt/default.nix4
-rw-r--r--pkgs/shells/mksh/default.nix4
-rw-r--r--pkgs/shells/mrsh/default.nix4
-rw-r--r--pkgs/shells/oksh/default.nix2
-rw-r--r--pkgs/shells/pash/default.nix4
-rw-r--r--pkgs/shells/rc/default.nix4
-rw-r--r--pkgs/shells/tcsh/default.nix4
-rw-r--r--pkgs/shells/xonsh/default.nix4
-rw-r--r--pkgs/shells/zsh/fzf-zsh/default.nix4
-rw-r--r--pkgs/shells/zsh/gradle-completion/default.nix4
-rw-r--r--pkgs/shells/zsh/grml-zsh-config/default.nix2
-rw-r--r--pkgs/shells/zsh/lambda-mod-zsh-theme/default.nix4
-rw-r--r--pkgs/shells/zsh/nix-zsh-completions/default.nix4
-rw-r--r--pkgs/shells/zsh/oh-my-zsh/default.nix4
-rw-r--r--pkgs/shells/zsh/spaceship-prompt/default.nix4
-rw-r--r--pkgs/shells/zsh/zsh-autosuggestions/default.nix4
-rw-r--r--pkgs/shells/zsh/zsh-command-time/default.nix4
-rw-r--r--pkgs/shells/zsh/zsh-deer/default.nix4
-rw-r--r--pkgs/shells/zsh/zsh-nix-shell/default.nix4
-rw-r--r--pkgs/shells/zsh/zsh-prezto/default.nix4
-rw-r--r--pkgs/shells/zsh/zsh-syntax-highlighting/default.nix4
-rw-r--r--pkgs/shells/zsh/zsh-you-should-use/default.nix4
-rw-r--r--pkgs/tools/X11/alttab/default.nix4
-rw-r--r--pkgs/tools/X11/bgs/default.nix4
-rw-r--r--pkgs/tools/X11/bumblebee/default.nix2
-rw-r--r--pkgs/tools/X11/ckbcomp/default.nix4
-rw-r--r--pkgs/tools/X11/devour/default.nix4
-rw-r--r--pkgs/tools/X11/dex/default.nix4
-rw-r--r--pkgs/tools/X11/dispad/default.nix4
-rw-r--r--pkgs/tools/X11/dragon-drop/default.nix4
-rw-r--r--pkgs/tools/X11/ffcast/default.nix4
-rw-r--r--pkgs/tools/X11/find-cursor/default.nix4
-rw-r--r--pkgs/tools/X11/go-sct/default.nix4
-rw-r--r--pkgs/tools/X11/grobi/default.nix4
-rw-r--r--pkgs/tools/X11/hsetroot/default.nix4
-rw-r--r--pkgs/tools/X11/imwheel/default.nix4
-rw-r--r--pkgs/tools/X11/keynav/default.nix4
-rw-r--r--pkgs/tools/X11/ksuperkey/default.nix4
-rw-r--r--pkgs/tools/X11/libstrangle/default.nix4
-rw-r--r--pkgs/tools/X11/ncview/default.nix4
-rw-r--r--pkgs/tools/X11/numlockx/default.nix4
-rw-r--r--pkgs/tools/X11/primus/lib.nix4
-rw-r--r--pkgs/tools/X11/run-scaled/default.nix4
-rw-r--r--pkgs/tools/X11/sct/default.nix4
-rw-r--r--pkgs/tools/X11/setroot/default.nix4
-rw-r--r--pkgs/tools/X11/srandrd/default.nix4
-rw-r--r--pkgs/tools/X11/vdpauinfo/default.nix4
-rw-r--r--pkgs/tools/X11/virtualgl/lib.nix4
-rw-r--r--pkgs/tools/X11/wmutils-core/default.nix4
-rw-r--r--pkgs/tools/X11/wmutils-libwm/default.nix4
-rw-r--r--pkgs/tools/X11/wmutils-opt/default.nix4
-rw-r--r--pkgs/tools/X11/wpgtk/default.nix4
-rw-r--r--pkgs/tools/X11/x11spice/default.nix4
-rw-r--r--pkgs/tools/X11/x11vnc/default.nix4
-rw-r--r--pkgs/tools/X11/x2vnc/default.nix4
-rw-r--r--pkgs/tools/X11/x2x/default.nix4
-rw-r--r--pkgs/tools/X11/xcalib/default.nix4
-rw-r--r--pkgs/tools/X11/xcape/default.nix4
-rw-r--r--pkgs/tools/X11/xcwd/default.nix4
-rw-r--r--pkgs/tools/X11/xdg-user-dirs/default.nix4
-rw-r--r--pkgs/tools/X11/xdg-utils/default.nix4
-rw-r--r--pkgs/tools/X11/xgeometry-select/default.nix4
-rw-r--r--pkgs/tools/X11/xkb-switch-i3/default.nix4
-rw-r--r--pkgs/tools/X11/xkb-switch/default.nix4
-rw-r--r--pkgs/tools/X11/xkbset/default.nix4
-rw-r--r--pkgs/tools/X11/xlayoutdisplay/default.nix4
-rw-r--r--pkgs/tools/X11/xmagnify/default.nix4
-rw-r--r--pkgs/tools/X11/xmousepasteblock/default.nix4
-rw-r--r--pkgs/tools/X11/xob/default.nix4
-rw-r--r--pkgs/tools/X11/xosview2/default.nix4
-rw-r--r--pkgs/tools/X11/xpra/libfakeXinerama.nix4
-rw-r--r--pkgs/tools/X11/xrectsel/default.nix4
-rw-r--r--pkgs/tools/X11/xsettingsd/default.nix4
-rw-r--r--pkgs/tools/X11/xtrace/default.nix4
-rw-r--r--pkgs/tools/X11/xtruss/default.nix4
-rw-r--r--pkgs/tools/X11/xvkbd/default.nix4
-rw-r--r--pkgs/tools/X11/xwallpaper/default.nix4
-rw-r--r--pkgs/tools/X11/xwinwrap/default.nix4
-rw-r--r--pkgs/tools/admin/acme.sh/default.nix2
-rw-r--r--pkgs/tools/admin/adtool/default.nix4
-rw-r--r--pkgs/tools/admin/aws-nuke/default.nix4
-rw-r--r--pkgs/tools/admin/aws-rotate-key/default.nix4
-rw-r--r--pkgs/tools/admin/awslogs/default.nix4
-rw-r--r--pkgs/tools/admin/bash-my-aws/default.nix4
-rw-r--r--pkgs/tools/admin/berglas/default.nix4
-rw-r--r--pkgs/tools/admin/bubblewrap/default.nix4
-rw-r--r--pkgs/tools/admin/certigo/default.nix4
-rw-r--r--pkgs/tools/admin/chkcrontab/default.nix4
-rw-r--r--pkgs/tools/admin/credhub-cli/default.nix4
-rw-r--r--pkgs/tools/admin/dehydrated/default.nix4
-rw-r--r--pkgs/tools/admin/docker-credential-gcr/default.nix4
-rw-r--r--pkgs/tools/admin/docker-credential-helpers/default.nix4
-rw-r--r--pkgs/tools/admin/fastlane/default.nix4
-rw-r--r--pkgs/tools/admin/google-cloud-sdk/default.nix2
-rw-r--r--pkgs/tools/admin/gtk-vnc/default.nix4
-rw-r--r--pkgs/tools/admin/iamy/default.nix4
-rw-r--r--pkgs/tools/admin/lxd/default.nix4
-rw-r--r--pkgs/tools/admin/nomachine-client/default.nix4
-rw-r--r--pkgs/tools/admin/procs/default.nix4
-rw-r--r--pkgs/tools/admin/s3bro/default.nix4
-rw-r--r--pkgs/tools/admin/scaleway-cli/default.nix4
-rw-r--r--pkgs/tools/admin/sewer/default.nix4
-rw-r--r--pkgs/tools/admin/simp_le/default.nix4
-rw-r--r--pkgs/tools/admin/ssh-import-id/default.nix4
-rw-r--r--pkgs/tools/admin/ssl-cert-check/default.nix4
-rw-r--r--pkgs/tools/admin/ssmsh/default.nix4
-rw-r--r--pkgs/tools/admin/stripe-cli/default.nix4
-rw-r--r--pkgs/tools/admin/virtscreen/default.nix4
-rw-r--r--pkgs/tools/archivers/arc_unpacker/default.nix4
-rw-r--r--pkgs/tools/archivers/bomutils/default.nix4
-rw-r--r--pkgs/tools/archivers/cabextract/default.nix4
-rw-r--r--pkgs/tools/archivers/cpio/default.nix4
-rw-r--r--pkgs/tools/archivers/cromfs/default.nix4
-rw-r--r--pkgs/tools/archivers/ctrtool/default.nix4
-rw-r--r--pkgs/tools/archivers/fsarchiver/default.nix4
-rw-r--r--pkgs/tools/archivers/innoextract/default.nix4
-rw-r--r--pkgs/tools/archivers/maxcso/default.nix4
-rw-r--r--pkgs/tools/archivers/pax/default.nix4
-rw-r--r--pkgs/tools/archivers/rpmextract/default.nix4
-rw-r--r--pkgs/tools/archivers/sharutils/default.nix4
-rw-r--r--pkgs/tools/archivers/snzip/default.nix2
-rw-r--r--pkgs/tools/archivers/unar/default.nix4
-rw-r--r--pkgs/tools/archivers/undmg/default.nix4
-rw-r--r--pkgs/tools/archivers/unp/default.nix2
-rw-r--r--pkgs/tools/archivers/unrar/default.nix4
-rw-r--r--pkgs/tools/archivers/unshield/default.nix4
-rw-r--r--pkgs/tools/archivers/wimlib/default.nix4
-rw-r--r--pkgs/tools/archivers/zip/default.nix4
-rw-r--r--pkgs/tools/archivers/zpaq/default.nix4
-rw-r--r--pkgs/tools/archivers/zpaq/zpaqd.nix4
-rw-r--r--pkgs/tools/audio/abcm2ps/default.nix4
-rw-r--r--pkgs/tools/audio/abcmidi/default.nix4
-rw-r--r--pkgs/tools/audio/accuraterip-checksum/default.nix4
-rw-r--r--pkgs/tools/audio/acoustid-fingerprinter/default.nix4
-rw-r--r--pkgs/tools/audio/alsaequal/default.nix4
-rw-r--r--pkgs/tools/audio/audiowaveform/default.nix4
-rw-r--r--pkgs/tools/audio/beets/plugins/check.nix4
-rw-r--r--pkgs/tools/audio/bpm-tools/default.nix4
-rw-r--r--pkgs/tools/audio/dir2opus/default.nix4
-rw-r--r--pkgs/tools/audio/essentia-extractor/default.nix4
-rw-r--r--pkgs/tools/audio/ezstream/default.nix4
-rw-r--r--pkgs/tools/audio/glyr/default.nix4
-rw-r--r--pkgs/tools/audio/kaldi/default.nix4
-rw-r--r--pkgs/tools/audio/liquidsoap/full.nix4
-rw-r--r--pkgs/tools/audio/midicsv/default.nix4
-rw-r--r--pkgs/tools/audio/mididings/default.nix4
-rw-r--r--pkgs/tools/audio/mp3cat/default.nix4
-rw-r--r--pkgs/tools/audio/mpd-mpris/default.nix4
-rw-r--r--pkgs/tools/audio/mpdas/default.nix4
-rw-r--r--pkgs/tools/audio/mpdcron/default.nix4
-rw-r--r--pkgs/tools/audio/mpdris2/default.nix4
-rw-r--r--pkgs/tools/audio/mpris-scrobbler/default.nix4
-rw-r--r--pkgs/tools/audio/opl3bankeditor/default.nix4
-rw-r--r--pkgs/tools/audio/pa-applet/default.nix4
-rw-r--r--pkgs/tools/audio/pasystray/default.nix4
-rw-r--r--pkgs/tools/audio/playerctl/default.nix4
-rw-r--r--pkgs/tools/audio/pnmixer/default.nix4
-rw-r--r--pkgs/tools/audio/pulsemixer/default.nix4
-rw-r--r--pkgs/tools/audio/trx/default.nix4
-rw-r--r--pkgs/tools/audio/video2midi/default.nix4
-rw-r--r--pkgs/tools/audio/volctl/default.nix4
-rw-r--r--pkgs/tools/audio/volumeicon/default.nix4
-rw-r--r--pkgs/tools/backup/automysqlbackup/default.nix4
-rw-r--r--pkgs/tools/backup/bacula/default.nix4
-rw-r--r--pkgs/tools/backup/bareos/default.nix4
-rw-r--r--pkgs/tools/backup/bdsync/default.nix4
-rw-r--r--pkgs/tools/backup/borg/default.nix4
-rw-r--r--pkgs/tools/backup/btrbk/default.nix4
-rw-r--r--pkgs/tools/backup/burp/default.nix4
-rw-r--r--pkgs/tools/backup/dedup/default.nix4
-rw-r--r--pkgs/tools/backup/dirvish/default.nix4
-rw-r--r--pkgs/tools/backup/diskrsync/default.nix4
-rw-r--r--pkgs/tools/backup/dump/default.nix4
-rw-r--r--pkgs/tools/backup/duplicati/default.nix4
-rw-r--r--pkgs/tools/backup/duplicity/default.nix4
-rw-r--r--pkgs/tools/backup/duply/default.nix4
-rw-r--r--pkgs/tools/backup/easysnap/default.nix4
-rw-r--r--pkgs/tools/backup/flockit/default.nix4
-rw-r--r--pkgs/tools/backup/grab-site/default.nix4
-rw-r--r--pkgs/tools/backup/hpe-ltfs/default.nix4
-rw-r--r--pkgs/tools/backup/httrack/default.nix4
-rw-r--r--pkgs/tools/backup/httrack/qt.nix4
-rw-r--r--pkgs/tools/backup/lvmsync/default.nix4
-rw-r--r--pkgs/tools/backup/monolith/default.nix4
-rw-r--r--pkgs/tools/backup/mydumper/default.nix4
-rw-r--r--pkgs/tools/backup/ori/default.nix4
-rw-r--r--pkgs/tools/backup/percona-xtrabackup/generic.nix4
-rw-r--r--pkgs/tools/backup/rdedup/default.nix4
-rw-r--r--pkgs/tools/backup/rsnapshot/default.nix4
-rw-r--r--pkgs/tools/backup/s3ql/default.nix4
-rw-r--r--pkgs/tools/backup/ugarit-manifest-maker/default.nix4
-rw-r--r--pkgs/tools/backup/ugarit/default.nix4
-rw-r--r--pkgs/tools/backup/zfs-prune-snapshots/default.nix4
-rw-r--r--pkgs/tools/backup/zfs-replicate/default.nix4
-rw-r--r--pkgs/tools/backup/zfsnap/default.nix4
-rw-r--r--pkgs/tools/backup/znapzend/default.nix4
-rw-r--r--pkgs/tools/bluetooth/bluez-tools/default.nix4
-rw-r--r--pkgs/tools/bluetooth/obex-data-server/default.nix4
-rw-r--r--pkgs/tools/bluetooth/obexd/default.nix4
-rw-r--r--pkgs/tools/bluetooth/obexfs/default.nix4
-rw-r--r--pkgs/tools/bluetooth/obexftp/default.nix4
-rw-r--r--pkgs/tools/bluetooth/openobex/default.nix4
-rw-r--r--pkgs/tools/bootloaders/refind/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/bashburn/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/bchunk/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/brasero/default.nix2
-rw-r--r--pkgs/tools/cd-dvd/ccd2iso/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/cdi2iso/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/cdimgtools/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/cdrdao/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/cdrtools/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/cuetools/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/dvd+rw-tools/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/dvd-vr/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/dvdisaster/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/ecm-tools/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/isolyzer/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/isomd5sum/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/lsdvd/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/mdf2iso/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/mkcue/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/nrg2iso/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/sacd/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/srt-to-vtt-cl/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/unetbootin/default.nix4
-rw-r--r--pkgs/tools/cd-dvd/xorriso/default.nix4
-rw-r--r--pkgs/tools/compression/advancecomp/default.nix4
-rw-r--r--pkgs/tools/compression/brotli/default.nix4
-rw-r--r--pkgs/tools/compression/bsc/default.nix4
-rw-r--r--pkgs/tools/compression/bzip2/1_1.nix4
-rw-r--r--pkgs/tools/compression/bzip2/default.nix4
-rw-r--r--pkgs/tools/compression/dejsonlz4/default.nix4
-rw-r--r--pkgs/tools/compression/dtrx/default.nix2
-rw-r--r--pkgs/tools/compression/flips/default.nix4
-rw-r--r--pkgs/tools/compression/hactool/default.nix4
-rw-r--r--pkgs/tools/compression/lbzip2/default.nix4
-rw-r--r--pkgs/tools/compression/lz4/default.nix4
-rw-r--r--pkgs/tools/compression/lzbench/default.nix4
-rw-r--r--pkgs/tools/compression/lzfse/default.nix4
-rw-r--r--pkgs/tools/compression/lzham/default.nix4
-rw-r--r--pkgs/tools/compression/lzop/default.nix4
-rw-r--r--pkgs/tools/compression/pbzip2/default.nix4
-rw-r--r--pkgs/tools/compression/pigz/default.nix4
-rw-r--r--pkgs/tools/compression/upx/default.nix4
-rw-r--r--pkgs/tools/compression/xdelta/default.nix4
-rw-r--r--pkgs/tools/compression/xdelta/unstable.nix4
-rw-r--r--pkgs/tools/compression/xz/default.nix4
-rw-r--r--pkgs/tools/compression/zdelta/default.nix4
-rw-r--r--pkgs/tools/compression/zopfli/default.nix4
-rw-r--r--pkgs/tools/compression/zstd/default.nix4
-rw-r--r--pkgs/tools/filesystems/aefs/default.nix4
-rw-r--r--pkgs/tools/filesystems/afpfs-ng/default.nix4
-rw-r--r--pkgs/tools/filesystems/android-file-transfer/default.nix4
-rw-r--r--pkgs/tools/filesystems/apfs-fuse/default.nix4
-rw-r--r--pkgs/tools/filesystems/bashmount/default.nix4
-rw-r--r--pkgs/tools/filesystems/bcache-tools/default.nix4
-rw-r--r--pkgs/tools/filesystems/bcachefs-tools/default.nix4
-rw-r--r--pkgs/tools/filesystems/bees/default.nix4
-rw-r--r--pkgs/tools/filesystems/blobfuse/default.nix4
-rw-r--r--pkgs/tools/filesystems/boxfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/btrfs-progs/default.nix4
-rw-r--r--pkgs/tools/filesystems/catcli/default.nix4
-rw-r--r--pkgs/tools/filesystems/convoy/default.nix4
-rw-r--r--pkgs/tools/filesystems/cpcfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/cryfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/curlftpfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/darling-dmg/default.nix4
-rw-r--r--pkgs/tools/filesystems/dislocker/default.nix4
-rw-r--r--pkgs/tools/filesystems/disorderfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/duff/default.nix4
-rw-r--r--pkgs/tools/filesystems/duperemove/default.nix4
-rw-r--r--pkgs/tools/filesystems/e2fsprogs/default.nix4
-rw-r--r--pkgs/tools/filesystems/encfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/exfat/default.nix4
-rw-r--r--pkgs/tools/filesystems/ext4magic/default.nix4
-rw-r--r--pkgs/tools/filesystems/extundelete/default.nix4
-rw-r--r--pkgs/tools/filesystems/f2fs-tools/default.nix4
-rw-r--r--pkgs/tools/filesystems/fatresize/default.nix4
-rw-r--r--pkgs/tools/filesystems/fatsort/default.nix4
-rw-r--r--pkgs/tools/filesystems/file-rename/default.nix4
-rw-r--r--pkgs/tools/filesystems/fuse-7z-ng/default.nix4
-rw-r--r--pkgs/tools/filesystems/fuse-overlayfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/fuseiso/default.nix4
-rw-r--r--pkgs/tools/filesystems/genext2fs/default.nix4
-rw-r--r--pkgs/tools/filesystems/genimage/default.nix4
-rw-r--r--pkgs/tools/filesystems/genromfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/glusterfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/gocryptfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/gpart/default.nix4
-rw-r--r--pkgs/tools/filesystems/grive2/default.nix4
-rw-r--r--pkgs/tools/filesystems/hubicfuse/default.nix4
-rw-r--r--pkgs/tools/filesystems/idsk/default.nix4
-rw-r--r--pkgs/tools/filesystems/ifuse/default.nix4
-rw-r--r--pkgs/tools/filesystems/jfsutils/default.nix4
-rw-r--r--pkgs/tools/filesystems/jmtpfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/lizardfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/mergerfs/tools.nix4
-rw-r--r--pkgs/tools/filesystems/mkspiffs/default.nix4
-rw-r--r--pkgs/tools/filesystems/moosefs/default.nix4
-rw-r--r--pkgs/tools/filesystems/mp3fs/default.nix4
-rw-r--r--pkgs/tools/filesystems/mtools/default.nix4
-rw-r--r--pkgs/tools/filesystems/mtpfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/nilfs-utils/default.nix4
-rw-r--r--pkgs/tools/filesystems/nixpart/0.4/blivet.nix4
-rw-r--r--pkgs/tools/filesystems/nixpart/0.4/default.nix4
-rw-r--r--pkgs/tools/filesystems/ntfs-3g/default.nix4
-rw-r--r--pkgs/tools/filesystems/orangefs/default.nix4
-rw-r--r--pkgs/tools/filesystems/rar2fs/default.nix4
-rw-r--r--pkgs/tools/filesystems/rdfind/default.nix4
-rw-r--r--pkgs/tools/filesystems/reiser4progs/default.nix4
-rw-r--r--pkgs/tools/filesystems/rmount/default.nix4
-rw-r--r--pkgs/tools/filesystems/romdirfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/s3backer/default.nix4
-rw-r--r--pkgs/tools/filesystems/s3fs/default.nix4
-rw-r--r--pkgs/tools/filesystems/sandboxfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/sasquatch/default.nix4
-rw-r--r--pkgs/tools/filesystems/securefs/default.nix4
-rw-r--r--pkgs/tools/filesystems/simg2img/default.nix4
-rw-r--r--pkgs/tools/filesystems/smbnetfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/sshfs-fuse/default.nix4
-rw-r--r--pkgs/tools/filesystems/tmsu/default.nix4
-rw-r--r--pkgs/tools/filesystems/u3-tool/default.nix4
-rw-r--r--pkgs/tools/filesystems/ubidump/default.nix4
-rw-r--r--pkgs/tools/filesystems/udftools/default.nix4
-rw-r--r--pkgs/tools/filesystems/unionfs-fuse/default.nix4
-rw-r--r--pkgs/tools/filesystems/vmfs-tools/default.nix4
-rw-r--r--pkgs/tools/filesystems/wdfs/default.nix4
-rw-r--r--pkgs/tools/filesystems/wiimms-iso-tools/default.nix4
-rw-r--r--pkgs/tools/filesystems/xfsprogs/default.nix4
-rw-r--r--pkgs/tools/filesystems/zfstools/default.nix4
-rw-r--r--pkgs/tools/graphics/amber/default.nix4
-rw-r--r--pkgs/tools/graphics/appleseed/default.nix4
-rw-r--r--pkgs/tools/graphics/argyllcms/default.nix2
-rw-r--r--pkgs/tools/graphics/asymptote/default.nix4
-rw-r--r--pkgs/tools/graphics/barcode/default.nix4
-rw-r--r--pkgs/tools/graphics/blockhash/default.nix4
-rw-r--r--pkgs/tools/graphics/blur-effect/default.nix4
-rw-r--r--pkgs/tools/graphics/cfdg/default.nix4
-rw-r--r--pkgs/tools/graphics/cuneiform/default.nix4
-rw-r--r--pkgs/tools/graphics/directx-shader-compiler/default.nix4
-rw-r--r--pkgs/tools/graphics/ditaa/default.nix4
-rw-r--r--pkgs/tools/graphics/dpic/default.nix4
-rw-r--r--pkgs/tools/graphics/editres/default.nix4
-rw-r--r--pkgs/tools/graphics/enblend-enfuse/default.nix4
-rw-r--r--pkgs/tools/graphics/eplot/default.nix4
-rw-r--r--pkgs/tools/graphics/epstool/default.nix4
-rw-r--r--pkgs/tools/graphics/exif/default.nix4
-rw-r--r--pkgs/tools/graphics/exifprobe/default.nix4
-rw-r--r--pkgs/tools/graphics/facedetect/default.nix4
-rw-r--r--pkgs/tools/graphics/fbv/default.nix4
-rw-r--r--pkgs/tools/graphics/feedgnuplot/default.nix4
-rw-r--r--pkgs/tools/graphics/fgallery/default.nix4
-rw-r--r--pkgs/tools/graphics/flam3/default.nix4
-rw-r--r--pkgs/tools/graphics/ggobi/default.nix4
-rw-r--r--pkgs/tools/graphics/gifski/default.nix4
-rw-r--r--pkgs/tools/graphics/glee/default.nix4
-rw-r--r--pkgs/tools/graphics/glmark2/default.nix4
-rw-r--r--pkgs/tools/graphics/glxinfo/default.nix4
-rw-r--r--pkgs/tools/graphics/gmic/default.nix4
-rw-r--r--pkgs/tools/graphics/graph-easy/default.nix4
-rw-r--r--pkgs/tools/graphics/graphviz/base.nix4
-rw-r--r--pkgs/tools/graphics/grim/default.nix4
-rw-r--r--pkgs/tools/graphics/gromit-mpx/default.nix4
-rw-r--r--pkgs/tools/graphics/ibniz/default.nix4
-rw-r--r--pkgs/tools/graphics/imageworsener/default.nix4
-rw-r--r--pkgs/tools/graphics/imgur-screenshot/default.nix4
-rw-r--r--pkgs/tools/graphics/imgurbash2/default.nix4
-rw-r--r--pkgs/tools/graphics/jhead/default.nix4
-rw-r--r--pkgs/tools/graphics/lepton/default.nix4
-rw-r--r--pkgs/tools/graphics/logstalgia/default.nix4
-rw-r--r--pkgs/tools/graphics/luxcorerender/default.nix4
-rw-r--r--pkgs/tools/graphics/maim/default.nix4
-rw-r--r--pkgs/tools/graphics/mesa-demos/default.nix4
-rw-r--r--pkgs/tools/graphics/nifskope/default.nix4
-rw-r--r--pkgs/tools/graphics/nip2/default.nix4
-rw-r--r--pkgs/tools/graphics/optar/default.nix4
-rw-r--r--pkgs/tools/graphics/optipng/default.nix4
-rw-r--r--pkgs/tools/graphics/oxipng/default.nix4
-rw-r--r--pkgs/tools/graphics/pdf2svg/default.nix4
-rw-r--r--pkgs/tools/graphics/pdfread/default.nix4
-rw-r--r--pkgs/tools/graphics/pdfredacttools/default.nix4
-rw-r--r--pkgs/tools/graphics/pdftag/default.nix4
-rw-r--r--pkgs/tools/graphics/perceptualdiff/default.nix4
-rw-r--r--pkgs/tools/graphics/pfstools/default.nix4
-rw-r--r--pkgs/tools/graphics/ploticus/default.nix4
-rw-r--r--pkgs/tools/graphics/pngnq/default.nix4
-rw-r--r--pkgs/tools/graphics/pngquant/default.nix4
-rw-r--r--pkgs/tools/graphics/povray/default.nix4
-rw-r--r--pkgs/tools/graphics/pstoedit/default.nix2
-rw-r--r--pkgs/tools/graphics/qrcode/default.nix4
-rw-r--r--pkgs/tools/graphics/rocket/default.nix4
-rw-r--r--pkgs/tools/graphics/scanbd/default.nix4
-rw-r--r--pkgs/tools/graphics/scrot/default.nix4
-rw-r--r--pkgs/tools/graphics/sng/default.nix4
-rw-r--r--pkgs/tools/graphics/spirv-cross/default.nix4
-rw-r--r--pkgs/tools/graphics/structure-synth/default.nix4
-rw-r--r--pkgs/tools/graphics/svgcleaner/default.nix4
-rw-r--r--pkgs/tools/graphics/twilight/default.nix4
-rw-r--r--pkgs/tools/graphics/unpaper/default.nix4
-rw-r--r--pkgs/tools/graphics/vips/default.nix4
-rw-r--r--pkgs/tools/graphics/vulkan-extension-layer/default.nix4
-rw-r--r--pkgs/tools/graphics/vulkan-tools-lunarg/default.nix2
-rw-r--r--pkgs/tools/graphics/vulkan-tools/default.nix2
-rw-r--r--pkgs/tools/graphics/xcur2png/default.nix4
-rw-r--r--pkgs/tools/graphics/yafaray-core/default.nix4
-rw-r--r--pkgs/tools/graphics/yaxg/default.nix4
-rw-r--r--pkgs/tools/inputmethods/anthy/default.nix4
-rw-r--r--pkgs/tools/inputmethods/evdevremapkeys/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-anthy/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-chewing/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-cloudpinyin/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-hangul/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-libpinyin/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-m17n/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-rime/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-skk/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-table-extra/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-table-other/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx-engines/fcitx-unikey/default.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx/fcitx-configtool.nix4
-rw-r--r--pkgs/tools/inputmethods/fcitx/unwrapped.nix4
-rw-r--r--pkgs/tools/inputmethods/hime/default.nix2
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-anthy/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-bamboo/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-kkc/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-libpinyin/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-libthai/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-m17n/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-mozc/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-rime/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-table-chinese/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-table-others/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-table/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-typing-booster/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus-engines/ibus-uniemoji/default.nix4
-rw-r--r--pkgs/tools/inputmethods/ibus/ibus-qt.nix4
-rw-r--r--pkgs/tools/inputmethods/interception-tools/caps2esc.nix4
-rw-r--r--pkgs/tools/inputmethods/keyfuzz/default.nix4
-rw-r--r--pkgs/tools/inputmethods/libinput-gestures/default.nix2
-rw-r--r--pkgs/tools/inputmethods/libkkc/default.nix4
-rw-r--r--pkgs/tools/inputmethods/nabi/default.nix4
-rw-r--r--pkgs/tools/inputmethods/netevent/default.nix4
-rw-r--r--pkgs/tools/inputmethods/tegaki-zinnia-japanese/default.nix4
-rw-r--r--pkgs/tools/inputmethods/triggerhappy/default.nix4
-rw-r--r--pkgs/tools/inputmethods/uim/default.nix4
-rw-r--r--pkgs/tools/inputmethods/zinnia/default.nix4
-rw-r--r--pkgs/tools/misc/0x0/default.nix4
-rw-r--r--pkgs/tools/misc/3mux/default.nix4
-rw-r--r--pkgs/tools/misc/adafruit-ampy/default.nix4
-rw-r--r--pkgs/tools/misc/aescrypt/default.nix4
-rw-r--r--pkgs/tools/misc/agedu/default.nix4
-rw-r--r--pkgs/tools/misc/alarm-clock-applet/default.nix4
-rw-r--r--pkgs/tools/misc/apparix/default.nix4
-rw-r--r--pkgs/tools/misc/apt-offline/default.nix4
-rw-r--r--pkgs/tools/misc/aptly/default.nix4
-rw-r--r--pkgs/tools/misc/archi/default.nix4
-rw-r--r--pkgs/tools/misc/arp-scan/default.nix4
-rw-r--r--pkgs/tools/misc/asciinema-scenario/default.nix4
-rw-r--r--pkgs/tools/misc/aspcud/default.nix4
-rw-r--r--pkgs/tools/misc/autojump/default.nix4
-rw-r--r--pkgs/tools/misc/automirror/default.nix4
-rw-r--r--pkgs/tools/misc/autorandr/default.nix4
-rw-r--r--pkgs/tools/misc/autorevision/default.nix4
-rw-r--r--pkgs/tools/misc/azure-vhd-utils/default.nix4
-rw-r--r--pkgs/tools/misc/bandwidth/default.nix4
-rw-r--r--pkgs/tools/misc/bash_unit/default.nix4
-rw-r--r--pkgs/tools/misc/bashcards/default.nix4
-rw-r--r--pkgs/tools/misc/bashplotlib/default.nix4
-rw-r--r--pkgs/tools/misc/bat-extras/default.nix4
-rw-r--r--pkgs/tools/misc/bat/default.nix4
-rw-r--r--pkgs/tools/misc/bbe/default.nix4
-rw-r--r--pkgs/tools/misc/bcunit/default.nix4
-rw-r--r--pkgs/tools/misc/bdf2psf/default.nix4
-rw-r--r--pkgs/tools/misc/bdf2sfd/default.nix4
-rw-r--r--pkgs/tools/misc/betterdiscordctl/default.nix4
-rw-r--r--pkgs/tools/misc/bfr/default.nix4
-rw-r--r--pkgs/tools/misc/bibtex2html/default.nix4
-rw-r--r--pkgs/tools/misc/bibtool/default.nix4
-rw-r--r--pkgs/tools/misc/bibutils/default.nix4
-rw-r--r--pkgs/tools/misc/birdfont/default.nix4
-rw-r--r--pkgs/tools/misc/birdfont/xmlbird.nix4
-rw-r--r--pkgs/tools/misc/bmap-tools/default.nix4
-rw-r--r--pkgs/tools/misc/bmon/default.nix4
-rw-r--r--pkgs/tools/misc/bonfire/default.nix4
-rw-r--r--pkgs/tools/misc/broadlink-cli/default.nix4
-rw-r--r--pkgs/tools/misc/broot/default.nix4
-rw-r--r--pkgs/tools/misc/buildtorrent/default.nix4
-rw-r--r--pkgs/tools/misc/byobu/default.nix4
-rw-r--r--pkgs/tools/misc/capture/default.nix4
-rw-r--r--pkgs/tools/misc/ccze/default.nix4
-rw-r--r--pkgs/tools/misc/chafa/default.nix4
-rw-r--r--pkgs/tools/misc/chelf/default.nix4
-rw-r--r--pkgs/tools/misc/chezmoi/default.nix4
-rw-r--r--pkgs/tools/misc/chrome-export/default.nix4
-rw-r--r--pkgs/tools/misc/cht.sh/default.nix4
-rw-r--r--pkgs/tools/misc/ckb-next/default.nix4
-rw-r--r--pkgs/tools/misc/clac/default.nix4
-rw-r--r--pkgs/tools/misc/clasp/default.nix4
-rw-r--r--pkgs/tools/misc/claws/default.nix4
-rw-r--r--pkgs/tools/misc/clex/default.nix4
-rw-r--r--pkgs/tools/misc/clipnotify/default.nix4
-rw-r--r--pkgs/tools/misc/clipster/default.nix4
-rw-r--r--pkgs/tools/misc/cloud-sql-proxy/default.nix4
-rw-r--r--pkgs/tools/misc/cloud-utils/default.nix4
-rw-r--r--pkgs/tools/misc/clpeak/default.nix4
-rw-r--r--pkgs/tools/misc/code-minimap/default.nix4
-rw-r--r--pkgs/tools/misc/codebraid/default.nix4
-rw-r--r--pkgs/tools/misc/colord-gtk/default.nix4
-rw-r--r--pkgs/tools/misc/colord/default.nix4
-rw-r--r--pkgs/tools/misc/colorpicker/default.nix4
-rw-r--r--pkgs/tools/misc/contacts/default.nix4
-rw-r--r--pkgs/tools/misc/convbin/default.nix4
-rw-r--r--pkgs/tools/misc/convfont/default.nix4
-rw-r--r--pkgs/tools/misc/convimg/default.nix4
-rw-r--r--pkgs/tools/misc/convmv/default.nix4
-rw-r--r--pkgs/tools/misc/cowsay/default.nix4
-rw-r--r--pkgs/tools/misc/cp437/default.nix4
-rw-r--r--pkgs/tools/misc/cpulimit/default.nix4
-rw-r--r--pkgs/tools/misc/cpuminer-multi/default.nix4
-rw-r--r--pkgs/tools/misc/cpuminer/default.nix4
-rw-r--r--pkgs/tools/misc/crex/default.nix4
-rw-r--r--pkgs/tools/misc/crudini/default.nix4
-rw-r--r--pkgs/tools/misc/csv2latex/default.nix4
-rw-r--r--pkgs/tools/misc/dashing/default.nix4
-rw-r--r--pkgs/tools/misc/datamash/default.nix4
-rw-r--r--pkgs/tools/misc/dateutils/default.nix4
-rw-r--r--pkgs/tools/misc/ddccontrol/default.nix4
-rw-r--r--pkgs/tools/misc/ddcutil/default.nix4
-rw-r--r--pkgs/tools/misc/debian-devscripts/default.nix4
-rw-r--r--pkgs/tools/misc/debianutils/default.nix4
-rw-r--r--pkgs/tools/misc/debootstrap/default.nix4
-rw-r--r--pkgs/tools/misc/detox/default.nix4
-rw-r--r--pkgs/tools/misc/diffoscope/default.nix2
-rw-r--r--pkgs/tools/misc/direnv/default.nix4
-rw-r--r--pkgs/tools/misc/diskonaut/default.nix4
-rw-r--r--pkgs/tools/misc/diskscan/default.nix4
-rw-r--r--pkgs/tools/misc/diskus/default.nix4
-rw-r--r--pkgs/tools/misc/docbook2mdoc/default.nix4
-rw-r--r--pkgs/tools/misc/docker-ls/default.nix4
-rw-r--r--pkgs/tools/misc/docui/default.nix4
-rw-r--r--pkgs/tools/misc/doitlive/default.nix4
-rw-r--r--pkgs/tools/misc/duc/default.nix4
-rw-r--r--pkgs/tools/misc/dumptorrent/default.nix4
-rw-r--r--pkgs/tools/misc/dupd/default.nix4
-rw-r--r--pkgs/tools/misc/dust/default.nix4
-rw-r--r--pkgs/tools/misc/dvtm/dvtm.nix4
-rw-r--r--pkgs/tools/misc/dylibbundler/default.nix4
-rw-r--r--pkgs/tools/misc/dynamic-colors/default.nix4
-rw-r--r--pkgs/tools/misc/ent/default.nix4
-rw-r--r--pkgs/tools/misc/entr/default.nix4
-rw-r--r--pkgs/tools/misc/envchain/default.nix4
-rw-r--r--pkgs/tools/misc/esptool-ck/default.nix4
-rw-r--r--pkgs/tools/misc/esptool/default.nix4
-rw-r--r--pkgs/tools/misc/etcher/default.nix4
-rw-r--r--pkgs/tools/misc/ethminer/default.nix3
-rw-r--r--pkgs/tools/misc/ethtool/default.nix4
-rw-r--r--pkgs/tools/misc/eva/default.nix4
-rw-r--r--pkgs/tools/misc/exa/default.nix4
-rw-r--r--pkgs/tools/misc/expect/default.nix4
-rw-r--r--pkgs/tools/misc/fbcat/default.nix4
-rw-r--r--pkgs/tools/misc/fdupes/default.nix4
-rw-r--r--pkgs/tools/misc/ffsend/default.nix4
-rw-r--r--pkgs/tools/misc/file/default.nix4
-rw-r--r--pkgs/tools/misc/filebench/default.nix4
-rw-r--r--pkgs/tools/misc/fltrdr/default.nix5
-rw-r--r--pkgs/tools/misc/fluent-bit/default.nix4
-rw-r--r--pkgs/tools/misc/foma/default.nix4
-rw-r--r--pkgs/tools/misc/fortune/default.nix4
-rw-r--r--pkgs/tools/misc/fpart/default.nix4
-rw-r--r--pkgs/tools/misc/fselect/default.nix4
-rw-r--r--pkgs/tools/misc/fsmark/default.nix4
-rw-r--r--pkgs/tools/misc/fsmon/default.nix4
-rw-r--r--pkgs/tools/misc/fsql/default.nix4
-rw-r--r--pkgs/tools/misc/fwup/default.nix2
-rw-r--r--pkgs/tools/misc/fx_cast/default.nix4
-rw-r--r--pkgs/tools/misc/fxlinuxprintutil/default.nix2
-rw-r--r--pkgs/tools/misc/fzy/default.nix4
-rw-r--r--pkgs/tools/misc/g933-utils/default.nix4
-rw-r--r--pkgs/tools/misc/gammy/default.nix4
-rw-r--r--pkgs/tools/misc/geekbench/default.nix4
-rw-r--r--pkgs/tools/misc/geteltorito/default.nix4
-rw-r--r--pkgs/tools/misc/gh-ost/default.nix4
-rw-r--r--pkgs/tools/misc/gif-for-cli/default.nix4
-rw-r--r--pkgs/tools/misc/git-fire/default.nix4
-rw-r--r--pkgs/tools/misc/git-town/default.nix4
-rw-r--r--pkgs/tools/misc/gnuvd/default.nix4
-rw-r--r--pkgs/tools/misc/go.rice/default.nix4
-rw-r--r--pkgs/tools/misc/gparted/default.nix4
-rw-r--r--pkgs/tools/misc/graylog/default.nix4
-rw-r--r--pkgs/tools/misc/grc/default.nix4
-rw-r--r--pkgs/tools/misc/grex/default.nix4
-rw-r--r--pkgs/tools/misc/gringo/default.nix4
-rw-r--r--pkgs/tools/misc/grub/2.0x.nix4
-rw-r--r--pkgs/tools/misc/grub/default.nix4
-rw-r--r--pkgs/tools/misc/grub/pvgrub_image/default.nix4
-rw-r--r--pkgs/tools/misc/grub/trusted.nix4
-rw-r--r--pkgs/tools/misc/grub4dos/default.nix4
-rw-r--r--pkgs/tools/misc/gti/default.nix4
-rw-r--r--pkgs/tools/misc/h/default.nix4
-rw-r--r--pkgs/tools/misc/hackertyper/default.nix4
-rw-r--r--pkgs/tools/misc/hakuneko/default.nix2
-rw-r--r--pkgs/tools/misc/hashit/default.nix4
-rw-r--r--pkgs/tools/misc/hdaps-gl/default.nix4
-rw-r--r--pkgs/tools/misc/hddtemp/default.nix4
-rw-r--r--pkgs/tools/misc/hdf4/default.nix4
-rw-r--r--pkgs/tools/misc/hdl-dump/default.nix4
-rw-r--r--pkgs/tools/misc/heatseeker/default.nix4
-rw-r--r--pkgs/tools/misc/hebcal/default.nix4
-rw-r--r--pkgs/tools/misc/heimdall/default.nix4
-rw-r--r--pkgs/tools/misc/hexyl/default.nix4
-rw-r--r--pkgs/tools/misc/hhpc/default.nix4
-rw-r--r--pkgs/tools/misc/hid-listen/default.nix4
-rw-r--r--pkgs/tools/misc/hpcg/default.nix4
-rw-r--r--pkgs/tools/misc/hpl/default.nix4
-rw-r--r--pkgs/tools/misc/hyperfine/default.nix4
-rw-r--r--pkgs/tools/misc/hyperledger-fabric/default.nix4
-rw-r--r--pkgs/tools/misc/i3minator/default.nix4
-rw-r--r--pkgs/tools/misc/ical2org/default.nix4
-rw-r--r--pkgs/tools/misc/ideviceinstaller/default.nix4
-rw-r--r--pkgs/tools/misc/idevicerestore/default.nix4
-rw-r--r--pkgs/tools/misc/ili2c/default.nix4
-rw-r--r--pkgs/tools/misc/ink/default.nix4
-rw-r--r--pkgs/tools/misc/intermodal/default.nix4
-rw-r--r--pkgs/tools/misc/ipad_charge/default.nix4
-rw-r--r--pkgs/tools/misc/ipbt/default.nix4
-rw-r--r--pkgs/tools/misc/ix/default.nix4
-rw-r--r--pkgs/tools/misc/jdiskreport/default.nix4
-rw-r--r--pkgs/tools/misc/jdupes/default.nix4
-rw-r--r--pkgs/tools/misc/jugglinglab/default.nix4
-rw-r--r--pkgs/tools/misc/kanshi/default.nix4
-rw-r--r--pkgs/tools/misc/kargo/default.nix4
-rw-r--r--pkgs/tools/misc/kermit/default.nix4
-rw-r--r--pkgs/tools/misc/kisslicer/default.nix4
-rw-r--r--pkgs/tools/misc/kodi-cli/default.nix4
-rw-r--r--pkgs/tools/misc/kt/default.nix4
-rw-r--r--pkgs/tools/misc/latex2html/default.nix4
-rw-r--r--pkgs/tools/misc/lazydocker/default.nix4
-rw-r--r--pkgs/tools/misc/lcdf-typetools/default.nix4
-rw-r--r--pkgs/tools/misc/ldapvi/default.nix4
-rw-r--r--pkgs/tools/misc/ldmtool/default.nix4
-rw-r--r--pkgs/tools/misc/less/default.nix4
-rw-r--r--pkgs/tools/misc/lesspipe/default.nix4
-rw-r--r--pkgs/tools/misc/libbitcoin/libbitcoin-client.nix4
-rw-r--r--pkgs/tools/misc/libbitcoin/libbitcoin-explorer.nix4
-rw-r--r--pkgs/tools/misc/libbitcoin/libbitcoin-network.nix4
-rw-r--r--pkgs/tools/misc/libbitcoin/libbitcoin-protocol.nix4
-rw-r--r--pkgs/tools/misc/libbitcoin/libbitcoin.nix4
-rw-r--r--pkgs/tools/misc/libcpuid/default.nix4
-rw-r--r--pkgs/tools/misc/lice/default.nix4
-rw-r--r--pkgs/tools/misc/linuxquota/default.nix4
-rw-r--r--pkgs/tools/misc/lnav/default.nix4
-rw-r--r--pkgs/tools/misc/lnch/default.nix4
-rw-r--r--pkgs/tools/misc/logstash/6.x.nix4
-rw-r--r--pkgs/tools/misc/logstash/7.x.nix4
-rw-r--r--pkgs/tools/misc/logtop/default.nix4
-rw-r--r--pkgs/tools/misc/lokalise2-cli/default.nix4
-rw-r--r--pkgs/tools/misc/loop/default.nix4
-rw-r--r--pkgs/tools/misc/lorri/default.nix4
-rw-r--r--pkgs/tools/misc/lottieconverter/default.nix4
-rw-r--r--pkgs/tools/misc/lrzsz/default.nix4
-rw-r--r--pkgs/tools/misc/lsd/default.nix4
-rw-r--r--pkgs/tools/misc/ltunify/default.nix4
-rw-r--r--pkgs/tools/misc/makebootfat/default.nix4
-rw-r--r--pkgs/tools/misc/man-db/default.nix4
-rw-r--r--pkgs/tools/misc/mandoc/default.nix4
-rw-r--r--pkgs/tools/misc/marlin-calc/default.nix4
-rw-r--r--pkgs/tools/misc/mc/default.nix4
-rw-r--r--pkgs/tools/misc/mcfly/default.nix4
-rw-r--r--pkgs/tools/misc/me_cleaner/default.nix4
-rw-r--r--pkgs/tools/misc/mht2htm/default.nix4
-rw-r--r--pkgs/tools/misc/microplane/default.nix4
-rw-r--r--pkgs/tools/misc/mimeo/default.nix4
-rw-r--r--pkgs/tools/misc/minicom/default.nix4
-rw-r--r--pkgs/tools/misc/miniserve/default.nix4
-rw-r--r--pkgs/tools/misc/ministat/default.nix4
-rw-r--r--pkgs/tools/misc/mlocate/default.nix4
-rw-r--r--pkgs/tools/misc/mmake/default.nix4
-rw-r--r--pkgs/tools/misc/mongodb-compass/default.nix4
-rw-r--r--pkgs/tools/misc/most/default.nix4
-rw-r--r--pkgs/tools/misc/mpdscribble/default.nix4
-rw-r--r--pkgs/tools/misc/ms-sys/default.nix4
-rw-r--r--pkgs/tools/misc/mstflint/default.nix4
-rw-r--r--pkgs/tools/misc/mtm/default.nix4
-rw-r--r--pkgs/tools/misc/mysqltuner/default.nix4
-rw-r--r--pkgs/tools/misc/nagstamon/default.nix4
-rw-r--r--pkgs/tools/misc/nbench/default.nix4
-rw-r--r--pkgs/tools/misc/ncdu/default.nix4
-rw-r--r--pkgs/tools/misc/neofetch/default.nix4
-rw-r--r--pkgs/tools/misc/nginx-config-formatter/default.nix4
-rw-r--r--pkgs/tools/misc/nix-direnv/default.nix2
-rw-r--r--pkgs/tools/misc/nms/default.nix4
-rw-r--r--pkgs/tools/misc/nncp/default.nix4
-rw-r--r--pkgs/tools/misc/noteshrink/default.nix4
-rw-r--r--pkgs/tools/misc/notify-desktop/default.nix4
-rw-r--r--pkgs/tools/misc/ntfy/default.nix4
-rw-r--r--pkgs/tools/misc/nvimpager/default.nix4
-rw-r--r--pkgs/tools/misc/nyancat/default.nix4
-rw-r--r--pkgs/tools/misc/odroid-xu3-bootloader/default.nix2
-rw-r--r--pkgs/tools/misc/odyssey/default.nix4
-rw-r--r--pkgs/tools/misc/onefetch/default.nix4
-rw-r--r--pkgs/tools/misc/opencorsairlink/default.nix4
-rw-r--r--pkgs/tools/misc/opentsdb/default.nix4
-rw-r--r--pkgs/tools/misc/oppai-ng/default.nix4
-rw-r--r--pkgs/tools/misc/os-prober/default.nix4
-rw-r--r--pkgs/tools/misc/osinfo-db-tools/default.nix4
-rw-r--r--pkgs/tools/misc/osm2pgsql/default.nix4
-rw-r--r--pkgs/tools/misc/ostree/default.nix4
-rw-r--r--pkgs/tools/misc/otfcc/default.nix4
-rw-r--r--pkgs/tools/misc/ovh-ttyrec/default.nix4
-rw-r--r--pkgs/tools/misc/pandoc-lua-filters/default.nix4
-rw-r--r--pkgs/tools/misc/paps/default.nix4
-rw-r--r--pkgs/tools/misc/parallel/default.nix4
-rw-r--r--pkgs/tools/misc/parcellite/default.nix4
-rw-r--r--pkgs/tools/misc/pastebinit/default.nix4
-rw-r--r--pkgs/tools/misc/pazi/default.nix4
-rw-r--r--pkgs/tools/misc/pb_cli/default.nix4
-rw-r--r--pkgs/tools/misc/pdd/default.nix4
-rw-r--r--pkgs/tools/misc/pdf-parser/default.nix4
-rw-r--r--pkgs/tools/misc/pfsshell/default.nix4
-rw-r--r--pkgs/tools/misc/pg_top/default.nix4
-rw-r--r--pkgs/tools/misc/pgcenter/default.nix4
-rw-r--r--pkgs/tools/misc/pgmetrics/default.nix4
-rw-r--r--pkgs/tools/misc/phoronix-test-suite/default.nix4
-rw-r--r--pkgs/tools/misc/phraseapp-client/default.nix4
-rw-r--r--pkgs/tools/misc/pick/default.nix4
-rw-r--r--pkgs/tools/misc/picocom/default.nix4
-rw-r--r--pkgs/tools/misc/pistol/default.nix4
-rw-r--r--pkgs/tools/misc/pkgdiff/default.nix2
-rw-r--r--pkgs/tools/misc/plantuml-server/default.nix4
-rw-r--r--pkgs/tools/misc/plantuml/default.nix4
-rw-r--r--pkgs/tools/misc/plotinus/default.nix4
-rw-r--r--pkgs/tools/misc/pod2mdoc/default.nix4
-rw-r--r--pkgs/tools/misc/powerline-go/default.nix4
-rw-r--r--pkgs/tools/misc/profile-sync-daemon/default.nix4
-rw-r--r--pkgs/tools/misc/progress/default.nix4
-rw-r--r--pkgs/tools/misc/pspg/default.nix4
-rw-r--r--pkgs/tools/misc/pubs/default.nix4
-rw-r--r--pkgs/tools/misc/rargs/default.nix4
-rw-r--r--pkgs/tools/misc/rcm/default.nix4
-rw-r--r--pkgs/tools/misc/recoverjpeg/default.nix4
-rw-r--r--pkgs/tools/misc/rename/default.nix4
-rw-r--r--pkgs/tools/misc/reredirect/default.nix4
-rw-r--r--pkgs/tools/misc/riemann-c-client/default.nix4
-rw-r--r--pkgs/tools/misc/rkflashtool/default.nix4
-rw-r--r--pkgs/tools/misc/rockbox-utility/default.nix4
-rw-r--r--pkgs/tools/misc/roundup/default.nix4
-rw-r--r--pkgs/tools/misc/routino/default.nix4
-rw-r--r--pkgs/tools/misc/rpcsvc-proto/default.nix2
-rw-r--r--pkgs/tools/misc/rpm-ostree/default.nix4
-rw-r--r--pkgs/tools/misc/rrdtool/default.nix4
-rw-r--r--pkgs/tools/misc/rw/default.nix4
-rw-r--r--pkgs/tools/misc/sam-ba/default.nix4
-rw-r--r--pkgs/tools/misc/scanmem/default.nix4
-rw-r--r--pkgs/tools/misc/screen/default.nix4
-rw-r--r--pkgs/tools/misc/sd-mux-ctrl/default.nix4
-rw-r--r--pkgs/tools/misc/sdl-jstest/default.nix4
-rw-r--r--pkgs/tools/misc/shadowenv/default.nix4
-rw-r--r--pkgs/tools/misc/shelldap/default.nix4
-rw-r--r--pkgs/tools/misc/shunit2/default.nix4
-rw-r--r--pkgs/tools/misc/skim/default.nix4
-rw-r--r--pkgs/tools/misc/sl/default.nix4
-rw-r--r--pkgs/tools/misc/slop/default.nix4
-rw-r--r--pkgs/tools/misc/slurp/default.nix4
-rw-r--r--pkgs/tools/misc/smc/default.nix4
-rw-r--r--pkgs/tools/misc/smenu/default.nix4
-rw-r--r--pkgs/tools/misc/snapper/default.nix4
-rw-r--r--pkgs/tools/misc/snore/default.nix4
-rw-r--r--pkgs/tools/misc/somafm-cli/default.nix4
-rw-r--r--pkgs/tools/misc/starship/default.nix4
-rw-r--r--pkgs/tools/misc/staruml/default.nix2
-rw-r--r--pkgs/tools/misc/statserial/default.nix4
-rw-r--r--pkgs/tools/misc/subberthehut/default.nix4
-rw-r--r--pkgs/tools/misc/svtplay-dl/default.nix4
-rw-r--r--pkgs/tools/misc/swaglyrics/default.nix2
-rw-r--r--pkgs/tools/misc/sweep-visualizer/default.nix2
-rw-r--r--pkgs/tools/misc/systrayhelper/default.nix4
-rw-r--r--pkgs/tools/misc/t1utils/default.nix4
-rw-r--r--pkgs/tools/misc/tab-rs/default.nix4
-rw-r--r--pkgs/tools/misc/tealdeer/default.nix4
-rw-r--r--pkgs/tools/misc/teleconsole/default.nix4
-rw-r--r--pkgs/tools/misc/tensorman/default.nix4
-rw-r--r--pkgs/tools/misc/texi2mdoc/default.nix4
-rw-r--r--pkgs/tools/misc/thefuck/default.nix4
-rw-r--r--pkgs/tools/misc/thin-provisioning-tools/default.nix4
-rw-r--r--pkgs/tools/misc/timidity/default.nix4
-rw-r--r--pkgs/tools/misc/tio/default.nix4
-rw-r--r--pkgs/tools/misc/tldr/default.nix4
-rw-r--r--pkgs/tools/misc/tmate/default.nix4
-rw-r--r--pkgs/tools/misc/tmpwatch/default.nix4
-rw-r--r--pkgs/tools/misc/tmux-xpanes/default.nix4
-rw-r--r--pkgs/tools/misc/tmuxp/default.nix4
-rw-r--r--pkgs/tools/misc/togglesg-download/default.nix2
-rw-r--r--pkgs/tools/misc/toilet/default.nix4
-rw-r--r--pkgs/tools/misc/toybox/default.nix2
-rw-r--r--pkgs/tools/misc/trash-cli/default.nix4
-rw-r--r--pkgs/tools/misc/ttfautohint/default.nix2
-rw-r--r--pkgs/tools/misc/ttwatch/default.nix4
-rw-r--r--pkgs/tools/misc/tty-clock/default.nix4
-rw-r--r--pkgs/tools/misc/ttygif/default.nix4
-rw-r--r--pkgs/tools/misc/ttylog/default.nix4
-rw-r--r--pkgs/tools/misc/ttyplot/default.nix4
-rw-r--r--pkgs/tools/misc/txr/default.nix4
-rw-r--r--pkgs/tools/misc/txtw/default.nix4
-rw-r--r--pkgs/tools/misc/tydra/default.nix4
-rw-r--r--pkgs/tools/misc/ugtrain/default.nix4
-rw-r--r--pkgs/tools/misc/uhubctl/default.nix4
-rw-r--r--pkgs/tools/misc/umlet/default.nix4
-rw-r--r--pkgs/tools/misc/unclutter-xfixes/default.nix4
-rw-r--r--pkgs/tools/misc/unclutter/default.nix4
-rw-r--r--pkgs/tools/misc/unicode/default.nix4
-rw-r--r--pkgs/tools/misc/units/default.nix2
-rw-r--r--pkgs/tools/misc/usbmuxd/default.nix4
-rw-r--r--pkgs/tools/misc/vcs_query/default.nix4
-rw-r--r--pkgs/tools/misc/vector/default.nix2
-rw-r--r--pkgs/tools/misc/vimer/default.nix4
-rw-r--r--pkgs/tools/misc/vimpager/build.nix4
-rw-r--r--pkgs/tools/misc/vimv/default.nix4
-rw-r--r--pkgs/tools/misc/vimwiki-markdown/default.nix4
-rw-r--r--pkgs/tools/misc/vivid/default.nix4
-rw-r--r--pkgs/tools/misc/vix/default.nix4
-rw-r--r--pkgs/tools/misc/void/default.nix4
-rw-r--r--pkgs/tools/misc/vorbisgain/default.nix4
-rw-r--r--pkgs/tools/misc/vttest/default.nix4
-rw-r--r--pkgs/tools/misc/wakatime/default.nix4
-rw-r--r--pkgs/tools/misc/watchexec/default.nix4
-rw-r--r--pkgs/tools/misc/websocat/default.nix4
-rw-r--r--pkgs/tools/misc/wev/default.nix4
-rw-r--r--pkgs/tools/misc/wimboot/default.nix4
-rw-r--r--pkgs/tools/misc/wl-clipboard/default.nix4
-rw-r--r--pkgs/tools/misc/wlr-randr/default.nix4
-rw-r--r--pkgs/tools/misc/wob/default.nix4
-rw-r--r--pkgs/tools/misc/woeusb/default.nix4
-rw-r--r--pkgs/tools/misc/woof/default.nix4
-rw-r--r--pkgs/tools/misc/wsl-open/default.nix4
-rw-r--r--pkgs/tools/misc/wyrd/default.nix4
-rw-r--r--pkgs/tools/misc/x11idle/default.nix4
-rw-r--r--pkgs/tools/misc/xdaliclock/default.nix4
-rw-r--r--pkgs/tools/misc/xdo/default.nix4
-rw-r--r--pkgs/tools/misc/xdxf2slob/default.nix4
-rw-r--r--pkgs/tools/misc/xfstests/default.nix2
-rw-r--r--pkgs/tools/misc/xiccd/default.nix4
-rw-r--r--pkgs/tools/misc/xilinx-bootgen/default.nix4
-rw-r--r--pkgs/tools/misc/xmonad-log/default.nix4
-rw-r--r--pkgs/tools/misc/xprite-editor/default.nix4
-rw-r--r--pkgs/tools/misc/xvfb-run/default.nix4
-rw-r--r--pkgs/tools/misc/yad/default.nix4
-rw-r--r--pkgs/tools/misc/yank/default.nix4
-rw-r--r--pkgs/tools/misc/yle-dl/default.nix4
-rw-r--r--pkgs/tools/misc/you-get/default.nix4
-rw-r--r--pkgs/tools/misc/ytree/default.nix4
-rw-r--r--pkgs/tools/misc/yubico-piv-tool/default.nix4
-rw-r--r--pkgs/tools/misc/yubikey-neo-manager/default.nix4
-rw-r--r--pkgs/tools/misc/yubikey-personalization-gui/default.nix4
-rw-r--r--pkgs/tools/misc/yubikey-personalization/default.nix4
-rw-r--r--pkgs/tools/misc/z-lua/default.nix4
-rw-r--r--pkgs/tools/misc/zabbixctl/default.nix4
-rw-r--r--pkgs/tools/misc/zalgo/default.nix4
-rw-r--r--pkgs/tools/misc/zsh-autoenv/default.nix4
-rw-r--r--pkgs/tools/misc/zsh-navigation-tools/default.nix4
-rw-r--r--pkgs/tools/networking/aircrack-ng/default.nix4
-rw-r--r--pkgs/tools/networking/airfield/default.nix4
-rw-r--r--pkgs/tools/networking/altermime/default.nix4
-rw-r--r--pkgs/tools/networking/argus-clients/default.nix4
-rw-r--r--pkgs/tools/networking/argus/default.nix4
-rw-r--r--pkgs/tools/networking/aria2/default.nix4
-rw-r--r--pkgs/tools/networking/arping/default.nix4
-rw-r--r--pkgs/tools/networking/arpoison/default.nix4
-rw-r--r--pkgs/tools/networking/assh/default.nix4
-rw-r--r--pkgs/tools/networking/atinout/default.nix4
-rw-r--r--pkgs/tools/networking/autossh/default.nix4
-rw-r--r--pkgs/tools/networking/axel/default.nix4
-rw-r--r--pkgs/tools/networking/bacnet-stack/default.nix4
-rw-r--r--pkgs/tools/networking/bandwhich/default.nix4
-rw-r--r--pkgs/tools/networking/bgpq3/default.nix4
-rw-r--r--pkgs/tools/networking/bgpq4/default.nix4
-rw-r--r--pkgs/tools/networking/biosdevname/default.nix4
-rw-r--r--pkgs/tools/networking/boringtun/default.nix4
-rw-r--r--pkgs/tools/networking/brook/default.nix4
-rw-r--r--pkgs/tools/networking/bsd-finger/default.nix4
-rw-r--r--pkgs/tools/networking/bukubrow/default.nix4
-rw-r--r--pkgs/tools/networking/bully/default.nix4
-rw-r--r--pkgs/tools/networking/bwm-ng/default.nix4
-rw-r--r--pkgs/tools/networking/cadaver/default.nix4
-rw-r--r--pkgs/tools/networking/carddav-util/default.nix4
-rw-r--r--pkgs/tools/networking/ccnet/default.nix4
-rw-r--r--pkgs/tools/networking/chrony/default.nix4
-rw-r--r--pkgs/tools/networking/circus/default.nix4
-rw-r--r--pkgs/tools/networking/cjdns/default.nix4
-rw-r--r--pkgs/tools/networking/cksfv/default.nix4
-rw-r--r--pkgs/tools/networking/clash/default.nix4
-rw-r--r--pkgs/tools/networking/cntlm/default.nix4
-rw-r--r--pkgs/tools/networking/connman/connman-gtk/default.nix4
-rw-r--r--pkgs/tools/networking/connman/connman-ncurses/default.nix4
-rw-r--r--pkgs/tools/networking/connman/connman-notify/default.nix4
-rw-r--r--pkgs/tools/networking/connman/connman.nix4
-rw-r--r--pkgs/tools/networking/corerad/default.nix4
-rw-r--r--pkgs/tools/networking/corkscrew/default.nix4
-rw-r--r--pkgs/tools/networking/croc/default.nix4
-rw-r--r--pkgs/tools/networking/curl-unix-socket/default.nix4
-rw-r--r--pkgs/tools/networking/curl/default.nix2
-rw-r--r--pkgs/tools/networking/cutter/default.nix4
-rw-r--r--pkgs/tools/networking/darkstat/default.nix4
-rw-r--r--pkgs/tools/networking/davix/default.nix4
-rw-r--r--pkgs/tools/networking/dd-agent/datadog-agent.nix2
-rw-r--r--pkgs/tools/networking/dd-agent/datadog-process-agent.nix4
-rw-r--r--pkgs/tools/networking/ddclient/default.nix4
-rw-r--r--pkgs/tools/networking/dhcp/default.nix2
-rw-r--r--pkgs/tools/networking/dhcpcd/default.nix4
-rw-r--r--pkgs/tools/networking/dhcpdump/default.nix4
-rw-r--r--pkgs/tools/networking/dhcping/default.nix4
-rw-r--r--pkgs/tools/networking/dibbler/default.nix4
-rw-r--r--pkgs/tools/networking/djbdns/default.nix4
-rw-r--r--pkgs/tools/networking/dnscrypt-proxy2/default.nix4
-rw-r--r--pkgs/tools/networking/dnscrypt-wrapper/default.nix4
-rw-r--r--pkgs/tools/networking/dnsperf/default.nix4
-rw-r--r--pkgs/tools/networking/dnsproxy/default.nix4
-rw-r--r--pkgs/tools/networking/dnstracer/default.nix4
-rw-r--r--pkgs/tools/networking/dogdns/default.nix4
-rw-r--r--pkgs/tools/networking/drill/default.nix4
-rw-r--r--pkgs/tools/networking/dropbear/default.nix2
-rw-r--r--pkgs/tools/networking/easyrsa/2.x.nix4
-rw-r--r--pkgs/tools/networking/easyrsa/default.nix4
-rw-r--r--pkgs/tools/networking/eggdrop/default.nix4
-rw-r--r--pkgs/tools/networking/eternal-terminal/default.nix4
-rw-r--r--pkgs/tools/networking/fakeroute/default.nix4
-rw-r--r--pkgs/tools/networking/fastd/default.nix4
-rw-r--r--pkgs/tools/networking/fdm/default.nix4
-rw-r--r--pkgs/tools/networking/filegive/default.nix4
-rw-r--r--pkgs/tools/networking/fping/default.nix4
-rw-r--r--pkgs/tools/networking/freebind/default.nix4
-rw-r--r--pkgs/tools/networking/gandi-cli/default.nix4
-rw-r--r--pkgs/tools/networking/gmrender-resurrect/default.nix4
-rw-r--r--pkgs/tools/networking/gnirehtet/default.nix4
-rw-r--r--pkgs/tools/networking/go-shadowsocks2/default.nix4
-rw-r--r--pkgs/tools/networking/goklp/default.nix4
-rw-r--r--pkgs/tools/networking/gupnp-tools/default.nix4
-rw-r--r--pkgs/tools/networking/gvpe/default.nix4
-rw-r--r--pkgs/tools/networking/hans/default.nix4
-rw-r--r--pkgs/tools/networking/horst/default.nix4
-rw-r--r--pkgs/tools/networking/hping/default.nix4
-rw-r--r--pkgs/tools/networking/htpdate/default.nix4
-rw-r--r--pkgs/tools/networking/http-prompt/default.nix4
-rw-r--r--pkgs/tools/networking/httperf/default.nix4
-rw-r--r--pkgs/tools/networking/httping/default.nix4
-rw-r--r--pkgs/tools/networking/httplab/default.nix4
-rw-r--r--pkgs/tools/networking/httplz/default.nix2
-rw-r--r--pkgs/tools/networking/httptunnel/default.nix4
-rw-r--r--pkgs/tools/networking/i2p/default.nix4
-rw-r--r--pkgs/tools/networking/i2pd/default.nix4
-rw-r--r--pkgs/tools/networking/ifstat-legacy/default.nix4
-rw-r--r--pkgs/tools/networking/iftop/default.nix4
-rw-r--r--pkgs/tools/networking/igmpproxy/default.nix4
-rw-r--r--pkgs/tools/networking/imapsync/default.nix4
-rw-r--r--pkgs/tools/networking/inadyn/default.nix4
-rw-r--r--pkgs/tools/networking/iouyap/default.nix4
-rw-r--r--pkgs/tools/networking/ip2location/default.nix4
-rw-r--r--pkgs/tools/networking/iperf/2.nix4
-rw-r--r--pkgs/tools/networking/iperf/3.nix4
-rw-r--r--pkgs/tools/networking/ipgrep/default.nix4
-rw-r--r--pkgs/tools/networking/ipv6calc/default.nix4
-rw-r--r--pkgs/tools/networking/isync/default.nix4
-rw-r--r--pkgs/tools/networking/kail/default.nix4
-rw-r--r--pkgs/tools/networking/kea/default.nix4
-rw-r--r--pkgs/tools/networking/keepalived/default.nix4
-rw-r--r--pkgs/tools/networking/lftp/default.nix4
-rw-r--r--pkgs/tools/networking/libnids/default.nix4
-rw-r--r--pkgs/tools/networking/libreswan/default.nix4
-rw-r--r--pkgs/tools/networking/logmein-hamachi/default.nix4
-rw-r--r--pkgs/tools/networking/maildrop/default.nix4
-rw-r--r--pkgs/tools/networking/mailutils/default.nix4
-rw-r--r--pkgs/tools/networking/maxscale/default.nix4
-rw-r--r--pkgs/tools/networking/megatools/default.nix4
-rw-r--r--pkgs/tools/networking/minidlna/default.nix4
-rw-r--r--pkgs/tools/networking/minio-client/default.nix4
-rw-r--r--pkgs/tools/networking/minissdpd/default.nix4
-rw-r--r--pkgs/tools/networking/miniupnpc/default.nix4
-rw-r--r--pkgs/tools/networking/miniupnpd/default.nix2
-rw-r--r--pkgs/tools/networking/miredo/default.nix4
-rw-r--r--pkgs/tools/networking/mmsd/default.nix4
-rw-r--r--pkgs/tools/networking/modem-manager/default.nix4
-rw-r--r--pkgs/tools/networking/mozwire/default.nix4
-rw-r--r--pkgs/tools/networking/mpack/default.nix4
-rw-r--r--pkgs/tools/networking/mtr/default.nix2
-rw-r--r--pkgs/tools/networking/mu/default.nix4
-rw-r--r--pkgs/tools/networking/nat-traverse/default.nix4
-rw-r--r--pkgs/tools/networking/ncftp/default.nix4
-rw-r--r--pkgs/tools/networking/ndisc6/default.nix4
-rw-r--r--pkgs/tools/networking/netboot/default.nix4
-rw-r--r--pkgs/tools/networking/netcat/default.nix4
-rw-r--r--pkgs/tools/networking/nethogs/default.nix4
-rw-r--r--pkgs/tools/networking/netifd/default.nix4
-rw-r--r--pkgs/tools/networking/netmask/default.nix4
-rw-r--r--pkgs/tools/networking/netselect/default.nix4
-rw-r--r--pkgs/tools/networking/netsniff-ng/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/0.9.8/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/applet/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/dmenu/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/fortisslvpn/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/iodine/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/l2tp/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/libnma/default.nix2
-rw-r--r--pkgs/tools/networking/network-manager/openconnect/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/openvpn/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/sstp/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/strongswan/default.nix4
-rw-r--r--pkgs/tools/networking/network-manager/vpnc/default.nix4
-rw-r--r--pkgs/tools/networking/nfdump/default.nix4
-rw-r--r--pkgs/tools/networking/nfstrace/default.nix4
-rw-r--r--pkgs/tools/networking/ngrep/default.nix2
-rw-r--r--pkgs/tools/networking/noip/default.nix4
-rw-r--r--pkgs/tools/networking/nss-pam-ldapd/default.nix4
-rw-r--r--pkgs/tools/networking/ntopng/default.nix4
-rw-r--r--pkgs/tools/networking/ntp/default.nix2
-rw-r--r--pkgs/tools/networking/nuttcp/default.nix4
-rw-r--r--pkgs/tools/networking/nylon/default.nix4
-rw-r--r--pkgs/tools/networking/nzbget/default.nix4
-rw-r--r--pkgs/tools/networking/ocproxy/default.nix4
-rw-r--r--pkgs/tools/networking/ocserv/default.nix4
-rw-r--r--pkgs/tools/networking/ofono/default.nix4
-rw-r--r--pkgs/tools/networking/openapi-generator-cli/default.nix4
-rw-r--r--pkgs/tools/networking/openapi-generator-cli/unstable.nix4
-rw-r--r--pkgs/tools/networking/openconnect/default.nix4
-rw-r--r--pkgs/tools/networking/openconnect_pa/default.nix4
-rw-r--r--pkgs/tools/networking/openfortivpn/default.nix2
-rw-r--r--pkgs/tools/networking/openntpd/default.nix4
-rw-r--r--pkgs/tools/networking/opensm/default.nix4
-rw-r--r--pkgs/tools/networking/openvpn/default.nix4
-rw-r--r--pkgs/tools/networking/openvpn/update-resolv-conf.nix2
-rw-r--r--pkgs/tools/networking/openvpn/update-systemd-resolved.nix2
-rw-r--r--pkgs/tools/networking/p2p/gtk-gnutella/default.nix4
-rw-r--r--pkgs/tools/networking/p2p/libtorrent/default.nix4
-rw-r--r--pkgs/tools/networking/p2p/rtorrent/default.nix4
-rw-r--r--pkgs/tools/networking/pacparser/default.nix4
-rw-r--r--pkgs/tools/networking/par2cmdline/default.nix4
-rw-r--r--pkgs/tools/networking/pcapc/default.nix4
-rw-r--r--pkgs/tools/networking/pcapfix/default.nix4
-rw-r--r--pkgs/tools/networking/pdnsd/default.nix4
-rw-r--r--pkgs/tools/networking/persepolis/default.nix2
-rw-r--r--pkgs/tools/networking/philter/default.nix4
-rw-r--r--pkgs/tools/networking/phodav/default.nix4
-rw-r--r--pkgs/tools/networking/photon/default.nix4
-rw-r--r--pkgs/tools/networking/pingtcp/default.nix4
-rw-r--r--pkgs/tools/networking/pirate-get/default.nix4
-rw-r--r--pkgs/tools/networking/pmacct/default.nix4
-rw-r--r--pkgs/tools/networking/polygraph/default.nix4
-rw-r--r--pkgs/tools/networking/polysh/default.nix4
-rw-r--r--pkgs/tools/networking/ppp/default.nix4
-rw-r--r--pkgs/tools/networking/pptp/default.nix4
-rw-r--r--pkgs/tools/networking/pptpd/default.nix4
-rw-r--r--pkgs/tools/networking/privoxy/default.nix4
-rw-r--r--pkgs/tools/networking/proxify/default.nix4
-rw-r--r--pkgs/tools/networking/pssh/default.nix4
-rw-r--r--pkgs/tools/networking/pwnat/default.nix4
-rw-r--r--pkgs/tools/networking/pykms/default.nix4
-rw-r--r--pkgs/tools/networking/quickserve/default.nix4
-rw-r--r--pkgs/tools/networking/quicktun/default.nix4
-rw-r--r--pkgs/tools/networking/radsecproxy/default.nix4
-rw-r--r--pkgs/tools/networking/radvd/default.nix4
-rw-r--r--pkgs/tools/networking/ratools/default.nix4
-rw-r--r--pkgs/tools/networking/rcon/default.nix4
-rw-r--r--pkgs/tools/networking/rdrview/default.nix4
-rw-r--r--pkgs/tools/networking/reaver-wps-t6x/default.nix4
-rw-r--r--pkgs/tools/networking/reaver-wps/default.nix4
-rw-r--r--pkgs/tools/networking/ripmime/default.nix4
-rw-r--r--pkgs/tools/networking/rp-pppoe/default.nix4
-rw-r--r--pkgs/tools/networking/s3cmd/default.nix4
-rw-r--r--pkgs/tools/networking/s4cmd/default.nix4
-rw-r--r--pkgs/tools/networking/saldl/default.nix4
-rw-r--r--pkgs/tools/networking/shadowfox/default.nix4
-rw-r--r--pkgs/tools/networking/shadowsocks-libev/default.nix4
-rw-r--r--pkgs/tools/networking/shadowsocks-rust/default.nix4
-rw-r--r--pkgs/tools/networking/shncpd/default.nix4
-rw-r--r--pkgs/tools/networking/siege/default.nix4
-rw-r--r--pkgs/tools/networking/simpleproxy/default.nix4
-rw-r--r--pkgs/tools/networking/sipcalc/default.nix4
-rw-r--r--pkgs/tools/networking/sipsak/default.nix4
-rw-r--r--pkgs/tools/networking/slirp4netns/default.nix4
-rw-r--r--pkgs/tools/networking/smartdns/default.nix4
-rw-r--r--pkgs/tools/networking/socat/2.x.nix4
-rw-r--r--pkgs/tools/networking/spoofer/default.nix4
-rw-r--r--pkgs/tools/networking/ssh-askpass-fullscreen/default.nix4
-rw-r--r--pkgs/tools/networking/sshoogr/default.nix4
-rw-r--r--pkgs/tools/networking/sshpass/default.nix4
-rw-r--r--pkgs/tools/networking/sshping/default.nix4
-rw-r--r--pkgs/tools/networking/sslsplit/default.nix4
-rw-r--r--pkgs/tools/networking/ssmtp/default.nix4
-rw-r--r--pkgs/tools/networking/stubby/default.nix4
-rw-r--r--pkgs/tools/networking/stun/default.nix4
-rw-r--r--pkgs/tools/networking/subfinder/default.nix4
-rw-r--r--pkgs/tools/networking/swagger-codegen/default.nix4
-rw-r--r--pkgs/tools/networking/swaks/default.nix4
-rw-r--r--pkgs/tools/networking/tayga/default.nix4
-rw-r--r--pkgs/tools/networking/tcpflow/default.nix2
-rw-r--r--pkgs/tools/networking/tcpreplay/default.nix4
-rw-r--r--pkgs/tools/networking/tdns-cli/default.nix4
-rw-r--r--pkgs/tools/networking/tendermint/default.nix4
-rw-r--r--pkgs/tools/networking/termshark/default.nix4
-rw-r--r--pkgs/tools/networking/tftp-hpa/default.nix4
-rw-r--r--pkgs/tools/networking/tgt/default.nix2
-rw-r--r--pkgs/tools/networking/tinc/pre.nix4
-rw-r--r--pkgs/tools/networking/tinyfecvpn/default.nix4
-rw-r--r--pkgs/tools/networking/tinyproxy/default.nix4
-rw-r--r--pkgs/tools/networking/tlspool/default.nix4
-rw-r--r--pkgs/tools/networking/tox-node/default.nix4
-rw-r--r--pkgs/tools/networking/toxvpn/default.nix4
-rw-r--r--pkgs/tools/networking/tracebox/default.nix4
-rw-r--r--pkgs/tools/networking/traceroute/default.nix4
-rw-r--r--pkgs/tools/networking/tridactyl-native/default.nix4
-rw-r--r--pkgs/tools/networking/tunnelto/default.nix4
-rw-r--r--pkgs/tools/networking/ubridge/default.nix4
-rw-r--r--pkgs/tools/networking/ucspi-tcp/default.nix4
-rw-r--r--pkgs/tools/networking/uget-integrator/default.nix4
-rw-r--r--pkgs/tools/networking/uget/default.nix4
-rw-r--r--pkgs/tools/networking/unbound/python.nix4
-rw-r--r--pkgs/tools/networking/urlwatch/default.nix4
-rw-r--r--pkgs/tools/networking/vde2/default.nix4
-rw-r--r--pkgs/tools/networking/vlan/default.nix4
-rw-r--r--pkgs/tools/networking/vtun/default.nix4
-rw-r--r--pkgs/tools/networking/wavemon/default.nix4
-rw-r--r--pkgs/tools/networking/webalizer/default.nix4
-rw-r--r--pkgs/tools/networking/wget/default.nix4
-rw-r--r--pkgs/tools/networking/whois/default.nix4
-rw-r--r--pkgs/tools/networking/wicd/default.nix4
-rw-r--r--pkgs/tools/networking/wifite2/default.nix2
-rw-r--r--pkgs/tools/networking/wireguard-go/default.nix4
-rw-r--r--pkgs/tools/networking/wol/default.nix4
-rw-r--r--pkgs/tools/networking/wolfebin/default.nix4
-rw-r--r--pkgs/tools/networking/wormhole-william/default.nix4
-rw-r--r--pkgs/tools/networking/wrk/default.nix4
-rw-r--r--pkgs/tools/networking/wuzz/default.nix4
-rw-r--r--pkgs/tools/networking/x11-ssh-askpass/default.nix4
-rw-r--r--pkgs/tools/networking/xl2tpd/default.nix4
-rw-r--r--pkgs/tools/networking/yrd/default.nix4
-rw-r--r--pkgs/tools/networking/zap/default.nix4
-rw-r--r--pkgs/tools/networking/zerotierone/default.nix4
-rw-r--r--pkgs/tools/nix/cached-nix-shell/default.nix4
-rw-r--r--pkgs/tools/nix/dnadd/default.nix4
-rw-r--r--pkgs/tools/nix/manix/default.nix4
-rw-r--r--pkgs/tools/nix/nar-serve/default.nix2
-rw-r--r--pkgs/tools/nix/nix-query-tree-viewer/default.nix4
-rw-r--r--pkgs/tools/nix/nix-script/default.nix4
-rw-r--r--pkgs/tools/nix/nixdoc/default.nix4
-rw-r--r--pkgs/tools/nix/nixos-generators/default.nix2
-rw-r--r--pkgs/tools/package-management/appimagekit/default.nix4
-rw-r--r--pkgs/tools/package-management/apt-dater/default.nix4
-rw-r--r--pkgs/tools/package-management/bunny/default.nix4
-rw-r--r--pkgs/tools/package-management/cargo-outdated/default.nix4
-rw-r--r--pkgs/tools/package-management/cargo-release/default.nix4
-rw-r--r--pkgs/tools/package-management/cargo-update/default.nix4
-rw-r--r--pkgs/tools/package-management/cde/default.nix4
-rw-r--r--pkgs/tools/package-management/clib/default.nix4
-rw-r--r--pkgs/tools/package-management/createrepo_c/default.nix4
-rw-r--r--pkgs/tools/package-management/dpkg/default.nix4
-rw-r--r--pkgs/tools/package-management/gx/default.nix4
-rw-r--r--pkgs/tools/package-management/gx/go/default.nix4
-rw-r--r--pkgs/tools/package-management/home-manager/default.nix4
-rw-r--r--pkgs/tools/package-management/libdnf/default.nix4
-rw-r--r--pkgs/tools/package-management/librepo/default.nix4
-rw-r--r--pkgs/tools/package-management/microdnf/default.nix4
-rw-r--r--pkgs/tools/package-management/mynewt-newt/default.nix4
-rw-r--r--pkgs/tools/package-management/nix-doc/default.nix4
-rw-r--r--pkgs/tools/package-management/nix-du/default.nix4
-rw-r--r--pkgs/tools/package-management/nix-index/default.nix4
-rw-r--r--pkgs/tools/package-management/nix-pin/default.nix2
-rw-r--r--pkgs/tools/package-management/nix-prefetch-scripts/default.nix6
-rw-r--r--pkgs/tools/package-management/nix-prefetch/default.nix4
-rw-r--r--pkgs/tools/package-management/nix-simple-deploy/default.nix4
-rw-r--r--pkgs/tools/package-management/nix-universal-prefetch/default.nix4
-rw-r--r--pkgs/tools/package-management/nixpkgs-review/default.nix2
-rw-r--r--pkgs/tools/package-management/opkg-utils/default.nix4
-rw-r--r--pkgs/tools/package-management/opkg/default.nix4
-rw-r--r--pkgs/tools/package-management/python2nix/default.nix4
-rw-r--r--pkgs/tools/package-management/rpm/default.nix2
-rw-r--r--pkgs/tools/package-management/xbps/default.nix4
-rw-r--r--pkgs/tools/security/1password-gui/default.nix4
-rw-r--r--pkgs/tools/security/2fa/default.nix4
-rw-r--r--pkgs/tools/security/acsccid/default.nix4
-rw-r--r--pkgs/tools/security/aespipe/default.nix4
-rw-r--r--pkgs/tools/security/afl/libdislocator.nix4
-rw-r--r--pkgs/tools/security/afl/qemu.nix4
-rw-r--r--pkgs/tools/security/aflplusplus/libdislocator.nix4
-rw-r--r--pkgs/tools/security/aflplusplus/libtokencap.nix4
-rw-r--r--pkgs/tools/security/aflplusplus/qemu.nix4
-rw-r--r--pkgs/tools/security/aide/default.nix4
-rw-r--r--pkgs/tools/security/asc-key-to-qr-code-gif/default.nix4
-rw-r--r--pkgs/tools/security/aws-iam-authenticator/default.nix4
-rw-r--r--pkgs/tools/security/aws-okta/default.nix4
-rw-r--r--pkgs/tools/security/bash-supergenpass/default.nix4
-rw-r--r--pkgs/tools/security/bettercap/default.nix4
-rw-r--r--pkgs/tools/security/bitwarden/default.nix2
-rw-r--r--pkgs/tools/security/bitwarden_rs/default.nix4
-rw-r--r--pkgs/tools/security/bitwarden_rs/vault.nix4
-rw-r--r--pkgs/tools/security/bmrsa/11.nix4
-rw-r--r--pkgs/tools/security/bruteforce-luks/default.nix4
-rw-r--r--pkgs/tools/security/brutespray/default.nix4
-rw-r--r--pkgs/tools/security/ccid/default.nix4
-rw-r--r--pkgs/tools/security/certmgr/default.nix4
-rw-r--r--pkgs/tools/security/certstrap/default.nix4
-rw-r--r--pkgs/tools/security/cfssl/default.nix4
-rw-r--r--pkgs/tools/security/chaps/default.nix4
-rw-r--r--pkgs/tools/security/chipsec/default.nix2
-rw-r--r--pkgs/tools/security/chkrootkit/default.nix4
-rw-r--r--pkgs/tools/security/chntpw/default.nix4
-rw-r--r--pkgs/tools/security/chrome-token-signing/default.nix4
-rw-r--r--pkgs/tools/security/clamav/default.nix4
-rw-r--r--pkgs/tools/security/cloudbrute/default.nix4
-rw-r--r--pkgs/tools/security/crackxls/default.nix4
-rw-r--r--pkgs/tools/security/creddump/default.nix4
-rw-r--r--pkgs/tools/security/crowbar/default.nix4
-rw-r--r--pkgs/tools/security/crunch/default.nix4
-rw-r--r--pkgs/tools/security/ctmg/default.nix4
-rw-r--r--pkgs/tools/security/deepsea/default.nix4
-rw-r--r--pkgs/tools/security/dnsenum/default.nix4
-rw-r--r--pkgs/tools/security/dnsrecon/default.nix4
-rw-r--r--pkgs/tools/security/dnsx/default.nix4
-rw-r--r--pkgs/tools/security/doona/default.nix4
-rw-r--r--pkgs/tools/security/ecdsatool/default.nix4
-rw-r--r--pkgs/tools/security/ecdsautils/default.nix4
-rw-r--r--pkgs/tools/security/ecryptfs/default.nix4
-rw-r--r--pkgs/tools/security/ecryptfs/helper.nix4
-rw-r--r--pkgs/tools/security/efitools/default.nix4
-rw-r--r--pkgs/tools/security/eid-mw/default.nix4
-rw-r--r--pkgs/tools/security/encryptr/default.nix2
-rw-r--r--pkgs/tools/security/enpass/default.nix2
-rw-r--r--pkgs/tools/security/enum4linux/default.nix4
-rw-r--r--pkgs/tools/security/eschalot/default.nix4
-rw-r--r--pkgs/tools/security/fail2ban/default.nix4
-rw-r--r--pkgs/tools/security/fcrackzip/default.nix4
-rw-r--r--pkgs/tools/security/ffuf/default.nix4
-rw-r--r--pkgs/tools/security/fido2luks/default.nix4
-rw-r--r--pkgs/tools/security/fierce/default.nix4
-rw-r--r--pkgs/tools/security/fprintd/default.nix4
-rw-r--r--pkgs/tools/security/fprot/default.nix4
-rw-r--r--pkgs/tools/security/fwknop/default.nix4
-rw-r--r--pkgs/tools/security/gau/default.nix4
-rw-r--r--pkgs/tools/security/gen-oath-safe/default.nix4
-rw-r--r--pkgs/tools/security/gencfsm/default.nix4
-rw-r--r--pkgs/tools/security/genpass/default.nix4
-rw-r--r--pkgs/tools/security/gnome-keysign/default.nix4
-rw-r--r--pkgs/tools/security/gnupg-pkcs11-scd/default.nix4
-rw-r--r--pkgs/tools/security/gnupg/1.nix4
-rw-r--r--pkgs/tools/security/gnupg/22.nix4
-rw-r--r--pkgs/tools/security/gopass/default.nix4
-rw-r--r--pkgs/tools/security/gospider/default.nix4
-rw-r--r--pkgs/tools/security/gpgstats/default.nix4
-rw-r--r--pkgs/tools/security/grype/default.nix4
-rw-r--r--pkgs/tools/security/hash_extender/default.nix4
-rw-r--r--pkgs/tools/security/hashcash/default.nix4
-rw-r--r--pkgs/tools/security/hashcat-utils/default.nix4
-rw-r--r--pkgs/tools/security/hashcat/default.nix4
-rw-r--r--pkgs/tools/security/hashdeep/default.nix4
-rw-r--r--pkgs/tools/security/hcxdumptool/default.nix2
-rw-r--r--pkgs/tools/security/hcxtools/default.nix4
-rw-r--r--pkgs/tools/security/hologram/default.nix4
-rw-r--r--pkgs/tools/security/httpx/default.nix4
-rw-r--r--pkgs/tools/security/ifdnfc/default.nix4
-rw-r--r--pkgs/tools/security/ipscan/default.nix4
-rw-r--r--pkgs/tools/security/jadx/default.nix4
-rw-r--r--pkgs/tools/security/jd-gui/default.nix4
-rw-r--r--pkgs/tools/security/jwt-cli/default.nix4
-rw-r--r--pkgs/tools/security/kbs2/default.nix4
-rw-r--r--pkgs/tools/security/keybase/default.nix2
-rw-r--r--pkgs/tools/security/keybase/gui.nix2
-rw-r--r--pkgs/tools/security/keybase/kbfs.nix4
-rw-r--r--pkgs/tools/security/knockknock/default.nix4
-rw-r--r--pkgs/tools/security/kpcli/default.nix4
-rw-r--r--pkgs/tools/security/lesspass-cli/default.nix4
-rw-r--r--pkgs/tools/security/libacr38u/default.nix4
-rw-r--r--pkgs/tools/security/libmodsecurity/default.nix4
-rw-r--r--pkgs/tools/security/logkeys/default.nix4
-rw-r--r--pkgs/tools/security/lynis/default.nix4
-rw-r--r--pkgs/tools/security/masscan/default.nix4
-rw-r--r--pkgs/tools/security/medusa/default.nix4
-rw-r--r--pkgs/tools/security/metasploit/default.nix4
-rw-r--r--pkgs/tools/security/mfcuk/default.nix4
-rw-r--r--pkgs/tools/security/mfoc/default.nix4
-rw-r--r--pkgs/tools/security/minisign/default.nix4
-rw-r--r--pkgs/tools/security/mkpasswd/default.nix4
-rw-r--r--pkgs/tools/security/mktemp/default.nix4
-rw-r--r--pkgs/tools/security/monkeysphere/default.nix4
-rw-r--r--pkgs/tools/security/mpw/default.nix4
-rw-r--r--pkgs/tools/security/munge/default.nix4
-rw-r--r--pkgs/tools/security/nasty/default.nix4
-rw-r--r--pkgs/tools/security/ncrack/default.nix4
-rw-r--r--pkgs/tools/security/neopg/default.nix4
-rw-r--r--pkgs/tools/security/nitrokey-app/default.nix4
-rw-r--r--pkgs/tools/security/nmap/qt.nix4
-rw-r--r--pkgs/tools/security/notary/default.nix4
-rw-r--r--pkgs/tools/security/nsjail/default.nix4
-rw-r--r--pkgs/tools/security/nuclei/default.nix4
-rw-r--r--pkgs/tools/security/nwipe/default.nix4
-rw-r--r--pkgs/tools/security/oath-toolkit/default.nix4
-rw-r--r--pkgs/tools/security/omapd/default.nix4
-rw-r--r--pkgs/tools/security/onesixtyone/default.nix4
-rw-r--r--pkgs/tools/security/onioncircuits/default.nix4
-rw-r--r--pkgs/tools/security/open-ecard/default.nix4
-rw-r--r--pkgs/tools/security/opencryptoki/default.nix4
-rw-r--r--pkgs/tools/security/opensc/default.nix4
-rw-r--r--pkgs/tools/security/pamtester/default.nix4
-rw-r--r--pkgs/tools/security/paperkey/default.nix4
-rw-r--r--pkgs/tools/security/pass/default.nix2
-rw-r--r--pkgs/tools/security/pass/extensions/audit/default.nix4
-rw-r--r--pkgs/tools/security/pass/extensions/checkup.nix4
-rw-r--r--pkgs/tools/security/pass/extensions/genphrase.nix4
-rw-r--r--pkgs/tools/security/pass/extensions/import.nix4
-rw-r--r--pkgs/tools/security/pass/extensions/otp.nix4
-rw-r--r--pkgs/tools/security/pass/extensions/tomb.nix4
-rw-r--r--pkgs/tools/security/pass/extensions/update.nix4
-rw-r--r--pkgs/tools/security/passff-host/default.nix4
-rw-r--r--pkgs/tools/security/pbis/default.nix4
-rw-r--r--pkgs/tools/security/pcsc-cyberjack/default.nix4
-rw-r--r--pkgs/tools/security/pcsc-scm-scl011/default.nix4
-rw-r--r--pkgs/tools/security/pcsclite/default.nix4
-rw-r--r--pkgs/tools/security/pgpdump/default.nix4
-rw-r--r--pkgs/tools/security/phrasendrescher/default.nix4
-rw-r--r--pkgs/tools/security/pinentry/default.nix2
-rw-r--r--pkgs/tools/security/proxmark3/default.nix4
-rw-r--r--pkgs/tools/security/pyrit/default.nix2
-rw-r--r--pkgs/tools/security/qdigidoc/default.nix4
-rw-r--r--pkgs/tools/security/rage/default.nix4
-rw-r--r--pkgs/tools/security/rarcrack/default.nix4
-rw-r--r--pkgs/tools/security/rhash/default.nix4
-rw-r--r--pkgs/tools/security/ripasso/cursive.nix2
-rw-r--r--pkgs/tools/security/rustscan/default.nix4
-rw-r--r--pkgs/tools/security/safe/default.nix4
-rw-r--r--pkgs/tools/security/saml2aws/default.nix4
-rw-r--r--pkgs/tools/security/sbsigntool/default.nix4
-rw-r--r--pkgs/tools/security/scallion/default.nix4
-rw-r--r--pkgs/tools/security/scrypt/default.nix4
-rw-r--r--pkgs/tools/security/secp256k1/default.nix4
-rw-r--r--pkgs/tools/security/sedutil/default.nix4
-rw-r--r--pkgs/tools/security/sequoia/default.nix2
-rw-r--r--pkgs/tools/security/sha1collisiondetection/default.nix4
-rw-r--r--pkgs/tools/security/shc/default.nix4
-rw-r--r--pkgs/tools/security/signify/default.nix4
-rw-r--r--pkgs/tools/security/signing-party/default.nix4
-rw-r--r--pkgs/tools/security/simple-tpm-pk11/default.nix4
-rw-r--r--pkgs/tools/security/snow/default.nix4
-rw-r--r--pkgs/tools/security/softhsm/default.nix4
-rw-r--r--pkgs/tools/security/sops/default.nix4
-rw-r--r--pkgs/tools/security/spectre-meltdown-checker/default.nix4
-rw-r--r--pkgs/tools/security/srm/default.nix4
-rw-r--r--pkgs/tools/security/sshguard/default.nix4
-rw-r--r--pkgs/tools/security/sshuttle/default.nix4
-rw-r--r--pkgs/tools/security/sslscan/default.nix4
-rw-r--r--pkgs/tools/security/steghide/default.nix4
-rw-r--r--pkgs/tools/security/stegseek/default.nix4
-rw-r--r--pkgs/tools/security/stoken/default.nix4
-rw-r--r--pkgs/tools/security/su-exec/default.nix4
-rw-r--r--pkgs/tools/security/subjs/default.nix4
-rw-r--r--pkgs/tools/security/sudolikeaboss/default.nix4
-rw-r--r--pkgs/tools/security/tboot/default.nix4
-rw-r--r--pkgs/tools/security/teler/default.nix4
-rw-r--r--pkgs/tools/security/thc-hydra/default.nix2
-rw-r--r--pkgs/tools/security/thc-ipv6/default.nix4
-rw-r--r--pkgs/tools/security/tor/default.nix4
-rw-r--r--pkgs/tools/security/tpm-luks/default.nix4
-rw-r--r--pkgs/tools/security/tpm-quote-tools/default.nix4
-rw-r--r--pkgs/tools/security/tpm-tools/default.nix4
-rw-r--r--pkgs/tools/security/trousers/default.nix4
-rw-r--r--pkgs/tools/security/urlhunter/default.nix4
-rw-r--r--pkgs/tools/security/vault/default.nix4
-rw-r--r--pkgs/tools/security/vault/vault-bin.nix4
-rw-r--r--pkgs/tools/security/volatility/default.nix4
-rw-r--r--pkgs/tools/security/vulnix/default.nix4
-rw-r--r--pkgs/tools/security/wipe/default.nix4
-rw-r--r--pkgs/tools/security/yara/default.nix4
-rw-r--r--pkgs/tools/security/zmap/default.nix4
-rw-r--r--pkgs/tools/security/zzuf/default.nix4
-rw-r--r--pkgs/tools/system/acct/default.nix4
-rw-r--r--pkgs/tools/system/acpica-tools/default.nix4
-rw-r--r--pkgs/tools/system/actkbd/default.nix4
-rw-r--r--pkgs/tools/system/augeas/default.nix4
-rw-r--r--pkgs/tools/system/autocpu-freq/default.nix4
-rw-r--r--pkgs/tools/system/awstats/default.nix4
-rw-r--r--pkgs/tools/system/bfs/default.nix4
-rw-r--r--pkgs/tools/system/bottom/default.nix4
-rw-r--r--pkgs/tools/system/bpytop/default.nix4
-rw-r--r--pkgs/tools/system/clinfo/default.nix4
-rw-r--r--pkgs/tools/system/cm-rgb/default.nix4
-rw-r--r--pkgs/tools/system/collectd/default.nix4
-rw-r--r--pkgs/tools/system/consul-template/default.nix4
-rw-r--r--pkgs/tools/system/cron/default.nix4
-rw-r--r--pkgs/tools/system/daemon/default.nix4
-rw-r--r--pkgs/tools/system/daemonize/default.nix4
-rw-r--r--pkgs/tools/system/das_watchdog/default.nix4
-rw-r--r--pkgs/tools/system/datefudge/default.nix4
-rw-r--r--pkgs/tools/system/dcfldd/default.nix4
-rw-r--r--pkgs/tools/system/dd_rescue/default.nix4
-rw-r--r--pkgs/tools/system/ddrescue/default.nix4
-rw-r--r--pkgs/tools/system/ddrutility/default.nix4
-rw-r--r--pkgs/tools/system/di/default.nix4
-rw-r--r--pkgs/tools/system/disk-filltest/default.nix4
-rw-r--r--pkgs/tools/system/dog/default.nix4
-rw-r--r--pkgs/tools/system/efibootmgr/default.nix4
-rw-r--r--pkgs/tools/system/efivar/default.nix4
-rw-r--r--pkgs/tools/system/envconsul/default.nix4
-rw-r--r--pkgs/tools/system/evemu/default.nix4
-rw-r--r--pkgs/tools/system/facter/default.nix4
-rw-r--r--pkgs/tools/system/fakechroot/default.nix4
-rw-r--r--pkgs/tools/system/fcron/default.nix4
-rw-r--r--pkgs/tools/system/fio/default.nix4
-rw-r--r--pkgs/tools/system/foremost/default.nix4
-rw-r--r--pkgs/tools/system/gdmap/default.nix4
-rw-r--r--pkgs/tools/system/gdu/default.nix4
-rw-r--r--pkgs/tools/system/gotop/default.nix4
-rw-r--r--pkgs/tools/system/gptfdisk/default.nix4
-rw-r--r--pkgs/tools/system/hardinfo/default.nix4
-rw-r--r--pkgs/tools/system/hardlink/default.nix4
-rw-r--r--pkgs/tools/system/honcho/default.nix4
-rw-r--r--pkgs/tools/system/htop/default.nix2
-rw-r--r--pkgs/tools/system/hwinfo/default.nix4
-rw-r--r--pkgs/tools/system/incron/default.nix4
-rw-r--r--pkgs/tools/system/inxi/default.nix2
-rw-r--r--pkgs/tools/system/ioping/default.nix4
-rw-r--r--pkgs/tools/system/iops/default.nix4
-rw-r--r--pkgs/tools/system/ior/default.nix4
-rw-r--r--pkgs/tools/system/ipmiutil/default.nix4
-rw-r--r--pkgs/tools/system/java-service-wrapper/default.nix4
-rw-r--r--pkgs/tools/system/journalwatch/default.nix4
-rw-r--r--pkgs/tools/system/ledmon/default.nix4
-rw-r--r--pkgs/tools/system/loadwatch/default.nix4
-rw-r--r--pkgs/tools/system/localtime/default.nix4
-rw-r--r--pkgs/tools/system/logcheck/default.nix4
-rw-r--r--pkgs/tools/system/lr/default.nix4
-rw-r--r--pkgs/tools/system/lshw/default.nix2
-rw-r--r--pkgs/tools/system/memtester/default.nix4
-rw-r--r--pkgs/tools/system/mlc/default.nix4
-rw-r--r--pkgs/tools/system/nvtop/default.nix4
-rw-r--r--pkgs/tools/system/opencl-info/default.nix4
-rw-r--r--pkgs/tools/system/pciutils/default.nix4
-rw-r--r--pkgs/tools/system/pcstat/default.nix4
-rw-r--r--pkgs/tools/system/plan9port/default.nix4
-rw-r--r--pkgs/tools/system/proot/default.nix4
-rw-r--r--pkgs/tools/system/ps_mem/default.nix4
-rw-r--r--pkgs/tools/system/psstop/default.nix4
-rw-r--r--pkgs/tools/system/rowhammer-test/default.nix4
-rw-r--r--pkgs/tools/system/runit/default.nix4
-rw-r--r--pkgs/tools/system/s-tui/default.nix4
-rw-r--r--pkgs/tools/system/safe-rm/default.nix4
-rw-r--r--pkgs/tools/system/sg3_utils/default.nix4
-rw-r--r--pkgs/tools/system/smartmontools/default.nix4
-rw-r--r--pkgs/tools/system/snooze/default.nix4
-rw-r--r--pkgs/tools/system/stress-ng/default.nix4
-rw-r--r--pkgs/tools/system/stress/default.nix4
-rw-r--r--pkgs/tools/system/suid-chroot/default.nix4
-rw-r--r--pkgs/tools/system/supervise/default.nix4
-rw-r--r--pkgs/tools/system/symlinks/default.nix4
-rw-r--r--pkgs/tools/system/syslog-ng-incubator/default.nix4
-rw-r--r--pkgs/tools/system/syslog-ng/default.nix4
-rw-r--r--pkgs/tools/system/systemd-journal2gelf/default.nix4
-rw-r--r--pkgs/tools/system/testdisk/default.nix4
-rw-r--r--pkgs/tools/system/thermald/default.nix4
-rw-r--r--pkgs/tools/system/thinkfan/default.nix4
-rw-r--r--pkgs/tools/system/throttled/default.nix4
-rw-r--r--pkgs/tools/system/tm/default.nix4
-rw-r--r--pkgs/tools/system/tre-command/default.nix4
-rw-r--r--pkgs/tools/system/ts/default.nix4
-rw-r--r--pkgs/tools/system/tuptime/default.nix4
-rw-r--r--pkgs/tools/system/uptimed/default.nix4
-rw-r--r--pkgs/tools/system/vbetool/default.nix4
-rw-r--r--pkgs/tools/system/vboot_reference/default.nix4
-rw-r--r--pkgs/tools/system/which/default.nix4
-rw-r--r--pkgs/tools/system/wsmancli/default.nix4
-rw-r--r--pkgs/tools/system/yeshup/default.nix4
-rw-r--r--pkgs/tools/system/zenith/default.nix4
-rw-r--r--pkgs/tools/text/a2ps/default.nix4
-rw-r--r--pkgs/tools/text/agrep/default.nix4
-rw-r--r--pkgs/tools/text/aha/default.nix4
-rw-r--r--pkgs/tools/text/amber/default.nix4
-rw-r--r--pkgs/tools/text/angle-grinder/default.nix4
-rw-r--r--pkgs/tools/text/ansifilter/default.nix4
-rw-r--r--pkgs/tools/text/ascii/default.nix4
-rw-r--r--pkgs/tools/text/boxes/default.nix4
-rw-r--r--pkgs/tools/text/catdoc/default.nix4
-rw-r--r--pkgs/tools/text/catdocx/default.nix2
-rw-r--r--pkgs/tools/text/cconv/default.nix4
-rw-r--r--pkgs/tools/text/chars/default.nix4
-rw-r--r--pkgs/tools/text/choose/default.nix4
-rw-r--r--pkgs/tools/text/cmigemo/default.nix4
-rw-r--r--pkgs/tools/text/colordiff/default.nix4
-rw-r--r--pkgs/tools/text/coloursum/default.nix4
-rw-r--r--pkgs/tools/text/copyright-update/default.nix4
-rw-r--r--pkgs/tools/text/dadadodo/default.nix4
-rw-r--r--pkgs/tools/text/diffr/default.nix4
-rw-r--r--pkgs/tools/text/diffstat/default.nix4
-rw-r--r--pkgs/tools/text/diffutils/default.nix4
-rw-r--r--pkgs/tools/text/discount/default.nix4
-rw-r--r--pkgs/tools/text/dos2unix/default.nix4
-rw-r--r--pkgs/tools/text/enca/default.nix4
-rw-r--r--pkgs/tools/text/epubcheck/default.nix4
-rw-r--r--pkgs/tools/text/esh/default.nix4
-rw-r--r--pkgs/tools/text/fanficfare/default.nix4
-rw-r--r--pkgs/tools/text/fastmod/default.nix4
-rw-r--r--pkgs/tools/text/gawk/default.nix5
-rw-r--r--pkgs/tools/text/gawk/gawkextlib.nix4
-rw-r--r--pkgs/tools/text/gjo/default.nix4
-rw-r--r--pkgs/tools/text/glogg/default.nix4
-rw-r--r--pkgs/tools/text/gnugrep/default.nix4
-rw-r--r--pkgs/tools/text/grip-search/default.nix4
-rw-r--r--pkgs/tools/text/groff/default.nix4
-rw-r--r--pkgs/tools/text/gtranslator/default.nix4
-rw-r--r--pkgs/tools/text/gucci/default.nix4
-rw-r--r--pkgs/tools/text/highlight/default.nix4
-rw-r--r--pkgs/tools/text/html-tidy/default.nix4
-rw-r--r--pkgs/tools/text/icdiff/default.nix4
-rw-r--r--pkgs/tools/text/invoice2data/default.nix4
-rw-r--r--pkgs/tools/text/ispell/default.nix4
-rw-r--r--pkgs/tools/text/jumanpp/default.nix4
-rw-r--r--pkgs/tools/text/kakasi/default.nix4
-rw-r--r--pkgs/tools/text/kytea/default.nix4
-rw-r--r--pkgs/tools/text/languagetool/default.nix4
-rw-r--r--pkgs/tools/text/link-grammar/default.nix4
-rw-r--r--pkgs/tools/text/lv/default.nix4
-rw-r--r--pkgs/tools/text/markdown-pp/default.nix4
-rw-r--r--pkgs/tools/text/mawk/default.nix4
-rw-r--r--pkgs/tools/text/mb2md/default.nix4
-rw-r--r--pkgs/tools/text/mdbook/default.nix4
-rw-r--r--pkgs/tools/text/mdcat/default.nix4
-rw-r--r--pkgs/tools/text/mecab/default.nix4
-rw-r--r--pkgs/tools/text/miller/default.nix4
-rw-r--r--pkgs/tools/text/numdiff/default.nix4
-rw-r--r--pkgs/tools/text/ocrmypdf/default.nix4
-rw-r--r--pkgs/tools/text/opencc/default.nix4
-rw-r--r--pkgs/tools/text/papertrail/default.nix4
-rw-r--r--pkgs/tools/text/par/default.nix4
-rw-r--r--pkgs/tools/text/patchutils/generic.nix4
-rw-r--r--pkgs/tools/text/pbgopy/default.nix4
-rw-r--r--pkgs/tools/text/peco/default.nix4
-rw-r--r--pkgs/tools/text/platinum-searcher/default.nix4
-rw-r--r--pkgs/tools/text/podiff/default.nix4
-rw-r--r--pkgs/tools/text/poedit/default.nix4
-rw-r--r--pkgs/tools/text/proselint/default.nix4
-rw-r--r--pkgs/tools/text/qgrep/default.nix4
-rw-r--r--pkgs/tools/text/rgxg/default.nix4
-rw-r--r--pkgs/tools/text/ripgrep-all/default.nix2
-rw-r--r--pkgs/tools/text/ripgrep/default.nix4
-rw-r--r--pkgs/tools/text/rpl/default.nix4
-rw-r--r--pkgs/tools/text/rs/default.nix4
-rw-r--r--pkgs/tools/text/ruplacer/default.nix4
-rw-r--r--pkgs/tools/text/schema2ldif/default.nix4
-rw-r--r--pkgs/tools/text/sd/default.nix4
-rw-r--r--pkgs/tools/text/shocco/default.nix4
-rw-r--r--pkgs/tools/text/silver-searcher/default.nix4
-rw-r--r--pkgs/tools/text/snippetpixie/default.nix4
-rw-r--r--pkgs/tools/text/tab/default.nix4
-rw-r--r--pkgs/tools/text/transifex-client/default.nix4
-rw-r--r--pkgs/tools/text/ucg/default.nix4
-rw-r--r--pkgs/tools/text/ugrep/default.nix4
-rw-r--r--pkgs/tools/text/unoconv/default.nix4
-rw-r--r--pkgs/tools/text/unrtf/default.nix4
-rw-r--r--pkgs/tools/text/untex/default.nix4
-rw-r--r--pkgs/tools/text/vale/default.nix4
-rw-r--r--pkgs/tools/text/xidel/default.nix4
-rw-r--r--pkgs/tools/text/xml/basex/default.nix4
-rw-r--r--pkgs/tools/text/xml/html-xml-utils/default.nix4
-rw-r--r--pkgs/tools/text/xml/jing-trang/default.nix4
-rw-r--r--pkgs/tools/text/xml/rnv/default.nix4
-rw-r--r--pkgs/tools/text/xml/xml2/default.nix4
-rw-r--r--pkgs/tools/text/xml/xmloscopy/default.nix2
-rw-r--r--pkgs/tools/text/xsv/default.nix4
-rw-r--r--pkgs/tools/text/xurls/default.nix4
-rw-r--r--pkgs/tools/text/yaml-merge/default.nix4
-rw-r--r--pkgs/tools/typesetting/asciidoc/default.nix4
-rw-r--r--pkgs/tools/typesetting/asciidoctorj/default.nix4
-rw-r--r--pkgs/tools/typesetting/bibclean/default.nix4
-rw-r--r--pkgs/tools/typesetting/biber/default.nix4
-rw-r--r--pkgs/tools/typesetting/biblatex-check/default.nix4
-rw-r--r--pkgs/tools/typesetting/docbook2odf/default.nix4
-rw-r--r--pkgs/tools/typesetting/docbook2x/default.nix4
-rw-r--r--pkgs/tools/typesetting/fop/default.nix4
-rw-r--r--pkgs/tools/typesetting/git-latexdiff/default.nix4
-rw-r--r--pkgs/tools/typesetting/halibut/default.nix4
-rw-r--r--pkgs/tools/typesetting/hevea/default.nix4
-rw-r--r--pkgs/tools/typesetting/htmldoc/default.nix4
-rw-r--r--pkgs/tools/typesetting/kindlegen/default.nix4
-rw-r--r--pkgs/tools/typesetting/lowdown/default.nix4
-rw-r--r--pkgs/tools/typesetting/multimarkdown/default.nix4
-rw-r--r--pkgs/tools/typesetting/odpdown/default.nix4
-rw-r--r--pkgs/tools/typesetting/pdf2djvu/default.nix2
-rw-r--r--pkgs/tools/typesetting/pdf2odt/default.nix2
-rw-r--r--pkgs/tools/typesetting/pdfsandwich/default.nix4
-rw-r--r--pkgs/tools/typesetting/pdftk/default.nix4
-rw-r--r--pkgs/tools/typesetting/psutils/default.nix4
-rw-r--r--pkgs/tools/typesetting/rubber/default.nix4
-rw-r--r--pkgs/tools/typesetting/satysfi/default.nix4
-rw-r--r--pkgs/tools/typesetting/scdoc/default.nix4
-rw-r--r--pkgs/tools/typesetting/sile/default.nix4
-rw-r--r--pkgs/tools/typesetting/sshlatex/default.nix4
-rw-r--r--pkgs/tools/typesetting/tectonic/default.nix4
-rw-r--r--pkgs/tools/typesetting/ted/default.nix4
-rw-r--r--pkgs/tools/typesetting/tex/lkproof/default.nix4
-rw-r--r--pkgs/tools/typesetting/tex/pgf/1.x.nix4
-rw-r--r--pkgs/tools/typesetting/tex/pgf/2.x.nix4
-rw-r--r--pkgs/tools/typesetting/tex/pgf/3.x.nix4
-rw-r--r--pkgs/tools/typesetting/tex/pgfplots/default.nix4
-rw-r--r--pkgs/tools/typesetting/tex/pplatex/default.nix4
-rw-r--r--pkgs/tools/typesetting/tex/tetex/default.nix4
-rw-r--r--pkgs/tools/typesetting/tex/texlive/bin.nix6
-rw-r--r--pkgs/tools/typesetting/tikzit/default.nix4
-rw-r--r--pkgs/tools/typesetting/xmlroff/default.nix4
-rw-r--r--pkgs/tools/video/atomicparsley/default.nix4
-rw-r--r--pkgs/tools/video/bento4/default.nix4
-rw-r--r--pkgs/tools/video/dvgrab/default.nix4
-rw-r--r--pkgs/tools/video/gopro/default.nix4
-rw-r--r--pkgs/tools/video/mjpegtools/default.nix2
-rw-r--r--pkgs/tools/video/svt-av1/default.nix4
-rw-r--r--pkgs/tools/video/untrunc-anthwlock/default.nix4
-rw-r--r--pkgs/tools/video/untrunc/default.nix4
-rw-r--r--pkgs/tools/video/yamdi/default.nix4
-rw-r--r--pkgs/tools/virtualization/amazon-ecs-cli/default.nix4
-rw-r--r--pkgs/tools/virtualization/awless/default.nix4
-rw-r--r--pkgs/tools/virtualization/awsebcli/default.nix4
-rw-r--r--pkgs/tools/virtualization/distrobuilder/default.nix4
-rw-r--r--pkgs/tools/virtualization/google-compute-engine-oslogin/default.nix2
-rw-r--r--pkgs/tools/virtualization/marathonctl/default.nix4
-rw-r--r--pkgs/tools/virtualization/nixos-shell/default.nix4
-rw-r--r--pkgs/tools/virtualization/udocker/default.nix4
-rw-r--r--pkgs/tools/wayland/wayland-utils/default.nix4
-rw-r--r--pkgs/tools/wayland/wlsunset/default.nix4
-rw-r--r--pkgs/tools/wayland/wshowkeys/default.nix4
-rw-r--r--pkgs/tools/wayland/ydotool/default.nix4
6869 files changed, 13585 insertions, 13580 deletions
diff --git a/pkgs/applications/accessibility/contrast/default.nix b/pkgs/applications/accessibility/contrast/default.nix
index 8f70f632cd6ec..1d18f4a923021 100644
--- a/pkgs/applications/accessibility/contrast/default.nix
+++ b/pkgs/applications/accessibility/contrast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , cairo
 , dbus
@@ -62,7 +62,7 @@ rustPlatform.buildRustPackage rec {
   checkPhase = null;
   installPhase = null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Checks whether the contrast between two colors meet the WCAG requirements";
     homepage = "https://gitlab.gnome.org/World/design/contrast";
     license = licenses.gpl3;
diff --git a/pkgs/applications/accessibility/mousetweaks/default.nix b/pkgs/applications/accessibility/mousetweaks/default.nix
index b645bc61848be..769ea241de89c 100644
--- a/pkgs/applications/accessibility/mousetweaks/default.nix
+++ b/pkgs/applications/accessibility/mousetweaks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , glib, gtk3, gnome3, gsettings-desktop-schemas, wrapGAppsHook
 , libX11, libXtst, libXfixes, libXcursor
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides mouse accessibility enhancements for the GNOME desktop";
     longDescription = ''
       Mousetweaks provides mouse accessibility enhancements for the GNOME
diff --git a/pkgs/applications/audio/a2jmidid/default.nix b/pkgs/applications/audio/a2jmidid/default.nix
index 9840488289233..35c9cda1821c7 100644
--- a/pkgs/applications/audio/a2jmidid/default.nix
+++ b/pkgs/applications/audio/a2jmidid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, makeWrapper, pkgconfig, alsaLib, dbus, libjack2
+{ lib, stdenv, fetchFromGitHub, fetchpatch, makeWrapper, pkgconfig, alsaLib, dbus, libjack2
 , python3Packages , meson, ninja }:
 
 stdenv.mkDerivation rec {
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/bin/a2j --replace "a2j_control" "$out/bin/a2j_control"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon for exposing legacy ALSA sequencer applications in JACK MIDI system";
     license = licenses.gpl2;
     maintainers = [ maintainers.goibhniu ];
diff --git a/pkgs/applications/audio/aacgain/default.nix b/pkgs/applications/audio/aacgain/default.nix
index 83b359b1b1cbe..d4fc3fbe698ea 100644
--- a/pkgs/applications/audio/aacgain/default.nix
+++ b/pkgs/applications/audio/aacgain/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, fetchpatch }:
+{ lib, stdenv, fetchFromGitLab, fetchpatch }:
 
 stdenv.mkDerivation {
   name = "aacgain-1.9.0";
@@ -53,7 +53,7 @@ stdenv.mkDerivation {
     install -D aacgain/aacgain "$out/bin/aacgain"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ReplayGain for AAC files";
     homepage = "https://aacgain.altosdesign.com";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/abcde/default.nix b/pkgs/applications/audio/abcde/default.nix
index 4cb28e512a72c..a90051136cb97 100644
--- a/pkgs/applications/audio/abcde/default.nix
+++ b/pkgs/applications/audio/abcde/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libcdio-paranoia, cddiscid, wget, which, vorbis-tools, id3v2, eyeD3
+{ lib, stdenv, fetchurl, libcdio-paranoia, cddiscid, wget, which, vorbis-tools, id3v2, eyeD3
 , lame, flac, glyr
 , perlPackages
 , makeWrapper }:
@@ -45,7 +45,7 @@ in
       done
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://abcde.einval.com/wiki/";
       license = licenses.gpl2Plus;
       maintainers = with maintainers; [ gebner ];
diff --git a/pkgs/applications/audio/adlplug/default.nix b/pkgs/applications/audio/adlplug/default.nix
index 7dcc13eb96d53..cdf9e3e538ee2 100644
--- a/pkgs/applications/audio/adlplug/default.nix
+++ b/pkgs/applications/audio/adlplug/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, libjack2, alsaLib
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, libjack2, alsaLib
 , freetype, libX11, libXrandr, libXinerama, libXext, libXcursor
 , fetchpatch, fmt
 , adlplugChip ? "-DADLplug_CHIP=OPL3"
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   ];
   nativeBuildInputs = [ cmake pkgconfig fmt ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OPL3 and OPN2 FM Chip Synthesizer";
     homepage = src.meta.homepage;
     license = licenses.boost;
diff --git a/pkgs/applications/audio/airwave/default.nix b/pkgs/applications/audio/airwave/default.nix
index 176d1d4cfb37e..d541afd2de3d7 100644
--- a/pkgs/applications/audio/airwave/default.nix
+++ b/pkgs/applications/audio/airwave/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, multiStdenv, cmake, fetchFromGitHub, file, libX11, makeWrapper
+{ lib, stdenv, multiStdenv, cmake, fetchFromGitHub, file, libX11, makeWrapper
 , qt5, requireFile, unzip, wine
 }:
 
@@ -73,7 +73,7 @@ multiStdenv.mkDerivation {
     wrapProgram $out/libexec/airwave-host-64.exe --set WINELOADER ${wine-xembed}/bin/wine64
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WINE-based VST bridge for Linux VST hosts";
     longDescription = ''
       Airwave is a wine based VST bridge, that allows for the use of
diff --git a/pkgs/applications/audio/aj-snapshot/default.nix b/pkgs/applications/audio/aj-snapshot/default.nix
index 2a2e15d9849a7..e4a196d0f6bf3 100644
--- a/pkgs/applications/audio/aj-snapshot/default.nix
+++ b/pkgs/applications/audio/aj-snapshot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, jack2Full, minixml, pkgconfig }:
+{ lib, stdenv, fetchurl, alsaLib, jack2Full, minixml, pkgconfig }:
 
 stdenv.mkDerivation rec {
   name =  packageName + "-" + version ;
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ alsaLib minixml jack2Full ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for storing/restoring JACK and/or ALSA connections to/from cml files";
     longDescription = ''
     Aj-snapshot is a small program that can be used to make snapshots of the connections made between JACK and/or ALSA clients.
diff --git a/pkgs/applications/audio/ams-lv2/default.nix b/pkgs/applications/audio/ams-lv2/default.nix
index a978b67c5dc7e..99c3ca7360768 100644
--- a/pkgs/applications/audio/ams-lv2/default.nix
+++ b/pkgs/applications/audio/ams-lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cairo, fftw, gtkmm2, lv2, lvtk, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cairo, fftw, gtkmm2, lv2, lvtk, pkgconfig
 , wafHook, python3 }:
 
 stdenv.mkDerivation  rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation  rec {
   nativeBuildInputs = [ pkgconfig wafHook python3 ];
   buildInputs = [ cairo fftw gtkmm2 lv2 lvtk ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An LV2 port of the internal modules found in Alsa Modular Synth";
     homepage = "https://github.com/blablack/ams-lv2";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/ams/default.nix b/pkgs/applications/audio/ams/default.nix
index e6c4fbe802e1a..188584b8e7328 100644
--- a/pkgs/applications/audio/ams/default.nix
+++ b/pkgs/applications/audio/ams/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , automake
 , alsaLib
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     qttools
   ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Realtime modular synthesizer for ALSA";
     homepage = "http://alsamodular.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/ardour/5.nix b/pkgs/applications/audio/ardour/5.nix
index 86879e4e5bd82..4a0656ed9ce27 100644
--- a/pkgs/applications/audio/ardour/5.nix
+++ b/pkgs/applications/audio/ardour/5.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , alsaLib
 , aubio
@@ -143,7 +143,7 @@ in stdenv.mkDerivation rec {
     install -vDm 644 "ardour.1"* -t "$out/share/man/man1"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-track hard disk recording software";
     longDescription = ''
       Ardour is a digital audio workstation (DAW), You can use it to
diff --git a/pkgs/applications/audio/ardour/default.nix b/pkgs/applications/audio/ardour/default.nix
index 314153bf260c2..26e25c687e776 100644
--- a/pkgs/applications/audio/ardour/default.nix
+++ b/pkgs/applications/audio/ardour/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , alsaLib
 , aubio
@@ -162,7 +162,7 @@ stdenv.mkDerivation rec {
 
   LINKFLAGS = "-lpthread";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-track hard disk recording software";
     longDescription = ''
       Ardour is a digital audio workstation (DAW), You can use it to
diff --git a/pkgs/applications/audio/artyFX/default.nix b/pkgs/applications/audio/artyFX/default.nix
index 75494c0d37a6c..84914e3e798a5 100644
--- a/pkgs/applications/audio/artyFX/default.nix
+++ b/pkgs/applications/audio/artyFX/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , cairomm, cmake, libjack2, libpthreadstubs, libXdmcp, libxshmfence, libsndfile, lv2, ntk, pkg-config }:
+{ lib, stdenv, fetchFromGitHub , cairomm, cmake, libjack2, libpthreadstubs, libXdmcp, libxshmfence, libsndfile, lv2, ntk, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "artyFX";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkg-config ];
   buildInputs = [ cairomm libjack2 libpthreadstubs libXdmcp libxshmfence libsndfile lv2 ntk ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://openavproductions.com/artyfx/";
     description = "A LV2 plugin bundle of artistic realtime effects";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/ashuffle/default.nix b/pkgs/applications/audio/ashuffle/default.nix
index 6bb21b5edaabd..f21cb9e3907fe 100644
--- a/pkgs/applications/audio/ashuffle/default.nix
+++ b/pkgs/applications/audio/ashuffle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, mpd_clientlib, meson, ninja }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, mpd_clientlib, meson, ninja }:
 
 stdenv.mkDerivation rec {
   pname = "ashuffle";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkg-config meson ninja ];
   buildInputs = [ mpd_clientlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/joshkunz/ashuffle";
     description = "Automatic library-wide shuffle for mpd";
     maintainers = [ maintainers.tcbravo ];
diff --git a/pkgs/applications/audio/aucatctl/default.nix b/pkgs/applications/audio/aucatctl/default.nix
index 4aff3e1f7bfbc..ad9fefb68b9f5 100644
--- a/pkgs/applications/audio/aucatctl/default.nix
+++ b/pkgs/applications/audio/aucatctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, sndio, libbsd }:
+{ lib, stdenv, fetchurl, sndio, libbsd }:
 
 stdenv.mkDerivation rec {
   pname = "aucatctl";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
         --replace '#include <string.h>' '#include <bsd/string.h>'
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "The aucatctl utility sends MIDI messages to control sndiod and/or aucat volumes";
     homepage = "http://www.sndio.org";
diff --git a/pkgs/applications/audio/audacity/default.nix b/pkgs/applications/audio/audacity/default.nix
index 1a29ed8b9785e..1f5468f7db389 100644
--- a/pkgs/applications/audio/audacity/default.nix
+++ b/pkgs/applications/audio/audacity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, wxGTK30, pkgconfig, file, gettext,
+{ lib, stdenv, fetchzip, wxGTK30, pkgconfig, file, gettext,
   libvorbis, libmad, libjack2, lv2, lilv, serd, sord, sratom, suil, alsaLib, libsndfile, soxr, flac, lame,
   expat, libid3tag, ffmpeg_3, soundtouch, /*, portaudio - given up fighting their portaudio.patch */
   cmake
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
   dontDisableStatic = true;
   doCheck = false; # Test fails
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sound editor with graphical UI";
     homepage = "https://www.audacityteam.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/audio-recorder/default.nix b/pkgs/applications/audio/audio-recorder/default.nix
index eee293b76c2f9..a66bb50f082cc 100644
--- a/pkgs/applications/audio/audio-recorder/default.nix
+++ b/pkgs/applications/audio/audio-recorder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , pkgconfig, intltool
 , glib, dbus, gtk3, libappindicator-gtk3, gst_all_1
 , librsvg, wrapGAppsHook
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     gstreamer gst-plugins-base gst-plugins-good gst-plugins-bad gst-plugins-ugly gst-libav
   ]) ++ stdenv.lib.optional pulseaudioSupport libpulseaudio;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Audio recorder for GNOME and Unity Desktops";
     longDescription = ''
       This program allows you to record your favourite music or audio to a file.
diff --git a/pkgs/applications/audio/autotalent/default.nix b/pkgs/applications/audio/autotalent/default.nix
index 8efa26777864b..ba96aa51d6068 100644
--- a/pkgs/applications/audio/autotalent/default.nix
+++ b/pkgs/applications/audio/autotalent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "autotalent";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     sed -r 's/^const LADSPA_Descriptor \*/__attribute__ ((visibility ("default"))) \0/' -i autotalent.c
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://tombaran.info/autotalent.html";
     description = "A real-time pitch correction LADSPA plugin (no MIDI control)";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/axoloti/default.nix b/pkgs/applications/audio/axoloti/default.nix
index 3d907e421b3e3..df885c90371f0 100644
--- a/pkgs/applications/audio/axoloti/default.nix
+++ b/pkgs/applications/audio/axoloti/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, makeWrapper, unzip
+{ lib, stdenv, fetchFromGitHub, fetchurl, makeWrapper, unzip
 , gnumake, gcc-arm-embedded, binutils-arm-embedded
 , dfu-util-axoloti, jdk, ant, libfaketime }:
 
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jdk}/bin/java $out/bin/axoloti --add-flags "-Daxoloti_release=$out/share/axoloti -Daxoloti_runtime=$out/share/axoloti -jar $out/share/axoloti/Axoloti.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.axoloti.com";
     description = ''
       Sketching embedded digital audio algorithms.
diff --git a/pkgs/applications/audio/axoloti/dfu-util.nix b/pkgs/applications/audio/axoloti/dfu-util.nix
index 80ec696c64594..4b4b5ce56780b 100644
--- a/pkgs/applications/audio/axoloti/dfu-util.nix
+++ b/pkgs/applications/audio/axoloti/dfu-util.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libusb1-axoloti }:
+{ lib, stdenv, fetchurl, pkgconfig, libusb1-axoloti }:
 
 stdenv.mkDerivation rec {
   pname = "dfu-util";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
     sha256 = "0n7h08avlzin04j93m6hkq9id6hxjiiix7ff9gc2n89aw6dxxjsm";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Device firmware update (DFU) USB programmer";
     longDescription = ''
       dfu-util is a program that implements the host (PC) side of the USB
diff --git a/pkgs/applications/audio/axoloti/libusb1.nix b/pkgs/applications/audio/axoloti/libusb1.nix
index 255cf3f5e3bfc..e95b391fc7818 100644
--- a/pkgs/applications/audio/axoloti/libusb1.nix
+++ b/pkgs/applications/audio/axoloti/libusb1.nix
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     sed 's,-ludev,-L${lib.getLib systemd}/lib -ludev,' -i $out/lib/libusb-1.0.la
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.libusb.info";
     description = "User-space USB library";
     platforms = platforms.unix;
diff --git a/pkgs/applications/audio/bambootracker/default.nix b/pkgs/applications/audio/bambootracker/default.nix
index f1f97de256e6b..8e9a566c172b7 100644
--- a/pkgs/applications/audio/bambootracker/default.nix
+++ b/pkgs/applications/audio/bambootracker/default.nix
@@ -1,5 +1,5 @@
 { mkDerivation
-, stdenv
+, lib, stdenv
 , fetchFromGitHub
 , qmake
 , qtbase
@@ -40,7 +40,7 @@ mkDerivation rec {
     ++ optional pulseSupport "CONFIG+=use_pulse"
     ++ optionals jackSupport [ "CONFIG+=use_jack" "CONFIG+=jack_has_rename" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tracker for YM2608 (OPNA) which was used in NEC PC-8801/9801 series computers";
     homepage = "https://github.com/rerrahkr/BambooTracker";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/audio/baudline/default.nix b/pkgs/applications/audio/baudline/default.nix
index 0d95675d1e67a..2f695b6ed7b4b 100644
--- a/pkgs/applications/audio/baudline/default.nix
+++ b/pkgs/applications/audio/baudline/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libXmu, libXt, libX11, libXext, libXxf86vm, libjack2
+{ lib, stdenv, fetchurl, libXmu, libXt, libX11, libXext, libXxf86vm, libjack2
 , makeWrapper
 }:
 
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scientific signal analysis application";
     longDescription = ''
       Baudline is a time-frequency browser designed for scientific
diff --git a/pkgs/applications/audio/bchoppr/default.nix b/pkgs/applications/audio/bchoppr/default.nix
index 33827287712aa..ffe9e549eb230 100644
--- a/pkgs/applications/audio/bchoppr/default.nix
+++ b/pkgs/applications/audio/bchoppr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, cairo, libX11, lv2 }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, cairo, libX11, lv2 }:
 
 stdenv.mkDerivation rec {
   pname = "bchoppr";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = https://github.com/sjaehn/BChoppr;
     description = "An audio stream chopping LV2 plugin";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/bitmeter/default.nix b/pkgs/applications/audio/bitmeter/default.nix
index ac05a9367cc99..ebea6251dfb05 100644
--- a/pkgs/applications/audio/bitmeter/default.nix
+++ b/pkgs/applications/audio/bitmeter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoreconfHook, fetchurl, libjack2, gtk2, pkgconfig }:
+{ lib, stdenv, autoreconfHook, fetchurl, libjack2, gtk2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "bitmeter";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://devel.tlrmx.org/audio/bitmeter/";
     description = "Also known as jack bitscope. Useful to detect denormals";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/bitwig-studio/bitwig-studio1.nix b/pkgs/applications/audio/bitwig-studio/bitwig-studio1.nix
index 61d522f677fe0..97c27d4ad9aff 100644
--- a/pkgs/applications/audio/bitwig-studio/bitwig-studio1.nix
+++ b/pkgs/applications/audio/bitwig-studio/bitwig-studio1.nix
@@ -83,7 +83,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A digital audio workstation";
     longDescription = ''
       Bitwig Studio is a multi-platform music-creation system for
diff --git a/pkgs/applications/audio/bitwig-studio/bitwig-studio3.nix b/pkgs/applications/audio/bitwig-studio/bitwig-studio3.nix
index 1e2a61a169af5..31086b3674d90 100644
--- a/pkgs/applications/audio/bitwig-studio/bitwig-studio3.nix
+++ b/pkgs/applications/audio/bitwig-studio/bitwig-studio3.nix
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
 
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A digital audio workstation";
     longDescription = ''
       Bitwig Studio is a multi-platform music-creation system for
diff --git a/pkgs/applications/audio/bjumblr/default.nix b/pkgs/applications/audio/bjumblr/default.nix
index e1a5bee64b305..cc6df2328e073 100644
--- a/pkgs/applications/audio/bjumblr/default.nix
+++ b/pkgs/applications/audio/bjumblr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, cairo, lv2, pkgconfig, libsndfile }:
+{ lib, stdenv, fetchFromGitHub, libX11, cairo, lv2, pkgconfig, libsndfile }:
 
 stdenv.mkDerivation rec {
   pname = "BJumblr";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sjaehn/BJumblr";
     description = "Pattern-controlled audio stream / sample re-sequencer LV2 plugin";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/bristol/default.nix b/pkgs/applications/audio/bristol/default.nix
index 704b888e22932..d58ff73bb70a9 100644
--- a/pkgs/applications/audio/bristol/default.nix
+++ b/pkgs/applications/audio/bristol/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, libjack2, pkgconfig, libpulseaudio, xorg }:
+{ lib, stdenv, fetchurl, alsaLib, libjack2, pkgconfig, libpulseaudio, xorg }:
 
 stdenv.mkDerivation  rec {
   pname = "bristol";
@@ -24,7 +24,7 @@ stdenv.mkDerivation  rec {
     sed -e "s@\`which brighton\`@$out/bin/brighton@g" -i bin/startBristol
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A range of synthesiser, electric piano and organ emulations";
     homepage = "http://bristol.sourceforge.net";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/bschaffl/default.nix b/pkgs/applications/audio/bschaffl/default.nix
index c0d11e1fe5acc..c8fae58ac2fbf 100644
--- a/pkgs/applications/audio/bschaffl/default.nix
+++ b/pkgs/applications/audio/bschaffl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, cairo, libX11, lv2 }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, cairo, libX11, lv2 }:
 
 stdenv.mkDerivation rec {
   pname = "bschaffl";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sjaehn/BSchaffl";
     description = "Pattern-controlled MIDI amp & time stretch LV2 plugin";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/bsequencer/default.nix b/pkgs/applications/audio/bsequencer/default.nix
index 093e9450de8bb..93e010d826dc1 100644
--- a/pkgs/applications/audio/bsequencer/default.nix
+++ b/pkgs/applications/audio/bsequencer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, cairo, lv2, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, xorg, cairo, lv2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "BSEQuencer";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sjaehn/BSEQuencer";
     description = "Multi channel MIDI step sequencer LV2 plugin";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/bshapr/default.nix b/pkgs/applications/audio/bshapr/default.nix
index aa4374c79bc1e..e4f96e396c9bd 100644
--- a/pkgs/applications/audio/bshapr/default.nix
+++ b/pkgs/applications/audio/bshapr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, cairo, lv2, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, xorg, cairo, lv2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "BShapr";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sjaehn/BShapr";
     description = "Beat / envelope shaper LV2 plugin";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/bslizr/default.nix b/pkgs/applications/audio/bslizr/default.nix
index e239a89b89952..c833bd1262b1c 100644
--- a/pkgs/applications/audio/bslizr/default.nix
+++ b/pkgs/applications/audio/bslizr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, cairo, lv2, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, xorg, cairo, lv2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "BSlizr";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sjaehn/BSlizr";
     description = "Sequenced audio slicing effect LV2 plugin (step sequencer effect)";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/calf/default.nix b/pkgs/applications/audio/calf/default.nix
index bbeef4c395a2b..8fecd558e678c 100644
--- a/pkgs/applications/audio/calf/default.nix
+++ b/pkgs/applications/audio/calf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cairo, expat, fftwSinglePrec, fluidsynth, glib
+{ lib, stdenv, fetchurl, cairo, expat, fftwSinglePrec, fluidsynth, glib
 , gtk2, libjack2, ladspaH , libglade, lv2, pkgconfig }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     libglade lv2 pkgconfig
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://calf-studio-gear.org";
     description = "A set of high quality open source audio plugins for musicians";
     license = licenses.lgpl2;
diff --git a/pkgs/applications/audio/carla/default.nix b/pkgs/applications/audio/carla/default.nix
index 8a566c2499178..883daa2ddef95 100644
--- a/pkgs/applications/audio/carla/default.nix
+++ b/pkgs/applications/audio/carla/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, alsaLib, file, fluidsynth, ffmpeg_3, jack2,
+{ lib, stdenv, fetchFromGitHub, alsaLib, file, fluidsynth, ffmpeg_3, jack2,
   liblo, libpulseaudio, libsndfile, pkgconfig, python3Packages,
   which, withFrontend ? true,
   withQt ? true, qtbase ? null, wrapQtAppsHook ? null,
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://kxstudio.sf.net/carla";
     description = "An audio plugin host";
     longDescription = ''
diff --git a/pkgs/applications/audio/caudec/default.nix b/pkgs/applications/audio/caudec/default.nix
index c953909586374..013cf9ef70756 100644
--- a/pkgs/applications/audio/caudec/default.nix
+++ b/pkgs/applications/audio/caudec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, bash, bc, findutils, flac, lame, opusTools, procps, sox }:
+{ lib, stdenv, fetchurl, makeWrapper, bash, bc, findutils, flac, lame, opusTools, procps, sox }:
 
 let
   version = "1.7.5";
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
     done
   '';
 
-   meta = with stdenv.lib; {
+   meta = with lib; {
     homepage = "http://caudec.net/";
     description = "A multiprocess audio converter that supports many formats (FLAC, MP3, Ogg Vorbis, Windows codecs and many more)";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/audio/cava/default.nix b/pkgs/applications/audio/cava/default.nix
index a92a5325f16d8..d024128c821a7 100644
--- a/pkgs/applications/audio/cava/default.nix
+++ b/pkgs/applications/audio/cava/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, alsaLib, fftw,
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, alsaLib, fftw,
   libpulseaudio, ncurses }:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
       --replace "/usr/share/consolefonts" "$out/share/consolefonts"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Console-based Audio Visualizer for Alsa";
     homepage = "https://github.com/karlstav/cava";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/cd-discid/default.nix b/pkgs/applications/audio/cd-discid/default.nix
index 2ceb5f6d09a2e..5dcb178dc79f7 100644
--- a/pkgs/applications/audio/cd-discid/default.nix
+++ b/pkgs/applications/audio/cd-discid/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv
+{ fetchurl, lib, stdenv
 , IOKit ? null }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   buildInputs = []
     ++ stdenv.lib.optional stdenv.isDarwin IOKit;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://linukz.org/cd-discid.shtml";
     license = licenses.gpl2Plus;
     maintainers = [ maintainers.rycee ];
diff --git a/pkgs/applications/audio/cdparanoia/default.nix b/pkgs/applications/audio/cdparanoia/default.nix
index 0658305723c4e..54d55d1c1b6f0 100644
--- a/pkgs/applications/audio/cdparanoia/default.nix
+++ b/pkgs/applications/audio/cdparanoia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, gnu-config, IOKit, Carbon }:
+{ lib, stdenv, fetchurl, autoreconfHook, gnu-config, IOKit, Carbon }:
 
 stdenv.mkDerivation rec {
   name = "cdparanoia-III-10.2";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     cp ${gnu-config}/config.guess configure.guess
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://xiph.org/paranoia";
     description = "A tool and library for reading digital audio from CDs";
     license = with licenses; [ gpl2Plus lgpl21Plus ];
diff --git a/pkgs/applications/audio/clementine/default.nix b/pkgs/applications/audio/clementine/default.nix
index 042d5b4b13a3e..500fb32935660 100644
--- a/pkgs/applications/audio/clementine/default.nix
+++ b/pkgs/applications/audio/clementine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, fetchpatch, boost, cmake, chromaprint, gettext, gst_all_1, liblastfm
+{ lib, stdenv, mkDerivation, fetchFromGitHub, fetchpatch, boost, cmake, chromaprint, gettext, gst_all_1, liblastfm
 , qtbase, qtx11extras
 , taglib, fftw, glew, qjson, sqlite, libgpod, libplist, usbmuxd, libmtp
 , libpulseaudio, gvfs, libcdio, libechonest, libspotify, pcre, projectm, protobuf
@@ -86,7 +86,7 @@ let
         --prefix GST_PLUGIN_SYSTEM_PATH_1_0 : "$GST_PLUGIN_SYSTEM_PATH_1_0"
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.clementine-player.org";
       description = "A multiplatform music player";
       license = licenses.gpl3Plus;
@@ -121,7 +121,7 @@ let
       done
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.clementine-player.org";
       description = "Spotify integration for Clementine";
       # The blob itself is Apache-licensed, although libspotify is unfree.
diff --git a/pkgs/applications/audio/clerk/default.nix b/pkgs/applications/audio/clerk/default.nix
index 912662b7726c6..03c693da15a54 100644
--- a/pkgs/applications/audio/clerk/default.nix
+++ b/pkgs/applications/audio/clerk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, rofi, mpc_cli, perl,
+{ lib, stdenv, fetchFromGitHub, makeWrapper, rofi, mpc_cli, perl,
 util-linux, pythonPackages, libnotify }:
 
 stdenv.mkDerivation {
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
       --prefix PATH : "${stdenv.lib.makeBinPath [ rofi mpc_cli perl util-linux libnotify ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An MPD client built on top of rofi";
     homepage    = "https://github.com/carnager/clerk";
     license     = licenses.mit;
diff --git a/pkgs/applications/audio/cmt/default.nix b/pkgs/applications/audio/cmt/default.nix
index 96cc3c5731988..bb23f9b62bbdd 100644
--- a/pkgs/applications/audio/cmt/default.nix
+++ b/pkgs/applications/audio/cmt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , ladspaH
 }:
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/lib/ladspa
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Computer Music Toolkit";
     homepage = "https://www.ladspa.org/cmt";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/cmus/default.nix b/pkgs/applications/audio/cmus/default.nix
index 3e5916ba0983e..2c8bf47cee97b 100644
--- a/pkgs/applications/audio/cmus/default.nix
+++ b/pkgs/applications/audio/cmus/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv, fetchFromGitHub, runCommand, ncurses, pkgconfig
+{ config, lib, stdenv, fetchFromGitHub, runCommand, ncurses, pkgconfig
 , libiconv, CoreAudio
 
 , alsaSupport ? stdenv.isLinux, alsaLib ? null
@@ -126,7 +126,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "LD=$(CC)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small, fast and powerful console music player for Linux and *BSD";
     homepage = "https://cmus.github.io/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/cmusfm/default.nix b/pkgs/applications/audio/cmusfm/default.nix
index 3e8360e1eaf61..c07b887192a33 100644
--- a/pkgs/applications/audio/cmusfm/default.nix
+++ b/pkgs/applications/audio/cmusfm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, curl, libnotify, gdk-pixbuf }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, curl, libnotify, gdk-pixbuf }:
 
 stdenv.mkDerivation {
   version = "2020-07-23";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ curl libnotify gdk-pixbuf ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Last.fm and Libre.fm standalone scrobbler for the cmus music player";
     longDescription = ''
       Features:
diff --git a/pkgs/applications/audio/cozy-audiobooks/default.nix b/pkgs/applications/audio/cozy-audiobooks/default.nix
index 1a78b783f53a0..a30d604e3465a 100644
--- a/pkgs/applications/audio/cozy-audiobooks/default.nix
+++ b/pkgs/applications/audio/cozy-audiobooks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , ninja
 , meson
 , pkgconfig
@@ -78,7 +78,7 @@ python3Packages.buildPythonApplication rec {
     ln -s $out/bin/com.github.geigi.cozy $out/bin/cozy
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern audio book player for Linux using GTK 3";
     homepage = "https://cozy.geigi.de/";
     maintainers = [ maintainers.makefu ];
diff --git a/pkgs/applications/audio/csa/default.nix b/pkgs/applications/audio/csa/default.nix
index 756c21892fb28..5121f6d616b29 100644
--- a/pkgs/applications/audio/csa/default.nix
+++ b/pkgs/applications/audio/csa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "csa";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   # so we remove one of them:
   postInstall = "rm $out/lib/ladspa/celllm_3890.*";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/csa/";
     description = "A group of LADSPA Audio plugins for FM broadcast and more";
     longDescription = ''
diff --git a/pkgs/applications/audio/csound/csound-qt/default.nix b/pkgs/applications/audio/csound/csound-qt/default.nix
index e6060c056ccb1..ba9df9039f6cf 100644
--- a/pkgs/applications/audio/csound/csound-qt/default.nix
+++ b/pkgs/applications/audio/csound/csound-qt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, csound, desktop-file-utils,
+{ lib, stdenv, csound, desktop-file-utils,
   fetchFromGitHub, python, python-qt, qmake,
   qtwebengine, qtxmlpatterns, rtmidi, fetchpatch }:
 
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
                  "SHARE_DIR=${placeholder "out"}/share"
                  ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CsoundQt is a frontend for Csound with editor, integrated help, widgets and other features";
     homepage = "https://csoundqt.github.io/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/csound/default.nix b/pkgs/applications/audio/csound/default.nix
index e7d264675e216..5a6a290af768d 100644
--- a/pkgs/applications/audio/csound/default.nix
+++ b/pkgs/applications/audio/csound/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libsndfile, libsamplerate, flex, bison, boost, gettext
+{ lib, stdenv, fetchFromGitHub, cmake, libsndfile, libsamplerate, flex, bison, boost, gettext
 , alsaLib ? null
 , libpulseaudio ? null
 , libjack2 ? null
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
       liblo ladspa-sdk fluidsynth eigen
       curl tcltk fltk ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sound design, audio synthesis, and signal processing system, providing facilities for music composition and performance on all major operating systems and platforms";
     homepage = "http://www.csounds.com/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/curseradio/default.nix b/pkgs/applications/audio/curseradio/default.nix
index 1dd5f9ee5eb24..82f3b130e6ea4 100644
--- a/pkgs/applications/audio/curseradio/default.nix
+++ b/pkgs/applications/audio/curseradio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll, python3Packages, mpv }:
+{ lib, stdenv, fetchFromGitHub, substituteAll, python3Packages, mpv }:
 
 python3Packages.buildPythonApplication rec {
   version = "0.2";
@@ -27,7 +27,7 @@ python3Packages.buildPythonApplication rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line radio player";
     homepage = "https://github.com/chronitis/curseradio";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/deadbeef/default.nix b/pkgs/applications/audio/deadbeef/default.nix
index 6b92d1263e339..0259f522d804f 100644
--- a/pkgs/applications/audio/deadbeef/default.nix
+++ b/pkgs/applications/audio/deadbeef/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv, fetchFromGitHub
+{ config, lib, stdenv, fetchFromGitHub
 , autoconf
 , automake
 , libtool
@@ -106,7 +106,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ultimate Music Player for GNU/Linux";
     homepage = "http://deadbeef.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/deadbeef/plugins/headerbar-gtk3.nix b/pkgs/applications/audio/deadbeef/plugins/headerbar-gtk3.nix
index 337d570a93535..819192fc1d4a8 100644
--- a/pkgs/applications/audio/deadbeef/plugins/headerbar-gtk3.nix
+++ b/pkgs/applications/audio/deadbeef/plugins/headerbar-gtk3.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig, libxml2, deadbeef, glib, gtk3 }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig, libxml2, deadbeef, glib, gtk3 }:
 
 stdenv.mkDerivation rec {
   pname = "deadbeef-headerbar-gtk3-plugin";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "./autogen.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plug-in that adds GTK 3 header bar to the DeaDBeeF music player";
     homepage = "https://github.com/saivert/ddb_misc_headerbar_GTK3";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/deadbeef/plugins/infobar.nix b/pkgs/applications/audio/deadbeef/plugins/infobar.nix
index 294d3a0ad8bf1..d5894e2fdbc3a 100644
--- a/pkgs/applications/audio/deadbeef/plugins/infobar.nix
+++ b/pkgs/applications/audio/deadbeef/plugins/infobar.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, deadbeef, gtk3, libxml2 }:
+{ lib, stdenv, fetchurl, pkgconfig, deadbeef, gtk3, libxml2 }:
 
 stdenv.mkDerivation rec {
   pname = "deadbeef-infobar-plugin";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true; # crashes DeaDBeeF and is abandoned (https://bitbucket.org/dsimbiriatin/deadbeef-infobar/issues/38/infobar-causes-deadbeef-180-to-crash)
     description = "DeaDBeeF Infobar Plugin";
     homepage = "https://bitbucket.org/dsimbiriatin/deadbeef-infobar";
diff --git a/pkgs/applications/audio/deadbeef/plugins/lyricbar.nix b/pkgs/applications/audio/deadbeef/plugins/lyricbar.nix
index 699f9d86f68da..ad388e23d9f99 100644
--- a/pkgs/applications/audio/deadbeef/plugins/lyricbar.nix
+++ b/pkgs/applications/audio/deadbeef/plugins/lyricbar.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, deadbeef, gtkmm3, libxmlxx3 }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, deadbeef, gtkmm3, libxmlxx3 }:
 
 stdenv.mkDerivation {
   pname = "deadbeef-lyricbar-plugin";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   buildFlags = [ "gtk3" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin for DeaDBeeF audio player that fetches and shows the song’s lyrics";
     homepage = "https://github.com/C0rn3j/deadbeef-lyricbar";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/deadbeef/plugins/mpris2.nix b/pkgs/applications/audio/deadbeef/plugins/mpris2.nix
index 95606a869b7f1..7bc0a4d1fa6fc 100644
--- a/pkgs/applications/audio/deadbeef/plugins/mpris2.nix
+++ b/pkgs/applications/audio/deadbeef/plugins/mpris2.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, deadbeef, glib }:
+{ lib, stdenv, fetchurl, pkgconfig, deadbeef, glib }:
 
 stdenv.mkDerivation rec {
   pname = "deadbeef-mpris2-plugin";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ deadbeef glib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MPRISv2 plugin for the DeaDBeeF music player";
     homepage = "https://github.com/Serranya/deadbeef-mpris2-plugin/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/denemo/default.nix b/pkgs/applications/audio/denemo/default.nix
index 313c7cbfd42f1..ea152b59a507c 100644
--- a/pkgs/applications/audio/denemo/default.nix
+++ b/pkgs/applications/audio/denemo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , libjack2, gettext, intltool, guile_2_0, lilypond
 , glib, libxml2, librsvg, libsndfile, aubio
 , gtk3, gtksourceview, evince, fluidsynth, rubberband
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     pkgconfig
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Music notation and composition software used with lilypond";
     homepage = "http://denemo.org";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/dfasma/default.nix b/pkgs/applications/audio/dfasma/default.nix
index 6df4679d1d5f6..20a1044fe24d1 100644
--- a/pkgs/applications/audio/dfasma/default.nix
+++ b/pkgs/applications/audio/dfasma/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, fftw, libsndfile, qtbase, qtmultimedia, qmake }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, fftw, libsndfile, qtbase, qtmultimedia, qmake }:
 
 let
 
@@ -9,7 +9,7 @@ let
       repo = "REAPER";
       owner = "gillesdegottex";
     };
-    meta = with stdenv.lib; {
+    meta = with lib; {
      license = licenses.asl20;
     };
   };
@@ -21,7 +21,7 @@ let
       repo = "libqaudioextra";
       owner = "gillesdegottex";
     };
-    meta = with stdenv.lib; {
+    meta = with lib; {
      license = licenses.gpl3Plus;
     };
   };
@@ -49,7 +49,7 @@ in mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Analyse and compare audio files in time and frequency";
     longDescription = ''
       DFasma is free open-source software to compare audio files by time and
diff --git a/pkgs/applications/audio/dirt/default.nix b/pkgs/applications/audio/dirt/default.nix
index 5e0cf3616fe53..333c1d08b3aa9 100644
--- a/pkgs/applications/audio/dirt/default.nix
+++ b/pkgs/applications/audio/dirt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libsndfile, libsamplerate, liblo, libjack2 }:
+{ lib, stdenv, fetchFromGitHub, libsndfile, libsamplerate, liblo, libjack2 }:
 
 stdenv.mkDerivation {
   name = "dirt-2018-01-01";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp -r samples $out/share/dirt/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An unimpressive thingie for playing bits of samples with some level of accuracy";
     homepage = "https://github.com/tidalcycles/Dirt";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/distrho/default.nix b/pkgs/applications/audio/distrho/default.nix
index e39cef3fb0e40..a217e4709548e 100644
--- a/pkgs/applications/audio/distrho/default.nix
+++ b/pkgs/applications/audio/distrho/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , alsaLib
 , fetchFromGitHub
 , freetype
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     libXrender
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://distrho.sourceforge.net/ports";
     description = "Linux audio plugins and LV2 ports";
     longDescription = ''
diff --git a/pkgs/applications/audio/dr14_tmeter/default.nix b/pkgs/applications/audio/dr14_tmeter/default.nix
index 272701b36804f..92e6eb2b3236b 100644
--- a/pkgs/applications/audio/dr14_tmeter/default.nix
+++ b/pkgs/applications/audio/dr14_tmeter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, pkgs }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, pkgs }:
 
 python3Packages.buildPythonApplication rec {
   pname = "dr14_tmeter";
@@ -20,7 +20,7 @@ python3Packages.buildPythonApplication rec {
   # There are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compute the DR14 of a given audio file according to the procedure described by the Pleasurize Music Foundation";
     license = licenses.gpl3Plus;
     homepage = "http://dr14tmeter.sourceforge.net/";
diff --git a/pkgs/applications/audio/dragonfly-reverb/default.nix b/pkgs/applications/audio/dragonfly-reverb/default.nix
index e5cbcd4a2e206..0ada1dfeaa6f4 100644
--- a/pkgs/applications/audio/dragonfly-reverb/default.nix
+++ b/pkgs/applications/audio/dragonfly-reverb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libjack2, libGL, pkgconfig, xorg }:
+{ lib, stdenv, fetchFromGitHub, libjack2, libGL, pkgconfig, xorg }:
 
 stdenv.mkDerivation rec {
   pname = "dragonfly-reverb";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/michaelwillis/dragonfly-reverb";
     description = "A hall-style reverb based on freeverb3 algorithms";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/drumgizmo/default.nix b/pkgs/applications/audio/drumgizmo/default.nix
index 9e24c4a1c295b..f69e101877bc3 100644
--- a/pkgs/applications/audio/drumgizmo/default.nix
+++ b/pkgs/applications/audio/drumgizmo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, alsaLib, expat, glib, libjack2, libXext, libX11, libpng
+{ lib, stdenv, fetchurl, fetchpatch, alsaLib, expat, glib, libjack2, libXext, libX11, libpng
 , libpthreadstubs, libsmf, libsndfile, lv2, pkgconfig, zita-resampler
 }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     libsmf libsndfile lv2 pkgconfig zita-resampler
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An LV2 sample based drum plugin";
     homepage = "https://www.drumgizmo.org";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/audio/dsf2flac/default.nix b/pkgs/applications/audio/dsf2flac/default.nix
index 031203dda756c..db07acf7c36c4 100644
--- a/pkgs/applications/audio/dsf2flac/default.nix
+++ b/pkgs/applications/audio/dsf2flac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, boost, flac, id3lib, pkg-config
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, boost, flac, id3lib, pkg-config
 , taglib, zlib }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--with-boost-libdir=${boost.out}/lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A DSD to FLAC transcoding tool";
     homepage = "https://github.com/hank/dsf2flac";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/easytag/default.nix b/pkgs/applications/audio/easytag/default.nix
index 3f294342da70f..5ea0871b62b0e 100644
--- a/pkgs/applications/audio/easytag/default.nix
+++ b/pkgs/applications/audio/easytag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, gtk3, glib, libid3tag, id3lib, taglib
+{ lib, stdenv, fetchurl, pkgconfig, intltool, gtk3, glib, libid3tag, id3lib, taglib
 , libvorbis, libogg, opusfile, flac, itstool, libxml2, gsettings-desktop-schemas
 , gnome3, wrapGAppsHook
 }:
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "View and edit tags for various audio files";
     homepage = "https://wiki.gnome.org/Apps/EasyTAG";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/ekho/default.nix b/pkgs/applications/audio/ekho/default.nix
index 0e2c950051a5a..86bf4faaa173d 100644
--- a/pkgs/applications/audio/ekho/default.nix
+++ b/pkgs/applications/audio/ekho/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , libsndfile, libpulseaudio
 }:
 
@@ -8,7 +8,7 @@ in stdenv.mkDerivation rec {
   pname = "ekho";
   inherit version;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chinese text-to-speech software";
     homepage    = "http://www.eguidedog.net/ekho.php";
     longDescription = ''
diff --git a/pkgs/applications/audio/ensemble-chorus/default.nix b/pkgs/applications/audio/ensemble-chorus/default.nix
index e2413a4fe87f1..65dac936a386b 100644
--- a/pkgs/applications/audio/ensemble-chorus/default.nix
+++ b/pkgs/applications/audio/ensemble-chorus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fltk, alsaLib, freetype, libXrandr, libXinerama, libXcursor, lv2, libjack2, cmake, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, fltk, alsaLib, freetype, libXrandr, libXinerama, libXcursor, lv2, libjack2, cmake, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "ensemble-chorus";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     fltk alsaLib freetype libXrandr libXinerama libXcursor lv2 libjack2
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jpcima/ensemble-chorus";
     description = "Digital model of electronic string ensemble chorus";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/espeak-ng/default.nix b/pkgs/applications/audio/espeak-ng/default.nix
index a284be4383250..720e1d4484a42 100644
--- a/pkgs/applications/audio/espeak-ng/default.nix
+++ b/pkgs/applications/audio/espeak-ng/default.nix
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     patchelf --set-rpath "$(patchelf --print-rpath $out/bin/espeak-ng)" $out/bin/speak-ng
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source speech synthesizer that supports over 70 languages, based on eSpeak";
     homepage = "https://github.com/espeak-ng/espeak-ng";
     changelog = "https://github.com/espeak-ng/espeak-ng/blob/${version}/CHANGELOG.md";
diff --git a/pkgs/applications/audio/espeak/default.nix b/pkgs/applications/audio/espeak/default.nix
index aa68fd5363d63..b155c1c41b60c 100644
--- a/pkgs/applications/audio/espeak/default.nix
+++ b/pkgs/applications/audio/espeak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, portaudio }:
+{ lib, stdenv, fetchurl, unzip, portaudio }:
 
 stdenv.mkDerivation rec {
   name = "espeak-1.48.04";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     makeFlags="PREFIX=$out DATADIR=$out/share/espeak-data"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compact open source software speech synthesizer";
     homepage = "http://espeak.sourceforge.net/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/espeak/edit.nix b/pkgs/applications/audio/espeak/edit.nix
index 6bcffcbc5c346..e027bb03cfcac 100644
--- a/pkgs/applications/audio/espeak/edit.nix
+++ b/pkgs/applications/audio/espeak/edit.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, unzip, portaudio, wxGTK, sox }:
+{ lib, stdenv, fetchurl, pkgconfig, unzip, portaudio, wxGTK, sox }:
 
 stdenv.mkDerivation rec {
   name = "espeakedit-1.48.03";
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     cp src/espeakedit "$out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Phoneme editor for espeak";
     homepage = "http://espeak.sourceforge.net/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/eteroj.lv2/default.nix b/pkgs/applications/audio/eteroj.lv2/default.nix
index 5ae3292379ea4..ee95ce43ff527 100644
--- a/pkgs/applications/audio/eteroj.lv2/default.nix
+++ b/pkgs/applications/audio/eteroj.lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, libuv, lv2 }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, libuv, lv2 }:
 
 stdenv.mkDerivation rec {
   pname = "eteroj.lv2";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libuv lv2 ];
   nativeBuildInputs = [ cmake pkg-config ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OSC injection/ejection from/to UDP/TCP/Serial for LV2";
     homepage = "https://open-music-kontrollers.ch/lv2/eteroj";
     license = licenses.artistic2;
diff --git a/pkgs/applications/audio/faust/faust1.nix b/pkgs/applications/audio/faust/faust1.nix
index 16956433655c9..efa97738d3c35 100644
--- a/pkgs/applications/audio/faust/faust1.nix
+++ b/pkgs/applications/audio/faust/faust1.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , coreutils
 , fetchurl
 , makeWrapper
@@ -16,7 +16,7 @@ let
     sha256 = "0d1fqwymyfb73zkmpwv4zk4gsg4ji7qs20mfsr20skmnqx30xvna";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://faust.grame.fr/";
     downloadPage = "https://sourceforge.net/projects/faudiostream/files/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/faust/faust2.nix b/pkgs/applications/audio/faust/faust2.nix
index 1c096374a42ba..4c0229e8f34e2 100644
--- a/pkgs/applications/audio/faust/faust2.nix
+++ b/pkgs/applications/audio/faust/faust2.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , coreutils
 , fetchFromGitHub
 , makeWrapper
@@ -30,7 +30,7 @@ let
     fetchSubmodules = true;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://faust.grame.fr/";
     downloadPage = "https://github.com/grame-cncm/faust/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/faust/faustlive.nix b/pkgs/applications/audio/faust/faustlive.nix
index 907ea3ed7caf1..852a4d68e6a62 100644
--- a/pkgs/applications/audio/faust/faustlive.nix
+++ b/pkgs/applications/audio/faust/faustlive.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , llvm, qt48Full, qrencode, libmicrohttpd_0_9_70, libjack2, alsaLib, faust, curl
 , bc, coreutils, which, libsndfile, pkg-config
 }:
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     install rsrc/FaustLive.desktop "$out/share/applications"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A standalone just-in-time Faust compiler";
     longDescription = ''
       FaustLive is a standalone just-in-time Faust compiler. It tries to bring
diff --git a/pkgs/applications/audio/fdkaac/default.nix b/pkgs/applications/audio/fdkaac/default.nix
index 8969f3a47b235..31b009c41333b 100644
--- a/pkgs/applications/audio/fdkaac/default.nix
+++ b/pkgs/applications/audio/fdkaac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoreconfHook, fetchFromGitHub, fdk_aac }:
+{ lib, stdenv, autoreconfHook, fetchFromGitHub, fdk_aac }:
 
 stdenv.mkDerivation rec {
   pname = "fdkaac";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line encoder frontend for libfdk-aac encder";
     longDescription = ''
       fdkaac reads linear PCM audio in either WAV, raw PCM, or CAF format,
diff --git a/pkgs/applications/audio/flac/default.nix b/pkgs/applications/audio/flac/default.nix
index bd8b9bea82b75..b4e4af9f51694 100644
--- a/pkgs/applications/audio/flac/default.nix
+++ b/pkgs/applications/audio/flac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libogg }:
+{ lib, stdenv, fetchurl, libogg }:
 
 stdenv.mkDerivation rec {
   name = "flac-1.3.3";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "bin" "dev" "out" "man" "doc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://xiph.org/flac/";
     description = "Library and tools for encoding and decoding the FLAC lossless audio file format";
     platforms = platforms.all;
diff --git a/pkgs/applications/audio/flac123/default.nix b/pkgs/applications/audio/flac123/default.nix
index 6f13b710effc6..09c7b44d92dd2 100644
--- a/pkgs/applications/audio/flac123/default.nix
+++ b/pkgs/applications/audio/flac123/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, flac, libao, libogg, popt }:
+{ lib, stdenv, fetchurl, autoreconfHook, flac, libao, libogg, popt }:
 
 stdenv.mkDerivation rec {
   pname = "flac123";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ flac libao libogg popt ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://flac-tools.sourceforge.net/";
     description = "A command-line program for playing FLAC audio files";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/flacon/default.nix b/pkgs/applications/audio/flacon/default.nix
index aaa0712c42fdd..b9750dd649ae0 100644
--- a/pkgs/applications/audio/flacon/default.nix
+++ b/pkgs/applications/audio/flacon/default.nix
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "$bin_path";
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Extracts audio tracks from an audio CD image to separate tracks";
     homepage = "https://flacon.github.io/";
diff --git a/pkgs/applications/audio/fomp/default.nix b/pkgs/applications/audio/fomp/default.nix
index a712eef06501f..006dbaf798033 100644
--- a/pkgs/applications/audio/fomp/default.nix
+++ b/pkgs/applications/audio/fomp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, lv2, pkgconfig, python2, wafHook }:
+{ lib, stdenv, fetchurl, lv2, pkgconfig, python2, wafHook }:
 
 stdenv.mkDerivation rec {
   pname = "fomp";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig wafHook ];
   buildInputs = [ lv2 python2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://drobilla.net/software/fomp/";
     description = "An LV2 port of the MCP, VCO, FIL, and WAH plugins by Fons Adriaensen";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/foo-yc20/default.nix b/pkgs/applications/audio/foo-yc20/default.nix
index 4ec69c62b1ae1..6f91f1e197740 100644
--- a/pkgs/applications/audio/foo-yc20/default.nix
+++ b/pkgs/applications/audio/foo-yc20/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub,  libjack2, gtk2, lv2, faust, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub,  libjack2, gtk2, lv2, faust, pkgconfig }:
 
 stdenv.mkDerivation {
   version = "git-2015-05-21";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
   # remove lv2 until https://github.com/sampov2/foo-yc20/issues/6 is resolved
   postInstallFixup = "rm -rf $out/lib/lv2";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true; # see: https://github.com/sampov2/foo-yc20/issues/7
     description = "A Faust implementation of a 1969 designed Yamaha combo organ, the YC-20";
     homepage = "https://github.com/sampov2/foo-yc20";
diff --git a/pkgs/applications/audio/freqtweak/default.nix b/pkgs/applications/audio/freqtweak/default.nix
index 046c8c8aac8a3..113894a9357d9 100644
--- a/pkgs/applications/audio/freqtweak/default.nix
+++ b/pkgs/applications/audio/freqtweak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, pkg-config, fftwFloat, libjack2, libsigcxx, libxml2, wxGTK }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, pkg-config, fftwFloat, libjack2, libsigcxx, libxml2, wxGTK }:
 
 stdenv.mkDerivation rec {
   pname = "freqtweak";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = http://essej.net/freqtweak/;
     description = "Realtime audio frequency spectral manipulation";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/ft2-clone/default.nix b/pkgs/applications/audio/ft2-clone/default.nix
index 68b3871f29fea..b231b4a69ed21 100644
--- a/pkgs/applications/audio/ft2-clone/default.nix
+++ b/pkgs/applications/audio/ft2-clone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , nixosTests
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     ft2-clone-starts = nixosTests.ft2-clone;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A highly accurate clone of the classic Fasttracker II software for MS-DOS";
     homepage = "https://16-bits.org/ft2.php";
     license = licenses.bsd3;
diff --git a/pkgs/applications/audio/fverb/default.nix b/pkgs/applications/audio/fverb/default.nix
index 289553795743d..2cd723b73bc9a 100644
--- a/pkgs/applications/audio/fverb/default.nix
+++ b/pkgs/applications/audio/fverb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 }:
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     patchShebangs ./dpf/utils/generate-ttl.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A stereo variant of the reverberator by Jon Dattorro, for lv2";
     homepage = "https://github.com/jpcima/fverb";
     license = licenses.bsd2;
diff --git a/pkgs/applications/audio/game-music-emu/default.nix b/pkgs/applications/audio/game-music-emu/default.nix
index fa93ca065deb1..a2aebc58a8250 100644
--- a/pkgs/applications/audio/game-music-emu/default.nix
+++ b/pkgs/applications/audio/game-music-emu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake }:
+{ lib, stdenv, fetchurl, cmake }:
 
 stdenv.mkDerivation rec {
   version = "0.6.3";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/mpyne/game-music-emu/wiki/Home";
     description = "A collection of video game music file emulators";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/applications/audio/gbsplay/default.nix b/pkgs/applications/audio/gbsplay/default.nix
index f89b8ed399b4e..7cee125f6e7db 100644
--- a/pkgs/applications/audio/gbsplay/default.nix
+++ b/pkgs/applications/audio/gbsplay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpulseaudio }:
+{ lib, stdenv, fetchFromGitHub, libpulseaudio }:
 
 stdenv.mkDerivation {
   name = "gbsplay-2016-12-17";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "tests=" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "gameboy sound player";
     license = licenses.gpl1;
     platforms = ["i686-linux" "x86_64-linux"];
diff --git a/pkgs/applications/audio/geonkick/default.nix b/pkgs/applications/audio/geonkick/default.nix
index 0e6f45194e551..6812cb4ef0fb7 100644
--- a/pkgs/applications/audio/geonkick/default.nix
+++ b/pkgs/applications/audio/geonkick/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, cmake, pkg-config, redkite, libsndfile, rapidjson
+{ lib, stdenv, fetchFromGitLab, cmake, pkg-config, redkite, libsndfile, rapidjson
 , libjack2, lv2, libX11, cairo }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     "-DCMAKE_INSTALL_LIBDIR=lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/iurie-sw/geonkick";
     description = "A free software percussion synthesizer";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/giada/default.nix b/pkgs/applications/audio/giada/default.nix
index 1408deba97d3d..c9b3216edef9d 100644
--- a/pkgs/applications/audio/giada/default.nix
+++ b/pkgs/applications/audio/giada/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , fltk
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
         src/core/{conf,init,midiMapConf,patch}.cpp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, minimal, hardcore audio tool for DJs, live performers and electronic musicians";
     homepage = "https://giadamusic.com/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/gigedit/default.nix b/pkgs/applications/audio/gigedit/default.nix
index 08eec3135081d..a97d1d3516f0b 100644
--- a/pkgs/applications/audio/gigedit/default.nix
+++ b/pkgs/applications/audio/gigedit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, intltool, libtool, pkgconfig, which
+{ lib, stdenv, fetchurl, autoconf, automake, intltool, libtool, pkgconfig, which
 , docbook_xml_dtd_45, docbook_xsl, gtkmm2, libgig, libsndfile, libxslt
 }:
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.linuxsampler.org";
     description = "Gigasampler file access library";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/gjay/default.nix b/pkgs/applications/audio/gjay/default.nix
index 9e016c68608bd..f2ba8ab3bfa96 100644
--- a/pkgs/applications/audio/gjay/default.nix
+++ b/pkgs/applications/audio/gjay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mpd_clientlib, dbus-glib, audacious, gtk2, gsl
+{ lib, stdenv, fetchurl, pkgconfig, mpd_clientlib, dbus-glib, audacious, gtk2, gsl
 , libaudclient }:
 
 stdenv.mkDerivation {
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generates playlists such that each song sounds good following the previous song";
     homepage = "http://gjay.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/gmpc/default.nix b/pkgs/applications/audio/gmpc/default.nix
index 7ae02ae38d852..d3d0d5fcd0a1f 100644
--- a/pkgs/applications/audio/gmpc/default.nix
+++ b/pkgs/applications/audio/gmpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libtool, intltool, pkgconfig, glib
+{ lib, stdenv, fetchurl, libtool, intltool, pkgconfig, glib
 , gtk2, curl, mpd_clientlib, libsoup, gob2, vala, libunique
 , libSM, libICE, sqlite, hicolor-icon-theme, wrapGAppsHook
 }:
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     libunique libmpd libSM libICE sqlite hicolor-icon-theme
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gmpclient.org";
     description = "A GTK2 frontend for Music Player Daemon";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/gnome-podcasts/default.nix b/pkgs/applications/audio/gnome-podcasts/default.nix
index da51f105075a4..8686150c08ada 100644
--- a/pkgs/applications/audio/gnome-podcasts/default.nix
+++ b/pkgs/applications/audio/gnome-podcasts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitLab
 , fetchpatch
@@ -72,7 +72,7 @@ rustPlatform.buildRustPackage rec {
     patchShebangs scripts/compile-gschema.py scripts/cargo.sh scripts/test.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Listen to your favorite podcasts";
     homepage = "https://wiki.gnome.org/Apps/Podcasts";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/google-musicmanager/default.nix b/pkgs/applications/audio/google-musicmanager/default.nix
index b4fe78dcbfcd7..a202b3ad28063 100644
--- a/pkgs/applications/audio/google-musicmanager/default.nix
+++ b/pkgs/applications/audio/google-musicmanager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , flac, expat, libidn, qtbase, qtwebkit, libvorbis }:
 assert stdenv.hostPlatform.system == "x86_64-linux";
 
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
       $out/opt/google/musicmanager/MusicManager
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Uploads music from your computer to Google Play";
     homepage    = "https://support.google.com/googleplay/answer/1229970";
     license     = licenses.unfree;
diff --git a/pkgs/applications/audio/gpodder/default.nix b/pkgs/applications/audio/gpodder/default.nix
index b153298d978bc..082630269595e 100644
--- a/pkgs/applications/audio/gpodder/default.nix
+++ b/pkgs/applications/audio/gpodder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, python3Packages, intltool
+{ lib, stdenv, fetchFromGitHub, python3, python3Packages, intltool
 , glibcLocales, gnome3, gtk3, wrapGAppsHook
 , gobject-introspection
 }:
@@ -67,7 +67,7 @@ python3Packages.buildPythonApplication rec {
     LC_ALL=C PYTHONPATH=./src:$PYTHONPATH python3 -m gpodder.unittests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A podcatcher written in python";
     longDescription = ''
       gPodder downloads and manages free audio and video content (podcasts)
diff --git a/pkgs/applications/audio/gradio/default.nix b/pkgs/applications/audio/gradio/default.nix
index 384235fc0650d..f9fda0fe7bd32 100644
--- a/pkgs/applications/audio/gradio/default.nix
+++ b/pkgs/applications/audio/gradio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig
+{ lib, stdenv, fetchFromGitHub, pkgconfig
 , python3
 , gsettings-desktop-schemas
 , desktop-file-utils
@@ -62,7 +62,7 @@ in stdenv.mkDerivation {
 
   patches = [ ./0001-Remove-post-install-script-that-hardcodes-paths.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/haecker-felix/gradio";
     description = "A GTK3 app for finding and listening to internet radio stations";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/greg/default.nix b/pkgs/applications/audio/greg/default.nix
index c243a81ac2ebe..46e1baed07d33 100644
--- a/pkgs/applications/audio/greg/default.nix
+++ b/pkgs/applications/audio/greg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 with pythonPackages; buildPythonApplication rec {
   pname = "greg";
@@ -15,7 +15,7 @@ with pythonPackages; buildPythonApplication rec {
 
   propagatedBuildInputs = [ setuptools feedparser ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/manolomartinez/greg";
     description = "A command-line podcast aggregator";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/gtkpod/default.nix b/pkgs/applications/audio/gtkpod/default.nix
index 1f293fe2d7960..c504f19de3934 100644
--- a/pkgs/applications/audio/gtkpod/default.nix
+++ b/pkgs/applications/audio/gtkpod/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, wrapGAppsHook, intltool, libgpod, curl, flac,
+{ lib, stdenv, fetchurl, pkgconfig, wrapGAppsHook, intltool, libgpod, curl, flac,
   gnome3, gtk3, gettext, perlPackages, flex, libid3tag, gdl,
   libvorbis, gdk-pixbuf }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK Manager for an Apple ipod";
     homepage = "http://gtkpod.sourceforge.net";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/guitarix/default.nix b/pkgs/applications/audio/guitarix/default.nix
index d74f1c8728f5d..41c7db959e0ba 100644
--- a/pkgs/applications/audio/guitarix/default.nix
+++ b/pkgs/applications/audio/guitarix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , avahi
 , bluez
@@ -100,7 +100,7 @@ stdenv.mkDerivation rec {
     "--install-roboto-font"
   ] ++ optional optimizationSupport "--optimization";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A virtual guitar amplifier for Linux running with JACK";
     longDescription = ''
         guitarix is a virtual guitar amplifier for Linux running with
diff --git a/pkgs/applications/audio/gwc/default.nix b/pkgs/applications/audio/gwc/default.nix
index d9631ac45e6b0..d6e7c0807a378 100644
--- a/pkgs/applications/audio/gwc/default.nix
+++ b/pkgs/applications/audio/gwc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkg-config
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = false; # Fails to generate machine.h in time.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI application for removing noise (hiss, pops and clicks) from audio files";
     homepage = "https://github.com/AlisterH/gwc/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/gxmatcheq-lv2/default.nix b/pkgs/applications/audio/gxmatcheq-lv2/default.nix
index b2d99e0eba866..42e5cd726c735 100644
--- a/pkgs/applications/audio/gxmatcheq-lv2/default.nix
+++ b/pkgs/applications/audio/gxmatcheq-lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, xorgproto, cairo, lv2, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, xorg, xorgproto, cairo, lv2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "GxMatchEQ.lv2";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "INSTALL_DIR=$(out)/lib/lv2" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brummer10/GxMatchEQ.lv2";
     description = "Matching Equalizer to apply EQ curve from one source to another source";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/gxplugins-lv2/default.nix b/pkgs/applications/audio/gxplugins-lv2/default.nix
index fa80611fc2806..9201ff730d902 100644
--- a/pkgs/applications/audio/gxplugins-lv2/default.nix
+++ b/pkgs/applications/audio/gxplugins-lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, xorgproto, cairo, lv2, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, xorg, xorgproto, cairo, lv2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "GxPlugins.lv2";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brummer10/GxPlugins.lv2";
     description = "A set of extra lv2 plugins from the guitarix project";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/helio-workstation/default.nix b/pkgs/applications/audio/helio-workstation/default.nix
index a4f586712831a..980b312ba6c44 100644
--- a/pkgs/applications/audio/helio-workstation/default.nix
+++ b/pkgs/applications/audio/helio-workstation/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , alsaLib, freetype, xorg, curl, libGL, libjack2, gnome3
 , pkgconfig, makeWrapper
 }:
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
       --replace "/usr/bin/helio" "$out/bin/Helio"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "One music sequencer for all major platforms, both desktop and mobile";
     homepage = "https://helio.fm/";
     license = licenses.gpl3Only;
diff --git a/pkgs/applications/audio/helm/default.nix b/pkgs/applications/audio/helm/default.nix
index 145ba68b08b1c..d20bbb8e573d7 100644
--- a/pkgs/applications/audio/helm/default.nix
+++ b/pkgs/applications/audio/helm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , xorg
@@ -52,7 +52,7 @@
    make DESTDIR="$out" install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://tytel.org/helm";
     description = "A free, cross-platform, polyphonic synthesizer";
     longDescription = ''
diff --git a/pkgs/applications/audio/hybridreverb2/default.nix b/pkgs/applications/audio/hybridreverb2/default.nix
index 831df6ba3c8d6..a8bb81de717b0 100644
--- a/pkgs/applications/audio/hybridreverb2/default.nix
+++ b/pkgs/applications/audio/hybridreverb2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchzip, cmake, pkgconfig, lv2, alsaLib, libjack2,
+{ lib, stdenv, fetchFromGitHub, fetchzip, cmake, pkgconfig, lv2, alsaLib, libjack2,
   freetype, libX11, gtk3, pcre, libpthreadstubs, libXdmcp, libxkbcommon,
   epoxy, at-spi2-core, dbus, curl, fftwFloat }:
 
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     cp  -r ${impulseDB}/* $out/share/${pname}/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www2.ika.ruhr-uni-bochum.de/HybridReverb2";
     description = "Reverb effect using hybrid impulse convolution";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/hydrogen/0.nix b/pkgs/applications/audio/hydrogen/0.nix
index b3aff4e4c5091..774b2a9344716 100644
--- a/pkgs/applications/audio/hydrogen/0.nix
+++ b/pkgs/applications/audio/hydrogen/0.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, cmake
+{ lib, stdenv, fetchurl, pkgconfig, cmake
 , alsaLib, boost, glib, lash, libjack2, libarchive, libsndfile, lrdf, qt4
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     alsaLib boost glib lash libjack2 libarchive libsndfile lrdf qt4
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced drum machine";
     homepage = "http://www.hydrogen-music.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/hydrogen/default.nix b/pkgs/applications/audio/hydrogen/default.nix
index c6d307e2c163d..728f0e90a9907 100644
--- a/pkgs/applications/audio/hydrogen/default.nix
+++ b/pkgs/applications/audio/hydrogen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, wrapQtAppsHook
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, wrapQtAppsHook
 , alsaLib, ladspa-sdk, lash, libarchive, libjack2, liblo, libpulseaudio, libsndfile, lrdf
 , qtbase, qttools, qtxmlpatterns
 }:
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     "-DWANT_DEBUG=OFF"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced drum machine";
     homepage = "http://www.hydrogen-music.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/id3v2/default.nix b/pkgs/applications/audio/id3v2/default.nix
index 75d999ede1d7a..f6c88bc456e96 100644
--- a/pkgs/applications/audio/id3v2/default.nix
+++ b/pkgs/applications/audio/id3v2/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, id3lib, groff, zlib}:
+{lib, stdenv, fetchurl, id3lib, groff, zlib}:
 
 stdenv.mkDerivation rec {
   pname = "id3v2";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/{bin,share/man/man1}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line editor for id3v2 tags";
     homepage = "http://id3v2.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/infamousPlugins/default.nix b/pkgs/applications/audio/infamousPlugins/default.nix
index 9ba835eb7eae8..ce3121e2f9580 100644
--- a/pkgs/applications/audio/infamousPlugins/default.nix
+++ b/pkgs/applications/audio/infamousPlugins/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig, cairomm, cmake, lv2, libpthreadstubs, libXdmcp, libXft, ntk, pcre, fftwFloat, zita-resampler }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, pkgconfig, cairomm, cmake, lv2, libpthreadstubs, libXdmcp, libXft, ntk, pcre, fftwFloat, zita-resampler }:
 
 stdenv.mkDerivation rec {
   pname = "infamousPlugins";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig cmake ];
   buildInputs = [ cairomm lv2 libpthreadstubs libXdmcp libXft ntk pcre fftwFloat zita-resampler ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ssj71.github.io/infamousPlugins";
     description = "A collection of open-source LV2 plugins";
     longDescription = ''
diff --git a/pkgs/applications/audio/ingen/default.nix b/pkgs/applications/audio/ingen/default.nix
index c5d4b3f87f491..9bb6ddd6a9850 100644
--- a/pkgs/applications/audio/ingen/default.nix
+++ b/pkgs/applications/audio/ingen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, boost, ganv, glibmm, gtkmm2, libjack2, lilv
+{ lib, stdenv, fetchgit, boost, ganv, glibmm, gtkmm2, libjack2, lilv
 , lv2, makeWrapper, pkgconfig, python, raul, rdflib, serd, sord, sratom
 , wafHook
 , suil
@@ -36,7 +36,7 @@ stdenv.mkDerivation  rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modular audio processing system using JACK and LV2 or LADSPA plugins";
     homepage = "http://drobilla.net/software/ingen";
     license = licenses.agpl3Plus;
diff --git a/pkgs/applications/audio/ir.lv2/default.nix b/pkgs/applications/audio/ir.lv2/default.nix
index aa5eeae0a46c7..bc3049dc6b342 100644
--- a/pkgs/applications/audio/ir.lv2/default.nix
+++ b/pkgs/applications/audio/ir.lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fftw, gtk2, lv2, libsamplerate, libsndfile, pkgconfig, zita-convolver }:
+{ lib, stdenv, fetchFromGitHub, fftw, gtk2, lv2, libsamplerate, libsndfile, pkgconfig, zita-convolver }:
 
 stdenv.mkDerivation rec {
   pname = "ir.lv2";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     install -Dm755 convert4chan "$out/bin/convert4chan"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://factorial.hu/plugins/lv2/ir";
     description = "Zero-latency, realtime, high performance signal convolver especially for creating reverb effects";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/jaaa/default.nix b/pkgs/applications/audio/jaaa/default.nix
index 80f15935af23f..035e15abb23f2 100644
--- a/pkgs/applications/audio/jaaa/default.nix
+++ b/pkgs/applications/audio/jaaa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, libclthreads, libclxclient, libX11, libXft, libXrender, fftwFloat, libjack2, zita-alsa-pcmi }:
+{ lib, stdenv, fetchurl, alsaLib, libclthreads, libclxclient, libX11, libXft, libXrender, fftwFloat, libjack2, zita-alsa-pcmi }:
 
 stdenv.mkDerivation rec {
   pname = "jaaa";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cd ./source/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://kokkinizita.linuxaudio.org/linuxaudio/index.html";
     description = "JACK and ALSA Audio Analyser";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/jack-capture/default.nix b/pkgs/applications/audio/jack-capture/default.nix
index e443a0a52694a..0cf21c6a8c8f7 100644
--- a/pkgs/applications/audio/jack-capture/default.nix
+++ b/pkgs/applications/audio/jack-capture/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libjack2, libsndfile, pkgconfig }:
+{ lib, stdenv, fetchurl, libjack2, libsndfile, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "jack_capture";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program for recording soundfiles with jack";
     homepage = "http://archive.notam02.no/arkiv/src";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/jack-oscrolloscope/default.nix b/pkgs/applications/audio/jack-oscrolloscope/default.nix
index 18915329ca9f1..ffd9ec5cbc359 100644
--- a/pkgs/applications/audio/jack-oscrolloscope/default.nix
+++ b/pkgs/applications/audio/jack-oscrolloscope/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL, libjack2, libGLU, libGL, pkgconfig }:
+{ lib, stdenv, fetchurl, SDL, libjack2, libGLU, libGL, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "jack_oscrolloscope";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     mv jack_oscrolloscope $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple waveform viewer for JACK";
     homepage = "http://das.nasophon.de/jack_oscrolloscope";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/jalv/default.nix b/pkgs/applications/audio/jalv/default.nix
index 39f1467138db5..d3ed57436c959 100644
--- a/pkgs/applications/audio/jalv/default.nix
+++ b/pkgs/applications/audio/jalv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk2, libjack2, lilv, lv2, pkgconfig, python
+{ lib, stdenv, fetchurl, gtk2, libjack2, lilv, lv2, pkgconfig, python
 , serd, sord , sratom, suil, wafHook }:
 
 stdenv.mkDerivation  rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation  rec {
     gtk2 libjack2 lilv lv2 python serd sord sratom suil
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple but fully featured LV2 host for Jack";
     homepage = "http://drobilla.net/software/jalv";
     license = licenses.isc;
diff --git a/pkgs/applications/audio/jamin/default.nix b/pkgs/applications/audio/jamin/default.nix
index 57caf4672d382..7f6501a473d85 100644
--- a/pkgs/applications/audio/jamin/default.nix
+++ b/pkgs/applications/audio/jamin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fftwFloat, gtk2, ladspaPlugins, libjack2, liblo, libxml2
+{ lib, stdenv, fetchurl, fftwFloat, gtk2, ladspaPlugins, libjack2, liblo, libxml2
 , makeWrapper, pkgconfig, perlPackages
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/jamin --set LADSPA_PATH ${ladspaPlugins}/lib/ladspa
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://jamin.sourceforge.net";
     description = "JACK Audio Mastering interface";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/kapitonov-plugins-pack/default.nix b/pkgs/applications/audio/kapitonov-plugins-pack/default.nix
index 53b55332f5d9a..4409437ebf206 100644
--- a/pkgs/applications/audio/kapitonov-plugins-pack/default.nix
+++ b/pkgs/applications/audio/kapitonov-plugins-pack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, faust, meson, ninja, pkg-config
+{ lib, stdenv, fetchFromGitHub, faust, meson, ninja, pkg-config
 , boost, cairo, fftw, gnome3, ladspa-sdk, libxcb, lv2, xcbutilwm
 , zita-convolver, zita-resampler
  }:
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     zita-resampler
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of LADSPA and LV2 plugins for guitar sound processing";
     homepage = https://github.com/olegkapitonov/Kapitonov-Plugins-Pack;
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/keyfinder-cli/default.nix b/pkgs/applications/audio/keyfinder-cli/default.nix
index 4bb1d63a1e715..d6e96d9083444 100644
--- a/pkgs/applications/audio/keyfinder-cli/default.nix
+++ b/pkgs/applications/audio/keyfinder-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libav, libkeyfinder }:
+{ lib, stdenv, fetchFromGitHub, libav, libkeyfinder }:
 
 stdenv.mkDerivation rec {
   pname = "keyfinder-cli";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Musical key detection for digital audio (command-line tool)";
     longDescription = ''
diff --git a/pkgs/applications/audio/keyfinder/default.nix b/pkgs/applications/audio/keyfinder/default.nix
index 710c1e8079297..187d3a58b171a 100644
--- a/pkgs/applications/audio/keyfinder/default.nix
+++ b/pkgs/applications/audio/keyfinder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libav_0_8, libkeyfinder, qtbase, qtxmlpatterns, qmake, taglib }:
+{ lib, stdenv, fetchFromGitHub, libav_0_8, libkeyfinder, qtbase, qtxmlpatterns, qmake, taglib }:
 
 stdenv.mkDerivation rec {
   pname = "keyfinder";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Musical key detection for digital audio (graphical UI)";
     longDescription = ''
       KeyFinder is an open source key detection tool, for DJs interested in
diff --git a/pkgs/applications/audio/kid3/default.nix b/pkgs/applications/audio/kid3/default.nix
index 84894aeee5c4f..340a661a95026 100644
--- a/pkgs/applications/audio/kid3/default.nix
+++ b/pkgs/applications/audio/kid3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , pkg-config, cmake, python3, ffmpeg_3, phonon, automoc4
 , chromaprint, docbook_xml_dtd_45, docbook_xsl, libxslt
 , id3lib, taglib, mp4v2, flac, libogg, libvorbis
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     export DOCBOOKDIR="${docbook_xsl}/xml/xsl/docbook/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple and powerful audio tag editor";
     longDescription = ''
       If you want to easily tag multiple MP3, Ogg/Vorbis, FLAC, MPC, MP4/AAC,
diff --git a/pkgs/applications/audio/klystrack/default.nix b/pkgs/applications/audio/klystrack/default.nix
index 5e8dc060c28c9..ea8cfcec2e430 100644
--- a/pkgs/applications/audio/klystrack/default.nix
+++ b/pkgs/applications/audio/klystrack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , SDL2, SDL2_image
 , pkgconfig
 }:
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
       --replace "klystrack %f" "$out/bin/klystrack %f"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A chiptune tracker";
     homepage = "https://kometbomb.github.io/klystrack";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/kmetronome/default.nix b/pkgs/applications/audio/kmetronome/default.nix
index 30a4d5f3684a4..415bfe370269e 100644
--- a/pkgs/applications/audio/kmetronome/default.nix
+++ b/pkgs/applications/audio/kmetronome/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkgconfig, qttools, alsaLib, drumstick, qtbase, qtsvg }:
+{ lib, stdenv, fetchurl, cmake, pkgconfig, qttools, alsaLib, drumstick, qtbase, qtsvg }:
 
 stdenv.mkDerivation rec {
   pname = "kmetronome";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ alsaLib drumstick qtbase qtsvg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kmetronome.sourceforge.io/";
     description = "ALSA MIDI metronome with Qt interface";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/ladspa-plugins/default.nix b/pkgs/applications/audio/ladspa-plugins/default.nix
index a0fc8631fb391..855056c6c1566 100644
--- a/pkgs/applications/audio/ladspa-plugins/default.nix
+++ b/pkgs/applications/audio/ladspa-plugins/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, automake, fftw, ladspaH, libxml2, pkgconfig
+{ lib, stdenv, fetchurl, autoreconfHook, automake, fftw, ladspaH, libxml2, pkgconfig
 , perlPackages }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp ${automake}/share/automake-*/mkinstalldirs .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://plugin.org.uk/";
     description = "LADSPA format audio plugins";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/lash/default.nix b/pkgs/applications/audio/lash/default.nix
index cb0a3ee05e122..26a8568f01aad 100644
--- a/pkgs/applications/audio/lash/default.nix
+++ b/pkgs/applications/audio/lash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, gtk2, libjack2, libuuid, libxml2
+{ lib, stdenv, fetchurl, alsaLib, gtk2, libjack2, libuuid, libxml2
 , makeWrapper, pkgconfig, readline }:
 
 assert libuuid != null;
@@ -26,7 +26,7 @@ stdenv.mkDerivation  rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Linux Audio Session Handler";
     longDescription = ''
       Session management system for GNU/Linux audio applications.
diff --git a/pkgs/applications/audio/librespot/default.nix b/pkgs/applications/audio/librespot/default.nix
index 6061edac02501..241a89caa0b5d 100644
--- a/pkgs/applications/audio/librespot/default.nix
+++ b/pkgs/applications/audio/librespot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, withRodio ? true
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, withRodio ? true
 , withALSA ? true, alsaLib ? null, withPulseAudio ? false, libpulseaudio ? null
 , withPortAudio ? false, portaudio ? null }:
 
@@ -37,7 +37,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open Source Spotify client library and playback daemon";
     homepage = "https://github.com/librespot-org/librespot";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/audio/linuxsampler/default.nix b/pkgs/applications/audio/linuxsampler/default.nix
index 6b6cfd55926b6..5eda9e92123cf 100644
--- a/pkgs/applications/audio/linuxsampler/default.nix
+++ b/pkgs/applications/audio/linuxsampler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, bison, libtool, pkgconfig, which
+{ lib, stdenv, fetchurl, autoconf, automake, bison, libtool, pkgconfig, which
 , alsaLib, asio, libjack2, libgig, libsndfile, lv2 }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.linuxsampler.org";
     description = "Sampler backend";
     longDescription = ''
diff --git a/pkgs/applications/audio/littlegptracker/default.nix b/pkgs/applications/audio/littlegptracker/default.nix
index 2fb453cf19c5b..9772425535f3d 100644
--- a/pkgs/applications/audio/littlegptracker/default.nix
+++ b/pkgs/applications/audio/littlegptracker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , unstableGitUpdater
 , SDL
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
 
   passthru.updateScript = unstableGitUpdater { };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A music tracker similar to lsdj optimised to run on portable game consoles";
     longDescription = ''
       LittleGPTracker (a.k.a 'The piggy', 'lgpt') is a music tracker optimised
diff --git a/pkgs/applications/audio/lmms/default.nix b/pkgs/applications/audio/lmms/default.nix
index 8513c1aae7887..ef95bf5949444 100644
--- a/pkgs/applications/audio/lmms/default.nix
+++ b/pkgs/applications/audio/lmms/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, alsaLib ? null, fftwFloat, fltk13
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, alsaLib ? null, fftwFloat, fltk13
 , fluidsynth_1 ? null, lame ? null, libgig ? null, libjack2 ? null, libpulseaudio ? null
 , libsamplerate, libsoundio ? null, libsndfile, libvorbis ? null, portaudio ? null
 , qtbase, qtx11extras, qttools, SDL ? null, mkDerivation }:
@@ -38,7 +38,7 @@ mkDerivation rec {
 
   cmakeFlags = [ "-DWANT_QT5=ON" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DAW similar to FL Studio (music production software)";
     homepage = "https://lmms.io";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/ltc-tools/default.nix b/pkgs/applications/audio/ltc-tools/default.nix
index c986e3af288e1..31986762fc1fd 100644
--- a/pkgs/applications/audio/ltc-tools/default.nix
+++ b/pkgs/applications/audio/ltc-tools/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, pkgconfig, libltc, libsndfile, jack2}:
+{lib, stdenv, fetchFromGitHub, pkgconfig, libltc, libsndfile, jack2}:
 
 stdenv.mkDerivation rec {
   pname = "ltc-tools";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/x42/ltc-tools";
     description = "Tools to deal with linear-timecode (LTC)";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/luppp/default.nix b/pkgs/applications/audio/luppp/default.nix
index 6cf2575b8e5fd..ac7ff3a3084d8 100644
--- a/pkgs/applications/audio/luppp/default.nix
+++ b/pkgs/applications/audio/luppp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     ntk
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://openavproductions.com/luppp/";  # https does not work
     description = "A music creation tool, intended for live use";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/lv2-cpp-tools/default.nix b/pkgs/applications/audio/lv2-cpp-tools/default.nix
index d98135fb0149f..b6e878d483673 100644
--- a/pkgs/applications/audio/lv2-cpp-tools/default.nix
+++ b/pkgs/applications/audio/lv2-cpp-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, pkgconfig, lv2, gtkmm2, boost }:
+{ lib, stdenv, fetchzip, pkgconfig, lv2, gtkmm2, boost }:
 
 stdenv.mkDerivation rec {
   pname = "lv2-cpp-tools";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ lv2 gtkmm2 boost ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ll-plugins.nongnu.org/hacking.html";
     description = "Tools and libraries that may come in handy when writing LV2 plugins in C++";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/lv2bm/default.nix b/pkgs/applications/audio/lv2bm/default.nix
index 99a2665bc1291..8f997a28193b9 100644
--- a/pkgs/applications/audio/lv2bm/default.nix
+++ b/pkgs/applications/audio/lv2bm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib, libsndfile, lilv, lv2, pkgconfig, serd, sord, sratom }:
+{ lib, stdenv, fetchFromGitHub, glib, libsndfile, lilv, lv2, pkgconfig, serd, sord, sratom }:
 
 stdenv.mkDerivation rec {
   pname = "lv2bm";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     make install PREFIX=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/portalmod/lv2bm";
     description = "A benchmark tool for LV2 plugins";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/mamba/default.nix b/pkgs/applications/audio/mamba/default.nix
index dc8620fdd4e15..022b41007c145 100644
--- a/pkgs/applications/audio/mamba/default.nix
+++ b/pkgs/applications/audio/mamba/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , cairo
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brummer10/Mamba";
     description = "Virtual MIDI keyboard for Jack Audio Connection Kit";
     license = licenses.bsd0;
diff --git a/pkgs/applications/audio/mda-lv2/default.nix b/pkgs/applications/audio/mda-lv2/default.nix
index 6e96bf45294ea..b53ea7a79636f 100644
--- a/pkgs/applications/audio/mda-lv2/default.nix
+++ b/pkgs/applications/audio/mda-lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fftwSinglePrec, lv2, pkgconfig, wafHook, python3 }:
+{ lib, stdenv, fetchurl, fftwSinglePrec, lv2, pkgconfig, wafHook, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "mda-lv2";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig wafHook python3 ];
   buildInputs = [ fftwSinglePrec lv2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://drobilla.net/software/mda-lv2/";
     description = "An LV2 port of the MDA plugins by Paul Kellett";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/melmatcheq.lv2/default.nix b/pkgs/applications/audio/melmatcheq.lv2/default.nix
index d5aa481e8233d..55c6e4c185a40 100644
--- a/pkgs/applications/audio/melmatcheq.lv2/default.nix
+++ b/pkgs/applications/audio/melmatcheq.lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, xorgproto, cairo, lv2, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, xorg, xorgproto, cairo, lv2, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "MelMatchEQ.lv2";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "INSTALL_DIR=$(out)/lib/lv2" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brummer10/MelMatchEQ.lv2";
     description = "a profiling EQ using a 26 step Mel Frequency Band";
     maintainers = with maintainers; [ magnetophon ];
diff --git a/pkgs/applications/audio/meterbridge/default.nix b/pkgs/applications/audio/meterbridge/default.nix
index 9d807358cd5a9..fbf23fbbd58a0 100644
--- a/pkgs/applications/audio/meterbridge/default.nix
+++ b/pkgs/applications/audio/meterbridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, SDL, SDL_image, libjack2
+{ lib, stdenv, fetchurl, pkgconfig, SDL, SDL_image, libjack2
 }:
 
 stdenv.mkDerivation rec {
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     [ pkgconfig SDL SDL_image libjack2
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Various meters (VU, PPM, DPM, JF, SCO) for Jack Audio Connection Kit";
     homepage = "http://plugin.org.uk/meterbridge/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/mhwaveedit/default.nix b/pkgs/applications/audio/mhwaveedit/default.nix
index 67204260da247..c87a050ed33b8 100644
--- a/pkgs/applications/audio/mhwaveedit/default.nix
+++ b/pkgs/applications/audio/mhwaveedit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, SDL, alsaLib, autoreconfHook, gtk2, libjack2, ladspaH
+{ lib, stdenv, fetchFromGitHub, makeWrapper, SDL, alsaLib, autoreconfHook, gtk2, libjack2, ladspaH
 , ladspaPlugins, libsamplerate, libsndfile, pkgconfig, libpulseaudio, lame
 , vorbis-tools }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${vorbis-tools}/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical program for editing, playing and recording sound files";
     homepage = "https://github.com/magnush/mhwaveedit";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/mid2key/default.nix b/pkgs/applications/audio/mid2key/default.nix
index 071b18e5a8a63..2e72a011921c0 100644
--- a/pkgs/applications/audio/mid2key/default.nix
+++ b/pkgs/applications/audio/mid2key/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, libX11, libXi, libXtst, xorgproto }:
+{ lib, stdenv, fetchurl, alsaLib, libX11, libXi, libXtst, xorgproto }:
 
 stdenv.mkDerivation rec {
   name = "mid2key-r1";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "mkdir -p $out/bin && mv mid2key $out/bin";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://code.google.com/p/mid2key/";
     description = "A simple tool which maps midi notes to simulated keystrokes";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/midas/generic.nix b/pkgs/applications/audio/midas/generic.nix
index 769593919d46c..8f2e29ee95b4e 100644
--- a/pkgs/applications/audio/midas/generic.nix
+++ b/pkgs/applications/audio/midas/generic.nix
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
       $out/bin/${baseName}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit homepage;
     description = "Editor for the ${brand} ${type} digital mixer";
     license = licenses.unfree;
diff --git a/pkgs/applications/audio/midi-visualizer/default.nix b/pkgs/applications/audio/midi-visualizer/default.nix
index 4def69bedced3..58f8fee3cefc5 100644
--- a/pkgs/applications/audio/midi-visualizer/default.nix
+++ b/pkgs/applications/audio/midi-visualizer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, libX11, glfw, makeWrapper,
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, libX11, glfw, makeWrapper,
   libXrandr, libXinerama, libXcursor, gtk3, ffmpeg-full, ...}:
 
 stdenv.mkDerivation rec {
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
       --prefix XDG_DATA_DIRS : "${gtk3}/share/gsettings-schemas/${gtk3.name}:$XDG_DATA_DIRS"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small MIDI visualizer tool, using OpenGL";
     homepage = "https://github.com/kosua20/MIDIVisualizer";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/midisheetmusic/default.nix b/pkgs/applications/audio/midisheetmusic/default.nix
index 388fc2a1b3ea1..1f408f6f62810 100644
--- a/pkgs/applications/audio/midisheetmusic/default.nix
+++ b/pkgs/applications/audio/midisheetmusic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , mono, dotnetPackages, makeWrapper
 , gtk2, cups, timidity }:
 
@@ -52,7 +52,7 @@ in stdenv.mkDerivation {
       --add-flags $out/bin/.MidiSheetMusic.exe
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert MIDI Files to Piano Sheet Music for two hands";
     homepage = "http://midisheetmusic.com";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/milkytracker/default.nix b/pkgs/applications/audio/milkytracker/default.nix
index 5a76e55d667fd..b061b48abc84d 100644
--- a/pkgs/applications/audio/milkytracker/default.nix
+++ b/pkgs/applications/audio/milkytracker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, makeWrapper
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, makeWrapper
 , SDL2, alsaLib, libjack2, lhasa, perl, rtmidi, zlib, zziplib }:
 
 stdenv.mkDerivation rec {
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     install -Dm644 $src/resources/milkytracker.appdata $out/share/appdata/milkytracker.appdata.xml
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Music tracker application, similar to Fasttracker II";
     homepage = "http://milkytracker.org";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/mixxx/default.nix b/pkgs/applications/audio/mixxx/default.nix
index 576dd4d97b35c..ef0db55f090f8 100644
--- a/pkgs/applications/audio/mixxx/default.nix
+++ b/pkgs/applications/audio/mixxx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, fetchFromGitHub, chromaprint
+{ lib, stdenv, mkDerivation, fetchurl, fetchFromGitHub, chromaprint
 , fftw, flac, faad2, glibcLocales, mp4v2
 , libid3tag, libmad, libopus, libshout, libsndfile, libusb1, libvorbis
 , libGLU, libxcb, lilv, lv2, opusfile
@@ -48,7 +48,7 @@ mkDerivation rec {
     "--set LOCALE_ARCHIVE ${glibcLocales}/lib/locale/locale-archive"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mixxx.org";
     description = "Digital DJ mixing software";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/moc/default.nix b/pkgs/applications/audio/moc/default.nix
index 9f68f8bb8e8e6..96a4ab9fdaa3f 100644
--- a/pkgs/applications/audio/moc/default.nix
+++ b/pkgs/applications/audio/moc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , ncurses, db , popt, libtool
 # Sound sub-systems
 , alsaSupport ? true, alsaLib
@@ -94,7 +94,7 @@ in stdenv.mkDerivation rec {
     "--without-rcc"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ncurses console audio player designed to be powerful and easy to use";
     homepage = "http://moc.daper.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/mod-distortion/default.nix b/pkgs/applications/audio/mod-distortion/default.nix
index 765def25d6004..7c9f2acfd8445 100644
--- a/pkgs/applications/audio/mod-distortion/default.nix
+++ b/pkgs/applications/audio/mod-distortion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, lv2 }:
+{ lib, stdenv, fetchFromGitHub, lv2 }:
 
 stdenv.mkDerivation {
   pname = "mod-distortion-git";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   installFlags = [ "INSTALL_PATH=$(out)/lib/lv2" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/portalmod/mod-distortion";
     description = "Analog distortion emulation lv2 plugins";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/molot-lite/default.nix b/pkgs/applications/audio/molot-lite/default.nix
index 5c5aa50553702..d30b6bcad2fb5 100644
--- a/pkgs/applications/audio/molot-lite/default.nix
+++ b/pkgs/applications/audio/molot-lite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, lv2 }:
+{ lib, stdenv, fetchurl, unzip, lv2 }:
 
 stdenv.mkDerivation {
   pname = "molot-lite";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     make install INSTALL_DIR=$out/lib/lv2 -C Molot_Stereo_Lite
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stereo and mono audio signal dynamic range compressor in LV2 format";
     homepage = "https://sourceforge.net/projects/molot/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/monkeys-audio/default.nix b/pkgs/applications/audio/monkeys-audio/default.nix
index adc8eb2087e5c..62b63f7e1cabc 100644
--- a/pkgs/applications/audio/monkeys-audio/default.nix
+++ b/pkgs/applications/audio/monkeys-audio/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   version = "3.99-u4-b5";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
     sha256 = "0kjfwzfxfx7f958b2b1kf8yj655lp0ppmn0sh57gbkjvj8lml7nz";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lossless audio codec";
     platforms = platforms.linux;
     license = licenses.lgpl2;
diff --git a/pkgs/applications/audio/mopidy/gmusic.nix b/pkgs/applications/audio/mopidy/gmusic.nix
index 1e5e42ac2f346..54af3bc68f1e5 100644
--- a/pkgs/applications/audio/mopidy/gmusic.nix
+++ b/pkgs/applications/audio/mopidy/gmusic.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "mopidy-gmusic";
@@ -19,7 +19,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.mopidy.com/";
     description = "Mopidy extension for playing music from Google Play Music";
     license = licenses.asl20;
diff --git a/pkgs/applications/audio/mopidy/iris.nix b/pkgs/applications/audio/mopidy/iris.nix
index a8530a30458ff..05827b0bb565a 100644
--- a/pkgs/applications/audio/mopidy/iris.nix
+++ b/pkgs/applications/audio/mopidy/iris.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "Mopidy-Iris";
@@ -20,7 +20,7 @@ python3Packages.buildPythonApplication rec {
   # no tests implemented
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jaedb/Iris";
     description = "A fully-functional Mopidy web client encompassing Spotify and many other backends";
     license = licenses.asl20;
diff --git a/pkgs/applications/audio/mopidy/moped.nix b/pkgs/applications/audio/mopidy/moped.nix
index ffd9af76d173b..8daaef7d45d9f 100644
--- a/pkgs/applications/audio/mopidy/moped.nix
+++ b/pkgs/applications/audio/mopidy/moped.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonPackages, mopidy, glibcLocales }:
+{ lib, stdenv, pythonPackages, mopidy, glibcLocales }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "Mopidy-Moped";
@@ -16,7 +16,7 @@ pythonPackages.buildPythonApplication rec {
   # no tests implemented
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/martijnboland/moped";
     description = "A web client for Mopidy";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/mopidy/mopidy.nix b/pkgs/applications/audio/mopidy/mopidy.nix
index 6f7ee0c857ae0..55b7646af0753 100644
--- a/pkgs/applications/audio/mopidy/mopidy.nix
+++ b/pkgs/applications/audio/mopidy/mopidy.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, wrapGAppsHook
+{ lib, stdenv, fetchFromGitHub, pythonPackages, wrapGAppsHook
 , gst_all_1, glib-networking, gobject-introspection
 }:
 
@@ -38,7 +38,7 @@ pythonPackages.buildPythonApplication rec {
   # There are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.mopidy.com/";
     description = ''
       An extensible music server that plays music from local disk, Spotify,
diff --git a/pkgs/applications/audio/mopidy/mopify.nix b/pkgs/applications/audio/mopidy/mopify.nix
index a9902ca417212..17e68c165394c 100644
--- a/pkgs/applications/audio/mopidy/mopify.nix
+++ b/pkgs/applications/audio/mopidy/mopify.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonPackages, mopidy }:
+{ lib, stdenv, pythonPackages, mopidy }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "Mopidy-Mopify";
@@ -14,7 +14,7 @@ pythonPackages.buildPythonApplication rec {
   # no tests implemented
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dirkgroenen/mopidy-mopify";
     description = "A mopidy webclient based on the Spotify webbased interface";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/mopidy/mpd.nix b/pkgs/applications/audio/mopidy/mpd.nix
index 4dd32ea3aa356..8d6d7a1528b91 100644
--- a/pkgs/applications/audio/mopidy/mpd.nix
+++ b/pkgs/applications/audio/mopidy/mpd.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "Mopidy-MPD";
@@ -15,7 +15,7 @@ python3Packages.buildPythonApplication rec {
   doCheck = false;
   pythonImportsCheck = [ "mopidy_mpd" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mopidy/mopidy-mpd";
     description = "Mopidy extension for controlling playback from MPD clients";
     license = licenses.asl20;
diff --git a/pkgs/applications/audio/mopidy/mpris.nix b/pkgs/applications/audio/mopidy/mpris.nix
index 1c6d841a34e40..868dbaf303587 100644
--- a/pkgs/applications/audio/mopidy/mpris.nix
+++ b/pkgs/applications/audio/mopidy/mpris.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "mopidy-mpris";
@@ -17,7 +17,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.mopidy.com/";
     description = "Mopidy extension for controlling Mopidy through D-Bus using the MPRIS specification";
     license = licenses.asl20;
diff --git a/pkgs/applications/audio/mopidy/musicbox-webclient.nix b/pkgs/applications/audio/mopidy/musicbox-webclient.nix
index b10accedc6f8e..1e2cb8d060947 100644
--- a/pkgs/applications/audio/mopidy/musicbox-webclient.nix
+++ b/pkgs/applications/audio/mopidy/musicbox-webclient.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, mopidy }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, mopidy }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "mopidy-musicbox-webclient";
@@ -15,7 +15,7 @@ pythonPackages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mopidy extension for playing music from SoundCloud";
     license = licenses.mit;
     broken = stdenv.isDarwin;
diff --git a/pkgs/applications/audio/mopidy/scrobbler.nix b/pkgs/applications/audio/mopidy/scrobbler.nix
index 19c5a29c8a478..be38c6a7040d5 100644
--- a/pkgs/applications/audio/mopidy/scrobbler.nix
+++ b/pkgs/applications/audio/mopidy/scrobbler.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "Mopidy-Scrobbler";
@@ -15,7 +15,7 @@ python3Packages.buildPythonApplication rec {
   doCheck = false;
   pythonImportsCheck = [ "mopidy_scrobbler" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mopidy/mopidy-scrobbler";
     description = "Mopidy extension for scrobbling played tracks to Last.fm.";
     license = licenses.asl20;
diff --git a/pkgs/applications/audio/mopidy/somafm.nix b/pkgs/applications/audio/mopidy/somafm.nix
index 2e3380fa20f87..afa46726db7eb 100644
--- a/pkgs/applications/audio/mopidy/somafm.nix
+++ b/pkgs/applications/audio/mopidy/somafm.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "mopidy-somafm";
@@ -16,7 +16,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = https://www.mopidy.com/;
     description = "Mopidy extension for playing music from SomaFM";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/mopidy/soundcloud.nix b/pkgs/applications/audio/mopidy/soundcloud.nix
index fb2e9474b1fab..bdc3523652c04 100644
--- a/pkgs/applications/audio/mopidy/soundcloud.nix
+++ b/pkgs/applications/audio/mopidy/soundcloud.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, mopidy }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, mopidy }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "mopidy-soundcloud";
@@ -15,7 +15,7 @@ pythonPackages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mopidy extension for playing music from SoundCloud";
     license = licenses.mit;
     maintainers = [ maintainers.spwhitt ];
diff --git a/pkgs/applications/audio/mopidy/spotify-tunigo.nix b/pkgs/applications/audio/mopidy/spotify-tunigo.nix
index 4b75af5ed5798..8fafab0970f8f 100644
--- a/pkgs/applications/audio/mopidy/spotify-tunigo.nix
+++ b/pkgs/applications/audio/mopidy/spotify-tunigo.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, mopidy, mopidy-spotify }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, mopidy, mopidy-spotify }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "mopidy-spotify-tunigo";
@@ -15,7 +15,7 @@ pythonPackages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mopidy extension for providing the browse feature of Spotify";
     license = licenses.asl20;
     maintainers = [ maintainers.spwhitt ];
diff --git a/pkgs/applications/audio/mopidy/spotify.nix b/pkgs/applications/audio/mopidy/spotify.nix
index 32019c74f86d7..57ba6ea1f615a 100644
--- a/pkgs/applications/audio/mopidy/spotify.nix
+++ b/pkgs/applications/audio/mopidy/spotify.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages, mopidy }:
+{ lib, stdenv, fetchurl, pythonPackages, mopidy }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "mopidy-spotify";
@@ -13,7 +13,7 @@ pythonPackages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.mopidy.com/";
     description = "Mopidy extension for playing music from Spotify";
     license = licenses.asl20;
diff --git a/pkgs/applications/audio/mopidy/tunein.nix b/pkgs/applications/audio/mopidy/tunein.nix
index 90deea7c02bac..776b4a0afb546 100644
--- a/pkgs/applications/audio/mopidy/tunein.nix
+++ b/pkgs/applications/audio/mopidy/tunein.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "mopidy-tunein";
@@ -16,7 +16,7 @@ python3Packages.buildPythonApplication rec {
 
   pythonImportsCheck = [ "mopidy_tunein.tunein" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mopidy extension for playing music from tunein";
     homepage = "https://github.com/kingosticks/mopidy-tunein";
     license = licenses.asl20;
diff --git a/pkgs/applications/audio/mopidy/youtube.nix b/pkgs/applications/audio/mopidy/youtube.nix
index a115812b86a6a..e35338a5f0d67 100644
--- a/pkgs/applications/audio/mopidy/youtube.nix
+++ b/pkgs/applications/audio/mopidy/youtube.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, mopidy }:
+{ lib, stdenv, python3Packages, mopidy }:
 
 python3Packages.buildPythonApplication rec {
   pname = "mopidy-youtube";
@@ -21,7 +21,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mopidy extension for playing music from YouTube";
     license = licenses.asl20;
     maintainers = [ maintainers.spwhitt ];
diff --git a/pkgs/applications/audio/mp3blaster/default.nix b/pkgs/applications/audio/mp3blaster/default.nix
index 74814a1b7cebe..d7795524529ae 100644
--- a/pkgs/applications/audio/mp3blaster/default.nix
+++ b/pkgs/applications/audio/mp3blaster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, libvorbis, SDL }:
+{ lib, stdenv, fetchFromGitHub, ncurses, libvorbis, SDL }:
 
 stdenv.mkDerivation rec {
   pname = "mp3blaster";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     "-Wno-reserved-user-defined-literal"
   ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An audio player for the text console";
     homepage = "http://www.mp3blaster.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/mp3gain/default.nix b/pkgs/applications/audio/mp3gain/default.nix
index 4502acfa11317..fb774476a2e2a 100644
--- a/pkgs/applications/audio/mp3gain/default.nix
+++ b/pkgs/applications/audio/mp3gain/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, unzip, mpg123 }:
+{ lib, stdenv, fetchurl, fetchpatch, unzip, mpg123 }:
 
 stdenv.mkDerivation {
   name = "mp3gain-1.6.2";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     install -vD mp3gain "$out/bin/mp3gain"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lossless mp3 normalizer with statistical analysis";
     homepage = "http://mp3gain.sourceforge.net/";
     license = licenses.lgpl21;
diff --git a/pkgs/applications/audio/mp3splt/default.nix b/pkgs/applications/audio/mp3splt/default.nix
index 323854575ea74..2ff147fa919ec 100644
--- a/pkgs/applications/audio/mp3splt/default.nix
+++ b/pkgs/applications/audio/mp3splt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libmp3splt }:
+{ lib, stdenv, fetchurl, pkgconfig, libmp3splt }:
 
 stdenv.mkDerivation rec {
   pname = "mp3splt";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility to split mp3, ogg vorbis and FLAC files without decoding";
     homepage = "https://sourceforge.net/projects/mp3splt/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/mpc/default.nix b/pkgs/applications/audio/mpc/default.nix
index a226b720df9b2..a00ac7868b3dc 100644
--- a/pkgs/applications/audio/mpc/default.nix
+++ b/pkgs/applications/audio/mpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, mpd_clientlib, sphinx, libiconv }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, mpd_clientlib, sphinx, libiconv }:
 
 stdenv.mkDerivation rec {
   pname = "mpc";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ meson ninja pkgconfig sphinx ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimalist command line interface to MPD";
     homepage = "https://www.musicpd.org/clients/mpc/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/mpg321/default.nix b/pkgs/applications/audio/mpg321/default.nix
index 63b8e2d867a72..1f98d31eb9c58 100644
--- a/pkgs/applications/audio/mpg321/default.nix
+++ b/pkgs/applications/audio/mpg321/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, fetchpatch, libao, libmad, libid3tag, zlib, alsaLib
+{lib, stdenv, fetchurl, fetchpatch, libao, libmad, libid3tag, zlib, alsaLib
 # Specify default libao output plugin to use (e.g. "alsa", "pulse" …).
 # If null, it will use the libao system default.
 , defaultAudio ? null
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
 
   installTargets = [ "install" "install-man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line MP3 player";
     homepage = "http://mpg321.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/munt/default.nix b/pkgs/applications/audio/munt/default.nix
index 2e072efe79912..8d8ab419fdb47 100644
--- a/pkgs/applications/audio/munt/default.nix
+++ b/pkgs/applications/audio/munt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, qtbase, alsaLib, makeDesktopItem, libjack2 }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, qtbase, alsaLib, makeDesktopItem, libjack2 }:
 
 let
   desktopItem = makeDesktopItem rec {
@@ -28,7 +28,7 @@ in mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ qtbase alsaLib libjack2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-platform software synthesiser emulating Roland MT-32, CM-32L, CM-64 and LAPC-I devices";
     homepage = "http://munt.sourceforge.net/";
     license = with licenses; [ lgpl21 gpl3 ];
diff --git a/pkgs/applications/audio/mup/default.nix b/pkgs/applications/audio/mup/default.nix
index 0227255d38dc6..8f1d5c38b341c 100644
--- a/pkgs/applications/audio/mup/default.nix
+++ b/pkgs/applications/audio/mup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, bison, flex, ghostscript, groff, netpbm
+{ lib, stdenv, fetchurl, autoreconfHook, bison, flex, ghostscript, groff, netpbm
 , fltk, libXinerama, libXpm, libjpeg
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = false; # Undeclared dependencies + https://stackoverflow.com/a/19822767/1687334 for prolog.ps.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.arkkra.com/";
     description = "Music typesetting program (ASCII to PostScript and MIDI)";
     license = licenses.bsd3;
diff --git a/pkgs/applications/audio/muse/default.nix b/pkgs/applications/audio/muse/default.nix
index e7332aa187591..a583e45be2cc8 100644
--- a/pkgs/applications/audio/muse/default.nix
+++ b/pkgs/applications/audio/muse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, qttools, wrapQtAppsHook
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, qttools, wrapQtAppsHook
 , alsaLib, dssi, fluidsynth, ladspaH, lash, libinstpatch, libjack2, liblo
 , libsamplerate, libsndfile, lilv, lrdf, lv2, qtsvg, rtaudio, rubberband, sord
 }:
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     libsamplerate libsndfile lilv lrdf lv2 qtsvg rtaudio rubberband sord
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://muse-sequencer.github.io/";
     description = "MIDI/Audio sequencer with recording and editing capabilities";
     longDescription = ''
diff --git a/pkgs/applications/audio/musescore/darwin.nix b/pkgs/applications/audio/musescore/darwin.nix
index 4a2ae29f36ad8..8cc876ab19e86 100644
--- a/pkgs/applications/audio/musescore/darwin.nix
+++ b/pkgs/applications/audio/musescore/darwin.nix
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     chmod a+x "$out/Applications/${appName}.app/Contents/MacOS/mscore"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Music notation and composition software";
     homepage = "https://musescore.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/musescore/default.nix b/pkgs/applications/audio/musescore/default.nix
index 18026808b2b73..fa05e45b6689b 100644
--- a/pkgs/applications/audio/musescore/default.nix
+++ b/pkgs/applications/audio/musescore/default.nix
@@ -40,7 +40,7 @@ mkDerivation rec {
     qtscript qtsvg qttools qtwebengine qtxmlpatterns
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Music notation and composition software";
     homepage = "https://musescore.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/musikcube/default.nix b/pkgs/applications/audio/musikcube/default.nix
index 10a3b3b87358e..fba80928b0d1f 100644
--- a/pkgs/applications/audio/musikcube/default.nix
+++ b/pkgs/applications/audio/musikcube/default.nix
@@ -10,7 +10,7 @@
 , libmicrohttpd
 , ncurses
 , pulseaudio
-, stdenv
+, lib, stdenv
 , taglib
 , systemdSupport ? stdenv.isLinux, systemd
 }:
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     "-DDISABLE_STRIP=true"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fully functional terminal-based music player, library, and streaming audio server";
     homepage = "https://musikcube.com/";
     maintainers = [ maintainers.aanderse ];
diff --git a/pkgs/applications/audio/musly/default.nix b/pkgs/applications/audio/musly/default.nix
index 7ef2b400b7699..1e8d29d377073 100644
--- a/pkgs/applications/audio/musly/default.nix
+++ b/pkgs/applications/audio/musly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, eigen, libav }:
+{ lib, stdenv, fetchFromGitHub, cmake, eigen, libav }:
 stdenv.mkDerivation {
   pname = "musly";
   version = "unstable-2017-04-26";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     install_name_tool -change libmusly_resample.dylib $out/lib/libmusly_resample.dylib $out/lib/libmusly.dylib
   '' else "";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.musly.org";
     description = "A fast and high-quality audio music similarity library written in C/C++";
     longDescription = ''
diff --git a/pkgs/applications/audio/ncmpc/default.nix b/pkgs/applications/audio/ncmpc/default.nix
index 97aa06453e52b..2deff6162fbec 100644
--- a/pkgs/applications/audio/ncmpc/default.nix
+++ b/pkgs/applications/audio/ncmpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, glib, ncurses
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, glib, ncurses
 , mpd_clientlib, gettext, boost
 , pcreSupport ? false
 , pcre ? null
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     "-Ddocumentation=disabled"
   ] ++ optional (!pcreSupport) "-Dregex=disabled";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Curses-based interface for MPD (music player daemon)";
     homepage    = "https://www.musicpd.org/clients/ncmpc/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/ncpamixer/default.nix b/pkgs/applications/audio/ncpamixer/default.nix
index a25f3bad5b528..70acc81404e5e 100644
--- a/pkgs/applications/audio/ncpamixer/default.nix
+++ b/pkgs/applications/audio/ncpamixer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, ncurses, libpulseaudio, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, cmake, ncurses, libpulseaudio, pkg-config }:
 
 stdenv.mkDerivation rec {
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     make build
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ncurses mixer for PulseAudio inspired by pavucontrol";
     homepage = "https://github.com/fulhax/ncpamixer";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/new-session-manager/default.nix b/pkgs/applications/audio/new-session-manager/default.nix
index e4cabe0c4831f..8d359b29201d9 100644
--- a/pkgs/applications/audio/new-session-manager/default.nix
+++ b/pkgs/applications/audio/new-session-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, pkg-config, ninja, liblo, libjack2, fltk }:
+{ lib, stdenv, fetchFromGitHub, meson, pkg-config, ninja, liblo, libjack2, fltk }:
 
 stdenv.mkDerivation rec {
   pname = "new-session-manager";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://linuxaudio.github.io/new-session-manager/";
     description = "A session manager designed for audio applications.";
     maintainers = [ maintainers._6AA4FD ];
diff --git a/pkgs/applications/audio/ninjas2/default.nix b/pkgs/applications/audio/ninjas2/default.nix
index 3a23347c1e764..5af483ecfe3f8 100644
--- a/pkgs/applications/audio/ninjas2/default.nix
+++ b/pkgs/applications/audio/ninjas2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libjack2, libGL, pkgconfig, xorg, mesa, libsndfile, libsamplerate }:
+{ lib, stdenv, fetchFromGitHub, libjack2, libGL, pkgconfig, xorg, mesa, libsndfile, libsamplerate }:
 
 stdenv.mkDerivation rec {
   pname = "ninjas2";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/clearly-broken-software/ninjas2";
     description = "sample slicer plugin for LV2, VST, and jack standalone";
     license = with licenses; [ gpl3 ];
diff --git a/pkgs/applications/audio/noise-repellent/default.nix b/pkgs/applications/audio/noise-repellent/default.nix
index 3b2f233c6afef..88281cd0989ab 100644
--- a/pkgs/applications/audio/noise-repellent/default.nix
+++ b/pkgs/applications/audio/noise-repellent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, fftwFloat, lv2 }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, fftwFloat, lv2 }:
 
 stdenv.mkDerivation rec {
   pname = "noise-repellent";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     fftwFloat lv2
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An lv2 plugin for broadband noise reduction";
     homepage    = "https://github.com/lucianodato/noise-repellent";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/audio/noisetorch/default.nix b/pkgs/applications/audio/noisetorch/default.nix
index 1796927f52983..bb22b3cec221b 100644
--- a/pkgs/applications/audio/noisetorch/default.nix
+++ b/pkgs/applications/audio/noisetorch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, rnnoise-plugin }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, rnnoise-plugin }:
 
 buildGoModule rec {
   pname = "NoiseTorch";
@@ -36,7 +36,7 @@ buildGoModule rec {
     cp assets/noisetorch.desktop $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Virtual microphone device with noise supression for PulseAudio";
     homepage = "https://github.com/lawl/NoiseTorch";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/nootka/default.nix b/pkgs/applications/audio/nootka/default.nix
index b0d4843aecd5d..b1b60540b8c27 100644
--- a/pkgs/applications/audio/nootka/default.nix
+++ b/pkgs/applications/audio/nootka/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake
+{ lib, stdenv, fetchurl, cmake
 , alsaLib, fftwSinglePrec, libjack2, libpulseaudio, libvorbis, soundtouch, qtbase
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "-DENABLE_PULSEAUDIO=ON"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Application for practicing playing musical scores and ear training";
     homepage = "https://nootka.sourceforge.io/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/nootka/unstable.nix b/pkgs/applications/audio/nootka/unstable.nix
index 16df55c1dfba0..1fb70c195dc0f 100644
--- a/pkgs/applications/audio/nootka/unstable.nix
+++ b/pkgs/applications/audio/nootka/unstable.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake
+{ lib, stdenv, fetchurl, cmake
 , alsaLib, fftwSinglePrec, libjack2, libpulseaudio, libvorbis, soundtouch
 , qtbase, qtdeclarative, qtquickcontrols2
 }:
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     "-DENABLE_PULSEAUDIO=ON"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Application for practicing playing musical scores and ear training";
     homepage = "https://nootka.sourceforge.io/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/normalize/default.nix b/pkgs/applications/audio/normalize/default.nix
index 0aa2641169325..78951c67e8d86 100644
--- a/pkgs/applications/audio/normalize/default.nix
+++ b/pkgs/applications/audio/normalize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libmad }:
+{ lib, stdenv, fetchurl, libmad }:
 
 stdenv.mkDerivation rec {
   pname = "normalize";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libmad ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.nongnu.org/normalize/";
     description = "Audio file normalizer";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/nova-filters/default.nix b/pkgs/applications/audio/nova-filters/default.nix
index bc5a3efc59a38..ed5ec36171425 100644
--- a/pkgs/applications/audio/nova-filters/default.nix
+++ b/pkgs/applications/audio/nova-filters/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, sconsPackages, boost, ladspaH, pkgconfig }:
+{lib, stdenv, fetchurl, sconsPackages, boost, ladspaH, pkgconfig }:
 
 stdenv.mkDerivation {
   version = "0.2-2";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     sed -i "s/= check/= detail::filter_base<internal_type, checked>::check/" nova/source/dsp/filter.hpp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LADSPA plugins based on filters of nova";
     homepage = "http://klingt.org/~tim/nova-filters/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/ocenaudio/default.nix b/pkgs/applications/audio/ocenaudio/default.nix
index 83b1ef3b0430d..c3ab0ffcebd12 100644
--- a/pkgs/applications/audio/ocenaudio/default.nix
+++ b/pkgs/applications/audio/ocenaudio/default.nix
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     ln -s ${bzip2.out}/lib/libbz2.so.1 $out/libbz2.so.1.0
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform, easy to use, fast and functional audio editor";
     homepage = "https://www.ocenaudio.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/audio/openmpt123/default.nix b/pkgs/applications/audio/openmpt123/default.nix
index 4d1387bf6331b..486a982751147 100644
--- a/pkgs/applications/audio/openmpt123/default.nix
+++ b/pkgs/applications/audio/openmpt123/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv, fetchurl, zlib, pkgconfig, mpg123, libogg, libvorbis, portaudio, libsndfile, flac
+{ config, lib, stdenv, fetchurl, zlib, pkgconfig, mpg123, libogg, libvorbis, portaudio, libsndfile, flac
 , usePulseAudio ? config.pulseaudio or false, libpulseaudio }:
 
 let
@@ -21,7 +21,7 @@ in stdenv.mkDerivation {
 
   configureFlags = stdenv.lib.optional (!usePulseAudio) "--without-pulseaudio";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cross-platform command-line based module file player";
     homepage = "https://lib.openmpt.org/libopenmpt/";
     license = licenses.bsd3;
diff --git a/pkgs/applications/audio/opusfile/default.nix b/pkgs/applications/audio/opusfile/default.nix
index 8c83eb01b368a..34813c05e5b27 100644
--- a/pkgs/applications/audio/opusfile/default.nix
+++ b/pkgs/applications/audio/opusfile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, openssl, libogg, libopus }:
+{ lib, stdenv, fetchurl, pkgconfig, openssl, libogg, libopus }:
 
 stdenv.mkDerivation rec {
   name = "opusfile-0.12";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   patches = [ ./include-multistream.patch ];
   configureFlags = [ "--disable-examples" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-level API for decoding and seeking in .opus files";
     homepage = "https://www.opus-codec.org/";
     license = licenses.bsd3;
diff --git a/pkgs/applications/audio/orca-c/default.nix b/pkgs/applications/audio/orca-c/default.nix
index 74c74578beb98..4cd5d52613ad9 100644
--- a/pkgs/applications/audio/orca-c/default.nix
+++ b/pkgs/applications/audio/orca-c/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, portmidi }:
+{ lib, stdenv, fetchFromGitHub, ncurses, portmidi }:
 stdenv.mkDerivation {
   pname = "orca-c";
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     install build/orca $out/bin/orca
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An esoteric programming language designed to quickly create procedural sequencers";
     homepage = "https://github.com/hundredrabbits/Orca-c";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/osmid/default.nix b/pkgs/applications/audio/osmid/default.nix
index 2e31efd8172c0..f16b146e616ac 100644
--- a/pkgs/applications/audio/osmid/default.nix
+++ b/pkgs/applications/audio/osmid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , alsaLib
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/llloret/osmid";
     description = "A lightweight, portable, easy to use tool to convert MIDI to OSC and OSC to MIDI";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/padthv1/default.nix b/pkgs/applications/audio/padthv1/default.nix
index e321119d838f5..4db337917ed64 100644
--- a/pkgs/applications/audio/padthv1/default.nix
+++ b/pkgs/applications/audio/padthv1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libjack2, alsaLib, libsndfile, liblo, lv2, qt5, fftwFloat, mkDerivation }:
+{ lib, stdenv, fetchurl, pkgconfig, libjack2, alsaLib, libsndfile, liblo, lv2, qt5, fftwFloat, mkDerivation }:
 
 mkDerivation rec {
   pname = "padthv1";
@@ -13,7 +13,7 @@ mkDerivation rec {
 
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "polyphonic additive synthesizer";
     homepage = "http://padthv1.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/pamix/default.nix b/pkgs/applications/audio/pamix/default.nix
index cc5d84d9471b1..deb8bec28c207 100644
--- a/pkgs/applications/audio/pamix/default.nix
+++ b/pkgs/applications/audio/pamix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgconfig, cmake
 , libpulseaudio, ncurses }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkgconfig ];
   buildInputs = [ libpulseaudio ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pulseaudio terminal mixer";
     homepage    = "https://github.com/patroclos/PAmix";
     license     = licenses.mit;
diff --git a/pkgs/applications/audio/pamixer/default.nix b/pkgs/applications/audio/pamixer/default.nix
index 3e2192c04148f..244e688fe5710 100644
--- a/pkgs/applications/audio/pamixer/default.nix
+++ b/pkgs/applications/audio/pamixer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, boost, libpulseaudio }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, boost, libpulseaudio }:
 
 stdenv.mkDerivation rec {
   pname = "pamixer";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -Dm755 pamixer -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pulseaudio command line mixer";
     longDescription = ''
       Features:
diff --git a/pkgs/applications/audio/paprefs/default.nix b/pkgs/applications/audio/paprefs/default.nix
index b5ec1206ce3da..f2ac17f155673 100644
--- a/pkgs/applications/audio/paprefs/default.nix
+++ b/pkgs/applications/audio/paprefs/default.nix
@@ -1,5 +1,5 @@
 { fetchurl
-, stdenv
+, lib, stdenv
 , meson
 , ninja
 , gettext
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     gtkmm3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PulseAudio Preferences";
 
     longDescription = ''
diff --git a/pkgs/applications/audio/parlatype/default.nix b/pkgs/applications/audio/parlatype/default.nix
index b9babddb800f3..7ca0d347fea13 100644
--- a/pkgs/applications/audio/parlatype/default.nix
+++ b/pkgs/applications/audio/parlatype/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, meson, gtk3, at-spi2-core, dbus, gst_all_1, sphinxbase, pocketsphinx, ninja, gettext, appstream-glib, python3, glib, gobject-introspection, gsettings-desktop-schemas, itstool, wrapGAppsHook, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, meson, gtk3, at-spi2-core, dbus, gst_all_1, sphinxbase, pocketsphinx, ninja, gettext, appstream-glib, python3, glib, gobject-introspection, gsettings-desktop-schemas, itstool, wrapGAppsHook, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "parlatype";
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     export GST_PLUGIN_SYSTEM_PATH_1_0="$out/lib/gstreamer-1.0/:$GST_PLUGIN_SYSTEM_PATH_1_0"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME audio player for transcription";
     longDescription = ''
       Parlatype is a minimal audio player for manual speech transcription, written for the GNOME desktop environment.
diff --git a/pkgs/applications/audio/paulstretch/default.nix b/pkgs/applications/audio/paulstretch/default.nix
index f6cee7672f7ca..f56ad4f593015 100644
--- a/pkgs/applications/audio/paulstretch/default.nix
+++ b/pkgs/applications/audio/paulstretch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , audiofile, libvorbis, fltk, fftw, fftwFloat
 , minixml, pkgconfig, libmad, libjack2, portaudio, libsamplerate
 }:
@@ -44,7 +44,7 @@ stdenv.mkDerivation {
     install -Dm555 ./paulstretch $out/bin/paulstretch
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Produces high quality extreme sound stretching";
     longDescription = ''
       This is a program for stretching the audio. It is suitable only for
diff --git a/pkgs/applications/audio/pavucontrol/default.nix b/pkgs/applications/audio/pavucontrol/default.nix
index f0a0956f662bf..ffc56e54586cb 100644
--- a/pkgs/applications/audio/pavucontrol/default.nix
+++ b/pkgs/applications/audio/pavucontrol/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, fetchpatch, stdenv, pkgconfig, intltool, libpulseaudio,
+{ fetchurl, fetchpatch, lib, stdenv, pkgconfig, intltool, libpulseaudio,
 gtkmm3 , libcanberra-gtk3, gnome3, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--disable-lynx" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PulseAudio Volume Control";
 
     longDescription = ''
diff --git a/pkgs/applications/audio/petrifoo/default.nix b/pkgs/applications/audio/petrifoo/default.nix
index ea7b8074de231..fb29f9b13e2bc 100644
--- a/pkgs/applications/audio/petrifoo/default.nix
+++ b/pkgs/applications/audio/petrifoo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, cmake, gtk2, libjack2, libgnomecanvas
+{ lib, stdenv, fetchurl, alsaLib, cmake, gtk2, libjack2, libgnomecanvas
 , libpthreadstubs, libsamplerate, libsndfile, libtool, libxml2
 , pkg-config, openssl }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation  rec {
   buildInputs = [ alsaLib gtk2 libjack2 libgnomecanvas libpthreadstubs
                   libsamplerate libsndfile libtool libxml2 openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MIDI controllable audio sampler";
     longDescription = "a fork of Specimen";
     homepage = "http://petri-foo.sourceforge.net";
diff --git a/pkgs/applications/audio/pianobar/default.nix b/pkgs/applications/audio/pianobar/default.nix
index 4cdf415d26bfe..b53c088b7af9a 100644
--- a/pkgs/applications/audio/pianobar/default.nix
+++ b/pkgs/applications/audio/pianobar/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, pkgconfig, libao, json_c, libgcrypt, ffmpeg_3, curl }:
+{ fetchurl, lib, stdenv, pkgconfig, libao, json_c, libgcrypt, ffmpeg_3, curl }:
 
 stdenv.mkDerivation rec {
   name = "pianobar-2020.04.05";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   CC = "gcc";
   CFLAGS = "-std=c99";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A console front-end for Pandora.com";
     homepage = "https://6xq.net/pianobar/";
     platforms = platforms.unix;
diff --git a/pkgs/applications/audio/pianobooster/default.nix b/pkgs/applications/audio/pianobooster/default.nix
index b92808775c8a1..f1d35d7e78e0d 100644
--- a/pkgs/applications/audio/pianobooster/default.nix
+++ b/pkgs/applications/audio/pianobooster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, qttools
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, qttools
 , alsaLib, ftgl, libGLU, libjack2, qtbase, rtmidi, wrapQtAppsHook
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "-DOpenGL_GL_PREFERENCE=GLVND"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A MIDI file player that teaches you how to play the piano";
     homepage = "https://github.com/captnfab/PianoBooster";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/picard/default.nix b/pkgs/applications/audio/picard/default.nix
index 69debfa2ea888..8a7c1b322454d 100644
--- a/pkgs/applications/audio/picard/default.nix
+++ b/pkgs/applications/audio/picard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, gettext, chromaprint, qt5
+{ lib, stdenv, python3Packages, fetchFromGitHub, gettext, chromaprint, qt5
 , enablePlayback ? true
 , gst_all_1
 }:
@@ -54,7 +54,7 @@ in pythonPackages.buildPythonApplication rec {
     ''
   ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://picard.musicbrainz.org/";
     description = "The official MusicBrainz tagger";
     maintainers = with maintainers; [ ehmry ];
diff --git a/pkgs/applications/audio/picoloop/default.nix b/pkgs/applications/audio/picoloop/default.nix
index 69052988f26f6..519888982ce4f 100644
--- a/pkgs/applications/audio/picoloop/default.nix
+++ b/pkgs/applications/audio/picoloop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpulseaudio, SDL2, SDL2_image, SDL2_ttf, alsaLib, libjack2 }:
+{ lib, stdenv, fetchFromGitHub, libpulseaudio, SDL2, SDL2_image, SDL2_ttf, alsaLib, libjack2 }:
 
 stdenv.mkDerivation rec {
   pname = "picoloop";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     cp {font.*,LICENSE} $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A synth and a stepsequencer (a clone of the famous nanoloop)";
     homepage = "https://github.com/yoyz/picoloop";
     platforms = platforms.linux;
diff --git a/pkgs/applications/audio/pithos/default.nix b/pkgs/applications/audio/pithos/default.nix
index 6c3ffebc8c955..550cfc909d9c5 100644
--- a/pkgs/applications/audio/pithos/default.nix
+++ b/pkgs/applications/audio/pithos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, appstream-glib
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, appstream-glib
 , wrapGAppsHook, pythonPackages, gtk3, gnome3, gobject-introspection
 , libnotify, libsecret, gst_all_1 }:
 
@@ -27,7 +27,7 @@ pythonPackages.buildPythonApplication rec {
     (with gst_all_1; [ gstreamer gst-plugins-base gst-plugins-good gst-plugins-ugly gst-plugins-bad ]) ++
     (with pythonPackages; [ pygobject3 pylast ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pandora Internet Radio player for GNOME";
     homepage = "https://pithos.github.io/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/playbar2/default.nix b/pkgs/applications/audio/playbar2/default.nix
index 15385e91927c6..7545c17131f95 100644
--- a/pkgs/applications/audio/playbar2/default.nix
+++ b/pkgs/applications/audio/playbar2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , cmake
 , extra-cmake-modules
 , plasma-framework
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     kwindowsystem
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mpris2 Client for Plasma5";
     homepage = "https://github.com/audoban/PlayBar2";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/plugin-torture/default.nix b/pkgs/applications/audio/plugin-torture/default.nix
index 3c852cf450e93..b906e0336014a 100644
--- a/pkgs/applications/audio/plugin-torture/default.nix
+++ b/pkgs/applications/audio/plugin-torture/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, ladspaH, lilv, lv2, pkgconfig, serd, sord, sratom }:
+{ lib, stdenv, fetchFromGitHub, boost, ladspaH, lilv, lv2, pkgconfig, serd, sord, sratom }:
 
 stdenv.mkDerivation {
   pname = "plugin-torture";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     cp find-safe-plugins $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cth103/plugin-torture";
     description = "A tool to test LADSPA and LV2 plugins";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/plujain-ramp/default.nix b/pkgs/applications/audio/plujain-ramp/default.nix
index 2523c5a565780..56f4d6da050aa 100644
--- a/pkgs/applications/audio/plujain-ramp/default.nix
+++ b/pkgs/applications/audio/plujain-ramp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, lv2  }:
+{ lib, stdenv, fetchFromGitHub, lv2  }:
 
 stdenv.mkDerivation rec {
   version = "v1.1.3";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "INSTALL_PATH=$(out)/lib/lv2" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A mono rhythmic tremolo LV2 Audio Plugin";
     homepage = "https://github.com/Houston4444/plujain-ramp";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/audio/pmidi/default.nix b/pkgs/applications/audio/pmidi/default.nix
index 3491afaaf7a7f..28e9788acbf26 100644
--- a/pkgs/applications/audio/pmidi/default.nix
+++ b/pkgs/applications/audio/pmidi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib
+{ lib, stdenv, fetchurl, alsaLib
 , version ? "1.7.1"
 , sourceSha256 ? "051mv6f13c8y13c1iv3279k1hhzpz4fm9sfczhgp9sim2bjdj055"
 }:
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ alsaLib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.parabola.me.uk/alsa/pmidi.html";
     description = "A straightforward command line program to play midi files through the ALSA sequencer";
     maintainers = with maintainers; [ lheckemann ];
diff --git a/pkgs/applications/audio/polyphone/default.nix b/pkgs/applications/audio/polyphone/default.nix
index 270d51840d788..f54e8e8e9f02d 100644
--- a/pkgs/applications/audio/polyphone/default.nix
+++ b/pkgs/applications/audio/polyphone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, pkgconfig, alsaLib, libjack2, portaudio, libogg, flac, libvorbis, rtmidi, qtsvg }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, pkgconfig, alsaLib, libjack2, portaudio, libogg, flac, libvorbis, rtmidi, qtsvg }:
 
 mkDerivation rec {
   version = "2.2.0";
@@ -39,7 +39,7 @@ mkDerivation rec {
     "INCLUDEPATH+=${libjack2}/include/jack"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A soundfont editor for creating musical instruments";
     homepage = "https://www.polyphone-soundfonts.com/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/ponymix/default.nix b/pkgs/applications/audio/ponymix/default.nix
index 6c289a97384f7..fb28b10448d45 100644
--- a/pkgs/applications/audio/ponymix/default.nix
+++ b/pkgs/applications/audio/ponymix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpulseaudio, libnotify, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, libpulseaudio, libnotify, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "ponymix";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   postPatch = ''substituteInPlace Makefile --replace "\$(DESTDIR)/usr" "$out"'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI PulseAudio Volume Control";
     homepage = "https://github.com/falconindy/ponymix";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/pt2-clone/default.nix b/pkgs/applications/audio/pt2-clone/default.nix
index c73c356276862..011ef8d12e5cd 100644
--- a/pkgs/applications/audio/pt2-clone/default.nix
+++ b/pkgs/applications/audio/pt2-clone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , nixosTests
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     pt2-clone-opens = nixosTests.pt2-clone;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A highly accurate clone of the classic ProTracker 2.3D software for Amiga";
     homepage = "https://16-bits.org/pt2.php";
     license = licenses.bsd3;
diff --git a/pkgs/applications/audio/ptcollab/default.nix b/pkgs/applications/audio/ptcollab/default.nix
index ff190fdcdd36c..36495986201f1 100644
--- a/pkgs/applications/audio/ptcollab/default.nix
+++ b/pkgs/applications/audio/ptcollab/default.nix
@@ -1,5 +1,5 @@
 { mkDerivation
-, stdenv
+, lib, stdenv
 , fetchFromGitHub
 , qmake
 , qtbase
@@ -22,7 +22,7 @@ mkDerivation rec {
 
   buildInputs = [ qtbase qtmultimedia libvorbis ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Experimental pxtone editor where you can collaborate with friends";
     homepage = "https://yuxshao.github.io/ptcollab/";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/puddletag/default.nix b/pkgs/applications/audio/puddletag/default.nix
index 55cde08fe871d..94a571df2944c 100644
--- a/pkgs/applications/audio/puddletag/default.nix
+++ b/pkgs/applications/audio/puddletag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, wrapQtAppsHook, chromaprint }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, wrapQtAppsHook, chromaprint }:
 
 python3Packages.buildPythonApplication rec {
   pname = "puddletag";
@@ -30,7 +30,7 @@ python3Packages.buildPythonApplication rec {
 
   dontStrip = true; # we are not generating any binaries
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An audio tag editor similar to the Windows program, Mp3tag";
     homepage = "https://docs.puddletag.net";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/pulseaudio-ctl/default.nix b/pkgs/applications/audio/pulseaudio-ctl/default.nix
index 6a19d959a23d8..245c58a211968 100644
--- a/pkgs/applications/audio/pulseaudio-ctl/default.nix
+++ b/pkgs/applications/audio/pulseaudio-ctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchFromGitHub, makeWrapper
 , bc, dbus, gawk, gnused, libnotify, pulseaudio }:
 
 let
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
       --prefix PATH : ${path}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Control pulseaudio volume from the shell or mapped to keyboard shortcuts. No need for alsa-utils";
     homepage = "https://bbs.archlinux.org/viewtopic.php?id=124513";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/pulseaudio-dlna/default.nix b/pkgs/applications/audio/pulseaudio-dlna/default.nix
index c0986880c0942..3c80a52128614 100644
--- a/pkgs/applications/audio/pulseaudio-dlna/default.nix
+++ b/pkgs/applications/audio/pulseaudio-dlna/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, pythonPackages
+{ fetchFromGitHub, lib, stdenv, pythonPackages
 , mp3Support ? true, lame ? null
 , opusSupport ? true, opusTools ? null
 , faacSupport ? false, faac ? null
@@ -44,7 +44,7 @@ pythonPackages.buildPythonApplication {
     $out/bin/pulseaudio-dlna --help > /dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight streaming server which brings DLNA / UPNP and Chromecast support to PulseAudio and Linux";
     homepage = "https://github.com/masmu/pulseaudio-dlna";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/pulseaudio-dlna/zeroconf.nix b/pkgs/applications/audio/pulseaudio-dlna/zeroconf.nix
index efe39aa1600ee..e28aabe8dab15 100644
--- a/pkgs/applications/audio/pulseaudio-dlna/zeroconf.nix
+++ b/pkgs/applications/audio/pulseaudio-dlna/zeroconf.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , ifaddr
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ netifaces six enum-compat ifaddr ]
     ++ stdenv.lib.optionals (pythonOlder "3.5") [ typing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure python implementation of multicast DNS service discovery";
     homepage = "https://github.com/jstasiak/python-zeroconf";
     license = licenses.lgpl21;
diff --git a/pkgs/applications/audio/pulseaudio-modules-bt/default.nix b/pkgs/applications/audio/pulseaudio-modules-bt/default.nix
index 42e780af0989a..c7dc2cc3b1d32 100644
--- a/pkgs/applications/audio/pulseaudio-modules-bt/default.nix
+++ b/pkgs/applications/audio/pulseaudio-modules-bt/default.nix
@@ -81,7 +81,7 @@ in stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/EHfive/pulseaudio-modules-bt";
     description = "LDAC, aptX, aptX HD, AAC codecs (A2DP Audio) support for Linux PulseAudio";
     platforms = platforms.linux;
diff --git a/pkgs/applications/audio/pulseeffects/default.nix b/pkgs/applications/audio/pulseeffects/default.nix
index a66cd00527729..4fb591e75c316 100644
--- a/pkgs/applications/audio/pulseeffects/default.nix
+++ b/pkgs/applications/audio/pulseeffects/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -104,7 +104,7 @@ in stdenv.mkDerivation rec {
   BOOST_INCLUDEDIR = "${stdenv.lib.getDev boost}/include";
   BOOST_LIBRARYDIR = "${stdenv.lib.getLib boost}/lib";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Limiter, compressor, reverberation, equalizer and auto volume effects for Pulseaudio applications";
     homepage = "https://github.com/wwmm/pulseeffects";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/puredata/default.nix b/pkgs/applications/audio/puredata/default.nix
index 4b221cd1a76bf..9bc6903e51b8e 100644
--- a/pkgs/applications/audio/puredata/default.nix
+++ b/pkgs/applications/audio/puredata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, gettext, makeWrapper
+{ lib, stdenv, fetchurl, autoreconfHook, gettext, makeWrapper
 , alsaLib, libjack2, tk, fftw
 }:
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation  rec {
     wrapProgram $out/bin/pd --prefix PATH : ${tk}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''A real-time graphical programming environment for
                     audio, video, and graphical processing'';
     homepage = "http://puredata.info";
diff --git a/pkgs/applications/audio/qjackctl/default.nix b/pkgs/applications/audio/qjackctl/default.nix
index 4ac64afe85477..51972e6bfebe3 100644
--- a/pkgs/applications/audio/qjackctl/default.nix
+++ b/pkgs/applications/audio/qjackctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub
+{ lib, stdenv, mkDerivation, fetchFromGitHub
 , pkg-config, cmake, alsaLib, libjack2, dbus, qtbase, qttools, qtx11extras
 # Enable jack session support
 , jackSession ? false
@@ -36,7 +36,7 @@ mkDerivation rec {
     "-DCONFIG_JACK_SESSION=${toString jackSession}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Qt application to control the JACK sound server daemon";
     homepage = "https://github.com/rncbc/qjackctl";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/qmidiarp/default.nix b/pkgs/applications/audio/qmidiarp/default.nix
index 4bbfe79a2c9f9..4fa165a05a9c7 100644
--- a/pkgs/applications/audio/qmidiarp/default.nix
+++ b/pkgs/applications/audio/qmidiarp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , automake
 , autoreconfHook
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     qttools
   ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An advanced MIDI arpeggiator";
     longDescription = ''
       An advanced MIDI arpeggiator, programmable step sequencer and LFO for Linux.
diff --git a/pkgs/applications/audio/qmidiroute/default.nix b/pkgs/applications/audio/qmidiroute/default.nix
index 2a83d98b6ea3a..ee983f7801452 100644
--- a/pkgs/applications/audio/qmidiroute/default.nix
+++ b/pkgs/applications/audio/qmidiroute/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, qt4, alsaLib }:
+{ lib, stdenv, fetchurl, pkgconfig, qt4, alsaLib }:
 
 stdenv.mkDerivation rec {
   version = "0.4.0";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ qt4 alsaLib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MIDI event processor and router";
     longDescription = ''
     qmidiroute is a versatile MIDI event processor and router for the ALSA
diff --git a/pkgs/applications/audio/qmmp/default.nix b/pkgs/applications/audio/qmmp/default.nix
index 2863ae3a61cbd..f5015325d850c 100644
--- a/pkgs/applications/audio/qmmp/default.nix
+++ b/pkgs/applications/audio/qmmp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, cmake, pkgconfig, xlibsWrapper
+{ lib, stdenv, mkDerivation, fetchurl, cmake, pkgconfig, xlibsWrapper
 , qtbase, qttools, qtmultimedia, qtx11extras
 # transports
 , curl, libmms
@@ -51,7 +51,7 @@ mkDerivation rec {
       libsamplerate
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt-based audio player that looks like Winamp";
     homepage = "http://qmmp.ylsoftware.com/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/qsampler/default.nix b/pkgs/applications/audio/qsampler/default.nix
index 1f65b37483814..0418957dee0bd 100644
--- a/pkgs/applications/audio/qsampler/default.nix
+++ b/pkgs/applications/audio/qsampler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, libtool, pkgconfig, qttools
+{ lib, stdenv, fetchurl, autoconf, automake, libtool, pkgconfig, qttools
 , liblscp, libgig, qtbase, mkDerivation }:
 
 mkDerivation rec {
@@ -17,7 +17,7 @@ mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.linuxsampler.org";
     description = "Graphical frontend to LinuxSampler";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/qsynth/default.nix b/pkgs/applications/audio/qsynth/default.nix
index af59bb56eb9ab..1ea7852dc102e 100644
--- a/pkgs/applications/audio/qsynth/default.nix
+++ b/pkgs/applications/audio/qsynth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, fluidsynth, libjack2, autoconf, pkgconfig
+{ lib, stdenv, fetchurl, alsaLib, fluidsynth, libjack2, autoconf, pkgconfig
 , mkDerivation, qtbase, qttools, qtx11extras
 }:
 
@@ -17,7 +17,7 @@ mkDerivation  rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fluidsynth GUI";
     homepage = "https://sourceforge.net/projects/qsynth";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/qtractor/default.nix b/pkgs/applications/audio/qtractor/default.nix
index f2d5ae1c80920..493a99f6b71ba 100644
--- a/pkgs/applications/audio/qtractor/default.nix
+++ b/pkgs/applications/audio/qtractor/default.nix
@@ -24,7 +24,7 @@
 , serd
 , sord
 , sratom
-, stdenv
+, lib, stdenv
 , suil
 }:
 
@@ -69,7 +69,7 @@ mkDerivation rec {
     suil
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Audio/MIDI multi-track sequencer";
     homepage = "https://qtractor.sourceforge.io";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/quodlibet/default.nix b/pkgs/applications/audio/quodlibet/default.nix
index 386a5110a8179..00da41e308a81 100644
--- a/pkgs/applications/audio/quodlibet/default.nix
+++ b/pkgs/applications/audio/quodlibet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3, wrapGAppsHook, gettext, libsoup, gnome3, gtk3, gdk-pixbuf, librsvg,
+{ lib, stdenv, fetchurl, python3, wrapGAppsHook, gettext, libsoup, gnome3, gtk3, gdk-pixbuf, librsvg,
   tag ? "", xvfb_run, dbus, glibcLocales, glib, glib-networking, gobject-introspection, hicolor-icon-theme,
   gst_all_1, withGstPlugins ? true,
   xineBackend ? false, xineLib,
@@ -67,7 +67,7 @@ python3.pkgs.buildPythonApplication rec {
 
   preFixup = stdenv.lib.optionalString (kakasi != null) "gappsWrapperArgs+=(--prefix PATH : ${kakasi}/bin)";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK-based audio player written in Python, using the Mutagen tagging library";
     license = licenses.gpl2Plus;
 
diff --git a/pkgs/applications/audio/radiotray-ng/default.nix b/pkgs/applications/audio/radiotray-ng/default.nix
index 8b61bc07a6942..9c5e6a931a97d 100644
--- a/pkgs/applications/audio/radiotray-ng/default.nix
+++ b/pkgs/applications/audio/radiotray-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, pkgconfig
 # Transport
 , curl
@@ -88,7 +88,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/rt2rtng --prefix PYTHONPATH : $PYTHONPATH
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An internet radio player for linux";
     homepage = "https://github.com/ebruck/radiotray-ng";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/rakarrack/default.nix b/pkgs/applications/audio/rakarrack/default.nix
index 4548f9ba624fa..8b5dd869e82ed 100644
--- a/pkgs/applications/audio/rakarrack/default.nix
+++ b/pkgs/applications/audio/rakarrack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, alsaUtils, fltk, libjack2, libXft,
+{ lib, stdenv, fetchurl, alsaLib, alsaUtils, fltk, libjack2, libXft,
 libXpm, libjpeg, libpng, libsamplerate, libsndfile, zlib }:
 
 stdenv.mkDerivation  rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation  rec {
   buildInputs = [ alsaLib alsaUtils fltk libjack2 libXft libXpm libjpeg
     libpng libsamplerate libsndfile zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-effects processor emulating a guitar effects pedalboard";
     homepage = "http://rakarrack.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/real_time_config_quick_scan/default.nix b/pkgs/applications/audio/real_time_config_quick_scan/default.nix
index 5193d2899d307..3fb476b65cc4b 100644
--- a/pkgs/applications/audio/real_time_config_quick_scan/default.nix
+++ b/pkgs/applications/audio/real_time_config_quick_scan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perlPackages, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, perlPackages, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "realTimeConfigQuickScan";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
       --set PERL5LIB "$out/share/$pname:${with perlPackages; makePerlPath [ Tk ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux configuration checker for systems to be used for real-time audio";
     homepage = "https://github.com/raboof/realtimeconfigquickscan";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/reaper/default.nix b/pkgs/applications/audio/reaper/default.nix
index e15addd78b1ed..09df5dcddbb5a 100644
--- a/pkgs/applications/audio/reaper/default.nix
+++ b/pkgs/applications/audio/reaper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoPatchelfHook, makeWrapper
+{ lib, stdenv, fetchurl, autoPatchelfHook, makeWrapper
 , alsaLib, xorg, libjack2
 , gtk3, pango, gdk-pixbuf, cairo, glib, freetype
 , libpulseaudio, xdg_utils
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
     ln -s $out/opt/REAPER/reamote-server $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Digital audio workstation";
     homepage = "https://www.reaper.fm/";
     license = licenses.unfree;
diff --git a/pkgs/applications/audio/rhythmbox/default.nix b/pkgs/applications/audio/rhythmbox/default.nix
index 79560451e540c..c07d73530b5a9 100644
--- a/pkgs/applications/audio/rhythmbox/default.nix
+++ b/pkgs/applications/audio/rhythmbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , python3
 , perl
 , perlPackages
@@ -57,7 +57,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Rhythmbox";
     description = "A music playing application for GNOME";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/rkrlv2/default.nix b/pkgs/applications/audio/rkrlv2/default.nix
index 2eb3dc3d7e5c1..19fca6af988da 100644
--- a/pkgs/applications/audio/rkrlv2/default.nix
+++ b/pkgs/applications/audio/rkrlv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, lv2, fftw, cmake, libXpm
+{ lib, stdenv, fetchFromGitHub, pkg-config, lv2, fftw, cmake, libXpm
 , libXft, libjack2, libsamplerate, libsndfile }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkg-config ];
   buildInputs = [ libXft libXpm lv2 fftw libjack2 libsamplerate libsndfile ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rakarrak effects ported to LV2";
     homepage = "https://github.com/ssj71/rkrlv2";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/audio/rosegarden/default.nix b/pkgs/applications/audio/rosegarden/default.nix
index 416f4906d6e2e..31fce7460770a 100644
--- a/pkgs/applications/audio/rosegarden/default.nix
+++ b/pkgs/applications/audio/rosegarden/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, makedepend, perl, pkgconfig, qttools, wrapQtAppsHook
+{ lib, stdenv, fetchurl, cmake, makedepend, perl, pkgconfig, qttools, wrapQtAppsHook
 , dssi, fftwSinglePrec, ladspaH, ladspaPlugins, libjack2, alsaLib
 , liblo, libsamplerate, libsndfile, lirc ? null, lrdf, qtbase }:
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation (rec {
     alsaLib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.rosegardenmusic.com/";
     description = "Music composition and editing environment";
     longDescription = ''
diff --git a/pkgs/applications/audio/rubyripper/default.nix b/pkgs/applications/audio/rubyripper/default.nix
index eb6de8431803e..b7abfa40b8636 100644
--- a/pkgs/applications/audio/rubyripper/default.nix
+++ b/pkgs/applications/audio/rubyripper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ruby, cdparanoia, makeWrapper }:
+{ lib, stdenv, fetchurl, ruby, cdparanoia, makeWrapper }:
 stdenv.mkDerivation rec {
   version = "0.6.2";
   pname = "rubyripper";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${cdparanoia}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High quality CD audio ripper";
     platforms = platforms.linux;
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/sc68/default.nix b/pkgs/applications/audio/sc68/default.nix
index 683aa9c36bcab..2ea9b123c0865 100644
--- a/pkgs/applications/audio/sc68/default.nix
+++ b/pkgs/applications/audio/sc68/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchsvn
 , pkg-config
 , which
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libao zlib curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Atari ST and Amiga music player";
     homepage = "http://sc68.atari.org/project.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/schismtracker/default.nix b/pkgs/applications/audio/schismtracker/default.nix
index 7f6762958a346..02c8f28da6579 100644
--- a/pkgs/applications/audio/schismtracker/default.nix
+++ b/pkgs/applications/audio/schismtracker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook
 , alsaLib, python, SDL }:
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ SDL ] ++ stdenv.lib.optional stdenv.isLinux alsaLib;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Music tracker application, free reimplementation of Impulse Tracker";
     homepage = "http://schismtracker.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/seq24/default.nix b/pkgs/applications/audio/seq24/default.nix
index c8347d70b1d93..aa3abd3f0f396 100644
--- a/pkgs/applications/audio/seq24/default.nix
+++ b/pkgs/applications/audio/seq24/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, gtkmm2, libjack2, pkgconfig }:
+{ lib, stdenv, fetchurl, alsaLib, gtkmm2, libjack2, pkgconfig }:
 
 stdenv.mkDerivation  rec {
   pname = "seq24";
@@ -14,7 +14,7 @@ stdenv.mkDerivation  rec {
   buildInputs = [ alsaLib gtkmm2 libjack2 ];
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minimal loop based midi sequencer";
     homepage = "http://www.filter24.org/seq24";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/seq66/default.nix b/pkgs/applications/audio/seq66/default.nix
index 6b3a3939b43f4..93f9e9503b95e 100644
--- a/pkgs/applications/audio/seq66/default.nix
+++ b/pkgs/applications/audio/seq66/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkg-config, qttools, which
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config, qttools, which
 , alsaLib, libjack2, liblo, qtbase
 }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ahlstromcj/seq66";
     description = "Loop based midi sequencer with Qt GUI derived from seq24 and sequencer64";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/setbfree/default.nix b/pkgs/applications/audio/setbfree/default.nix
index a7500f8c6a5ef..0f3b2fcfa9533 100644
--- a/pkgs/applications/audio/setbfree/default.nix
+++ b/pkgs/applications/audio/setbfree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, alsaLib, freetype, ftgl, libjack2, libX11, lv2
+{ lib, stdenv, fetchzip, alsaLib, freetype, ftgl, libjack2, libX11, lv2
 , libGLU, libGL, pkgconfig, ttf_bitstream_vera
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation  rec {
     ttf_bitstream_vera
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A DSP tonewheel organ emulator";
     homepage = "http://setbfree.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/sfizz/default.nix b/pkgs/applications/audio/sfizz/default.nix
index b4ff5fc56d56e..4ba30935089cf 100644
--- a/pkgs/applications/audio/sfizz/default.nix
+++ b/pkgs/applications/audio/sfizz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , cmake, libjack2, libsndfile, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub , cmake, libjack2, libsndfile, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "sfizz";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "-DSFIZZ_TESTS=ON"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sfztools/sfizz";
     description = "SFZ jack client and LV2 plugin";
     license = licenses.bsd2;
diff --git a/pkgs/applications/audio/sfxr/default.nix b/pkgs/applications/audio/sfxr/default.nix
index fbd0f3c5def3d..9e5195b2caaf5 100644
--- a/pkgs/applications/audio/sfxr/default.nix
+++ b/pkgs/applications/audio/sfxr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , desktop-file-utils
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.drpetter.se/project_sfxr.html";
     description = "A videogame sound effect generator";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/shortwave/default.nix b/pkgs/applications/audio/shortwave/default.nix
index 3572bbf88abb8..2cc8c53f6072a 100644
--- a/pkgs/applications/audio/shortwave/default.nix
+++ b/pkgs/applications/audio/shortwave/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , cargo
 , dbus
@@ -73,7 +73,7 @@ rustPlatform.buildRustPackage rec {
     patchShebangs build-aux/meson/postinstall.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/World/Shortwave";
     description = "Find and listen to internet radio stations";
     longDescription = ''
diff --git a/pkgs/applications/audio/sisco.lv2/default.nix b/pkgs/applications/audio/sisco.lv2/default.nix
index 07215fc42f87f..311edbbae89f1 100644
--- a/pkgs/applications/audio/sisco.lv2/default.nix
+++ b/pkgs/applications/audio/sisco.lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, lv2, pkgconfig, libGLU, libGL, cairo, pango, libjack2 }:
+{ lib, stdenv, fetchFromGitHub, lv2, pkgconfig, libGLU, libGL, cairo, pango, libjack2 }:
 
 let
   name = "sisco.lv2-${version}";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
   sisco_VERSION = version;
   preConfigure = "makeFlagsArray=(PREFIX=$out)";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple audio oscilloscope with variable time scale, triggering, cursors and numeric readout in LV2 plugin format";
     homepage = "http://x42.github.io/sisco.lv2/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/sndpeek/default.nix b/pkgs/applications/audio/sndpeek/default.nix
index d239fda11aee4..a8dfe759d6252 100644
--- a/pkgs/applications/audio/sndpeek/default.nix
+++ b/pkgs/applications/audio/sndpeek/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libsndfile, freeglut, alsaLib, mesa, libGLU, libX11, libXmu
+{ lib, stdenv, fetchurl, libsndfile, freeglut, alsaLib, mesa, libGLU, libX11, libXmu
 , libXext, libXi }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     mv sndpeek $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Real-time 3D animated audio display/playback";
     longDescription = ''
        sndpeek is just what it sounds (and looks) like:
diff --git a/pkgs/applications/audio/sonic-lineup/default.nix b/pkgs/applications/audio/sonic-lineup/default.nix
index 526dd245691b7..87803e684857c 100644
--- a/pkgs/applications/audio/sonic-lineup/default.nix
+++ b/pkgs/applications/audio/sonic-lineup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, boost, bzip2, fftw, fftwFloat, libfishsound
+{ lib, stdenv, fetchurl, alsaLib, boost, bzip2, fftw, fftwFloat, libfishsound
 , libid3tag, liblo, libmad, liboggz, libpulseaudio, libsamplerate
 , libsndfile, lrdf, opusfile, portaudio, rubberband, serd, sord, capnproto
 , wrapQtAppsHook, pkgconfig
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     sed -i 's/sub_test_svcore_/#sub_test_svcore_/' sonic-lineup.pro
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Comparative visualisation of related audio recordings";
     homepage = "https://www.sonicvisualiser.org/sonic-lineup/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/sonic-visualiser/default.nix b/pkgs/applications/audio/sonic-visualiser/default.nix
index 2593bf38d194b..f2df119fcc685 100644
--- a/pkgs/applications/audio/sonic-visualiser/default.nix
+++ b/pkgs/applications/audio/sonic-visualiser/default.nix
@@ -1,6 +1,6 @@
 # TODO add plugins having various licenses, see http://www.vamp-plugins.org/download.html
 
-{ stdenv, fetchurl, alsaLib, bzip2, fftw, libjack2, libX11, liblo
+{ lib, stdenv, fetchurl, alsaLib, bzip2, fftw, libjack2, libX11, liblo
 , libmad, lrdf, librdf_raptor, librdf_rasqal, libsamplerate
 , libsndfile, pkg-config, libpulseaudio, qtbase, qtsvg, redland
 , rubberband, serd, sord, vamp-plugin-sdk, fftwFloat
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "View and analyse contents of music audio files";
     homepage = "https://www.sonicvisualiser.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/sooperlooper/default.nix b/pkgs/applications/audio/sooperlooper/default.nix
index f1c76bf0d33c9..e9ec7b33f7473 100644
--- a/pkgs/applications/audio/sooperlooper/default.nix
+++ b/pkgs/applications/audio/sooperlooper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkgconfig
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A live looping sampler capable of immediate loop recording, overdubbing, multiplying, reversing and more";
     longDescription = ''
       It allows for multiple simultaneous multi-channel loops limited only by your computer's available memory.
diff --git a/pkgs/applications/audio/sorcer/default.nix b/pkgs/applications/audio/sorcer/default.nix
index b20188bfb4777..59c7d91a3e387 100644
--- a/pkgs/applications/audio/sorcer/default.nix
+++ b/pkgs/applications/audio/sorcer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , boost, cairomm, cmake, libsndfile, lv2, ntk, pkg-config, python }:
+{ lib, stdenv, fetchFromGitHub , boost, cairomm, cmake, libsndfile, lv2, ntk, pkg-config, python }:
 
 stdenv.mkDerivation rec {
   pname = "sorcer";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     cp -a ../presets/* "$out/lib/lv2"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://openavproductions.com/sorcer/";
     description = "A wavetable LV2 plugin synth, targeted at the electronic / dubstep genre";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/sound-juicer/default.nix b/pkgs/applications/audio/sound-juicer/default.nix
index 89653a59f437c..e8ab895579caa 100644
--- a/pkgs/applications/audio/sound-juicer/default.nix
+++ b/pkgs/applications/audio/sound-juicer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, glib, gtk3, intltool, itstool, libxml2, brasero
+{ lib, stdenv, fetchurl, pkgconfig, glib, gtk3, intltool, itstool, libxml2, brasero
 , libcanberra-gtk3, gnome3, gst_all_1, libmusicbrainz5, libdiscid, isocodes
 , gsettings-desktop-schemas, wrapGAppsHook }:
 
@@ -30,7 +30,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Gnome CD Ripper";
     homepage = "https://wiki.gnome.org/Apps/SoundJuicer";
     maintainers = [ maintainers.bdimcheff ];
diff --git a/pkgs/applications/audio/soundtracker/default.nix b/pkgs/applications/audio/soundtracker/default.nix
index 1fd341765b09d..aa78bbf3de8e3 100644
--- a/pkgs/applications/audio/soundtracker/default.nix
+++ b/pkgs/applications/audio/soundtracker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkg-config
 , autoconf
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A music tracking tool similar in design to the DOS program FastTracker and the Amiga legend ProTracker";
     longDescription = ''
       SoundTracker is a pattern-oriented music editor (similar to the DOS
diff --git a/pkgs/applications/audio/spectmorph/default.nix b/pkgs/applications/audio/spectmorph/default.nix
index ece6689a9d073..055ed99dbeb67 100644
--- a/pkgs/applications/audio/spectmorph/default.nix
+++ b/pkgs/applications/audio/spectmorph/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libjack2, lv2, glib, qt5, libao, cairo, libsndfile, fftwFloat }:
+{ lib, stdenv, fetchurl, pkgconfig, libjack2, lv2, glib, qt5, libao, cairo, libsndfile, fftwFloat }:
 
 stdenv.mkDerivation rec {
   pname = "spectmorph";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows to analyze samples of musical instruments, and to combine them (morphing) to construct hybrid sounds";
     homepage = "http://spectmorph.org";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/speech-denoiser/default.nix b/pkgs/applications/audio/speech-denoiser/default.nix
index 9c18665d39932..34b372f964e63 100644
--- a/pkgs/applications/audio/speech-denoiser/default.nix
+++ b/pkgs/applications/audio/speech-denoiser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, lv2, meson, ninja }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, lv2, meson, ninja }:
 
 let
   speech-denoiser-src = fetchFromGitHub {
@@ -34,7 +34,7 @@ stdenv.mkDerivation  {
       --replace "cc.find_library('rnnoise-nu',dirs: meson.current_source_dir() + '/rnnoise/.libs/',required : true)" "cc.find_library('rnnoise-nu', required : true)"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Speech denoise lv2 plugin based on RNNoise library";
     homepage = "https://github.com/lucianodato/speech-denoiser";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/audio/spek/default.nix b/pkgs/applications/audio/spek/default.nix
index d6918b1923153..d4b83605c321a 100644
--- a/pkgs/applications/audio/spek/default.nix
+++ b/pkgs/applications/audio/spek/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, intltool, pkgconfig, ffmpeg, wxGTK30-gtk3, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, intltool, pkgconfig, ffmpeg, wxGTK30-gtk3, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "spek";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ffmpeg wxGTK30-gtk3 wxGTK30-gtk3.gtk ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Analyse your audio files by showing their spectrogram";
     homepage = "http://spek.cc/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/split2flac/default.nix b/pkgs/applications/audio/split2flac/default.nix
index efad434e30796..689e9e1cb24b4 100644
--- a/pkgs/applications/audio/split2flac/default.nix
+++ b/pkgs/applications/audio/split2flac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchFromGitHub, makeWrapper
 , shntool, cuetools
 , flac, faac, mp4v2, wavpack, mac
 , imagemagick, libiconv, enca, lame, pythonPackages, vorbis-tools
@@ -52,7 +52,7 @@ in stdenv.mkDerivation rec {
     ${wrapSplit2flac "wav"}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Split flac/ape/wv/wav + cue sheet into separate tracks";
     homepage = "https://github.com/ftrvxmtrx/split2flac";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/spotify-cli-linux/default.nix b/pkgs/applications/audio/spotify-cli-linux/default.nix
index da41fb6b64ed4..593ad9468ebae 100644
--- a/pkgs/applications/audio/spotify-cli-linux/default.nix
+++ b/pkgs/applications/audio/spotify-cli-linux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, dbus }:
+{ lib, stdenv, python3Packages, dbus }:
 python3Packages.buildPythonApplication rec {
   pname = "spotify-cli-linux";
   version = "1.6.0";
@@ -19,7 +19,7 @@ python3Packages.buildPythonApplication rec {
   # upstream has no code tests, but uses its "tests" for linting and formatting checks
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pwittchen.github.io/spotify-cli-linux/";
     maintainers = [ maintainers.kmein ];
     description = "A command line interface to Spotify on Linux.";
diff --git a/pkgs/applications/audio/spotify-tui/default.nix b/pkgs/applications/audio/spotify-tui/default.nix
index 4eb6288e4ee70..55a725e59b0a8 100644
--- a/pkgs/applications/audio/spotify-tui/default.nix
+++ b/pkgs/applications/audio/spotify-tui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, installShellFiles, pkgconfig, openssl, python3, libxcb, AppKit, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles, pkgconfig, openssl, python3, libxcb, AppKit, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "spotify-tui";
@@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Spotify for the terminal written in Rust";
     homepage = "https://github.com/Rigellute/spotify-tui";
     changelog = "https://github.com/Rigellute/spotify-tui/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/applications/audio/spotify/default.nix b/pkgs/applications/audio/spotify/default.nix
index ff44f14476f16..bfc8757445c9b 100644
--- a/pkgs/applications/audio/spotify/default.nix
+++ b/pkgs/applications/audio/spotify/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, squashfsTools, xorg, alsaLib, makeWrapper, openssl, freetype
+{ fetchurl, lib, stdenv, squashfsTools, xorg, alsaLib, makeWrapper, openssl, freetype
 , glib, pango, cairo, atk, gdk-pixbuf, gtk2, cups, nspr, nss, libpng, libnotify
 , libgcrypt, systemd, fontconfig, dbus, expat, ffmpeg_3, curl, zlib, gnome3
 , at-spi2-atk, at-spi2-core, libpulseaudio, libdrm, mesa
@@ -158,7 +158,7 @@ stdenv.mkDerivation {
       runHook postInstall
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.spotify.com/";
     description = "Play music from the Spotify music service";
     license = licenses.unfree;
diff --git a/pkgs/applications/audio/spotifyd/default.nix b/pkgs/applications/audio/spotifyd/default.nix
index c4e1695f08352..737b8656c6a28 100644
--- a/pkgs/applications/audio/spotifyd/default.nix
+++ b/pkgs/applications/audio/spotifyd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPackages_1_45, pkgconfig, openssl
+{ lib, stdenv, fetchFromGitHub, rustPackages_1_45, pkgconfig, openssl
 , withALSA ? true, alsaLib ? null
 , withPulseAudio ? false, libpulseaudio ? null
 , withPortAudio ? false, portaudio ? null
@@ -39,7 +39,7 @@ rustPackages_1_45.rustPlatform.buildRustPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source Spotify client running as a UNIX daemon";
     homepage = "https://github.com/Spotifyd/spotifyd";
     license = with licenses; [ gpl3 ];
diff --git a/pkgs/applications/audio/spotifywm/default.nix b/pkgs/applications/audio/spotifywm/default.nix
index a51e82f29c4bc..2241db126b81c 100644
--- a/pkgs/applications/audio/spotifywm/default.nix
+++ b/pkgs/applications/audio/spotifywm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, spotify, xorg, runtimeShell }:
+{ lib, stdenv, fetchFromGitHub, spotify, xorg, runtimeShell }:
 stdenv.mkDerivation {
   pname = "spotifywm-unstable";
   version = "2016-11-28";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     install -Dm755 spotifywm $out/bin/spotifywm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dasJ/spotifywm";
     description = "Wrapper around Spotify that correctly sets class name before opening the window";
     license = licenses.mit;
diff --git a/pkgs/applications/audio/squeezelite/default.nix b/pkgs/applications/audio/squeezelite/default.nix
index c6a78f090058f..d5c84888eeb02 100644
--- a/pkgs/applications/audio/squeezelite/default.nix
+++ b/pkgs/applications/audio/squeezelite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , alsaLib, flac, libmad, libvorbis, mpg123
 , dsdSupport ? true
 , faad2Support ? true, faad2
@@ -60,7 +60,7 @@ in stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight headless squeezebox client emulator";
     homepage = "https://github.com/ralph-irving/squeezelite";
     license = with licenses; [ gpl3 ] ++ optional dsdSupport bsd2;
diff --git a/pkgs/applications/audio/squishyball/default.nix b/pkgs/applications/audio/squishyball/default.nix
index e6dd48018e745..06ff5f3909dcc 100644
--- a/pkgs/applications/audio/squishyball/default.nix
+++ b/pkgs/applications/audio/squishyball/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoreconfHook, fetchsvn, flac, libao, libvorbis, ncurses
+{ lib, stdenv, autoreconfHook, fetchsvn, flac, libao, libvorbis, ncurses
 , opusfile, pkgconfig
 }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     cp squishyball.1 $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to perform sample comparison testing on the command line";
     longDescription = ''
        squishyball is a simple command-line utility for performing
diff --git a/pkgs/applications/audio/ssrc/default.nix b/pkgs/applications/audio/ssrc/default.nix
index 9d519e14147b2..3516c6e4db0cd 100644
--- a/pkgs/applications/audio/ssrc/default.nix
+++ b/pkgs/applications/audio/ssrc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "ssrc";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp ssrc ssrc_hp $out/bin
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high quality audio sampling rate converter";
     longDescription = ''
       This program converts sampling rates of PCM wav files. This
diff --git a/pkgs/applications/audio/stochas/default.nix b/pkgs/applications/audio/stochas/default.nix
index 402d3f1b6fa2b..0c50cda8e6c0e 100644
--- a/pkgs/applications/audio/stochas/default.nix
+++ b/pkgs/applications/audio/stochas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, libX11, libXrandr, libXinerama, libXext, libXcursor, freetype, alsaLib, libjack2 }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, libX11, libXrandr, libXinerama, libXext, libXcursor, freetype, alsaLib, libjack2 }:
 
 stdenv.mkDerivation rec {
   pname = "stochas";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp -r stochas_artefacts/Release/VST3/Stochas.vst3 $out/lib/vst3
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Probabilistic polyrhythmic sequencer plugin";
     homepage = "https://stochas.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/stone-phaser/default.nix b/pkgs/applications/audio/stone-phaser/default.nix
index d36b28df978a7..7fb4a5410fb46 100644
--- a/pkgs/applications/audio/stone-phaser/default.nix
+++ b/pkgs/applications/audio/stone-phaser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, cairo, lv2, libjack2, mesa, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, xorg, cairo, lv2, libjack2, mesa, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "stone-phaser";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jpcima/stone-phaser";
     description = "A classic analog phaser effect, made with DPF and Faust";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/streamripper/default.nix b/pkgs/applications/audio/streamripper/default.nix
index 1411fe59b30fd..7d21e816667fd 100644
--- a/pkgs/applications/audio/streamripper/default.nix
+++ b/pkgs/applications/audio/streamripper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl , glib, pkgconfig, libogg, libvorbis, libmad }:
+{ lib, stdenv, fetchurl , glib, pkgconfig, libogg, libvorbis, libmad }:
 
 stdenv.mkDerivation rec {
   pname = "streamripper";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ glib libogg libvorbis libmad ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://streamripper.sourceforge.net/";
     description = "Application that lets you record streaming mp3 to your hard drive";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/string-machine/default.nix b/pkgs/applications/audio/string-machine/default.nix
index 67053baa35fff..a146ea8cd977a 100644
--- a/pkgs/applications/audio/string-machine/default.nix
+++ b/pkgs/applications/audio/string-machine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, cairo, lv2, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, boost, cairo, lv2, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "string-machine";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "PREFIX=$(out)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jpcima/string-machine";
     description = "Digital model of electronic string ensemble instrument";
     maintainers = [ maintainers.magnetophon ];
diff --git a/pkgs/applications/audio/sunvox/default.nix b/pkgs/applications/audio/sunvox/default.nix
index 1b3b476d70373..12397f2fdbffa 100644
--- a/pkgs/applications/audio/sunvox/default.nix
+++ b/pkgs/applications/audio/sunvox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, alsaLib, libX11, libXi, SDL2 }:
+{ lib, stdenv, fetchurl, unzip, alsaLib, libX11, libXi, SDL2 }:
 
 let
   libPath = stdenv.lib.makeLibraryPath [ stdenv.cc.cc alsaLib libX11 libXi SDL2 ];
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     ln -s "$bin" $out/bin/sunvox
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small, fast and powerful modular synthesizer with pattern-based sequencer";
     license = licenses.unfreeRedistributable;
     homepage = "http://www.warmplace.ru/soft/sunvox/";
diff --git a/pkgs/applications/audio/surge/default.nix b/pkgs/applications/audio/surge/default.nix
index 1614bbfae6678..831253246947f 100644
--- a/pkgs/applications/audio/surge/default.nix
+++ b/pkgs/applications/audio/surge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, git, pkg-config, python3
+{ lib, stdenv, fetchFromGitHub, cmake, git, pkg-config, python3
 , cairo, libsndfile, libxcb, libxkbcommon, xcbutil, xcbutilcursor, xcbutilkeysyms, zenity
 }:
 
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     build/surge-headless
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LV2 & VST3 synthesizer plug-in (previously released as Vember Audio Surge)";
     homepage = "https://surge-synthesizer.github.io";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/svox/default.nix b/pkgs/applications/audio/svox/default.nix
index d5b67819cb070..044fd176481f9 100644
--- a/pkgs/applications/audio/svox/default.nix
+++ b/pkgs/applications/audio/svox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, popt }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, popt }:
 
 stdenv.mkDerivation {
   pname = "svox";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Text-to-speech engine";
     homepage = "https://android.googlesource.com/platform/external/svox";
     platforms = platforms.linux;
diff --git a/pkgs/applications/audio/swh-lv2/default.nix b/pkgs/applications/audio/swh-lv2/default.nix
index 02499d54476f1..ccec7b9171f81 100644
--- a/pkgs/applications/audio/swh-lv2/default.nix
+++ b/pkgs/applications/audio/swh-lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fftwSinglePrec, libxslt, lv2, pkgconfig }:
+{ lib, stdenv, fetchurl, fftwSinglePrec, libxslt, lv2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "swh-lv2";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "make install-system";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://plugin.org.uk";
     description = "LV2 version of Steve Harris' SWH plugins";
     longDescription = ''
diff --git a/pkgs/applications/audio/synthv1/default.nix b/pkgs/applications/audio/synthv1/default.nix
index 74f68283fd60d..f10b20bfc3c05 100644
--- a/pkgs/applications/audio/synthv1/default.nix
+++ b/pkgs/applications/audio/synthv1/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, pkgconfig, qtbase, qttools, libjack2, alsaLib, liblo, lv2 }:
+{ mkDerivation, lib, stdenv, fetchurl, pkgconfig, qtbase, qttools, libjack2, alsaLib, liblo, lv2 }:
 
 mkDerivation rec {
   pname = "synthv1";
@@ -13,7 +13,7 @@ mkDerivation rec {
 
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An old-school 4-oscillator subtractive polyphonic synthesizer with stereo fx";
     homepage = "https://synthv1.sourceforge.io/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/talentedhack/default.nix b/pkgs/applications/audio/talentedhack/default.nix
index b30cf59f7b30e..0dd9a03739dfc 100644
--- a/pkgs/applications/audio/talentedhack/default.nix
+++ b/pkgs/applications/audio/talentedhack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, lv2, fftwFloat, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, lv2, fftwFloat, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "talentedhack";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     cp *.so *.ttl $d
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jeremysalwen/TalentedHack";
     description = "LV2 port of Autotalent pitch correction plugin";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/tambura/default.nix b/pkgs/applications/audio/tambura/default.nix
index 96f9bb7053e0b..b1a6513c7f738 100644
--- a/pkgs/applications/audio/tambura/default.nix
+++ b/pkgs/applications/audio/tambura/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, faust2jaqt, faust2lv2 }:
+{ lib, stdenv, fetchFromGitHub, faust2jaqt, faust2lv2 }:
 stdenv.mkDerivation rec {
   pname = "Tambura";
   version = "1.0";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp -r ${pname}.lv2/ $out/lib/lv2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A FAUST patch inspired by the Indian Tambura/Tanpura - a four string drone instrument, known for its unique rich harmonic timbre";
     homepage = "https://github.com/olilarkin/Tambura";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/tamgamp.lv2/default.nix b/pkgs/applications/audio/tamgamp.lv2/default.nix
index 9f51f9d022d8f..2907a5277ee29 100644
--- a/pkgs/applications/audio/tamgamp.lv2/default.nix
+++ b/pkgs/applications/audio/tamgamp.lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, lv2, zita-resampler }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, lv2, zita-resampler }:
 
 stdenv.mkDerivation rec {
   pname = "tamgamp.lv2";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sadko4u/tamgamp.lv2";
     description = "Guitar amplifier simulator";
     longDescription = ''
diff --git a/pkgs/applications/audio/tetraproc/default.nix b/pkgs/applications/audio/tetraproc/default.nix
index 8780e54bb7c33..1fe56096e9519 100644
--- a/pkgs/applications/audio/tetraproc/default.nix
+++ b/pkgs/applications/audio/tetraproc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper
+{ lib, stdenv, fetchurl, makeWrapper
 , expat, fftwFloat, fontconfig, freetype, libjack2, jack2Full, libclthreads, libclxclient
 , libsndfile, libxcb, xorg
 }:
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/tetraproc --prefix PATH : "${jack2Full}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts the A-format signals from a tetrahedral Ambisonic microphone into B-format signals ready for recording";
     homepage = "http://kokkinizita.linuxaudio.org/linuxaudio/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/tony/default.nix b/pkgs/applications/audio/tony/default.nix
index 011d802536477..8d3ba620f9dc3 100644
--- a/pkgs/applications/audio/tony/default.nix
+++ b/pkgs/applications/audio/tony/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, wrapQtAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, wrapQtAppsHook
 , alsaLib, boost, bzip2, fftw, fftwFloat, libX11, libfishsound, libid3tag
 , libjack2, liblo, libmad, libogg, liboggz, libpulseaudio, libsamplerate
 , libsndfile, lrdf, opusfile, qtbase, qtsvg, rubberband, serd, sord
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pitch and note annotation of unaccompanied melody";
     homepage = "https://www.sonicvisualiser.org/tony/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/transcode/default.nix b/pkgs/applications/audio/transcode/default.nix
index c7ee3914f25cc..cc3c8c7a0f0a9 100644
--- a/pkgs/applications/audio/transcode/default.nix
+++ b/pkgs/applications/audio/transcode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, flac, lame, zlib, libjpeg, libvorbis, libtheora, libxml2
+{ lib, stdenv, fetchurl, flac, lame, zlib, libjpeg, libvorbis, libtheora, libxml2
 , lzo, libdvdread, pkgconfig, x264, libmpeg2, xvidcore }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Suite of command line utilities for transcoding video and audio codecs, and for converting between different container formats";
     homepage = "http://www.transcoding.org/";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/applications/audio/traverso/default.nix b/pkgs/applications/audio/traverso/default.nix
index 94bce19b7e1a0..f9395ec6fa2b8 100644
--- a/pkgs/applications/audio/traverso/default.nix
+++ b/pkgs/applications/audio/traverso/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, cmake, pkgconfig
+{ mkDerivation, lib, stdenv, fetchurl, cmake, pkgconfig
 , alsaLib, fftw, flac, lame, libjack2, libmad, libpulseaudio
 , libsamplerate, libsndfile, libvorbis, portaudio, qtbase, wavpack
 }:
@@ -20,7 +20,7 @@ mkDerivation {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform multitrack audio recording and audio editing suite";
     homepage = "https://traverso-daw.org/";
     license = with licenses; [ gpl2Plus lgpl21Plus ];
diff --git a/pkgs/applications/audio/tree-from-tags/default.nix b/pkgs/applications/audio/tree-from-tags/default.nix
index 3b25b4218f19f..4bf4db09ac077 100644
--- a/pkgs/applications/audio/tree-from-tags/default.nix
+++ b/pkgs/applications/audio/tree-from-tags/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bundlerEnv, ruby, fetchFromGitHub }:
+{ lib, stdenv, bundlerEnv, ruby, fetchFromGitHub }:
 let
   version = "1.1";
   gems = bundlerEnv {
@@ -28,7 +28,7 @@ EOF
     chmod +x $bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create file hierarchies from media tags";
     homepage = "https://www.emacswiki.org/emacs/Bongo";
     platforms = ruby.meta.platforms;
diff --git a/pkgs/applications/audio/tunefish/default.nix b/pkgs/applications/audio/tunefish/default.nix
index 72802c4f87840..6dc1eb3396276 100644
--- a/pkgs/applications/audio/tunefish/default.nix
+++ b/pkgs/applications/audio/tunefish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, python3
+{ lib, stdenv, fetchFromGitHub, pkg-config, python3
 , alsaLib, curl, freetype, gtk3, libGL, libX11, libXext, libXinerama, webkitgtk
 }:
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tunefish-synth.com/";
     description = "Virtual analog synthesizer LV2 plugin";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/uade123/default.nix b/pkgs/applications/audio/uade123/default.nix
index 9130461e4d728..09e066dadac70 100644
--- a/pkgs/applications/audio/uade123/default.nix
+++ b/pkgs/applications/audio/uade123/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, libao, pkgconfig }:
+{ lib, stdenv, fetchurl, which, libao, pkgconfig }:
 
 let
   version = "2.13";
@@ -15,7 +15,7 @@ in stdenv.mkDerivation {
   enableParallelBuilding = true;
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plays old Amiga tunes through UAE emulation and cloned m68k-assembler Eagleplayer API";
     homepage = "http://zakalwe.fi/uade/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/uhhyou.lv2/default.nix b/pkgs/applications/audio/uhhyou.lv2/default.nix
index 732e9d8433f64..9c748929d6252 100644
--- a/pkgs/applications/audio/uhhyou.lv2/default.nix
+++ b/pkgs/applications/audio/uhhyou.lv2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , python3
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Audio plugins for Linux";
     longDescription = ''
       Plugin List:
diff --git a/pkgs/applications/audio/vcv-rack/default.nix b/pkgs/applications/audio/vcv-rack/default.nix
index a94cfd3a7cc3f..27844841482c4 100644
--- a/pkgs/applications/audio/vcv-rack/default.nix
+++ b/pkgs/applications/audio/vcv-rack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, fetchzip, fetchFromGitHub, pkgconfig
+{ lib, stdenv, makeWrapper, fetchzip, fetchFromGitHub, pkgconfig
 , alsaLib, curl, glew, glfw, gtk2-x11, jansson, libjack2, libXext, libXi
 , libzip, rtaudio, rtmidi, speex, libsamplerate }:
 
@@ -89,7 +89,7 @@ with stdenv.lib; stdenv.mkDerivation rec {
     wrapProgram $out/bin/Rack --add-flags "-s $out/share/vcv-rack"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open-source virtual modular synthesizer";
     homepage = "https://vcvrack.com/";
     # The source is BSD-3 licensed, some of the art is CC-BY-NC 4.0 or under a
diff --git a/pkgs/applications/audio/vimpc/default.nix b/pkgs/applications/audio/vimpc/default.nix
index bcbfa6d3874f4..b0412005aba21 100644
--- a/pkgs/applications/audio/vimpc/default.nix
+++ b/pkgs/applications/audio/vimpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, mpd_clientlib, ncurses, pcre, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, mpd_clientlib, ncurses, pcre, pkgconfig
 , taglib, curl }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp doc/vimpcrc.example $out/etc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A vi/vim inspired client for the Music Player Daemon (mpd)";
     homepage = "https://github.com/boysetsfrog/vimpc";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/virtual-ans/default.nix b/pkgs/applications/audio/virtual-ans/default.nix
index 24e112aff2b4f..dd7e8b062da72 100644
--- a/pkgs/applications/audio/virtual-ans/default.nix
+++ b/pkgs/applications/audio/virtual-ans/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchzip
 , libX11
 , libXi
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     else            if stdenv.isx86_64 then "pixilang_linux_x86_64"
     else                                    "";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Photoelectronic microtonal/spectral musical instrument";
     longDescription = ''
       Virtual ANS is a software simulator of the unique Russian synthesizer ANS
diff --git a/pkgs/applications/audio/vkeybd/default.nix b/pkgs/applications/audio/vkeybd/default.nix
index 0e8f12823d1e4..3409d8a490708 100644
--- a/pkgs/applications/audio/vkeybd/default.nix
+++ b/pkgs/applications/audio/vkeybd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, libX11, makeWrapper, tcl, tk }:
+{ lib, stdenv, fetchurl, alsaLib, libX11, makeWrapper, tcl, tk }:
 
 stdenv.mkDerivation  rec {
   pname = "vkeybd";
@@ -22,7 +22,7 @@ stdenv.mkDerivation  rec {
     wrapProgram $out/bin/vkeybd --set TK_LIBRARY "${tk}/lib/${tk.libPrefix}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Virtual MIDI keyboard";
     homepage = "https://www.alsa-project.org/~tiwai/alsa.html";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/vocal/default.nix b/pkgs/applications/audio/vocal/default.nix
index b519003a9ec95..fb1046aab52e8 100644
--- a/pkgs/applications/audio/vocal/default.nix
+++ b/pkgs/applications/audio/vocal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , cmake
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The podcast client for the modern free desktop";
     longDescription = ''
       Vocal is a powerful, fast, and intuitive application that helps users find new podcasts, manage their libraries, and enjoy the best that indepedent audio and video publishing has to offer. Vocal features full support for both episode downloading and streaming, native system integration, iTunes store search and top 100 charts (with international results support), iTunes link parsing, OPML importing and exporting, and so much more. Plus, it has great smart features like automatically keeping your library clean from old files, and the ability to set custom skip intervals.
diff --git a/pkgs/applications/audio/vocproc/default.nix b/pkgs/applications/audio/vocproc/default.nix
index ddaa5b790e274..dce4ed36aac1b 100644
--- a/pkgs/applications/audio/vocproc/default.nix
+++ b/pkgs/applications/audio/vocproc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, pkgconfig, lvtk, lv2, fftw, lv2-cpp-tools, gtkmm2 }:
+{ lib, stdenv, fetchzip, pkgconfig, lvtk, lv2, fftw, lv2-cpp-tools, gtkmm2 }:
 
 stdenv.mkDerivation rec {
   pname = "vocproc";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     "INSTALL_DIR=$(out)/lib/lv2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://hyperglitch.com/dev/VocProc";
     description = "An LV2 plugin for pitch shifting (with or without formant correction), vocoding, automatic pitch correction and harmonizing of singing voice (harmonizer)";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/vorbis-tools/default.nix b/pkgs/applications/audio/vorbis-tools/default.nix
index 2270e56e62ac3..b50912f26d756 100644
--- a/pkgs/applications/audio/vorbis-tools/default.nix
+++ b/pkgs/applications/audio/vorbis-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchzip, libogg, libvorbis, libao, pkgconfig, curl
+{ lib, stdenv, fetchurl, fetchzip, libogg, libvorbis, libao, pkgconfig, curl
 , speex, flac }:
 
 let
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libogg libvorbis libao curl speex flac ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extra tools for Ogg-Vorbis audio codec";
     longDescription = ''
       A set of command-line tools to manipulate Ogg Vorbis audio
diff --git a/pkgs/applications/audio/waon/default.nix b/pkgs/applications/audio/waon/default.nix
index bc05547e641d2..78e4fb1a5c551 100644
--- a/pkgs/applications/audio/waon/default.nix
+++ b/pkgs/applications/audio/waon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fftw, gtk2, libao, libsamplerate
+{ lib, stdenv, fetchFromGitHub, fftw, gtk2, libao, libsamplerate
 , libsndfile, ncurses, pkgconfig
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -Dt $out/bin waon pv gwaon
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Wave-to-Notes transcriber";
     homepage = "https://kichiki.github.io/WaoN/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/audio/whipper/default.nix b/pkgs/applications/audio/whipper/default.nix
index 3ff1368c9432b..227091dd58198 100644
--- a/pkgs/applications/audio/whipper/default.nix
+++ b/pkgs/applications/audio/whipper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, cdparanoia, cdrdao, flac
+{ lib, stdenv, fetchFromGitHub, python3, cdparanoia, cdrdao, flac
 , sox, accuraterip-checksum, libsndfile, util-linux, substituteAll }:
 
 python3.pkgs.buildPythonApplication rec {
@@ -52,7 +52,7 @@ python3.pkgs.buildPythonApplication rec {
     HOME=$TMPDIR
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/whipper-team/whipper";
     description = "A CD ripper aiming for accuracy over speed";
     maintainers = with maintainers; [ rycee emily ];
diff --git a/pkgs/applications/audio/wolf-shaper/default.nix b/pkgs/applications/audio/wolf-shaper/default.nix
index ca16d60bea883..e724e934e52bd 100644
--- a/pkgs/applications/audio/wolf-shaper/default.nix
+++ b/pkgs/applications/audio/wolf-shaper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , libjack2, lv2, xorg, liblo, libGL, libXcursor, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub , libjack2, lv2, xorg, liblo, libGL, libXcursor, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "wolf-shaper";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     cp -r bin/wolf-shaper        $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pdesaulniers.github.io/wolf-shaper/";
     description = "Waveshaper plugin with spline-based graph editor";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/x42-avldrums/default.nix b/pkgs/applications/audio/x42-avldrums/default.nix
index fb05a50b4e594..b2b9a4c233d17 100644
--- a/pkgs/applications/audio/x42-avldrums/default.nix
+++ b/pkgs/applications/audio/x42-avldrums/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, cairo, glib, libGLU, lv2, pango }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, cairo, glib, libGLU, lv2, pango }:
 
 stdenv.mkDerivation rec {
   pname = "x42-avldrums";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Drum sample player LV2 plugin dedicated to Glen MacArthur's AVLdrums";
     homepage = "https://x42-plugins.com/x42/x42-avldrums";
     maintainers = with maintainers; [ magnetophon orivej ];
diff --git a/pkgs/applications/audio/x42-gmsynth/default.nix b/pkgs/applications/audio/x42-gmsynth/default.nix
index 7a96e3fd4f2f8..dad6d05f90400 100644
--- a/pkgs/applications/audio/x42-gmsynth/default.nix
+++ b/pkgs/applications/audio/x42-gmsynth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, glib, lv2 }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, glib, lv2 }:
 
 stdenv.mkDerivation rec {
   pname = "x42-gmsynth";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chris Colins' General User soundfont player LV2 plugin";
     homepage = "https://x42-plugins.com/x42/x42-gmsynth";
     maintainers = with maintainers; [ orivej ];
diff --git a/pkgs/applications/audio/xmp/default.nix b/pkgs/applications/audio/xmp/default.nix
index d234f6b6b8ccf..d38faa6925dcd 100644
--- a/pkgs/applications/audio/xmp/default.nix
+++ b/pkgs/applications/audio/xmp/default.nix
@@ -1,9 +1,9 @@
-{ stdenv, fetchurl, pkgconfig, alsaLib, libxmp }:
+{ lib, stdenv, fetchurl, pkgconfig, alsaLib, libxmp }:
 
 stdenv.mkDerivation rec {
   name = "xmp-4.1.0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extended module player";
     homepage    = "http://xmp.sourceforge.net/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/xsynth-dssi/default.nix b/pkgs/applications/audio/xsynth-dssi/default.nix
index c0803ffa41857..e8f6bd94bb4b9 100644
--- a/pkgs/applications/audio/xsynth-dssi/default.nix
+++ b/pkgs/applications/audio/xsynth-dssi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, autoconf, automake, dssi, gtk2, libjack2,
+{ lib, stdenv, fetchurl, alsaLib, autoconf, automake, dssi, gtk2, libjack2,
 ladspaH, ladspaPlugins, liblo, pkgconfig }:
 
 stdenv.mkDerivation  rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation  rec {
     cp src/.libs/* $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Classic-analog (VCOs-VCF-VCA) style software synthesizer";
     longDescription = ''
       Xsynth-DSSI is a classic-analog (VCOs-VCF-VCA) style software
diff --git a/pkgs/applications/audio/xtuner/default.nix b/pkgs/applications/audio/xtuner/default.nix
index 57ce3ab151144..c51852179114b 100644
--- a/pkgs/applications/audio/xtuner/default.nix
+++ b/pkgs/applications/audio/xtuner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , cairo
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brummer10/XTuner";
     description = "Tuner for Jack Audio Connection Kit";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/yoshimi/default.nix b/pkgs/applications/audio/yoshimi/default.nix
index 2b0a89bbaf5be..7f5b0e8d008a3 100644
--- a/pkgs/applications/audio/yoshimi/default.nix
+++ b/pkgs/applications/audio/yoshimi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , alsaLib, boost, cairo, cmake, fftwSinglePrec, fltk, pcre
+{ lib, stdenv, fetchFromGitHub , alsaLib, boost, cairo, cmake, fftwSinglePrec, fltk, pcre
 , libjack2, libsndfile, libXdmcp, readline, lv2, libGLU, libGL, minixml, pkgconfig, zlib, xorg
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation  rec {
 
   cmakeFlags = [ "-DFLTK_MATH_LIBRARY=${stdenv.glibc.out}/lib/libm.so" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High quality software synthesizer based on ZynAddSubFX";
     longDescription = ''
       Yoshimi delivers the same synthesizer capabilities as
diff --git a/pkgs/applications/audio/zam-plugins/default.nix b/pkgs/applications/audio/zam-plugins/default.nix
index edcc70f9912f1..82993ec2673bb 100644
--- a/pkgs/applications/audio/zam-plugins/default.nix
+++ b/pkgs/applications/audio/zam-plugins/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, libX11, libGL, liblo, libjack2, ladspaH, lv2, pkgconfig, rubberband, libsndfile, fftwFloat, libsamplerate }:
+{ lib, stdenv, fetchFromGitHub, boost, libX11, libGL, liblo, libjack2, ladspaH, lv2, pkgconfig, rubberband, libsndfile, fftwFloat, libsamplerate }:
 
 stdenv.mkDerivation rec {
   pname = "zam-plugins";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.zamaudio.com/?p=976";
     description = "A collection of LV2/LADSPA/VST/JACK audio plugins by ZamAudio";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/audio/zita-ajbridge/default.nix b/pkgs/applications/audio/zita-ajbridge/default.nix
index ad2ea53e9f7e1..4b094864607ce 100644
--- a/pkgs/applications/audio/zita-ajbridge/default.nix
+++ b/pkgs/applications/audio/zita-ajbridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, libjack2, zita-alsa-pcmi, zita-resampler }:
+{ lib, stdenv, fetchurl, alsaLib, libjack2, zita-alsa-pcmi, zita-resampler }:
 
 stdenv.mkDerivation rec {
   name = "zita-ajbridge-0.8.4";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Connect additional ALSA devices to JACK";
     homepage = "http://kokkinizita.linuxaudio.org/linuxaudio/index.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/zita-at1/default.nix b/pkgs/applications/audio/zita-at1/default.nix
index d357febd882e3..7a66ed42b0538 100644
--- a/pkgs/applications/audio/zita-at1/default.nix
+++ b/pkgs/applications/audio/zita-at1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , cairo, fftwSinglePrec, libX11, libXft, libclthreads, libclxclient, libjack2
 , xorgproto, zita-resampler
 }:
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Autotuner Jack application to correct the pitch of vocal tracks";
     homepage = "https://kokkinizita.linuxaudio.org/linuxaudio/index.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/audio/zita-njbridge/default.nix b/pkgs/applications/audio/zita-njbridge/default.nix
index 3a293cfc026f4..142f9bc4d09b2 100644
--- a/pkgs/applications/audio/zita-njbridge/default.nix
+++ b/pkgs/applications/audio/zita-njbridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libjack2, zita-resampler }:
+{ lib, stdenv, fetchurl, libjack2, zita-resampler }:
 
 stdenv.mkDerivation rec {
   version = "0.4.4";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
   ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "command line Jack clients to transmit full quality multichannel audio over a local IP network";
     homepage = "http://kokkinizita.linuxaudio.org/linuxaudio/index.html";
     license = licenses.gpl3;
diff --git a/pkgs/applications/audio/zynaddsubfx/mruby-zest/default.nix b/pkgs/applications/audio/zynaddsubfx/mruby-zest/default.nix
index 0f00e6244d1d6..0096cc97ddbde 100644
--- a/pkgs/applications/audio/zynaddsubfx/mruby-zest/default.nix
+++ b/pkgs/applications/audio/zynaddsubfx/mruby-zest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , bison
 , git
@@ -99,7 +99,7 @@ stdenv.mkDerivation rec {
     touch "$out/qml/MainWindow.qml"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Zest Framework used in ZynAddSubFX's UI";
     homepage = "https://github.com/mruby-zest";
     license = licenses.lgpl21;
diff --git a/pkgs/applications/backup/areca/default.nix b/pkgs/applications/backup/areca/default.nix
index b4d644430dd19..2cf0113cb5aba 100644
--- a/pkgs/applications/backup/areca/default.nix
+++ b/pkgs/applications/backup/areca/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ant, jre, jdk, swt, acl, attr }:
+{ lib, stdenv, fetchurl, ant, jre, jdk, swt, acl, attr }:
 
 stdenv.mkDerivation {
   name = "areca-7.5";
@@ -44,7 +44,7 @@ stdenv.mkDerivation {
     cp COPYING $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.areca-backup.org/";
     description = "An Open Source personal backup solution";
     license = licenses.gpl2;
diff --git a/pkgs/applications/backup/deja-dup/default.nix b/pkgs/applications/backup/deja-dup/default.nix
index d6ce864d6523a..4ab491cb9a9d4 100644
--- a/pkgs/applications/backup/deja-dup/default.nix
+++ b/pkgs/applications/backup/deja-dup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , substituteAll
 , meson
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
     "-Dduplicity_command=${duplicity}/bin/duplicity"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple backup tool";
     longDescription = ''
       Déjà Dup is a simple backup tool. It hides the complexity \
diff --git a/pkgs/applications/backup/vdmfec/default.nix b/pkgs/applications/backup/vdmfec/default.nix
index 1366bb484a913..2f9b4a4bfaea2 100644
--- a/pkgs/applications/backup/vdmfec/default.nix
+++ b/pkgs/applications/backup/vdmfec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "vdmfec";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0i7q4ylx2xmzzq778anpkj4nqir5gf573n1lbpxnbc10ymsjq2rm";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program that adds error correction blocks";
     homepage = "http://members.tripod.com/professor_tom/archives/index.html";
     maintainers = [ maintainers.ar1a ];
diff --git a/pkgs/applications/blockchains/aeon/default.nix b/pkgs/applications/blockchains/aeon/default.nix
index 5e0c25466ebef..b9c8512ae1361 100644
--- a/pkgs/applications/blockchains/aeon/default.nix
+++ b/pkgs/applications/blockchains/aeon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, git, doxygen, graphviz
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, git, doxygen, graphviz
 , boost, miniupnpc, openssl, unbound, cppzmq
 , zeromq, pcsclite, readline, libsodium
 }:
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "fortify" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Private, secure, untraceable currency";
     homepage = "http://www.aeon.cash/";
     license = licenses.bsd3;
diff --git a/pkgs/applications/blockchains/bitcoin-knots.nix b/pkgs/applications/blockchains/bitcoin-knots.nix
index dd0132df4d941..a7fb005ea816f 100644
--- a/pkgs/applications/blockchains/bitcoin-knots.nix
+++ b/pkgs/applications/blockchains/bitcoin-knots.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , autoreconfHook
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
   configureFlags = [ "--with-incompatible-bdb"
                      "--with-boost-libdir=${boost.out}/lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An enhanced Bitcoin node software";
     homepage = "https://bitcoinknots.org/";
     license = licenses.mit;
diff --git a/pkgs/applications/blockchains/cgminer/default.nix b/pkgs/applications/blockchains/cgminer/default.nix
index 966303ec5a651..b7d9bcd583a23 100644
--- a/pkgs/applications/blockchains/cgminer/default.nix
+++ b/pkgs/applications/blockchains/cgminer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , libtool
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
                      "--enable-keccak"
                      "--enable-bflsc"];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CPU/GPU miner in c for bitcoin";
     homepage = "https://github.com/ckolivas/cgminer";
     license = licenses.gpl3;
diff --git a/pkgs/applications/blockchains/ergo/default.nix b/pkgs/applications/blockchains/ergo/default.nix
index 6b686d0b2d6c8..3c5bc5ea5ced4 100644
--- a/pkgs/applications/blockchains/ergo/default.nix
+++ b/pkgs/applications/blockchains/ergo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 stdenv.mkDerivation rec {
   pname = "ergo";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/ergo --add-flags "-jar $src"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open protocol that implements modern scientific ideas in the blockchain area";
     homepage = "https://ergoplatform.org/en/";
     license = licenses.cc0;
diff --git a/pkgs/applications/blockchains/ethabi.nix b/pkgs/applications/blockchains/ethabi.nix
index ad574c82b4649..ec142cc723ef1 100644
--- a/pkgs/applications/blockchains/ethabi.nix
+++ b/pkgs/applications/blockchains/ethabi.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "ethabi";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1hx8qw51rl7sn9jmnclw0hc4rx619hf78hpaih5mvny3k0zgiwpm";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ethereum function call encoding (ABI) utility";
     homepage = "https://github.com/ethcore/ethabi/";
     maintainers = [ maintainers.dbrock ];
diff --git a/pkgs/applications/blockchains/exodus/default.nix b/pkgs/applications/blockchains/exodus/default.nix
index 3992c78248511..ae1286a384fff 100644
--- a/pkgs/applications/blockchains/exodus/default.nix
+++ b/pkgs/applications/blockchains/exodus/default.nix
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
       $out/Exodus
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.exodus.io/";
     description = "Top-rated cryptocurrency wallet with Trezor integration and built-in Exchange";
     license = licenses.unfree;
diff --git a/pkgs/applications/blockchains/go-ethereum.nix b/pkgs/applications/blockchains/go-ethereum.nix
index 24f58a6c2c34d..3fc3a9109c5ae 100644
--- a/pkgs/applications/blockchains/go-ethereum.nix
+++ b/pkgs/applications/blockchains/go-ethereum.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, libobjc, IOKit }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, libobjc, IOKit }:
 
 buildGoModule rec {
   pname = "go-ethereum";
@@ -37,7 +37,7 @@ buildGoModule rec {
   propagatedBuildInputs =
     stdenv.lib.optionals stdenv.isDarwin [ libobjc IOKit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://geth.ethereum.org/";
     description = "Official golang implementation of the Ethereum protocol";
     license = with licenses; [ lgpl3 gpl3 ];
diff --git a/pkgs/applications/blockchains/ledger-live-desktop/default.nix b/pkgs/applications/blockchains/ledger-live-desktop/default.nix
index bb2fc89339933..54805f2512fec 100644
--- a/pkgs/applications/blockchains/ledger-live-desktop/default.nix
+++ b/pkgs/applications/blockchains/ledger-live-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, appimageTools, imagemagick }:
+{ lib, stdenv, fetchurl, makeDesktopItem, appimageTools, imagemagick }:
 
 let
   pname = "ledger-live-desktop";
@@ -26,7 +26,7 @@ in appimageTools.wrapType2 rec {
       --replace 'Exec=AppRun' 'Exec=${pname}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wallet app for Ledger Nano S and Ledger Blue";
     homepage = "https://www.ledger.com/live";
     license = licenses.mit;
diff --git a/pkgs/applications/blockchains/monero/default.nix b/pkgs/applications/blockchains/monero/default.nix
index d45f5a2e5ca69..9d1761ab44652 100644
--- a/pkgs/applications/blockchains/monero/default.nix
+++ b/pkgs/applications/blockchains/monero/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , cmake, pkgconfig
 , boost, miniupnpc, openssl, unbound
 , zeromq, pcsclite, readline, libsodium, hidapi
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "source" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Private, secure, untraceable currency";
     homepage    = "https://getmonero.org/";
     license     = licenses.bsd3;
diff --git a/pkgs/applications/blockchains/parity-ui/default.nix b/pkgs/applications/blockchains/parity-ui/default.nix
index b18c121607abd..43b933d3e6aec 100644
--- a/pkgs/applications/blockchains/parity-ui/default.nix
+++ b/pkgs/applications/blockchains/parity-ui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgs, fetchurl, makeWrapper, nodePackages }:
+{ lib, stdenv, pkgs, fetchurl, makeWrapper, nodePackages }:
 
 let
 
@@ -38,7 +38,7 @@ in stdenv.mkDerivation rec {
     ln -s $out/share/parity-ui/parity-ui $out/bin/parity-ui
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "UI for Parity. Fast, light, robust Ethereum implementation";
     homepage = "http://parity.io";
     license = licenses.gpl3;
diff --git a/pkgs/applications/blockchains/pivx.nix b/pkgs/applications/blockchains/pivx.nix
index eb4651e586e29..dc80df74a455e 100644
--- a/pkgs/applications/blockchains/pivx.nix
+++ b/pkgs/applications/blockchains/pivx.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, pkgconfig, autoreconfHook, wrapQtAppsHook ? null
+{ fetchFromGitHub, lib, stdenv, pkgconfig, autoreconfHook, wrapQtAppsHook ? null
 , openssl, db48, boost, zlib, miniupnpc, gmp
 , qrencode, glib, protobuf, yasm, libevent
 , util-linux, qtbase ? null, qttools ? null
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     $out/bin/test_pivx
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source crypto-currency focused on fast private transactions";
     longDescription = ''
       PIVX is an MIT licensed, open source, blockchain-based cryptocurrency with
diff --git a/pkgs/applications/blockchains/quorum.nix b/pkgs/applications/blockchains/quorum.nix
index eb98777c587d9..499e2a77c6f68 100644
--- a/pkgs/applications/blockchains/quorum.nix
+++ b/pkgs/applications/blockchains/quorum.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage, git, which, removeReferencesTo, go }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage, git, which, removeReferencesTo, go }:
 
 buildGoPackage rec {
   pname = "quorum";
@@ -31,7 +31,7 @@ buildGoPackage rec {
     find $out -type f -exec ${removeReferencesTo}/bin/remove-references-to -t ${go} '{}' +
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A permissioned implementation of Ethereum supporting data privacy";
     homepage = "https://www.goquorum.com/";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/blockchains/stellar-core.nix b/pkgs/applications/blockchains/stellar-core.nix
index 6bb717a0344b0..925942c56e9b4 100644
--- a/pkgs/applications/blockchains/stellar-core.nix
+++ b/pkgs/applications/blockchains/stellar-core.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoconf, libtool, automake, pkgconfig, git
+{ lib, stdenv, fetchgit, autoconf, libtool, automake, pkgconfig, git
 , bison, flex, postgresql }:
 
 let
@@ -31,7 +31,7 @@ in stdenv.mkDerivation {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Implements the Stellar Consensus Protocol, a federated consensus protocol";
     longDescription = ''
       Stellar-core is the backbone of the Stellar network. It maintains a
diff --git a/pkgs/applications/blockchains/tessera.nix b/pkgs/applications/blockchains/tessera.nix
index 84f7925d21804..5b13925255342 100644
--- a/pkgs/applications/blockchains/tessera.nix
+++ b/pkgs/applications/blockchains/tessera.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 stdenv.mkDerivation rec {
   pname = "tessera";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/tessera --add-flags "-jar $src"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enterprise Implementation of Quorum's transaction manager";
     homepage = "https://github.com/jpmorganchase/tessera";
     license = licenses.asl20;
diff --git a/pkgs/applications/blockchains/turbo-geth.nix b/pkgs/applications/blockchains/turbo-geth.nix
index cf0b60ab9856e..acb0eafb95e89 100644
--- a/pkgs/applications/blockchains/turbo-geth.nix
+++ b/pkgs/applications/blockchains/turbo-geth.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "turbo-geth";
@@ -20,7 +20,7 @@ buildGoModule rec {
     "cmd/rpcdaemon"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ledgerwatch/turbo-geth/";
     description = "Ethereum node and geth fork focused on scalability and modularity";
     license = with licenses; [ lgpl3 gpl3 ];
diff --git a/pkgs/applications/blockchains/wasabibackend/default.nix b/pkgs/applications/blockchains/wasabibackend/default.nix
index 6b5358c9cf936..fd298debcb6f3 100644
--- a/pkgs/applications/blockchains/wasabibackend/default.nix
+++ b/pkgs/applications/blockchains/wasabibackend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchurl
 , makeWrapper
@@ -90,7 +90,7 @@ stdenv.mkDerivation rec {
   # If we don't disable stripping the executable fails to start with segfault
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Backend for the Wasabi Wallet";
     homepage = "https://wasabiwallet.io/";
     license = licenses.mit;
diff --git a/pkgs/applications/blockchains/wasabiwallet/default.nix b/pkgs/applications/blockchains/wasabiwallet/default.nix
index 4a0dbe83716ab..ae9c8fa3e8881 100644
--- a/pkgs/applications/blockchains/wasabiwallet/default.nix
+++ b/pkgs/applications/blockchains/wasabiwallet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeDesktopItem
 , curl
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     cp -v $desktopItem/share/applications/* $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Privacy focused Bitcoin wallet";
     homepage = "https://wasabiwallet.io/";
     license = licenses.mit;
diff --git a/pkgs/applications/blockchains/whirlpool-gui/default.nix b/pkgs/applications/blockchains/whirlpool-gui/default.nix
index 9a660bb8bffb8..3417f9b518568 100644
--- a/pkgs/applications/blockchains/whirlpool-gui/default.nix
+++ b/pkgs/applications/blockchains/whirlpool-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, callPackage, makeWrapper, makeDesktopItem
+{ lib, stdenv, fetchFromGitHub, callPackage, makeWrapper, makeDesktopItem
 , nodejs, yarn, electron_7, jre8, tor }:
 
 let
@@ -94,7 +94,7 @@ in stdenv.mkDerivation rec {
     outputHash = stdenv.lib.fakeSha256;
   });
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop GUI for Whirlpool by Samourai-Wallet";
     homepage = https://www.samouraiwallet.com/whirlpool;
     license = licenses.unlicense;
diff --git a/pkgs/applications/display-managers/lightdm-enso-os-greeter/default.nix b/pkgs/applications/display-managers/lightdm-enso-os-greeter/default.nix
index 488ef4cfedd47..43f5bcd495a67 100644
--- a/pkgs/applications/display-managers/lightdm-enso-os-greeter/default.nix
+++ b/pkgs/applications/display-managers/lightdm-enso-os-greeter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, pkgconfig, linkFarm, lightdm-enso-os-greeter
+{ lib, stdenv, fetchgit, pkgconfig, linkFarm, lightdm-enso-os-greeter
 , dbus, pcre, epoxy, libXdmcp, at-spi2-core, libxklavier, libxkbcommon, libpthreadstubs
 , gtk3, vala, cmake, libgee, libX11, lightdm, gdk-pixbuf, clutter-gtk, wrapGAppsHook, librsvg }:
 
@@ -55,7 +55,7 @@ stdenv.mkDerivation {
       --replace "pantheon-greeter" "$out/bin/pantheon-greeter"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A fork of pantheon greeter that positions elements in a central and
       vertigal manner and adds a blur effect to the background
diff --git a/pkgs/applications/display-managers/lightdm-mini-greeter/default.nix b/pkgs/applications/display-managers/lightdm-mini-greeter/default.nix
index 256ecd59f4e94..363e0503c2d6c 100644
--- a/pkgs/applications/display-managers/lightdm-mini-greeter/default.nix
+++ b/pkgs/applications/display-managers/lightdm-mini-greeter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, linkFarm, lightdm-mini-greeter, fetchFromGitHub, autoreconfHook, pkgconfig, lightdm, gtk3, glib, gdk-pixbuf, wrapGAppsHook, librsvg }:
+{ lib, stdenv, linkFarm, lightdm-mini-greeter, fetchFromGitHub, autoreconfHook, pkgconfig, lightdm, gtk3, glib, gdk-pixbuf, wrapGAppsHook, librsvg }:
 
 stdenv.mkDerivation rec {
   pname = "lightdm-mini-greeter";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     name = "lightdm-mini-greeter.desktop";
   }];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal, configurable, single-user GTK3 LightDM greeter";
     homepage = "https://github.com/prikhi/lightdm-mini-greeter";
     license = licenses.gpl3;
diff --git a/pkgs/applications/display-managers/lightdm-tiny-greeter/default.nix b/pkgs/applications/display-managers/lightdm-tiny-greeter/default.nix
index 7e37d1348749d..29dece3e5cf7e 100644
--- a/pkgs/applications/display-managers/lightdm-tiny-greeter/default.nix
+++ b/pkgs/applications/display-managers/lightdm-tiny-greeter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, linkFarm, lightdm-tiny-greeter, fetchFromGitHub
+{ lib, stdenv, linkFarm, lightdm-tiny-greeter, fetchFromGitHub
 , pkgconfig, lightdm, gtk3, glib, wrapGAppsHook, conf ? "" }:
 
 stdenv.mkDerivation rec {
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     name = "lightdm-tiny-greeter.desktop";
   }];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiny multi user lightdm greeter";
     homepage = "https://github.com/off-world/lightdm-tiny-greeter";
     license = licenses.bsd3;
diff --git a/pkgs/applications/display-managers/lightdm/gtk-greeter.nix b/pkgs/applications/display-managers/lightdm/gtk-greeter.nix
index a89e2b0711339..b25e087a211dc 100644
--- a/pkgs/applications/display-managers/lightdm/gtk-greeter.nix
+++ b/pkgs/applications/display-managers/lightdm/gtk-greeter.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , lightdm_gtk_greeter
 , fetchurl
 , lightdm
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     name = "lightdm-gtk-greeter.desktop";
   }];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/lightdm-gtk-greeter";
     platforms = platforms.linux;
     license = licenses.gpl3;
diff --git a/pkgs/applications/editors/amp/default.nix b/pkgs/applications/editors/amp/default.nix
index 9be6d56ab345c..54b3c646e2563 100644
--- a/pkgs/applications/editors/amp/default.nix
+++ b/pkgs/applications/editors/amp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, openssl, pkgconfig, python3, xorg, cmake, libgit2, darwin
+{ lib, stdenv, fetchFromGitHub, rustPlatform, openssl, pkgconfig, python3, xorg, cmake, libgit2, darwin
 , curl }:
 
 rustPlatform.buildRustPackage rec {
@@ -21,7 +21,7 @@ rustPlatform.buildRustPackage rec {
   # Tests need to write to the theme directory in HOME.
   preCheck = "export HOME=`mktemp -d`";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern text editor inspired by Vim";
     homepage = "https://amp.rs";
     license = [ licenses.gpl3 ];
diff --git a/pkgs/applications/editors/android-studio/common.nix b/pkgs/applications/editors/android-studio/common.nix
index cbd156d78e0ee..d8f2d86daee3a 100644
--- a/pkgs/applications/editors/android-studio/common.nix
+++ b/pkgs/applications/editors/android-studio/common.nix
@@ -41,6 +41,7 @@
 , pkgsi686Linux
 , ps
 , setxkbmap
+, lib
 , stdenv
 , systemd
 , unzip
@@ -182,7 +183,7 @@ in runCommand
     passthru = {
       unwrapped = androidStudio;
     };
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "The Official IDE for Android (${channel} channel)";
       longDescription = ''
         Android Studio is the official IDE for Android app development, based on
diff --git a/pkgs/applications/editors/apostrophe/default.nix b/pkgs/applications/editors/apostrophe/default.nix
index b3902293718e9..cb8e9b7e3bbcf 100644
--- a/pkgs/applications/editors/apostrophe/default.nix
+++ b/pkgs/applications/editors/apostrophe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, meson, ninja, cmake
+{ lib, stdenv, fetchFromGitLab, meson, ninja, cmake
 , wrapGAppsHook, pkgconfig, desktop-file-utils
 , appstream-glib, pythonPackages, glib, gobject-introspection
 , gtk3, webkitgtk, glib-networking, gnome3, gspell, texlive
@@ -46,7 +46,7 @@ in stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/somas/apostrophe";
     description = "A distraction free Markdown editor for GNU/Linux";
     license = licenses.gpl3;
diff --git a/pkgs/applications/editors/atom/default.nix b/pkgs/applications/editors/atom/default.nix
index 35640965c6fa9..9d1d8d4113ccc 100644
--- a/pkgs/applications/editors/atom/default.nix
+++ b/pkgs/applications/editors/atom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgs, fetchurl, wrapGAppsHook, gvfs, gtk3, atomEnv }:
+{ lib, stdenv, pkgs, fetchurl, wrapGAppsHook, gvfs, gtk3, atomEnv }:
 
 let
   versions = {
@@ -81,7 +81,7 @@ let
       sed -i -e "s|Exec=.*$|Exec=$out/bin/${pname}|" $out/share/applications/${pname}.desktop
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A hackable text editor for the 21st Century";
       homepage = "https://atom.io/";
       license = licenses.mit;
diff --git a/pkgs/applications/editors/bless/default.nix b/pkgs/applications/editors/bless/default.nix
index b3c3caae4e451..ab5f2ccc10417 100644
--- a/pkgs/applications/editors/bless/default.nix
+++ b/pkgs/applications/editors/bless/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkgconfig
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/bless --prefix MONO_PATH : "$MPATH" --prefix LD_LIBRARY_PATH : "$MPATH"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/afrantzis/bless";
     description = "Gtk# Hex Editor";
     maintainers = [ maintainers.mkg20001 ];
diff --git a/pkgs/applications/editors/bluefish/default.nix b/pkgs/applications/editors/bluefish/default.nix
index 48c83b0531080..21da4de9c6d6f 100644
--- a/pkgs/applications/editors/bluefish/default.nix
+++ b/pkgs/applications/editors/bluefish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, wrapGAppsHook, pkgconfig , gtk, libxml2
+{ lib, stdenv, fetchurl, intltool, wrapGAppsHook, pkgconfig , gtk, libxml2
 , enchant, gucharmap, python, gnome3
 }:
 
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ gnome3.adwaita-icon-theme gtk libxml2
     enchant gucharmap python ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A powerful editor targeted towards programmers and webdevelopers";
     homepage = "http://bluefish.openoffice.nl/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/editors/bluej/default.nix b/pkgs/applications/editors/bluej/default.nix
index 25caf4b7ac7f8..af333e00961ed 100644
--- a/pkgs/applications/editors/bluej/default.nix
+++ b/pkgs/applications/editors/bluej/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jdk }:
+{ lib, stdenv, fetchurl, makeWrapper, jdk }:
 
 stdenv.mkDerivation rec {
   pname = "bluej";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       --add-flags "-Djavafx.embed.singleThread=true -Dawt.useSystemAAFontSettings=on -Xmx512M -cp \"$out/share/bluej/bluej.jar\" bluej.Boot"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple integrated development environment for Java";
     homepage = "https://www.bluej.org/";
     license = licenses.gpl2ClasspathPlus;
diff --git a/pkgs/applications/editors/bonzomatic/default.nix b/pkgs/applications/editors/bonzomatic/default.nix
index 4d02b6837ca18..df54f710d9c58 100644
--- a/pkgs/applications/editors/bonzomatic/default.nix
+++ b/pkgs/applications/editors/bonzomatic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, fetchFromGitHub, cmake, alsaLib, mesa_glu, libXcursor, libXinerama, libXrandr, xorgserver }:
+{ lib, stdenv, makeWrapper, fetchFromGitHub, cmake, alsaLib, mesa_glu, libXcursor, libXinerama, libXrandr, xorgserver }:
 
 stdenv.mkDerivation rec {
   pname = "bonzomatic";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/Bonzomatic --prefix LD_LIBRARY_PATH : "${alsaLib}/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A live-coding tool for writing 2D fragment/pixel shaders";
     license = with licenses; [
       unlicense
diff --git a/pkgs/applications/editors/bvi/default.nix b/pkgs/applications/editors/bvi/default.nix
index 8a61e0252bc3a..ddef8467646b5 100644
--- a/pkgs/applications/editors/bvi/default.nix
+++ b/pkgs/applications/editors/bvi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "bvi";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Hex editor with vim style keybindings";
     homepage = "http://bvi.sourceforge.net/download.html";
     license = licenses.gpl2;
diff --git a/pkgs/applications/editors/bviplus/default.nix b/pkgs/applications/editors/bviplus/default.nix
index 2cf094c091a6e..e48a147e6daf6 100644
--- a/pkgs/applications/editors/bviplus/default.nix
+++ b/pkgs/applications/editors/bviplus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "bviplus";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   buildFlags = [ "CFLAGS=-fgnu89-inline" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ncurses based hex editor with a vim-like interface";
     homepage = "http://bviplus.sourceforge.net";
     license = licenses.gpl3;
diff --git a/pkgs/applications/editors/code-browser/default.nix b/pkgs/applications/editors/code-browser/default.nix
index ed11298c621ac..3eecc471db940 100644
--- a/pkgs/applications/editors/code-browser/default.nix
+++ b/pkgs/applications/editors/code-browser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , copper
 , ruby
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
   ]
   ++ stdenv.lib.optionals withQt [ "UI=qt" ]
   ++ stdenv.lib.optionals withGtk [ "UI=gtk" ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Folding text editor, designed to hierarchically structure any kind of text file and especially source code";
     homepage = "https://tibleiz.net/code-browser/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/editors/deadpixi-sam/default.nix b/pkgs/applications/editors/deadpixi-sam/default.nix
index 65ec439391278..463865d26bf79 100644
--- a/pkgs/applications/editors/deadpixi-sam/default.nix
+++ b/pkgs/applications/editors/deadpixi-sam/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, freetype, libX11, libXi, libXt, libXft }:
+{ lib, stdenv, fetchFromGitHub, freetype, libX11, libXi, libXt, libXft }:
 
 stdenv.mkDerivation rec {
   version = "2017-10-27";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     mv deadpixi-sam.desktop $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Updated version of the sam text editor";
     license = with licenses; lpl-102;
diff --git a/pkgs/applications/editors/dit/default.nix b/pkgs/applications/editors/dit/default.nix
index e89267d04c500..170019d27381e 100644
--- a/pkgs/applications/editors/dit/default.nix
+++ b/pkgs/applications/editors/dit/default.nix
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     substituteInPlace Prototypes.h --replace 'tail' "$(type -P tail)"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A console text editor for Unix that you already know how to use";
     homepage = "https://hisham.hm/dit/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/editors/eclipse/plugins.nix b/pkgs/applications/editors/eclipse/plugins.nix
index 04b8a1de159a2..000129f74dfff 100644
--- a/pkgs/applications/editors/eclipse/plugins.nix
+++ b/pkgs/applications/editors/eclipse/plugins.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchzip, unzip }:
+{ lib, stdenv, fetchurl, fetchzip, unzip }:
 
 rec {
 
@@ -105,7 +105,7 @@ rec {
       sha256 = "1cn64xj2bm69vnn9db2xxh6kq148v83w5nx3183mrqb59ym3v9kf";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/tobiasmelcher/EclipseAceJump";
       description = "Provides fast jumps to text based on initial letter";
       license = licenses.mit;
@@ -128,7 +128,7 @@ rec {
       sha256 = "1j42l0xxzs89shqkyn91lb0gia10mifzy0i73c3n7gj7sv2ddbjq";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://mihai-nita.net/java/#ePluginAEC";
       description = "Adds support for ANSI escape sequences in the Eclipse console";
       license = licenses.asl20;
@@ -151,7 +151,7 @@ rec {
       cp -v $src $dropinDir/${name}.jar
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A powerful parser generator for processing structured text or binary files";
       homepage = "https://www.antlr.org/";
       license = licenses.bsd3;
@@ -174,7 +174,7 @@ rec {
       cp -v $src $dropinDir/${name}.jar
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A powerful parser generator for processing structured text or binary files";
       homepage = "https://www.antlr.org/";
       license = licenses.bsd3;
@@ -197,7 +197,7 @@ rec {
       sha256 = "03iyb6j2srq74iigmg7dk098c2svyv0ygdfql5jqr44a32n07k8q";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://andrei.gmxhome.de/anyedit/";
       description = "Adds new tools to the context menu of text-based editors";
       license = licenses.epl10;
@@ -220,7 +220,7 @@ rec {
       sha256 = "1n2rzybfcwp3ss2qi0fhd8vm38vdwav8j837lqiqlfcnvzwsk86m";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/cypher256/eclipse-encoding-plugin";
       description = "Show file encoding and line ending for the active editor in the eclipse status bar";
       license = licenses.epl10;
@@ -243,7 +243,7 @@ rec {
       sha256 = "1vmsqv32jfl7anvdkw0vir342miv5sr9df7vd1w44lf1yf97vxlw";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://andrei.gmxhome.de/bytecode/";
       description = "Shows disassembled bytecode of current java editor or class file";
       license = licenses.bsd2;
@@ -263,7 +263,7 @@ rec {
       sha256 = "1hbswcar3a5cw20mwrj82w9pvpkvvj6jrvqqf1lincva0r5sl7h8";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://eclipse.org/cdt/";
       description = "C/C++ development tooling";
       license = licenses.epl10;
@@ -282,7 +282,7 @@ rec {
       sha256 = "07fymk705x4mwq7vh2i6frsf67jql4bzrkdzhb4n74zb0g1dib60";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://eclipse-cs.sourceforge.net/";
       description = "Checkstyle integration into the Eclipse IDE";
       license = licenses.lgpl21;
@@ -306,7 +306,7 @@ rec {
       sha256 = "0wz61909bhqwzpqwll27ia0cn3anyp81haqx3rj1iq42cbl42h0y";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://eclipsecolorthemes.org/";
       description = "Plugin to switch color themes conveniently and without side effects";
       license = licenses.epl10;
@@ -339,7 +339,7 @@ rec {
 
     propagatedBuildInputs = [ zest ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://www2.cs.tum.edu/projects/cup/eclipse.php";
       description = "IDE for developing CUP based parsers";
       platforms = platforms.all;
@@ -364,7 +364,7 @@ rec {
       '';
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.drools.org/";
       description = "Drools is a Business Rules Management System (BRMS) solution";
       license = licenses.asl20;
@@ -381,7 +381,7 @@ rec {
       sha256 = "0w1kwcjh45p7msv5vpc8i6dsqwrnfmjama6vavpnxlji56jd3c43";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.eclemma.org/";
       description = "EclEmma is a free Java code coverage tool for Eclipse";
       license = licenses.epl10;
@@ -404,7 +404,7 @@ rec {
       sha256 = "10p3mrbp9wi6jhlmmc23qv7frh605a23pqsc7w96569bsfb5wa8q";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://findbugs.sourceforge.net/";
       description = "Plugin that uses static analysis to look for bugs in Java code";
       license = licenses.epl10;
@@ -423,7 +423,7 @@ rec {
       sha256 = "1g77jlhfa3csaxxps1z5lasrd9l2p5ajnddnq9ra5syw8ggkdc2h";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://gnuarmeclipse.livius.net/";
       description = "GNU ARM Eclipse Plug-ins";
       license = licenses.epl10;
@@ -461,7 +461,7 @@ rec {
 
     propagatedBuildInputs = [ antlr-runtime_4_7 ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Adds support for JSON files to Eclipse";
       homepage = "https://github.com/boothen/Json-Eclipse-Plugin";
       license = licenses.epl10;
@@ -480,7 +480,7 @@ rec {
       sha256 = "q0O6OE2u0bdz1+nOkzXDrrOOzoEbVaXnejx4lX7uZgk=";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.eclipse.org/jdt/";
       description = "Eclipse Java development tools";
       license = licenses.epl10;
@@ -503,7 +503,7 @@ rec {
       sha256 = "0qdzlqcjcm2i4mwhmcdml0am83z1dayrcmf37ji7vmw6iwdk1xmp";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/angelozerr/jdt-codemining";
       description = "Provides JDT Java CodeMining";
       license = licenses.epl10;
@@ -529,7 +529,7 @@ rec {
         '';
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/RustDT";
       description = "Rust development tooling";
       license = licenses.epl10;
@@ -546,7 +546,7 @@ rec {
       sha256 = "13xgx2rwlll0l4bs0g6gyvrx5gcc0125vzn501fdj0wv2fqxn5lw";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://scala-ide.org/";
       description = "The Scala IDE for Eclipse";
       license = licenses.bsd3;
@@ -565,7 +565,7 @@ rec {
       sha256 = "0aanqwx3gy1arpbkqd846381hiy6272lzwhfjl94x8jhfykpqqbj";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://spotbugs.github.io/";
       description = "Plugin that uses static analysis to look for bugs in Java code";
       license = licenses.lgpl21;
@@ -588,7 +588,7 @@ rec {
       sha256 = "1j4zw6392q3q6z3pcy803k3g0p220gk1x19fs99p0rmmdz83lc8d";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://testng.org/doc/";
       description = "Eclipse plugin for the TestNG testing framework";
       license = licenses.asl20;
@@ -610,7 +610,7 @@ rec {
       sha256 = "0nyirf6km97q211cxfy01kidxac20m8ba3kk9xj73ykrhsk3cxjp";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/vrapper/vrapper";
       description = "A wrapper to provide a Vim-like input scheme for moving around and editing text";
       license = licenses.gpl3;
@@ -633,7 +633,7 @@ rec {
       sha256 = "1wpyw4z28ka60z36f8m71kz1giajcm26wb9bpv18sjiqwdgx9v0z";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/oyse/yedit";
       description = "A YAML editor plugin for Eclipse";
       license = licenses.epl10;
@@ -651,7 +651,7 @@ rec {
       sha256 = "01scn7cmcrjcp387spjm8ifgwrwwi77ypildandbisfvhj3qqs7m";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.eclipse.org/gef/zest/";
       description = "The Eclipse Visualization Toolkit";
       platforms = platforms.all;
diff --git a/pkgs/applications/editors/edbrowse/default.nix b/pkgs/applications/editors/edbrowse/default.nix
index 4e727e9a22a65..86cc81a58c268 100644
--- a/pkgs/applications/editors/edbrowse/default.nix
+++ b/pkgs/applications/editors/edbrowse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, duktape, curl, pcre, readline, openssl, perl, html-tidy }:
+{ lib, stdenv, fetchFromGitHub, duktape, curl, pcre, readline, openssl, perl, html-tidy }:
 
 stdenv.mkDerivation rec {
   pname = "edbrowse";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     rev = "v${version}";
     sha256 = "0cw9d60mdhwna57r1vxn53s8gl81rr3cxnvm769ifq3xyh49vfcf";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command Line Editor Browser";
     longDescription = ''
       Edbrowse is a combination editor, browser, and mail client that is 100% text based.
diff --git a/pkgs/applications/editors/edit/default.nix b/pkgs/applications/editors/edit/default.nix
index 052206002610e..ff4dcca893526 100644
--- a/pkgs/applications/editors/edit/default.nix
+++ b/pkgs/applications/editors/edit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, unzip, pkgconfig, ncurses, libX11, libXft, cwebbin }:
+{ lib, stdenv, fetchgit, unzip, pkgconfig, ncurses, libX11, libXft, cwebbin }:
 
 stdenv.mkDerivation {
   pname = "edit-nightly";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     cp obj/edit $out/bin/edit
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A relaxing mix of Vi and ACME";
     homepage = "http://c9x.me/edit";
     license = licenses.publicDomain;
diff --git a/pkgs/applications/editors/emacs-modes/color-theme-solarized/default.nix b/pkgs/applications/editors/emacs-modes/color-theme-solarized/default.nix
index ba54e5f434129..ce85e9be4e9a7 100644
--- a/pkgs/applications/editors/emacs-modes/color-theme-solarized/default.nix
+++ b/pkgs/applications/editors/emacs-modes/color-theme-solarized/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchzip, emacs, color-theme}:
+{lib, stdenv, fetchzip, emacs, color-theme}:
 let
   commit = "f3ca8902ea056fb8e46cb09f09c96294e31cd4ee";
 in
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     install *.el* $out/share/emacs/site-lisp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Precision colors for machines and people";
     homepage = "http://ethanschoonover.com/solarized";
     maintainers = [ maintainers.samuelrivas ];
diff --git a/pkgs/applications/editors/emacs-modes/sv-kalender/default.nix b/pkgs/applications/editors/emacs-modes/sv-kalender/default.nix
index 211be0a908971..dd553fc199804 100644
--- a/pkgs/applications/editors/emacs-modes/sv-kalender/default.nix
+++ b/pkgs/applications/editors/emacs-modes/sv-kalender/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, trivialBuild }:
+{ fetchurl, lib, stdenv, trivialBuild }:
 
 trivialBuild {
   pname = "sv-kalender";
@@ -12,7 +12,7 @@ trivialBuild {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Swedish calendar for Emacs";
     homepage = "http://bigwalter.net/daniel/elisp/sv-kalender.el";
     platforms = platforms.all;
diff --git a/pkgs/applications/editors/emacs/generic.nix b/pkgs/applications/editors/emacs/generic.nix
index 101dbdaa2e943..0f3ececd37dfe 100644
--- a/pkgs/applications/editors/emacs/generic.nix
+++ b/pkgs/applications/editors/emacs/generic.nix
@@ -177,7 +177,7 @@ in stdenv.mkDerivation (lib.optionalAttrs nativeComp {
     inherit nativeComp;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The extensible, customizable GNU text editor";
     homepage    = "https://www.gnu.org/software/emacs/";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/applications/editors/emacs/macport.nix b/pkgs/applications/editors/emacs/macport.nix
index f991fe7ea666b..dd9a66734586d 100644
--- a/pkgs/applications/editors/emacs/macport.nix
+++ b/pkgs/applications/editors/emacs/macport.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, pkgconfig, texinfo, libxml2, gnutls, gettext, autoconf, automake, jansson
+{ lib, stdenv, fetchurl, ncurses, pkgconfig, texinfo, libxml2, gnutls, gettext, autoconf, automake, jansson
 , AppKit, Carbon, Cocoa, IOKit, OSAKit, Quartz, QuartzCore, WebKit
 , ImageCaptureCore, GSS, ImageIO # These may be optional
 }:
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
   #   lisp/net/tramp-tests.log
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The extensible, customizable text editor";
     homepage    = "https://www.gnu.org/software/emacs/";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/applications/editors/featherpad/default.nix b/pkgs/applications/editors/featherpad/default.nix
index 8343472fa70ac..dee0fe72ebb0c 100644
--- a/pkgs/applications/editors/featherpad/default.nix
+++ b/pkgs/applications/editors/featherpad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, pkgconfig, qmake, qttools, qtbase, qtsvg, qtx11extras, fetchFromGitHub }:
+{ lib, stdenv, mkDerivation, pkgconfig, qmake, qttools, qtbase, qtsvg, qtx11extras, fetchFromGitHub }:
 mkDerivation rec {
   pname = "featherpad";
   version = "0.10.0";
@@ -13,7 +13,7 @@ mkDerivation rec {
   nativeBuildInputs = [ qmake pkgconfig qttools ];
   buildInputs = [ qtbase qtsvg qtx11extras ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight Qt5 Plain-Text Editor for Linux";
     homepage = "https://github.com/tsujan/FeatherPad";
     platforms = platforms.linux;
diff --git a/pkgs/applications/editors/flpsed/default.nix b/pkgs/applications/editors/flpsed/default.nix
index 3d6aac7e18e5a..871d8489f61fc 100644
--- a/pkgs/applications/editors/flpsed/default.nix
+++ b/pkgs/applications/editors/flpsed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fltk13, ghostscript }:
+{ lib, stdenv, fetchurl, fltk13, ghostscript }:
 
 stdenv.mkDerivation rec {
   pname = "flpsed";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
         -i src/GsWidget.cxx
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WYSIWYG PostScript annotator";
     homepage = "https://flpsed.org/flpsed.html";
     license = licenses.gpl3;
diff --git a/pkgs/applications/editors/focuswriter/default.nix b/pkgs/applications/editors/focuswriter/default.nix
index c30cfcb1fb9c7..1a5ce245153eb 100644
--- a/pkgs/applications/editors/focuswriter/default.nix
+++ b/pkgs/applications/editors/focuswriter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, qmake, qttools, hunspell, qtbase, qtmultimedia, mkDerivation }:
+{ lib, stdenv, fetchurl, pkgconfig, qmake, qttools, hunspell, qtbase, qtmultimedia, mkDerivation }:
 
 mkDerivation rec {
   pname = "focuswriter";
@@ -17,7 +17,7 @@ mkDerivation rec {
   qmakeFlags = [ "PREFIX=/" ];
   installFlags = [ "INSTALL_ROOT=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple, distraction-free writing environment";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ madjar ];
diff --git a/pkgs/applications/editors/fte/default.nix b/pkgs/applications/editors/fte/default.nix
index f19a264c06a56..3814c8a879fd6 100644
--- a/pkgs/applications/editors/fte/default.nix
+++ b/pkgs/applications/editors/fte/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, perl, libX11, libXpm, gpm, ncurses, slang }:
+{ lib, stdenv, fetchurl, unzip, perl, libX11, libXpm, gpm, ncurses, slang }:
 
 stdenv.mkDerivation rec {
   name = "fte-0.50.02";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" "INSTALL_NONROOT=1" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free text editor for developers";
     homepage = "http://fte.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/editors/geany/default.nix b/pkgs/applications/editors/geany/default.nix
index 124d4ee0417ad..e6752386718e8 100644
--- a/pkgs/applications/editors/geany/default.nix
+++ b/pkgs/applications/editors/geany/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gtk3
 , which
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small and lightweight IDE";
     longDescription = ''
       Geany is a small and lightweight Integrated Development Environment.
diff --git a/pkgs/applications/editors/ghostwriter/default.nix b/pkgs/applications/editors/ghostwriter/default.nix
index aa67124c1146f..4da73d0d2e617 100644
--- a/pkgs/applications/editors/ghostwriter/default.nix
+++ b/pkgs/applications/editors/ghostwriter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, pkgconfig, qttools, qtwebengine, hunspell }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, pkgconfig, qttools, qtwebengine, hunspell }:
 
 mkDerivation rec {
   pname = "ghostwriter";
@@ -15,7 +15,7 @@ mkDerivation rec {
 
   buildInputs = [ qtwebengine hunspell ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cross-platform, aesthetic, distraction-free Markdown editor";
     homepage = src.meta.homepage;
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/editors/gnome-builder/default.nix b/pkgs/applications/editors/gnome-builder/default.nix
index 6704702837a6b..6c91595c99a8a 100644
--- a/pkgs/applications/editors/gnome-builder/default.nix
+++ b/pkgs/applications/editors/gnome-builder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , ctags
 , appstream-glib
 , desktop-file-utils
@@ -138,7 +138,7 @@ stdenv.mkDerivation rec {
 
   passthru.updateScript = gnome3.updateScript { packageName = pname; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An IDE for writing GNOME-based software";
     longDescription = ''
       Global search, auto-completion, source code map, documentation
diff --git a/pkgs/applications/editors/gnome-latex/default.nix b/pkgs/applications/editors/gnome-latex/default.nix
index ffdeb21de7f31..692e07e52ca97 100644
--- a/pkgs/applications/editors/gnome-latex/default.nix
+++ b/pkgs/applications/editors/gnome-latex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, wrapGAppsHook, gsettings-desktop-schemas, gspell, gtksourceview4, libgee
+{ lib, stdenv, fetchurl, wrapGAppsHook, gsettings-desktop-schemas, gspell, gtksourceview4, libgee
 , tepl, amtk, gnome3, glib, pkgconfig, intltool, itstool, libxml2 }:
 let
   version = "3.38.0";
@@ -37,7 +37,7 @@ in stdenv.mkDerivation {
 
   passthru.updateScript = gnome3.updateScript { packageName = pname; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/GNOME-LaTeX";
     description = "A LaTeX editor for the GNOME desktop";
     maintainers = [ maintainers.manveru ];
diff --git a/pkgs/applications/editors/gobby/default.nix b/pkgs/applications/editors/gobby/default.nix
index e3d039e42232d..4dc7ea33cddc4 100644
--- a/pkgs/applications/editors/gobby/default.nix
+++ b/pkgs/applications/editors/gobby/default.nix
@@ -1,5 +1,5 @@
 { avahiSupport ? false # build support for Avahi in libinfinity
-, stdenv, fetchFromGitHub, autoconf, automake, pkgconfig, wrapGAppsHook, yelp-tools
+, lib, stdenv, fetchFromGitHub, autoconf, automake, pkgconfig, wrapGAppsHook, yelp-tools
 , gtkmm3, gsasl, gtksourceview3, libxmlxx, libinfinity, intltool, itstool, gnome3 }:
 
 let
@@ -18,7 +18,7 @@ in stdenv.mkDerivation {
 
   preConfigure = "./autogen.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gobby.0x539.de/";
     description = "A GTK-based collaborative editor supporting multiple documents in one session and a multi-user chat";
     license = stdenv.lib.licenses.gpl2Plus;
diff --git a/pkgs/applications/editors/greenfoot/default.nix b/pkgs/applications/editors/greenfoot/default.nix
index 8205d52b43a19..324d8b13f21e2 100644
--- a/pkgs/applications/editors/greenfoot/default.nix
+++ b/pkgs/applications/editors/greenfoot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jdk }:
+{ lib, stdenv, fetchurl, makeWrapper, jdk }:
 
 stdenv.mkDerivation rec {
   pname = "greenfoot";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
       --add-flags "-Djavafx.embed.singleThread=true -Dawt.useSystemAAFontSettings=on -Xmx512M -cp \"$out/share/greenfoot/bluej.jar\" bluej.Boot -greenfoot=true -bluej.compiler.showunchecked=false -greenfoot.scenarios=$out/share/doc/Greenfoot/scenarios -greenfoot.url.javadoc=file://$out/share/doc/Greenfoot/API"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple integrated development environment for Java";
     homepage = "https://www.greenfoot.org/";
     license = licenses.gpl2ClasspathPlus;
diff --git a/pkgs/applications/editors/hecate/default.nix b/pkgs/applications/editors/hecate/default.nix
index de57fb092157a..a0fdcfbb3f66d 100644
--- a/pkgs/applications/editors/hecate/default.nix
+++ b/pkgs/applications/editors/hecate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   version = "0.0.1";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "terminal hex editor";
     longDescription = "The Hex Editor From Hell!";
diff --git a/pkgs/applications/editors/hexdino/default.nix b/pkgs/applications/editors/hexdino/default.nix
index 9722854b98044..5d782aa1abcbb 100644
--- a/pkgs/applications/editors/hexdino/default.nix
+++ b/pkgs/applications/editors/hexdino/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, ncurses }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, ncurses }:
 
 rustPlatform.buildRustPackage {
   pname = "hexdino";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage {
 
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A hex editor with vim like keybindings written in Rust";
     homepage = "https://github.com/Luz/hexdino";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/jedit/default.nix b/pkgs/applications/editors/jedit/default.nix
index 18fe236983ac0..0d29eeb17dc24 100644
--- a/pkgs/applications/editors/jedit/default.nix
+++ b/pkgs/applications/editors/jedit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ant, jdk, commonsBsf, commonsLogging, bsh }:
+{ lib, stdenv, fetchurl, ant, jdk, commonsBsf, commonsLogging, bsh }:
 
 let
   version = "5.2.0";
@@ -52,7 +52,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/jedit
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mature programmer's text editor (Java based)";
     homepage = "http://www.jedit.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/editors/jetbrains/default.nix b/pkgs/applications/editors/jetbrains/default.nix
index 9d743b197e63e..d805d17964723 100644
--- a/pkgs/applications/editors/jetbrains/default.nix
+++ b/pkgs/applications/editors/jetbrains/default.nix
@@ -15,7 +15,7 @@ let
     lib.overrideDerivation (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "CLion";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/clion/";
         inherit description license;
         longDescription = ''
@@ -83,7 +83,7 @@ let
     (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "DataGrip";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/datagrip/";
         inherit description license;
         longDescription = ''
@@ -100,7 +100,7 @@ let
     lib.overrideDerivation (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "Goland";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/go/";
         inherit description license;
         longDescription = ''
@@ -125,7 +125,7 @@ let
     (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "IDEA";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/idea/";
         inherit description license;
         longDescription = ''
@@ -143,7 +143,7 @@ let
     (mkJetBrainsProduct rec {
       inherit name version src wmClass jdk;
       product = "MPS";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = https://www.jetbrains.com/mps/;
         inherit license description;
         longDescription = ''
@@ -161,7 +161,7 @@ let
     (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "PhpStorm";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/phpstorm/";
         inherit description license;
         longDescription = ''
@@ -178,7 +178,7 @@ let
     (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "PyCharm";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/pycharm/";
         inherit description license;
         longDescription = ''
@@ -205,7 +205,7 @@ let
     lib.overrideDerivation (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "Rider";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/rider/";
         inherit description license;
         longDescription = ''
@@ -231,7 +231,7 @@ let
     (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "RubyMine";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/ruby/";
         inherit description license;
         longDescription = description;
@@ -244,7 +244,7 @@ let
     lib.overrideDerivation (mkJetBrainsProduct {
       inherit name version src wmClass jdk;
       product = "WebStorm";
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.jetbrains.com/webstorm/";
         inherit description license;
         longDescription = ''
diff --git a/pkgs/applications/editors/joe/default.nix b/pkgs/applications/editors/joe/default.nix
index 9470c7940d67b..4a335a351c750 100644
--- a/pkgs/applications/editors/joe/default.nix
+++ b/pkgs/applications/editors/joe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl } :
+{ lib, stdenv, fetchurl } :
 
 stdenv.mkDerivation rec {
   pname = "joe";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1pmr598xxxm9j9dl93kq4dv36zyw0q2dh6d7x07hf134y9hhlnj9";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full featured terminal-based screen editor";
     longDescription = ''
       JOE (Joe's Own Editor) is a full featured terminal-based screen editor
diff --git a/pkgs/applications/editors/jupp/default.nix b/pkgs/applications/editors/jupp/default.nix
index 79db7b8a558a7..e134113e23faa 100644
--- a/pkgs/applications/editors/jupp/default.nix
+++ b/pkgs/applications/editors/jupp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, gpm }:
+{ lib, stdenv, fetchurl, ncurses, gpm }:
 
 stdenv.mkDerivation rec {
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     "--enable-largefile"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A portable fork of Joe's editor";
     longDescription = ''
       This is the portable version of JOE's Own Editor, which is currently
diff --git a/pkgs/applications/editors/kakoune/plugins/case.kak.nix b/pkgs/applications/editors/kakoune/plugins/case.kak.nix
index 6a2ef200e6e14..3fa91113bbadc 100644
--- a/pkgs/applications/editors/kakoune/plugins/case.kak.nix
+++ b/pkgs/applications/editors/kakoune/plugins/case.kak.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab }:
+{ lib, stdenv, fetchFromGitLab }:
 
 stdenv.mkDerivation {
   name = "case.kak";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     cp -r rc/case.kak $out/share/kak/autoload/plugins
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Case convention conversion for Kakoune";
     homepage = "https://gitlab.com/FlyingWombat/case.kak";
     license = licenses.unlicense;
diff --git a/pkgs/applications/editors/kakoune/plugins/kak-ansi.nix b/pkgs/applications/editors/kakoune/plugins/kak-ansi.nix
index 408cba45fbe64..f34ee6d299908 100644
--- a/pkgs/applications/editors/kakoune/plugins/kak-ansi.nix
+++ b/pkgs/applications/editors/kakoune/plugins/kak-ansi.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   name = "kak-ansi";
@@ -22,7 +22,7 @@ declare-option -hidden str ansi_filter %{'"$out"'/bin/kak-ansi-filter}
     ' rc/ansi.kak >$out/share/kak/autoload/plugins/ansi.kak
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kakoune support for rendering ANSI code";
     homepage = "https://github.com/eraserhd/kak-ansi";
     license = licenses.unlicense;
diff --git a/pkgs/applications/editors/kakoune/plugins/kak-plumb.nix b/pkgs/applications/editors/kakoune/plugins/kak-plumb.nix
index 7abef93053109..0c59ca9a08f00 100644
--- a/pkgs/applications/editors/kakoune/plugins/kak-plumb.nix
+++ b/pkgs/applications/editors/kakoune/plugins/kak-plumb.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kakoune-unwrapped, plan9port, ... }:
+{ lib, stdenv, fetchFromGitHub, kakoune-unwrapped, plan9port, ... }:
 
 stdenv.mkDerivation rec {
   pname = "kak-plumb";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/edit-client
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kakoune integration with the Plan 9 plumber";
     homepage = "https://github.com/eraserhd/kak-plumb";
     license = licenses.unlicense;
diff --git a/pkgs/applications/editors/kakoune/plugins/openscad.kak.nix b/pkgs/applications/editors/kakoune/plugins/openscad.kak.nix
index 21c8b7a60ccaa..57c1033ebbdd1 100644
--- a/pkgs/applications/editors/kakoune/plugins/openscad.kak.nix
+++ b/pkgs/applications/editors/kakoune/plugins/openscad.kak.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "openscad.kak";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     install -Dm644 rc/openscad.kak -t $out/share/kak/autoload/plugins/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Syntax highlighting for OpenSCAD files";
     homepage = "https://github.com/mayjs/openscad.kak";
     license = licenses.unlicense;
diff --git a/pkgs/applications/editors/kdevelop5/kdevelop-pg-qt.nix b/pkgs/applications/editors/kdevelop5/kdevelop-pg-qt.nix
index 40e46d9295f93..27cf579734e83 100644
--- a/pkgs/applications/editors/kdevelop5/kdevelop-pg-qt.nix
+++ b/pkgs/applications/editors/kdevelop5/kdevelop-pg-qt.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkgconfig, extra-cmake-modules, qtbase }:
+{ lib, stdenv, fetchurl, cmake, pkgconfig, extra-cmake-modules, qtbase }:
 
 let
   pname = "kdevelop-pg-qt";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ qtbase ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = [ maintainers.ambrop72 ];
     platforms = platforms.linux;
     description = "Parser-generator from KDevplatform";
diff --git a/pkgs/applications/editors/kibi/default.nix b/pkgs/applications/editors/kibi/default.nix
index 7945dedc52e1b..07454d331c6f7 100644
--- a/pkgs/applications/editors/kibi/default.nix
+++ b/pkgs/applications/editors/kibi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 }:
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
     sha256 = "1x5bvvq33380k2qhs1bwz3f9zl5q1sl7iic47pxfkzv24bpjnypb";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A text editor in ≤1024 lines of code, written in Rust";
     homepage = "https://github.com/ilai-deutel/kibi";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/kodestudio/default.nix b/pkgs/applications/editors/kodestudio/default.nix
index 71fa2bcd41b50..d7f00a2e18adf 100644
--- a/pkgs/applications/editors/kodestudio/default.nix
+++ b/pkgs/applications/editors/kodestudio/default.nix
@@ -114,7 +114,7 @@ in
           --prefix LD_PRELOAD : ${stdenv.lib.makeLibraryPath [ libXScrnSaver ]}/libXss.so.1
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = ''
         An IDE for Kha based on Visual Studio Code
       '';
diff --git a/pkgs/applications/editors/leafpad/default.nix b/pkgs/applications/editors/leafpad/default.nix
index 94fa0be017375..d37a2de286659 100644
--- a/pkgs/applications/editors/leafpad/default.nix
+++ b/pkgs/applications/editors/leafpad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, pkgconfig, gtk2 }:
+{ lib, stdenv, fetchurl, intltool, pkgconfig, gtk2 }:
 
 stdenv.mkDerivation rec {
   version = "0.8.18.1";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     "--enable-chooser"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A notepad clone for GTK 2.0";
     homepage = "http://tarot.freeshell.org/leafpad";
     platforms = platforms.linux;
diff --git a/pkgs/applications/editors/lighttable/default.nix b/pkgs/applications/editors/lighttable/default.nix
index abf55b42c5513..ff5b6e3862ebc 100644
--- a/pkgs/applications/editors/lighttable/default.nix
+++ b/pkgs/applications/editors/lighttable/default.nix
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     cp "${desktopItem}/share/applications/LightTable.desktop" "$out"/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The next generation code editor";
     homepage = "http://www.lighttable.com/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/editors/lite/default.nix b/pkgs/applications/editors/lite/default.nix
index 2f43972349848..a313ea18212f7 100644
--- a/pkgs/applications/editors/lite/default.nix
+++ b/pkgs/applications/editors/lite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , SDL2
 , lua52Packages
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     makeWrapper $out/lib/${pname}/lite $out/bin/lite
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight text editor written in Lua";
     homepage = "https://github.com/rxi/lite";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/marker/default.nix b/pkgs/applications/editors/marker/default.nix
index 19ffdbd2c2c1c..f974cc1ef42c4 100644
--- a/pkgs/applications/editors/marker/default.nix
+++ b/pkgs/applications/editors/marker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     pandoc
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fabiocolacio.github.io/Marker/";
     description = "Markdown editor for the Linux desktop";
     maintainers = with maintainers; [ trepetti ];
diff --git a/pkgs/applications/editors/mg/default.nix b/pkgs/applications/editors/mg/default.nix
index 6ba315e541bb1..8878e01de67f4 100644
--- a/pkgs/applications/editors/mg/default.nix
+++ b/pkgs/applications/editors/mg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, ncurses, buildPackages }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, ncurses, buildPackages }:
 
 stdenv.mkDerivation rec {
   pname = "mg";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Micro GNU/emacs, a portable version of the mg maintained by the OpenBSD team";
     homepage = "https://man.openbsd.org/OpenBSD-current/man1/mg.1";
     license = licenses.publicDomain;
diff --git a/pkgs/applications/editors/mindforger/default.nix b/pkgs/applications/editors/mindforger/default.nix
index f7e244342257c..a8e60cddfbb84 100644
--- a/pkgs/applications/editors/mindforger/default.nix
+++ b/pkgs/applications/editors/mindforger/default.nix
@@ -4,7 +4,7 @@
 , qmake
 , qtbase
 , qtwebkit
-, stdenv
+, lib, stdenv
 , wrapGAppsHook
 }:
 
@@ -31,7 +31,7 @@ mkDerivation rec {
 
   qmakeFlags = [ "-r mindforger.pro" "CONFIG+=mfnoccache" ] ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Thinking Notebook & Markdown IDE";
     longDescription = ''
      MindForger is actually more than an editor or IDE - it's human
diff --git a/pkgs/applications/editors/mle/default.nix b/pkgs/applications/editors/mle/default.nix
index 692b82dc68874..d57e4d36b4e38 100644
--- a/pkgs/applications/editors/mle/default.nix
+++ b/pkgs/applications/editors/mle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, termbox, pcre, uthash, lua5_3 }:
+{ lib, stdenv, fetchFromGitHub, termbox, pcre, uthash, lua5_3 }:
 
 stdenv.mkDerivation rec {
   pname = "mle";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "prefix=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small, flexible terminal-based text editor";
     homepage = "https://github.com/adsr/mle";
     license = licenses.asl20;
diff --git a/pkgs/applications/editors/moe/default.nix b/pkgs/applications/editors/moe/default.nix
index d6dbe10065285..4365c172f48fd 100644
--- a/pkgs/applications/editors/moe/default.nix
+++ b/pkgs/applications/editors/moe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , ncurses
 , lzip
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ lzip ];
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small, 8-bit clean editor";
     longDescription = ''
       GNU moe is a powerful, 8-bit clean, console text editor for ISO-8859 and
diff --git a/pkgs/applications/editors/monodevelop/default.nix b/pkgs/applications/editors/monodevelop/default.nix
index 527228742c4cd..9b576795be003 100644
--- a/pkgs/applications/editors/monodevelop/default.nix
+++ b/pkgs/applications/editors/monodevelop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , autoconf, automake, pkgconfig, shared-mime-info, intltool
 , glib, mono, gtk-sharp-2_0, gnome2, gnome-sharp, unzip
 , dotnetPackages
@@ -73,7 +73,7 @@ stdenv.mkDerivation rec {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     maintainers = with maintainers; [ obadz ];
     broken = true; # 2018-09-21, build has failed since 2018-03-08
diff --git a/pkgs/applications/editors/music/tuxguitar/default.nix b/pkgs/applications/editors/music/tuxguitar/default.nix
index 08841eb581002..e7cd319b82016 100644
--- a/pkgs/applications/editors/music/tuxguitar/default.nix
+++ b/pkgs/applications/editors/music/tuxguitar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, swt, jdk, makeWrapper, alsaLib, jack2, fluidsynth, libpulseaudio }:
+{ lib, stdenv, fetchurl, swt, jdk, makeWrapper, alsaLib, jack2, fluidsynth, libpulseaudio }:
 
 let metadata = assert stdenv.hostPlatform.system == "i686-linux" || stdenv.hostPlatform.system == "x86_64-linux";
   if stdenv.hostPlatform.system == "i686-linux" then
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
       --prefix CLASSPATH : "${swt}/jars/swt.jar:$out/lib/tuxguitar.jar:$out/lib/itext.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multitrack guitar tablature editor";
     longDescription = ''
       TuxGuitar is a multitrack guitar tablature editor and player written
diff --git a/pkgs/applications/editors/ne/default.nix b/pkgs/applications/editors/ne/default.nix
index 4faf1e28b1cca..fde6542f16055 100644
--- a/pkgs/applications/editors/ne/default.nix
+++ b/pkgs/applications/editors/ne/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, texinfo, texlive, perl, ghostscript }:
+{ lib, stdenv, fetchFromGitHub, ncurses, texinfo, texlive, perl, ghostscript }:
 
 stdenv.mkDerivation rec {
   pname = "ne";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The nice editor";
     homepage = "http://ne.di.unimi.it/";
     longDescription = ''
diff --git a/pkgs/applications/editors/nedit/default.nix b/pkgs/applications/editors/nedit/default.nix
index e1d1fa3070a91..feaba31734c2c 100644
--- a/pkgs/applications/editors/nedit/default.nix
+++ b/pkgs/applications/editors/nedit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xlibsWrapper, motif, libXpm }:
+{ lib, stdenv, fetchurl, xlibsWrapper, motif, libXpm }:
 
 stdenv.mkDerivation rec {
   pname = "nedit";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp -p source/nedit source/nc $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/nedit";
     description = "A fast, compact Motif/X11 plain text editor";
     platforms = with platforms; linux ++ darwin;
diff --git a/pkgs/applications/editors/neovim/gnvim/default.nix b/pkgs/applications/editors/neovim/gnvim/default.nix
index e6166dd14b197..f1d56584e4995 100644
--- a/pkgs/applications/editors/neovim/gnvim/default.nix
+++ b/pkgs/applications/editors/neovim/gnvim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, gtk, webkitgtk }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, gtk, webkitgtk }:
 
 rustPlatform.buildRustPackage rec {
   pname = "gnvim-unwrapped";
@@ -41,7 +41,7 @@ rustPlatform.buildRustPackage rec {
     make install PREFIX="${placeholder "out"}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for neovim, without any web bloat";
     homepage = "https://github.com/vhakulinen/gnvim";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/neovim/qt.nix b/pkgs/applications/editors/neovim/qt.nix
index 5a75a9284f038..8eaa9204c4355 100644
--- a/pkgs/applications/editors/neovim/qt.nix
+++ b/pkgs/applications/editors/neovim/qt.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, doxygen, makeWrapper
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, doxygen, makeWrapper
 , msgpack, neovim, pythonPackages, qtbase }:
 
 let
@@ -35,7 +35,7 @@ let
 
     doCheck = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Neovim client library and GUI, in Qt5";
       homepage = "https://github.com/equalsraf/neovim-qt";
       license     = licenses.isc;
diff --git a/pkgs/applications/editors/okteta/default.nix b/pkgs/applications/editors/okteta/default.nix
index 382fcd44257ef..d51f46b9e0a40 100644
--- a/pkgs/applications/editors/okteta/default.nix
+++ b/pkgs/applications/editors/okteta/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, extra-cmake-modules, kdoctools, qtscript, kconfig
+{ mkDerivation, lib, stdenv, fetchurl, extra-cmake-modules, kdoctools, qtscript, kconfig
 , kinit, karchive, kcrash, kcmutils, kconfigwidgets, knewstuff, kparts
 , qca-qt5, shared-mime-info }:
 
@@ -26,7 +26,7 @@ mkDerivation rec {
     kcrash
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl2;
     description = "A hex editor";
     maintainers = with maintainers; [ peterhoeg bkchr ];
diff --git a/pkgs/applications/editors/quilter/default.nix b/pkgs/applications/editors/quilter/default.nix
index b69d20850ad21..9834b78eae989 100644
--- a/pkgs/applications/editors/quilter/default.nix
+++ b/pkgs/applications/editors/quilter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nix-update-script, pkgconfig, meson, ninja, python3, vala
+{ lib, stdenv, fetchFromGitHub, nix-update-script, pkgconfig, meson, ninja, python3, vala
 , gtk3, desktop-file-utils, gtksourceview, webkitgtk, gtkspell3, pantheon
 , libgee, discount, wrapGAppsHook }:
 
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Focus on your writing - designed for elementary OS";
     homepage = "https://github.com/lainsce/quilter";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/editors/qxmledit/default.nix b/pkgs/applications/editors/qxmledit/default.nix
index cb658e8fcdac3..4023861cc3748 100644
--- a/pkgs/applications/editors/qxmledit/default.nix
+++ b/pkgs/applications/editors/qxmledit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub,
+{ lib, stdenv, fetchFromGitHub,
   qmake, qtbase, qtxmlpatterns, qtsvg, qtscxml, qtquick1, libGLU }:
 
 stdenv.mkDerivation rec {
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     export QXMLEDIT_INST_DOC_DIR="$doc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple XML editor based on qt libraries" ;
     homepage = "https://sourceforge.net/projects/qxmledit";
     license = licenses.lgpl2;
diff --git a/pkgs/applications/editors/qxw/default.nix b/pkgs/applications/editors/qxw/default.nix
index aed69e4f568ba..c36aba6d9bba1 100644
--- a/pkgs/applications/editors/qxw/default.nix
+++ b/pkgs/applications/editors/qxw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkg-config, gtk2, pcre }:
+{ lib, stdenv, fetchurl, pkg-config, gtk2, pcre }:
 
 stdenv.mkDerivation rec {
   pname = "qxw";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
             s,/usr/games,/bin,' Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program to help create and publish crosswords";
     homepage = "https://www.quinapalus.com/qxw.html";
     license = licenses.gpl2;
diff --git a/pkgs/applications/editors/rehex/default.nix b/pkgs/applications/editors/rehex/default.nix
index 0fe00d08405b5..ec85ffde488ac 100644
--- a/pkgs/applications/editors/rehex/default.nix
+++ b/pkgs/applications/editors/rehex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , capstone
 , jansson
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=$(out)" ] ++ (stdenv.lib.optionals stdenv.isDarwin [ "-f Makefile.osx" ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reverse Engineers' Hex Editor";
     longDescription = ''
       A cross-platform (Windows, Linux, Mac) hex editor for reverse
diff --git a/pkgs/applications/editors/retext/default.nix b/pkgs/applications/editors/retext/default.nix
index c32e831575615..99f7340f7536f 100644
--- a/pkgs/applications/editors/retext/default.nix
+++ b/pkgs/applications/editors/retext/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchFromGitHub, wrapQtAppsHook, buildEnv, aspellDicts
+{ lib, stdenv, python3, fetchFromGitHub, wrapQtAppsHook, buildEnv, aspellDicts
 # Use `lib.collect lib.isDerivation aspellDicts;` to make all dictionaries
 # available.
 , enchantAspellDicts ? with aspellDicts; [ en en-computers en-science ]
@@ -55,7 +55,7 @@ in python.pkgs.buildPythonApplication {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/retext-project/retext/";
     description = "Simple but powerful editor for Markdown and reStructuredText";
     license = licenses.gpl3;
diff --git a/pkgs/applications/editors/scite/default.nix b/pkgs/applications/editors/scite/default.nix
index 4e92856fee241..0b72a57df3ec6 100644
--- a/pkgs/applications/editors/scite/default.nix
+++ b/pkgs/applications/editors/scite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk2 }:
+{ lib, stdenv, fetchurl, pkgconfig, gtk2 }:
 
 stdenv.mkDerivation {
   pname = "scite";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     make install prefix=$out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.scintilla.org/SciTE.html";
     description = "SCIntilla based Text Editor";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/sigil/default.nix b/pkgs/applications/editors/sigil/default.nix
index 6bf1ca5ada3e6..8e662d55523df 100644
--- a/pkgs/applications/editors/sigil/default.nix
+++ b/pkgs/applications/editors/sigil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, pkgconfig, makeWrapper
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, pkgconfig, makeWrapper
 , boost, xercesc, hunspell, zlib, pcre16
 , qtbase, qttools, qtwebengine, qtxmlpatterns
 , python3Packages
@@ -36,7 +36,7 @@ mkDerivation rec {
        ''${qtWrapperArgs[@]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free, open source, multi-platform ebook (ePub) editor";
     homepage = "https://github.com/Sigil-Ebook/Sigil/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/editors/spacevim/default.nix b/pkgs/applications/editors/spacevim/default.nix
index b2eb6eecc1935..02c6fd82d8c51 100644
--- a/pkgs/applications/editors/spacevim/default.nix
+++ b/pkgs/applications/editors/spacevim/default.nix
@@ -1,5 +1,5 @@
 { ripgrep, gitAndTools, fzf, makeWrapper, vim_configurable, vimPlugins, fetchFromGitHub, writeTextDir
-, stdenv, runCommandNoCC, remarshal, formats, spacevim_config ? import ./init.nix }:
+, lib, stdenv, runCommandNoCC, remarshal, formats, spacevim_config ? import ./init.nix }:
 with stdenv;
 let
   format = formats.toml {};
@@ -42,7 +42,7 @@ in mkDerivation rec {
         --prefix PATH : ${lib.makeBinPath [ fzf gitAndTools.git ripgrep]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern Vim distribution";
     longDescription = ''
       SpaceVim is a distribution of the Vim editor that’s inspired by spacemacs.
diff --git a/pkgs/applications/editors/standardnotes/default.nix b/pkgs/applications/editors/standardnotes/default.nix
index e019814b3d678..e472df44a6040 100644
--- a/pkgs/applications/editors/standardnotes/default.nix
+++ b/pkgs/applications/editors/standardnotes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appimageTools, autoPatchelfHook, desktop-file-utils
+{ lib, stdenv, appimageTools, autoPatchelfHook, desktop-file-utils
   , fetchurl, runtimeShell }:
 
 let
@@ -44,7 +44,7 @@ in appimageTools.wrapType2 rec {
     rm usr/lib/* AppRun standard-notes.desktop .so*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple and private notes app";
     longDescription = ''
       Standard Notes is a private notes app that features unmatched simplicity,
diff --git a/pkgs/applications/editors/sublime/3/common.nix b/pkgs/applications/editors/sublime/3/common.nix
index 22c23280d17d1..82d824b487706 100644
--- a/pkgs/applications/editors/sublime/3/common.nix
+++ b/pkgs/applications/editors/sublime/3/common.nix
@@ -1,6 +1,6 @@
 { buildVersion, x32sha256, x64sha256, dev ? false }:
 
-{ fetchurl, stdenv, xorg, glib, glibcLocales, gtk3, cairo, pango, libredirect, makeWrapper, wrapGAppsHook
+{ fetchurl, lib, stdenv, xorg, glib, glibcLocales, gtk3, cairo, pango, libredirect, makeWrapper, wrapGAppsHook
 , pkexecPath ? "/run/wrappers/bin/pkexec"
 , writeScript, common-updater-scripts, curl, gnugrep
 , openssl, bzip2, bash, unzip, zip
@@ -148,7 +148,7 @@ in stdenv.mkDerivation (rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sophisticated text editor for code, markup and prose";
     homepage = "https://www.sublimetext.com/";
     maintainers = with maintainers; [ jtojnar wmertens demin-dmitriy zimbatm ];
diff --git a/pkgs/applications/editors/supertux-editor/default.nix b/pkgs/applications/editors/supertux-editor/default.nix
index dc18bd694c696..b42ebe19f64ce 100644
--- a/pkgs/applications/editors/supertux-editor/default.nix
+++ b/pkgs/applications/editors/supertux-editor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, mono, gtk-sharp-2_0, pkgconfig, makeWrapper, gnome2, gtk2 }:
+{ lib, stdenv, fetchFromGitHub, mono, gtk-sharp-2_0, pkgconfig, makeWrapper, gnome2, gtk2 }:
 stdenv.mkDerivation {
   version = "git-2014-08-20";
   pname = "supertux-editor";
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
   # Always needed on Mono, otherwise nothing runs
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Level editor for SuperTux";
     homepage = "https://github.com/SuperTux/supertux-editor";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/editors/tecoc/default.nix b/pkgs/applications/editors/tecoc/default.nix
index 3df13260d51f3..50cad500c9550 100644
--- a/pkgs/applications/editors/tecoc/default.nix
+++ b/pkgs/applications/editors/tecoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , ncurses }:
 
 stdenv.mkDerivation rec {
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
      ln -s tecoc Inspect )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A clone of the good old TECO editor";
     longDescription = ''
       For those who don't know: TECO is the acronym of Tape Editor and COrrector
diff --git a/pkgs/applications/editors/textadept/10/default.nix b/pkgs/applications/editors/textadept/10/default.nix
index 0456d013bbbe6..4450fe77d1835 100644
--- a/pkgs/applications/editors/textadept/10/default.nix
+++ b/pkgs/applications/editors/textadept/10/default.nix
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     "PREFIX=$(out) WGET=true PIXMAPS_DIR=$(out)/share/pixmaps"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extensible text editor based on Scintilla with Lua scripting";
     homepage = "http://foicica.com/textadept";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/textadept/11/default.nix b/pkgs/applications/editors/textadept/11/default.nix
index 487f1b3767f14..017a2970c308a 100644
--- a/pkgs/applications/editors/textadept/11/default.nix
+++ b/pkgs/applications/editors/textadept/11/default.nix
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     "PREFIX=$(out) WGET=true PIXMAPS_DIR=$(out)/share/pixmaps"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extensible text editor based on Scintilla with Lua scripting. Version 11_beta";
     homepage = "http://foicica.com/textadept";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/thonny/default.nix b/pkgs/applications/editors/thonny/default.nix
index 0808bf82390e5..e98d57420e813 100644
--- a/pkgs/applications/editors/thonny/default.nix
+++ b/pkgs/applications/editors/thonny/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 with python3.pkgs;
 
@@ -37,7 +37,7 @@ buildPythonApplication rec {
   # Tests need a DISPLAY
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python IDE for beginners";
     longDescription = ''
       Thonny is a Python IDE for beginners. It supports different ways
diff --git a/pkgs/applications/editors/tiled/default.nix b/pkgs/applications/editors/tiled/default.nix
index 10c0ed9ea79b2..b58f5da6a967a 100644
--- a/pkgs/applications/editors/tiled/default.nix
+++ b/pkgs/applications/editors/tiled/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, pkgconfig, qmake
+{ lib, stdenv, mkDerivation, fetchFromGitHub, pkgconfig, qmake
 , python, qtbase, qttools }:
 
 mkDerivation rec {
@@ -17,7 +17,7 @@ mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free, easy to use and flexible tile map editor";
     homepage = "https://www.mapeditor.org/";
     license = with licenses; [
diff --git a/pkgs/applications/editors/tweak/default.nix b/pkgs/applications/editors/tweak/default.nix
index 3dc7d04ede388..887a9a8e69239 100644
--- a/pkgs/applications/editors/tweak/default.nix
+++ b/pkgs/applications/editors/tweak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "tweak";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ ncurses ];
   preBuild = "substituteInPlace Makefile --replace '$(DESTDIR)/usr/local' $out";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An efficient hex editor";
     homepage = "http://www.chiark.greenend.org.uk/~sgtatham/tweak";
     license = licenses.mit;
diff --git a/pkgs/applications/editors/vim/macvim.nix b/pkgs/applications/editors/vim/macvim.nix
index d2cc14c30c481..e950e7685ef81 100644
--- a/pkgs/applications/editors/vim/macvim.nix
+++ b/pkgs/applications/editors/vim/macvim.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, runCommand, ncurses, gettext
+{ lib, stdenv, fetchFromGitHub, runCommand, ncurses, gettext
 , pkgconfig, cscope, ruby, tcl, perl, luajit
 , darwin
 
@@ -175,7 +175,7 @@ stdenv.mkDerivation {
     (deny file-read* file-write* process-exec mach-lookup (subpath "/usr/local") (with no-log))
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Vim - the text editor - for macOS";
     homepage    = "https://github.com/macvim-dev/macvim";
     license = licenses.vim;
diff --git a/pkgs/applications/editors/vim/vimacs.nix b/pkgs/applications/editors/vim/vimacs.nix
index d067b4181213d..cb77e60cf0027 100644
--- a/pkgs/applications/editors/vim/vimacs.nix
+++ b/pkgs/applications/editors/vim/vimacs.nix
@@ -1,4 +1,4 @@
-{ stdenv, config, vim_configurable, macvim, vimPlugins
+{ lib, stdenv, config, vim_configurable, macvim, vimPlugins
 , useMacvim ? stdenv.isDarwin && (config.vimacs.macvim or true)
 , vimacsExtraArgs ? "" }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Vim-Improved eMACS: Emacs emulation for Vim";
     homepage = "http://algorithm.com.au/code/vimacs";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/editors/vis/default.nix b/pkgs/applications/editors/vis/default.nix
index c8eb119eb07a2..bd6eba94907fd 100644
--- a/pkgs/applications/editors/vis/default.nix
+++ b/pkgs/applications/editors/vis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, makeWrapper, makeDesktopItem
+{ lib, stdenv, fetchFromGitHub, pkgconfig, makeWrapper, makeDesktopItem
 , ncurses, libtermkey, lpeg, lua
 , acl ? null, libselinux ? null
 }:
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     terminal = "true";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A vim like editor";
     homepage = "https://github.com/martanne/vis";
     license = licenses.isc;
diff --git a/pkgs/applications/editors/viw/default.nix b/pkgs/applications/editors/viw/default.nix
index 4025bf252b309..3aad18ef11cbc 100644
--- a/pkgs/applications/editors/viw/default.nix
+++ b/pkgs/applications/editors/viw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "viw";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -Dm 644 -t $out/share/doc/${pname} README.md
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VI Worsened, a fun and light clone of VI";
     homepage = "https://github.com/lpan/viw";
     license = licenses.gpl3Only;
diff --git a/pkgs/applications/editors/vscode/vscode.nix b/pkgs/applications/editors/vscode/vscode.nix
index 911b497e8f023..7324a19620dc7 100644
--- a/pkgs/applications/editors/vscode/vscode.nix
+++ b/pkgs/applications/editors/vscode/vscode.nix
@@ -40,7 +40,7 @@ in
 
     sourceRoot = "";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = ''
         Open source source code editor developed by Microsoft for Windows,
         Linux and macOS
diff --git a/pkgs/applications/editors/vscode/vscodium.nix b/pkgs/applications/editors/vscode/vscodium.nix
index c3d8c4ee46c5e..cae1611061513 100644
--- a/pkgs/applications/editors/vscode/vscodium.nix
+++ b/pkgs/applications/editors/vscode/vscodium.nix
@@ -1,4 +1,4 @@
-{ stdenv, callPackage, fetchurl }:
+{ lib, stdenv, callPackage, fetchurl }:
 
 let
   inherit (stdenv.hostPlatform) system;
@@ -45,7 +45,7 @@ in
       inherit sha256;
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = ''
         Open source source code editor developed by Microsoft for Windows,
         Linux and macOS (VS Code without MS branding/telemetry/licensing)
diff --git a/pkgs/applications/editors/wily/default.nix b/pkgs/applications/editors/wily/default.nix
index ac741599bdab0..3fe756bcf72b7 100644
--- a/pkgs/applications/editors/wily/default.nix
+++ b/pkgs/applications/editors/wily/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXt } :
+{ lib, stdenv, fetchurl, libX11, libXt } :
 
 stdenv.mkDerivation rec {
   version = "0.13.42";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An emulation of ACME";
     homepage = "http://wily.sourceforge.net";
     license = licenses.artistic1;
diff --git a/pkgs/applications/editors/xmlcopyeditor/default.nix b/pkgs/applications/editors/xmlcopyeditor/default.nix
index f3270fccdfe73..d9bf7f52b2c49 100644
--- a/pkgs/applications/editors/xmlcopyeditor/default.nix
+++ b/pkgs/applications/editors/xmlcopyeditor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, aspell, boost, expat, intltool, libxml2, libxslt, pcre, wxGTK, xercesc }:
+{ lib, stdenv, fetchurl, aspell, boost, expat, intltool, libxml2, libxslt, pcre, wxGTK, xercesc }:
 
 stdenv.mkDerivation rec {
   pname = "xmlcopyeditor";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast, free, validating XML editor";
     homepage = "http://xml-copy-editor.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/editors/yi/wrapper.nix b/pkgs/applications/editors/yi/wrapper.nix
index 243690bc2632d..a7456590ab811 100644
--- a/pkgs/applications/editors/yi/wrapper.nix
+++ b/pkgs/applications/editors/yi/wrapper.nix
@@ -1,6 +1,6 @@
 # To use this for hacking of your Yi config file, drop into a shell
 # with env attribute.
-{ stdenv, makeWrapper
+{ lib, stdenv, makeWrapper
 , haskellPackages
 , extraPackages ? (s: [])
 }:
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
   # For hacking purposes
   passthru.env = yiEnv;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows Yi to find libraries and the compiler easily";
     # This wrapper and wrapper only is under PD
     license = licenses.publicDomain;
diff --git a/pkgs/applications/editors/zile/default.nix b/pkgs/applications/editors/zile/default.nix
index 5181c2c67678d..81c86fb400edc 100644
--- a/pkgs/applications/editors/zile/default.nix
+++ b/pkgs/applications/editors/zile/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, glib, libgee, pkg-config, ncurses, boehmgc, perl, help2man, vala }:
+{ fetchurl, lib, stdenv, glib, libgee, pkg-config, ncurses, boehmgc, perl, help2man, vala }:
 
 stdenv.mkDerivation rec {
   name = "zile-2.6.0.90";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   # XXX: Work around cross-compilation-unfriendly `gl_FUNC_FSTATAT' macro.
   gl_cv_func_fstatat_zero_flag="yes";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight Emacs clone";
 
     longDescription = ''
diff --git a/pkgs/applications/gis/gmt/dcw.nix b/pkgs/applications/gis/gmt/dcw.nix
index 58390e8929032..bc253f394c7ff 100644
--- a/pkgs/applications/gis/gmt/dcw.nix
+++ b/pkgs/applications/gis/gmt/dcw.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "dcw-gmt";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     cp -rv ./* $out/share/dcw-gmt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.soest.hawaii.edu/pwessel/dcw/";
     description = "Vector basemap of the world, for use with GMT";
     longDescription = ''
diff --git a/pkgs/applications/gis/gmt/default.nix b/pkgs/applications/gis/gmt/default.nix
index f045ec067fee3..0e2b45888b488 100644
--- a/pkgs/applications/gis/gmt/default.nix
+++ b/pkgs/applications/gis/gmt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, curl, Accelerate, CoreGraphics, CoreVideo
+{ lib, stdenv, fetchurl, cmake, curl, Accelerate, CoreGraphics, CoreVideo
 , fftwSinglePrec, netcdf, pcre, gdal, blas, lapack, glibc, ghostscript, dcw-gmt
 , gshhg-gmt }:
 
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
       "-DBLAS_LIBRARY=${blas}/lib/libblas.so"
     ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.generic-mapping-tools.org";
     description = "Tools for manipulating geographic and cartesian data sets";
     longDescription = ''
diff --git a/pkgs/applications/gis/gmt/gshhg.nix b/pkgs/applications/gis/gmt/gshhg.nix
index 0f22f87c89b5f..62758c71d594e 100644
--- a/pkgs/applications/gis/gmt/gshhg.nix
+++ b/pkgs/applications/gis/gmt/gshhg.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "gshhg-gmt";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     cp -rv ./* $out/share/gshhg-gmt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.soest.hawaii.edu/pwessel/gshhg/";
     description = "High-resolution shoreline data set, for use with GMT";
     longDescription = ''
diff --git a/pkgs/applications/gis/openorienteering-mapper/default.nix b/pkgs/applications/gis/openorienteering-mapper/default.nix
index 45c38b3e5732b..e4307e244ad0c 100644
--- a/pkgs/applications/gis/openorienteering-mapper/default.nix
+++ b/pkgs/applications/gis/openorienteering-mapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchFromGitHub
 , substituteAll
@@ -75,7 +75,7 @@ mkDerivation rec {
     ln -s $out/Applications/Mapper.app/Contents/MacOS/Mapper $out/bin/mapper
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       OpenOrienteering Mapper is an orienteering mapmaking program
       and provides a free alternative to the existing proprietary solution.
diff --git a/pkgs/applications/gis/whitebox-tools/default.nix b/pkgs/applications/gis/whitebox-tools/default.nix
index 61c2bbc542cd1..c31701901ec5d 100644
--- a/pkgs/applications/gis/whitebox-tools/default.nix
+++ b/pkgs/applications/gis/whitebox-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, Security }:
 rustPlatform.buildRustPackage rec {
   pname = "whitebox_tools";
   version = "1.4.0";
@@ -14,7 +14,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "09rz8f1xyc64qjbj6pgw8jxr2a7chghmdc6sfkbv7hdvx6vg4wvk";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An advanced geospatial data analysis platform";
     homepage = "https://jblindsay.github.io/ghrg/WhiteboxTools/index.html";
     license = licenses.mit;
diff --git a/pkgs/applications/graphics/ImageMagick/7.0.nix b/pkgs/applications/graphics/ImageMagick/7.0.nix
index 558112763a23a..9d52046ba0cb1 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 0222efff64299..42f157e531396 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 c5f1bf8680185..a994ae271c9c3 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 6fc84e088dd39..27d5ece57fe63 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 95be29abba54a..d92ad9998f2c3 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 84a005445316f..462962d9e188b 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 166bc135c1936..0313115ddfa8f 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 8d50696efcbd2..1f58ee83e03af 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 cd7937f8a5498..54cc09a4d18f0 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 6d4fa501710df..65fc56f81b1c0 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 c2e7ce6f35d37..74dc55fc5e137 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 52a2589b409cc..4b5974825543f 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 425ede0375931..4317cc78cda3b 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 27d4a4ab0e2e5..c93b94ee18360 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 6af6d93477a55..66309ebf7acf8 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 6ec54201fbfa5..da6047a025666 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 4d09f2ad5fe0c..a7fc17ce29b10 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 0bb4364d6fa9a..31dff2f9c2d6e 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 bdbdf04bcd504..75f1fb9acd156 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 39c23eb4fe8c3..c50b6d0c2ad8f 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 c81ba1240173c..e90d0e13f2254 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 7f0167f983424..4754cc1a02414 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 cd7db3d29c50d..c22bbbb482783 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 f560ad45c5742..05260dc9812a2 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 73cfdccea8166..ee75d6e1ae05a 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 1c272cf44e24f..cb37a81d9e1a2 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 75c43f06d2c3a..e7eb2c4f92acd 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 2962825e49b13..2771559416bf6 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 629abb3321d5f..7167700c244c9 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 84f5abfce0631..7ea76c9a82455 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 be487fcb8a6bd..c6b7b60c98e81 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 0d4b06c8c6d51..425762fdaa966 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 c36d576cc8e2f..e4a82703febb4 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 771109fb55d21..ec51e077c5688 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 9e3ab37c32233..e686aa4f35919 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 965ac5db68219..6ea67e332129a 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 7dbe03d9f281e..c97e28c9f9afb 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 1a8a552aa4f48..17d1dc3267665 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 8e9998dde393f..69fdb9e2e114d 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 9ae7ae2cb8ce4..fbee1d5b0e83d 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 d47369f5094a0..7e3238e94bbc7 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 22a35b3a4cc33..c0115d95ac809 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 5943632930c57..cb2301d6339e1 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 06549468efe98..d3640a656f131 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 71e156881c40d..067abb785b479 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 810b19ba90a66..be89d32e722a9 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 013d3bec3527e..affd934e93682 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 8beaf43c089c5..cac930dae1435 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 e15aedd77e1c8..1660d89eacf93 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 265ce82b8ac3f..6095d81c528df 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 5fe35edabdf6f..1a7320bf6930e 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 c74f35e4334af..c333ecaa99fde 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 eaef8c13b7c8f..4f3e08bf7b0f2 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 e5aac9b8823d2..80abca80f87f0 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 d0d9f100878f3..1872d976f8e3d 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 e53c36b59cd93..2756414d30dee 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 5e950eeac04ba..39a287900a9af 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 811a907746d55..9b1dbe537956d 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 24c80a6bd8770..81077578eb272 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 5425b8bef23c0..c894de2c93308 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 7502ab69c3206..395ae028423a0 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 7267e8401600b..3b030a1eb578c 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 d79a356657436..3c571fedb830c 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 678bc12278df6..e49093c568cbd 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 80f5926811105..476d56fb3fe3c 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 28fe58183faec..95ff90a8eeff2 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 0d1d64f3dd05c..a74043730bf58 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 89d49a1514577..b200b9be8cd9e 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 1f2861e7109c9..8bd82c783932a 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 d0c8d1c9ee941..6e4738dd07c11 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 e699b453bcf54..9fdf92a4ae80a 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 3f91fae0beb7f..3a06c8e31f7de 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 19e8121ac08d8..be3b07bf4cc76 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 3c89f3ffac03f..b44130c47ae19 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 f619d79c0f55d..ca2455dd048c9 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 cb8ef65b2e9e6..436d6764c75fe 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 7020bf6c83e65..21960358a7bd5 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 e34d5a87a4785..d4788b3c1e764 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 dd8e84349fad8..9392f27c1713f 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 96efc091ef2b0..969a3bcb9d14f 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 de5ae4fcbfd31..434f9fab88df6 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 f9dc494b4b35a..65ecaa90784d7 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 d3dd917d7b7dd..e0426de6fb621 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 1653ea9272062..635da088e5604 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 7e9547c1067cd..e86436cd06f24 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 aa6db0accdba8..73341cf2ea055 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 c2edecb858f7e..f9e3662f1b809 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 d3e8b417017d1..cef48daca11ad 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 885dff311b8f1..86a1f201f8267 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 e4598193469b8..361f1fa180949 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 c041d2dde8ccd..992a7f7879944 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 cddc99eebe29e..2d2e332977f05 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 18d8d546a7775..26b544cf1c5d8 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 ffc19653dade4..e9507129a2c04 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 e2ffd16025857..14f502434b287 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 2f47ebab66e40..ac8da654f0576 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 ac382bb632780..f695cb2b0d76a 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 e1a0cfa95204f..c30aeb15a0c2f 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 1addb2d7bd56a..9718dee45dd83 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 3c2ad8f4fab0d..d03c29a58ecef 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 fe5a13703329a..3f35880b3f229 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 cc7013739985c..482134269d2b2 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 8a5d9c3597b83..066e6cf2fb13e 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 c21d0ed20545a..c6aa330329c22 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 33aa3ae3575e9..20e01a1701dad 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 67f43faf99a30..d2c569b91c68c 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 d7c83704dca42..8a498fbe7ea3a 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 6cc59a7e60bdd..435f4ccaf6db6 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;
diff --git a/pkgs/applications/logging/humioctl/default.nix b/pkgs/applications/logging/humioctl/default.nix
index bcaf4a3627fe6..a5131d14ca9fe 100644
--- a/pkgs/applications/logging/humioctl/default.nix
+++ b/pkgs/applications/logging/humioctl/default.nix
@@ -1,4 +1,4 @@
-{ buildGoModule, fetchFromGitHub, installShellFiles, stdenv }:
+{ buildGoModule, fetchFromGitHub, installShellFiles, lib, stdenv }:
 
 let
   humioCtlVersion = "0.28.1";
@@ -30,7 +30,7 @@ in buildGoModule {
       installShellCompletion humioctl.{bash,zsh}
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/humio/cli";
       description = "A CLI for managing and sending data to Humio";
       license = licenses.asl20;
diff --git a/pkgs/applications/misc/1password/default.nix b/pkgs/applications/misc/1password/default.nix
index e6a55421a9164..4f4841bb2ed06 100644
--- a/pkgs/applications/misc/1password/default.nix
+++ b/pkgs/applications/misc/1password/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, autoPatchelfHook, fetchurl, xar, cpio }:
+{ lib, stdenv, fetchzip, autoPatchelfHook, fetchurl, xar, cpio }:
 
 stdenv.mkDerivation rec {
   pname = "1password";
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     $out/bin/op --version
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "1Password command-line tool";
     homepage     = "https://support.1password.com/command-line/";
     downloadPage = "https://app-updates.agilebits.com/product_history/CLI";
diff --git a/pkgs/applications/misc/ArchiSteamFarm/default.nix b/pkgs/applications/misc/ArchiSteamFarm/default.nix
index 8e55090e4c170..c753721adbf0a 100644
--- a/pkgs/applications/misc/ArchiSteamFarm/default.nix
+++ b/pkgs/applications/misc/ArchiSteamFarm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, makeWrapper, dotnetCorePackages, jq }:
+{ lib, stdenv, fetchurl, unzip, makeWrapper, dotnetCorePackages, jq }:
 
 stdenv.mkDerivation rec {
   pname = "ArchiSteamFarm";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
       --run "ln -sf $dist/www ."
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Application with primary purpose of idling Steam cards from multiple accounts simultaneously";
     homepage = "https://github.com/JustArchiNET/ArchiSteamFarm";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/OSCAR/default.nix b/pkgs/applications/misc/OSCAR/default.nix
index e619ad8c69712..7115801d00bbf 100644
--- a/pkgs/applications/misc/OSCAR/default.nix
+++ b/pkgs/applications/misc/OSCAR/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitLab, qmake, qtbase, qttools, qtserialport, libGLU }:
+{ lib, stdenv, mkDerivation, fetchFromGitLab, qmake, qtbase, qttools, qtserialport, libGLU }:
 mkDerivation rec {
   pname = "OSCAR";
   version = "1.2.0";
@@ -34,7 +34,7 @@ mkDerivation rec {
     install -T Building/Linux/OSCAR.desktop $out/share/applications/OSCAR.desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.sleepfiles.com/OSCAR/";
     description = "Software for reviewing and exploring data produced by CPAP and related machines used in the treatment of sleep apnea";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/airtame/default.nix b/pkgs/applications/misc/airtame/default.nix
index a5c08ad3642af..58fcf4cb10ddc 100644
--- a/pkgs/applications/misc/airtame/default.nix
+++ b/pkgs/applications/misc/airtame/default.nix
@@ -69,7 +69,7 @@ in stdenv.mkDerivation rec {
 
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://airtame.com/download";
     description = "Wireless streaming client for Airtame devices";
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/almanah/default.nix b/pkgs/applications/misc/almanah/default.nix
index 7d5c468ab971d..b2b6815f7df11 100644
--- a/pkgs/applications/misc/almanah/default.nix
+++ b/pkgs/applications/misc/almanah/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , atk
 , cairo
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small GTK application to allow to keep a diary of your life";
     homepage = "https://wiki.gnome.org/Apps/Almanah_Diary";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/antfs-cli/default.nix b/pkgs/applications/misc/antfs-cli/default.nix
index 49da252b6c0d1..133194f7af516 100644
--- a/pkgs/applications/misc/antfs-cli/default.nix
+++ b/pkgs/applications/misc/antfs-cli/default.nix
@@ -1,10 +1,10 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication {
   pname = "antfs-cli";
   version = "unstable-2017-02-11";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Tigge/antfs-cli";
     description = "Extracts FIT files from ANT-FS based sport watches";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/ape/clex.nix b/pkgs/applications/misc/ape/clex.nix
index c680ffe967834..a98695dab6825 100644
--- a/pkgs/applications/misc/ape/clex.nix
+++ b/pkgs/applications/misc/ape/clex.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "attempto-clex";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp clex_lexicon.pl $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Large lexicon for APE (~100,000 entries)";
     license = licenses.gpl3;
     platforms = platforms.unix;
diff --git a/pkgs/applications/misc/ape/default.nix b/pkgs/applications/misc/ape/default.nix
index dda6c812c8d8e..f16d6e1573323 100644
--- a/pkgs/applications/misc/ape/default.nix
+++ b/pkgs/applications/misc/ape/default.nix
@@ -1,9 +1,9 @@
-{ stdenv, swiProlog, makeWrapper,
+{ lib, stdenv, swiProlog, makeWrapper,
   fetchFromGitHub,
   lexiconPath ? "prolog/lexicon/clex_lexicon.pl",
   pname ? "ape",
   description ? "Parser for Attempto Controlled English (ACE)",
-  license ? with stdenv.lib; licenses.lgpl3
+  license ? with lib; licenses.lgpl3
 }:
 
 stdenv.mkDerivation rec {
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     makeWrapper $out/ape.exe $out/bin/ape --add-flags ace
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = description;
     license = license;
     platforms = platforms.unix;
diff --git a/pkgs/applications/misc/appeditor/default.nix b/pkgs/applications/misc/appeditor/default.nix
index ab58f9237647c..20ee9a254941b 100644
--- a/pkgs/applications/misc/appeditor/default.nix
+++ b/pkgs/applications/misc/appeditor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , vala
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Edit the Pantheon desktop application menu";
     homepage = "https://github.com/donadigo/appeditor";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/misc/apvlv/default.nix b/pkgs/applications/misc/apvlv/default.nix
index aa052426e7244..f80dfeb107513 100644
--- a/pkgs/applications/misc/apvlv/default.nix
+++ b/pkgs/applications/misc/apvlv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, cmake, pkg-config, pcre, libxkbcommon, epoxy
+{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, pkg-config, pcre, libxkbcommon, epoxy
 , gtk3, poppler, freetype, libpthreadstubs, libXdmcp, libxshmfence, wrapGAppsHook
 }:
 
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     install -D ../apvlv.desktop $out/share/applications/apvlv.desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://naihe2010.github.io/apvlv/";
     description = "PDF viewer with Vim-like behaviour";
     longDescription = ''
diff --git a/pkgs/applications/misc/archivy/default.nix b/pkgs/applications/misc/archivy/default.nix
index 635cd9a991a62..c94011466ec35 100644
--- a/pkgs/applications/misc/archivy/default.nix
+++ b/pkgs/applications/misc/archivy/default.nix
@@ -47,7 +47,7 @@ python3.pkgs.buildPythonApplication rec {
   # __init__.py attempts to mkdir in read-only file system
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Self-hosted knowledge repository";
     homepage = "https://archivy.github.io";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/artha/default.nix b/pkgs/applications/misc/artha/default.nix
index 648a2cfd99459..bc31b844f18d7 100644
--- a/pkgs/applications/misc/artha/default.nix
+++ b/pkgs/applications/misc/artha/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoreconfHook, fetchurl, dbus-glib, gtk2, pkgconfig, wordnet }:
+{ lib, stdenv, autoreconfHook, fetchurl, dbus-glib, gtk2, pkgconfig, wordnet }:
 
 stdenv.mkDerivation {
   pname = "artha";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     ./gio-underlink.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An offline thesaurus based on WordNet";
     homepage = "http://artha.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/asciiquarium/default.nix b/pkgs/applications/misc/asciiquarium/default.nix
index 592c0938ffbd4..a4276dac1d1f3 100644
--- a/pkgs/applications/misc/asciiquarium/default.nix
+++ b/pkgs/applications/misc/asciiquarium/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, perlPackages }:
+{ lib, stdenv, fetchurl, makeWrapper, perlPackages }:
 
 let version = "1.1";
 in stdenv.mkDerivation {
@@ -20,7 +20,7 @@ in stdenv.mkDerivation {
       --set PERL5LIB ${perlPackages.makeFullPerlPath [ perlPackages.TermAnimation ] }
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enjoy the mysteries of the sea from the safety of your own terminal!";
     homepage = "https://robobunny.com/projects/asciiquarium/html/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/audio/wavrsocvt/default.nix b/pkgs/applications/misc/audio/wavrsocvt/default.nix
index 7f8ff3d6d2198..3b32f0d7f30bc 100644
--- a/pkgs/applications/misc/audio/wavrsocvt/default.nix
+++ b/pkgs/applications/misc/audio/wavrsocvt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "wavrsocvt-1.0.2.0";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp wavrsocvt $out/bin
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert .wav files into sound files for Lego NXT brick";
     longDescription = ''
     wavrsocvt is a command-line utility which can be used from a
diff --git a/pkgs/applications/misc/ausweisapp2/default.nix b/pkgs/applications/misc/ausweisapp2/default.nix
index dc46edc070fd1..e4305118b573d 100644
--- a/pkgs/applications/misc/ausweisapp2/default.nix
+++ b/pkgs/applications/misc/ausweisapp2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, pkgconfig, pcsclite, qtsvg, qttools, qtwebsockets
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, pkgconfig, pcsclite, qtsvg, qttools, qtwebsockets
 , qtquickcontrols2, qtgraphicaleffects }:
 
 mkDerivation rec {
@@ -16,7 +16,7 @@ mkDerivation rec {
 
   buildInputs = [ qtsvg qttools qtwebsockets qtquickcontrols2 qtgraphicaleffects pcsclite ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Authentication software for the German ID card";
     downloadPage = "https://github.com/Governikus/AusweisApp2/releases";
     homepage = "https://www.ausweisapp.bund.de/ausweisapp2/";
diff --git a/pkgs/applications/misc/autospotting/default.nix b/pkgs/applications/misc/autospotting/default.nix
index f2e922e5b4d16..0b57ad292661c 100644
--- a/pkgs/applications/misc/autospotting/default.nix
+++ b/pkgs/applications/misc/autospotting/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage {
   pname = "autospotting";
@@ -17,7 +17,7 @@ buildGoPackage {
     sed -i "s+github.com/cristim/autospotting/core+github.com/AutoSpotting/AutoSpotting/core+" autospotting.go
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AutoSpotting/AutoSpotting";
     description = "Automatically convert your existing AutoScaling groups to up to 90% cheaper spot instances with minimal configuration changes";
     license = licenses.free;
diff --git a/pkgs/applications/misc/avrdudess/default.nix b/pkgs/applications/misc/avrdudess/default.nix
index f4a56e4f92403..4e5e253fd07f2 100644
--- a/pkgs/applications/misc/avrdudess/default.nix
+++ b/pkgs/applications/misc/avrdudess/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, runtimeShell, fetchurl, unzip, mono, avrdude, gtk2, xdg_utils }:
+{ lib, stdenv, runtimeShell, fetchurl, unzip, mono, avrdude, gtk2, xdg_utils }:
 
 stdenv.mkDerivation {
   name = "avrdudess-2.2.20140102";
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
     chmod a+x "$out/bin/"*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for AVRDUDE (AVR microcontroller programmer)";
     homepage = "https://github.com/zkemble/AVRDUDESS";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/batsignal/default.nix b/pkgs/applications/misc/batsignal/default.nix
index 90fca4ce28cee..93e16ea3469df 100644
--- a/pkgs/applications/misc/batsignal/default.nix
+++ b/pkgs/applications/misc/batsignal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libnotify, pkg-config, glib }:
+{ lib, stdenv, fetchFromGitHub, libnotify, pkg-config, glib }:
 
 stdenv.mkDerivation rec {
   pname = "batsignal";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkg-config ];
   installFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/electrickite/batsignal";
     description = "Lightweight battery daemon written in C";
     license = licenses.isc;
diff --git a/pkgs/applications/misc/bicon/default.nix b/pkgs/applications/misc/bicon/default.nix
index 41b0d3c13a80e..72f5a639f11f6 100644
--- a/pkgs/applications/misc/bicon/default.nix
+++ b/pkgs/applications/misc/bicon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
   , fetchFromGitHub
   , autoreconfHook
   , pkg-config
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     patchShebangs .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A bidirectional console";
     homepage =  "https://github.com/behdad/bicon";
     license = [ licenses.lgpl21 licenses.psfl licenses.bsd0 ];
diff --git a/pkgs/applications/misc/bleachbit/default.nix b/pkgs/applications/misc/bleachbit/default.nix
index 3c11c7bfaf576..31da1e8d4955f 100644
--- a/pkgs/applications/misc/bleachbit/default.nix
+++ b/pkgs/applications/misc/bleachbit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python3Packages
 , fetchurl
 , gettext
@@ -59,7 +59,7 @@ python3Packages.buildPythonApplication rec {
 
   strictDeps = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://bleachbit.sourceforge.net";
     description = "A program to clean your computer";
     longDescription = "BleachBit helps you easily clean your computer to free space and maintain privacy.";
diff --git a/pkgs/applications/misc/blender/default.nix b/pkgs/applications/misc/blender/default.nix
index 905e765185c27..9921fdc7a797c 100644
--- a/pkgs/applications/misc/blender/default.nix
+++ b/pkgs/applications/misc/blender/default.nix
@@ -146,7 +146,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "3D Creation/Animation/Publishing System";
     homepage = "https://www.blender.org";
     # They comment two licenses: GPLv2 and Blender License, but they
diff --git a/pkgs/applications/misc/blogc/default.nix b/pkgs/applications/misc/blogc/default.nix
index 72e26191456fd..57be731a1213a 100644
--- a/pkgs/applications/misc/blogc/default.nix
+++ b/pkgs/applications/misc/blogc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, ronn, git, cmocka }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, ronn, git, cmocka }:
 
 stdenv.mkDerivation rec {
   pname = "blogc";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A blog compiler";
     license = licenses.bsd3;
     homepage = "https://blogc.rgm.io";
diff --git a/pkgs/applications/misc/blugon/default.nix b/pkgs/applications/misc/blugon/default.nix
index 9aa8d3da39a0d..d11a61e440fb8 100644
--- a/pkgs/applications/misc/blugon/default.nix
+++ b/pkgs/applications/misc/blugon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, libX11, libXrandr }:
+{ lib, stdenv, fetchFromGitHub, python3, libX11, libXrandr }:
 
 stdenv.mkDerivation rec {
   pname = "blugon";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple and configurable Blue Light Filter for X";
     longDescription = ''
       blugon is a simple and fast Blue Light Filter, that is highly configurable and provides a command line interface.
diff --git a/pkgs/applications/misc/break-time/default.nix b/pkgs/applications/misc/break-time/default.nix
index 4bcc4de5157d6..05815e242f024 100644
--- a/pkgs/applications/misc/break-time/default.nix
+++ b/pkgs/applications/misc/break-time/default.nix
@@ -5,7 +5,7 @@
 , pkg-config
 , python3
 , rustPlatform
-, stdenv
+, lib, stdenv
 , wrapGAppsHook
 }:
 
@@ -34,7 +34,7 @@ rustPlatform.buildRustPackage rec {
     openssl
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Break timer that forces you to take a break";
     homepage    = "https://github.com/cdepillabout/break-time";
     license     = with licenses; [ mit ];
diff --git a/pkgs/applications/misc/buku/default.nix b/pkgs/applications/misc/buku/default.nix
index 459b2159a93f5..9568c38d4344a 100644
--- a/pkgs/applications/misc/buku/default.nix
+++ b/pkgs/applications/misc/buku/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchFromGitHub }:
+{ lib, stdenv, python3, fetchFromGitHub }:
 
 with python3.pkgs; buildPythonApplication rec {
   version = "4.5";
@@ -70,7 +70,7 @@ with python3.pkgs; buildPythonApplication rec {
     cp auto-completion/fish/* $out/share/fish/vendor_completions.d
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Private cmdline bookmark manager";
     homepage = "https://github.com/jarun/Buku";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/calcurse/default.nix b/pkgs/applications/misc/calcurse/default.nix
index a3cad7d9f2e7b..ba8edb2baa50f 100644
--- a/pkgs/applications/misc/calcurse/default.nix
+++ b/pkgs/applications/misc/calcurse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, gettext, python3, python3Packages, makeWrapper }:
+{ lib, stdenv, fetchurl, ncurses, gettext, python3, python3Packages, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "calcurse";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     patchPythonScript $out/bin/calcurse-caldav
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A calendar and scheduling application for the command line";
     longDescription = ''
       calcurse is a calendar and scheduling application for the command line. It helps
diff --git a/pkgs/applications/misc/candle/default.nix b/pkgs/applications/misc/candle/default.nix
index eb4ac9c9b34da..d3357b41bd2e3 100644
--- a/pkgs/applications/misc/candle/default.nix
+++ b/pkgs/applications/misc/candle/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, qtbase, qtserialport, qmake }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, qtbase, qtserialport, qmake }:
 
 mkDerivation rec {
   pname = "candle";
@@ -23,7 +23,7 @@ mkDerivation rec {
 
   buildInputs = [ qtbase qtserialport ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GRBL controller application with G-Code visualizer written in Qt";
     homepage = "https://github.com/Denvi/Candle";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/cardpeek/default.nix b/pkgs/applications/misc/cardpeek/default.nix
index 83340f78dd482..c565a1bf99417 100644
--- a/pkgs/applications/misc/cardpeek/default.nix
+++ b/pkgs/applications/misc/cardpeek/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook,
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook,
   glib, gtk3, pcsclite, lua5_2, curl, readline }:
 let
   version = "0.8.4";
@@ -19,7 +19,7 @@ in
 
     enableParallelBuilding = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/L1L1/cardpeek";
       description = "A tool to read the contents of ISO7816 smart cards";
       license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/cataract/build.nix b/pkgs/applications/misc/cataract/build.nix
index 1c33a92987c15..3347321d71d2e 100644
--- a/pkgs/applications/misc/cataract/build.nix
+++ b/pkgs/applications/misc/cataract/build.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , autoreconfHook
 , glib
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     cp src/cgg{,-dirgen} $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cgg.bzatek.net/";
     description = "A simple static web photo gallery, designed to be clean and easily usable";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/catclock/default.nix b/pkgs/applications/misc/catclock/default.nix
index 6b4ab1f3a8bf2..9c6b1812683a0 100644
--- a/pkgs/applications/misc/catclock/default.nix
+++ b/pkgs/applications/misc/catclock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xlibsWrapper, motif }:
+{ lib, stdenv, fetchFromGitHub, xlibsWrapper, motif }:
 
 stdenv.mkDerivation {
   name = "catclock-2015-10-04";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ xlibsWrapper motif ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://codefromabove.com/2014/05/catclock/";
     license = with licenses; mit;
     maintainers = with maintainers; [ ramkromberg ];
diff --git a/pkgs/applications/misc/cbatticon/default.nix b/pkgs/applications/misc/cbatticon/default.nix
index e7664244db7bb..e77958b724d8a 100644
--- a/pkgs/applications/misc/cbatticon/default.nix
+++ b/pkgs/applications/misc/cbatticon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, gettext, glib, gtk3, libnotify, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, gettext, glib, gtk3, libnotify, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "cbatticon";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight and fast battery icon that sits in the system tray";
     homepage = "https://github.com/valr/cbatticon";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/cheat/default.nix b/pkgs/applications/misc/cheat/default.nix
index 208c9c5331371..988af330deb59 100644
--- a/pkgs/applications/misc/cheat/default.nix
+++ b/pkgs/applications/misc/cheat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , buildGoModule, installShellFiles }:
 
 buildGoModule rec {
@@ -25,7 +25,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create and view interactive cheatsheets on the command-line";
     maintainers = with maintainers; [ mic92 ];
     license = with licenses; [ gpl3 mit ];
diff --git a/pkgs/applications/misc/chewing-editor/default.nix b/pkgs/applications/misc/chewing-editor/default.nix
index 3a89773b85870..e1a57bb5300fc 100644
--- a/pkgs/applications/misc/chewing-editor/default.nix
+++ b/pkgs/applications/misc/chewing-editor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, pkgconfig, libchewing, qtbase
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, pkgconfig, libchewing, qtbase
 , qttools }:
 
 mkDerivation rec {
@@ -17,7 +17,7 @@ mkDerivation rec {
   nativeBuildInputs = [ cmake pkgconfig ];
   buildInputs = [ libchewing qtbase qttools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross platform chewing user phrase editor";
     longDescription = ''
       chewing-editor is a cross platform chewing user phrase editor. It provides a easy way to manage user phrase. With it, user can customize their user phrase to increase input performance.
diff --git a/pkgs/applications/misc/cipher/default.nix b/pkgs/applications/misc/cipher/default.nix
index 630519ff2bfff..ccf7da70f6ee7 100644
--- a/pkgs/applications/misc/cipher/default.nix
+++ b/pkgs/applications/misc/cipher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple application for encoding and decoding text, designed for elementary OS";
     homepage = "https://github.com/arshubham/cipher";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/misc/clipit/default.nix b/pkgs/applications/misc/clipit/default.nix
index cc6d7d29fcd4e..97ac54731c9fd 100644
--- a/pkgs/applications/misc/clipit/default.nix
+++ b/pkgs/applications/misc/clipit/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, fetchpatch, stdenv
+{ fetchFromGitHub, fetchpatch, lib, stdenv
 , autoreconfHook, intltool, pkgconfig
 , gtk3, libayatana-appindicator, xdotool, which, wrapGAppsHook }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     "--prefix" "PATH" ":" "${stdenv.lib.makeBinPath [ xdotool which ]}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight GTK Clipboard Manager";
     inherit (src.meta) homepage;
     license     = licenses.gpl3;
diff --git a/pkgs/applications/misc/clipmenu/default.nix b/pkgs/applications/misc/clipmenu/default.nix
index f616e86c5b774..e3a0046205e04 100644
--- a/pkgs/applications/misc/clipmenu/default.nix
+++ b/pkgs/applications/misc/clipmenu/default.nix
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
       --set PATH "${lib.makeBinPath [ clipnotify coreutils gawk util-linux xdotool xsel ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clipboard management using dmenu";
     inherit (src.meta) homepage;
     maintainers = with maintainers; [ jb55 ];
diff --git a/pkgs/applications/misc/cmatrix/default.nix b/pkgs/applications/misc/cmatrix/default.nix
index fa0e10f9eef82..8008edf099692 100644
--- a/pkgs/applications/misc/cmatrix/default.nix
+++ b/pkgs/applications/misc/cmatrix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, ncurses }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "cmatrix";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simulates the falling characters theme from The Matrix movie";
     license = licenses.gpl3;
     longDescription = ''
diff --git a/pkgs/applications/misc/colort/default.nix b/pkgs/applications/misc/colort/default.nix
index 1eda11890e795..a4283e5ebb934 100644
--- a/pkgs/applications/misc/colort/default.nix
+++ b/pkgs/applications/misc/colort/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   name = "colort-unstable-2017-03-12";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
 
   makeFlags = ["PREFIX=$(out)"];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program for 'tinting' color values";
     homepage = "https://github.com/neeasade/colort";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/corectrl/default.nix b/pkgs/applications/misc/corectrl/default.nix
index 090a63a32e4f6..3e129a81b162f 100644
--- a/pkgs/applications/misc/corectrl/default.nix
+++ b/pkgs/applications/misc/corectrl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , extra-cmake-modules
 , botan2
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec{
     wrapQtApp $out/bin/corectrl --prefix PATH ":" ${binPath}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/corectrl/corectrl/";
     description = "Control your computer hardware via application profiles";
     longDescription = ''
diff --git a/pkgs/applications/misc/coursera-dl/default.nix b/pkgs/applications/misc/coursera-dl/default.nix
index bbb7c53b61f65..631d53b506fc0 100644
--- a/pkgs/applications/misc/coursera-dl/default.nix
+++ b/pkgs/applications/misc/coursera-dl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glibcLocales, pandoc, python3 }:
+{ lib, stdenv, fetchFromGitHub, glibcLocales, pandoc, python3 }:
 
 let
   pythonPackages = python3.pkgs;
@@ -36,7 +36,7 @@ in pythonPackages.buildPythonApplication rec {
     py.test -k 'not test_get_credentials_with_keyring' .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI for downloading Coursera.org videos and naming them";
     homepage = "https://github.com/coursera-dl/coursera-dl";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/applications/misc/cpu-x/default.nix b/pkgs/applications/misc/cpu-x/default.nix
index a92ca30c5d800..236c2d6d43327 100644
--- a/pkgs/applications/misc/cpu-x/default.nix
+++ b/pkgs/applications/misc/cpu-x/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, gtk3, ncurses
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, gtk3, ncurses
 , libcpuid, pciutils, procps, wrapGAppsHook, nasm, makeWrapper }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ stdenv.cc ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free software that gathers information on CPU, motherboard and more";
     homepage = src.meta.homepage;
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/ctodo/default.nix b/pkgs/applications/misc/ctodo/default.nix
index 0c6a42fccdc54..224a79881e043 100644
--- a/pkgs/applications/misc/ctodo/default.nix
+++ b/pkgs/applications/misc/ctodo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, ncurses, readline }:
+{ lib, stdenv, fetchFromGitHub, cmake, ncurses, readline }:
 
 stdenv.mkDerivation rec {
   pname = "ctodo";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ ncurses readline ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ctodo.apakoh.dk/";
     description = "A simple ncurses-based task list manager";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/cum/default.nix b/pkgs/applications/misc/cum/default.nix
index 2675a5f4fc5d2..6b851e80f3468 100644
--- a/pkgs/applications/misc/cum/default.nix
+++ b/pkgs/applications/misc/cum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 with python3Packages;
 
@@ -26,7 +26,7 @@ buildPythonApplication rec {
     rm -rf $out/tests $out/LICENSE
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "comic updater, mangafied";
     homepage = "https://github.com/Hamuko/cum";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/cura/lulzbot/libarcus.nix b/pkgs/applications/misc/cura/lulzbot/libarcus.nix
index 5edaabbacb0f7..1e186bdf5fd2a 100644
--- a/pkgs/applications/misc/cura/lulzbot/libarcus.nix
+++ b/pkgs/applications/misc/cura/lulzbot/libarcus.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchgit, fetchurl, cmake, sip, protobuf, pythonOlder }:
+{ lib, stdenv, buildPythonPackage, fetchgit, fetchurl, cmake, sip, protobuf, pythonOlder }:
 
 buildPythonPackage {
   pname = "libarcus";
@@ -22,7 +22,7 @@ buildPythonPackage {
     sed -i '/SET(ENV{PYTHONPATH}/d' cmake/FindSIP.cmake
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Communication library between internal components for Ultimaker software";
     homepage = "https://code.alephobjects.com/source/arcus/";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/applications/misc/cura/lulzbot/libsavitar.nix b/pkgs/applications/misc/cura/lulzbot/libsavitar.nix
index e32117a103ee0..fb920235031f1 100644
--- a/pkgs/applications/misc/cura/lulzbot/libsavitar.nix
+++ b/pkgs/applications/misc/cura/lulzbot/libsavitar.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchgit, cmake, sip }:
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchgit, cmake, sip }:
 
 buildPythonPackage {
   pname = "libsavitar-lulzbot";
@@ -23,7 +23,7 @@ buildPythonPackage {
 
   disabled = pythonOlder "3.4.0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C++ implementation of 3mf loading with SIP python bindings";
     homepage = "https://github.com/Ultimaker/libSavitar";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/applications/misc/cura/lulzbot/uranium.nix b/pkgs/applications/misc/cura/lulzbot/uranium.nix
index 2ce0fab170ea0..77a4f3edef655 100644
--- a/pkgs/applications/misc/cura/lulzbot/uranium.nix
+++ b/pkgs/applications/misc/cura/lulzbot/uranium.nix
@@ -1,4 +1,4 @@
-{ stdenv, callPackage, fetchurl, fetchgit, buildPythonPackage, fetchFromGitHub, python, cmake
+{ lib, stdenv, callPackage, fetchurl, fetchgit, buildPythonPackage, fetchFromGitHub, python, cmake
 , pyqt5, numpy, scipy, shapely, libarcusLulzbot, doxygen, gettext, pythonOlder }:
 
 buildPythonPackage {
@@ -27,7 +27,7 @@ buildPythonPackage {
      UM/Application.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python framework for building Desktop applications";
     homepage = "https://code.alephobjects.com/diffusion/U/";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/applications/misc/cura/plugins.nix b/pkgs/applications/misc/cura/plugins.nix
index 9082feb38a7a0..699df0e1936fc 100644
--- a/pkgs/applications/misc/cura/plugins.nix
+++ b/pkgs/applications/misc/cura/plugins.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, python3Packages }:
 
 let
 
@@ -24,7 +24,7 @@ let
         cp -rv . $out/lib/cura/plugins/OctoPrintPlugin/
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "Enables printing directly to OctoPrint and monitoring the process";
         homepage = "https://github.com/fieldOfView/Cura-OctoPrintPlugin";
         license = licenses.agpl3;
diff --git a/pkgs/applications/misc/cura/stable.nix b/pkgs/applications/misc/cura/stable.nix
index 87d2aba891b63..5383cbe9a23ab 100644
--- a/pkgs/applications/misc/cura/stable.nix
+++ b/pkgs/applications/misc/cura/stable.nix
@@ -1,4 +1,4 @@
-{ stdenv, python27Packages, curaengine, makeDesktopItem, fetchurl }:
+{ lib, stdenv, python27Packages, curaengine, makeDesktopItem, fetchurl }:
 let
   py = python27Packages;
   version = "15.04";
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
     ln -s "$resources/images/c.png" "$out"/share/icons/cura.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "3D printing host software";
     homepage = "https://github.com/daid/Cura";
     license = licenses.agpl3;
diff --git a/pkgs/applications/misc/curaengine/default.nix b/pkgs/applications/misc/curaengine/default.nix
index 8993c01a6bd25..4a4558ba2893b 100644
--- a/pkgs/applications/misc/curaengine/default.nix
+++ b/pkgs/applications/misc/curaengine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libarcus, stb, protobuf }:
+{ lib, stdenv, fetchFromGitHub, cmake, libarcus, stb, protobuf }:
 
 stdenv.mkDerivation rec {
   pname = "curaengine";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DCURA_ENGINE_VERSION=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A powerful, fast and robust engine for processing 3D models into 3D printing instruction";
     homepage = "https://github.com/Ultimaker/CuraEngine";
     license = licenses.agpl3;
diff --git a/pkgs/applications/misc/curaengine/stable.nix b/pkgs/applications/misc/curaengine/stable.nix
index 394a94f19ab89..23041c2fe37eb 100644
--- a/pkgs/applications/misc/curaengine/stable.nix
+++ b/pkgs/applications/misc/curaengine/stable.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 let
   version = "15.04.6";
 in
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     cp build/CuraEngine $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Engine for processing 3D models into 3D printing instructions";
     homepage = "https://github.com/Ultimaker/CuraEngine";
     license = licenses.agpl3;
diff --git a/pkgs/applications/misc/dasel/default.nix b/pkgs/applications/misc/dasel/default.nix
index c8f7016435ef2..3a46b5e2f9a61 100644
--- a/pkgs/applications/misc/dasel/default.nix
+++ b/pkgs/applications/misc/dasel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 }:
@@ -31,7 +31,7 @@ buildGoModule rec {
     fi
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Query and update data structures from the command line";
     longDescription = ''
       Dasel (short for data-selector) allows you to query and modify data structures using selector strings.
diff --git a/pkgs/applications/misc/dbeaver/default.nix b/pkgs/applications/misc/dbeaver/default.nix
index f14f5aec8cb68..e1c73393ec5f2 100644
--- a/pkgs/applications/misc/dbeaver/default.nix
+++ b/pkgs/applications/misc/dbeaver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, makeWrapper
+{ lib, stdenv, fetchurl, makeDesktopItem, makeWrapper
 , fontconfig, freetype, glib, gtk3
 , jdk, libX11, libXrender, libXtst, zlib }:
 
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     ln -s $out/dbeaver/icon.xpm $out/share/pixmaps/dbeaver.xpm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://dbeaver.io/";
     description = "Universal SQL Client for developers, DBA and analysts. Supports MySQL, PostgreSQL, MariaDB, SQLite, and more";
     longDescription = ''
diff --git a/pkgs/applications/misc/ddgr/default.nix b/pkgs/applications/misc/ddgr/default.nix
index 1cac8811103d7..850bca3320eab 100644
--- a/pkgs/applications/misc/ddgr/default.nix
+++ b/pkgs/applications/misc/ddgr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, python3, installShellFiles }:
 
 stdenv.mkDerivation rec {
   version = "1.9";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     installShellCompletion --zsh auto-completion/zsh/_ddgr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jarun/ddgr";
     description = "Search DuckDuckGo from the terminal";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/deadd-notification-center/default.nix b/pkgs/applications/misc/deadd-notification-center/default.nix
index 00820874bce4e..8414e02eb889e 100644
--- a/pkgs/applications/misc/deadd-notification-center/default.nix
+++ b/pkgs/applications/misc/deadd-notification-center/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , autoPatchelfHook
 , gtk3
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     sed "s|##PREFIX##|$out|g" ${dbusService} > $out/share/dbus-1/services/com.ph-uhl.deadd.notification.service
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A haskell-written notification center for users that like a desktop with style";
     homepage = "https://github.com/phuhl/linux_notification_center";
     license = licenses.bsd3;
diff --git a/pkgs/applications/misc/deco/default.nix b/pkgs/applications/misc/deco/default.nix
index ad8b56e830fad..2ea3483f1bac7 100644
--- a/pkgs/applications/misc/deco/default.nix
+++ b/pkgs/applications/misc/deco/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, scsh, feh, xorg }:
+{ lib, stdenv, fetchFromGitHub, scsh, feh, xorg }:
 
 stdenv.mkDerivation rec {
   pname = "deco";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/bin/deco --replace "xdpyinfo" "${xorg.xdpyinfo}/bin/xdpyinfo"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ebzzry/deco";
     description = "A simple root image setter";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/devdocs-desktop/default.nix b/pkgs/applications/misc/devdocs-desktop/default.nix
index 7c1726961339c..3425ceb44a932 100644
--- a/pkgs/applications/misc/devdocs-desktop/default.nix
+++ b/pkgs/applications/misc/devdocs-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appimageTools, fetchurl, gsettings-desktop-schemas, gtk3 }:
+{ lib, stdenv, appimageTools, fetchurl, gsettings-desktop-schemas, gtk3 }:
 
 let
   version = "0.7.1";
@@ -29,7 +29,7 @@ in appimageTools.wrapType2 rec {
       --replace 'Exec=AppRun' 'Exec=${pname}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full-featured desktop app for DevDocs.io";
     longDescription = ''
       DevDocs.io combines multiple API documentations in a fast, organized, and searchable interface. This is an unofficial desktop app for it.
diff --git a/pkgs/applications/misc/devilspie2/default.nix b/pkgs/applications/misc/devilspie2/default.nix
index 2961baee10243..70fb38d17c409 100644
--- a/pkgs/applications/misc/devilspie2/default.nix
+++ b/pkgs/applications/misc/devilspie2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, pkgconfig, glib, gtk, lua, libwnck3 }:
+{ lib, stdenv, fetchurl, intltool, pkgconfig, glib, gtk, lua, libwnck3 }:
 
 stdenv.mkDerivation rec {
   pname = "devilspie2";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp devilspie2.1 $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A window matching utility";
     longDescription = ''
       Devilspie2 is a window matching utility, allowing the user to
diff --git a/pkgs/applications/misc/diff-pdf/default.nix b/pkgs/applications/misc/diff-pdf/default.nix
index 83116da4df05b..471755c6392bf 100644
--- a/pkgs/applications/misc/diff-pdf/default.nix
+++ b/pkgs/applications/misc/diff-pdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, pkgconfig, cairo, poppler, wxGTK ? null, wxmac ? null, darwin ? null }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, pkgconfig, cairo, poppler, wxGTK ? null, wxmac ? null, darwin ? null }:
 
 let
   wxInputs =
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "./bootstrap";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://vslavik.github.io/diff-pdf/";
     description = "Simple tool for visually comparing two PDF files";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/ding/default.nix b/pkgs/applications/misc/ding/default.nix
index 374c4cf66487e..4f06708e47e99 100644
--- a/pkgs/applications/misc/ding/default.nix
+++ b/pkgs/applications/misc/ding/default.nix
@@ -1,4 +1,4 @@
-{ aspell, aspellDicts_de, aspellDicts_en, buildEnv, fetchurl, fortune, gnugrep, makeWrapper, stdenv, tk, tre }:
+{ aspell, aspellDicts_de, aspellDicts_en, buildEnv, fetchurl, fortune, gnugrep, makeWrapper, lib, stdenv, tk, tre }:
 let
   aspellEnv = buildEnv {
     name = "env-ding-aspell";
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/ding --prefix PATH : ${stdenv.lib.makeBinPath [ gnugrep aspellEnv tk fortune ]} --prefix ASPELL_CONF : "\"prefix ${aspellEnv};\""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple and fast dictionary lookup tool";
     homepage = "https://www-user.tu-chemnitz.de/~fri/ding/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/djvulibre/default.nix b/pkgs/applications/misc/djvulibre/default.nix
index afb7b6cf13915..d4384e829cf51 100644
--- a/pkgs/applications/misc/djvulibre/default.nix
+++ b/pkgs/applications/misc/djvulibre/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , libjpeg
 , libtiff
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     ./CVE-2019-15145.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The big set of CLI tools to make/modify/optimize/show/export DJVU files";
     homepage = "http://djvu.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/dmensamenu/default.nix b/pkgs/applications/misc/dmensamenu/default.nix
index cf02efdcece50..a0b4237c7f675 100644
--- a/pkgs/applications/misc/dmensamenu/default.nix
+++ b/pkgs/applications/misc/dmensamenu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub, substituteAll, requests, dmenu }:
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub, substituteAll, requests, dmenu }:
 
 buildPythonApplication rec {
   pname = "dmensamenu";
@@ -25,7 +25,7 @@ buildPythonApplication rec {
   # No tests implemented
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dotlambda/dmensamenu";
     description = "Print German canteen menus using dmenu and OpenMensa";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/dmenu/default.nix b/pkgs/applications/misc/dmenu/default.nix
index f83c5fc7f01fb..62f02ce67142b 100644
--- a/pkgs/applications/misc/dmenu/default.nix
+++ b/pkgs/applications/misc/dmenu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXinerama, libXft, zlib, patches ? null }:
+{ lib, stdenv, fetchurl, libX11, libXinerama, libXft, zlib, patches ? null }:
 
 stdenv.mkDerivation rec {
   name = "dmenu-5.0";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "CC:=$(CC)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
       description = "A generic, highly customizable, and efficient menu for the X Window System";
       homepage = "https://tools.suckless.org/dmenu";
       license = licenses.mit;
diff --git a/pkgs/applications/misc/dmenu/wayland.nix b/pkgs/applications/misc/dmenu/wayland.nix
index 250a7567d782c..8d77588ce8f1b 100644
--- a/pkgs/applications/misc/dmenu/wayland.nix
+++ b/pkgs/applications/misc/dmenu/wayland.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, cairo, pango, pkg-config, wayland-protocols
+{ lib, stdenv, fetchFromGitHub, meson, ninja, cairo, pango, pkg-config, wayland-protocols
 , glib, wayland, libxkbcommon, makeWrapper
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     platforms = platforms.linux;
     description = "dmenu for wayland-compositors";
diff --git a/pkgs/applications/misc/dockbarx/default.nix b/pkgs/applications/misc/dockbarx/default.nix
index 13d837aceec55..e0e9fcd6febfd 100644
--- a/pkgs/applications/misc/dockbarx/default.nix
+++ b/pkgs/applications/misc/dockbarx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, gnome2, keybinder }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, gnome2, keybinder }:
 
 pythonPackages.buildPythonApplication rec {
   ver = "0.93";
@@ -28,10 +28,10 @@ pythonPackages.buildPythonApplication rec {
     ++ (with gnome2; [ gnome_python gnome_python_desktop ])
     ++ [ keybinder ];
 
-    # no tests
-    doCheck = false;
+  # no tests
+  doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/dockbar/";
     description = "Lightweight taskbar / panel replacement for Linux which works as a stand-alone dock";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/doomseeker/default.nix b/pkgs/applications/misc/doomseeker/default.nix
index 999904a21d3c0..37f75c4fdd5c7 100644
--- a/pkgs/applications/misc/doomseeker/default.nix
+++ b/pkgs/applications/misc/doomseeker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, cmake, fetchFromBitbucket, pkgconfig, qtbase, qttools, qtmultimedia, zlib, bzip2, xxd }:
+{ lib, stdenv, mkDerivation, cmake, fetchFromBitbucket, pkgconfig, qtbase, qttools, qtmultimedia, zlib, bzip2, xxd }:
 
 mkDerivation {
   pname = "doomseeker";
@@ -18,7 +18,7 @@ mkDerivation {
 
   hardeningDisable = stdenv.lib.optional stdenv.isDarwin "format";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://doomseeker.drdteam.org/";
     description = "Multiplayer server browser for many Doom source ports";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/dotfiles/default.nix b/pkgs/applications/misc/dotfiles/default.nix
index b515074fd4750..913ed9523baae 100644
--- a/pkgs/applications/misc/dotfiles/default.nix
+++ b/pkgs/applications/misc/dotfiles/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonPackages }:
+{ lib, stdenv, pythonPackages }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "dotfiles";
@@ -15,7 +15,7 @@ pythonPackages.buildPythonApplication rec {
   checkInputs = with pythonPackages; [ pytest ];
   propagatedBuildInputs = with pythonPackages; [ click ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easily manage your dotfiles";
     homepage = "https://github.com/jbernard/dotfiles";
     license = licenses.isc;
diff --git a/pkgs/applications/misc/dstask/default.nix b/pkgs/applications/misc/dstask/default.nix
index 0c2f25b2653f7..78efa133c1e4f 100644
--- a/pkgs/applications/misc/dstask/default.nix
+++ b/pkgs/applications/misc/dstask/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "dstask";
@@ -32,7 +32,7 @@ buildGoModule rec {
 
   subPackages = [ "cmd/dstask.go" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line todo list with super-reliable git sync";
     homepage = src.meta.homepage;
     license = licenses.mit;
diff --git a/pkgs/applications/misc/dupeguru/default.nix b/pkgs/applications/misc/dupeguru/default.nix
index 51e1b77096d23..7a9e293964050 100644
--- a/pkgs/applications/misc/dupeguru/default.nix
+++ b/pkgs/applications/misc/dupeguru/default.nix
@@ -1,4 +1,4 @@
-{stdenv, python3Packages, fetchpatch, gettext, qt5, fetchFromGitHub}:
+{lib, stdenv, python3Packages, fetchpatch, gettext, qt5, fetchFromGitHub}:
 
 python3Packages.buildPythonApplication rec {
   pname = "dupeguru";
@@ -61,7 +61,7 @@ python3Packages.buildPythonApplication rec {
     wrapPythonProgramsIn "$out/share/dupeguru" "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI tool to find duplicate files in a system";
     homepage = "https://github.com/arsenetar/dupeguru";
     license = licenses.bsd3;
diff --git a/pkgs/applications/misc/eaglemode/default.nix b/pkgs/applications/misc/eaglemode/default.nix
index 052e290120d76..806d960222da5 100644
--- a/pkgs/applications/misc/eaglemode/default.nix
+++ b/pkgs/applications/misc/eaglemode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, libX11, libXinerama, libjpeg, libpng, libtiff, pkgconfig,
+{ lib, stdenv, fetchurl, perl, libX11, libXinerama, libjpeg, libpng, libtiff, pkgconfig,
 librsvg, glib, gtk2, libXext, libXxf86vm, poppler, xineLib, ghostscript, makeWrapper }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/eaglemode --set EM_DIR "$out" --prefix LD_LIBRARY_PATH : "$out/lib" --prefix PATH : "${ghostscript}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://eaglemode.sourceforge.net";
     description = "Zoomable User Interface";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/effitask/default.nix b/pkgs/applications/misc/effitask/default.nix
index 26008c133b827..b80ec80746f32 100644
--- a/pkgs/applications/misc/effitask/default.nix
+++ b/pkgs/applications/misc/effitask/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , pkg-config
@@ -34,7 +34,7 @@ rustPlatform.buildRustPackage rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical task manager, based on the todo.txt format";
     longDescription = ''
       To use it as todo.sh add-on, create a symlink like this:
diff --git a/pkgs/applications/misc/electrum/dash.nix b/pkgs/applications/misc/electrum/dash.nix
index 33a8284744e50..29ac8b4484b57 100644
--- a/pkgs/applications/misc/electrum/dash.nix
+++ b/pkgs/applications/misc/electrum/dash.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python2Packages }:
+{ lib, stdenv, fetchurl, python2Packages }:
 
 python2Packages.buildPythonApplication rec {
   version = "2.9.3.1";
@@ -37,7 +37,7 @@ python2Packages.buildPythonApplication rec {
     pyrcc4 icons.qrc -o gui/qt/icons_rc.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Electrum DASH";
     homepage = "https://github.com/dashpay/electrum-dash";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/electrum/default.nix b/pkgs/applications/misc/electrum/default.nix
index ac963c890dcfd..215aa3dd5f24b 100644
--- a/pkgs/applications/misc/electrum/default.nix
+++ b/pkgs/applications/misc/electrum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchFromGitHub
 , wrapQtAppsHook
@@ -139,7 +139,7 @@ python3.pkgs.buildPythonApplication {
     ;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight Bitcoin wallet";
     longDescription = ''
       An easy-to-use Bitcoin client featuring wallets generated from
diff --git a/pkgs/applications/misc/electrum/ltc.nix b/pkgs/applications/misc/electrum/ltc.nix
index 7d6480b4696c9..ad6ed6f7a783c 100644
--- a/pkgs/applications/misc/electrum/ltc.nix
+++ b/pkgs/applications/misc/electrum/ltc.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python3Packages
 , wrapQtAppsHook
@@ -46,7 +46,7 @@ python3Packages.buildPythonApplication rec {
     $out/bin/electrum-ltc help >/dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Litecoin thin client";
     longDescription = ''
       Electrum-LTC is a simple, but powerful Litecoin wallet. A twelve-word
diff --git a/pkgs/applications/misc/elfx86exts/default.nix b/pkgs/applications/misc/elfx86exts/default.nix
index 56a3751a0bfb9..8fc7fb32743db 100644
--- a/pkgs/applications/misc/elfx86exts/default.nix
+++ b/pkgs/applications/misc/elfx86exts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 }:
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1dfhx40jr5llqa554wifd920mqdbm8s5fns98m6vcqdjxzan4nr2";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Decode x86 binaries and print out which instruction set extensions they use.";
     longDescription = ''
       Disassemble a binary containing x86 instructions and print out which extensions it uses.
diff --git a/pkgs/applications/misc/emem/default.nix b/pkgs/applications/misc/emem/default.nix
index e0fcc221100e1..ab718cdffcf26 100644
--- a/pkgs/applications/misc/emem/default.nix
+++ b/pkgs/applications/misc/emem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jdk }:
+{ lib, stdenv, fetchurl, jdk }:
 
 stdenv.mkDerivation rec {
   pname = "emem";
@@ -28,7 +28,7 @@ EOF
     chmod +x $out/bin/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ebzzry/emem";
     description = "A trivial Markdown to HTML converter";
     license = licenses.epl10;
diff --git a/pkgs/applications/misc/epdfview/default.nix b/pkgs/applications/misc/epdfview/default.nix
index 7cbae2271aea9..90884af9fdf46 100644
--- a/pkgs/applications/misc/epdfview/default.nix
+++ b/pkgs/applications/misc/epdfview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, gtk2, poppler }:
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, gtk2, poppler }:
 
 stdenv.mkDerivation rec {
   pname = "epdfview";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
               })
             ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://packages.debian.org/wheezy/epdfview";
     description = "A lightweight PDF document viewer using Poppler and GTK";
     longDescription = ''
diff --git a/pkgs/applications/misc/et/default.nix b/pkgs/applications/misc/et/default.nix
index 9ab3fda96dc21..0de4ad9e21f33 100644
--- a/pkgs/applications/misc/et/default.nix
+++ b/pkgs/applications/misc/et/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libnotify, gdk-pixbuf }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libnotify, gdk-pixbuf }:
 
 stdenv.mkDerivation rec {
   pname = "et";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp et-status.sh $out/bin/et-status
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minimal libnotify-based (egg) timer";
     homepage = "https://github.com/oxzi/et";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/eureka-editor/default.nix b/pkgs/applications/misc/eureka-editor/default.nix
index 7cee0487ea823..0b5922f8f699c 100644
--- a/pkgs/applications/misc/eureka-editor/default.nix
+++ b/pkgs/applications/misc/eureka-editor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, fltk, zlib, xdg_utils, xorg, libjpeg, libGL }:
+{ lib, stdenv, fetchzip, fltk, zlib, xdg_utils, xorg, libjpeg, libGL }:
 
 stdenv.mkDerivation rec {
   pname = "eureka-editor";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     cp misc/eureka.6 $out/man/man6
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://eureka-editor.sourceforge.net";
     description = "A map editor for the classic DOOM games, and a few related games such as Heretic and Hexen";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/evtest/default.nix b/pkgs/applications/misc/evtest/default.nix
index d6d20367b0600..7ed1afd14f856 100644
--- a/pkgs/applications/misc/evtest/default.nix
+++ b/pkgs/applications/misc/evtest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, pkgconfig, libxml2 }:
+{ lib, stdenv, fetchgit, autoreconfHook, pkgconfig, libxml2 }:
 
 stdenv.mkDerivation rec {
   pname = "evtest";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     sha256 = "168gdhzj11f4nk94a6z696sm8v1njzwww69bn6wr97l17897913g";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple tool for input event debugging";
     license = stdenv.lib.licenses.gpl2;
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/exercism/default.nix b/pkgs/applications/misc/exercism/default.nix
index 87e59d4292fcd..1eeeba1b4391f 100644
--- a/pkgs/applications/misc/exercism/default.nix
+++ b/pkgs/applications/misc/exercism/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "exercism";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   subPackages = [ "./exercism" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
    inherit (src.meta) homepage;
    description = "A Go based command line tool for exercism.io";
    license     = licenses.mit;
diff --git a/pkgs/applications/misc/far2l/default.nix b/pkgs/applications/misc/far2l/default.nix
index eb7314a870dba..75d0ec3f7965d 100644
--- a/pkgs/applications/misc/far2l/default.nix
+++ b/pkgs/applications/misc/far2l/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, makeWrapper, cmake, pkgconfig, wxGTK30, glib, pcre, m4, bash,
+{ lib, stdenv, fetchFromGitHub, fetchpatch, makeWrapper, cmake, pkgconfig, wxGTK30, glib, pcre, m4, bash,
   xdg_utils, gvfs, zip, unzip, gzip, bzip2, gnutar, p7zip, xz, imagemagick, darwin }:
 
 let
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
 
   stripDebugList = [ "bin" "share" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An orthodox file manager";
     homepage = "https://github.com/elfmz/far2l";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/fbmenugen/default.nix b/pkgs/applications/misc/fbmenugen/default.nix
index bc40f2dad8316..26b8beab19cdc 100644
--- a/pkgs/applications/misc/fbmenugen/default.nix
+++ b/pkgs/applications/misc/fbmenugen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fluxbox
 , gnused
@@ -65,7 +65,7 @@ perlPackages.buildPerlPackage rec {
     wrapProgram "$out/bin/${pname}" --prefix PERL5LIB : "$PERL5LIB"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/trizen/fbmenugen";
     description = "Simple menu generator for the Fluxbox Window Manager";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/fbreader/default.nix b/pkgs/applications/misc/fbreader/default.nix
index 187988077435c..fff5bf1680d50 100644
--- a/pkgs/applications/misc/fbreader/default.nix
+++ b/pkgs/applications/misc/fbreader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig
+{ lib, stdenv, fetchFromGitHub, fetchpatch, pkgconfig
 , bzip2, curl, expat, fribidi, libunibreak, sqlite, zlib
 , uiTarget ? if !stdenv.isDarwin then "desktop" else "macosx"
 , uiType ? if !stdenv.isDarwin then "qt4" else "cocoa"
@@ -63,7 +63,7 @@ stdenv.mkDerivation {
 
   NIX_CFLAGS_COMPILE = "-Wno-error=narrowing";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An e-book reader for Linux";
     homepage = "http://www.fbreader.org/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/fehlstart/default.nix b/pkgs/applications/misc/fehlstart/default.nix
index cae637c2c4a48..55d47459aedde 100644
--- a/pkgs/applications/misc/fehlstart/default.nix
+++ b/pkgs/applications/misc/fehlstart/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, gtk2, keybinder, fetchFromGitLab }:
+{ lib, stdenv, pkgconfig, gtk2, keybinder, fetchFromGitLab }:
 
 stdenv.mkDerivation {
   name = "fehlstart-9f4342d7";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     export PREFIX=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small desktop application launcher with reasonable memory footprint";
     homepage = "https://gitlab.com/fehlstart/fehlstart";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/fff/default.nix b/pkgs/applications/misc/fff/default.nix
index cf307afd1bddd..5b007ccb37fce 100644
--- a/pkgs/applications/misc/fff/default.nix
+++ b/pkgs/applications/misc/fff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, bashInteractive, xdg_utils, file, coreutils, w3m, xdotool }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, bashInteractive, xdg_utils, file, coreutils, w3m, xdotool }:
 
 stdenv.mkDerivation rec {
   pname = "fff";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     wrapProgram "$out/bin/fff" --prefix PATH : $pathAdd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fucking Fast File-Manager";
     homepage = "https://github.com/dylanaraps/fff";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/filet/default.nix b/pkgs/applications/misc/filet/default.nix
index ee4b05fa689f2..0ee3f6fb221ae 100644
--- a/pkgs/applications/misc/filet/default.nix
+++ b/pkgs/applications/misc/filet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "filet";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fucking fucking fast file fucker (afffff)";
     homepage = "https://github.com/buffet/filet";
     license = licenses.mpl20;
diff --git a/pkgs/applications/misc/firestarter/default.nix b/pkgs/applications/misc/firestarter/default.nix
index a03c87eb41b5f..3af59d0ddfa59 100644
--- a/pkgs/applications/misc/firestarter/default.nix
+++ b/pkgs/applications/misc/firestarter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glibc, python3, cudatoolkit,
+{ lib, stdenv, fetchFromGitHub, glibc, python3, cudatoolkit,
   withCuda ? true
 }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     cp FIRESTARTER $out/bin/firestarter
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tu-dresden.de/zih/forschung/projekte/firestarter";
     description = "Processor Stress Test Utility";
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/flamerobin/default.nix b/pkgs/applications/misc/flamerobin/default.nix
index 2e389c753e2ed..8178288ba56ea 100644
--- a/pkgs/applications/misc/flamerobin/default.nix
+++ b/pkgs/applications/misc/flamerobin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, wxGTK30, boost, firebird }:
+{ lib, stdenv, fetchFromGitHub, wxGTK30, boost, firebird }:
 
 stdenv.mkDerivation rec {
   version = "0.9.3.1";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     "--disable-debug"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Database administration tool for Firebird RDBMS";
     homepage = "https://github.com/mariuz/flamerobin";
     license = licenses.bsdOriginal;
diff --git a/pkgs/applications/misc/fme/default.nix b/pkgs/applications/misc/fme/default.nix
index 5af6ae03f24cf..1a4b38a1cad38 100644
--- a/pkgs/applications/misc/fme/default.nix
+++ b/pkgs/applications/misc/fme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, autoconf, automake, gettext
+{ lib, stdenv, fetchurl, pkgconfig, autoconf, automake, gettext
 , fluxbox, bc, gtkmm2, glibmm, libglademm, libsigcxx }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Editor for Fluxbox menus";
     longDescription = ''
       Fluxbox Menu Editor is a menu editor for the Window Manager Fluxbox written in C++
diff --git a/pkgs/applications/misc/font-manager/default.nix b/pkgs/applications/misc/font-manager/default.nix
index defbe7520d7c2..8b8fc09f7d35b 100644
--- a/pkgs/applications/misc/font-manager/default.nix
+++ b/pkgs/applications/misc/font-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, gettext, python3,
+{ lib, stdenv, fetchFromGitHub, meson, ninja, gettext, python3,
   pkgconfig, libxml2, json-glib , sqlite, itstool, librsvg, yelp-tools,
   vala, gtk3, gnome3, desktop-file-utils, wrapGAppsHook, gobject-introspection
 }:
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson_post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fontmanager.github.io/";
     description = "Simple font management for GTK desktop environments";
     longDescription = ''
diff --git a/pkgs/applications/misc/fontpreview/default.nix b/pkgs/applications/misc/fontpreview/default.nix
index 1d4e4d3e00feb..7fa2e4d89102a 100644
--- a/pkgs/applications/misc/fontpreview/default.nix
+++ b/pkgs/applications/misc/fontpreview/default.nix
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${lib.makeBinPath [ xdotool fzf imagemagick sxiv getopt ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sdushantha/fontpreview";
     description = "Highly customizable and minimal font previewer written in bash";
     longDescription = ''
diff --git a/pkgs/applications/misc/formatter/default.nix b/pkgs/applications/misc/formatter/default.nix
index 85a70812cad11..71479c4ac3e88 100644
--- a/pkgs/applications/misc/formatter/default.nix
+++ b/pkgs/applications/misc/formatter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple formatter designed for elementary OS";
     homepage = "https://github.com/Djaler/Formatter";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/misc/foxtrotgps/default.nix b/pkgs/applications/misc/foxtrotgps/default.nix
index 9ac7010149062..5d0f07492a1b2 100644
--- a/pkgs/applications/misc/foxtrotgps/default.nix
+++ b/pkgs/applications/misc/foxtrotgps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchbzr, autoreconfHook, texinfo, help2man, imagemagick, pkg-config
+{ lib, stdenv, fetchbzr, autoreconfHook, texinfo, help2man, imagemagick, pkg-config
 , curl, gnome2, gpsd, gtk2, wrapGAppsHook
 , intltool, libexif, python3Packages, sqlite }:
 
@@ -49,7 +49,7 @@ in stdenv.mkDerivation rec {
   intltoolize --automake --copy --force
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GPS/GIS application optimized for small screens";
     longDescription = ''
       An easy to use, free & open-source GPS/GIS application that works well on
diff --git a/pkgs/applications/misc/freemind/default.nix b/pkgs/applications/misc/freemind/default.nix
index 5774320220a16..b87c43226e0a2 100644
--- a/pkgs/applications/misc/freemind/default.nix
+++ b/pkgs/applications/misc/freemind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jdk, jre, ant }:
+{ lib, stdenv, fetchurl, jdk, jre, ant }:
 
 stdenv.mkDerivation rec {
   pname = "freemind";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/{bin/freemind,nix-support/dist/freemind.sh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mind-mapping software";
     homepage = "http://freemind.sourceforge.net/wiki/index.php/Main_Page";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/fsv/default.nix b/pkgs/applications/misc/fsv/default.nix
index ff556621f9ae6..71e60a11caa23 100644
--- a/pkgs/applications/misc/fsv/default.nix
+++ b/pkgs/applications/misc/fsv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, autoreconfHook
+{ lib, stdenv, fetchurl, fetchFromGitHub, autoreconfHook
 , libtool, pkgconfig, gtk2, libGLU, file
 }:
 
@@ -34,7 +34,7 @@ in stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook libtool pkgconfig ];
   buildInputs       = [ file gtk2 libGLU gtkglarea ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description     = "File system visualizer in cyberspace";
     longDescription = ''
       fsv (pronounced eff-ess-vee) is a file system visualizer in cyberspace.
diff --git a/pkgs/applications/misc/fusee-interfacee-tk/default.nix b/pkgs/applications/misc/fusee-interfacee-tk/default.nix
index 90ab3b11c13dd..813b8113ee30d 100644
--- a/pkgs/applications/misc/fusee-interfacee-tk/default.nix
+++ b/pkgs/applications/misc/fusee-interfacee-tk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv , fetchFromGitHub , python3 , makeWrapper }:
+{ lib, stdenv , fetchFromGitHub , python3 , makeWrapper }:
 
 let pythonEnv = python3.withPackages(ps: [ ps.tkinter ps.pyusb ]);
 in stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ in stdenv.mkDerivation rec {
     cp intermezzo.bin $out/bin/intermezzo.bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nh-server/fusee-interfacee-tk";
     description = "A tool to send .bin files to a Nintendo Switch in RCM mode";
     longDescription = "A mod of falquinhos Fusée Launcher for use with Nintendo Homebrew Switch Guide. It also adds the ability to mount SD while in RCM.
diff --git a/pkgs/applications/misc/gImageReader/default.nix b/pkgs/applications/misc/gImageReader/default.nix
index 2884fca623983..80ec6f82571ae 100644
--- a/pkgs/applications/misc/gImageReader/default.nix
+++ b/pkgs/applications/misc/gImageReader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, libuuid
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, libuuid
 , sane-backends, podofo, libjpeg, djvulibre, libxmlxx3, libzip, tesseract
 , intltool, poppler, json-glib
 , ninja
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
   # interface type can be where <type> is either gtk, qt5, qt4
   cmakeFlags = [ "-DINTERFACE_TYPE=${variant}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple Gtk/Qt front-end to tesseract-ocr";
     homepage = "https://github.com/manisandro/gImageReader";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/galculator/default.nix b/pkgs/applications/misc/galculator/default.nix
index 1964ba6aaf73a..6d7989412d445 100644
--- a/pkgs/applications/misc/galculator/default.nix
+++ b/pkgs/applications/misc/galculator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook, intltool
 , gtk, pkgconfig, flex }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook intltool pkgconfig ];
   buildInputs = [ gtk flex ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GTK 2/3 algebraic and RPN calculator";
     longDescription = ''
       galculator is a GTK 2 / GTK 3 based calculator. Its main features include:
diff --git a/pkgs/applications/misc/ganttproject-bin/default.nix b/pkgs/applications/misc/ganttproject-bin/default.nix
index b36bd83e70f60..2b4504a1dce2f 100644
--- a/pkgs/applications/misc/ganttproject-bin/default.nix
+++ b/pkgs/applications/misc/ganttproject-bin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, makeDesktopItem, makeWrapper
+{ lib, stdenv, fetchzip, makeDesktopItem, makeWrapper
 , jre
 }:
 
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     cp -rv "${desktopItem}/share/applications" "$out/share"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Project scheduling and management";
     homepage = "https://www.ganttproject.biz/";
     downloadPage = "https://www.ganttproject.biz/download";
diff --git a/pkgs/applications/misc/gcstar/default.nix b/pkgs/applications/misc/gcstar/default.nix
index b1ab386083ea1..f482b8af2898e 100644
--- a/pkgs/applications/misc/gcstar/default.nix
+++ b/pkgs/applications/misc/gcstar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , perlPackages
 , wrapGAppsHook
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/gcstar --prefix PERL5LIB : $PERL5LIB
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/Kerenoc/GCstar";
     description = "Manage your collections of movies, games, books, music and more";
     longDescription = ''
diff --git a/pkgs/applications/misc/geoipupdate/default.nix b/pkgs/applications/misc/geoipupdate/default.nix
index 707a7adb8a18b..1e0aba0400f0a 100644
--- a/pkgs/applications/misc/geoipupdate/default.nix
+++ b/pkgs/applications/misc/geoipupdate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "geoipupdate";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic GeoIP database updater";
     homepage = "https://github.com/maxmind/geoipupdate";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/applications/misc/getxbook/default.nix b/pkgs/applications/misc/getxbook/default.nix
index 8ac0b000c46d1..a69f8d7f05745 100644
--- a/pkgs/applications/misc/getxbook/default.nix
+++ b/pkgs/applications/misc/getxbook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl }:
+{ lib, stdenv, fetchurl, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "getxbook";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of tools to download books from Google Books";
     homepage    = "https://njw.me.uk/getxbook/";
     license     = licenses.isc;
diff --git a/pkgs/applications/misc/girara/default.nix b/pkgs/applications/misc/girara/default.nix
index 35e9d16f9df0a..4c61a4dad511d 100644
--- a/pkgs/applications/misc/girara/default.nix
+++ b/pkgs/applications/misc/girara/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, check, dbus, xvfb_run, glib, gtk, gettext, libiconv, json_c, libintl
+{ lib, stdenv, fetchurl, meson, ninja, pkgconfig, check, dbus, xvfb_run, glib, gtk, gettext, libiconv, json_c, libintl
 }:
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
       meson test --print-errorlogs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.pwmt.org/pwmt/girara";
     description = "User interface library";
     longDescription = ''
diff --git a/pkgs/applications/misc/glava/default.nix b/pkgs/applications/misc/glava/default.nix
index 88991bb40a192..daa74c3a41471 100644
--- a/pkgs/applications/misc/glava/default.nix
+++ b/pkgs/applications/misc/glava/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, writeScript, fetchFromGitHub
+{ lib, stdenv, writeScript, fetchFromGitHub
 , libGL, libX11, libXext, python3, libXrandr, libXrender, libpulseaudio, libXcomposite
 , enableGlfw ? false, glfw, runtimeShell }:
 
@@ -78,7 +78,7 @@ in
       chmod +x $out/bin/glava
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = ''
         OpenGL audio spectrum visualizer
       '';
diff --git a/pkgs/applications/misc/glom/default.nix b/pkgs/applications/misc/glom/default.nix
index 9af6e39cb9bbf..0c2bb9304b141 100644
--- a/pkgs/applications/misc/glom/default.nix
+++ b/pkgs/applications/misc/glom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , autoconf
@@ -121,7 +121,7 @@ in stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An easy-to-use database designer and user interface";
     homepage = "http://www.glom.org/";
     license = [ licenses.lgpl2 licenses.gpl2 ];
diff --git a/pkgs/applications/misc/gmrun/default.nix b/pkgs/applications/misc/gmrun/default.nix
index 8ca4c6061629b..b3ef510739bde 100644
--- a/pkgs/applications/misc/gmrun/default.nix
+++ b/pkgs/applications/misc/gmrun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glib, gtk2, pkgconfig, popt }:
+{ lib, stdenv, fetchurl, glib, gtk2, pkgconfig, popt }:
 
 let
   version = "0.9.2";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       ./gmrun-0.9.2-xdg.patch
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnome Completion-Run Utility";
     longDescription = ''
       A simple program which provides a "run program" window, featuring a bash-like TAB completion.
diff --git a/pkgs/applications/misc/gnome-firmware-updater/default.nix b/pkgs/applications/misc/gnome-firmware-updater/default.nix
index f007f0ae52e16..88be6b22f280d 100644
--- a/pkgs/applications/misc/gnome-firmware-updater/default.nix
+++ b/pkgs/applications/misc/gnome-firmware-updater/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , fetchpatch
 , appstream-glib
@@ -65,7 +65,7 @@ stdenv.mkDerivation rec {
     "-Dconsolekit=false"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/hughsie/gnome-firmware-updater";
     description = "Tool for installing firmware on devices";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/gnome-multi-writer/default.nix b/pkgs/applications/misc/gnome-multi-writer/default.nix
index 06bc0024995d8..628f93f5bbc6f 100644
--- a/pkgs/applications/misc/gnome-multi-writer/default.nix
+++ b/pkgs/applications/misc/gnome-multi-writer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , appstream-glib
 , desktop-file-utils
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for writing an ISO file to multiple USB devices at once";
     homepage = "https://wiki.gnome.org/Apps/MultiWriter";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/gnome-passwordsafe/default.nix b/pkgs/applications/misc/gnome-passwordsafe/default.nix
index dc84b312626ef..c6617cc2324ce 100644
--- a/pkgs/applications/misc/gnome-passwordsafe/default.nix
+++ b/pkgs/applications/misc/gnome-passwordsafe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , ninja
 , pkg-config
@@ -68,7 +68,7 @@ python3.pkgs.buildPythonApplication rec {
     libpwquality # using the python bindings
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = stdenv.hostPlatform.isStatic; # libpwquality doesn't provide bindings when static
     description = "Password manager for GNOME which makes use of the KeePass v.4 format";
     homepage = "https://gitlab.gnome.org/World/PasswordSafe";
diff --git a/pkgs/applications/misc/gnome-recipes/default.nix b/pkgs/applications/misc/gnome-recipes/default.nix
index cb9d10377cb8d..3e21e2cadb9f8 100644
--- a/pkgs/applications/misc/gnome-recipes/default.nix
+++ b/pkgs/applications/misc/gnome-recipes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -69,7 +69,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recipe management application for GNOME";
     homepage = "https://wiki.gnome.org/Apps/Recipes";
     maintainers = teams.gnome.members;
diff --git a/pkgs/applications/misc/gnome-usage/default.nix b/pkgs/applications/misc/gnome-usage/default.nix
index 44d4727edba06..ad956e9d02a74 100644
--- a/pkgs/applications/misc/gnome-usage/default.nix
+++ b/pkgs/applications/misc/gnome-usage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A nice way to view information about use of system resources, like memory and disk space";
     license = licenses.gpl3;
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/go-jira/default.nix b/pkgs/applications/misc/go-jira/default.nix
index 001f3d1de4c2f..c2871766debb1 100644
--- a/pkgs/applications/misc/go-jira/default.nix
+++ b/pkgs/applications/misc/go-jira/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "go-jira";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple command line client for Atlassian's Jira service written in Go";
     homepage = "https://github.com/go-jira/jira";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/golden-cheetah/default.nix b/pkgs/applications/misc/golden-cheetah/default.nix
index 362ba4a3a121b..57e2d95f0430b 100644
--- a/pkgs/applications/misc/golden-cheetah/default.nix
+++ b/pkgs/applications/misc/golden-cheetah/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, mkDerivation
+{ lib, stdenv, fetchFromGitHub, fetchpatch, mkDerivation
 , qtbase, qtsvg, qtserialport, qtwebengine, qtmultimedia, qttools
 , qtconnectivity, qtcharts, libusb-compat-0_1
 , yacc, flex, zlib, qmake, makeDesktopItem, makeWrapper
@@ -69,7 +69,7 @@ in mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Performance software for cyclists, runners and triathletes";
     platforms = platforms.linux;
     maintainers = [ ];
diff --git a/pkgs/applications/misc/goldendict/default.nix b/pkgs/applications/misc/goldendict/default.nix
index 65848fac95ec3..0fb4b3f2b974f 100644
--- a/pkgs/applications/misc/goldendict/default.nix
+++ b/pkgs/applications/misc/goldendict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, pkgconfig
+{ lib, stdenv, mkDerivation, fetchFromGitHub, pkgconfig
 , libXtst, libvorbis, hunspell, lzo, xz, bzip2, libiconv
 , qtbase, qtsvg, qtwebkit, qtx11extras, qttools, qmake
 , withCC ? true, opencc
@@ -59,7 +59,7 @@ mkDerivation rec {
     wrapQtApp $out/Applications/GoldenDict.app/Contents/MacOS/GoldenDict
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://goldendict.org/";
     description = "A feature-rich dictionary lookup program";
     platforms = with platforms; linux ++ darwin;
diff --git a/pkgs/applications/misc/gollum/default.nix b/pkgs/applications/misc/gollum/default.nix
index 9005f38f563be..e1698f06015de 100644
--- a/pkgs/applications/misc/gollum/default.nix
+++ b/pkgs/applications/misc/gollum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bundlerEnv, ruby, makeWrapper, bundlerUpdateScript
+{ lib, stdenv, bundlerEnv, ruby, makeWrapper, bundlerUpdateScript
 , git }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   passthru.updateScript = bundlerUpdateScript "gollum";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple, Git-powered wiki with a sweet API and local frontend";
     homepage = "https://github.com/gollum/gollum";
     changelog = "https://github.com/gollum/gollum/blob/v${version}/HISTORY.md";
diff --git a/pkgs/applications/misc/googleearth/default.nix b/pkgs/applications/misc/googleearth/default.nix
index db38810634541..641e0896f4eec 100644
--- a/pkgs/applications/misc/googleearth/default.nix
+++ b/pkgs/applications/misc/googleearth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glibc, libGLU, libGL, freetype, glib, libSM, libICE, libXi, libXv
+{ lib, stdenv, fetchurl, glibc, libGLU, libGL, freetype, glib, libSM, libICE, libXi, libXv
 , libXrender, libXrandr, libXfixes, libXcursor, libXinerama, libXext, libX11
 , zlib, fontconfig, dpkg, libproxy, libxml2, gst_all_1, dbus }:
 
@@ -96,7 +96,7 @@ stdenv.mkDerivation rec {
 
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A world sphere viewer";
     homepage = "http://earth.google.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/googler/default.nix b/pkgs/applications/misc/googler/default.nix
index 7a096b52314a0..f7a29c257f42a 100644
--- a/pkgs/applications/misc/googler/default.nix
+++ b/pkgs/applications/misc/googler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, python, installShellFiles }:
 
 stdenv.mkDerivation rec {
   pname = "googler";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     installShellCompletion --zsh auto-completion/zsh/_googler
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jarun/googler";
     description = "Google Search, Google Site Search, Google News from the terminal";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/gosmore/default.nix b/pkgs/applications/misc/gosmore/default.nix
index 4da6c6d07cc4d..4d55129193ff7 100644
--- a/pkgs/applications/misc/gosmore/default.nix
+++ b/pkgs/applications/misc/gosmore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchsvn, libxml2, gtk2, curl, pkgconfig } :
+{ lib, stdenv, fetchsvn, libxml2, gtk2, curl, pkgconfig } :
 
 let
   version = "31801";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
   patches = [ ./pointer_int_comparison.patch ];
   patchFlags = [ "-p1" "--binary" ]; # patch has dos style eol
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open Street Map viewer";
     homepage = "https://sourceforge.net/projects/gosmore/";
     maintainers = with maintainers; [
diff --git a/pkgs/applications/misc/gpa/default.nix b/pkgs/applications/misc/gpa/default.nix
index cd7b724a1d78f..6bda23aebe07e 100644
--- a/pkgs/applications/misc/gpa/default.nix
+++ b/pkgs/applications/misc/gpa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, pkgconfig, gtk2, gpgme, libgpgerror, libassuan }:
+{ lib, stdenv, fetchurl, intltool, pkgconfig, gtk2, gpgme, libgpgerror, libassuan }:
 
 stdenv.mkDerivation rec {
   name = "gpa-0.10.0";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ intltool pkgconfig ];
   buildInputs = [ gtk2 gpgme libgpgerror libassuan ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical user interface for the GnuPG";
     homepage = "https://www.gnupg.org/related_software/gpa/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/gphoto2/default.nix b/pkgs/applications/misc/gphoto2/default.nix
index 7bda292a4cbab..409aaded4b6ff 100644
--- a/pkgs/applications/misc/gphoto2/default.nix
+++ b/pkgs/applications/misc/gphoto2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , gettext
 , libexif
 , libgphoto2
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     readline
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A ready to use set of digital camera software applications";
     longDescription = ''
 
diff --git a/pkgs/applications/misc/gphoto2/gphotofs.nix b/pkgs/applications/misc/gphoto2/gphotofs.nix
index 668706ca38959..c5511847ba026 100644
--- a/pkgs/applications/misc/gphoto2/gphotofs.nix
+++ b/pkgs/applications/misc/gphoto2/gphotofs.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libtool, pkgconfig, libgphoto2, fuse, glib }:
+{ lib, stdenv, fetchurl, libtool, pkgconfig, libgphoto2, fuse, glib }:
 
 stdenv.mkDerivation rec {
   pname = "gphoto2fs";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     libgphoto2 fuse glib libtool
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fuse FS to mount a digital camera";
     homepage = "http://www.gphoto.org/";
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/applications/misc/gpsbabel/default.nix b/pkgs/applications/misc/gpsbabel/default.nix
index a95ffbbb59aa7..39cd4f40b4bd0 100644
--- a/pkgs/applications/misc/gpsbabel/default.nix
+++ b/pkgs/applications/misc/gpsbabel/default.nix
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     # The arc-project test fails on aarch64.
   + lib.optionalString stdenv.isAarch64 "rm -v testo.d/arc-project.test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert, upload and download data from GPS and Map programs";
     longDescription = ''
       GPSBabel converts waypoints, tracks, and routes between popular
diff --git a/pkgs/applications/misc/gpsbabel/gui.nix b/pkgs/applications/misc/gpsbabel/gui.nix
index 57eca9f47a58f..b115329cf0d6f 100644
--- a/pkgs/applications/misc/gpsbabel/gui.nix
+++ b/pkgs/applications/misc/gpsbabel/gui.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, qmake, qttools, qtwebkit, qttranslations, gpsbabel }:
+{ lib, stdenv, mkDerivation, qmake, qttools, qtwebkit, qttranslations, gpsbabel }:
 
 mkDerivation {
   pname = "gpsbabel-gui";
@@ -39,7 +39,7 @@ mkDerivation {
     install -Dm644 *.qm coretool/*.qm -t $out/share/gpsbabel/translations
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt-based GUI for gpsbabel";
     homepage = "http://www.gpsbabel.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/gpscorrelate/default.nix b/pkgs/applications/misc/gpscorrelate/default.nix
index 42f522175b045..5d8296d337fa5 100644
--- a/pkgs/applications/misc/gpscorrelate/default.nix
+++ b/pkgs/applications/misc/gpscorrelate/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, fetchpatch, pkgconfig, exiv2, libxml2, gtk3
+{ fetchFromGitHub, lib, stdenv, fetchpatch, pkgconfig, exiv2, libxml2, gtk3
 , libxslt, docbook_xsl, docbook_xml_dtd_42, desktop-file-utils, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
 
   installTargets = [ "install" "install-po" "install-desktop-file" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GPS photo correlation tool, to add EXIF geotags";
 
     longDescription = ''
diff --git a/pkgs/applications/misc/gpsprune/default.nix b/pkgs/applications/misc/gpsprune/default.nix
index 828b3ca9bf0b3..2348384abd0f2 100644
--- a/pkgs/applications/misc/gpsprune/default.nix
+++ b/pkgs/applications/misc/gpsprune/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, makeDesktopItem, makeWrapper, unzip, jdk }:
+{ fetchurl, lib, stdenv, makeDesktopItem, makeWrapper, unzip, jdk }:
 
 stdenv.mkDerivation rec {
   pname = "gpsprune";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     ${unzip}/bin/unzip -p $src tim/prune/gui/images/window_icon_64.png > $out/share/pixmaps/gpsprune.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Application for viewing, editing and converting GPS coordinate data";
     homepage = "https://activityworkshop.net/software/gpsprune/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/gpx-viewer/default.nix b/pkgs/applications/misc/gpx-viewer/default.nix
index 64296688c93e9..2c14691869fc0 100644
--- a/pkgs/applications/misc/gpx-viewer/default.nix
+++ b/pkgs/applications/misc/gpx-viewer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, libxml2, pkgconfig, gnome3, libchamplain, gdl, shared-mime-info, desktop-file-utils, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, intltool, libxml2, pkgconfig, gnome3, libchamplain, gdl, shared-mime-info, desktop-file-utils, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "gpx-viewer";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   ];
   buildInputs = [ gdl libchamplain gnome3.adwaita-icon-theme libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://blog.sarine.nl/tag/gpxviewer/";
     description = "Simple tool to visualize tracks and waypoints stored in a gpx file";
     platforms = with platforms; linux;
diff --git a/pkgs/applications/misc/gpxsee/default.nix b/pkgs/applications/misc/gpxsee/default.nix
index 5374a18b154ae..adafe8801f390 100644
--- a/pkgs/applications/misc/gpxsee/default.nix
+++ b/pkgs/applications/misc/gpxsee/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, qttools, qttranslations, substituteAll }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, qttools, qttranslations, substituteAll }:
 
 mkDerivation rec {
   pname = "gpxsee";
@@ -29,7 +29,7 @@ mkDerivation rec {
     wrapQtApp $out/Applications/GPXSee.app/Contents/MacOS/GPXSee
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GPS log file viewer and analyzer";
     longDescription = ''
       GPXSee is a Qt-based GPS log file viewer and analyzer that supports
diff --git a/pkgs/applications/misc/gramps/default.nix b/pkgs/applications/misc/gramps/default.nix
index 6d28abb737f51..7b2c5a23f8b04 100644
--- a/pkgs/applications/misc/gramps/default.nix
+++ b/pkgs/applications/misc/gramps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, pythonPackages, intltool, gexiv2,
+{ lib, stdenv, fetchFromGitHub, gtk3, pythonPackages, intltool, gexiv2,
   pango, gobject-introspection, wrapGAppsHook, gettext,
 # Optional packages:
  enableOSM ? true, osm-gps-map,
@@ -55,7 +55,7 @@ in buildPythonApplication rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Genealogy software";
     homepage = "https://gramps-project.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/green-pdfviewer/default.nix b/pkgs/applications/misc/green-pdfviewer/default.nix
index 4e888f4faac89..876ab5625989f 100644
--- a/pkgs/applications/misc/green-pdfviewer/default.nix
+++ b/pkgs/applications/misc/green-pdfviewer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, poppler, pkgconfig, gdk-pixbuf, SDL, gtk2 }:
+{ lib, stdenv, fetchFromGitHub, poppler, pkgconfig, gdk-pixbuf, SDL, gtk2 }:
 
 stdenv.mkDerivation {
   pname = "green-pdfviewer";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     make install PREFIX=$out MANDIR=$out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/schandinat/green/";
     description = "Viewer for PDF files, uses SDL and libpoppler";
 
diff --git a/pkgs/applications/misc/gremlin-console/default.nix b/pkgs/applications/misc/gremlin-console/default.nix
index 74485e2004aad..6c3ba132d0b21 100644
--- a/pkgs/applications/misc/gremlin-console/default.nix
+++ b/pkgs/applications/misc/gremlin-console/default.nix
@@ -1,4 +1,4 @@
-{ fetchzip, stdenv, makeWrapper, openjdk }:
+{ fetchzip, lib, stdenv, makeWrapper, openjdk }:
 
 stdenv.mkDerivation rec {
   pname = "gremlin-console";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       --set CLASSPATH "$out/opt/lib/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tinkerpop.apache.org/";
     description = "Console of the Apache TinkerPop graph computing framework";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/grsync/default.nix b/pkgs/applications/misc/grsync/default.nix
index e1c9902c6ae7b..f4d1b08525915 100644
--- a/pkgs/applications/misc/grsync/default.nix
+++ b/pkgs/applications/misc/grsync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dee, gtk2, intltool, libdbusmenu-gtk2, libunity, pkg-config, rsync }:
+{ lib, stdenv, fetchurl, dee, gtk2, intltool, libdbusmenu-gtk2, libunity, pkg-config, rsync }:
 
 stdenv.mkDerivation rec {
   version = "1.2.8";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     rsync
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Synchronize folders, files and make backups";
     homepage = "http://www.opbyte.it/grsync/";
     license = licenses.gpl1;
diff --git a/pkgs/applications/misc/gsctl/default.nix b/pkgs/applications/misc/gsctl/default.nix
index e80f43f5bd9ba..101baa093966e 100644
--- a/pkgs/applications/misc/gsctl/default.nix
+++ b/pkgs/applications/misc/gsctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gsctl";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "0s5bli08wfd9xszx3kc90k51vlgjc00r0qg4mikb6qdc4pxpgsxj";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Giant Swarm command line interface";
     homepage = "https://github.com/giantswarm/gsctl";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/gtk2fontsel/default.nix b/pkgs/applications/misc/gtk2fontsel/default.nix
index 21ad7d757a19f..828cd952bbcee 100644
--- a/pkgs/applications/misc/gtk2fontsel/default.nix
+++ b/pkgs/applications/misc/gtk2fontsel/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, pkgconfig, gtk2 }:
+{lib, stdenv, fetchurl, pkgconfig, gtk2 }:
 
 stdenv.mkDerivation rec {
   version = "0.1";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A font selection program for X11 using the GTK 2 toolkit";
     longDescription = ''
       Font selection tool similar to xfontsel implemented using GTK 2.
diff --git a/pkgs/applications/misc/gxneur/default.nix b/pkgs/applications/misc/gxneur/default.nix
index adabe22c6b64f..2e2e9f0850e04 100644
--- a/pkgs/applications/misc/gxneur/default.nix
+++ b/pkgs/applications/misc/gxneur/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, gtk2, xorg, glib, xneur, libglade, GConf, libappindicator-gtk2, pcre }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, gtk2, xorg, glib, xneur, libglade, GConf, libappindicator-gtk2, pcre }:
 
 stdenv.mkDerivation {
   name = "gxneur-0.20.0";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     libglade GConf pcre libappindicator-gtk2
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for XNEUR keyboard layout switcher";
     platforms = platforms.linux;
     license = with licenses; [ gpl2 gpl3 ];
diff --git a/pkgs/applications/misc/hamster/default.nix b/pkgs/applications/misc/hamster/default.nix
index 57b36e00436ec..855123ef79312 100644
--- a/pkgs/applications/misc/hamster/default.nix
+++ b/pkgs/applications/misc/hamster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, intltool, glib, itstool
+{ lib, stdenv, fetchFromGitHub, python3Packages, intltool, glib, itstool
 , wrapGAppsHook, gobject-introspection, pango, gdk-pixbuf, atk, wafHook }:
 
 python3Packages.buildPythonApplication rec {
@@ -52,7 +52,7 @@ python3Packages.buildPythonApplication rec {
     wrapPythonProgramsIn $out/libexec "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Time tracking application";
     homepage = "http://projecthamster.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/haxor-news/default.nix b/pkgs/applications/misc/haxor-news/default.nix
index 41aa71cb82e20..467cbfad65685 100644
--- a/pkgs/applications/misc/haxor-news/default.nix
+++ b/pkgs/applications/misc/haxor-news/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, python3, fetchpatch }:
 
 
 let
@@ -50,7 +50,7 @@ buildPythonApplication rec {
     ${python.interpreter} -m unittest discover -s tests -v
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/donnemartin/haxor-news";
     description = "Browse Hacker News like a haxor";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/hello/default.nix b/pkgs/applications/misc/hello/default.nix
index 32c8c696730f7..a885b1643fe23 100644
--- a/pkgs/applications/misc/hello/default.nix
+++ b/pkgs/applications/misc/hello/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "hello";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program that produces a familiar, friendly greeting";
     longDescription = ''
       GNU Hello is a program that prints "Hello, world!" when you run it.
diff --git a/pkgs/applications/misc/hivemind/default.nix b/pkgs/applications/misc/hivemind/default.nix
index 8a8f80f57977f..fc22d3a854a6e 100644
--- a/pkgs/applications/misc/hivemind/default.nix
+++ b/pkgs/applications/misc/hivemind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, runtimeShell }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, runtimeShell }:
 
 buildGoPackage rec {
   pname = "hivemind";
@@ -16,7 +16,7 @@ buildGoPackage rec {
     sha256 = "0afcnd03wsdphbbpha65rv5pnv0x6ldnnm6rnv1m6xkkywgnzx95";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/DarthSim/";
     description = "Process manager for Procfile-based applications";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/misc/hr/default.nix b/pkgs/applications/misc/hr/default.nix
index a0555f9032e95..706a8ff749551 100644
--- a/pkgs/applications/misc/hr/default.nix
+++ b/pkgs/applications/misc/hr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "hr";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/{bin,share}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/LuRsT/hr";
     description = "A horizontal bar for your terminal";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/hubstaff/default.nix b/pkgs/applications/misc/hubstaff/default.nix
index bbe05e0396bbc..4cfb5703883fe 100644
--- a/pkgs/applications/misc/hubstaff/default.nix
+++ b/pkgs/applications/misc/hubstaff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, makeWrapper, libX11, zlib, libSM, libICE
+{ lib, stdenv, fetchurl, unzip, makeWrapper, libX11, zlib, libSM, libICE
 , libXext , freetype, libXrender, fontconfig, libXft, libXinerama
 , libXfixes, libXScrnSaver, libnotify, glib , gtk3, libappindicator-gtk3
 , curl }:
@@ -56,7 +56,7 @@ stdenv.mkDerivation {
     ln -s $opt/data/resources $opt/x86_64/resources
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Time tracking software";
     homepage = "https://hubstaff.com/";
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/hugo/default.nix b/pkgs/applications/misc/hugo/default.nix
index d614360bf44d2..2d2ccefe934ee 100644
--- a/pkgs/applications/misc/hugo/default.nix
+++ b/pkgs/applications/misc/hugo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "hugo";
@@ -21,7 +21,7 @@ buildGoModule rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast and modern static website engine";
     homepage = "https://gohugo.io";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/imag/default.nix b/pkgs/applications/misc/imag/default.nix
index f3d4e156d6cd2..2f5597158389f 100644
--- a/pkgs/applications/misc/imag/default.nix
+++ b/pkgs/applications/misc/imag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , llvmPackages
@@ -53,7 +53,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion target/imag.{bash,fish} --zsh target/_imag
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Commandline personal information management suite";
     homepage = "https://imag-pim.org/";
     license = licenses.lgpl21;
diff --git a/pkgs/applications/misc/ipmicfg/default.nix b/pkgs/applications/misc/ipmicfg/default.nix
index f3d8d5cbc2059..a2cee088e1dfa 100644
--- a/pkgs/applications/misc/ipmicfg/default.nix
+++ b/pkgs/applications/misc/ipmicfg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "ipmicfg";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
    dontPatchShebangs = true; # There are no scripts and it complains about null bytes.
 
-   meta = with stdenv.lib; {
+   meta = with lib; {
      description = "Supermicro IPMI configuration tool";
      homepage = "http://www.supermicro.com/products/nfo/ipmi.cfm";
      license = licenses.unfree;
diff --git a/pkgs/applications/misc/ipmiview/default.nix b/pkgs/applications/misc/ipmiview/default.nix
index f0e2b70d939a8..415762eb6ffb1 100644
--- a/pkgs/applications/misc/ipmiview/default.nix
+++ b/pkgs/applications/misc/ipmiview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeDesktopItem
 , makeWrapper
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
              cd $WORK_DIR'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.unfree;
     maintainers = with maintainers; [ vlaci ];
     platforms = [ "x86_64-linux" "i686-linux" ];
diff --git a/pkgs/applications/misc/j4-dmenu-desktop/default.nix b/pkgs/applications/misc/j4-dmenu-desktop/default.nix
index 2b1b093fd3549..eca79c6521c08 100644
--- a/pkgs/applications/misc/j4-dmenu-desktop/default.nix
+++ b/pkgs/applications/misc/j4-dmenu-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, dmenu }:
+{ lib, stdenv, fetchFromGitHub, cmake, dmenu }:
 
 stdenv.mkDerivation rec {
   pname = "j4-dmenu-desktop";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     "-DWITH_GIT_CATCH=OFF"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A wrapper for dmenu that recognize .desktop files";
     homepage = "https://github.com/enkore/j4-dmenu-desktop";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/jgmenu/default.nix b/pkgs/applications/misc/jgmenu/default.nix
index e6a140ec7f96c..62f15818966fa 100644
--- a/pkgs/applications/misc/jgmenu/default.nix
+++ b/pkgs/applications/misc/jgmenu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , python3Packages
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/johanmalm/jgmenu";
     description = "Small X11 menu intended to be used with openbox and tint2";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/joplin-desktop/default.nix b/pkgs/applications/misc/joplin-desktop/default.nix
index bcd4f686f818a..a61740434e615 100644
--- a/pkgs/applications/misc/joplin-desktop/default.nix
+++ b/pkgs/applications/misc/joplin-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appimageTools, fetchurl, gsettings-desktop-schemas, gtk3, undmg }:
+{ lib, stdenv, appimageTools, fetchurl, gsettings-desktop-schemas, gtk3, undmg }:
 
 let
   pname = "joplin-desktop";
@@ -25,7 +25,7 @@ let
     inherit name src;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source note taking and to-do application with synchronisation capabilities";
     longDescription = ''
       Joplin is a free, open source note taking and to-do application, which can
diff --git a/pkgs/applications/misc/josm/default.nix b/pkgs/applications/misc/josm/default.nix
index 30e7882b60b72..056d73ba76fbd 100644
--- a/pkgs/applications/misc/josm/default.nix
+++ b/pkgs/applications/misc/josm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchsvn, makeWrapper, unzip, jre, libXxf86vm }:
+{ lib, stdenv, fetchurl, fetchsvn, makeWrapper, unzip, jre, libXxf86vm }:
 let
   pname = "josm";
   version = "17428";
@@ -40,7 +40,7 @@ stdenv.mkDerivation {
         --prefix LD_LIBRARY_PATH ":" '${libXxf86vm}/lib'
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extensible editor for OpenStreetMap";
     homepage = "https://josm.openstreetmap.de/";
     changelog = "https://josm.openstreetmap.de/wiki/Changelog";
diff --git a/pkgs/applications/misc/jotta-cli/default.nix b/pkgs/applications/misc/jotta-cli/default.nix
index 069d98111cc41..ad7ca25324d62 100644
--- a/pkgs/applications/misc/jotta-cli/default.nix
+++ b/pkgs/applications/misc/jotta-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 let
   arch = "amd64";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     $out/bin/jotta-cli completion > $out/share/bash-completion/completions/jotta-cli.bash
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "Jottacloud CLI";
     homepage     = "https://www.jottacloud.com/";
     downloadPage = "https://repo.jotta.us/archives/linux/";
diff --git a/pkgs/applications/misc/jp2a/default.nix b/pkgs/applications/misc/jp2a/default.nix
index d30e5d96df451..a48716a3dd2b5 100644
--- a/pkgs/applications/misc/jp2a/default.nix
+++ b/pkgs/applications/misc/jp2a/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libjpeg, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, libjpeg, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   version = "1.0.7";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ libjpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://csl.name/jp2a/";
     description = "A small utility that converts JPG images to ASCII";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/jrnl/default.nix b/pkgs/applications/misc/jrnl/default.nix
index 992b981c00376..7fc8ef88330f3 100644
--- a/pkgs/applications/misc/jrnl/default.nix
+++ b/pkgs/applications/misc/jrnl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python3
 }:
 
@@ -21,7 +21,7 @@ buildPythonApplication rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://maebert.github.io/jrnl/";
     description = "A simple command line journal application that stores your journal in a plain text file";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/k2pdfopt/default.nix b/pkgs/applications/misc/k2pdfopt/default.nix
index be61a76190a27..7c2e2ac071103 100644
--- a/pkgs/applications/misc/k2pdfopt/default.nix
+++ b/pkgs/applications/misc/k2pdfopt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, runCommand, fetchzip, fetchurl, fetchpatch, fetchFromGitHub
+{ lib, stdenv, runCommand, fetchzip, fetchurl, fetchpatch, fetchFromGitHub
 , cmake, pkgconfig, zlib, libpng, makeWrapper
 , enableGSL ? true, gsl
 , enableGhostScript ? true, ghostscript
@@ -161,7 +161,7 @@ in stdenv.mkDerivation rec {
     wrapProgram $out/bin/k2pdfopt --set-default TESSDATA_PREFIX ${tesseract4}/share/tessdata
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimizes PDF/DJVU files for mobile e-readers (e.g. the Kindle) and smartphones";
     homepage = "http://www.willus.com/k2pdfopt";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/k4dirstat/default.nix b/pkgs/applications/misc/k4dirstat/default.nix
index 2b4ae320e4e05..1d6a6097d27ce 100644
--- a/pkgs/applications/misc/k4dirstat/default.nix
+++ b/pkgs/applications/misc/k4dirstat/default.nix
@@ -6,7 +6,7 @@
 , kio
 , kjobwidgets
 , kxmlgui
-, stdenv
+, lib, stdenv
 }:
 
 mkDerivation rec {
@@ -23,7 +23,7 @@ mkDerivation rec {
   nativeBuildInputs = [ extra-cmake-modules ];
   buildInputs = [ kiconthemes kio kjobwidgets kxmlgui ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jeromerobert/k4dirstat";
     description = "A small utility program that sums up disk usage for directory trees";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/kanboard/default.nix b/pkgs/applications/misc/kanboard/default.nix
index ebe31b10c60ef..722f2364ab3e1 100644
--- a/pkgs/applications/misc/kanboard/default.nix
+++ b/pkgs/applications/misc/kanboard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "kanboard";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp -rv . $out/share/kanboard
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kanban project management software";
     homepage = "https://kanboard.net";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/kapow/default.nix b/pkgs/applications/misc/kapow/default.nix
index ccdc57dd0e675..49fbed7b1efb9 100644
--- a/pkgs/applications/misc/kapow/default.nix
+++ b/pkgs/applications/misc/kapow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, qmake, fetchFromGitHub, qtbase, qttools, wrapQtAppsHook }:
+{ lib, stdenv, qmake, fetchFromGitHub, qtbase, qttools, wrapQtAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "kapow";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ qtbase ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Punch clock to track time spent on projects";
     homepage = "https://gottcode.org/kapow/";
     maintainers = with maintainers; [ orivej ];
diff --git a/pkgs/applications/misc/keepass-plugins/keepassrpc/default.nix b/pkgs/applications/misc/keepass-plugins/keepassrpc/default.nix
index b28914a44a818..cbcb88b9d1a86 100644
--- a/pkgs/applications/misc/keepass-plugins/keepassrpc/default.nix
+++ b/pkgs/applications/misc/keepass-plugins/keepassrpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildEnv, fetchurl, mono }:
+{ lib, stdenv, buildEnv, fetchurl, mono }:
 
 let
   version = "1.14.0";
@@ -10,7 +10,7 @@ let
       sha256 = "1c410cc93c0252e7cfdb02507b8172c13e18d12c97f08630b721d897dc9b8b24";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "The KeePassRPC plugin that needs to be installed inside KeePass in order for Kee to be able to connect your browser to your passwords";
       homepage    = "https://github.com/kee-org/keepassrpc";
       platforms   = [ "x86_64-linux" ];
diff --git a/pkgs/applications/misc/keeweb/default.nix b/pkgs/applications/misc/keeweb/default.nix
index 801e5841c1ba1..cf14679cd9bbe 100644
--- a/pkgs/applications/misc/keeweb/default.nix
+++ b/pkgs/applications/misc/keeweb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, appimageTools, undmg, libsecret }:
+{ lib, stdenv, fetchurl, appimageTools, undmg, libsecret }:
 let
   inherit (stdenv.hostPlatform) system;
   throwSystem = throw "Unsupported system: ${system}";
@@ -26,7 +26,7 @@ let
     inherit name src;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free cross-platform password manager compatible with KeePass";
     homepage = "https://keeweb.info/";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/khal/default.nix b/pkgs/applications/misc/khal/default.nix
index 3c46043256a28..7bd4a3bbf7f5d 100644
--- a/pkgs/applications/misc/khal/default.nix
+++ b/pkgs/applications/misc/khal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgs, python3, fetchpatch, glibcLocales }:
+{ lib, stdenv, pkgs, python3, fetchpatch, glibcLocales }:
 
 with python3.pkgs; buildPythonApplication rec {
   pname = "khal";
@@ -62,7 +62,7 @@ with python3.pkgs; buildPythonApplication rec {
       and not test_birthdays_no_year"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://lostpackets.de/khal/";
     description = "CLI calendar application";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/kjv/default.nix b/pkgs/applications/misc/kjv/default.nix
index 307781931e971..5247207d1493b 100644
--- a/pkgs/applications/misc/kjv/default.nix
+++ b/pkgs/applications/misc/kjv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch }:
 
 let
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     "PREFIX=${placeholder "out"}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Bible, King James Version";
     homepage = "https://github.com/bontibon/kjv";
     license = licenses.publicDomain;
diff --git a/pkgs/applications/misc/kondo/default.nix b/pkgs/applications/misc/kondo/default.nix
index f47458f0f3ff2..545dc85efebfa 100644
--- a/pkgs/applications/misc/kondo/default.nix
+++ b/pkgs/applications/misc/kondo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "kondo";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1ax81a2828z3yla1psg5xi8ild65m6zcsvx48ncz902mpzqlj92b";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Save disk space by cleaning unneeded files from software projects";
     homepage = "https://github.com/tbillington/kondo";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/koreader/default.nix b/pkgs/applications/misc/koreader/default.nix
index 54d6a66fc0883..c3d7fbac12fdf 100644
--- a/pkgs/applications/misc/koreader/default.nix
+++ b/pkgs/applications/misc/koreader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeWrapper
 , dpkg
@@ -41,7 +41,7 @@ in stdenv.mkDerivation rec {
     }
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/koreader/koreader";
     description =
       "An ebook reader application supporting PDF, DjVu, EPUB, FB2 and many more formats, running on Cervantes, Kindle, Kobo, PocketBook and Android devices";
diff --git a/pkgs/applications/misc/kupfer/default.nix b/pkgs/applications/misc/kupfer/default.nix
index f2744bf23ea57..ce21ea75b3070 100644
--- a/pkgs/applications/misc/kupfer/default.nix
+++ b/pkgs/applications/misc/kupfer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , intltool
 , python3Packages
@@ -44,7 +44,7 @@ buildPythonApplication rec {
 
   doCheck = false; # no tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A smart, quick launcher";
     homepage    = "https://kupferlauncher.github.io/";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/misc/lenmus/default.nix b/pkgs/applications/misc/lenmus/default.nix
index 2f513634259b5..a9aef85753ec6 100644
--- a/pkgs/applications/misc/lenmus/default.nix
+++ b/pkgs/applications/misc/lenmus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkg-config, fetchFromGitHub, fetchpatch
+{ lib, stdenv, pkg-config, fetchFromGitHub, fetchpatch
 , cmake, boost
 , portmidi, sqlite
 , freetype, libpng, pngpp, zlib
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     wxGTK30 wxsqlite3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LenMus Phonascus is a program for learning music";
     longDescription = ''
       LenMus Phonascus is a free open source program (GPL v3) for learning music.
diff --git a/pkgs/applications/misc/libosmocore/default.nix b/pkgs/applications/misc/libosmocore/default.nix
index 8b36d384e153f..27432a4dd75b2 100644
--- a/pkgs/applications/misc/libosmocore/default.nix
+++ b/pkgs/applications/misc/libosmocore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , pcsclite, talloc, python2, gnutls
 }:
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of Osmocom core libraries";
     homepage = "https://github.com/osmocom/libosmocore";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/librecad/default.nix b/pkgs/applications/misc/librecad/default.nix
index 6f7967dfdfd53..676b7aea1e283 100644
--- a/pkgs/applications/misc/librecad/default.nix
+++ b/pkgs/applications/misc/librecad/default.nix
@@ -1,4 +1,5 @@
-{ boost
+{ lib
+, boost
 , fetchFromGitHub
 , fetchpatch
 , installShellFiles
@@ -89,7 +90,7 @@ mkDerivationWith stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "2D CAD package based on Qt";
     homepage = "https://librecad.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/lifelines/default.nix b/pkgs/applications/misc/lifelines/default.nix
index 7207dea9d522e..50827355cac08 100644
--- a/pkgs/applications/misc/lifelines/default.nix
+++ b/pkgs/applications/misc/lifelines/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gettext, libiconv, bison, ncurses, perl, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, gettext, libiconv, bison, ncurses, perl, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "lifelines";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   ];
   nativeBuildInputs = [ autoreconfHook bison ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Genealogy tool with ncurses interface";
     homepage = "https://lifelines.github.io/lifelines/";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/lighthouse/default.nix b/pkgs/applications/misc/lighthouse/default.nix
index 9e651c59d4eb0..a54b8a54e8ba4 100644
--- a/pkgs/applications/misc/lighthouse/default.nix
+++ b/pkgs/applications/misc/lighthouse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig
+{ lib, stdenv, fetchFromGitHub, pkgconfig
 , libX11, libxcb, cairo, gtk2, pango, python27, python3
 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   postFixup = "chmod -x $out/share/lighthouse/.config/lighthouse/google.py";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple flexible popup dialog to run on X";
     homepage = "https://github.com/emgram769/lighthouse";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/llpp/default.nix b/pkgs/applications/misc/llpp/default.nix
index 8b3dfa35ff402..7004d0dce34f1 100644
--- a/pkgs/applications/misc/llpp/default.nix
+++ b/pkgs/applications/misc/llpp/default.nix
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
         --prefix PATH ":" "${procps}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://repo.or.cz/w/llpp.git";
     description = "A MuPDF based PDF pager written in OCaml";
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/loxodo/default.nix b/pkgs/applications/misc/loxodo/default.nix
index 4b201c66fe5ef..e32535d4445e7 100644
--- a/pkgs/applications/misc/loxodo/default.nix
+++ b/pkgs/applications/misc/loxodo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python27Packages, fetchgit }:
+{ lib, stdenv, python27Packages, fetchgit }:
 let
   py = python27Packages;
   python = py.python;
@@ -28,7 +28,7 @@ py.buildPythonApplication {
     EOF
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Password Safe V3 compatible password vault";
     homepage = "https://www.christoph-sommer.de/loxodo/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/ltwheelconf/default.nix b/pkgs/applications/misc/ltwheelconf/default.nix
index 2ceb8e91def87..66d10f5e6b88b 100644
--- a/pkgs/applications/misc/ltwheelconf/default.nix
+++ b/pkgs/applications/misc/ltwheelconf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libusb1, pkgconfig, fetchFromGitHub }:
+{ lib, stdenv, libusb1, pkgconfig, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "ltwheelconf";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp ltwheelconf $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/thk/LTWheelConf";
     description = "Logitech wheels configuration tool";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/madonctl/default.nix b/pkgs/applications/misc/madonctl/default.nix
index a61c66d937461..249ed48bd1c4f 100644
--- a/pkgs/applications/misc/madonctl/default.nix
+++ b/pkgs/applications/misc/madonctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "madonctl";
@@ -21,7 +21,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI for the Mastodon social network API";
     homepage = "https://github.com/McKael/madonctl";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/makeself/default.nix b/pkgs/applications/misc/makeself/default.nix
index 993596aabe1d4..205d526ed9419 100644
--- a/pkgs/applications/misc/makeself/default.nix
+++ b/pkgs/applications/misc/makeself/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which }:
+{ lib, stdenv, fetchFromGitHub, which }:
 
 stdenv.mkDerivation rec {
   version = "2.4.2";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     sed -e "s|^HEADER=.*|HEADER=$out/share/${pname}-${version}/makeself-header.sh|" -i $out/bin/makeself
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://megastep.org/makeself";
     description = "Utility to create self-extracting packages";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/mako/default.nix b/pkgs/applications/misc/mako/default.nix
index e1b14acb46f4f..3c1babaab3705 100644
--- a/pkgs/applications/misc/mako/default.nix
+++ b/pkgs/applications/misc/mako/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, scdoc
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, scdoc
 , systemd, pango, cairo, gdk-pixbuf
 , wayland, wayland-protocols
 , wrapGAppsHook }:
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   mesonFlags = [ "-Dzsh-completions=true" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight Wayland notification daemon";
     homepage = "https://wayland.emersion.fr/mako/";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/masterpdfeditor/default.nix b/pkgs/applications/misc/masterpdfeditor/default.nix
index d541c5e1289ae..a743a9fbc27d5 100644
--- a/pkgs/applications/misc/masterpdfeditor/default.nix
+++ b/pkgs/applications/misc/masterpdfeditor/default.nix
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Master PDF Editor";
     homepage = "https://code-industry.net/free-pdf-editor/";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/applications/misc/mdp/default.nix b/pkgs/applications/misc/mdp/default.nix
index b96c4d00214b8..2c13ed4ecc9e7 100644
--- a/pkgs/applications/misc/mdp/default.nix
+++ b/pkgs/applications/misc/mdp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   version = "1.0.15";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/visit1985/mdp";
     description = "A command-line based markdown presentation tool";
     maintainers = with maintainers; [ matthiasbeyer vrthra ];
diff --git a/pkgs/applications/misc/mediaelch/default.nix b/pkgs/applications/misc/mediaelch/default.nix
index c4ed0c975eabd..8597e92f4011e 100644
--- a/pkgs/applications/misc/mediaelch/default.nix
+++ b/pkgs/applications/misc/mediaelch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchFromGitHub
 , qmake
@@ -31,7 +31,7 @@ mkDerivation rec {
     substituteInPlace MediaElch.pro --replace "/usr" "$out"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mediaelch.de/mediaelch/";
     description = "Media Manager for Kodi";
     license = licenses.lgpl3Only;
diff --git a/pkgs/applications/misc/mediainfo-gui/default.nix b/pkgs/applications/misc/mediainfo-gui/default.nix
index b3e23f2245cfb..99aada11f0482 100644
--- a/pkgs/applications/misc/mediainfo-gui/default.nix
+++ b/pkgs/applications/misc/mediainfo-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig, libzen, libmediainfo, wxGTK30-gtk3
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig, libzen, libmediainfo, wxGTK30-gtk3
 , desktop-file-utils, libSM, imagemagick }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Supplies technical and tag information about a video or audio file (GUI version)";
     longDescription = ''
       MediaInfo is a convenient unified display of the most relevant technical
diff --git a/pkgs/applications/misc/mediainfo/default.nix b/pkgs/applications/misc/mediainfo/default.nix
index 0fd3826f4e563..bb90d76977b95 100644
--- a/pkgs/applications/misc/mediainfo/default.nix
+++ b/pkgs/applications/misc/mediainfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig, libzen, libmediainfo, zlib }:
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig, libzen, libmediainfo, zlib }:
 
 stdenv.mkDerivation rec {
   version = "20.09";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Supplies technical and tag information about a video or audio file";
     longDescription = ''
       MediaInfo is a convenient unified display of the most relevant technical
diff --git a/pkgs/applications/misc/megacmd/default.nix b/pkgs/applications/misc/megacmd/default.nix
index 899b069f05423..1e7aa1f56db64 100644
--- a/pkgs/applications/misc/megacmd/default.nix
+++ b/pkgs/applications/misc/megacmd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoconf
 , automake
 , c-ares
@@ -78,7 +78,7 @@ stdenv.mkDerivation rec {
     "--with-termcap"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MEGA Command Line Interactive and Scriptable Application";
     homepage    = "https://mega.nz/";
     license     = licenses.unfree;
diff --git a/pkgs/applications/misc/megasync/default.nix b/pkgs/applications/misc/megasync/default.nix
index 3b25d7e606a65..b7f8c0a281d47 100644
--- a/pkgs/applications/misc/megasync/default.nix
+++ b/pkgs/applications/misc/megasync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoconf
 , automake
 , c-ares
@@ -109,7 +109,7 @@ mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Easy automated syncing between your computers and your MEGA Cloud Drive";
     homepage = "https://mega.nz/";
diff --git a/pkgs/applications/misc/mencal/default.nix b/pkgs/applications/misc/mencal/default.nix
index df0a4db7fc703..806d6a53cfaae 100644
--- a/pkgs/applications/misc/mencal/default.nix
+++ b/pkgs/applications/misc/mencal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   name = "mencal-3.0";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Menstruation calendar";
     longDescription = ''
       Mencal is a simple variation of the well-known unix command cal.
diff --git a/pkgs/applications/misc/menumaker/default.nix b/pkgs/applications/misc/menumaker/default.nix
index f76d6cb6b8a8a..192228de5d91e 100644
--- a/pkgs/applications/misc/menumaker/default.nix
+++ b/pkgs/applications/misc/menumaker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages }:
+{ lib, stdenv, fetchurl, pythonPackages }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "menumaker";
@@ -11,7 +11,7 @@ pythonPackages.buildPythonApplication rec {
 
   format = "other";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Heuristics-driven menu generator for several window managers";
     homepage = "http://menumaker.sourceforge.net";
     license = licenses.bsd2;
diff --git a/pkgs/applications/misc/metamorphose2/default.nix b/pkgs/applications/misc/metamorphose2/default.nix
index a81aec9d0364c..277d00fe050b9 100644
--- a/pkgs/applications/misc/metamorphose2/default.nix
+++ b/pkgs/applications/misc/metamorphose2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, makeWrapper, gettext
+{ lib, stdenv, fetchgit, makeWrapper, gettext
 , python27, python2Packages
 }:
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a graphical mass renaming program for files and folders";
     homepage    = "https://github.com/metamorphose/metamorphose2";
     license     = with licenses; gpl3Plus;
diff --git a/pkgs/applications/misc/metar/default.nix b/pkgs/applications/misc/metar/default.nix
index f5185c6398739..d9e1922f1c482 100644
--- a/pkgs/applications/misc/metar/default.nix
+++ b/pkgs/applications/misc/metar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, curl }:
+{ lib, stdenv, fetchgit, curl }:
 
 stdenv.mkDerivation {
   name = "metar-20161013.1";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/keesL/metar";
     license = licenses.gpl2;
     maintainers = [ maintainers.zalakain ];
diff --git a/pkgs/applications/misc/minder/default.nix b/pkgs/applications/misc/minder/default.nix
index bf94ac4299477..1c25e5c3320c8 100644
--- a/pkgs/applications/misc/minder/default.nix
+++ b/pkgs/applications/misc/minder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgconfig, meson, ninja, python3
 , wrapGAppsHook, vala, shared-mime-info
 , cairo, pantheon, glib, gtk3, libxml2, libgee, libarchive
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mind-mapping application for Elementary OS";
     homepage = "https://github.com/phase1geo/Minder";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/minergate-cli/default.nix b/pkgs/applications/misc/minergate-cli/default.nix
index 67ce53262864c..59de7ba8a9e5c 100644
--- a/pkgs/applications/misc/minergate-cli/default.nix
+++ b/pkgs/applications/misc/minergate-cli/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, dpkg, makeWrapper, openssl }:
+{ fetchurl, lib, stdenv, dpkg, makeWrapper, openssl }:
 
 stdenv.mkDerivation {
   version = "8.2";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     ln -s $pgm $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minergate CPU/GPU console client mining software";
     homepage = "https://www.minergate.com/";
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/minergate/default.nix b/pkgs/applications/misc/minergate/default.nix
index 6fbe39c4da2d1..18af19db5100d 100644
--- a/pkgs/applications/misc/minergate/default.nix
+++ b/pkgs/applications/misc/minergate/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, dpkg, makeWrapper, fontconfig, freetype, openssl, xorg, xkeyboard_config }:
+{ fetchurl, lib, stdenv, dpkg, makeWrapper, fontconfig, freetype, openssl, xorg, xkeyboard_config }:
 
 stdenv.mkDerivation {
   version = "8.1";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     ln -s $out/opt/minergate/minergate $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minergate CPU/GPU mining software";
     homepage = "https://www.minergate.com/";
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/mkgmap/default.nix b/pkgs/applications/misc/mkgmap/default.nix
index 9bd5be9dc8017..0ef661333d6dd 100644
--- a/pkgs/applications/misc/mkgmap/default.nix
+++ b/pkgs/applications/misc/mkgmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchsvn
 , jdk
@@ -75,7 +75,7 @@ stdenv.mkDerivation {
     cp -r dist/examples $out/share/mkgmap/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create maps for Garmin GPS devices from OpenStreetMap (OSM) data";
     homepage = "http://www.mkgmap.org.uk";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/misc/mkgmap/splitter/default.nix b/pkgs/applications/misc/mkgmap/splitter/default.nix
index df1c526fed61e..98f6379700eb2 100644
--- a/pkgs/applications/misc/mkgmap/splitter/default.nix
+++ b/pkgs/applications/misc/mkgmap/splitter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchsvn
 , jdk
@@ -68,7 +68,7 @@ stdenv.mkDerivation {
       --add-flags "-jar $out/share/java/splitter/splitter.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for splitting OpenStreetMap maps into tiles";
     homepage = "http://www.mkgmap.org.uk";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/misc/moonlight-embedded/default.nix b/pkgs/applications/misc/moonlight-embedded/default.nix
index 2ae3f1894d53d..06835aad4d19d 100644
--- a/pkgs/applications/misc/moonlight-embedded/default.nix
+++ b/pkgs/applications/misc/moonlight-embedded/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, perl
+{ lib, stdenv, fetchFromGitHub, cmake, perl
 , alsaLib, libevdev, libopus, udev, SDL2
 , ffmpeg_3, pkgconfig, xorg, libvdpau, libpulseaudio, libcec
 , curl, expat, avahi, enet, libuuid, libva
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     xorg.libpthreadstubs curl expat avahi enet libuuid libva
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source implementation of NVIDIA's GameStream";
     homepage = "https://github.com/irtimmer/moonlight-embedded";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/mop/default.nix b/pkgs/applications/misc/mop/default.nix
index be81760892409..07102fe56f233 100644
--- a/pkgs/applications/misc/mop/default.nix
+++ b/pkgs/applications/misc/mop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchgit }:
+{ lib, stdenv, buildGoPackage, fetchgit }:
 
 buildGoPackage rec {
   pname = "mop";
@@ -22,7 +22,7 @@ buildGoPackage rec {
     sha256 = "0zp51g9i8rw6acs4vnrxclbxa5z1v0a0m1xx27szszp0rphcczkx";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple stock tracker implemented in go";
     homepage =  "https://github.com/mop-tracker/mop";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/mpvc/default.nix b/pkgs/applications/misc/mpvc/default.nix
index eacc4b5758c36..64b55cce7a044 100644
--- a/pkgs/applications/misc/mpvc/default.nix
+++ b/pkgs/applications/misc/mpvc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, socat, fetchFromGitHub, makeWrapper }:
+{ lib, stdenv, socat, fetchFromGitHub, makeWrapper }:
 
 stdenv.mkDerivation {
   name = "mpvc-unstable-2017-03-18";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ socat makeWrapper ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A mpc-like control interface for mpv";
     homepage = "https://github.com/wildefyr/mpvc";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/mqtt-bench/default.nix b/pkgs/applications/misc/mqtt-bench/default.nix
index 1f6112d7d7bbb..c01a1b9cbc691 100644
--- a/pkgs/applications/misc/mqtt-bench/default.nix
+++ b/pkgs/applications/misc/mqtt-bench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, fetchpatch }:
 
 buildGoPackage rec {
   pname = "mqtt-bench";
@@ -24,7 +24,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mosquitto benchmark tool";
     homepage = "https://github.com/takanorig/mqtt-bench";
     maintainers = with maintainers; [ disassembler ];
diff --git a/pkgs/applications/misc/mucommander/default.nix b/pkgs/applications/misc/mucommander/default.nix
index a1e02dbe18e05..c42ae1e815b38 100644
--- a/pkgs/applications/misc/mucommander/default.nix
+++ b/pkgs/applications/misc/mucommander/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gradle_6, perl, makeWrapper, jdk11, gsettings-desktop-schemas }:
+{ lib, stdenv, fetchFromGitHub, gradle_6, perl, makeWrapper, jdk11, gsettings-desktop-schemas }:
 
 let
   version = "0.9.3-3";
@@ -76,7 +76,7 @@ in stdenv.mkDerivation {
       --set JAVA_HOME ${jdk11}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.mucommander.com/";
     description = "Cross-platform file manager";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/multibootusb/default.nix b/pkgs/applications/misc/multibootusb/default.nix
index c1c7b5a2706ef..34671d9374f28 100644
--- a/pkgs/applications/misc/multibootusb/default.nix
+++ b/pkgs/applications/misc/multibootusb/default.nix
@@ -1,6 +1,6 @@
 { fetchFromGitHub, libxcb, mtools, p7zip, parted, procps, qemu, unzip, zip,
   coreutils, gnugrep, which, gnused, e2fsprogs, autoPatchelfHook, gptfdisk,
-  python36Packages, qt5, runtimeShell, stdenv, util-linux, wrapQtAppsHook }:
+  python36Packages, qt5, runtimeShell, lib, stdenv, util-linux, wrapQtAppsHook }:
 
 # Note: Multibootusb is tricky to maintain. It relies on the
 # $PYTHONPATH variable containing some of their code, so that
@@ -105,7 +105,7 @@ python36Packages.buildPythonApplication rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiboot USB creator for Linux live disks";
     homepage = "http://multibootusb.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/mupdf/1.17.nix b/pkgs/applications/misc/mupdf/1.17.nix
index c6243e5f1d6ba..bf66fc80bab92 100644
--- a/pkgs/applications/misc/mupdf/1.17.nix
+++ b/pkgs/applications/misc/mupdf/1.17.nix
@@ -80,7 +80,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mupdf.com";
     repositories.git = "git://git.ghostscript.com/mupdf.git";
     description = "Lightweight PDF, XPS, and E-book viewer and toolkit written in portable C";
diff --git a/pkgs/applications/misc/mupdf/default.nix b/pkgs/applications/misc/mupdf/default.nix
index 836d970a2b558..09ad5fe98423e 100644
--- a/pkgs/applications/misc/mupdf/default.nix
+++ b/pkgs/applications/misc/mupdf/default.nix
@@ -97,7 +97,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mupdf.com";
     repositories.git = "git://git.ghostscript.com/mupdf.git";
     description = "Lightweight PDF, XPS, and E-book viewer and toolkit written in portable C";
diff --git a/pkgs/applications/misc/mwic/default.nix b/pkgs/applications/misc/mwic/default.nix
index dffc27bd40b08..970c89b2acfcd 100644
--- a/pkgs/applications/misc/mwic/default.nix
+++ b/pkgs/applications/misc/mwic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages }:
+{ lib, stdenv, fetchurl, pythonPackages }:
 
 stdenv.mkDerivation rec {
   version = "0.7.8";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://jwilk.net/software/mwic";
     description = "spell-checker that groups possible misspellings and shows them in their contexts";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/mysql-workbench/default.nix b/pkgs/applications/misc/mysql-workbench/default.nix
index 71adcdc0757b9..34e124367ebf2 100644
--- a/pkgs/applications/misc/mysql-workbench/default.nix
+++ b/pkgs/applications/misc/mysql-workbench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , substituteAll
 , cmake
@@ -172,7 +172,7 @@ in stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Visual MySQL database modeling, administration and querying tool";
     longDescription = ''
       MySQL Workbench is a modeling tool that allows you to design
diff --git a/pkgs/applications/misc/mystem/default.nix b/pkgs/applications/misc/mystem/default.nix
index 27caef9ea2eb2..62c1834d26ad7 100644
--- a/pkgs/applications/misc/mystem/default.nix
+++ b/pkgs/applications/misc/mystem/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl }:
+{lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "mystem";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     patchelf --set-interpreter $(cat ${stdenv.cc}/nix-support/dynamic-linker) $out/bin/mystem
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Morphological analysis of Russian text";
     homepage = "https://yandex.ru/dev/mystem/";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/applications/misc/neap/default.nix b/pkgs/applications/misc/neap/default.nix
index 992a3c0248a0c..e5f50dd337066 100644
--- a/pkgs/applications/misc/neap/default.nix
+++ b/pkgs/applications/misc/neap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages }:
+{ lib, stdenv, fetchFromGitHub, python2Packages }:
 
 stdenv.mkDerivation rec {
   pname = "neap";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Systray workspace pager";
     homepage = "https://github.com/vzxwco/neap";
     license = licenses.bsd2;
diff --git a/pkgs/applications/misc/nix-tour/default.nix b/pkgs/applications/misc/nix-tour/default.nix
index 05ef696f99b84..dda4dcb47e57d 100644
--- a/pkgs/applications/misc/nix-tour/default.nix
+++ b/pkgs/applications/misc/nix-tour/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, electron, runtimeShell } :
+{ lib, stdenv, fetchgit, electron, runtimeShell } :
 
 stdenv.mkDerivation rec {
   pname = "nix-tour";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     chmod 0755 $out/bin/nix-tour
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "'the tour of nix' from nixcloud.io/tour as offline version";
     homepage = "https://nixcloud.io/tour";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/nixnote2/default.nix b/pkgs/applications/misc/nixnote2/default.nix
index 92bb4ca220773..b23c41e6feec2 100644
--- a/pkgs/applications/misc/nixnote2/default.nix
+++ b/pkgs/applications/misc/nixnote2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, boost
+{ lib, stdenv, mkDerivation, fetchFromGitHub, boost
 , qtbase, qtwebkit, poppler, qmake, hunspell, html-tidy}:
 
 mkDerivation rec {
@@ -35,7 +35,7 @@ mkDerivation rec {
     cp theme.ini $out/share/nixnote2/theme.ini
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An unofficial client of Evernote";
     homepage = "http://www.nixnote.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/notejot/default.nix b/pkgs/applications/misc/notejot/default.nix
index d5d6aea494617..5a84f91bb7410 100644
--- a/pkgs/applications/misc/notejot/default.nix
+++ b/pkgs/applications/misc/notejot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nix-update-script, vala, pkgconfig, meson, ninja, python3, pantheon
+{ lib, stdenv, fetchFromGitHub, nix-update-script, vala, pkgconfig, meson, ninja, python3, pantheon
 , gtk3, gtksourceview, json-glib, libgee, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stupidly-simple sticky notes applet";
     homepage = "https://github.com/lainsce/notejot";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/notify-osd-customizable/default.nix b/pkgs/applications/misc/notify-osd-customizable/default.nix
index 36fa888e88843..aeeb1051b0942 100644
--- a/pkgs/applications/misc/notify-osd-customizable/default.nix
+++ b/pkgs/applications/misc/notify-osd-customizable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , dbus-glib
 , fetchurl
 , glib
@@ -38,7 +38,7 @@ in stdenv.mkDerivation rec {
       --prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon that displays passive pop-up notifications";
     homepage = "https://launchpad.net/notify-osd";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/notify-osd/default.nix b/pkgs/applications/misc/notify-osd/default.nix
index e2bff00311860..bc2e40764043e 100644
--- a/pkgs/applications/misc/notify-osd/default.nix
+++ b/pkgs/applications/misc/notify-osd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, glib, libwnck3, libnotify, dbus-glib, makeWrapper, gsettings-desktop-schemas }:
+{ lib, stdenv, fetchurl, pkgconfig, glib, libwnck3, libnotify, dbus-glib, makeWrapper, gsettings-desktop-schemas }:
 
 stdenv.mkDerivation rec {
   pname = "notify-osd";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon that displays passive pop-up notifications";
     homepage = "https://launchpad.net/notify-osd";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/nrsc5/default.nix b/pkgs/applications/misc/nrsc5/default.nix
index ada603cba9631..f00fd7894c756 100644
--- a/pkgs/applications/misc/nrsc5/default.nix
+++ b/pkgs/applications/misc/nrsc5/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub,
+{ lib, stdenv, fetchFromGitHub,
   autoconf, automake, libtool, cmake,
   rtl-sdr, libao, fftwFloat
 } :
@@ -42,7 +42,7 @@ in stdenv.mkDerivation {
 
   cmakeFlags = [ "-DUSE_COLOR=ON" "-DUSE_FAAD2=ON" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/theori-io/nrsc5";
     description = "HD-Radio decoder for RTL-SDR";
     platforms = stdenv.lib.platforms.linux;
diff --git a/pkgs/applications/misc/nut/default.nix b/pkgs/applications/misc/nut/default.nix
index 8f188818d4f71..d36efb483db1a 100644
--- a/pkgs/applications/misc/nut/default.nix
+++ b/pkgs/applications/misc/nut/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, neon, libusb-compat-0_1, openssl, udev, avahi, freeipmi
+{ lib, stdenv, fetchurl, pkgconfig, neon, libusb-compat-0_1, openssl, udev, avahi, freeipmi
 , libtool, makeWrapper, autoreconfHook, fetchpatch
 }:
 
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
       "$out/lib:${neon}/lib:${libusb-compat-0_1.out}/lib:${avahi}/lib:${freeipmi}/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network UPS Tools";
     longDescription = ''
       Network UPS Tools is a collection of programs which provide a common
diff --git a/pkgs/applications/misc/nwg-launchers/default.nix b/pkgs/applications/misc/nwg-launchers/default.nix
index 77eae10293d41..e6575b780f7ca 100644
--- a/pkgs/applications/misc/nwg-launchers/default.nix
+++ b/pkgs/applications/misc/nwg-launchers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , gtkmm3
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${swaylock}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK-based launchers: application grid, button bar, dmenu for sway and other window managers";
     homepage = "https://github.com/nwg-piotr/nwg-launchers";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/obinskit/default.nix b/pkgs/applications/misc/obinskit/default.nix
index dc03b9b4f93c7..ee31948c62d17 100644
--- a/pkgs/applications/misc/obinskit/default.nix
+++ b/pkgs/applications/misc/obinskit/default.nix
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [ stdenv.cc.cc.lib libxkbcommon (lib.getLib systemd) xorg.libXt ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical configurator for Anne Pro and Anne Pro II keyboards";
     homepage = "http://en.obins.net/obinskit/"; # https is broken
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/ocropus/default.nix b/pkgs/applications/misc/ocropus/default.nix
index ef371dc59fff9..27b1b4ab98faa 100644
--- a/pkgs/applications/misc/ocropus/default.nix
+++ b/pkgs/applications/misc/ocropus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, pythonPackages, curl }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, pythonPackages, curl }:
 
 let
   getmodel = name: sha256: {
@@ -49,7 +49,7 @@ pythonPackages.buildPythonApplication rec {
     PATH=".:$PATH" ./run-test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source document analysis and OCR system";
     license = licenses.asl20;
     homepage = "https://github.com/tmbdev/ocropy/";
diff --git a/pkgs/applications/misc/octoprint/default.nix b/pkgs/applications/misc/octoprint/default.nix
index 974b733ae6401..f35d03c6d1723 100644
--- a/pkgs/applications/misc/octoprint/default.nix
+++ b/pkgs/applications/misc/octoprint/default.nix
@@ -172,7 +172,7 @@ let
 
               passthru.python = self.python;
 
-              meta = with stdenv.lib; {
+              meta = with lib; {
                 homepage = "https://octoprint.org/";
                 description = "The snappy web interface for your 3D printer";
                 license = licenses.agpl3;
diff --git a/pkgs/applications/misc/octoprint/plugins.nix b/pkgs/applications/misc/octoprint/plugins.nix
index 421690f29d465..df0409c8be483 100644
--- a/pkgs/applications/misc/octoprint/plugins.nix
+++ b/pkgs/applications/misc/octoprint/plugins.nix
@@ -23,7 +23,7 @@ in {
       sha256 = "0ij3rvdwya1sbymwm5swlh2j4jagb6fal945g88zrzh5xf26hzjh";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Marlin auto bed leveling control, mesh correction, and z probe handling";
       homepage = "https://framagit.org/razer/Octoprint_ABL_Expert/";
       license = licenses.agpl3;
@@ -44,7 +44,7 @@ in {
 
     propagatedBuildInputs = with super; [ numpy ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Displays 3D mesh of bed topography report";
       homepage = "https://github.com/jneilliii/OctoPrint-BedLevelVisualizer";
       license = licenses.agpl3;
@@ -63,7 +63,7 @@ in {
       sha256 = "1a7pxlmj1a7blkv97sn1k390pbjcxx2860011pbjcdnli74zpvv5";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Plugin for slicing via Cura Legacy from within OctoPrint";
       homepage = "https://github.com/OctoPrint/OctoPrint-CuraEngineLegacy";
       license = licenses.agpl3;
@@ -82,7 +82,7 @@ in {
       sha256 = "1lbivg3rcjzv8zqvp8n8gcaczxdm7gvd5ihjb6jq0fgf958lv59n";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "OctoPrint-Plugin that sends the current progress of a print via M117 command";
       homepage = "https://github.com/OllisGit/OctoPrint-DisplayLayerProgress";
       license = licenses.agpl3;
@@ -101,7 +101,7 @@ in {
       sha256 = "1yjj9lmxbzmzrn7gahw9lj7554fphalbjjp8ns0rr9py3rshwxkm";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Edit gcode on OctoPrint";
       homepage = "https://github.com/ieatacid/OctoPrint-GcodeEditor";
       license = licenses.agpl3;
@@ -120,7 +120,7 @@ in {
       sha256 = "0vx06w9hqwy0k4r8g67y8gdckfdx7wl8ghfx6hmxc1s8fgkghfkc";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Displays GCode documentation for Marlin in the Octoprint terminal command line";
       homepage = "https://github.com/costas-basdekis/MarlinGcodeDocumentation";
       license = licenses.agpl3;
@@ -141,7 +141,7 @@ in {
 
     propagatedBuildInputs = with super; [ paho-mqtt ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Publish printer status MQTT";
       homepage = "https://github.com/OctoPrint/OctoPrint-MQTT";
       license = licenses.agpl3;
@@ -170,7 +170,7 @@ in {
       ./printtimegenius-logging.patch
     ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Better print time estimation for OctoPrint";
       homepage = "https://github.com/eyal0/OctoPrint-PrintTimeGenius";
       license = licenses.agpl3;
@@ -194,7 +194,7 @@ in {
       sed /RPi.GPIO/d -i requirements.txt
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "OctoPrint plugin to control ATX/AUX power supply";
       homepage = "https://github.com/kantlivelong/OctoPrint-PSUControl";
       license = licenses.agpl3;
@@ -213,7 +213,7 @@ in {
       sha256 = "0hhh5grmn32abkix1b9fr1d0pcpdi2r066iypcxdxcza9qzwjiyi";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A simple plugin that add an emergency stop buton on NavBar of OctoPrint";
       homepage = "https://github.com/Sebclem/OctoPrint-SimpleEmergencyStop";
       license = licenses.agpl3;
@@ -232,7 +232,7 @@ in {
       sha256 = "0mkvh44fn2ch4z2avsdjwi1rp353ylmk9j5fln4x7rx8ph8y7g2b";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A simple stl viewer tab for OctoPrint";
       homepage = "https://github.com/jneilliii/Octoprint-STLViewer";
       license = licenses.agpl3;
@@ -251,7 +251,7 @@ in {
       sha256 = "0j1qs6kyh947npdy7pqda25fjkqinpas3sy0qyscqlxi558lhvx2";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Beautiful themes for OctoPrint";
       homepage = "https://github.com/birkbjo/OctoPrint-Themeify";
       license = licenses.agpl3;
@@ -270,7 +270,7 @@ in {
       sha256 = "10nxjrixg0i6n6x8ghc1ndshm25c97bvkcis5j9kmlkkzs36i2c6";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Show printers status in window title";
       homepage = "https://github.com/MoonshineSG/OctoPrint-TitleStatus";
       license = licenses.agpl3;
@@ -289,7 +289,7 @@ in {
       sha256 = "1jlqjirc4ygl4k7jp93l2h6b18jap3mzz8sf2g61j9w0kgv9l365";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Touch friendly interface for a small TFT module or phone for OctoPrint";
       homepage = "https://github.com/BillyBlaze/OctoPrint-TouchUI";
       license = licenses.agpl3;
@@ -308,7 +308,7 @@ in {
       sha256 = "15yg2blbgqp2gdpsqqm8qiiznq5qaq8wss07jimkl0865vrvlz7l";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A plugin for a better integration of Klipper into OctoPrint";
       homepage = "https://github.com/AliceGrey/OctoprintKlipperPlugin";
       license = licenses.agpl3;
@@ -327,7 +327,7 @@ in {
       sha256 = "0p94jwd7kagh3sixhcrqmsgbay4aaf9l1pgyi2b45jym8pvld5n4";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A dashboard for Octoprint";
       homepage = "https://github.com/StefanCohen/OctoPrint-Dashboard";
       license = licenses.agpl3;
diff --git a/pkgs/applications/misc/ola/default.nix b/pkgs/applications/misc/ola/default.nix
index a9f12d572c8a4..6524052e5f3b2 100644
--- a/pkgs/applications/misc/ola/default.nix
+++ b/pkgs/applications/misc/ola/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , bison
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A framework for controlling entertainment lighting equipment";
     homepage = "https://www.openlighting.org/ola/";
     maintainers = with maintainers; [ globin ];
diff --git a/pkgs/applications/misc/olifant/default.nix b/pkgs/applications/misc/olifant/default.nix
index 21091b2583a5d..b6d184efe46bb 100644
--- a/pkgs/applications/misc/olifant/default.nix
+++ b/pkgs/applications/misc/olifant/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple Mastodon client designed for elementary OS, originally developed by @bleakgrey";
     homepage = "https://github.com/cleac/olifant";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/omegat.nix b/pkgs/applications/misc/omegat.nix
index 47536cc9f6a48..7b91d245f810e 100644
--- a/pkgs/applications/misc/omegat.nix
+++ b/pkgs/applications/misc/omegat.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, jdk, makeWrapper}:
+{ lib, stdenv, fetchurl, unzip, jdk, makeWrapper}:
 
 stdenv.mkDerivation {
   version = "4.3.0";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/omegat
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The free computer aided translation (CAT) tool for professionals";
     longDescription = ''
       OmegaT is a free and open source multiplatform Computer Assisted Translation
diff --git a/pkgs/applications/misc/onboard/default.nix b/pkgs/applications/misc/onboard/default.nix
index e427519d4d6e2..3c7f87ff96725 100644
--- a/pkgs/applications/misc/onboard/default.nix
+++ b/pkgs/applications/misc/onboard/default.nix
@@ -1,5 +1,5 @@
 { fetchurl
-, stdenv
+, lib, stdenv
 , substituteAll
 , aspellWithDicts
 , at-spi2-core ? null
@@ -172,7 +172,7 @@ python3.pkgs.buildPythonApplication rec {
     rm -rf  $out/share/icons/ubuntu-mono-*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/onboard";
     description = "Onscreen keyboard useful for tablet PC users and for mobility impaired users";
     maintainers = with maintainers; [ johnramsden ];
diff --git a/pkgs/applications/misc/oneko/default.nix b/pkgs/applications/misc/oneko/default.nix
index 1c5858b5677fc..48b29f4b561de 100644
--- a/pkgs/applications/misc/oneko/default.nix
+++ b/pkgs/applications/misc/oneko/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, imake, gccmakedep, xlibsWrapper }:
+{ lib, stdenv, fetchurl, imake, gccmakedep, xlibsWrapper }:
 
 stdenv.mkDerivation rec {
   version_name = "1.2.sakura.5";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   makeFlags = [ "BINDIR=$(out)/bin" "MANPATH=$(out)/share/man" ];
   installTargets = [ "install" "install.man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Creates a cute cat chasing around your mouse cursor";
     longDescription = ''
     Oneko changes your mouse cursor into a mouse
diff --git a/pkgs/applications/misc/openbrf/default.nix b/pkgs/applications/misc/openbrf/default.nix
index 8e990b6dffba5..ec5d3c0a07520 100644
--- a/pkgs/applications/misc/openbrf/default.nix
+++ b/pkgs/applications/misc/openbrf/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, qtbase, vcg, glew, qmake, libGLU, libGL }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, qtbase, vcg, glew, qmake, libGLU, libGL }:
 
 
 mkDerivation {
@@ -37,7 +37,7 @@ mkDerivation {
 
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to edit resource files (BRF)";
     homepage = "https://github.com/cfcohen/openbrf";
     maintainers = with stdenv.lib.maintainers; [ abbradar ];
diff --git a/pkgs/applications/misc/opentx/default.nix b/pkgs/applications/misc/opentx/default.nix
index 770d12d27223c..53dbde29a0ea4 100644
--- a/pkgs/applications/misc/opentx/default.nix
+++ b/pkgs/applications/misc/opentx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub
+{ lib, stdenv, mkDerivation, fetchFromGitHub
 , cmake, gcc-arm-embedded, python3Packages
 , qtbase, qtmultimedia, qttranslations, SDL, gtest
 , dfu-util, avrdude
@@ -33,7 +33,7 @@ mkDerivation rec {
     #"-DAVRDUDE_PATH=${avrdude}/bin/avrdude"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenTX Companion transmitter support software";
     longDescription = ''
       OpenTX Companion is used for many different tasks like loading OpenTX
diff --git a/pkgs/applications/misc/orca/default.nix b/pkgs/applications/misc/orca/default.nix
index e438fd0762fab..be6928a874660 100644
--- a/pkgs/applications/misc/orca/default.nix
+++ b/pkgs/applications/misc/orca/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pkgconfig
 , fetchurl
 , buildPythonApplication
@@ -97,7 +97,7 @@ buildPythonApplication rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Projects/Orca";
     description = "Screen reader";
     longDescription = ''
diff --git a/pkgs/applications/misc/osm2xmap/default.nix b/pkgs/applications/misc/osm2xmap/default.nix
index 1c89333649840..3c06ed19e5241 100644
--- a/pkgs/applications/misc/osm2xmap/default.nix
+++ b/pkgs/applications/misc/osm2xmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libroxml, proj, libyamlcpp, boost } :
+{ lib, stdenv, fetchFromGitHub, libroxml, proj, libyamlcpp, boost } :
 
 stdenv.mkDerivation rec {
   pname = "osm2xmap";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libroxml proj libyamlcpp boost ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sembruk/osm2xmap";
     description = "Converter from OpenStreetMap data format to OpenOrienteering Mapper format";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/osmctools/default.nix b/pkgs/applications/misc/osmctools/default.nix
index b0f1f48d9aea3..fc46ffb7fface 100644
--- a/pkgs/applications/misc/osmctools/default.nix
+++ b/pkgs/applications/misc/osmctools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, autoreconfHook, zlib }:
+{ lib, stdenv, fetchFromGitLab, autoreconfHook, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "osmctools";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tools for transforming Open Street Map files";
     homepage = [
       "https://wiki.openstreetmap.org/wiki/osmconvert"
diff --git a/pkgs/applications/misc/osmium-tool/default.nix b/pkgs/applications/misc/osmium-tool/default.nix
index 78878d79553de..2397f3b8806b5 100644
--- a/pkgs/applications/misc/osmium-tool/default.nix
+++ b/pkgs/applications/misc/osmium-tool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , installShellFiles
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     installShellCompletion --zsh ../zsh_completion/_osmium
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multipurpose command line tool for working with OpenStreetMap data based on the Osmium library";
     homepage = "https://osmcode.org/osmium-tool/";
     license = with licenses; [ gpl3Plus mit bsd3 ];
diff --git a/pkgs/applications/misc/pastel/default.nix b/pkgs/applications/misc/pastel/default.nix
index aaaf6dc778b9b..7fd88348fe9e3 100644
--- a/pkgs/applications/misc/pastel/default.nix
+++ b/pkgs/applications/misc/pastel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "pastel";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line tool to generate, analyze, convert and manipulate colors";
     homepage = "https://github.com/sharkdp/pastel";
     changelog = "https://github.com/sharkdp/pastel/releases/tag/v${version}";
diff --git a/pkgs/applications/misc/pbpst/default.nix b/pkgs/applications/misc/pbpst/default.nix
index c1fd6c5d7cb8b..ebca7a4240916 100644
--- a/pkgs/applications/misc/pbpst/default.nix
+++ b/pkgs/applications/misc/pbpst/default.nix
@@ -1,4 +1,4 @@
-{ llvmPackages, stdenv, fetchFromGitHub
+{ llvmPackages, lib, stdenv, fetchFromGitHub
 , python36Packages, which, pkgconfig, curl, git, gettext, jansson
 
 # Optional overrides
@@ -39,7 +39,7 @@ llvmPackages.stdenv.mkDerivation rec {
     "--provider=${provider}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line libcurl C client for pb deployments";
     inherit (src.meta) homepage;
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/pcmanfm/default.nix b/pkgs/applications/misc/pcmanfm/default.nix
index 202e7a2de95f8..15aedb8e709e6 100644
--- a/pkgs/applications/misc/pcmanfm/default.nix
+++ b/pkgs/applications/misc/pcmanfm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glib, intltool, libfm, libX11, pango, pkgconfig
+{ lib, stdenv, fetchurl, glib, intltool, libfm, libX11, pango, pkgconfig
 , wrapGAppsHook, gnome3, withGtk3 ? true, gtk2, gtk3 }:
 
 let
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = optional withGtk3 "--with-gtk=3";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://blog.lxde.org/category/pcmanfm/";
     license = licenses.gpl2Plus;
     description = "File manager with GTK interface";
diff --git a/pkgs/applications/misc/pcmanx-gtk2/default.nix b/pkgs/applications/misc/pcmanx-gtk2/default.nix
index 6c3241d629b8f..cb8b615077737 100644
--- a/pkgs/applications/misc/pcmanx-gtk2/default.nix
+++ b/pkgs/applications/misc/pcmanx-gtk2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk2, libXft, intltool, automake, autoconf, libtool, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, gtk2, libXft, intltool, automake, autoconf, libtool, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "pcmanx-gtk2";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cd libltdl; autoreconf; cd ..
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pcman.ptt.cc";
     license = licenses.gpl2;
     description = "Telnet BBS browser with GTK interface";
diff --git a/pkgs/applications/misc/pdf-quench/default.nix b/pkgs/applications/misc/pdf-quench/default.nix
index c84c09e59a7eb..907cceeb58b70 100644
--- a/pkgs/applications/misc/pdf-quench/default.nix
+++ b/pkgs/applications/misc/pdf-quench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgs, python3, wrapGAppsHook}:
+{ lib, stdenv, fetchFromGitHub, pkgs, python3, wrapGAppsHook}:
 
 python3.pkgs.buildPythonApplication {
   pname = "pdf-quench";
@@ -27,7 +27,7 @@ python3.pkgs.buildPythonApplication {
     install -D -T -m 755 src/pdf_quench.py $out/bin/pdf-quench
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxerwang/pdf-quench";
     description = "A visual tool for cropping pdf files";
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/pdfdiff/default.nix b/pkgs/applications/misc/pdfdiff/default.nix
index 93ca8c6447983..31719cdfef2bd 100644
--- a/pkgs/applications/misc/pdfdiff/default.nix
+++ b/pkgs/applications/misc/pdfdiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonPackages, fetchurl, xpdf }:
+{ lib, stdenv, pythonPackages, fetchurl, xpdf }:
 let
   py = pythonPackages;
 in
@@ -32,7 +32,7 @@ py.buildPythonApplication rec {
     substituteInPlace $out/bin/pdfdiff --replace "#!/usr/bin/python" "#!${pythonPackages.python.interpreter}"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.cs.ox.ac.uk/people/cas.cremers/misc/pdfdiff.html";
     description = "Tool to view the difference between two PDF or PS files";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/pdfmod/default.nix b/pkgs/applications/misc/pdfmod/default.nix
index 90107be64c728..76eeaa4da7fac 100644
--- a/pkgs/applications/misc/pdfmod/default.nix
+++ b/pkgs/applications/misc/pdfmod/default.nix
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Attic/PdfMod";
     description = "A simple application for modifying PDF documents";
     platforms = platforms.all;
diff --git a/pkgs/applications/misc/pdfpc/default.nix b/pkgs/applications/misc/pdfpc/default.nix
index 216f8c4b8b8e1..5714b04c7d1bf 100644
--- a/pkgs/applications/misc/pdfpc/default.nix
+++ b/pkgs/applications/misc/pdfpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, vala, gtk3, libgee, fetchpatch
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, vala, gtk3, libgee, fetchpatch
 , poppler, libpthreadstubs, gstreamer, gst-plugins-base, gst-plugins-good, gst-libav, librsvg, pcre, gobject-introspection, wrapGAppsHook
 , webkitgtk, discount, json-glib }:
 
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = stdenv.lib.optional stdenv.isDarwin "-DMOVIES=OFF";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A presenter console with multi-monitor support for PDF files";
     homepage = "https://pdfpc.github.io/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/pdfsam-basic/default.nix b/pkgs/applications/misc/pdfsam-basic/default.nix
index 039967f418200..2aeb3ba7f99fd 100644
--- a/pkgs/applications/misc/pdfsam-basic/default.nix
+++ b/pkgs/applications/misc/pdfsam-basic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeDesktopItem, fetchurl, jdk11, wrapGAppsHook, glib }:
+{ lib, stdenv, makeDesktopItem, fetchurl, jdk11, wrapGAppsHook, glib }:
 
 stdenv.mkDerivation rec {
   pname = "pdfsam-basic";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     categories = "Office;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
       homepage = "https://github.com/torakiki/pdfsam";
       description = "Multi-platform software designed to extract pages, split, merge, mix and rotate PDF files";
       license = licenses.agpl3;
diff --git a/pkgs/applications/misc/peaclock/default.nix b/pkgs/applications/misc/peaclock/default.nix
index e824bbaf583b4..619b6ed9b3754 100644
--- a/pkgs/applications/misc/peaclock/default.nix
+++ b/pkgs/applications/misc/peaclock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libpthreadstubs, icu }:
+{ lib, stdenv, fetchFromGitHub, cmake, libpthreadstubs, icu }:
 
 stdenv.mkDerivation rec {
   pname = "peaclock";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ libpthreadstubs icu ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A clock, timer, and stopwatch for the terminal";
     homepage = "https://octobanana.com/software/peaclock";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/pell/default.nix b/pkgs/applications/misc/pell/default.nix
index ae96ce6925e3d..0b21de1e91e0d 100644
--- a/pkgs/applications/misc/pell/default.nix
+++ b/pkgs/applications/misc/pell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, scsh, sox, libnotify }:
+{ lib, stdenv, fetchFromGitHub, scsh, sox, libnotify }:
 
 stdenv.mkDerivation rec {
   pname = "pell";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/bin/pell --replace "/usr/share/pell/offline.mp3" "$out/share/offline.mp3"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ebzzry/pell";
     description = "A simple host availability monitor";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/pgadmin/default.nix b/pkgs/applications/misc/pgadmin/default.nix
index b0aabead24575..f4981f6d3fb79 100644
--- a/pkgs/applications/misc/pgadmin/default.nix
+++ b/pkgs/applications/misc/pgadmin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, postgresql, wxGTK, libxml2, libxslt, openssl, zlib, makeDesktopItem }:
+{ lib, stdenv, fetchurl, fetchpatch, postgresql, wxGTK, libxml2, libxslt, openssl, zlib, makeDesktopItem }:
 
 stdenv.mkDerivation rec {
   pname = "pgadmin3";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     "--with-libxslt=${libxslt.dev}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PostgreSQL administration GUI tool";
     homepage = "https://www.pgadmin.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/pgmanage/default.nix b/pkgs/applications/misc/pgmanage/default.nix
index 68f29cb9b9ace..b892ebb2a9e08 100644
--- a/pkgs/applications/misc/pgmanage/default.nix
+++ b/pkgs/applications/misc/pgmanage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, openssl } :
+{ lib, stdenv, fetchFromGitHub, postgresql, openssl } :
 
 stdenv.mkDerivation rec {
   pname = "pgmanage";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ postgresql openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast replacement for PGAdmin";
     longDescription = ''
       At the heart of pgManage is a modern, fast, event-based C-binary, built in
diff --git a/pkgs/applications/misc/pgmodeler/default.nix b/pkgs/applications/misc/pgmodeler/default.nix
index a690e72d3e785..67010e713c3cd 100644
--- a/pkgs/applications/misc/pgmodeler/default.nix
+++ b/pkgs/applications/misc/pgmodeler/default.nix
@@ -26,7 +26,7 @@ mkDerivation rec {
   # todo: libpq would suffice here. Unfortunately this won't work, if one uses only postgresql.lib here.
   buildInputs = [ postgresql qtsvg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database modeling tool for PostgreSQL";
     homepage = "https://pgmodeler.io/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/pinfo/default.nix b/pkgs/applications/misc/pinfo/default.nix
index 55093b21f950f..8668807e81cc1 100644
--- a/pkgs/applications/misc/pinfo/default.nix
+++ b/pkgs/applications/misc/pinfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, gettext, texinfo, ncurses, readline }:
+{ lib, stdenv, fetchurl, autoreconfHook, gettext, texinfo, ncurses, readline }:
 
 stdenv.mkDerivation {
   name = "pinfo-0.6.10";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   configureFlags = [ "--with-curses=${ncurses.dev}" "--with-readline=${readline.dev}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A viewer for info files";
     license = licenses.gpl2Plus;
     platforms = platforms.unix;
diff --git a/pkgs/applications/misc/pipr/default.nix b/pkgs/applications/misc/pipr/default.nix
index b3bde2a1c241f..7332f20168947 100644
--- a/pkgs/applications/misc/pipr/default.nix
+++ b/pkgs/applications/misc/pipr/default.nix
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
     wrapProgram "$out/bin/pipr" --prefix PATH : ${lib.makeBinPath [ bubblewrap ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A commandline-tool to interactively write shell pipelines";
     homepage = "https://github.com/ElKowar/pipr";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/plank/default.nix b/pkgs/applications/misc/plank/default.nix
index 0ae9e7379e7c8..cdc0868612439 100644
--- a/pkgs/applications/misc/plank/default.nix
+++ b/pkgs/applications/misc/plank/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , vala
 , atk
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
       --replace "/usr/bin/file" "${file}/bin/file"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Elegant, simple, clean dock";
     homepage = "https://launchpad.net/plank";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/plasma-applet-volumewin7mixer/default.nix b/pkgs/applications/misc/plasma-applet-volumewin7mixer/default.nix
index 820048bdd6b0a..d9feb28c037b0 100644
--- a/pkgs/applications/misc/plasma-applet-volumewin7mixer/default.nix
+++ b/pkgs/applications/misc/plasma-applet-volumewin7mixer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, extra-cmake-modules, plasma-framework, kwindowsystem, plasma-pa, fetchFromGitHub }:
+{ lib, stdenv, cmake, extra-cmake-modules, plasma-framework, kwindowsystem, plasma-pa, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "plasma-applet-volumewin7mixer";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake extra-cmake-modules ];
   buildInputs = [ plasma-framework kwindowsystem plasma-pa ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fork of the default volume plasmoid with a Windows 7 theme (vertical sliders)";
     homepage = "https://github.com/Zren/plasma-applet-volumewin7mixer";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/playonlinux/default.nix b/pkgs/applications/misc/playonlinux/default.nix
index 42412820c4860..73d50209e90fc 100644
--- a/pkgs/applications/misc/playonlinux/default.nix
+++ b/pkgs/applications/misc/playonlinux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , makeWrapper
 , fetchurl
 , cabextract
@@ -103,7 +103,7 @@ in stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for managing Windows programs under linux";
     homepage = "https://www.playonlinux.com/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/plover/default.nix b/pkgs/applications/misc/plover/default.nix
index 8ecc4f974b455..2a3368e351f74 100644
--- a/pkgs/applications/misc/plover/default.nix
+++ b/pkgs/applications/misc/plover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python27Packages, python36Packages, wmctrl,
+{ lib, stdenv, fetchurl, python27Packages, python36Packages, wmctrl,
   qtbase, mkDerivationWith }:
 
 {
@@ -6,7 +6,7 @@
     pname = "plover";
     version = "3.1.1";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "OpenSteno Plover stenography software";
       maintainers = with maintainers; [ twey kovirobi ];
       license     = licenses.gpl2;
@@ -28,7 +28,7 @@
     pname = "plover";
     version = "4.0.0.dev8";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "OpenSteno Plover stenography software";
       maintainers = with maintainers; [ twey kovirobi ];
       license     = licenses.gpl2;
diff --git a/pkgs/applications/misc/polybar/default.nix b/pkgs/applications/misc/polybar/default.nix
index 940cd1cdc9191..2556eb02062cb 100644
--- a/pkgs/applications/misc/polybar/default.nix
+++ b/pkgs/applications/misc/polybar/default.nix
@@ -1,5 +1,5 @@
 { cairo, cmake, fetchFromGitHub, libXdmcp, libpthreadstubs, libxcb, pcre, pkgconfig
-, python3, stdenv, xcbproto, xcbutil, xcbutilcursor, xcbutilimage
+, python3, lib, stdenv, xcbproto, xcbutil, xcbutilcursor, xcbutilimage
 , xcbutilrenderutil, xcbutilwm, xcbutilxrm, makeWrapper
 , removeReferencesTo
 
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
       fetchSubmodules = true;
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://polybar.github.io/";
       description = "A fast and easy-to-use tool for creating status bars";
       longDescription = ''
diff --git a/pkgs/applications/misc/posterazor/default.nix b/pkgs/applications/misc/posterazor/default.nix
index 391868503c2d2..602ac3e5e3b47 100644
--- a/pkgs/applications/misc/posterazor/default.nix
+++ b/pkgs/applications/misc/posterazor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, unzip, pkg-config, libXpm, fltk13, freeimage }:
+{ lib, stdenv, fetchurl, cmake, unzip, pkg-config, libXpm, fltk13, freeimage }:
 
 stdenv.mkDerivation {
   name = "posterazor-1.5.1";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
     cp PosteRazor $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://posterazor.sourceforge.net/";
     description = "Cuts a raster image into pieces which can afterwards be printed out and assembled to a poster";
     maintainers = [ maintainers.madjar ];
diff --git a/pkgs/applications/misc/prevo/data.nix b/pkgs/applications/misc/prevo/data.nix
index 7f61f60bf6ae0..efd19d7745cae 100644
--- a/pkgs/applications/misc/prevo/data.nix
+++ b/pkgs/applications/misc/prevo/data.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, prevo-tools }:
+{ lib, stdenv, fetchFromGitHub, prevo-tools }:
 
 stdenv.mkDerivation rec {
   pname = "prevo-data";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp prevo.db $out/share/prevo/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "data for offline version of the Esperanto dictionary Reta Vortaro";
     longDescription = ''
diff --git a/pkgs/applications/misc/prevo/default.nix b/pkgs/applications/misc/prevo/default.nix
index 1f299b15d4092..92d7886950355 100644
--- a/pkgs/applications/misc/prevo/default.nix
+++ b/pkgs/applications/misc/prevo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, symlinkJoin, prevo-tools, prevo-data, makeWrapper }:
+{ lib, stdenv, symlinkJoin, prevo-tools, prevo-data, makeWrapper }:
 
 symlinkJoin rec {
   name = "prevo-${version}";
@@ -13,7 +13,7 @@ symlinkJoin rec {
       --prefix XDG_DATA_DIRS : "${prevo-data}/share"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "offline version of the Esperanto dictionary Reta Vortaro";
     longDescription = ''
       PReVo is the "portable" ReVo, i.e., the offline version
diff --git a/pkgs/applications/misc/prevo/tools.nix b/pkgs/applications/misc/prevo/tools.nix
index 39c54b73b2fe2..508f085bb44b7 100644
--- a/pkgs/applications/misc/prevo/tools.nix
+++ b/pkgs/applications/misc/prevo/tools.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkg-config, glib, expat
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config, glib, expat
 , installShellFiles }:
 
 stdenv.mkDerivation rec {
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     installShellCompletion --bash src/prevo-completion
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "CLI tools for the offline version of the Esperanto dictionary Reta Vortaro";
     longDescription = ''
diff --git a/pkgs/applications/misc/printrun/default.nix b/pkgs/applications/misc/printrun/default.nix
index c8f454c3545d4..bd45e742f54be 100644
--- a/pkgs/applications/misc/printrun/default.nix
+++ b/pkgs/applications/misc/printrun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python27Packages, fetchFromGitHub }:
+{ lib, stdenv, python27Packages, fetchFromGitHub }:
 
 python27Packages.buildPythonApplication rec {
   pname = "printrun";
@@ -29,7 +29,7 @@ python27Packages.buildPythonApplication rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pronterface, Pronsole, and Printcore - Pure Python 3d printing host software";
     homepage = "https://github.com/kliment/Printrun";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/procmail/default.nix b/pkgs/applications/misc/procmail/default.nix
index 1e6c558defbe0..1244347cc53c9 100644
--- a/pkgs/applications/misc/procmail/default.nix
+++ b/pkgs/applications/misc/procmail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "procmail-3.22";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     sha256 = "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mail processing and filtering utility";
     homepage = "http://www.procmail.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/projectlibre/default.nix b/pkgs/applications/misc/projectlibre/default.nix
index 2a7a82bc74a49..fd83d74edd541 100644
--- a/pkgs/applications/misc/projectlibre/default.nix
+++ b/pkgs/applications/misc/projectlibre/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, ant, jdk, makeWrapper, jre, coreutils, which }:
+{ lib, stdenv, fetchgit, ant, jdk, makeWrapper, jre, coreutils, which }:
 
 stdenv.mkDerivation rec {
   pname = "projectlibre";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     cp -R $resourcesPath/samples/* $out/share/projectlibre/samples
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.projectlibre.com/";
     description = "Project-Management Software similar to MS-Project";
     maintainers = [ maintainers.Mogria ];
diff --git a/pkgs/applications/misc/prusa-slicer/default.nix b/pkgs/applications/misc/prusa-slicer/default.nix
index d715e08fbe0d0..80936d910a3d9 100644
--- a/pkgs/applications/misc/prusa-slicer/default.nix
+++ b/pkgs/applications/misc/prusa-slicer/default.nix
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
     categories = "Development;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "G-code generator for 3D printer";
     homepage = "https://github.com/prusa3d/PrusaSlicer";
     license = licenses.agpl3;
diff --git a/pkgs/applications/misc/prusa-slicer/super-slicer.nix b/pkgs/applications/misc/prusa-slicer/super-slicer.nix
index 2bc59e855a086..eed3bfc9c3130 100644
--- a/pkgs/applications/misc/prusa-slicer/super-slicer.nix
+++ b/pkgs/applications/misc/prusa-slicer/super-slicer.nix
@@ -38,7 +38,7 @@ let
       categories = "Development;";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       inherit description;
       homepage = "https://github.com/supermerili/SuperSlicer";
       license = licenses.agpl3;
diff --git a/pkgs/applications/misc/pstree/default.nix b/pkgs/applications/misc/pstree/default.nix
index 7aaa8a8c38d20..d25e4a6f90baa 100644
--- a/pkgs/applications/misc/pstree/default.nix
+++ b/pkgs/applications/misc/pstree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "pstree";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Show the set of running processes as a tree";
     homepage = "http://www.thp.uni-duisburg.de/pstree/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/ptask/default.nix b/pkgs/applications/misc/ptask/default.nix
index a5fd55c967bb2..011b782053eaf 100644
--- a/pkgs/applications/misc/ptask/default.nix
+++ b/pkgs/applications/misc/ptask/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, makeWrapper, gtk3, json_c, taskwarrior }:
+{ lib, stdenv, fetchurl, pkgconfig, makeWrapper, gtk3, json_c, taskwarrior }:
 
 stdenv.mkDerivation rec {
   name = "ptask-1.0.0";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${taskwarrior}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://wpitchoune.net/ptask/";
     description = "GTK-based GUI for taskwarrior";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/pwsafe/default.nix b/pkgs/applications/misc/pwsafe/default.nix
index 0e0ddffaac072..c1b9d04d67306 100644
--- a/pkgs/applications/misc/pwsafe/default.nix
+++ b/pkgs/applications/misc/pwsafe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, zip, gettext, perl
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, zip, gettext, perl
 , wxGTK30, libXext, libXi, libXt, libXtst, xercesc
 , qrencode, libuuid, libyubikey, yubikey-personalization
 , curl, openssl, file
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A password database utility";
     longDescription = ''
       Password Safe is a password database utility. Like many other
diff --git a/pkgs/applications/misc/pydf/default.nix b/pkgs/applications/misc/pydf/default.nix
index aa2835107088d..0135e10d6df11 100644
--- a/pkgs/applications/misc/pydf/default.nix
+++ b/pkgs/applications/misc/pydf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonPackage rec {
   pname = "pydf";
@@ -15,7 +15,7 @@ python3Packages.buildPythonPackage rec {
     install -t $out/share/man/man1 -m 444 pydf.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "colourised df(1)-clone";
     homepage = "http://kassiopeia.juls.savba.sk/~garabik/software/pydf/";
     license = licenses.publicDomain;
diff --git a/pkgs/applications/misc/pyditz/cerberus.nix b/pkgs/applications/misc/pyditz/cerberus.nix
index be12906e61ec3..a26b6b014da4e 100644
--- a/pkgs/applications/misc/pyditz/cerberus.nix
+++ b/pkgs/applications/misc/pyditz/cerberus.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytestrunner, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytestrunner, pytest }:
 
 buildPythonPackage rec {
   pname = "Cerberus";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestrunner pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://python-cerberus.org/";
     description = "Lightweight, extensible schema and data validation tool for Python dictionaries";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/pyditz/default.nix b/pkgs/applications/misc/pyditz/default.nix
index d8b2b2ec602eb..268d2fb286093 100644
--- a/pkgs/applications/misc/pyditz/default.nix
+++ b/pkgs/applications/misc/pyditz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonPackages }:
+{ lib, stdenv, pythonPackages }:
 
 with pythonPackages;
 
@@ -19,7 +19,7 @@ in buildPythonApplication rec {
     ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pythonhosted.org/pyditz/";
     description = "Drop-in replacement for the Ditz distributed issue tracker";
     maintainers = [ maintainers.ilikeavocadoes ];
diff --git a/pkgs/applications/misc/pytrainer/default.nix b/pkgs/applications/misc/pytrainer/default.nix
index 00c4511417922..eb775a1f60241 100644
--- a/pkgs/applications/misc/pytrainer/default.nix
+++ b/pkgs/applications/misc/pytrainer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , perl
 , python3
@@ -84,7 +84,7 @@ python3.pkgs.buildPythonApplication rec {
       ${python3.interpreter} setup.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pytrainer/pytrainer/wiki";
     description = "Application for logging and graphing sporting excursions";
     maintainers = [ maintainers.rycee ];
diff --git a/pkgs/applications/misc/qMasterPassword/default.nix b/pkgs/applications/misc/qMasterPassword/default.nix
index c2adcabe414c4..d3449da97f367 100644
--- a/pkgs/applications/misc/qMasterPassword/default.nix
+++ b/pkgs/applications/misc/qMasterPassword/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qtbase, qmake, libX11, libXtst, openssl, libscrypt }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qtbase, qmake, libX11, libXtst, openssl, libscrypt }:
 
 mkDerivation rec {
   name = "qMasterPassword";
@@ -30,7 +30,7 @@ mkDerivation rec {
     mv data/icons/* $out/share/icons/qmasterpassword
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stateless Master Password Manager";
     longDescription = ''
       Access all your passwords using only a single master password. But in
diff --git a/pkgs/applications/misc/qcad/default.nix b/pkgs/applications/misc/qcad/default.nix
index a0d370c00ac1e..ac1db54ebcea9 100644
--- a/pkgs/applications/misc/qcad/default.nix
+++ b/pkgs/applications/misc/qcad/default.nix
@@ -10,7 +10,7 @@
 , qtsvg
 , qtxmlpatterns
 , qttools
-, stdenv
+, lib, stdenv
 }:
 
 mkDerivationWith stdenv.mkDerivation rec {
@@ -92,7 +92,7 @@ mkDerivationWith stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "2D CAD package based on Qt";
     homepage = "https://qcad.org";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/qdirstat/default.nix b/pkgs/applications/misc/qdirstat/default.nix
index e9f049159bfa7..a51bd3a80c051 100644
--- a/pkgs/applications/misc/qdirstat/default.nix
+++ b/pkgs/applications/misc/qdirstat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qmake
+{ lib, stdenv, fetchFromGitHub, qmake
 , coreutils, xdg_utils, bash
 , makeWrapper, perlPackages, mkDerivation }:
 
@@ -47,7 +47,7 @@ mkDerivation {
       --set PERL5LIB "${perlPackages.makePerlPath [ perlPackages.URI ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical disk usage analyzer";
     homepage = src.meta.homepage;
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/qlandkartegt/garmindev.nix b/pkgs/applications/misc/qlandkartegt/garmindev.nix
index 22b6dfbf33d59..07b58b72c494f 100644
--- a/pkgs/applications/misc/qlandkartegt/garmindev.nix
+++ b/pkgs/applications/misc/qlandkartegt/garmindev.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, libusb-compat-0_1 }:
+{ lib, stdenv, fetchurl, cmake, libusb-compat-0_1 }:
 
 stdenv.mkDerivation rec {
   pname = "garmindev";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libusb-compat-0_1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.qlandkarte.org/";
     description = "Garmin Device Drivers for QlandkarteGT";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/qlcplus/default.nix b/pkgs/applications/misc/qlcplus/default.nix
index 452629b6181da..0f359007696dd 100644
--- a/pkgs/applications/misc/qlcplus/default.nix
+++ b/pkgs/applications/misc/qlcplus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, pkgconfig, udev
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, pkgconfig, udev
 , qtmultimedia, qtscript, alsaLib, ola, libftdi1, libusb-compat-0_1
 , libsndfile, libmad
 }:
@@ -35,7 +35,7 @@ mkDerivation rec {
     ln -sf $out/lib/*/libqlcplus* $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free and cross-platform software to control DMX or analog lighting systems like moving heads, dimmers, scanners etc";
     maintainers = [ maintainers.globin ];
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/qmetro/default.nix b/pkgs/applications/misc/qmetro/default.nix
index 623bd050dc9b6..70c41ff3142f6 100644
--- a/pkgs/applications/misc/qmetro/default.nix
+++ b/pkgs/applications/misc/qmetro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qmake4Hook, unzip, qt4 }:
+{ lib, stdenv, fetchurl, qmake4Hook, unzip, qt4 }:
 
 stdenv.mkDerivation rec {
   name = "${project}-${version}";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/qmetro/";
     description = "Worldwide transit maps viewer";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/qsudo/default.nix b/pkgs/applications/misc/qsudo/default.nix
index 63d97b3001c47..f7dbc9a90581a 100644
--- a/pkgs/applications/misc/qsudo/default.nix
+++ b/pkgs/applications/misc/qsudo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchFromGitHub
 , qmake
@@ -32,7 +32,7 @@ mkDerivation rec {
     substituteInPlace qsudo.pro --replace /usr/bin $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical sudo utility from Project Trident";
     homepage = "https://github.com/project-trident/qsudo";
     license = licenses.bsd2;
diff --git a/pkgs/applications/misc/qt-box-editor/default.nix b/pkgs/applications/misc/qt-box-editor/default.nix
index 852f0d30f9a5b..5de2428250a0c 100644
--- a/pkgs/applications/misc/qt-box-editor/default.nix
+++ b/pkgs/applications/misc/qt-box-editor/default.nix
@@ -1,5 +1,5 @@
 { mkDerivation
-, stdenv
+, lib, stdenv
 , fetchFromGitHub
 , qtbase
 , qtsvg
@@ -29,7 +29,7 @@ mkDerivation {
     printf "INSTALLS += target\ntarget.path = $out/bin" >>  qt-box-editor.pro
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Editor of tesseract-ocr box files";
     homepage = "https://github.com/zdenop/qt-box-editor";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/qtbitcointrader/default.nix b/pkgs/applications/misc/qtbitcointrader/default.nix
index c5dfdf95fb5e3..4ab70a5a8d7d1 100644
--- a/pkgs/applications/misc/qtbitcointrader/default.nix
+++ b/pkgs/applications/misc/qtbitcointrader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, qt5, mkDerivation }:
+{ lib, stdenv, fetchzip, qt5, mkDerivation }:
 
 let
   version = "1.40.43";
@@ -26,7 +26,7 @@ mkDerivation {
     runHook postConfigure
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bitcoin trading client";
     homepage = "https://centrabit.com/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/redshift-plasma-applet/default.nix b/pkgs/applications/misc/redshift-plasma-applet/default.nix
index c14eee398ceec..fa5ee0c753aac 100644
--- a/pkgs/applications/misc/redshift-plasma-applet/default.nix
+++ b/pkgs/applications/misc/redshift-plasma-applet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, extra-cmake-modules, plasma-framework, kwindowsystem, redshift, fetchFromGitHub, }:
+{ lib, stdenv, cmake, extra-cmake-modules, plasma-framework, kwindowsystem, redshift, fetchFromGitHub, }:
 
 let version = "1.0.18"; in
 
@@ -35,7 +35,7 @@ stdenv.mkDerivation {
     kwindowsystem
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "KDE Plasma 5 widget for controlling Redshift";
     homepage = "https://github.com/kotelnik/plasma-applet-redshift-control";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/redshift/default.nix b/pkgs/applications/misc/redshift/default.nix
index 99d65eb090a7c..6e48a75810e49 100644
--- a/pkgs/applications/misc/redshift/default.nix
+++ b/pkgs/applications/misc/redshift/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchFromGitLab
+{ lib, stdenv, fetchFromGitHub, fetchFromGitLab
 , autoconf, automake, gettext, intltool
 , libtool, pkgconfig, wrapGAppsHook, wrapPython, gobject-introspection
 , gtk3, python, pygobject3, pyxdg
@@ -95,7 +95,7 @@ rec {
       sha256 = "12cb4gaqkybp4bkkns8pam378izr2mwhr2iy04wkprs2v92j7bz6";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Screen color temperature manager";
       longDescription = ''
         Redshift adjusts the color temperature according to the position
diff --git a/pkgs/applications/misc/regextester/default.nix b/pkgs/applications/misc/regextester/default.nix
index 22f46eed7df47..a6762d7d84604 100644
--- a/pkgs/applications/misc/regextester/default.nix
+++ b/pkgs/applications/misc/regextester/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , vala
 , gettext
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     ${glib.dev}/bin/glib-compile-schemas $out/share/glib-2.0/schemas
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A desktop application to test regular expressions interactively";
     homepage = "https://github.com/artemanufrij/regextester";
     maintainers = with maintainers; [ samdroid-apps ];
diff --git a/pkgs/applications/misc/remarkable/remarkable-mouse/default.nix b/pkgs/applications/misc/remarkable/remarkable-mouse/default.nix
index c07fe631f4464..77538f2436149 100644
--- a/pkgs/applications/misc/remarkable/remarkable-mouse/default.nix
+++ b/pkgs/applications/misc/remarkable/remarkable-mouse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchPypi, python3Packages }:
+{ lib, stdenv, buildPythonApplication, fetchPypi, python3Packages }:
 
 buildPythonApplication rec {
   pname = "remarkable-mouse";
@@ -15,7 +15,7 @@ buildPythonApplication rec {
   doCheck = false;
   pythonImportsCheck = [ "remarkable_mouse" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program to use a reMarkable as a graphics tablet";
     homepage = "https://github.com/evidlo/remarkable_mouse";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/remarkable/rmapi/default.nix b/pkgs/applications/misc/remarkable/rmapi/default.nix
index 5ccf930e620f1..22a154da4fd02 100644
--- a/pkgs/applications/misc/remarkable/rmapi/default.nix
+++ b/pkgs/applications/misc/remarkable/rmapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "rmapi";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Go app that allows access to the ReMarkable Cloud API programmatically";
     homepage = "https://github.com/juruen/rmapi";
     changelog = "https://github.com/juruen/rmapi/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/applications/misc/rofi-file-browser/default.nix b/pkgs/applications/misc/rofi-file-browser/default.nix
index 10453b8584911..d5b0944ac39c1 100644
--- a/pkgs/applications/misc/rofi-file-browser/default.nix
+++ b/pkgs/applications/misc/rofi-file-browser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, rofi, gtk3 }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, rofi, gtk3 }:
 
 stdenv.mkDerivation rec {
   pname = "rofi-file-browser-extended";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   dontUseCmakeBuildDir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Use rofi to quickly open files";
     homepage = "https://github.com/marvinkreis/rofi-file-browser-extended";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/rofi-menugen/default.nix b/pkgs/applications/misc/rofi-menugen/default.nix
index 088ec29ae37b0..6c9e5f6feff83 100644
--- a/pkgs/applications/misc/rofi-menugen/default.nix
+++ b/pkgs/applications/misc/rofi-menugen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rofi, gnused }:
+{ lib, stdenv, fetchFromGitHub, rofi, gnused }:
 
 stdenv.mkDerivation rec {
   rev = "168efd2608fdb88b1aff3e0244bda8402169f207";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     cp menugen $out/bin/rofi-menugen
     cp menugenbase $out/bin/rofi-menugenbase
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generates menu based applications using rofi";
     homepage = "https://github.com/octotep/menugen";
     maintainers = with maintainers; [ ];
diff --git a/pkgs/applications/misc/rootbar/default.nix b/pkgs/applications/misc/rootbar/default.nix
index 2eb3170b88cb8..d50cefb2a7180 100644
--- a/pkgs/applications/misc/rootbar/default.nix
+++ b/pkgs/applications/misc/rootbar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchhg
 , pkg-config
 , meson
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     wayland
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/alexays/waybar";
     description = "A bar for Wayland WMs";
     longDescription = ''
diff --git a/pkgs/applications/misc/rsclock/default.nix b/pkgs/applications/misc/rsclock/default.nix
index e1ae63e09fd37..d7b38e2d665da 100644
--- a/pkgs/applications/misc/rsclock/default.nix
+++ b/pkgs/applications/misc/rsclock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "rsClock";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "01dhkis6zswq1y40n7sdq9xv1sp61f2v7nfqbkicyjngmdrmcgrl";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple terminal clock written in Rust";
     homepage = "https://github.com/valebes/rsClock";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/rss-bridge-cli/default.nix b/pkgs/applications/misc/rss-bridge-cli/default.nix
index f481f0953f817..4ab79440b239e 100644
--- a/pkgs/applications/misc/rss-bridge-cli/default.nix
+++ b/pkgs/applications/misc/rss-bridge-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, writeShellScriptBin, rss-bridge, php }:
+{ lib, stdenv, writeShellScriptBin, rss-bridge, php }:
 
 let
   phpWithExts = (php.withExtensions
@@ -19,7 +19,7 @@ in (writeShellScriptBin "rss-bridge-cli" ''
 '').overrideAttrs (oldAttrs: rec {
   version = rss-bridge.version;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line interface for RSS-Bridge";
     homepage = "https://github.com/RSS-Bridge/rss-bridge";
     license = licenses.unlicense;
diff --git a/pkgs/applications/misc/rtv/default.nix b/pkgs/applications/misc/rtv/default.nix
index c4547e8751307..343936962329d 100644
--- a/pkgs/applications/misc/rtv/default.nix
+++ b/pkgs/applications/misc/rtv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 with python3Packages;
 buildPythonApplication rec {
@@ -37,7 +37,7 @@ buildPythonApplication rec {
     six
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/michael-lazar/rtv";
     description = "Browse Reddit from your Terminal";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/sc-im/default.nix b/pkgs/applications/misc/sc-im/default.nix
index 6ee4695d1717a..21cf60b60fcca 100644
--- a/pkgs/applications/misc/sc-im/default.nix
+++ b/pkgs/applications/misc/sc-im/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, yacc, ncurses, libxml2, libzip, libxls, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, yacc, ncurses, libxml2, libzip, libxls, pkgconfig }:
 
 stdenv.mkDerivation rec {
   version = "0.7.0";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     make install prefix=
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/andmarti1424/sc-im";
     description = "SC-IM - Spreadsheet Calculator Improvised - SC fork";
     license = licenses.bsdOriginal;
diff --git a/pkgs/applications/misc/sdcv/default.nix b/pkgs/applications/misc/sdcv/default.nix
index d220047a0a3b0..ea3fc7d30f12f 100644
--- a/pkgs/applications/misc/sdcv/default.nix
+++ b/pkgs/applications/misc/sdcv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, glib, gettext, readline }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, glib, gettext, readline }:
 
 stdenv.mkDerivation rec {
   pname = "sdcv";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-D__GNU_LIBRARY__";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://dushistov.github.io/sdcv/";
     description = "Console version of StarDict";
     maintainers = with maintainers; [ lovek323 ];
diff --git a/pkgs/applications/misc/sent/default.nix b/pkgs/applications/misc/sent/default.nix
index fe8598e49157d..f4b811e0752d3 100644
--- a/pkgs/applications/misc/sent/default.nix
+++ b/pkgs/applications/misc/sent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, farbfeld, libX11, libXft, makeWrapper
+{ lib, stdenv, fetchurl, farbfeld, libX11, libXft, makeWrapper
 , patches ? [] }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     wrapProgram "$out/bin/sent" --prefix PATH : "${farbfeld}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple plaintext presentation tool";
     homepage = "https://tools.suckless.org/sent/";
     license = licenses.isc;
diff --git a/pkgs/applications/misc/sequeler/default.nix b/pkgs/applications/misc/sequeler/default.nix
index d196217614079..ff7fc7dd08244 100644
--- a/pkgs/applications/misc/sequeler/default.nix
+++ b/pkgs/applications/misc/sequeler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nix-update-script
+{ lib, stdenv, fetchFromGitHub, nix-update-script
 , vala, meson, ninja, pkgconfig, pantheon, gettext, wrapGAppsHook, python3, desktop-file-utils
 , gtk3, glib, libgee, libgda, gtksourceview, libxml2, libsecret, libssh2 }:
 
@@ -35,7 +35,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Friendly SQL Client";
     longDescription = ''
       Sequeler is a native Linux SQL client built in Vala and Gtk. It allows you
diff --git a/pkgs/applications/misc/sidequest/default.nix b/pkgs/applications/misc/sidequest/default.nix
index 883b3eec03dbb..ef4d472e74c93 100644
--- a/pkgs/applications/misc/sidequest/default.nix
+++ b/pkgs/applications/misc/sidequest/default.nix
@@ -44,7 +44,7 @@
 		passthru = {
 			inherit pname version;
 
-			meta = with stdenv.lib; {
+			meta = with lib; {
 				description = "An open app store and side-loading tool for Android-based VR devices such as the Oculus Go, Oculus Quest or Moverio BT 300";
 				homepage = "https://github.com/the-expanse/SideQuest";
 				downloadPage = "https://github.com/the-expanse/SideQuest/releases";
diff --git a/pkgs/applications/misc/simplenote/default.nix b/pkgs/applications/misc/simplenote/default.nix
index fa0a47fdcb5ea..bc5814add89b5 100644
--- a/pkgs/applications/misc/simplenote/default.nix
+++ b/pkgs/applications/misc/simplenote/default.nix
@@ -23,7 +23,7 @@ let
     x86_64-linux = "123b0fh14068s2z3k6s5mmh46xwlz02qfnpmj838zlm5hckjmifv";
   }.${system} or throwSystem;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The simplest way to keep notes";
     homepage = "https://github.com/Automattic/simplenote-electron";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/slade/default.nix b/pkgs/applications/misc/slade/default.nix
index f278cf7fd9614..ed0dde0ffaf64 100644
--- a/pkgs/applications/misc/slade/default.nix
+++ b/pkgs/applications/misc/slade/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, wxGTK, gtk2, sfml, fluidsynth, curl, freeimage, ftgl, glew, zip }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, wxGTK, gtk2, sfml, fluidsynth, curl, freeimage, ftgl, glew, zip }:
 
 stdenv.mkDerivation rec {
   pname = "slade";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkgconfig zip ];
   buildInputs = [ wxGTK gtk2 sfml fluidsynth curl freeimage ftgl glew ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Doom editor";
     homepage = "http://slade.mancubus.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/slade/git.nix b/pkgs/applications/misc/slade/git.nix
index 056ba196cf571..b7fee00a40ffa 100644
--- a/pkgs/applications/misc/slade/git.nix
+++ b/pkgs/applications/misc/slade/git.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, wxGTK, gtk2, sfml, fluidsynth, curl, freeimage, ftgl, glew, zip }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, wxGTK, gtk2, sfml, fluidsynth, curl, freeimage, ftgl, glew, zip }:
 
 stdenv.mkDerivation {
   name = "slade-git-3.1.2.2018.01.29";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ cmake pkgconfig zip ];
   buildInputs = [ wxGTK gtk2 sfml fluidsynth curl freeimage ftgl glew ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Doom editor";
     homepage = "http://slade.mancubus.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/sleepyhead/default.nix b/pkgs/applications/misc/sleepyhead/default.nix
index 56063c737ab4c..1ea7893108dbd 100644
--- a/pkgs/applications/misc/sleepyhead/default.nix
+++ b/pkgs/applications/misc/sleepyhead/default.nix
@@ -37,7 +37,7 @@ in mkDerivation {
     wrapQtApp "$out/Applications/SleepyHead.app/Contents/MacOS/SleepyHead"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sleepyhead.jedimark.net/";
     description = "Review and explore data produced by CPAP and related machines";
     longDescription = ''
diff --git a/pkgs/applications/misc/slic3r/default.nix b/pkgs/applications/misc/slic3r/default.nix
index c8ecfbcb4a149..49ff51c2f4855 100644
--- a/pkgs/applications/misc/slic3r/default.nix
+++ b/pkgs/applications/misc/slic3r/default.nix
@@ -75,7 +75,7 @@ stdenv.mkDerivation rec {
     cp "$desktopItem"/share/applications/* "$out/share/applications/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "G-code generator for 3D printers";
     longDescription = ''
       Slic3r is the tool you need to convert a digital 3D model into printing
diff --git a/pkgs/applications/misc/smos/default.nix b/pkgs/applications/misc/smos/default.nix
index a1e118d76b382..7d994a749bd4e 100644
--- a/pkgs/applications/misc/smos/default.nix
+++ b/pkgs/applications/misc/smos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , unzip
 }:
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   unpackCmd = "${unzip}/bin/unzip -d $out $curSrc";
   sourceRoot = ".";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A comprehensive self-management system";
     homepage = https://smos.online;
     license = licenses.mit;
diff --git a/pkgs/applications/misc/snowsql/default.nix b/pkgs/applications/misc/snowsql/default.nix
index 720ee5f679963..6927719600176 100644
--- a/pkgs/applications/misc/snowsql/default.nix
+++ b/pkgs/applications/misc/snowsql/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , rpmextract
 , patchelf
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
       --set LD_LIBRARY_PATH "${libPath}":"${placeholder "out"}"/lib64/snowflake/snowsql \
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line client for the Snowflake database";
     homepage = "https://www.snowflake.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/speedread/default.nix b/pkgs/applications/misc/speedread/default.nix
index 180b66fda8ce4..a7b9cb591a5e7 100644
--- a/pkgs/applications/misc/speedread/default.nix
+++ b/pkgs/applications/misc/speedread/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl }:
+{ lib, stdenv, fetchFromGitHub, perl }:
 
 stdenv.mkDerivation rec {
   name = "speedread-unstable-2016-09-21";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     install -m755 -D speedread $out/bin/speedread
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple terminal-based open source Spritz-alike";
     longDescription = ''
       Speedread is a command line filter that shows input text as a
diff --git a/pkgs/applications/misc/sqliteman/default.nix b/pkgs/applications/misc/sqliteman/default.nix
index 24fbb985beffa..a0ddf8db053e2 100644
--- a/pkgs/applications/misc/sqliteman/default.nix
+++ b/pkgs/applications/misc/sqliteman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, qt4, qscintilla }:
+{ lib, stdenv, fetchFromGitHub, cmake, qt4, qscintilla }:
 
 stdenv.mkDerivation rec {
   pname = "sqliteman";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     sed -i 's,PATHS ''${QT_LIBRARY_DIR},PATHS ${qscintilla}/libs,' cmake/modules/FindQScintilla.cmake
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple but powerful Sqlite3 GUI database manager";
     homepage = "http://sqliteman.yarpen.cz/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/ssocr/default.nix b/pkgs/applications/misc/ssocr/default.nix
index d3a5eb7ec24fe..42bd58cd78316 100644
--- a/pkgs/applications/misc/ssocr/default.nix
+++ b/pkgs/applications/misc/ssocr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, imlib2, libX11 }:
+{ lib, stdenv, fetchFromGitHub, imlib2, libX11 }:
 
 stdenv.mkDerivation {
   pname = "ssocr";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Seven Segment Optical Character Recognition";
     homepage = "https://github.com/auerswal/ssocr";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/ssw/default.nix b/pkgs/applications/misc/ssw/default.nix
index 7e1e402581065..f3dc8e136a1d3 100644
--- a/pkgs/applications/misc/ssw/default.nix
+++ b/pkgs/applications/misc/ssw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkg-config, gtk3 }:
+{ lib, stdenv, fetchurl, pkg-config, gtk3 }:
 
 stdenv.mkDerivation rec {
   pname = "ssw";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkg-config ];
   buildInputs = [ gtk3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/ssw/";
     license = licenses.gpl3;
     description = "GNU Spread Sheet Widget";
diff --git a/pkgs/applications/misc/stog/default.nix b/pkgs/applications/misc/stog/default.nix
index 7b497dc60e47c..442750837bb55 100644
--- a/pkgs/applications/misc/stog/default.nix
+++ b/pkgs/applications/misc/stog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, ocaml, findlib, ocf, ptime,
+{ lib, stdenv, fetchFromGitLab, ocaml, findlib, ocf, ptime,
   uutf, uri, ppx_blob, xtmpl, ocaml_lwt, higlo, omd
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   patches = [ ./install.patch ./uri.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XML documents and web site compiler";
     homepage = "https://www.good-eris.net/stog";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/misc/stretchly/default.nix b/pkgs/applications/misc/stretchly/default.nix
index 95f361669737f..e1591810c5b16 100644
--- a/pkgs/applications/misc/stretchly/default.nix
+++ b/pkgs/applications/misc/stretchly/default.nix
@@ -66,7 +66,7 @@ stdenv.mkDerivation rec {
     categories = "Utility;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A break time reminder app";
     longDescription = ''
       stretchly is a cross-platform electron app that reminds you to take
diff --git a/pkgs/applications/misc/styx/default.nix b/pkgs/applications/misc/styx/default.nix
index 06bf1bd5f2fac..e59f6710737a5 100644
--- a/pkgs/applications/misc/styx/default.nix
+++ b/pkgs/applications/misc/styx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, caddy, asciidoctor
+{ lib, stdenv, fetchFromGitHub, caddy, asciidoctor
 , file, lessc, sass, multimarkdown, linkchecker
 , perlPackages, python27 }:
 
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
     cp -r themes/* $themes
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "Nix based static site generator";
     maintainers  = with maintainers; [ ericsagnes ];
     homepage     = "https://styx-static.github.io/styx-site/";
diff --git a/pkgs/applications/misc/subsurface/default.nix b/pkgs/applications/misc/subsurface/default.nix
index 509f5f55e6dbe..ab3423c47375b 100644
--- a/pkgs/applications/misc/subsurface/default.nix
+++ b/pkgs/applications/misc/subsurface/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, autoreconfHook, cmake, wrapQtAppsHook, pkgconfig, qmake
+{ lib, stdenv, fetchurl, fetchFromGitHub, autoreconfHook, cmake, wrapQtAppsHook, pkgconfig, qmake
 , curl, grantlee, libgit2, libusb-compat-0_1, libssh2, libxml2, libxslt, libzip, zlib
 , qtbase, qtconnectivity, qtlocation, qtsvg, qttools, qtwebkit, libXcomposite
 }:
@@ -27,7 +27,7 @@ let
 
     enableParallelBuilding = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://www.libdivecomputer.org";
       description = "A cross-platform and open source library for communication with dive computers from various manufacturers";
       maintainers = with maintainers; [ mguentner ];
@@ -63,7 +63,7 @@ let
 
     enableParallelBuilding = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       inherit (src.meta) homepage;
       description = "QtLocation plugin for Google maps tile API";
       maintainers = with maintainers; [ orivej ];
@@ -93,7 +93,7 @@ in stdenv.mkDerivation {
 
   passthru = { inherit version libdc googlemaps; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A divelog program";
     longDescription = ''
       Subsurface can track single- and multi-tank dives using air, Nitrox or TriMix.
diff --git a/pkgs/applications/misc/swappy/default.nix b/pkgs/applications/misc/swappy/default.nix
index ddd9b434852db..11798db34f524 100644
--- a/pkgs/applications/misc/swappy/default.nix
+++ b/pkgs/applications/misc/swappy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson
 , ninja
 , wayland
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     "-Dc_args=-I${glib.dev}/include/gio-unix-2.0"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jtheoof/swappy";
     description = "A Wayland native snapshot editing tool, inspired by Snappy on macOS ";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/synapse/default.nix b/pkgs/applications/misc/synapse/default.nix
index 751c0a48f5b37..6f8dd068de80c 100644
--- a/pkgs/applications/misc/synapse/default.nix
+++ b/pkgs/applications/misc/synapse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gettext, pkgconfig, glib, libnotify, gtk3, libgee
+{ lib, stdenv, fetchurl, gettext, pkgconfig, glib, libnotify, gtk3, libgee
 , keybinder3, json-glib, zeitgeist, vala, gobject-introspection
 }:
 
@@ -22,7 +22,7 @@ in stdenv.mkDerivation rec {
     glib libnotify gtk3 libgee keybinder3 json-glib zeitgeist
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     longDescription = ''
       Semantic launcher written in Vala that you can use to start applications
       as well as find and access relevant documents and files by making use of
diff --git a/pkgs/applications/misc/syncthing-tray/default.nix b/pkgs/applications/misc/syncthing-tray/default.nix
index 1cb5bb441ed87..ab57bf7a43023 100644
--- a/pkgs/applications/misc/syncthing-tray/default.nix
+++ b/pkgs/applications/misc/syncthing-tray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage, pkgconfig, libappindicator-gtk3 }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage, pkgconfig, libappindicator-gtk3 }:
 
 buildGoPackage rec {
   pname = "syncthing-tray";
@@ -18,7 +18,7 @@ buildGoPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libappindicator-gtk3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple application tray for syncthing";
     homepage = "https://github.com/alex2108/syncthing-tray";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/systembus-notify/default.nix b/pkgs/applications/misc/systembus-notify/default.nix
index 374adc6c89bfe..6e5405ce988eb 100644
--- a/pkgs/applications/misc/systembus-notify/default.nix
+++ b/pkgs/applications/misc/systembus-notify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, systemd }:
+{ lib, stdenv, fetchFromGitHub, systemd }:
 
 stdenv.mkDerivation rec {
   pname = "systembus-notify";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System bus notification daemon";
     homepage = "https://github.com/rfjakob/systembus-notify";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/tabula/default.nix b/pkgs/applications/misc/tabula/default.nix
index 1b29118c9b14f..1804f3c04e89a 100644
--- a/pkgs/applications/misc/tabula/default.nix
+++ b/pkgs/applications/misc/tabula/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jre, makeWrapper }:
+{ lib, stdenv, fetchzip, jre, makeWrapper }:
 
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for liberating data tables locked inside PDF files";
     longDescription = ''
       If you’ve ever tried to do anything with data provided to you in PDFs, you
diff --git a/pkgs/applications/misc/tasknc/default.nix b/pkgs/applications/misc/tasknc/default.nix
index 9080bec753de8..d24a7d3e0d13f 100644
--- a/pkgs/applications/misc/tasknc/default.nix
+++ b/pkgs/applications/misc/tasknc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, perl, ncurses5, taskwarrior }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, perl, ncurses5, taskwarrior }:
 
 stdenv.mkDerivation rec {
   version = "2020-12-17";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/lharding/tasknc";
     description = "A ncurses wrapper around taskwarrior";
     maintainers = with maintainers; [ matthiasbeyer infinisil ];
diff --git a/pkgs/applications/misc/taskopen/default.nix b/pkgs/applications/misc/taskopen/default.nix
index a60ca997ee033..3632a282f7d7a 100644
--- a/pkgs/applications/misc/taskopen/default.nix
+++ b/pkgs/applications/misc/taskopen/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, makeWrapper, which, perl, perlPackages }:
+{ fetchurl, lib, stdenv, makeWrapper, which, perl, perlPackages }:
 
 stdenv.mkDerivation {
   name = "taskopen-1.1.4";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
          --set PERL5LIB "$PERL5LIB"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Script for taking notes and open urls with taskwarrior";
     homepage = "https://github.com/ValiValpas/taskopen";
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/tasksh/default.nix b/pkgs/applications/misc/tasksh/default.nix
index b7564fd2402df..134d1373ad4be 100644
--- a/pkgs/applications/misc/tasksh/default.nix
+++ b/pkgs/applications/misc/tasksh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, readline }:
+{ lib, stdenv, fetchurl, cmake, readline }:
 
 stdenv.mkDerivation rec {
   pname = "tasksh";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ readline ];
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "REPL for taskwarrior";
     homepage = "http://tasktools.org";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/taskwarrior-tui/default.nix b/pkgs/applications/misc/taskwarrior-tui/default.nix
index 682bc920a0e6f..ae730d597ce78 100644
--- a/pkgs/applications/misc/taskwarrior-tui/default.nix
+++ b/pkgs/applications/misc/taskwarrior-tui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 }:
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "11zpy3whzir9mlbvf0jyscqwj9z44a6s5i1bc2cnxyciqy9b57md";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A terminal user interface for taskwarrior ";
     homepage = "https://github.com/kdheepak/taskwarrior-tui";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/misc/taskwarrior/default.nix b/pkgs/applications/misc/taskwarrior/default.nix
index e18b8d697fd89..b3f26c87c50e0 100644
--- a/pkgs/applications/misc/taskwarrior/default.nix
+++ b/pkgs/applications/misc/taskwarrior/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libuuid, gnutls }:
+{ lib, stdenv, fetchFromGitHub, cmake, libuuid, gnutls }:
 
 stdenv.mkDerivation rec {
   pname = "taskwarrior";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     ln -s "../../../share/doc/task/scripts/zsh/_task" "$out/share/zsh/site-functions/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Highly flexible command-line tool to manage TODO lists";
     homepage = "https://taskwarrior.org";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/tdrop/default.nix b/pkgs/applications/misc/tdrop/default.nix
index f9e2ea34b39e8..e8c42ab48d704 100644
--- a/pkgs/applications/misc/tdrop/default.nix
+++ b/pkgs/applications/misc/tdrop/default.nix
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
 
   nativeBuildInputs = [ makeWrapper ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Glorified WM-Independent Dropdown Creator";
     homepage = "https://github.com/noctuid/tdrop";
     license = licenses.bsd2;
diff --git a/pkgs/applications/misc/termdown/default.nix b/pkgs/applications/misc/termdown/default.nix
index ad6f9e9382b77..d8bb03138f323 100644
--- a/pkgs/applications/misc/termdown/default.nix
+++ b/pkgs/applications/misc/termdown/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonApplication
 , click
@@ -20,7 +20,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ dateutil click pyfiglet setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Starts a countdown to or from TIMESPEC";
     longDescription = "Countdown timer and stopwatch in your terminal";
     homepage = "https://github.com/trehn/termdown";
diff --git a/pkgs/applications/misc/terminal-parrot/default.nix b/pkgs/applications/misc/terminal-parrot/default.nix
index 52116a52fbb7e..e3e64cfd68aff 100644
--- a/pkgs/applications/misc/terminal-parrot/default.nix
+++ b/pkgs/applications/misc/terminal-parrot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "terminal-parrot";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shows colorful, animated party parrot in your terminial";
     homepage = "https://github.com/jmhobbs/terminal-parrot";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/terminal-typeracer/default.nix b/pkgs/applications/misc/terminal-typeracer/default.nix
index bfa84ebbb6c0a..9b7adac9a2a96 100644
--- a/pkgs/applications/misc/terminal-typeracer/default.nix
+++ b/pkgs/applications/misc/terminal-typeracer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , rustPlatform
 , pkg-config
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
   buildInputs = [ openssl sqlite ] ++ stdenv.lib.optionals stdenv.isDarwin [ libiconv Security ];
   nativeBuildInputs = [ pkg-config ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source terminal based version of Typeracer written in rust";
     homepage = "https://gitlab.com/ttyperacer/terminal-typeracer";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/termpdf.py/default.nix b/pkgs/applications/misc/termpdf.py/default.nix
index 5988f569109b0..2541a17fc201a 100644
--- a/pkgs/applications/misc/termpdf.py/default.nix
+++ b/pkgs/applications/misc/termpdf.py/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonApplication
 , fetchFromGitHub
 , fetchPypi
@@ -39,7 +39,7 @@ buildPythonApplication {
   # upstream doesn't contain tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A graphical pdf (and epub, cbz, ...) reader that works
       inside the kitty terminal.
diff --git a/pkgs/applications/misc/thinking-rock/default.nix b/pkgs/applications/misc/thinking-rock/default.nix
index 2b5c9da4b17ae..3bf3dda7ca4d9 100644
--- a/pkgs/applications/misc/thinking-rock/default.nix
+++ b/pkgs/applications/misc/thinking-rock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, runtimeShell }:
+{ lib, stdenv, fetchurl, runtimeShell }:
 
 stdenv.mkDerivation {
   name = "thinkingrock-binary-2.2.1";
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
 
   installPhase = ":";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Task management system";
     homepage = "http://www.thinkingrock.com.au/";
     license = licenses.cddl;
diff --git a/pkgs/applications/misc/tickrs/default.nix b/pkgs/applications/misc/tickrs/default.nix
index 754de71f1ae70..ced50748d0f79 100644
--- a/pkgs/applications/misc/tickrs/default.nix
+++ b/pkgs/applications/misc/tickrs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, perl }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, perl }:
 
 rustPlatform.buildRustPackage rec {
   pname = "tickrs";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   nativeBuildInputs = [ perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Realtime ticker data in your terminal";
     homepage = "https://github.com/tarkah/tickrs";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/timewarrior/default.nix b/pkgs/applications/misc/timewarrior/default.nix
index 380f1d437f118..41dc179efe09f 100644
--- a/pkgs/applications/misc/timewarrior/default.nix
+++ b/pkgs/applications/misc/timewarrior/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "timewarrior";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line time tracker";
     homepage = "https://timewarrior.net";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/tint2/default.nix b/pkgs/applications/misc/tint2/default.nix
index 326dd3c0d92a1..c78fe9afeda47 100644
--- a/pkgs/applications/misc/tint2/default.nix
+++ b/pkgs/applications/misc/tint2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , pkg-config
 , cmake
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/o9000/tint2";
     description = "Simple panel/taskbar unintrusive and light (memory, cpu, aestetic)";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/tipp10/default.nix b/pkgs/applications/misc/tipp10/default.nix
index 689c5aa3a9ef6..0658b43626ed3 100644
--- a/pkgs/applications/misc/tipp10/default.nix
+++ b/pkgs/applications/misc/tipp10/default.nix
@@ -1,4 +1,4 @@
-{ cmake, stdenv, mkDerivation, fetchFromGitLab,
+{ cmake, lib, stdenv, mkDerivation, fetchFromGitLab,
   qtmultimedia, qttools, ... }:
 
 mkDerivation rec {
@@ -15,7 +15,7 @@ mkDerivation rec {
   nativeBuildInputs = [ cmake qttools ];
   buildInputs = [ qtmultimedia ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Learn and train typing with the ten-finger system";
     homepage = "https://gitlab.com/a_a/tipp10";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/tippecanoe/default.nix b/pkgs/applications/misc/tippecanoe/default.nix
index 455876a772b4a..9aeb726e5c2ce 100644
--- a/pkgs/applications/misc/tippecanoe/default.nix
+++ b/pkgs/applications/misc/tippecanoe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, sqlite, zlib, perl }:
+{ lib, stdenv, fetchFromGitHub, sqlite, zlib, perl }:
 
 stdenv.mkDerivation rec {
   pname = "tippecanoe";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   enableParallelBuilding = true;
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Build vector tilesets from large collections of GeoJSON features";
     homepage = "https://github.com/mapbox/tippecanoe";
     license = licenses.bsd2;
diff --git a/pkgs/applications/misc/tiramisu/default.nix b/pkgs/applications/misc/tiramisu/default.nix
index e5cc9a1c17830..79286ff10c3cd 100644
--- a/pkgs/applications/misc/tiramisu/default.nix
+++ b/pkgs/applications/misc/tiramisu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, glib }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, glib }:
 
 stdenv.mkDerivation rec {
   pname = "tiramisu";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop notifications, the UNIX way";
     longDescription = ''
     tiramisu is a notification daemon based on dunst that outputs notifications
diff --git a/pkgs/applications/misc/tiv/default.nix b/pkgs/applications/misc/tiv/default.nix
index 3790a9fdd0694..1ee176166ea4c 100644
--- a/pkgs/applications/misc/tiv/default.nix
+++ b/pkgs/applications/misc/tiv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, imagemagick }:
+{ lib, stdenv, fetchFromGitHub, imagemagick }:
 
 stdenv.mkDerivation rec {
   pname = "tiv";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "cd src/main/cpp";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/stefanhaustein/TerminalImageViewer";
     description = "Small C++ program to display images in a (modern) terminal using RGB ANSI codes and unicode block graphics characters";
     license = licenses.asl20;
diff --git a/pkgs/applications/misc/tnef/default.nix b/pkgs/applications/misc/tnef/default.nix
index 40505c4fdbea4..65e07915c760d 100644
--- a/pkgs/applications/misc/tnef/default.nix
+++ b/pkgs/applications/misc/tnef/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   version = "1.4.18";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unpacks MIME attachments of type application/ms-tnef";
     longDescription = ''
       TNEF is a program for unpacking MIME attachments of type "application/ms-tnef". This is a Microsoft only attachment.
diff --git a/pkgs/applications/misc/todiff/default.nix b/pkgs/applications/misc/todiff/default.nix
index 431f922eeeec6..bc172c9b49fbb 100644
--- a/pkgs/applications/misc/todiff/default.nix
+++ b/pkgs/applications/misc/todiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "todiff";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   checkPhase = "cargo test --features=integration_tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Human-readable diff for todo.txt files";
     homepage = "https://github.com/Ekleog/todiff";
     maintainers = with maintainers; [ ekleog ];
diff --git a/pkgs/applications/misc/todolist/default.nix b/pkgs/applications/misc/todolist/default.nix
index 669c06a9480eb..e678da0a43607 100644
--- a/pkgs/applications/misc/todolist/default.nix
+++ b/pkgs/applications/misc/todolist/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "todolist";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "0dazfymby5xm4482p9cyj23djmkz5q7g79cqm2d85mczvz7vks8p";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple GTD-style todo list for the command line";
     homepage = "http://todolist.site";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/tomboy/default.nix b/pkgs/applications/misc/tomboy/default.nix
index ff4faf139e6cd..b87d52fa62865 100644
--- a/pkgs/applications/misc/tomboy/default.nix
+++ b/pkgs/applications/misc/tomboy/default.nix
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
       --prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ glib gtk-sharp-2_0 gtk-sharp-2_0.gtk gnome2.GConf ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Tomboy";
     description = "A simple note-taking application with synchronization";
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/toot/default.nix b/pkgs/applications/misc/toot/default.nix
index f46af56ed45ff..d992d9cdc410c 100644
--- a/pkgs/applications/misc/toot/default.nix
+++ b/pkgs/applications/misc/toot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   version = "0.27.0";
@@ -20,7 +20,7 @@ python3Packages.buildPythonApplication rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mastodon CLI interface";
     homepage    = "https://github.com/ihabunek/toot";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/misc/tootle/default.nix b/pkgs/applications/misc/tootle/default.nix
index 9c6008b79349c..70568f92383fb 100644
--- a/pkgs/applications/misc/tootle/default.nix
+++ b/pkgs/applications/misc/tootle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple Mastodon client designed for elementary OS";
     homepage = "https://github.com/bleakgrey/tootle";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/topydo/default.nix b/pkgs/applications/misc/topydo/default.nix
index 6db651ff39297..4ff3090d1f853 100644
--- a/pkgs/applications/misc/topydo/default.nix
+++ b/pkgs/applications/misc/topydo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, glibcLocales }:
+{ lib, stdenv, python3Packages, fetchFromGitHub, glibcLocales }:
 
 with python3Packages;
 
@@ -33,7 +33,7 @@ buildPythonApplication rec {
 
   LC_ALL="en_US.UTF-8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cli todo application compatible with the todo.txt format";
     homepage = "https://github.com/bram85/topydo";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/translate-shell/default.nix b/pkgs/applications/misc/translate-shell/default.nix
index 62e66055a2f94..94dc46560270c 100644
--- a/pkgs/applications/misc/translate-shell/default.nix
+++ b/pkgs/applications/misc/translate-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, curl, fribidi, rlwrap, gawk, groff, ncurses }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, curl, fribidi, rlwrap, gawk, groff, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "translate-shell";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
       ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.soimort.org/translate-shell";
     description = "Command-line translator using Google Translate, Bing Translator, Yandex.Translate, and Apertium";
     license = licenses.unlicense;
diff --git a/pkgs/applications/misc/tthsum/default.nix b/pkgs/applications/misc/tthsum/default.nix
index 792b80d04629e..7db743559a4e5 100644
--- a/pkgs/applications/misc/tthsum/default.nix
+++ b/pkgs/applications/misc/tthsum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "tthsum";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An md5sum-alike program that works with Tiger/THEX hashes";
     longDescription = ''
       tthsum generates or checks TTH checksums (root of the THEX hash
diff --git a/pkgs/applications/misc/tty-share/default.nix b/pkgs/applications/misc/tty-share/default.nix
index a9fcb969f675e..be9a0bafcc625 100644
--- a/pkgs/applications/misc/tty-share/default.nix
+++ b/pkgs/applications/misc/tty-share/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 # Upstream has a `./vendor` directory with all deps which we rely upon.
 buildGoPackage rec {
@@ -14,7 +14,7 @@ buildGoPackage rec {
 
   goPackagePath = "github.com/elisescu/tty-share";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tty-share.com";
     description = "Share terminal via browser for remote work or shared sessions";
     platforms = platforms.linux;
diff --git a/pkgs/applications/misc/tty-solitaire/default.nix b/pkgs/applications/misc/tty-solitaire/default.nix
index 00e6efb713e5e..9b2fcf3d17a1e 100644
--- a/pkgs/applications/misc/tty-solitaire/default.nix
+++ b/pkgs/applications/misc/tty-solitaire/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "tty-solitaire";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "CC=cc" "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Klondike Solitaire in your ncurses terminal";
     license = licenses.mit;
     homepage = "https://github.com/mpereira/tty-solitaire";
diff --git a/pkgs/applications/misc/tut/default.nix b/pkgs/applications/misc/tut/default.nix
index d65e894417e61..1fa3e9b7883a6 100644
--- a/pkgs/applications/misc/tut/default.nix
+++ b/pkgs/applications/misc/tut/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "tut";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "1l7lc6cjx97v9zhc0b6lfzqjmyv1i3qj83drkck36if3mc60vvwi";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A TUI for Mastodon with vim inspired keys";
     homepage = "https://github.com/RasmusLindroth/tut";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/tvbrowser/bin.nix b/pkgs/applications/misc/tvbrowser/bin.nix
index 68d25e4e3de7a..fa08b5f555a76 100644
--- a/pkgs/applications/misc/tvbrowser/bin.nix
+++ b/pkgs/applications/misc/tvbrowser/bin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre, makeDesktopItem }:
+{ lib, stdenv, fetchurl, makeWrapper, jre, makeDesktopItem }:
 
 let
   desktopItem = makeDesktopItem {
@@ -46,7 +46,7 @@ in stdenv.mkDerivation rec {
       --run "cd $out/share/java/${pname}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Electronic TV Program Guide";
     homepage = "https://www.tvbrowser.org/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/tzupdate/default.nix b/pkgs/applications/misc/tzupdate/default.nix
index 8a18948da2446..3873f8d248ebd 100644
--- a/pkgs/applications/misc/tzupdate/default.nix
+++ b/pkgs/applications/misc/tzupdate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3 }:
+{ lib, stdenv, python3 }:
 
 let
   inherit (python3.pkgs) buildPythonApplication fetchPypi requests;
@@ -14,7 +14,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Update timezone information based on geoip";
     homepage = "https://github.com/cdown/tzupdate";
     maintainers = [ maintainers.michaelpj ];
diff --git a/pkgs/applications/misc/udiskie/default.nix b/pkgs/applications/misc/udiskie/default.nix
index a6efc492d8a3a..e2178850da1c5 100644
--- a/pkgs/applications/misc/udiskie/default.nix
+++ b/pkgs/applications/misc/udiskie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, asciidoc-full, gettext
+{ lib, stdenv, fetchFromGitHub, asciidoc-full, gettext
 , gobject-introspection, gtk3, libappindicator-gtk3, libnotify, librsvg
 , udisks2, wrapGAppsHook
 , python3Packages
@@ -53,7 +53,7 @@ python3Packages.buildPythonApplication rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Removable disk automounter for udisks";
     license = licenses.mit;
     homepage = "https://github.com/coldfix/udiskie";
diff --git a/pkgs/applications/misc/ulauncher/default.nix b/pkgs/applications/misc/ulauncher/default.nix
index d2522360a7532..117d9dc6aa7b4 100644
--- a/pkgs/applications/misc/ulauncher/default.nix
+++ b/pkgs/applications/misc/ulauncher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , nix-update-script
 , python3Packages
@@ -110,7 +110,7 @@ python3Packages.buildPythonApplication rec {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast application launcher for Linux, written in Python, using GTK";
     homepage = "https://ulauncher.io/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/upwork/default.nix b/pkgs/applications/misc/upwork/default.nix
index 18c2bc129ccc0..136c4c2745a8d 100644
--- a/pkgs/applications/misc/upwork/default.nix
+++ b/pkgs/applications/misc/upwork/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg, wrapGAppsHook, autoPatchelfHook, writeShellScript
+{ lib, stdenv, fetchurl, dpkg, wrapGAppsHook, autoPatchelfHook, writeShellScript
 , alsaLib, atk, at-spi2-atk, at-spi2-core, cairo, cups, dbus, expat, fontconfig, freetype
 , gdk-pixbuf, glib, gtk3, libnotify, libX11, libXcomposite, libXcursor, libXdamage, libuuid
 , libXext, libXfixes, libXi, libXrandr, libXrender, libXtst, nspr, nss, libxcb
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : ${libPath}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Online freelancing platform desktop application for time tracking";
     homepage = "https://www.upwork.com/ab/downloads/";
     license = licenses.unfree;
diff --git a/pkgs/applications/misc/urlscan/default.nix b/pkgs/applications/misc/urlscan/default.nix
index c5edd9133b7d5..3e97088371aca 100644
--- a/pkgs/applications/misc/urlscan/default.nix
+++ b/pkgs/applications/misc/urlscan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 python3Packages.buildPythonApplication rec {
   pname = "urlscan";
@@ -15,7 +15,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false; # No tests available
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mutt and terminal url selector (similar to urlview)";
     homepage = "https://github.com/firecat53/urlscan";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/urlview/default.nix b/pkgs/applications/misc/urlview/default.nix
index 6430a1bc7196b..0374fb91844d9 100644
--- a/pkgs/applications/misc/urlview/default.nix
+++ b/pkgs/applications/misc/urlview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, autoreconfHook }:
+{ lib, stdenv, fetchurl, ncurses, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   version    = "0.9";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     patchShebangs $out/etc/urlview
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extract URLs from text";
     homepage = "https://packages.qa.debian.org/u/urlview.html";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/usync/default.nix b/pkgs/applications/misc/usync/default.nix
index 9234d8ad202aa..8ab2a485a6491 100644
--- a/pkgs/applications/misc/usync/default.nix
+++ b/pkgs/applications/misc/usync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, scsh, rsync, unison }:
+{ lib, stdenv, fetchFromGitHub, scsh, rsync, unison }:
 
 stdenv.mkDerivation rec {
   pname = "usync";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/bin/$pname --replace "(unison " "(${unison}/bin/unison "
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ebzzry/usync";
     description = "A simple site-to-site synchronization tool";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/verbiste/default.nix b/pkgs/applications/misc/verbiste/default.nix
index a322756c157f0..be354d60dc423 100644
--- a/pkgs/applications/misc/verbiste/default.nix
+++ b/pkgs/applications/misc/verbiste/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libgnomeui, libxml2 }:
+{ lib, stdenv, fetchurl, pkgconfig, libgnomeui, libxml2 }:
 
 stdenv.mkDerivation rec {
   pname = "verbiste";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://sarrazip.com/dev/verbiste.html";
     description = "French and Italian verb conjugator";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/vifm/default.nix b/pkgs/applications/misc/vifm/default.nix
index 2c388e58fe11d..64f0f6b7f5f76 100644
--- a/pkgs/applications/misc/vifm/default.nix
+++ b/pkgs/applications/misc/vifm/default.nix
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
     ${if mediaSupport then wrapVifmMedia else ""}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''A vi-like file manager${if isFullPackage then "; Includes support for optional features" else ""}'';
     maintainers = with maintainers; [ raskin ];
     platforms = if mediaSupport then platforms.linux else platforms.unix;
diff --git a/pkgs/applications/misc/viking/default.nix b/pkgs/applications/misc/viking/default.nix
index 03d3256e375a6..4e002d92ec5ed 100644
--- a/pkgs/applications/misc/viking/default.nix
+++ b/pkgs/applications/misc/viking/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, fetchpatch, stdenv, makeWrapper
+{ fetchurl, fetchpatch, lib, stdenv, makeWrapper
 , pkgconfig, intltool, gettext, gtk2, expat, curl
 , gpsd, bc, file, gnome-doc-utils, libexif, libxml2, libxslt, scrollkeeper
 , docbook_xml_dtd_412, gexiv2, gpsbabel, expect
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${expect}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GPS data editor and analyzer";
     longDescription = ''
       Viking is a free/open source program to manage GPS data.  You
diff --git a/pkgs/applications/misc/volnoti/default.nix b/pkgs/applications/misc/volnoti/default.nix
index 845bdae6bec78..c565bfe0ce3ae 100644
--- a/pkgs/applications/misc/volnoti/default.nix
+++ b/pkgs/applications/misc/volnoti/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , pkgconfig, dbus, gdk-pixbuf, glib, libX11, gtk2, librsvg
 , dbus-glib, autoreconfHook, wrapGAppsHook }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
     dbus gdk-pixbuf glib libX11 gtk2 dbus-glib librsvg
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight volume notification for Linux";
     homepage = "https://github.com/davidbrazdil/volnoti";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/vp/default.nix b/pkgs/applications/misc/vp/default.nix
index 8bebed45fc416..d133331a0a7b9 100644
--- a/pkgs/applications/misc/vp/default.nix
+++ b/pkgs/applications/misc/vp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, SDL, SDL_image }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, SDL, SDL_image }:
 
 stdenv.mkDerivation rec {
   pname = "vp";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE="-I${SDL}/include/SDL -I${SDL_image}/include/SDL";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://brlcad.org/~erik/";
     description = "SDL based picture viewer/slideshow";
     platforms = platforms.unix;
diff --git a/pkgs/applications/misc/vym/default.nix b/pkgs/applications/misc/vym/default.nix
index ce45471c2f022..d198a15c25269 100644
--- a/pkgs/applications/misc/vym/default.nix
+++ b/pkgs/applications/misc/vym/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, pkgconfig, qmake, qtscript, qtsvg }:
+{ lib, stdenv, mkDerivation, fetchurl, pkgconfig, qmake, qtscript, qtsvg }:
 
 mkDerivation rec {
   pname = "vym";
@@ -41,7 +41,7 @@ mkDerivation rec {
 
   dontGzipMan = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A mind-mapping software";
     longDescription = ''
       VYM (View Your Mind) is a tool to generate and manipulate maps which show your thoughts.
diff --git a/pkgs/applications/misc/waybar/default.nix b/pkgs/applications/misc/waybar/default.nix
index 11a4b1a51aada..3bb96d7a75760 100644
--- a/pkgs/applications/misc/waybar/default.nix
+++ b/pkgs/applications/misc/waybar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, pkgconfig, ninja, wrapGAppsHook
+{ lib, stdenv, fetchFromGitHub, meson, pkgconfig, ninja, wrapGAppsHook
 , wayland, wlroots, gtkmm3, libsigcxx, jsoncpp, fmt, scdoc, spdlog, gtk-layer-shell
 , howard-hinnant-date, cmake
 , traySupport  ? true,  libdbusmenu-gtk3
@@ -61,7 +61,7 @@
         --prefix PYTHONPATH : "$PYTHONPATH:$out/${python3.sitePackages}"
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Highly customizable Wayland bar for Sway and Wlroots based compositors";
       license = licenses.mit;
       maintainers = with maintainers; [ FlorianFranzen minijackson synthetica ];
diff --git a/pkgs/applications/misc/wcalc/default.nix b/pkgs/applications/misc/wcalc/default.nix
index 94c56ba5439c2..7541b759e06c3 100644
--- a/pkgs/applications/misc/wcalc/default.nix
+++ b/pkgs/applications/misc/wcalc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mpfr, readline }:
+{ lib, stdenv, fetchurl, mpfr, readline }:
 
 stdenv.mkDerivation rec {
   pname = "wcalc";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ mpfr readline ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line calculator";
     homepage = "http://w-calc.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/weather/default.nix b/pkgs/applications/misc/weather/default.nix
index 7894bc2f5e4c6..bd5a117f0f43e 100644
--- a/pkgs/applications/misc/weather/default.nix
+++ b/pkgs/applications/misc/weather/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages, installShellFiles }:
+{ lib, stdenv, fetchurl, pythonPackages, installShellFiles }:
 
 stdenv.mkDerivation rec {
   version = "2.4.1";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     installManPage weather.1 weatherrc.5
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fungi.yuggoth.org/weather";
     description = "Quick access to current weather conditions and forecasts";
     license = licenses.isc;
diff --git a/pkgs/applications/misc/web-media-controller/default.nix b/pkgs/applications/misc/web-media-controller/default.nix
index b2a3394f8aecb..ccd1e22990223 100644
--- a/pkgs/applications/misc/web-media-controller/default.nix
+++ b/pkgs/applications/misc/web-media-controller/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, glib, pcre, json-glib }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, glib, pcre, json-glib }:
 
 stdenv.mkDerivation rec {
   pname = "wmc-mpris";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "-DFIREFOX_MANIFEST_DESTINATION=${placeholder "out"}/lib/mozilla/native-messaging-hosts"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/f1u77y/wmc-mpris";
     description = "MPRIS proxy for usage with 'Web Media Controller' web extension";
     license = licenses.unlicense;
diff --git a/pkgs/applications/misc/worker/default.nix b/pkgs/applications/misc/worker/default.nix
index b19b1b86cf57f..12ac72b6021ab 100644
--- a/pkgs/applications/misc/worker/default.nix
+++ b/pkgs/applications/misc/worker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libX11, fetchurl }:
+{ lib, stdenv, libX11, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "worker";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libX11 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A two-pane file manager with advanced file manipulation features";
     homepage = "http://www.boomerangsworld.de/cms/worker/index.html";
     license =  licenses.gpl2;
diff --git a/pkgs/applications/misc/workrave/default.nix b/pkgs/applications/misc/workrave/default.nix
index b0020b64ededa..aa769e7d8ee3a 100644
--- a/pkgs/applications/misc/workrave/default.nix
+++ b/pkgs/applications/misc/workrave/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, wrapGAppsHook
+{ lib, stdenv, fetchFromGitHub, wrapGAppsHook
 , autoconf, autoconf-archive, automake, gettext, intltool, libtool, pkgconfig
 , libICE, libSM, libXScrnSaver, libXtst, cheetah
 , gobject-introspection, glib, glibmm, gtkmm3, atk, pango, pangomm, cairo
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program to help prevent Repetitive Strain Injury";
     longDescription = ''
       Workrave is a program that assists in the recovery and prevention of
diff --git a/pkgs/applications/misc/xastir/default.nix b/pkgs/applications/misc/xastir/default.nix
index 84e4eee2bddc1..63240e0402fe5 100644
--- a/pkgs/applications/misc/xastir/default.nix
+++ b/pkgs/applications/misc/xastir/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, autoreconfHook
 , curl, db, libgeotiff
 , libXpm, libXt, motif, pcre
 , perl, proj, rastermagick, shapelib
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   postPatch = "patchShebangs .";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical APRS client";
     homepage = "https://xastir.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/xautoclick/default.nix b/pkgs/applications/misc/xautoclick/default.nix
index f259b28131db6..641d3b4e20cd2 100644
--- a/pkgs/applications/misc/xautoclick/default.nix
+++ b/pkgs/applications/misc/xautoclick/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, pkg-config
+{ lib, stdenv, fetchFromGitHub, xorg, pkg-config
 , cmake, libevdev
 , gtkSupport ? true, gtk3, pcre, glib, wrapGAppsHook
 , fltkSupport ? true, fltk
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     ++ stdenv.lib.optionals fltkSupport [ fltk ]
     ++ stdenv.lib.optionals qtSupport [ qt5.qtbase qt5.wrapQtAppsHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Autoclicker application, which enables you to automatically click the left mousebutton";
     homepage = "https://github.com/qarkai/xautoclick";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/xbattbar/default.nix b/pkgs/applications/misc/xbattbar/default.nix
index 0864e24f8c9dc..93f5d1c2279c0 100644
--- a/pkgs/applications/misc/xbattbar/default.nix
+++ b/pkgs/applications/misc/xbattbar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, libX11, perl, ... }:
+{ lib, stdenv, fetchgit, libX11, perl, ... }:
 
 stdenv.mkDerivation rec {
   pname = "xbattbar";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     install -m 0755 xbattbar-check-sys $out/libexec/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display battery status in X11";
     homepage = "https://salsa.debian.org/debian/xbattbar";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/xchm/default.nix b/pkgs/applications/misc/xchm/default.nix
index fb1b59ed01fa3..f3764ce60f3f7 100644
--- a/pkgs/applications/misc/xchm/default.nix
+++ b/pkgs/applications/misc/xchm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, wxGTK30, chmlib }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, wxGTK30, chmlib }:
 
 stdenv.mkDerivation rec {
   pname = "xchm";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     export LDFLAGS="$LDFLAGS $(${wxGTK30}/bin/wx-config --libs | sed -e s@-pthread@@) -lwx_gtk2u_aui-3.0"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A viewer for Microsoft HTML Help files";
     homepage = "https://github.com/rzvncj/xCHM";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/xcruiser/default.nix b/pkgs/applications/misc/xcruiser/default.nix
index 80a1ced563f8b..2e4771563a04c 100644
--- a/pkgs/applications/misc/xcruiser/default.nix
+++ b/pkgs/applications/misc/xcruiser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gccmakedep, imake, libXt, libXaw, libXpm, libXext }:
+{ lib, stdenv, fetchurl, gccmakedep, imake, libXt, libXaw, libXpm, libXext }:
 
 stdenv.mkDerivation {
   name = "xcruiser-0.30";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     "XAPPLOADDIR=$(out)/etc/X11/app-defaults"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Filesystem visualization utility";
     longDescription = ''
       XCruiser, formerly known as XCruise, is a filesystem visualization utility.
diff --git a/pkgs/applications/misc/xdgmenumaker/default.nix b/pkgs/applications/misc/xdgmenumaker/default.nix
index b4d821e1deb11..c1af7ae373c63 100644
--- a/pkgs/applications/misc/xdgmenumaker/default.nix
+++ b/pkgs/applications/misc/xdgmenumaker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, txt2tags, python3Packages, glib, gobject-introspection, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, txt2tags, python3Packages, glib, gobject-introspection, wrapGAppsHook }:
 
 python3Packages.buildPythonApplication rec {
   pname = "xdgmenumaker";
@@ -38,7 +38,7 @@ python3Packages.buildPythonApplication rec {
     "DESTDIR="
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tool that generates XDG menus for several window managers";
     homepage = "https://github.com/gapan/xdgmenumaker";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/xdragon/default.nix b/pkgs/applications/misc/xdragon/default.nix
index 74f1f755ec8a0..39f291a884937 100644
--- a/pkgs/applications/misc/xdragon/default.nix
+++ b/pkgs/applications/misc/xdragon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, gtk3 }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, gtk3 }:
 
 stdenv.mkDerivation rec {
   pname = "xdragon";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     ln -s $out/bin/dragon $out/bin/xdragon
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple drag-and-drop source/sink for X (called dragon in upstream)";
     homepage = "https://github.com/mwh/dragon";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/xiphos/default.nix b/pkgs/applications/misc/xiphos/default.nix
index a51cc18bc7407..efdd7f2b0f15d 100644
--- a/pkgs/applications/misc/xiphos/default.nix
+++ b/pkgs/applications/misc/xiphos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig
+{ lib, stdenv, fetchFromGitHub, pkgconfig
 , python
 , intltool
 , docbook2x, docbook_xml_dtd_412, libxslt
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
 
   wafConfigureFlags = [ "--enable-webkit2" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GTK Bible study tool";
     longDescription = ''
       Xiphos (formerly known as GnomeSword) is a Bible study tool
diff --git a/pkgs/applications/misc/xkbd/default.nix b/pkgs/applications/misc/xkbd/default.nix
index cbca2a33d59eb..173ea71fe4075 100644
--- a/pkgs/applications/misc/xkbd/default.nix
+++ b/pkgs/applications/misc/xkbd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, freetype, libXrender, libXft, xorgproto
+{ lib, stdenv, fetchFromGitHub, freetype, libXrender, libXft, xorgproto
 , xinput, libXi, libXext, libXtst, libXpm, libX11, autoreconfHook
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mahatma-kaganovich/xkbd";
     description = "onscreen soft keyboard for X11";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/xkblayout-state/default.nix b/pkgs/applications/misc/xkblayout-state/default.nix
index 296d6f38db64a..4d1dd54bba6c4 100644
--- a/pkgs/applications/misc/xkblayout-state/default.nix
+++ b/pkgs/applications/misc/xkblayout-state/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qt4 }:
+{ lib, stdenv, fetchurl, qt4 }:
 
 stdenv.mkDerivation rec {
   pname = "xkblayout-state";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp xkblayout-state $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small command-line program to get/set the current XKB keyboard layout";
     homepage = "https://github.com/nonpop/xkblayout-state";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/xkbmon/default.nix b/pkgs/applications/misc/xkbmon/default.nix
index 1e6384c7d5763..cd7037872cb73 100644
--- a/pkgs/applications/misc/xkbmon/default.nix
+++ b/pkgs/applications/misc/xkbmon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11 }:
+{ lib, stdenv, fetchFromGitHub, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "xkbmon";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "install -D -t $out/bin xkbmon";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/xkbmon/xkbmon";
     description = "Command-line keyboard layout monitor for X11";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/xmenu/default.nix b/pkgs/applications/misc/xmenu/default.nix
index e84f95e09981c..f29bfcb55fe15 100644
--- a/pkgs/applications/misc/xmenu/default.nix
+++ b/pkgs/applications/misc/xmenu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, imlib2, libX11, libXft, libXinerama }:
+{ lib, stdenv, fetchFromGitHub, imlib2, libX11, libXft, libXinerama }:
 
 stdenv.mkDerivation rec {
   pname = "xmenu";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   postPatch = "sed -i \"s:/usr/local:$out:\" config.mk";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A menu utility for X";
     homepage = "https://github.com/phillbush/xmenu";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/xmind/default.nix b/pkgs/applications/misc/xmind/default.nix
index 3e729af71fe53..7629b42c877f8 100644
--- a/pkgs/applications/misc/xmind/default.nix
+++ b/pkgs/applications/misc/xmind/default.nix
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
     ln -s ${jre} $out/libexec/jre
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mind-mapping software";
     longDescription = ''
       XMind is a mind mapping and brainstorming software. In addition
diff --git a/pkgs/applications/misc/xneur/default.nix b/pkgs/applications/misc/xneur/default.nix
index e75055e92b804..9c3795ef394d8 100644
--- a/pkgs/applications/misc/xneur/default.nix
+++ b/pkgs/applications/misc/xneur/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, xorg, pcre, gst_all_1, glib
+{ lib, stdenv, fetchurl, pkgconfig, intltool, xorg, pcre, gst_all_1, glib
 , xosd, libnotify, enchant, wrapGAppsHook, gdk-pixbuf }:
 
 stdenv.mkDerivation {
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     sed -e 's@for xosd_dir in@for xosd_dir in ${xosd} @' -i configure
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for switching between keyboard layouts";
     homepage = "https://xneur.ru";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/misc/xpad/default.nix b/pkgs/applications/misc/xpad/default.nix
index 8944011a8d730..acb1cbf90e364 100644
--- a/pkgs/applications/misc/xpad/default.nix
+++ b/pkgs/applications/misc/xpad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , autoreconfHook, pkgconfig, wrapGAppsHook
 , glib, intltool, gtk3, gtksourceview }:
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ glib intltool gtk3 gtksourceview ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A sticky note application for jotting down things to remember";
     homepage = "https://launchpad.net/xpad";
     license = licenses.gpl3;
diff --git a/pkgs/applications/misc/xpdf/default.nix b/pkgs/applications/misc/xpdf/default.nix
index f5ec9b71503e8..a6fadcf9d2fd2 100644
--- a/pkgs/applications/misc/xpdf/default.nix
+++ b/pkgs/applications/misc/xpdf/default.nix
@@ -1,7 +1,7 @@
 { enableGUI ? true
 , enablePDFtoPPM ? true
 , enablePrinting ? true
-, stdenv, fetchzip, cmake, makeDesktopItem
+, lib, stdenv, fetchzip, cmake, makeDesktopItem
 , zlib, libpng, cups ? null, freetype ? null
 , qtbase ? null, qtsvg ? null, wrapQtAppsHook
 }:
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     install -Dm644 $src/xpdf-qt/xpdf-icon.svg $out/share/pixmaps/xpdf.svg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.xpdfreader.com";
     description = "Viewer for Portable Document Format (PDF) files";
     longDescription = ''
diff --git a/pkgs/applications/misc/xpdf/libxpdf.nix b/pkgs/applications/misc/xpdf/libxpdf.nix
index 7b7d9051ada3a..342c00aa12e37 100644
--- a/pkgs/applications/misc/xpdf/libxpdf.nix
+++ b/pkgs/applications/misc/xpdf/libxpdf.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 }:
 
 stdenv.mkDerivation {
@@ -46,7 +46,7 @@ stdenv.mkDerivation {
     cp -v xpdf/*.h $out/include
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.unix;
     license = licenses.gpl2;
   };
diff --git a/pkgs/applications/misc/xrandr-invert-colors/default.nix b/pkgs/applications/misc/xrandr-invert-colors/default.nix
index dabdad137af37..0d5fbc336ae49 100644
--- a/pkgs/applications/misc/xrandr-invert-colors/default.nix
+++ b/pkgs/applications/misc/xrandr-invert-colors/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, libXrandr}:
+{ fetchurl, lib, stdenv, libXrandr}:
 
 stdenv.mkDerivation rec {
   version = "0.01";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     install xrandr-invert-colors $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Inverts the colors of your screen";
     license = stdenv.lib.licenses.gpl3Plus;
     homepage = "https://github.com/zoltanp/xrandr-invert-colors";
diff --git a/pkgs/applications/misc/xscope/default.nix b/pkgs/applications/misc/xscope/default.nix
index 4db034476c7af..d2cc2bf7ad1c5 100644
--- a/pkgs/applications/misc/xscope/default.nix
+++ b/pkgs/applications/misc/xscope/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libXt }:
+{ lib, stdenv, fetchurl, pkgconfig, libXt }:
 
 stdenv.mkDerivation rec {
   pname = "xscope";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libXt ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "program to monitor X11/Client conversations";
     homepage = "https://cgit.freedesktop.org/xorg/app/xscope/";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/misc/xsw/default.nix b/pkgs/applications/misc/xsw/default.nix
index c7c10254c0ca0..d20489d37f3ea 100644
--- a/pkgs/applications/misc/xsw/default.nix
+++ b/pkgs/applications/misc/xsw/default.nix
@@ -24,7 +24,7 @@ in stdenv.mkDerivation rec {
     ./parse.patch # Fixes compilation error by avoiding redundant definitions.
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "A slide show presentation tool";
 
diff --git a/pkgs/applications/misc/xteddy/default.nix b/pkgs/applications/misc/xteddy/default.nix
index 34ec17b0b9a52..717ba66feb86a 100644
--- a/pkgs/applications/misc/xteddy/default.nix
+++ b/pkgs/applications/misc/xteddy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, pkg-config, xorg, imlib2, makeWrapper }:
+{ lib, stdenv, fetchFromGitLab, pkg-config, xorg, imlib2, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "xteddy";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/xteddy --run "cd $out/share/images/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cuddly teddy bear for your X desktop";
     homepage = "https://weber.itn.liu.se/~stegu/xteddy/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/misc/xygrib/default.nix b/pkgs/applications/misc/xygrib/default.nix
index e3d22b5d00a64..24f6b22b4e2b8 100644
--- a/pkgs/applications/misc/xygrib/default.nix
+++ b/pkgs/applications/misc/xygrib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, wrapQtAppsHook, cmake, bzip2, qtbase, qttools, libnova, proj, libpng, openjpeg } :
+{ lib, stdenv, fetchFromGitHub, wrapQtAppsHook, cmake, bzip2, qtbase, qttools, libnova, proj, libpng, openjpeg } :
 
 stdenv.mkDerivation rec {
   version = "1.2.6.1";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     ln -s $out/XyGrib/XyGrib $out/bin/xygrib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://opengribs.org";
     description = "Weather Forecast Visualization";
     longDescription = ''XyGrib is a leading opensource weather visualization package.
diff --git a/pkgs/applications/misc/yarssr/default.nix b/pkgs/applications/misc/yarssr/default.nix
index 805c708ea00c4..93e8f1fc9d75c 100644
--- a/pkgs/applications/misc/yarssr/default.nix
+++ b/pkgs/applications/misc/yarssr/default.nix
@@ -54,7 +54,7 @@ stdenv.mkDerivation {
       --set PERL5LIB "${perlPackages.makePerlPath perlDeps}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tsyrogit/zxcvbn-c";
     description = "A fork of Yarssr (a RSS reader for the GNOME Tray) from http://yarssr.sf.net with various fixes";
     license = licenses.gpl1;
diff --git a/pkgs/applications/misc/yokadi/default.nix b/pkgs/applications/misc/yokadi/default.nix
index 00507d2ee8881..ca329521142cb 100644
--- a/pkgs/applications/misc/yokadi/default.nix
+++ b/pkgs/applications/misc/yokadi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonApplication, dateutil,
+{ lib, stdenv, fetchurl, buildPythonApplication, dateutil,
   sqlalchemy, setproctitle, icalendar }:
 
 buildPythonApplication rec {
@@ -20,7 +20,7 @@ buildPythonApplication rec {
   # Yokadi doesn't have any tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line oriented, sqlite powered, todo-list";
     homepage = "https://yokadi.github.io/index.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/misc/yubioath-desktop/default.nix b/pkgs/applications/misc/yubioath-desktop/default.nix
index 460b34416ff5b..22385262a5d4c 100644
--- a/pkgs/applications/misc/yubioath-desktop/default.nix
+++ b/pkgs/applications/misc/yubioath-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mkDerivation
+{ lib, stdenv, fetchurl, mkDerivation
 , qmake, qtbase, qtquickcontrols2, qtgraphicaleffects
 , python3, pyotherside
 , pcsclite, yubikey-personalization
@@ -51,7 +51,7 @@ mkDerivation rec {
         --replace 'Icon=yubioath' "Icon=$out/share/yubioath/icons/com.yubico.yubioath.png"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Yubico Authenticator";
     longDescription = ''
       Application for generating Open Authentication (OATH) time-based TOTP and
diff --git a/pkgs/applications/misc/zathura/djvu/default.nix b/pkgs/applications/misc/zathura/djvu/default.nix
index 954df5301e312..a5ed7ab678122 100644
--- a/pkgs/applications/misc/zathura/djvu/default.nix
+++ b/pkgs/applications/misc/zathura/djvu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, gtk, zathura_core, girara, djvulibre, gettext }:
+{ lib, stdenv, fetchurl, meson, ninja, pkgconfig, gtk, zathura_core, girara, djvulibre, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "zathura-djvu";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   PKG_CONFIG_ZATHURA_PLUGINDIR = "lib/zathura";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pwmt.org/projects/zathura-djvu/";
     description = "A zathura DJVU plugin";
     longDescription = ''
diff --git a/pkgs/applications/misc/zola/default.nix b/pkgs/applications/misc/zola/default.nix
index 63d5ba8d484db..99699d6e3ccbe 100644
--- a/pkgs/applications/misc/zola/default.nix
+++ b/pkgs/applications/misc/zola/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, cmake, pkg-config, openssl, oniguruma, CoreServices }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, cmake, pkg-config, openssl, oniguruma, CoreServices }:
 
 rustPlatform.buildRustPackage rec {
   pname = "zola";
@@ -28,7 +28,7 @@ rustPlatform.buildRustPackage rec {
       -t $out/share/fish/vendor_completions.d
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast static site generator with everything built-in";
     homepage = "https://www.getzola.org/";
     license = licenses.mit;
diff --git a/pkgs/applications/misc/zscroll/default.nix b/pkgs/applications/misc/zscroll/default.nix
index 402032b5cec3f..748bc21ee35fe 100644
--- a/pkgs/applications/misc/zscroll/default.nix
+++ b/pkgs/applications/misc/zscroll/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3, python3Packages, fetchFromGitHub }:
 
 let version = "1.0"; in
 
@@ -18,7 +18,7 @@ python3Packages.buildPythonApplication {
 
   propagatedBuildInputs = [ python3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A text scroller for use with panels and shells";
     homepage = "https://github.com/noctuid/zscroll";
     license = licenses.bsd2;
diff --git a/pkgs/applications/networking/3proxy/default.nix b/pkgs/applications/networking/3proxy/default.nix
index a1e54b502289d..f89d6eebb5efc 100644
--- a/pkgs/applications/networking/3proxy/default.nix
+++ b/pkgs/applications/networking/3proxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, coreutils }:
+{ lib, stdenv, fetchFromGitHub, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "3proxy";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   preConfigure = ''
     ln -s Makefile.Linux Makefile
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiny free proxy server";
     homepage = "https://github.com/z3APA3A/3proxy";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/apache-directory-studio/default.nix b/pkgs/applications/networking/apache-directory-studio/default.nix
index 94359bdd22714..18f9a7990c3e9 100644
--- a/pkgs/applications/networking/apache-directory-studio/default.nix
+++ b/pkgs/applications/networking/apache-directory-studio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jdk, makeWrapper, autoPatchelfHook, makeDesktopItem, glib, libsecret }:
+{ lib, stdenv, fetchurl, jdk, makeWrapper, autoPatchelfHook, makeDesktopItem, glib, libsecret }:
 
 let
   desktopItem = makeDesktopItem {
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     install -D -t "$out/share/applications" ${desktopItem}/share/applications/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Eclipse-based LDAP browser and directory client";
     homepage = "https://directory.apache.org/studio/";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/appgate-sdp/default.nix b/pkgs/applications/networking/appgate-sdp/default.nix
index c56a6eb658257..bfe6ba97e4c28 100644
--- a/pkgs/applications/networking/appgate-sdp/default.nix
+++ b/pkgs/applications/networking/appgate-sdp/default.nix
@@ -159,7 +159,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/opt/appgate/appgate-driver --prefix PATH : ${stdenv.lib.makeBinPath [ iproute networkmanager dnsmasq ]}
     wrapProgram $out/opt/appgate/linux/set_dns --set PYTHONPATH $PYTHONPATH
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Appgate SDP (Software Defined Perimeter) desktop client";
     homepage = https://www.appgate.com/support/software-defined-perimeter-support;
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/brig/default.nix b/pkgs/applications/networking/brig/default.nix
index 66329b64eaceb..a56a586b82a19 100644
--- a/pkgs/applications/networking/brig/default.nix
+++ b/pkgs/applications/networking/brig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "brig";
@@ -15,7 +15,7 @@ buildGoPackage rec {
     sha256 = "0gi39jmnzqrgj146yw8lcmgmvzx7ii1dgw4iqig7kx8c0jiqi600";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "File synchronization on top of ipfs with git like interface and FUSE filesystem";
     homepage = "https://github.com/sahib/brig";
     license = licenses.agpl3;
diff --git a/pkgs/applications/networking/browsers/asuka/default.nix b/pkgs/applications/networking/browsers/asuka/default.nix
index 89f4fda88a186..89718100ab543 100644
--- a/pkgs/applications/networking/browsers/asuka/default.nix
+++ b/pkgs/applications/networking/browsers/asuka/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchurl, pkgconfig, ncurses, openssl, Security }:
+{ lib, stdenv, rustPlatform, fetchurl, pkgconfig, ncurses, openssl, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "asuka";
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
   buildInputs = [ ncurses openssl ]
     ++ stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gemini Project client written in Rust with NCurses";
     homepage = "https://git.sr.ht/~julienxx/asuka";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/brave/default.nix b/pkgs/applications/networking/browsers/brave/default.nix
index 92177183b0cab..9eed9b627e67d 100644
--- a/pkgs/applications/networking/browsers/brave/default.nix
+++ b/pkgs/applications/networking/browsers/brave/default.nix
@@ -155,7 +155,7 @@ stdenv.mkDerivation rec {
 
   passthru.updateScript = ./update.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://brave.com/";
     description = "Privacy-oriented browser for Desktop and Laptop computers";
     changelog = "https://github.com/brave/brave-browser/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/applications/networking/browsers/browsh/default.nix b/pkgs/applications/networking/browsers/browsh/default.nix
index 3662c3badd3e8..cf1ae25974e87 100644
--- a/pkgs/applications/networking/browsers/browsh/default.nix
+++ b/pkgs/applications/networking/browsers/browsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchurl, fetchFromGitHub, go-bindata }:
+{ lib, stdenv, buildGoPackage, fetchurl, fetchFromGitHub, go-bindata }:
 
 let
   version = "1.6.4";
@@ -51,7 +51,7 @@ in buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fully-modern text-based browser, rendering to TTY and browsers";
     homepage = "https://www.brow.sh/";
     maintainers = [ maintainers.kalbasit ];
diff --git a/pkgs/applications/networking/browsers/castor/default.nix b/pkgs/applications/networking/browsers/castor/default.nix
index c9ad213cf1d15..6482ce59da6c0 100644
--- a/pkgs/applications/networking/browsers/castor/default.nix
+++ b/pkgs/applications/networking/browsers/castor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , rustPlatform
 , pkg-config
@@ -41,7 +41,7 @@ rustPlatform.buildRustPackage rec {
   # Sometimes tests fail when run in parallel
   cargoParallelTestThreads = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A graphical client for plain-text protocols written in Rust with GTK. It currently supports the Gemini, Gopher and Finger protocols";
     homepage = "https://sr.ht/~julienxx/Castor";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/dillo/default.nix b/pkgs/applications/networking/browsers/dillo/default.nix
index fa1fa76340c32..9da80576e95a9 100644
--- a/pkgs/applications/networking/browsers/dillo/default.nix
+++ b/pkgs/applications/networking/browsers/dillo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , fltk
 , openssl
 , libjpeg, libpng
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--enable-ssl" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.dillo.org/";
     description = "A fast graphical web browser with a small footprint";
     longDescription = ''
diff --git a/pkgs/applications/networking/browsers/elinks/default.nix b/pkgs/applications/networking/browsers/elinks/default.nix
index 79f3cb76a01a3..114bc93f3b9f5 100644
--- a/pkgs/applications/networking/browsers/elinks/default.nix
+++ b/pkgs/applications/networking/browsers/elinks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, ncurses, xlibsWrapper, bzip2, zlib
+{ lib, stdenv, fetchFromGitHub, fetchpatch, ncurses, xlibsWrapper, bzip2, zlib
 , brotli, zstd, lzma, openssl, autoreconfHook, gettext, pkgconfig, libev
 , gpm, libidn, tre, expat
 , # Incompatible licenses, LGPLv3 - GPLv2
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     ++ stdenv.lib.optional enablePerl         "--with-perl"
     ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Full-featured text-mode web browser (package based on the fork felinks)";
     homepage = "https://github.com/rkd77/felinks";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/browsers/eolie/default.nix b/pkgs/applications/networking/browsers/eolie/default.nix
index a16beb6520898..53a32e09f8781 100644
--- a/pkgs/applications/networking/browsers/eolie/default.nix
+++ b/pkgs/applications/networking/browsers/eolie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, meson, ninja, pkgconfig, nix-update-script
+{ lib, stdenv, fetchgit, meson, ninja, pkgconfig, nix-update-script
 , python3, gtk3, libsecret, gst_all_1, webkitgtk, glib
 , glib-networking, gtkspell3, hunspell, desktop-file-utils
 , gobject-introspection, wrapGAppsHook, gnome3 }:
@@ -72,7 +72,7 @@ python3.pkgs.buildPythonApplication rec {
 
   strictDeps = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A new GNOME web browser";
     homepage = "https://wiki.gnome.org/Apps/Eolie";
     license  = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/browsers/ephemeral/default.nix b/pkgs/applications/networking/browsers/ephemeral/default.nix
index 6d8aa3649a90e..ad2d69edd4e0d 100644
--- a/pkgs/applications/networking/browsers/ephemeral/default.nix
+++ b/pkgs/applications/networking/browsers/ephemeral/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , desktop-file-utils
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The always-incognito web browser";
     homepage = "https://github.com/cassidyjames/ephemeral";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/networking/browsers/falkon/default.nix b/pkgs/applications/networking/browsers/falkon/default.nix
index 49d67690bf1fd..c1d40fa770ffa 100644
--- a/pkgs/applications/networking/browsers/falkon/default.nix
+++ b/pkgs/applications/networking/browsers/falkon/default.nix
@@ -47,7 +47,7 @@ mkDerivation rec {
     wrapQtAppsHook
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "QtWebEngine based cross-platform web browser";
     homepage    = "https://community.kde.org/Incubator/Projects/Falkon";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/networking/browsers/firefox-bin/default.nix b/pkgs/applications/networking/browsers/firefox-bin/default.nix
index d86b9d6f98709..1bf97a8ad98c0 100644
--- a/pkgs/applications/networking/browsers/firefox-bin/default.nix
+++ b/pkgs/applications/networking/browsers/firefox-bin/default.nix
@@ -193,7 +193,7 @@ stdenv.mkDerivation {
         then "http://archive.mozilla.org/pub/devedition/releases/"
         else "http://archive.mozilla.org/pub/firefox/releases/";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mozilla Firefox, free web browser (binary package)";
     homepage = "http://www.mozilla.org/firefox/";
     license = {
diff --git a/pkgs/applications/networking/browsers/links2/default.nix b/pkgs/applications/networking/browsers/links2/default.nix
index 0db521f8ef59d..f497a7f9a2856 100644
--- a/pkgs/applications/networking/browsers/links2/default.nix
+++ b/pkgs/applications/networking/browsers/links2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , gpm, openssl, pkgconfig, libev # Misc.
 , libpng, libjpeg, libtiff, librsvg # graphic formats
 , bzip2, zlib, xz # Transfer encodings
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     ++ stdenv.lib.optional enableFB "--with-fb"
     ++ stdenv.lib.optional enableDirectFB "--with-directfb";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://links.twibright.com/";
     description = "A small browser with some graphics support";
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/applications/networking/browsers/luakit/default.nix b/pkgs/applications/networking/browsers/luakit/default.nix
index 42eb8bcb63a81..e634b0f566f60 100644
--- a/pkgs/applications/networking/browsers/luakit/default.nix
+++ b/pkgs/applications/networking/browsers/luakit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, wrapGAppsHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, wrapGAppsHook
 , help2man, luafilesystem, luajit, sqlite
 , webkitgtk, gtk3, gst_all_1, glib-networking
 }:
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, small, webkit-based browser framework extensible in Lua";
     longDescription = ''
       Luakit is a highly configurable browser framework based on the WebKit web
diff --git a/pkgs/applications/networking/browsers/lynx/default.nix b/pkgs/applications/networking/browsers/lynx/default.nix
index 8aeee45b9e542..9c9ec5624c87e 100644
--- a/pkgs/applications/networking/browsers/lynx/default.nix
+++ b/pkgs/applications/networking/browsers/lynx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages
+{ lib, stdenv, buildPackages
 , fetchurl, pkgconfig, ncurses, gzip
 , sslSupport ? true, openssl ? null
 , nukeReferences
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     nuke-refs cfg_defs.h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A text-mode web browser";
     homepage = "https://lynx.invisible-island.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/networking/browsers/midori/default.nix b/pkgs/applications/networking/browsers/midori/default.nix
index 66f6384643ad0..ca6d4335785ef 100644
--- a/pkgs/applications/networking/browsers/midori/default.nix
+++ b/pkgs/applications/networking/browsers/midori/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cmake
 , ninja
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     libarchive
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight WebKitGTK web browser";
     homepage = "https://www.midori-browser.org/";
     license = with licenses; [ lgpl21Plus ];
diff --git a/pkgs/applications/networking/browsers/netsurf/browser.nix b/pkgs/applications/networking/browsers/netsurf/browser.nix
index 407d94a4dc456..4dc3ee1695727 100644
--- a/pkgs/applications/networking/browsers/netsurf/browser.nix
+++ b/pkgs/applications/networking/browsers/netsurf/browser.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, makeWrapper, wrapGAppsHook
+{ lib, stdenv, fetchurl, fetchpatch, makeWrapper, wrapGAppsHook
 
 # Buildtime dependencies.
 , check, pkgconfig, xxd
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     "TARGET=${uilib}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/";
     description = "A free, open source, small web browser";
     longDescription = ''
diff --git a/pkgs/applications/networking/browsers/netsurf/buildsystem.nix b/pkgs/applications/networking/browsers/netsurf/buildsystem.nix
index 2d625b7254465..4956c70655a70 100644
--- a/pkgs/applications/networking/browsers/netsurf/buildsystem.nix
+++ b/pkgs/applications/networking/browsers/netsurf/buildsystem.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "netsurf-${libname}";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     "PREFIX=$(out)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/";
     description = "NetSurf browser shared build system";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libcss.nix b/pkgs/applications/networking/browsers/netsurf/libcss.nix
index db907edd8799d..b09701fc3678e 100644
--- a/pkgs/applications/networking/browsers/netsurf/libcss.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libcss.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, perl
+{ lib, stdenv, fetchurl, pkgconfig, perl
 , buildsystem
 , libparserutils
 , libwapcaplet
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE= "-Wno-error=implicit-fallthrough";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "Cascading Style Sheets library for netsurf browser";
     longDescription = ''
diff --git a/pkgs/applications/networking/browsers/netsurf/libdom.nix b/pkgs/applications/networking/browsers/netsurf/libdom.nix
index 3aa9e3a1878e4..5bb6280143742 100644
--- a/pkgs/applications/networking/browsers/netsurf/libdom.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libdom.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, expat
+{ lib, stdenv, fetchurl, pkgconfig, expat
 , buildsystem
 , libparserutils
 , libwapcaplet
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "Document Object Model library for netsurf browser";
     longDescription = ''
diff --git a/pkgs/applications/networking/browsers/netsurf/libhubbub.nix b/pkgs/applications/networking/browsers/netsurf/libhubbub.nix
index 53b8d270d4f63..3a1a29e743c02 100644
--- a/pkgs/applications/networking/browsers/netsurf/libhubbub.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libhubbub.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, perl
+{ lib, stdenv, fetchurl, pkgconfig, perl
 , buildsystem
 , libparserutils
 }:
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/hubbub/";
     description = "HTML5 parser library for netsurf browser";
     longDescription = ''
diff --git a/pkgs/applications/networking/browsers/netsurf/libnsbmp.nix b/pkgs/applications/networking/browsers/netsurf/libnsbmp.nix
index 95487eed00fc5..f25ccf9635421 100644
--- a/pkgs/applications/networking/browsers/netsurf/libnsbmp.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libnsbmp.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , buildsystem
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/";
     description = "BMP Decoder for netsurf browser";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libnsfb.nix b/pkgs/applications/networking/browsers/netsurf/libnsfb.nix
index d37766f5330f2..cb3a759acb858 100644
--- a/pkgs/applications/networking/browsers/netsurf/libnsfb.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libnsfb.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , uilib, SDL
 , buildsystem
 }:
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     "TARGET=${uilib}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "Netsurf framebuffer abstraction library";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libnsgif.nix b/pkgs/applications/networking/browsers/netsurf/libnsgif.nix
index d8683280c4e1a..032d886085fbc 100644
--- a/pkgs/applications/networking/browsers/netsurf/libnsgif.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libnsgif.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , buildsystem
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "GIF Decoder for netsurf browser";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libnslog.nix b/pkgs/applications/networking/browsers/netsurf/libnslog.nix
index 12fdcff50bd30..eba4952d7fc07 100644
--- a/pkgs/applications/networking/browsers/netsurf/libnslog.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libnslog.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, bison, flex
+{ lib, stdenv, fetchurl, pkgconfig, bison, flex
 , buildsystem
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/";
     description = "NetSurf Parametric Logging Library";
     license = licenses.isc;
diff --git a/pkgs/applications/networking/browsers/netsurf/libnspsl.nix b/pkgs/applications/networking/browsers/netsurf/libnspsl.nix
index 4338f78247c75..bfbd611000c84 100644
--- a/pkgs/applications/networking/browsers/netsurf/libnspsl.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libnspsl.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , buildsystem
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/";
     description = "NetSurf Public Suffix List - Handling library";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libnsutils.nix b/pkgs/applications/networking/browsers/netsurf/libnsutils.nix
index 42c8b8b062141..56e2e048b6767 100644
--- a/pkgs/applications/networking/browsers/netsurf/libnsutils.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libnsutils.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , buildsystem
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "Generalised utility library for netsurf browser";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libparserutils.nix b/pkgs/applications/networking/browsers/netsurf/libparserutils.nix
index b96018d92eb86..ac50237cc49d2 100644
--- a/pkgs/applications/networking/browsers/netsurf/libparserutils.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libparserutils.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl
+{ lib, stdenv, fetchurl, perl
 , buildsystem
 }:
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "Parser building library for netsurf browser";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libsvgtiny.nix b/pkgs/applications/networking/browsers/netsurf/libsvgtiny.nix
index aef154bbc17cd..66a2dbcf437f3 100644
--- a/pkgs/applications/networking/browsers/netsurf/libsvgtiny.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libsvgtiny.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gperf
+{ lib, stdenv, fetchurl, pkgconfig, gperf
 , buildsystem
 , libdom
 , libhubbub
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "NetSurf SVG decoder";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libutf8proc.nix b/pkgs/applications/networking/browsers/netsurf/libutf8proc.nix
index 59bae9e941eb1..38680da1bcf31 100644
--- a/pkgs/applications/networking/browsers/netsurf/libutf8proc.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libutf8proc.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , buildsystem
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "UTF8 Processing library for netsurf browser";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/libwapcaplet.nix b/pkgs/applications/networking/browsers/netsurf/libwapcaplet.nix
index 8c5af461fd06f..318885bd27214 100644
--- a/pkgs/applications/networking/browsers/netsurf/libwapcaplet.nix
+++ b/pkgs/applications/networking/browsers/netsurf/libwapcaplet.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , buildsystem
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-Wno-error=cast-function-type";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/projects/${libname}/";
     description = "String internment library for netsurf browser";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/netsurf/nsgenbind.nix b/pkgs/applications/networking/browsers/netsurf/nsgenbind.nix
index 0be7adc4a5950..d08f4dbccf60a 100644
--- a/pkgs/applications/networking/browsers/netsurf/nsgenbind.nix
+++ b/pkgs/applications/networking/browsers/netsurf/nsgenbind.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , flex, bison
 , buildsystem
 }:
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "NSSHARED=${buildsystem}/share/netsurf-buildsystem"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.netsurf-browser.org/";
     description = "Generator for JavaScript bindings for netsurf browser";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/browsers/nyxt/default.nix b/pkgs/applications/networking/browsers/nyxt/default.nix
index ff99b1c21ddd1..b4bec6ead3f64 100644
--- a/pkgs/applications/networking/browsers/nyxt/default.nix
+++ b/pkgs/applications/networking/browsers/nyxt/default.nix
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     $out/bin/nyxt -h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Infinitely extensible web-browser (with Lisp development files using WebKitGTK platform port)";
     homepage = "https://nyxt.atlas.engineer";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/browsers/qutebrowser/default.nix b/pkgs/applications/networking/browsers/qutebrowser/default.nix
index 4b1efe9dba2f1..753ea1dc08d5e 100644
--- a/pkgs/applications/networking/browsers/qutebrowser/default.nix
+++ b/pkgs/applications/networking/browsers/qutebrowser/default.nix
@@ -113,7 +113,7 @@ in mkDerivationWith python3Packages.buildPythonApplication rec {
       --add-flags '--backend ${backend}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/The-Compiler/qutebrowser";
     description = "Keyboard-focused browser with a minimal GUI";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/browsers/surf/default.nix b/pkgs/applications/networking/browsers/surf/default.nix
index 57eb4fad76b0c..5ab7cb8d93b3f 100644
--- a/pkgs/applications/networking/browsers/surf/default.nix
+++ b/pkgs/applications/networking/browsers/surf/default.nix
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple web browser based on WebKitGTK";
     longDescription = ''
       surf is a simple web browser based on WebKitGTK. It is able to display
diff --git a/pkgs/applications/networking/browsers/tor-browser-bundle-bin/default.nix b/pkgs/applications/networking/browsers/tor-browser-bundle-bin/default.nix
index ab8a21c5b71b7..8c70b13cfe15d 100644
--- a/pkgs/applications/networking/browsers/tor-browser-bundle-bin/default.nix
+++ b/pkgs/applications/networking/browsers/tor-browser-bundle-bin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeDesktopItem
 
@@ -390,7 +390,7 @@ stdenv.mkDerivation rec {
       $out/bin/tor-browser --version >/dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tor Browser Bundle built by torproject.org";
     longDescription = ''
       Tor Browser Bundle is a bundle of the Tor daemon, Tor Browser (heavily patched version of
diff --git a/pkgs/applications/networking/browsers/vivaldi/default.nix b/pkgs/applications/networking/browsers/vivaldi/default.nix
index cf37a31ee4235..d19da31026e02 100644
--- a/pkgs/applications/networking/browsers/vivaldi/default.nix
+++ b/pkgs/applications/networking/browsers/vivaldi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, libX11, libXext, libSM, libICE, libxkbcommon
+{ lib, stdenv, fetchurl, zlib, libX11, libXext, libSM, libICE, libxkbcommon
 , libXfixes, libXt, libXi, libXcursor, libXScrnSaver, libXcomposite, libXdamage, libXtst, libXrandr
 , alsaLib, dbus, cups, libexif, ffmpeg_3, systemd
 , freetype, fontconfig, libXft, libXrender, libxcb, expat
@@ -86,7 +86,7 @@ in stdenv.mkDerivation rec {
     ln -sf ${vivaldi-widevine}/share/google/chrome/WidevineCdm $out/opt/${vivaldiName}/WidevineCdm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Browser for our Friends, powerful and personal";
     homepage    = "https://vivaldi.com";
     license     = licenses.unfree;
diff --git a/pkgs/applications/networking/browsers/vivaldi/ffmpeg-codecs.nix b/pkgs/applications/networking/browsers/vivaldi/ffmpeg-codecs.nix
index 2643bd3e58d9b..d6703788ed92a 100644
--- a/pkgs/applications/networking/browsers/vivaldi/ffmpeg-codecs.nix
+++ b/pkgs/applications/networking/browsers/vivaldi/ffmpeg-codecs.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , dpkg
 }:
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     install -vD usr/lib/chromium-browser/libffmpeg.so $out/lib/libffmpeg.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Additional support for proprietary codecs for Vivaldi";
     homepage    = "https://ffmpeg.org/";
     license     = licenses.lgpl21;
diff --git a/pkgs/applications/networking/browsers/vivaldi/widevine.nix b/pkgs/applications/networking/browsers/vivaldi/widevine.nix
index 6e807aac5df6f..3b3a0a8589076 100644
--- a/pkgs/applications/networking/browsers/vivaldi/widevine.nix
+++ b/pkgs/applications/networking/browsers/vivaldi/widevine.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , unzip
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     install -vD libwidevinecdm.so $out/share/google/chrome/WidevineCdm/_platform_specific/linux_x64/libwidevinecdm.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Widevine support for Vivaldi";
     homepage = "https://www.widevine.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/c14/default.nix b/pkgs/applications/networking/c14/default.nix
index 58d9d026f97d9..572975f78d0b4 100644
--- a/pkgs/applications/networking/c14/default.nix
+++ b/pkgs/applications/networking/c14/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "c14-cli";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "0b1piviy6vvdbak8y8bc24rk3c1fi67vv3352pmnzvrhsar2r5yf";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C14 is designed for data archiving & long-term backups";
     homepage = "https://www.online.net/en/storage/c14-cold-storage";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/calls/default.nix b/pkgs/applications/networking/calls/default.nix
index e57cf810491c5..d163f8a7475a0 100644
--- a/pkgs/applications/networking/calls/default.nix
+++ b/pkgs/applications/networking/calls/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , meson
 , ninja
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A phone dialer and call handler";
     homepage = "https://source.puri.sm/Librem5/calls";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/cawbird/default.nix b/pkgs/applications/networking/cawbird/default.nix
index bd927d2b68e3f..3394394afd493 100644
--- a/pkgs/applications/networking/cawbird/default.nix
+++ b/pkgs/applications/networking/cawbird/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , glib
 , gtk3
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     patchShebangs data/meson_post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Native GTK Twitter client for the Linux desktop";
     longDescription = "Cawbird is a modern, easy and fun Twitter client. Fork of the discontinued Corebird.";
     homepage = "https://ibboard.co.uk/cawbird/";
diff --git a/pkgs/applications/networking/charles/default.nix b/pkgs/applications/networking/charles/default.nix
index 3dd9fe2c4f892..82c4ce0f1be60 100644
--- a/pkgs/applications/networking/charles/default.nix
+++ b/pkgs/applications/networking/charles/default.nix
@@ -1,5 +1,5 @@
 {
-stdenv
+lib, stdenv
 , makeWrapper
 , makeDesktopItem
 , fetchurl
@@ -45,7 +45,7 @@ let
         cp -r icon $out/share/icons/hicolor
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "Web Debugging Proxy";
         homepage = "https://www.charlesproxy.com/";
         maintainers = [ maintainers.kalbasit ];
diff --git a/pkgs/applications/networking/cloudflared/default.nix b/pkgs/applications/networking/cloudflared/default.nix
index 3e19af619db38..2b5f7a0e663fe 100644
--- a/pkgs/applications/networking/cloudflared/default.nix
+++ b/pkgs/applications/networking/cloudflared/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "cloudflared";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   buildFlagsArray = "-ldflags=-X main.Version=${version}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CloudFlare Argo Tunnel daemon (and DNS-over-HTTPS client)";
     homepage    = "https://www.cloudflare.com/products/argo-tunnel";
     license     = licenses.unfree;
diff --git a/pkgs/applications/networking/cluster/atlantis/default.nix b/pkgs/applications/networking/cluster/atlantis/default.nix
index 15c5f0e97c4cd..60be1d000b3d2 100644
--- a/pkgs/applications/networking/cluster/atlantis/default.nix
+++ b/pkgs/applications/networking/cluster/atlantis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "atlantis";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/runatlantis/atlantis";
     description = "Terraform Pull Request Automation";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/click/default.nix b/pkgs/applications/networking/cluster/click/default.nix
index 2c0e73fb30dbb..f1895d074bc4b 100644
--- a/pkgs/applications/networking/cluster/click/default.nix
+++ b/pkgs/applications/networking/cluster/click/default.nix
@@ -1,4 +1,4 @@
-{ darwin, fetchFromGitHub, rustPlatform, stdenv }:
+{ darwin, fetchFromGitHub, rustPlatform, lib, stdenv }:
 
 with rustPlatform;
 
@@ -17,7 +17,7 @@ buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''The "Command Line Interactive Controller for Kubernetes"'';
     homepage = "https://github.com/databricks/click";
     license = [ licenses.asl20 ];
diff --git a/pkgs/applications/networking/cluster/docker-machine/default.nix b/pkgs/applications/networking/cluster/docker-machine/default.nix
index 93f5a85c33ad8..5a4f6b7db0e57 100644
--- a/pkgs/applications/networking/cluster/docker-machine/default.nix
+++ b/pkgs/applications/networking/cluster/docker-machine/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by go2nix.
-{ stdenv, buildGoPackage, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, installShellFiles }:
 
 buildGoPackage rec {
   pname = "machine";
@@ -23,7 +23,7 @@ buildGoPackage rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.docker.com/machine/";
     description = "Docker Machine is a tool that lets you install Docker Engine on virtual hosts, and manage Docker Engine on the hosts";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/docker-machine/kvm.nix b/pkgs/applications/networking/cluster/docker-machine/kvm.nix
index 024572ec3db99..50f2ab14a77b5 100644
--- a/pkgs/applications/networking/cluster/docker-machine/kvm.nix
+++ b/pkgs/applications/networking/cluster/docker-machine/kvm.nix
@@ -1,5 +1,5 @@
 # This file was generated by go2nix.
-{ stdenv, buildGoPackage, fetchFromGitHub, libvirt, pkgconfig }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, libvirt, pkgconfig }:
 
 buildGoPackage rec {
   pname = "docker-machine-kvm";
@@ -18,7 +18,7 @@ buildGoPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libvirt ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dhiltgen/docker-machine-kvm";
     description = "KVM driver for docker-machine";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/docker-machine/xhyve.nix b/pkgs/applications/networking/cluster/docker-machine/xhyve.nix
index a740d0486db5d..49e59ab7093a9 100644
--- a/pkgs/applications/networking/cluster/docker-machine/xhyve.nix
+++ b/pkgs/applications/networking/cluster/docker-machine/xhyve.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, fetchpatch, pkgconfig, cctools, Hypervisor, vmnet }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, fetchpatch, pkgconfig, cctools, Hypervisor, vmnet }:
 
 buildGoPackage rec {
   pname = "docker-machine-xhyve";
@@ -29,7 +29,7 @@ buildGoPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ Hypervisor vmnet ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/machine-drivers/docker-machine-driver-xhyve";
     description = "Xhyve driver for docker-machine";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/cluster/flink/default.nix b/pkgs/applications/networking/cluster/flink/default.nix
index f99c708161eb7..d8b156bed88e8 100644
--- a/pkgs/applications/networking/cluster/flink/default.nix
+++ b/pkgs/applications/networking/cluster/flink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre
+{ lib, stdenv, fetchurl, makeWrapper, jre
 , version ? "1.6" }:
 
 let
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     EOF
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A distributed stream processing framework";
     homepage = "https://flink.apache.org";
     downloadPage = "https://flink.apache.org/downloads.html";
diff --git a/pkgs/applications/networking/cluster/fluxcd/default.nix b/pkgs/applications/networking/cluster/fluxcd/default.nix
index bd903bf7253a9..2800df052b5df 100644
--- a/pkgs/applications/networking/cluster/fluxcd/default.nix
+++ b/pkgs/applications/networking/cluster/fluxcd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
 
 buildGoModule rec {
   pname = "fluxcd";
@@ -28,7 +28,7 @@ buildGoModule rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open and extensible continuous delivery solution for Kubernetes";
     longDescription = ''
       Flux is a tool for keeping Kubernetes clusters in sync
diff --git a/pkgs/applications/networking/cluster/fluxctl/default.nix b/pkgs/applications/networking/cluster/fluxctl/default.nix
index c478966195130..4f1f57e45b7fb 100644
--- a/pkgs/applications/networking/cluster/fluxctl/default.nix
+++ b/pkgs/applications/networking/cluster/fluxctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
 
 buildGoModule rec {
   pname = "fluxctl";
@@ -28,7 +28,7 @@ buildGoModule rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI client for Flux, the GitOps Kubernetes operator";
     homepage = "https://github.com/fluxcd/flux";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/habitat/default.nix b/pkgs/applications/networking/cluster/habitat/default.nix
index f2f3925fbe4d3..9abaeef80137a 100644
--- a/pkgs/applications/networking/cluster/habitat/default.nix
+++ b/pkgs/applications/networking/cluster/habitat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkgconfig
 , libsodium, libarchive, openssl, zeromq }:
 
 rustPlatform.buildRustPackage rec {
@@ -28,7 +28,7 @@ rustPlatform.buildRustPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An application automation framework";
     homepage = "https://www.habitat.sh";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/hadoop/default.nix b/pkgs/applications/networking/cluster/hadoop/default.nix
index 5fc35e6a0af11..88d4a88b67e23 100644
--- a/pkgs/applications/networking/cluster/hadoop/default.nix
+++ b/pkgs/applications/networking/cluster/hadoop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, pkgconfig, which, maven, cmake, jre, bash
+{ lib, stdenv, fetchurl, makeWrapper, pkgconfig, which, maven, cmake, jre, bash
 , coreutils, glibc, protobuf2_5, fuse, snappy, zlib, bzip2, openssl, openssl_1_0_2
 }:
 
@@ -94,7 +94,7 @@ let
           done
         '';
 
-        meta = with stdenv.lib; {
+        meta = with lib; {
           homepage = "http://hadoop.apache.org/";
           description = "Framework for distributed processing of large data sets across clusters of computers";
           license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/helm/default.nix b/pkgs/applications/networking/cluster/helm/default.nix
index 1cb7a257eccb7..7d97896c360a6 100644
--- a/pkgs/applications/networking/cluster/helm/default.nix
+++ b/pkgs/applications/networking/cluster/helm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
 
 buildGoModule rec {
   pname = "helm";
@@ -24,7 +24,7 @@ buildGoModule rec {
     installShellCompletion helm.{bash,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kubernetes/helm";
     description = "A package manager for kubernetes";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/k9s/default.nix b/pkgs/applications/networking/cluster/k9s/default.nix
index d45cbb19e71b5..abc23058303b9 100644
--- a/pkgs/applications/networking/cluster/k9s/default.nix
+++ b/pkgs/applications/networking/cluster/k9s/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "k9s";
@@ -22,7 +22,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kubernetes CLI To Manage Your Clusters In Style";
     homepage = "https://github.com/derailed/k9s";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/kops/default.nix b/pkgs/applications/networking/cluster/kops/default.nix
index a81c33a84bb1f..f3037cf8a3630 100644
--- a/pkgs/applications/networking/cluster/kops/default.nix
+++ b/pkgs/applications/networking/cluster/kops/default.nix
@@ -39,7 +39,7 @@ let
           done
         '';
 
-        meta = with stdenv.lib; {
+        meta = with lib; {
           description = "Easiest way to get a production Kubernetes up and running";
           homepage = "https://github.com/kubernetes/kops";
           changelog = "https://github.com/kubernetes/kops/tree/master/docs/releases";
diff --git a/pkgs/applications/networking/cluster/kubeless/default.nix b/pkgs/applications/networking/cluster/kubeless/default.nix
index 6f6c8dc338bf6..fd7eabf12761b 100644
--- a/pkgs/applications/networking/cluster/kubeless/default.nix
+++ b/pkgs/applications/networking/cluster/kubeless/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, installShellFiles }:
 
 buildGoPackage rec {
   pname = "kubeless";
@@ -28,7 +28,7 @@ buildGoPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kubeless.io";
     description = "The Kubernetes Native Serverless Framework";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/kubelogin/default.nix b/pkgs/applications/networking/cluster/kubelogin/default.nix
index ced9c43876f6e..b1b107a2b0323 100644
--- a/pkgs/applications/networking/cluster/kubelogin/default.nix
+++ b/pkgs/applications/networking/cluster/kubelogin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule, go }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule, go }:
 
 buildGoModule rec {
   pname = "kubelogin";
@@ -19,7 +19,7 @@ buildGoModule rec {
         -X main.goVersion=${stdenv.lib.getVersion go}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Kubernetes credential plugin implementing Azure authentication";
     inherit (src.meta) homepage;
     license = licenses.mit;
diff --git a/pkgs/applications/networking/cluster/kubernix/default.nix b/pkgs/applications/networking/cluster/kubernix/default.nix
index 2251b12e499ae..1411892b75b8a 100644
--- a/pkgs/applications/networking/cluster/kubernix/default.nix
+++ b/pkgs/applications/networking/cluster/kubernix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "kubernix";
@@ -14,7 +14,7 @@ rustPlatform.buildRustPackage rec {
   cargoSha256 = "17agwqx7nhzi124yq1s6zpqb227drrhp9c11r3jbicc08dz88bwg";
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Single dependency Kubernetes clusters for local testing, experimenting and development";
     homepage = "https://github.com/saschagrunert/kubernix";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/networking/cluster/linkerd/default.nix b/pkgs/applications/networking/cluster/linkerd/default.nix
index 63e4e59ff453b..8718da4624691 100644
--- a/pkgs/applications/networking/cluster/linkerd/default.nix
+++ b/pkgs/applications/networking/cluster/linkerd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 
 buildGoModule {
   pname = "linkerd-unstable";
@@ -17,7 +17,7 @@ buildGoModule {
 
   subPackages = [ "cli/cmd" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A service mesh for Kubernetes and beyond";
     homepage = "https://linkerd.io/";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/minikube/default.nix b/pkgs/applications/networking/cluster/minikube/default.nix
index 080cfc167daba..9acb5f319ca4c 100644
--- a/pkgs/applications/networking/cluster/minikube/default.nix
+++ b/pkgs/applications/networking/cluster/minikube/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , go-bindata
@@ -45,7 +45,7 @@ buildGoModule rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://minikube.sigs.k8s.io";
     description = "A tool that makes it easy to run Kubernetes locally";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/node-problem-detector/default.nix b/pkgs/applications/networking/cluster/node-problem-detector/default.nix
index 61f0feced959b..370a86db0e6c9 100644
--- a/pkgs/applications/networking/cluster/node-problem-detector/default.nix
+++ b/pkgs/applications/networking/cluster/node-problem-detector/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, systemd }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, systemd }:
 
 buildGoModule rec {
   pname = "node-problem-detector";
@@ -36,7 +36,7 @@ buildGoModule rec {
     "-X k8s.io/${pname}/pkg/version.version=v${version}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Various problem detectors running on the Kubernetes nodes";
     homepage = "https://github.com/kubernetes/node-problem-detector";
     changelog = "https://github.com/kubernetes/node-problem-detector/releases/tag/v${version}";
diff --git a/pkgs/applications/networking/cluster/octant/default.nix b/pkgs/applications/networking/cluster/octant/default.nix
index 4ccc05189c9ee..4eb2bf78b54ae 100644
--- a/pkgs/applications/networking/cluster/octant/default.nix
+++ b/pkgs/applications/networking/cluster/octant/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 let
   version = "0.16.3";
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     mv octant $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Highly extensible platform for developers to better understand the complexity of Kubernetes clusters.";
     longDescription = ''
       Octant is a tool for developers to understand how applications run on a Kubernetes cluster.
diff --git a/pkgs/applications/networking/cluster/openshift/default.nix b/pkgs/applications/networking/cluster/openshift/default.nix
index 34d362a4623b0..ef9e6c74220a1 100644
--- a/pkgs/applications/networking/cluster/openshift/default.nix
+++ b/pkgs/applications/networking/cluster/openshift/default.nix
@@ -67,7 +67,7 @@ in buildGoPackage rec {
     installShellCompletion --zsh contrib/completions/zsh/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Build, deploy, and manage your applications with Docker and Kubernetes";
     license = licenses.asl20;
     homepage = "http://www.openshift.org";
diff --git a/pkgs/applications/networking/cluster/pig/default.nix b/pkgs/applications/networking/cluster/pig/default.nix
index afcd736e629c6..2a2c2c4372248 100644
--- a/pkgs/applications/networking/cluster/pig/default.nix
+++ b/pkgs/applications/networking/cluster/pig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, hadoop, jre, bash }:
+{ lib, stdenv, fetchurl, makeWrapper, hadoop, jre, bash }:
 
 stdenv.mkDerivation rec {
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pig.apache.org/";
     description = "High-level language for Apache Hadoop";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/popeye/default.nix b/pkgs/applications/networking/cluster/popeye/default.nix
index 6e7eccac20635..650532ae8b96f 100644
--- a/pkgs/applications/networking/cluster/popeye/default.nix
+++ b/pkgs/applications/networking/cluster/popeye/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "popeye";
@@ -23,7 +23,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Kubernetes cluster resource sanitizer";
     homepage = "https://github.com/derailed/popeye";
     changelog = "https://github.com/derailed/popeye/releases/tag/v${version}";
diff --git a/pkgs/applications/networking/cluster/ssm-agent/default.nix b/pkgs/applications/networking/cluster/ssm-agent/default.nix
index c6f9217b35b88..80c8244bee1b9 100644
--- a/pkgs/applications/networking/cluster/ssm-agent/default.nix
+++ b/pkgs/applications/networking/cluster/ssm-agent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage, bash, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage, bash, makeWrapper }:
 
 buildGoPackage rec {
   pname   = "amazon-ssm-agent";
@@ -53,7 +53,7 @@ buildGoPackage rec {
     wrapProgram $out/bin/amazon-ssm-agent --prefix PATH : ${bash}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Agent to enable remote management of your Amazon EC2 instance configuration";
     homepage    = "https://github.com/aws/amazon-ssm-agent";
     license     = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/terraform-inventory/default.nix b/pkgs/applications/networking/cluster/terraform-inventory/default.nix
index 72e717d916623..7b9bf354af755 100644
--- a/pkgs/applications/networking/cluster/terraform-inventory/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-inventory/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub}:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub}:
 
 buildGoPackage rec {
   pname = "terraform-inventory";
@@ -18,7 +18,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/adammck/terraform-inventory";
     description = "Terraform state to ansible inventory adapter";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/ansible/default.nix b/pkgs/applications/networking/cluster/terraform-providers/ansible/default.nix
index bb634a78e23cf..14d411c023963 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/ansible/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/ansible/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage }:
 buildGoPackage rec {
   pname = "terraform-provider-ansible";
   version = "1.0.3";
@@ -17,7 +17,7 @@ buildGoPackage rec {
   # if the versions are not provided via file paths.
   postBuild = "mv go/bin/terraform-provider-ansible{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Terraform provider serving as an interop layer for an Ansible dynamic inventory script.";
     homepage = "https://github.com/nbering/terraform-provider-ansible";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/cloudfoundry/default.nix b/pkgs/applications/networking/cluster/terraform-providers/cloudfoundry/default.nix
index 7e807d2ed5ce7..0528bce81e3ca 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/cloudfoundry/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/cloudfoundry/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "terraform-provider-cloudfoundry";
@@ -20,7 +20,7 @@ buildGoModule rec {
 
   passthru = { provider-source-address = "registry.terraform.io/cloudfoundry-community/cloudfoundry"; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cloudfoundry-community/terraform-provider-cloudfoundry";
     description = "Terraform provider for cloudfoundry";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/elasticsearch/default.nix b/pkgs/applications/networking/cluster/terraform-providers/elasticsearch/default.nix
index 6eaaa05106d12..47e4f30d00927 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/elasticsearch/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/elasticsearch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 buildGoModule rec {
   pname = "terraform-provider-elasticsearch";
   version = "0.7.0";
@@ -20,7 +20,7 @@ buildGoModule rec {
   # if the versions are not provided via file paths.
   postInstall = "mv $out/bin/terraform-provider-elasticsearch{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terraform provider for elasticsearch";
     homepage = "https://github.com/phillbaker/terraform-provider-elasticsearch";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/gandi/default.nix b/pkgs/applications/networking/cluster/terraform-providers/gandi/default.nix
index 4571d368991fa..fe508f4fa2ef6 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/gandi/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/gandi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage }:
 buildGoPackage rec {
   pname = "terraform-provider-gandi";
   version = "1.0.0";
@@ -17,7 +17,7 @@ buildGoPackage rec {
   # if the versions are not provided via file paths.
   postBuild = "mv go/bin/terraform-provider-gandi{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terraform provider for the Gandi LiveDNS service.";
     homepage = "https://github.com/tiramiseb/terraform-provider-gandi";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/hcloud/default.nix b/pkgs/applications/networking/cluster/terraform-providers/hcloud/default.nix
index 89a22c718efb1..97331e683efb8 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/hcloud/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/hcloud/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "terraform-provider-hcloud";
@@ -23,7 +23,7 @@ buildGoModule rec {
 
   postInstall = "mv $out/bin/terraform-provider-hcloud{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cloudfoundry-community/terraform-provider-cloudfoundry";
     description = "Terraform provider for cloudfoundry";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/keycloak/default.nix b/pkgs/applications/networking/cluster/terraform-providers/keycloak/default.nix
index 7e9a9b830082f..f2244345a9c3f 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/keycloak/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/keycloak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildGoModule
 }:
@@ -20,7 +20,7 @@ buildGoModule rec {
 
   postInstall = "mv $out/bin/terraform-provider-keycloak{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terraform provider for keycloak";
     homepage = "https://github.com/mrparkers/terraform-provider-keycloak";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/libvirt/default.nix b/pkgs/applications/networking/cluster/terraform-providers/libvirt/default.nix
index 4662a315a8c46..3caab38a3ef74 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/libvirt/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/libvirt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, libvirt, pkgconfig, makeWrapper, cdrtools }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, libvirt, pkgconfig, makeWrapper, cdrtools }:
 
 # USAGE:
 # install the following package globally or in nix-shell:
@@ -42,7 +42,7 @@ buildGoPackage rec {
   # if the versions are not provided via file paths.
   postBuild = "mv go/bin/terraform-provider-libvirt{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dmacvicar/terraform-provider-libvirt";
     description = "Terraform provider for libvirt";
     platforms = platforms.linux;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/linuxbox/default.nix b/pkgs/applications/networking/cluster/terraform-providers/linuxbox/default.nix
index 60cd7f2d7637b..f445d48eaee2d 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/linuxbox/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/linuxbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "terraform-provider-linuxbox";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.provider-source-address = "registry.terraform.io/numtide/linuxbox";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/numtide/terraform-provider-linuxbox";
     description = "Basic building block for Seed DevOps";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/lxd/default.nix b/pkgs/applications/networking/cluster/terraform-providers/lxd/default.nix
index a583bc3351421..6ccc551b4d31d 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/lxd/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/lxd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "terraform-provider-lxd";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   postBuild = "mv ../go/bin/terraform-provider-lxd{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sl1pm4t/terraform-provider-lxd";
     description = "Terraform provider for lxd";
     platforms = platforms.linux;
diff --git a/pkgs/applications/networking/cluster/terraform-providers/shell/default.nix b/pkgs/applications/networking/cluster/terraform-providers/shell/default.nix
index c0ee431fa4057..4833a96778848 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/shell/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 buildGoModule rec {
   pname = "terraform-provider-shell";
   version = "1.6.0";
@@ -20,7 +20,7 @@ buildGoModule rec {
   # if the versions are not provided via file paths.
   postInstall = "mv $out/bin/${pname}{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Terraform provider for executing shell commands and saving output to state file";
     changelog = "https://github.com/scottwinkler/terraform-provider-shell/releases/tag/v${version}";
diff --git a/pkgs/applications/networking/cluster/terraform-providers/vercel/default.nix b/pkgs/applications/networking/cluster/terraform-providers/vercel/default.nix
index b4e17aabb45b6..f4cfe6ba02f7a 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/vercel/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/vercel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "terraform-provider-vercel";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   postInstall = "mv $out/bin/terraform-provider-vercel{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ondrejsika/terraform-provider-vercel";
     description = "Terraform provider for Vercel";
     maintainers = with maintainers; [ mmahut ];
diff --git a/pkgs/applications/networking/cluster/terraform-providers/vpsadmin/default.nix b/pkgs/applications/networking/cluster/terraform-providers/vpsadmin/default.nix
index a4167d2b099ef..4f56070fa51cf 100644
--- a/pkgs/applications/networking/cluster/terraform-providers/vpsadmin/default.nix
+++ b/pkgs/applications/networking/cluster/terraform-providers/vpsadmin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 buildGoModule rec {
   pname = "terraform-provider-vpsadmin";
   version = "0.1.0";
@@ -20,7 +20,7 @@ buildGoModule rec {
   # if the versions are not provided via file paths.
   postInstall = "mv $out/bin/${pname}{,_v${version}}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terraform provider for vpsAdmin";
     homepage = "https://github.com/vpsfreecz/terraform-provider-vpsadmin";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/cluster/terraform/default.nix b/pkgs/applications/networking/cluster/terraform/default.nix
index b9f15e21f3231..a190994e74696 100644
--- a/pkgs/applications/networking/cluster/terraform/default.nix
+++ b/pkgs/applications/networking/cluster/terraform/default.nix
@@ -38,7 +38,7 @@ let
 
       subPackages = [ "." ];
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description =
           "Tool for building, changing, and versioning infrastructure";
         homepage = "https://www.terraform.io/";
diff --git a/pkgs/applications/networking/cluster/terranix/default.nix b/pkgs/applications/networking/cluster/terranix/default.nix
index 1954f867eb0ea..89a96cc12ca55 100644
--- a/pkgs/applications/networking/cluster/terranix/default.nix
+++ b/pkgs/applications/networking/cluster/terranix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ... }:
+{ lib, stdenv, fetchFromGitHub, ... }:
 
 stdenv.mkDerivation rec {
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     mv bin core modules lib $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A NixOS like terraform-json generator";
     homepage = "https://terranix.org";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/cluster/tilt/default.nix b/pkgs/applications/networking/cluster/tilt/default.nix
index 42de638ec42cf..9f2a223c4486d 100644
--- a/pkgs/applications/networking/cluster/tilt/default.nix
+++ b/pkgs/applications/networking/cluster/tilt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "tilt";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-X main.version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Local development tool to manage your developer instance when your team deploys to Kubernetes in production";
     homepage = "https://tilt.dev/";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/cluster/velero/default.nix b/pkgs/applications/networking/cluster/velero/default.nix
index 45cae94ec850f..ec95b090c2e52 100644
--- a/pkgs/applications/networking/cluster/velero/default.nix
+++ b/pkgs/applications/networking/cluster/velero/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
 
 buildGoModule rec {
   pname = "velero";
@@ -32,7 +32,7 @@ buildGoModule rec {
     installShellCompletion velero.{bash,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "A utility for managing disaster recovery, specifically for your Kubernetes cluster resources and persistent volumes";
     homepage = "https://velero.io/";
diff --git a/pkgs/applications/networking/compactor/default.nix b/pkgs/applications/networking/compactor/default.nix
index ed04e90bcdecf..96b8b6933d857 100644
--- a/pkgs/applications/networking/compactor/default.nix
+++ b/pkgs/applications/networking/compactor/default.nix
@@ -1,5 +1,5 @@
 { autoconf, automake, boost, cbor-diag, cddl, fetchFromGitHub, file, libctemplate, libmaxminddb
-, libpcap, libtins, libtool, lzma, openssl, pkgconfig, stdenv, tcpdump, wireshark-cli
+, libpcap, libtins, libtool, lzma, openssl, pkgconfig, lib, stdenv, tcpdump, wireshark-cli
 }:
 
 stdenv.mkDerivation rec {
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     rm test-scripts/same-tshark-output.sh
   ''; # TODO: https://github.com/dns-stats/compactor/issues/49  (failing test)
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools to capture DNS traffic and record it in C-DNS files";
     homepage    = "http://dns-stats.org/";
     changelog   = "https://github.com/dns-stats/${pname}/raw/${version}/ChangeLog.txt";
diff --git a/pkgs/applications/networking/datovka/default.nix b/pkgs/applications/networking/datovka/default.nix
index 22bf982ec4cc3..ca675dd7836c0 100644
--- a/pkgs/applications/networking/datovka/default.nix
+++ b/pkgs/applications/networking/datovka/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchurl
 , libxml2
@@ -22,7 +22,7 @@ mkDerivation rec {
 
   nativeBuildInputs = [ pkg-config ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client application for operating Czech government-provided Databox infomation system";
     homepage = "https://www.datovka.cz/";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/networking/davmail/default.nix b/pkgs/applications/networking/davmail/default.nix
index 38a08aaf4c067..bbb27672a7d24 100644
--- a/pkgs/applications/networking/davmail/default.nix
+++ b/pkgs/applications/networking/davmail/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, jre, glib, libXtst, gtk2, makeWrapper, unzip }:
+{ fetchurl, lib, stdenv, jre, glib, libXtst, gtk2, makeWrapper, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "davmail";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : ${stdenv.lib.makeLibraryPath [ glib gtk2 libXtst ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://davmail.sourceforge.net/";
     description = "A Java application which presents a Microsoft Exchange server as local CALDAV, IMAP and SMTP servers";
     maintainers = [ maintainers.hinton ];
diff --git a/pkgs/applications/networking/dsvpn/default.nix b/pkgs/applications/networking/dsvpn/default.nix
index 04d3887bf4ed9..f165e6a59942d 100644
--- a/pkgs/applications/networking/dsvpn/default.nix
+++ b/pkgs/applications/networking/dsvpn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "dsvpn";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Dead Simple VPN";
     homepage = "https://github.com/jedisct1/dsvpn";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/dyndns/cfdyndns/default.nix b/pkgs/applications/networking/dyndns/cfdyndns/default.nix
index 60a7e5b2fb215..cedfcbdb5d1dd 100644
--- a/pkgs/applications/networking/dyndns/cfdyndns/default.nix
+++ b/pkgs/applications/networking/dyndns/cfdyndns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl }:
 
 with rustPlatform;
 
@@ -22,7 +22,7 @@ buildRustPackage rec {
     cp -p $releaseDir/cfdyndns $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CloudFlare Dynamic DNS Client";
     homepage = "https://github.com/colemickens/cfdyndns";
     license = stdenv.lib.licenses.mit;
diff --git a/pkgs/applications/networking/esniper/default.nix b/pkgs/applications/networking/esniper/default.nix
index 0282483df8dc5..4c1b2bbea04fa 100644
--- a/pkgs/applications/networking/esniper/default.nix
+++ b/pkgs/applications/networking/esniper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, openssl, curl, coreutils, gawk, bash, which }:
+{ lib, stdenv, fetchgit, openssl, curl, coreutils, gawk, bash, which }:
 
 stdenv.mkDerivation {
   name = "esniper-2.35.0-21-g6379846";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     chmod 555 "$out/bin/snipe"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple, lightweight tool for sniping eBay auctions";
     homepage    = "http://esniper.sourceforge.net";
     license     = licenses.gpl2;
diff --git a/pkgs/applications/networking/feedreaders/canto-daemon/default.nix b/pkgs/applications/networking/feedreaders/canto-daemon/default.nix
index 2992f28c58a0b..a67e0c3aed2be 100644
--- a/pkgs/applications/networking/feedreaders/canto-daemon/default.nix
+++ b/pkgs/applications/networking/feedreaders/canto-daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, }:
 
 python3Packages.buildPythonApplication rec {
   version = "0.9.8";
@@ -17,7 +17,7 @@ python3Packages.buildPythonApplication rec {
 
   pythonImportsCheck = [ "canto_next" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon for the canto Atom/RSS feed reader";
     longDescription = ''
       Canto is an Atom/RSS feed reader for the console that is meant to be
diff --git a/pkgs/applications/networking/feedreaders/castget/default.nix b/pkgs/applications/networking/feedreaders/castget/default.nix
index 33f8d8ca23836..6aec4540147f3 100644
--- a/pkgs/applications/networking/feedreaders/castget/default.nix
+++ b/pkgs/applications/networking/feedreaders/castget/default.nix
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     pkgconfig
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple, command-line based RSS enclosure downloader";
     longDescription = ''
       castget is a simple, command-line based RSS enclosure downloader. It is
diff --git a/pkgs/applications/networking/feedreaders/feedreader/default.nix b/pkgs/applications/networking/feedreaders/feedreader/default.nix
index d050b75ac30a1..2df2b9ce786a3 100644
--- a/pkgs/applications/networking/feedreaders/feedreader/default.nix
+++ b/pkgs/applications/networking/feedreaders/feedreader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nix-update-script, meson, ninja, pkgconfig, vala, gettext, python3
+{ lib, stdenv, fetchFromGitHub, nix-update-script, meson, ninja, pkgconfig, vala, gettext, python3
 , appstream-glib, desktop-file-utils, wrapGAppsHook, gnome-online-accounts
 , gtk3, libgee, libpeas, librest, webkitgtk, gsettings-desktop-schemas, pantheon
 , curl, glib, gnome3, gst_all_1, json-glib, libnotify, libsecret, sqlite, gumbo, libxml2
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern desktop application designed to complement existing web-based RSS accounts";
     homepage = "https://jangernert.github.io/FeedReader/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/feedreaders/newsboat/default.nix b/pkgs/applications/networking/feedreaders/newsboat/default.nix
index 3b8f6e0a0562c..448590fbf1165 100644
--- a/pkgs/applications/networking/feedreaders/newsboat/default.nix
+++ b/pkgs/applications/networking/feedreaders/newsboat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, stfl, sqlite, curl, gettext, pkg-config, libxml2, json_c, ncurses
+{ lib, stdenv, rustPlatform, fetchFromGitHub, stfl, sqlite, curl, gettext, pkg-config, libxml2, json_c, ncurses
 , asciidoctor, libiconv, Security, Foundation, makeWrapper }:
 
 rustPlatform.buildRustPackage rec {
@@ -63,7 +63,7 @@ rustPlatform.buildRustPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://newsboat.org/";
     description = "A fork of Newsbeuter, an RSS/Atom feed reader for the text console";
     maintainers = with maintainers; [ dotlambda nicknovitski ];
diff --git a/pkgs/applications/networking/feedreaders/rawdog/default.nix b/pkgs/applications/networking/feedreaders/rawdog/default.nix
index 9435d995c351e..d24e0fbf71709 100644
--- a/pkgs/applications/networking/feedreaders/rawdog/default.nix
+++ b/pkgs/applications/networking/feedreaders/rawdog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python2Packages }:
+{ lib, stdenv, fetchurl, python2Packages }:
 
 python2Packages.buildPythonApplication rec {
   pname = "rawdog";
@@ -17,7 +17,7 @@ python2Packages.buildPythonApplication rec {
 
   namePrefix = "";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://offog.org/code/rawdog/";
     description = "RSS Aggregator Without Delusions Of Grandeur";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/feedreaders/rssguard/default.nix b/pkgs/applications/networking/feedreaders/rssguard/default.nix
index 13dc38aaba936..93b7c62ad9620 100644
--- a/pkgs/applications/networking/feedreaders/rssguard/default.nix
+++ b/pkgs/applications/networking/feedreaders/rssguard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qmake, qtwebengine, qttools, wrapGAppsHook, wrapQtAppsHook }:
+{ lib, stdenv, fetchFromGitHub, qmake, qtwebengine, qttools, wrapGAppsHook, wrapQtAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "rssguard";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ qmake wrapGAppsHook wrapQtAppsHook ];
   qmakeFlags = [ "CONFIG+=release" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple RSS/Atom feed reader with online synchronization";
     longDescription = ''
       RSS Guard is a simple, light and easy-to-use RSS/ATOM feed aggregator
diff --git a/pkgs/applications/networking/feedreaders/rsstail/default.nix b/pkgs/applications/networking/feedreaders/rsstail/default.nix
index 66228efe89528..f83c911175513 100644
--- a/pkgs/applications/networking/feedreaders/rsstail/default.nix
+++ b/pkgs/applications/networking/feedreaders/rsstail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cppcheck, libmrss, libiconv }:
+{ lib, stdenv, fetchFromGitHub, cppcheck, libmrss, libiconv }:
 
 stdenv.mkDerivation {
   pname = "rsstail";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Monitor RSS feeds for new entries";
     longDescription = ''
       RSSTail is more or less an RSS reader: it monitors an RSS feed and if it
diff --git a/pkgs/applications/networking/firehol/default.nix b/pkgs/applications/networking/firehol/default.nix
index 83f4d267f9591..904fd90e102e7 100644
--- a/pkgs/applications/networking/firehol/default.nix
+++ b/pkgs/applications/networking/firehol/default.nix
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
                      "--disable-doc" "--disable-man" ] ++
                    lib.optional onlyQOS [ "--disable-firehol" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A firewall for humans";
     longDescription = ''
       FireHOL, an iptables stateful packet filtering firewall for humans!
diff --git a/pkgs/applications/networking/firehol/iprange.nix b/pkgs/applications/networking/firehol/iprange.nix
index 75b4d5b40a6b2..7dc43d5c116c8 100644
--- a/pkgs/applications/networking/firehol/iprange.nix
+++ b/pkgs/applications/networking/firehol/iprange.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "iprange";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0rymw4ydn09dng34q4g5111706fyppzs2gd5br76frgvfj4x2f71";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "manage IP ranges";
     homepage = "https://github.com/firehol/iprange";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/flent/default.nix b/pkgs/applications/networking/flent/default.nix
index 319630ceff35e..5f9350b70cd8b 100644
--- a/pkgs/applications/networking/flent/default.nix
+++ b/pkgs/applications/networking/flent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchPypi, matplotlib, procps, pyqt5, python
+{ lib, stdenv, buildPythonApplication, fetchPypi, matplotlib, procps, pyqt5, python
 , pythonPackages, qt5, sphinx, xvfb_run }:
 
 buildPythonApplication rec {
@@ -29,7 +29,7 @@ buildPythonApplication rec {
     makeWrapperArgs+=("''${qtWrapperArgs[@]}")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The FLExible Network Tester";
     homepage = "https://flent.org";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/flent/http-getter.nix b/pkgs/applications/networking/flent/http-getter.nix
index 2967c4e535fe2..21c9d3ca6fb10 100644
--- a/pkgs/applications/networking/flent/http-getter.nix
+++ b/pkgs/applications/networking/flent/http-getter.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, curl, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, cmake, curl, pkg-config }:
 
 stdenv.mkDerivation {
   pname = "http-getter";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ cmake pkg-config ];
   buildInputs = [ curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tohojo/http-getter";
     description = "Simple getter for HTTP URLs using cURL";
     platforms = platforms.unix;
diff --git a/pkgs/applications/networking/ftp/filezilla/default.nix b/pkgs/applications/networking/ftp/filezilla/default.nix
index 17306059e996e..a24105f8315e3 100644
--- a/pkgs/applications/networking/ftp/filezilla/default.nix
+++ b/pkgs/applications/networking/ftp/filezilla/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , autoreconfHook
 , dbus
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://filezilla-project.org/";
     description = "Graphical FTP, FTPS and SFTP client";
     longDescription = ''
diff --git a/pkgs/applications/networking/ftp/taxi/default.nix b/pkgs/applications/networking/ftp/taxi/default.nix
index c629a8a07cd8e..335b94cd2f431 100644
--- a/pkgs/applications/networking/ftp/taxi/default.nix
+++ b/pkgs/applications/networking/ftp/taxi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nix-update-script, pantheon, pkgconfig, meson, ninja, python3, vala
+{ lib, stdenv, fetchFromGitHub, nix-update-script, pantheon, pkgconfig, meson, ninja, python3, vala
 , gtk3, libgee, libsoup, libsecret, gobject-introspection, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The FTP Client that drives you anywhere";
     homepage    = "https://github.com/Alecaddd/taxi";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/gdrive/default.nix b/pkgs/applications/networking/gdrive/default.nix
index c5a5d1e970a6d..b51512332c5aa 100644
--- a/pkgs/applications/networking/gdrive/default.nix
+++ b/pkgs/applications/networking/gdrive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gdrive";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     inherit rev;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/prasmussen/gdrive";
     description = "A command line utility for interacting with Google Drive";
     platforms   = platforms.unix;
diff --git a/pkgs/applications/networking/gmailctl/default.nix b/pkgs/applications/networking/gmailctl/default.nix
index a32da469719be..30a25dc9f70d3 100644
--- a/pkgs/applications/networking/gmailctl/default.nix
+++ b/pkgs/applications/networking/gmailctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 }:
@@ -18,7 +18,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Declarative configuration for Gmail filters";
     homepage = "https://github.com/mbrt/gmailctl";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/gnome-network-displays/default.nix b/pkgs/applications/networking/gnome-network-displays/default.nix
index 80fbb6dd6e747..5a865fddb5944 100644
--- a/pkgs/applications/networking/gnome-network-displays/default.nix
+++ b/pkgs/applications/networking/gnome-network-displays/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 # native
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
     patchShebangs ./build-aux/meson/postinstall.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/GNOME/gnome-network-displays";
     description = "Miracast implementation for GNOME";
     maintainers = with maintainers; [ doronbehar ];
diff --git a/pkgs/applications/networking/gns3/server.nix b/pkgs/applications/networking/gns3/server.nix
index ad346104f969b..c2ca0f580c353 100644
--- a/pkgs/applications/networking/gns3/server.nix
+++ b/pkgs/applications/networking/gns3/server.nix
@@ -53,7 +53,7 @@ in python.pkgs.buildPythonPackage {
     rm $out/bin/gns3loopback # For Windows only
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical Network Simulator 3 server (${branch} release)";
     longDescription = ''
       The GNS3 server manages emulators such as Dynamips, VirtualBox or
diff --git a/pkgs/applications/networking/gopher/gopher/default.nix b/pkgs/applications/networking/gopher/gopher/default.nix
index 4e57163864427..09b8f8aafcb31 100644
--- a/pkgs/applications/networking/gopher/gopher/default.nix
+++ b/pkgs/applications/networking/gopher/gopher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "gopher";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "export LIBS=-lncurses";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gopher.quux.org:70/devel/gopher";
     description = "A ncurses gopher client";
     platforms = platforms.linux; # clang doesn't like local regex.h
diff --git a/pkgs/applications/networking/gopher/sacc/default.nix b/pkgs/applications/networking/gopher/sacc/default.nix
index e10d97aeb42bf..a3ead49c69f30 100644
--- a/pkgs/applications/networking/gopher/sacc/default.nix
+++ b/pkgs/applications/networking/gopher/sacc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses
+{ lib, stdenv, fetchurl, ncurses
 , patches ? [] # allow users to easily override config.def.h
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       --replace "/usr/local" "$out"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A terminal gopher client";
     homepage = "gopher://bitreich.org/1/scm/sacc";
     license = licenses.isc;
diff --git a/pkgs/applications/networking/ids/suricata/default.nix b/pkgs/applications/networking/ids/suricata/default.nix
index d6e9b2e743973..40dbbddbb3e36 100644
--- a/pkgs/applications/networking/ids/suricata/default.nix
+++ b/pkgs/applications/networking/ids/suricata/default.nix
@@ -148,7 +148,7 @@ stdenv.mkDerivation rec {
       --replace "/etc/suricata" "$out/etc/suricata"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free and open source, mature, fast and robust network threat detection engine";
     homepage = "https://suricata-ids.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/ids/zeek/default.nix b/pkgs/applications/networking/ids/zeek/default.nix
index 8fa3a86e5c01e..dc8fde4c6ca12 100644
--- a/pkgs/applications/networking/ids/zeek/default.nix
+++ b/pkgs/applications/networking/ids/zeek/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cmake
 , flex
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     "-DINSTALL_AUX_TOOLS=true"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful network analysis framework much different from a typical IDS";
     homepage = "https://www.zeek.org";
     changelog = "https://github.com/zeek/zeek/blob/v${version}/CHANGES";
diff --git a/pkgs/applications/networking/ike/default.nix b/pkgs/applications/networking/ike/default.nix
index 93858ba3027ce..405827d8c5df1 100644
--- a/pkgs/applications/networking/ike/default.nix
+++ b/pkgs/applications/networking/ike/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, cmake, openssl, libedit, flex, bison, qt4, makeWrapper
+{ lib, stdenv, fetchurl, fetchpatch, cmake, openssl, libedit, flex, bison, qt4, makeWrapper
 , gcc, nettools, iproute, linuxHeaders }:
 
 # NOTE: use $out/etc/iked.conf as sample configuration and also set: dhcp_file "/etc/iked.dhcp";
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.shrew.net/software";
     description = "IPsec Client for FreeBSD, NetBSD and many Linux based operating systems";
     platforms = platforms.unix;
diff --git a/pkgs/applications/networking/instant-messengers/SkypeExport/default.nix b/pkgs/applications/networking/instant-messengers/SkypeExport/default.nix
index f5ec3d7b6bd04..bab9d12123df6 100644
--- a/pkgs/applications/networking/instant-messengers/SkypeExport/default.nix
+++ b/pkgs/applications/networking/instant-messengers/SkypeExport/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, boost166 }:
+{ lib, stdenv, fetchFromGitHub, cmake, boost166 }:
 
 stdenv.mkDerivation rec {
   pname = "SkypeExport";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   preConfigure = "cd src/SkypeExport/_gccbuild/linux";
   installPhase = "install -Dt $out/bin SkypeExport";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Export Skype history to HTML";
     homepage = "https://github.com/Temptin/SkypeExport";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/blink/default.nix b/pkgs/applications/networking/instant-messengers/blink/default.nix
index 28cc383605769..9dd6754af0cb1 100644
--- a/pkgs/applications/networking/instant-messengers/blink/default.nix
+++ b/pkgs/applications/networking/instant-messengers/blink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchdarcs, pythonPackages, libvncserver, zlib
+{ lib, stdenv, fetchdarcs, pythonPackages, libvncserver, zlib
 , gnutls, libvpx, makeDesktopItem, mkDerivationWith }:
 
 mkDerivationWith pythonPackages.buildPythonApplication rec {
@@ -58,7 +58,7 @@ mkDerivationWith pythonPackages.buildPythonApplication rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://icanblink.com/";
     description = "A state of the art, easy to use SIP client for Voice, Video and IM";
     platforms = platforms.linux;
diff --git a/pkgs/applications/networking/instant-messengers/bluejeans/default.nix b/pkgs/applications/networking/instant-messengers/bluejeans/default.nix
index 5e3f0bdb5d63a..cce3a7edd792d 100644
--- a/pkgs/applications/networking/instant-messengers/bluejeans/default.nix
+++ b/pkgs/applications/networking/instant-messengers/bluejeans/default.nix
@@ -116,7 +116,7 @@ stdenv.mkDerivation rec {
     patchShebangs "$out"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Video, audio, and web conferencing that works together with the collaboration tools you use every day";
     homepage = "https://www.bluejeans.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/instant-messengers/cordless/default.nix b/pkgs/applications/networking/instant-messengers/cordless/default.nix
index d3633e2245ff6..5d95eddb6b630 100644
--- a/pkgs/applications/networking/instant-messengers/cordless/default.nix
+++ b/pkgs/applications/networking/instant-messengers/cordless/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "cordless";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   vendorSha256 = "01anbhwgwam70dymcmvkia1xpw48658rq7wv4m7fiavxvnli6z2y";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Bios-Marcel/cordless";
     description = "Discord terminal client";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/instant-messengers/coyim/default.nix b/pkgs/applications/networking/instant-messengers/coyim/default.nix
index 67c2a0db2372a..d16ad19428fc6 100644
--- a/pkgs/applications/networking/instant-messengers/coyim/default.nix
+++ b/pkgs/applications/networking/instant-messengers/coyim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, pkgconfig,
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, pkgconfig,
   cairo, gdk-pixbuf, glib, gnome3, wrapGAppsHook, gtk3 }:
 
 buildGoPackage rec {
@@ -18,7 +18,7 @@ buildGoPackage rec {
 
   buildInputs = [ glib cairo gdk-pixbuf gtk3 gnome3.adwaita-icon-theme ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a safe and secure chat client";
     homepage = "https://coy.im/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/dino/default.nix b/pkgs/applications/networking/instant-messengers/dino/default.nix
index 03508c2ffb53e..8e6725d6067f5 100644
--- a/pkgs/applications/networking/instant-messengers/dino/default.nix
+++ b/pkgs/applications/networking/instant-messengers/dino/default.nix
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern Jabber/XMPP Client using GTK/Vala";
     homepage = "https://github.com/dino/dino";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/discord/base.nix b/pkgs/applications/networking/instant-messengers/discord/base.nix
index 46c0cbef669eb..72fb92b9d7cdd 100644
--- a/pkgs/applications/networking/instant-messengers/discord/base.nix
+++ b/pkgs/applications/networking/instant-messengers/discord/base.nix
@@ -1,5 +1,5 @@
 { pname, version, src, binaryName, desktopName
-, autoPatchelfHook, fetchurl, makeDesktopItem, stdenv, wrapGAppsHook
+, autoPatchelfHook, fetchurl, makeDesktopItem, lib, stdenv, wrapGAppsHook
 , alsaLib, at-spi2-atk, at-spi2-core, atk, cairo, cups, dbus, expat, fontconfig
 , freetype, gdk-pixbuf, glib, gtk3, libcxx, libdrm, libnotify, libpulseaudio, libuuid
 , libX11, libXScrnSaver, libXcomposite, libXcursor, libXdamage, libXext
@@ -69,7 +69,7 @@ in stdenv.mkDerivation rec {
 
   passthru.updateScript = ./update-discord.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "All-in-one cross-platform voice and text chat for gamers";
     homepage = "https://discordapp.com/";
     downloadPage = "https://discordapp.com/download";
diff --git a/pkgs/applications/networking/instant-messengers/element/element-desktop.nix b/pkgs/applications/networking/instant-messengers/element/element-desktop.nix
index b6dfac397a111..1b2cd7d598aa1 100644
--- a/pkgs/applications/networking/instant-messengers/element/element-desktop.nix
+++ b/pkgs/applications/networking/instant-messengers/element/element-desktop.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , makeWrapper, makeDesktopItem, mkYarnPackage
 , electron_9, element-web
 }:
@@ -72,7 +72,7 @@ in mkYarnPackage rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A feature-rich client for Matrix.org";
     homepage = "https://element.io/";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/instant-messengers/ferdi/default.nix b/pkgs/applications/networking/instant-messengers/ferdi/default.nix
index 190050d8327b3..458808c832da9 100644
--- a/pkgs/applications/networking/instant-messengers/ferdi/default.nix
+++ b/pkgs/applications/networking/instant-messengers/ferdi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkFranzDerivation, fetchurl }:
+{ lib, stdenv, mkFranzDerivation, fetchurl }:
 
 mkFranzDerivation rec {
   pname = "ferdi";
@@ -8,7 +8,7 @@ mkFranzDerivation rec {
     url = "https://github.com/getferdi/ferdi/releases/download/v${version}/ferdi_${version}_amd64.deb";
     sha256 = "0i24vcnq4iz5amqmn2fgk92ff9x9y7fg8jhc3g6ksvmcfly7af3k";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Combine your favorite messaging services into one application";
     homepage = "https://getferdi.com/";
     license = licenses.free;
diff --git a/pkgs/applications/networking/instant-messengers/fractal/default.nix b/pkgs/applications/networking/instant-messengers/fractal/default.nix
index bc6dbc5ce1938..14cf45e97bbdf 100644
--- a/pkgs/applications/networking/instant-messengers/fractal/default.nix
+++ b/pkgs/applications/networking/instant-messengers/fractal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , nix-update-script
 , fetchpatch
@@ -88,7 +88,7 @@ rustPlatform.buildRustPackage rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Matrix group messaging app";
     homepage = "https://gitlab.gnome.org/GNOME/fractal";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/franz/default.nix b/pkgs/applications/networking/instant-messengers/franz/default.nix
index 646a790fed252..a72ff17abcd4e 100644
--- a/pkgs/applications/networking/instant-messengers/franz/default.nix
+++ b/pkgs/applications/networking/instant-messengers/franz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkFranzDerivation, fetchurl }:
+{ lib, stdenv, mkFranzDerivation, fetchurl }:
 
 mkFranzDerivation rec {
   pname = "franz";
@@ -8,7 +8,7 @@ mkFranzDerivation rec {
     url = "https://github.com/meetfranz/franz/releases/download/v${version}/franz_${version}_amd64.deb";
     sha256 = "1gn0n1hr6z2gsdnpxysyq6sm8y7cjr9jafhsam8ffw0bq74kph7p";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free messaging app that combines chat & messaging services into one application";
     homepage = "https://meetfranz.com";
     license = licenses.free;
diff --git a/pkgs/applications/networking/instant-messengers/freetalk/default.nix b/pkgs/applications/networking/instant-messengers/freetalk/default.nix
index e24ac2e18317b..2fe770e56ebfd 100644
--- a/pkgs/applications/networking/instant-messengers/freetalk/default.nix
+++ b/pkgs/applications/networking/instant-messengers/freetalk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , guile, pkgconfig, glib, loudmouth, gmp, libidn, readline, libtool
 , libunwind, ncurses, curl, jansson, texinfo
 , automake, autoconf }:
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     libunwind ncurses curl jansson
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =  "Console XMPP client";
     license = licenses.gpl3Plus ;
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/applications/networking/instant-messengers/gitter/default.nix b/pkgs/applications/networking/instant-messengers/gitter/default.nix
index 69a1984806680..42827d43f0db9 100644
--- a/pkgs/applications/networking/instant-messengers/gitter/default.nix
+++ b/pkgs/applications/networking/instant-messengers/gitter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, alsaLib, atk, at-spi2-core, cairo, cups, dbus, dpkg, expat, fetchurl
+{ lib, stdenv, alsaLib, atk, at-spi2-core, cairo, cups, dbus, dpkg, expat, fetchurl
 , fontconfig, freetype, gdk-pixbuf, glib, gnome2, gtk3,  libdrm, libX11
 , libXScrnSaver, libXcomposite, libXcursor, libXdamage, libXext, libXfixes
 , libXi, libXrandr, libXrender, libXtst, libappindicator-gtk3, libcxx
@@ -92,7 +92,7 @@ in stdenv.mkDerivation rec {
     categories = "Network;InstantMessaging;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Where developers come to talk";
     downloadPage = "https://gitter.im/apps";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/instant-messengers/gomuks/default.nix b/pkgs/applications/networking/instant-messengers/gomuks/default.nix
index 00134e2597be9..015e7fdbdf4b4 100644
--- a/pkgs/applications/networking/instant-messengers/gomuks/default.nix
+++ b/pkgs/applications/networking/instant-messengers/gomuks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, olm, makeDesktopItem }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, olm, makeDesktopItem }:
 
 buildGoModule rec {
   pname = "gomuks";
@@ -32,7 +32,7 @@ buildGoModule rec {
     substituteAllInPlace $out/share/applications/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://maunium.net/go/gomuks/";
     description = "A terminal based Matrix client written in Go";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/hipchat/default.nix b/pkgs/applications/networking/instant-messengers/hipchat/default.nix
index 63cbb69b187df..27e1fc0cad31c 100644
--- a/pkgs/applications/networking/instant-messengers/hipchat/default.nix
+++ b/pkgs/applications/networking/instant-messengers/hipchat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xorg, freetype, fontconfig, openssl, glib, nss, nspr, expat
+{ lib, stdenv, fetchurl, xorg, freetype, fontconfig, openssl, glib, nss, nspr, expat
 , alsaLib, dbus, zlib, libxml2, libxslt, makeWrapper, xkeyboard_config, systemd
 , libGL, xcbutilkeysyms, xdg_utils, libtool }:
 
@@ -78,7 +78,7 @@ in stdenv.mkDerivation {
       --set QT_PLUGIN_PATH "$d/plugins"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop client for HipChat services";
     homepage = "http://www.hipchat.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/instant-messengers/jitsi-meet-electron/default.nix b/pkgs/applications/networking/instant-messengers/jitsi-meet-electron/default.nix
index 4797bf5ffccbc..c23d081866baf 100644
--- a/pkgs/applications/networking/instant-messengers/jitsi-meet-electron/default.nix
+++ b/pkgs/applications/networking/instant-messengers/jitsi-meet-electron/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , appimageTools
 , makeWrapper
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [ stdenv.cc.cc ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jitsi Meet desktop application powered by Electron";
     homepage = "https://github.com/jitsi/jitsi-meet-electron";
     license = licenses.asl20;
diff --git a/pkgs/applications/networking/instant-messengers/jitsi/default.nix b/pkgs/applications/networking/instant-messengers/jitsi/default.nix
index 938be9a9778d8..137ad4d49b04b 100644
--- a/pkgs/applications/networking/instant-messengers/jitsi/default.nix
+++ b/pkgs/applications/networking/instant-messengers/jitsi/default.nix
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://jitsi.org/";
     description = "Open Source Video Calls and Chat";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/applications/networking/instant-messengers/mattermost-desktop/default.nix b/pkgs/applications/networking/instant-messengers/mattermost-desktop/default.nix
index 7e63161ff35a8..686e9c4769751 100644
--- a/pkgs/applications/networking/instant-messengers/mattermost-desktop/default.nix
+++ b/pkgs/applications/networking/instant-messengers/mattermost-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnome2, gtk3, pango, atk, cairo, gdk-pixbuf, glib,
+{ lib, stdenv, fetchurl, gnome2, gtk3, pango, atk, cairo, gdk-pixbuf, glib,
 freetype, fontconfig, dbus, libX11, xorg, libXi, libXcursor, libXdamage,
 libXrandr, libXcomposite, libXext, libXfixes, libXrender, libXtst,
 libXScrnSaver, nss, nspr, alsaLib, cups, expat, udev, wrapGAppsHook,
@@ -88,7 +88,7 @@ in
         $out/share/mattermost-desktop/mattermost-desktop
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Mattermost Desktop client";
       homepage    = "https://about.mattermost.com/";
       license     = licenses.asl20;
diff --git a/pkgs/applications/networking/instant-messengers/mcabber/default.nix b/pkgs/applications/networking/instant-messengers/mcabber/default.nix
index 23db7d1ce2570..8e5642855a39c 100644
--- a/pkgs/applications/networking/instant-messengers/mcabber/default.nix
+++ b/pkgs/applications/networking/instant-messengers/mcabber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, ncurses, pkgconfig, glib, loudmouth, libotr
+{ lib, stdenv, fetchurl, openssl, ncurses, pkgconfig, glib, loudmouth, libotr
 , gpgme
 }:
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mcabber.com/";
     description = "Small Jabber console client";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/mikutter/default.nix b/pkgs/applications/networking/instant-messengers/mikutter/default.nix
index 5c86157f50231..be84342787d23 100644
--- a/pkgs/applications/networking/instant-messengers/mikutter/default.nix
+++ b/pkgs/applications/networking/instant-messengers/mikutter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , bundlerEnv, ruby
 , alsaUtils, libnotify, which, wrapGAppsHook, gtk2, atk, gobject-introspection
 }:
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
       --replace "$out/bin/.mikutter-wrapped" "$out/mikutter.rb"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extensible Twitter client";
     homepage = "https://mikutter.hachune.net";
     platforms = ruby.meta.platforms;
diff --git a/pkgs/applications/networking/instant-messengers/mirage/default.nix b/pkgs/applications/networking/instant-messengers/mirage/default.nix
index decdb18aa0637..bcf3279d6a085 100644
--- a/pkgs/applications/networking/instant-messengers/mirage/default.nix
+++ b/pkgs/applications/networking/instant-messengers/mirage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub
+{ lib, stdenv, mkDerivation, fetchFromGitHub
 , qmake, pkgconfig, olm, wrapQtAppsHook
 , qtbase, qtquickcontrols2, qtkeychain, qtmultimedia, qttools, qtgraphicaleffects
 , python3Packages, pyotherside, libXScrnSaver
@@ -47,7 +47,7 @@ mkDerivation rec {
       "''${qtWrapperArgs[@]}"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fancy, customizable, keyboard-operable Qt/QML+Python Matrix chat client for encrypted and decentralized communication";
     homepage = "https://github.com/mirukana/mirage";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/networking/instant-messengers/mm/default.nix b/pkgs/applications/networking/instant-messengers/mm/default.nix
index a9306a751ac8f..7229218a704da 100644
--- a/pkgs/applications/networking/instant-messengers/mm/default.nix
+++ b/pkgs/applications/networking/instant-messengers/mm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchgit }:
+{ lib, stdenv, buildGoModule, fetchgit }:
 
 buildGoModule {
   pname = "mm";
@@ -12,7 +12,7 @@ buildGoModule {
 
   vendorSha256 = "sha256-zJJ9PzQShv2iRNyCg1XVscbwjV9ZtMIojJDtXXm3rVM=";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A file system based matrix client";
     homepage = "https://git.lost.host/meutraa/mm";
     license = licenses.isc;
diff --git a/pkgs/applications/networking/instant-messengers/neochat/default.nix b/pkgs/applications/networking/instant-messengers/neochat/default.nix
index 2a489ee3e713e..03e74de7780d6 100644
--- a/pkgs/applications/networking/instant-messengers/neochat/default.nix
+++ b/pkgs/applications/networking/instant-messengers/neochat/default.nix
@@ -1,5 +1,5 @@
 { mkDerivation
-, stdenv
+, lib, stdenv
 , fetchFromGitLab
 , pkg-config
 , cmake
@@ -57,7 +57,7 @@ mkDerivation rec {
     libpulseaudio
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A client for matrix, the decentralized communication protocol.";
     homepage = "https://apps.kde.org/en/neochat";
     license = licenses.gpl3Only;
diff --git a/pkgs/applications/networking/instant-messengers/nheko/default.nix b/pkgs/applications/networking/instant-messengers/nheko/default.nix
index 80ffbebe9be39..a26d3c41b221e 100644
--- a/pkgs/applications/networking/instant-messengers/nheko/default.nix
+++ b/pkgs/applications/networking/instant-messengers/nheko/default.nix
@@ -57,7 +57,7 @@ mkDerivation rec {
     qtgraphicaleffects
   ] ++ lib.optional stdenv.isDarwin qtmacextras;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop client for the Matrix protocol";
     homepage = "https://github.com/Nheko-Reborn/nheko";
     maintainers = with maintainers; [ ekleog fpletz ];
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/carbons/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/carbons/default.nix
index 7c2150a584fe6..2bb347611b832 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/carbons/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/carbons/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libxml2, pidgin, pkgconfig, fetchFromGitHub } :
+{ lib, stdenv, libxml2, pidgin, pkgconfig, fetchFromGitHub } :
 
 stdenv.mkDerivation rec {
   pname = "pidgin-carbons";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libxml2 pidgin ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gkdr/carbons";
     description = "XEP-0280: Message Carbons plugin for libpurple";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/otr/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/otr/default.nix
index bdc16d101f556..c7bad49cebaa6 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/otr/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/otr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libotr, pidgin, intltool } :
+{ lib, stdenv, fetchurl, libotr, pidgin, intltool } :
 
 stdenv.mkDerivation rec {
   name = "pidgin-otr-4.0.2";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libotr pidgin intltool ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://otr.cypherpunks.ca/";
     description = "Plugin for Pidgin 2.x which implements OTR Messaging";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-latex/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-latex/default.nix
index 1fd248e0c89d9..5f54d02ca9f6c 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-latex/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-latex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, pidgin, texLive, imagemagick, glib, gtk2 }:
+{ lib, stdenv, fetchurl, pkgconfig, pidgin, texLive, imagemagick, glib, gtk2 }:
 
 let version = "1.5.0";
 in
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     wrapArgs = "--prefix PATH ':' ${stdenv.lib.makeBinPath [ texLive imagemagick ]}";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/pidgin-latex/";
     description = "LaTeX rendering plugin for Pidgin IM";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-opensteamworks/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-opensteamworks/default.nix
index 067a71a93dd52..f72dd198b60f0 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-opensteamworks/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-opensteamworks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, pidgin, glib, json-glib, nss, nspr
+{ lib, stdenv, fetchFromGitHub, pkgconfig, pidgin, glib, json-glib, nss, nspr
 , libsecret
 } :
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     pidgin glib json-glib nss nspr libsecret
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/EionRobb/pidgin-opensteamworks";
     description = "Plugin for Pidgin 2.x which implements Steam Friends/Steam IM compatibility";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-osd/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-osd/default.nix
index bf9979c19f257..4c7cb2c46bfa2 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-osd/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-osd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pidgin, xosd
+{ lib, stdenv, fetchFromGitHub, pidgin, xosd
 , autoreconfHook } :
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ xosd pidgin ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mbroemme/pidgin-osd";
     description = "Plugin for Pidgin which implements on-screen display via libxosd";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-skypeweb/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-skypeweb/default.nix
index 72309e3479fe0..59afb8bd65b0b 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-skypeweb/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-skypeweb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, pidgin, json-glib }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, pidgin, json-glib }:
 
 stdenv.mkDerivation rec {
   pname = "pidgin-skypeweb";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   PKG_CONFIG_PURPLE_PLUGINDIR = "${placeholder "out"}/lib/purple-2";
   PKG_CONFIG_PURPLE_DATADIR = "${placeholder "out"}/share";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/EionRobb/skype4pidgin";
     description = "SkypeWeb plugin for Pidgin";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-xmpp-receipts/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-xmpp-receipts/default.nix
index 463b6326b5a24..f545b65cd8ea9 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-xmpp-receipts/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/pidgin-xmpp-receipts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pidgin } :
+{ lib, stdenv, fetchFromGitHub, pidgin } :
 
 let
   version = "0.8";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     cp xmpp-receipts.so $out/lib/pidgin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://devel.kondorgulasch.de/pidgin-xmpp-receipts/";
     description = "Message delivery receipts (XEP-0184) Pidgin plugin";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-discord/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-discord/default.nix
index 0322005ae9352..8128d0af7b7f6 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-discord/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-discord/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, pidgin, json-glib }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, pidgin, json-glib }:
 
 stdenv.mkDerivation {
   pname = "purple-discord";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
   PKG_CONFIG_PURPLE_PLUGINDIR = "${placeholder "out"}/lib/purple-2";
   PKG_CONFIG_PURPLE_DATADIR = "${placeholder "out"}/share";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/EionRobb/purple-discord";
     description = "Discord plugin for Pidgin";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-facebook/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-facebook/default.nix
index cff1bcc56b92a..a45f91ec57fdb 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-facebook/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-facebook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchhg, pidgin, glib, json-glib, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, fetchhg, pidgin, glib, json-glib, autoreconfHook }:
 
 
 let
@@ -55,7 +55,7 @@ in stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ pidgin glib json-glib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Facebook protocol plugin for libpurple";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-hangouts/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-hangouts/default.nix
index 204d99f6d7aba..653708abe3b69 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-hangouts/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-hangouts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchhg, pidgin, glib, json-glib, protobuf, protobufc }:
+{ lib, stdenv, fetchhg, pidgin, glib, json-glib, protobuf, protobufc }:
 
 stdenv.mkDerivation {
   pname = "purple-hangouts-hg";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
   PKG_CONFIG_PURPLE_PLUGINDIR = "${placeholder "out"}/lib/purple-2";
   PKG_CONFIG_PURPLE_DATADIR = "${placeholder "out"}/share";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/EionRobb/purple-hangouts";
     description = "Native Hangouts support for pidgin";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-lurch/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-lurch/default.nix
index 0a6aa1a133d6e..2170aac16e053 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-lurch/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-lurch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pidgin, minixml, libxml2, sqlite, libgcrypt }:
+{ lib, stdenv, fetchFromGitHub, cmake, pidgin, minixml, libxml2, sqlite, libgcrypt }:
 
 stdenv.mkDerivation rec {
   pname = "purple-lurch";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -Dm755 -t $out/lib/purple-2 build/lurch.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gkdr/lurch";
     description = "XEP-0384: OMEMO Encryption for libpurple";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-matrix/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-matrix/default.nix
index 4ded2ce1d0bfe..75be98506aec9 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-matrix/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-matrix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, pidgin, json-glib, glib, http-parser, sqlite, olm, libgcrypt } :
+{ lib, stdenv, fetchFromGitHub, pkgconfig, pidgin, json-glib, glib, http-parser, sqlite, olm, libgcrypt } :
 
 stdenv.mkDerivation rec {
   pname = "purple-matrix-unstable";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   buildFlags = [ "CC=cc" ]; # fix build on darwin
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/matrix-org/purple-matrix";
     description = "Matrix support for Pidgin / libpurple";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-plugin-pack/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-plugin-pack/default.nix
index 6739befbfea48..edc047c78ba23 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-plugin-pack/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-plugin-pack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pidgin, intltool, python } :
+{ lib, stdenv, fetchurl, pidgin, intltool, python } :
 
 stdenv.mkDerivation rec {
   name = "purple-plugin-pack-2.7.0";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pidgin intltool python ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/rekkanoryo/purple-plugin-pack";
     description = "Plugin pack for Pidgin 2.x";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-slack/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-slack/default.nix
index 5b3a1564aebfd..547cd2b14278d 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-slack/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-slack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pidgin, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, pidgin, pkgconfig }:
 
 stdenv.mkDerivation {
   pname = "purple-slack-unstable";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
   PKG_CONFIG_PURPLE_PLUGINDIR = "${placeholder "out"}/lib/purple-2";
   PKG_CONFIG_PURPLE_DATAROOTDIR = "${placeholder "out"}/share";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dylex/slack-libpurple";
     description = "Slack plugin for Pidgin";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-xmpp-http-upload/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-xmpp-http-upload/default.nix
index 3277e12ec086d..6ade8e5f19e56 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-xmpp-http-upload/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/purple-xmpp-http-upload/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, pidgin, glib, libxml2 }:
+{ lib, stdenv, fetchgit, pidgin, glib, libxml2 }:
 
 stdenv.mkDerivation {
   name = "purple-xmpp-upload-2017-12-31";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     install -Dm644 -t $out/lib/purple-2 jabber_http_file_upload.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Junker/purple-xmpp-http-upload";
     description = "HTTP File Upload plugin for libpurple (XMPP Protocol XEP-0363)";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/sipe/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/sipe/default.nix
index 3d1a6ac534c59..468d7f64c4cf3 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/sipe/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/sipe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pidgin, intltool, libxml2, gmime, nss }:
+{ lib, stdenv, fetchurl, pidgin, intltool, libxml2, gmime, nss }:
 
 stdenv.mkDerivation rec {
   pname = "pidgin-sipe";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   postInstall = "ln -s \$out/lib/purple-2 \$out/share/pidgin-sipe";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SIPE plugin for Pidgin IM";
     homepage = "http://sipe.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/telegram-purple/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/telegram-purple/default.nix
index 38424ca25979b..a5593624691b8 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/telegram-purple/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/telegram-purple/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, pkgconfig, pidgin, libwebp, libgcrypt, gettext } :
+{ lib, stdenv, fetchgit, pkgconfig, pidgin, libwebp, libgcrypt, gettext } :
 
 let
   version = "1.3.1";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     cp imgs/telegram48.png $out/pixmaps/pidgin/protocols/48
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/majn/telegram-purple";
     description = "Telegram for Pidgin / libpurple";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/tox-prpl/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/tox-prpl/default.nix
index de48ee26a6ed4..41c6a75310a6f 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/tox-prpl/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/tox-prpl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libtoxcore, pidgin, autoreconfHook, libsodium }:
+{ lib, stdenv, fetchFromGitHub, libtoxcore, pidgin, autoreconfHook, libsodium }:
 
 stdenv.mkDerivation rec {
   pname = "tox-prpl";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libtoxcore pidgin libsodium ];
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jin-eld/tox-prpl";
     description = "Tox plugin for Pidgin / libpurple";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin-plugins/window-merge/default.nix b/pkgs/applications/networking/instant-messengers/pidgin-plugins/window-merge/default.nix
index f576f2ad9c3e7..c5437e965ed87 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin-plugins/window-merge/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin-plugins/window-merge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pidgin } :
+{ lib, stdenv, fetchurl, pidgin } :
 
 stdenv.mkDerivation rec {
   pname = "pidgin-window-merge";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pidgin ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dm0-/window_merge";
     description = "Pidgin plugin that merges the Buddy List window with a conversation window";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/pidgin/default.nix b/pkgs/applications/networking/instant-messengers/pidgin/default.nix
index a269eead708aa..c956864b83d78 100644
--- a/pkgs/applications/networking/instant-messengers/pidgin/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pidgin/default.nix
@@ -72,7 +72,7 @@ let unwrapped = stdenv.mkDerivation rec {
       --prefix GST_PLUGIN_SYSTEM_PATH_1_0 : "$GST_PLUGIN_SYSTEM_PATH_1_0"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-protocol instant messaging client";
     homepage = "http://pidgin.im";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/networking/instant-messengers/pybitmessage/default.nix b/pkgs/applications/networking/instant-messengers/pybitmessage/default.nix
index d76b8dd206e46..06f02fa809468 100644
--- a/pkgs/applications/networking/instant-messengers/pybitmessage/default.nix
+++ b/pkgs/applications/networking/instant-messengers/pybitmessage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages, openssl }:
+{ lib, stdenv, fetchFromGitHub, python2Packages, openssl }:
 
 python2Packages.buildPythonApplication rec {
   pname = "pybitmessage";
@@ -30,7 +30,7 @@ python2Packages.buildPythonApplication rec {
 
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitmessage.org/";
     description = "The official Bitmessage client";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/instant-messengers/qtox/default.nix b/pkgs/applications/networking/instant-messengers/qtox/default.nix
index 2605d6dc08187..37527262b7fec 100644
--- a/pkgs/applications/networking/instant-messengers/qtox/default.nix
+++ b/pkgs/applications/networking/instant-messengers/qtox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, pkg-config, perl
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, pkg-config, perl
 , libtoxcore, libpthreadstubs, libXdmcp, libXScrnSaver
 , qtbase, qtsvg, qttools, qttranslations
 , ffmpeg_3, filter-audio, libexif, libsodium, libopus
@@ -35,7 +35,7 @@ mkDerivation rec {
     "-DTIMESTAMP=1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt Tox client";
     homepage = "https://tox.chat";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/rambox/default.nix b/pkgs/applications/networking/instant-messengers/rambox/default.nix
index cc9fab4d3752d..bc26b68d2db7c 100644
--- a/pkgs/applications/networking/instant-messengers/rambox/default.nix
+++ b/pkgs/applications/networking/instant-messengers/rambox/default.nix
@@ -41,7 +41,7 @@ in stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free and Open Source messaging and emailing app that combines common web applications into one";
     homepage = "https://rambox.pro";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/instant-messengers/rambox/pro.nix b/pkgs/applications/networking/instant-messengers/rambox/pro.nix
index 3cdf1339e3bf3..1df0b597ae24a 100644
--- a/pkgs/applications/networking/instant-messengers/rambox/pro.nix
+++ b/pkgs/applications/networking/instant-messengers/rambox/pro.nix
@@ -1,4 +1,4 @@
-{ autoPatchelfHook, electron_7, fetchurl, makeDesktopItem, makeWrapper, nodePackages, nss, stdenv, xdg_utils, xorg }:
+{ autoPatchelfHook, electron_7, fetchurl, makeDesktopItem, makeWrapper, nodePackages, nss, lib, stdenv, xdg_utils, xorg }:
 
 let
   electron = electron_7;
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     categories = "Network;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Messaging and emailing app that combines common web applications into one";
     homepage = "https://rambox.pro";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/instant-messengers/ricochet/default.nix b/pkgs/applications/networking/instant-messengers/ricochet/default.nix
index de46c891d1fae..322da86071c59 100644
--- a/pkgs/applications/networking/instant-messengers/ricochet/default.nix
+++ b/pkgs/applications/networking/instant-messengers/ricochet/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, pkgconfig, makeDesktopItem
+{ mkDerivation, lib, stdenv, fetchurl, pkgconfig, makeDesktopItem
 , qtbase, qttools, qtmultimedia, qtquick1, qtquickcontrols
 , openssl, protobuf, qmake
 }:
@@ -49,7 +49,7 @@ mkDerivation rec {
   # RCC: Error in 'translation/embedded.qrc': Cannot find file 'ricochet_en.qm'
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Anonymous peer-to-peer instant messaging";
     homepage = "https://ricochet.im";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/instant-messengers/ring-daemon/default.nix b/pkgs/applications/networking/instant-messengers/ring-daemon/default.nix
index 4a95debdfd104..801e682668034 100644
--- a/pkgs/applications/networking/instant-messengers/ring-daemon/default.nix
+++ b/pkgs/applications/networking/instant-messengers/ring-daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , which
 , autoreconfHook
@@ -52,7 +52,7 @@ let
   patchdir = "${src}/contrib/src";
 
   restbed = import ./restbed.nix {
-    inherit stdenv fetchFromGitHub cmake asio openssl;
+    inherit stdenv lib fetchFromGitHub cmake asio openssl;
     patches = [
     "${patchdir}/restbed/CMakeLists.patch"
     "${patchdir}/restbed/strand.patch"
@@ -132,7 +132,7 @@ stdenv.mkDerivation {
     ln -s $out/dringctrl/dringctrl.py $out/bin/dringctrl.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Voice-over-IP software phone";
     longDescription = ''
       As the SIP/audio daemon and the user interface are separate processes, it
diff --git a/pkgs/applications/networking/instant-messengers/ring-daemon/restbed.nix b/pkgs/applications/networking/instant-messengers/ring-daemon/restbed.nix
index 5b7a402504d8b..e2cdb1f05b0e9 100644
--- a/pkgs/applications/networking/instant-messengers/ring-daemon/restbed.nix
+++ b/pkgs/applications/networking/instant-messengers/ring-daemon/restbed.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , asio
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ asio openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP framework for building networked applications";
     longDescription = ''
       HTTP framework for building networked applications that require seamless
diff --git a/pkgs/applications/networking/instant-messengers/salut-a-toi/default.nix b/pkgs/applications/networking/instant-messengers/salut-a-toi/default.nix
index 6b9593a24b7f1..614ceeb0c3247 100644
--- a/pkgs/applications/networking/instant-messengers/salut-a-toi/default.nix
+++ b/pkgs/applications/networking/instant-messengers/salut-a-toi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python27Packages, file }:
+{ lib, stdenv, fetchurl, python27Packages, file }:
 
 let
   inherit (python27Packages) python;
@@ -50,7 +50,7 @@ in
       done
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://sat.goffi.org/";
       description = "A multi-frontend XMPP client";
       platforms = platforms.linux;
diff --git a/pkgs/applications/networking/instant-messengers/salut-a-toi/requirements.nix b/pkgs/applications/networking/instant-messengers/salut-a-toi/requirements.nix
index 1a68111824533..c15b7ac45dd85 100644
--- a/pkgs/applications/networking/instant-messengers/salut-a-toi/requirements.nix
+++ b/pkgs/applications/networking/instant-messengers/salut-a-toi/requirements.nix
@@ -1,5 +1,5 @@
 { fetchurl
-, stdenv
+, lib, stdenv
 , pythonPackages
 }:
 
@@ -40,7 +40,7 @@ in {
     # error: invalid command 'test'
     doCheck = false;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://home.blarg.net/~steveha/pyfeed.html";
       description = "Tools for syndication feeds";
     };
@@ -57,7 +57,7 @@ in {
 
     propagatedBuildInputs = with pythonPackages; [twisted dateutil];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Some (mainly XMPP-related) additions to twisted";
       homepage = "http://wokkel.ik.nu/";
       license = licenses.mit;
diff --git a/pkgs/applications/networking/instant-messengers/scudcloud/default.nix b/pkgs/applications/networking/instant-messengers/scudcloud/default.nix
index b16659ba44cd9..55935f69e1c8c 100644
--- a/pkgs/applications/networking/instant-messengers/scudcloud/default.nix
+++ b/pkgs/applications/networking/instant-messengers/scudcloud/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3Packages }:
+{ lib, stdenv, fetchurl, python3Packages }:
 
 let version = "1.63";
 in python3Packages.buildPythonPackage {
@@ -11,7 +11,7 @@ in python3Packages.buildPythonPackage {
 
   propagatedBuildInputs = with python3Packages; [ pyqt5_with_qtwebkit dbus-python jsmin ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Non-official desktop client for Slack";
     homepage = "https://github.com/raelgc/scudcloud";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/instant-messengers/skypeforlinux/default.nix b/pkgs/applications/networking/instant-messengers/skypeforlinux/default.nix
index d4e43ed3a92df..068b939d515c5 100644
--- a/pkgs/applications/networking/instant-messengers/skypeforlinux/default.nix
+++ b/pkgs/applications/networking/instant-messengers/skypeforlinux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg
+{ lib, stdenv, fetchurl, dpkg
 , alsaLib, atk, cairo, cups, curl, dbus, expat, fontconfig, freetype, gdk-pixbuf, glib, glibc, gnome2, gnome3
 , gtk3, libappindicator-gtk3, libnotify, libpulseaudio, libsecret, libv4l, nspr, nss, pango, systemd, wrapGAppsHook, xorg
 , at-spi2-atk, libuuid, at-spi2-core }:
@@ -114,7 +114,7 @@ in stdenv.mkDerivation {
       --replace /usr/bin/ $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux client for skype";
     homepage = "https://www.skype.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/instant-messengers/slack-term/default.nix b/pkgs/applications/networking/instant-messengers/slack-term/default.nix
index c862c253c00a6..66d59346c4b14 100644
--- a/pkgs/applications/networking/instant-messengers/slack-term/default.nix
+++ b/pkgs/applications/networking/instant-messengers/slack-term/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   # https://github.com/erroneousboat/slack-term
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "1fbq7bdhy70hlkklppimgdjamnk0v059pg73xm9ax1f4616ki1m6";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Slack client for your terminal";
     homepage = "https://github.com/erroneousboat/slack-term";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/instant-messengers/slack/default.nix b/pkgs/applications/networking/instant-messengers/slack/default.nix
index 5f367c76a928f..6c1e99a24dac7 100644
--- a/pkgs/applications/networking/instant-messengers/slack/default.nix
+++ b/pkgs/applications/networking/instant-messengers/slack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , dpkg
 , undmg
@@ -65,7 +65,7 @@ let
     };
   }.${system} or throwSystem;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop client for Slack";
     homepage = "https://slack.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/instant-messengers/stride/default.nix b/pkgs/applications/networking/instant-messengers/stride/default.nix
index 895ad30360e97..9096a925bbdee 100644
--- a/pkgs/applications/networking/instant-messengers/stride/default.nix
+++ b/pkgs/applications/networking/instant-messengers/stride/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg, alsaLib, atk, cairo, cups, dbus, expat, fontconfig
+{ lib, stdenv, fetchurl, dpkg, alsaLib, atk, cairo, cups, dbus, expat, fontconfig
 , freetype, gdk-pixbuf, glib, gnome2, nspr, nss, pango, udev, xorg }:
 let
   fullPath = stdenv.lib.makeLibraryPath [
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
       "$out/bin/stride"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop client for Atlassian Stride";
     homepage = "https://www.stride.com/";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/instant-messengers/swift-im/default.nix b/pkgs/applications/networking/instant-messengers/swift-im/default.nix
index c520835b1f0c8..494a1f267f95f 100644
--- a/pkgs/applications/networking/instant-messengers/swift-im/default.nix
+++ b/pkgs/applications/networking/instant-messengers/swift-im/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, pkgconfig, qttools, sconsPackages
+{ mkDerivation, lib, stdenv, fetchurl, pkgconfig, qttools, sconsPackages
 , GConf, avahi, boost, hunspell, libXScrnSaver, libedit, libidn, libnatpmp, libxml2
 , lua, miniupnpc, openssl, qtbase, qtmultimedia, qtsvg, qtwebkit, qtx11extras, zlib
 }:
@@ -34,7 +34,7 @@ mkDerivation rec {
   installTargets = [ (placeholder "out") ];
   installFlags = [ "SWIFT_INSTALLDIR=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://swift.im/";
     description = "Qt XMPP client";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/teams/default.nix b/pkgs/applications/networking/instant-messengers/teams/default.nix
index 1f4e11527ccda..af3235bbdc7c2 100644
--- a/pkgs/applications/networking/instant-messengers/teams/default.nix
+++ b/pkgs/applications/networking/instant-messengers/teams/default.nix
@@ -78,7 +78,7 @@ stdenv.mkDerivation rec {
     done;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Microsoft Teams";
     homepage = "https://teams.microsoft.com";
     downloadPage = "https://teams.microsoft.com/downloads";
diff --git a/pkgs/applications/networking/instant-messengers/teamspeak/client.nix b/pkgs/applications/networking/instant-messengers/teamspeak/client.nix
index ba726d5b37710..33b8c5355f70a 100644
--- a/pkgs/applications/networking/instant-messengers/teamspeak/client.nix
+++ b/pkgs/applications/networking/instant-messengers/teamspeak/client.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, makeDesktopItem, zlib, glib, libpng, freetype, openssl
+{ lib, stdenv, fetchurl, makeWrapper, makeDesktopItem, zlib, glib, libpng, freetype, openssl
 , xorg, fontconfig, qtbase, qtwebengine, qtwebchannel, qtsvg, qtwebsockets, xkeyboard_config
 , alsaLib, libpulseaudio ? null, libredirect, quazip, which, unzip, llvmPackages, writeShellScriptBin
 }:
@@ -99,7 +99,7 @@ stdenv.mkDerivation rec {
   dontStrip = true;
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The TeamSpeak voice communication tool";
     homepage = "https://teamspeak.com/";
     license = {
diff --git a/pkgs/applications/networking/instant-messengers/teamspeak/server.nix b/pkgs/applications/networking/instant-messengers/teamspeak/server.nix
index 521e60c78f000..3dfbb69e83c7f 100644
--- a/pkgs/applications/networking/instant-messengers/teamspeak/server.nix
+++ b/pkgs/applications/networking/instant-messengers/teamspeak/server.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, postgresql, autoPatchelfHook, writeScript }:
+{ lib, stdenv, fetchurl, postgresql, autoPatchelfHook, writeScript }:
 
 let
   arch = if stdenv.is64bit then "amd64" else "x86";
@@ -51,7 +51,7 @@ in stdenv.mkDerivation rec {
     update-source-version teamspeak_server "$version" --system=x86_64-linux
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TeamSpeak voice communication server";
     homepage = "https://teamspeak.com/";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/applications/networking/instant-messengers/telepathy/gabble/default.nix b/pkgs/applications/networking/instant-messengers/telepathy/gabble/default.nix
index d81af8388aac9..3cdaa72cfd2c4 100644
--- a/pkgs/applications/networking/instant-messengers/telepathy/gabble/default.nix
+++ b/pkgs/applications/networking/instant-messengers/telepathy/gabble/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxslt, telepathy-glib, libxml2, dbus-glib, dbus
+{ lib, stdenv, fetchurl, pkgconfig, libxslt, telepathy-glib, libxml2, dbus-glib, dbus
 , sqlite, libsoup, libnice, gnutls}:
 
 stdenv.mkDerivation rec {
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   enableParallelBuilding = true;
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://telepathy.freedesktop.org/components/telepathy-gabble/";
     description = "Jabber/XMPP connection manager for the Telepathy framework";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/applications/networking/instant-messengers/telepathy/logger/default.nix b/pkgs/applications/networking/instant-messengers/telepathy/logger/default.nix
index f8e1f1f2c665d..e96b35f21a8e0 100644
--- a/pkgs/applications/networking/instant-messengers/telepathy/logger/default.nix
+++ b/pkgs/applications/networking/instant-messengers/telepathy/logger/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dbus-glib, libxml2, sqlite, telepathy-glib, pkgconfig
+{ lib, stdenv, fetchurl, dbus-glib, libxml2, sqlite, telepathy-glib, pkgconfig
 , dconf, makeWrapper, intltool, libxslt, gobject-introspection, dbus }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       --prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Logger service for Telepathy framework";
     homepage = "https://telepathy.freedesktop.org/components/telepathy-logger/";
     license = licenses.lgpl21;
diff --git a/pkgs/applications/networking/instant-messengers/telepathy/mission-control/default.nix b/pkgs/applications/networking/instant-messengers/telepathy/mission-control/default.nix
index bc0657f7b1a73..1df59809146e9 100644
--- a/pkgs/applications/networking/instant-messengers/telepathy/mission-control/default.nix
+++ b/pkgs/applications/networking/instant-messengers/telepathy/mission-control/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkg-config
 , dconf
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
       --prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An account manager and channel dispatcher for the Telepathy framework";
     homepage = "https://telepathy.freedesktop.org/components/telepathy-mission-control/";
     license = licenses.lgpl21Only;
diff --git a/pkgs/applications/networking/instant-messengers/telepathy/salut/default.nix b/pkgs/applications/networking/instant-messengers/telepathy/salut/default.nix
index 6513c6324a617..dc0a16139ea91 100644
--- a/pkgs/applications/networking/instant-messengers/telepathy/salut/default.nix
+++ b/pkgs/applications/networking/instant-messengers/telepathy/salut/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxslt, glib, libxml2, telepathy-glib, avahi, libsoup
+{ lib, stdenv, fetchurl, libxslt, glib, libxml2, telepathy-glib, avahi, libsoup
 , libuuid, openssl, pcre, sqlite, pkgconfig }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--disable-avahi-tests" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Link-local XMPP connection manager for Telepathy";
     platforms = platforms.gnu ++ platforms.linux; # Random choice
     maintainers = [ maintainers.lethalman ];
diff --git a/pkgs/applications/networking/instant-messengers/tensor/default.nix b/pkgs/applications/networking/instant-messengers/tensor/default.nix
index 1ea249a8b51bd..93b3315c1eff1 100644
--- a/pkgs/applications/networking/instant-messengers/tensor/default.nix
+++ b/pkgs/applications/networking/instant-messengers/tensor/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchgit, qtbase, qtquickcontrols, qmake, makeDesktopItem }:
+{ mkDerivation, lib, stdenv, fetchgit, qtbase, qtquickcontrols, qmake, makeDesktopItem }:
 
 # we now have libqmatrixclient so a future version of tensor that supports it
 # should use that
@@ -45,7 +45,7 @@ mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://matrix.org/docs/projects/client/tensor.html";
     description = "Cross-platform Qt5/QML-based Matrix client";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/torchat/default.nix b/pkgs/applications/networking/instant-messengers/torchat/default.nix
index 8231f481ee0d9..087dd502946de 100644
--- a/pkgs/applications/networking/instant-messengers/torchat/default.nix
+++ b/pkgs/applications/networking/instant-messengers/torchat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python, unzip, wxPython, wrapPython, tor }:
+{ lib, stdenv, fetchurl, python, unzip, wxPython, wrapPython, tor }:
 stdenv.mkDerivation rec {
 
   pname = "torchat";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
         --add-flags "-O $out/lib/torchat/torchat.py"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/prof7bit/TorChat";
     description = "Instant messaging application on top of the Tor network and it's location hidden services";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/toxic/default.nix b/pkgs/applications/networking/instant-messengers/toxic/default.nix
index a2489427b946a..4aee50453ed40 100644
--- a/pkgs/applications/networking/instant-messengers/toxic/default.nix
+++ b/pkgs/applications/networking/instant-messengers/toxic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libsodium, ncurses, curl
+{ lib, stdenv, fetchFromGitHub, libsodium, ncurses, curl
 , libtoxcore, openal, libvpx, freealut, libconfig, pkgconfig, libopus
 , qrencode, gdk-pixbuf, libnotify }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   ];
   nativeBuildInputs = [ pkgconfig libconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reference CLI for Tox";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ ];
diff --git a/pkgs/applications/networking/instant-messengers/turses/default.nix b/pkgs/applications/networking/instant-messengers/turses/default.nix
index b6017277b0a50..4b07289a11caf 100644
--- a/pkgs/applications/networking/instant-messengers/turses/default.nix
+++ b/pkgs/applications/networking/instant-messengers/turses/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, python3Packages }:
+{ lib, stdenv, fetchpatch, python3Packages }:
 
 with stdenv.lib;
 with python3Packages;
@@ -44,7 +44,7 @@ buildPythonPackage rec {
     sed -i -e "s|self.observer.update.assert_called_once()|assert self.observer.update.call_count == 1|" tests/test_meta.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/louipc/turses";
     description = "A Twitter client for the console";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/twinkle/default.nix b/pkgs/applications/networking/instant-messengers/twinkle/default.nix
index b6f0b87dc8480..004a4dab82366 100644
--- a/pkgs/applications/networking/instant-messengers/twinkle/default.nix
+++ b/pkgs/applications/networking/instant-messengers/twinkle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , libxml2
@@ -73,7 +73,7 @@ mkDerivation rec {
     /* "-DWITH_DIAMONDCARD=On" seems ancient and broken */
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     changelog = "https://github.com/LubosD/twinkle/blob/${version}/NEWS";
     description = "A SIP-based VoIP client";
     homepage = "http://twinkle.dolezel.info/";
diff --git a/pkgs/applications/networking/instant-messengers/utox/default.nix b/pkgs/applications/networking/instant-messengers/utox/default.nix
index b360793e484b7..01f2b9c5644c5 100644
--- a/pkgs/applications/networking/instant-messengers/utox/default.nix
+++ b/pkgs/applications/networking/instant-messengers/utox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, check, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, check, cmake, pkgconfig
 , libtoxcore, filter-audio, dbus, libvpx, libX11, openal, freetype, libv4l
 , libXrender, fontconfig, libXext, libXft, libsodium, libopus }:
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   doCheck = stdenv.hostPlatform == stdenv.buildPlatform;
   checkInputs = [ check ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight Tox client";
     homepage = "https://github.com/uTox/uTox";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/instant-messengers/vacuum/default.nix b/pkgs/applications/networking/instant-messengers/vacuum/default.nix
index ed320d9679d6b..0fc7e8b6d8ee2 100644
--- a/pkgs/applications/networking/instant-messengers/vacuum/default.nix
+++ b/pkgs/applications/networking/instant-messengers/vacuum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
   , qt4, qmake4Hook, openssl
   , xorgproto, libX11, libXScrnSaver
   , xz, zlib
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An XMPP client fully composed of plugins";
     maintainers = [ maintainers.raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/networking/instant-messengers/vk-messenger/default.nix b/pkgs/applications/networking/instant-messengers/vk-messenger/default.nix
index 2910c389daace..d7deb7ee052c6 100644
--- a/pkgs/applications/networking/instant-messengers/vk-messenger/default.nix
+++ b/pkgs/applications/networking/instant-messengers/vk-messenger/default.nix
@@ -44,7 +44,7 @@ in stdenv.mkDerivation {
     cp -r --parents share/pixmaps $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple and Convenient Messaging App for VK";
     homepage = "https://vk.com/messenger";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/instant-messengers/wavebox/default.nix b/pkgs/applications/networking/instant-messengers/wavebox/default.nix
index bdc8aabf61cf7..cddff29b5ed50 100644
--- a/pkgs/applications/networking/instant-messengers/wavebox/default.nix
+++ b/pkgs/applications/networking/instant-messengers/wavebox/default.nix
@@ -1,5 +1,5 @@
 { alsaLib, autoPatchelfHook, fetchurl, gtk3, libnotify
-, makeDesktopItem, makeWrapper, nss, stdenv, udev, xdg_utils
+, makeDesktopItem, makeWrapper, nss, lib, stdenv, udev, xdg_utils
 , xorg
 }:
 
@@ -57,7 +57,7 @@ in stdenv.mkDerivation {
       --prefix PATH : ${xdg_utils}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wavebox messaging application";
     homepage = "https://wavebox.io";
     license = licenses.mpl20;
diff --git a/pkgs/applications/networking/instant-messengers/wire-desktop/default.nix b/pkgs/applications/networking/instant-messengers/wire-desktop/default.nix
index b198b954bd40a..966583d2089a1 100644
--- a/pkgs/applications/networking/instant-messengers/wire-desktop/default.nix
+++ b/pkgs/applications/networking/instant-messengers/wire-desktop/default.nix
@@ -31,7 +31,7 @@ let
     x86_64-linux = "033804nkz1fdmq3p8iplrlx708x1fjlr09bmrpy36lqg5h7m3yd6";
   }.${system} or throwSystem;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern, secure messenger for everyone";
     longDescription = ''
       Wire Personal is a secure, privacy-friendly messenger. It combines useful
diff --git a/pkgs/applications/networking/instant-messengers/xmpp-client/default.nix b/pkgs/applications/networking/instant-messengers/xmpp-client/default.nix
index 52cf8e3279a03..a4c3f55b29962 100644
--- a/pkgs/applications/networking/instant-messengers/xmpp-client/default.nix
+++ b/pkgs/applications/networking/instant-messengers/xmpp-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "xmpp-client";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An XMPP client with OTR support";
     homepage = "https://github.com/agl/xmpp-client";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/ipfs-cluster/default.nix b/pkgs/applications/networking/ipfs-cluster/default.nix
index 2fe9365a84d5a..69b2d9ef30947 100644
--- a/pkgs/applications/networking/ipfs-cluster/default.nix
+++ b/pkgs/applications/networking/ipfs-cluster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "ipfs-cluster";
@@ -17,7 +17,7 @@ buildGoModule rec {
     sha256 = "0fschpysma2piy2bfas56yapxm2cl6nj986ww3sp7ysldjzadmkk";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allocate, replicate, and track Pins across a cluster of IPFS daemons";
     homepage = "https://cluster.ipfs.io/";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/ipfs/default.nix b/pkgs/applications/networking/ipfs/default.nix
index 01e808a9e7250..fd9d8bd0d347b 100644
--- a/pkgs/applications/networking/ipfs/default.nix
+++ b/pkgs/applications/networking/ipfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchurl, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchurl, nixosTests }:
 
 buildGoModule rec {
   pname = "ipfs";
@@ -35,7 +35,7 @@ buildGoModule rec {
       --replace /usr/bin/ipfs $out/bin/ipfs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A global, versioned, peer-to-peer filesystem";
     homepage = "https://ipfs.io/";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/ipget/default.nix b/pkgs/applications/networking/ipget/default.nix
index f16031e9dc826..ded83f30a1af4 100644
--- a/pkgs/applications/networking/ipget/default.nix
+++ b/pkgs/applications/networking/ipget/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "ipget";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Retrieve files over IPFS and save them locally";
     homepage = "https://ipfs.io/";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/iptraf-ng/default.nix b/pkgs/applications/networking/iptraf-ng/default.nix
index 6d61acb4982f1..c90fd239267e0 100644
--- a/pkgs/applications/networking/iptraf-ng/default.nix
+++ b/pkgs/applications/networking/iptraf-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   version = "1.2.1";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A console-based network monitoring utility (fork of iptraf)";
     longDescription = ''
       IPTraf-ng is a console-based network monitoring utility. IPTraf-ng
diff --git a/pkgs/applications/networking/irc/communi/default.nix b/pkgs/applications/networking/irc/communi/default.nix
index f3a840e23d0fd..5380bb5458ed4 100644
--- a/pkgs/applications/networking/irc/communi/default.nix
+++ b/pkgs/applications/networking/irc/communi/default.nix
@@ -1,4 +1,4 @@
-{ fetchgit, libcommuni, qtbase, qmake, stdenv }:
+{ fetchgit, libcommuni, qtbase, qmake, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   pname = "communi";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     rm -rf lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple and elegant cross-platform IRC client";
     homepage = "https://github.com/communi/communi-desktop";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/irc/epic5/default.nix b/pkgs/applications/networking/irc/epic5/default.nix
index cb2fa4ae6823e..872c96ac7a012 100644
--- a/pkgs/applications/networking/irc/epic5/default.nix
+++ b/pkgs/applications/networking/irc/epic5/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, ncurses, libiconv, tcl, coreutils, fetchpatch }:
+{ lib, stdenv, fetchurl, openssl, ncurses, libiconv, tcl, coreutils, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "epic5";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
       --replace /bin/chmod ${coreutils}/bin/chmod \
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://epicsol.org";
     description = "A IRC client that offers a great ircII interface";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/irc/glowing-bear/default.nix b/pkgs/applications/networking/irc/glowing-bear/default.nix
index 59278dddad1aa..bd7e05e8d3897 100644
--- a/pkgs/applications/networking/irc/glowing-bear/default.nix
+++ b/pkgs/applications/networking/irc/glowing-bear/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv }:
+{ fetchFromGitHub, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   pname = "glowing-bear";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp -R 3rdparty assets css directives js $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A web client for Weechat";
     homepage = "https://github.com/glowing-bear/glowing-bear";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/irc/hexchat/default.nix b/pkgs/applications/networking/irc/hexchat/default.nix
index c5b2a9f1b28e7..19f398bc59a43 100644
--- a/pkgs/applications/networking/irc/hexchat/default.nix
+++ b/pkgs/applications/networking/irc/hexchat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig, gtk2, lua, perl, python3
+{ lib, stdenv, fetchFromGitHub, fetchpatch, pkgconfig, gtk2, lua, perl, python3
 , pciutils, dbus-glib, libcanberra-gtk2, libproxy
 , enchant2, libnotify, openssl, isocodes
 , desktop-file-utils
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
 
   mesonFlags = [ "-Dwith-lua=lua" "-Dwith-text=true" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A popular and easy to use graphical IRC (chat) client";
     homepage = "https://hexchat.github.io/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/irc/quassel/default.nix b/pkgs/applications/networking/irc/quassel/default.nix
index 4afd488c68d11..842e160677e81 100644
--- a/pkgs/applications/networking/irc/quassel/default.nix
+++ b/pkgs/applications/networking/irc/quassel/default.nix
@@ -4,7 +4,7 @@
 , tag ? "-kf5" # tag added to the package name
 , static ? false # link statically
 
-, stdenv, fetchFromGitHub, cmake, makeWrapper, dconf
+, lib, stdenv, fetchFromGitHub, cmake, makeWrapper, dconf
 , mkDerivation, qtbase, qtscript
 , phonon, libdbusmenu, qca-qt5
 
@@ -83,7 +83,7 @@ in (if !buildClient then stdenv.mkDerivation else mkDerivation) rec {
         --prefix GIO_EXTRA_MODULES : "${dconf}/lib/gio/modules"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://quassel-irc.org/";
     description = "Qt/KDE distributed IRC client suppporting a remote daemon";
     longDescription = ''
diff --git a/pkgs/applications/networking/irc/qweechat/default.nix b/pkgs/applications/networking/irc/qweechat/default.nix
index 27adb2cefc5fc..18a4872a44fa1 100644
--- a/pkgs/applications/networking/irc/qweechat/default.nix
+++ b/pkgs/applications/networking/irc/qweechat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python27Packages }:
+{ lib, stdenv, fetchFromGitHub, python27Packages }:
 
 python27Packages.buildPythonApplication rec {
   version = "2016-07-29";
@@ -21,7 +21,7 @@ python27Packages.buildPythonApplication rec {
      pyside setuptools
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/weechat/qweechat";
     description = "Qt remote GUI for WeeChat";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/irc/weechat/scripts/wee-slack/default.nix b/pkgs/applications/networking/irc/weechat/scripts/wee-slack/default.nix
index 9650f903ed6b6..089271812a7a8 100644
--- a/pkgs/applications/networking/irc/weechat/scripts/wee-slack/default.nix
+++ b/pkgs/applications/networking/irc/weechat/scripts/wee-slack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll, buildEnv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, substituteAll, buildEnv, fetchFromGitHub, python3Packages }:
 
 stdenv.mkDerivation rec {
   pname = "wee-slack";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     install -D -m 0444 weemoji.json $out/share/wee-slack/weemoji.json
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/wee-slack/wee-slack";
     license = licenses.mit;
     maintainers = with maintainers; [ willibutz ];
diff --git a/pkgs/applications/networking/irc/weechat/scripts/weechat-autosort/default.nix b/pkgs/applications/networking/irc/weechat/scripts/weechat-autosort/default.nix
index 883ed793ced60..49e74e0203acf 100644
--- a/pkgs/applications/networking/irc/weechat/scripts/weechat-autosort/default.nix
+++ b/pkgs/applications/networking/irc/weechat/scripts/weechat-autosort/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "weechat-autosort";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     install -D autosort.py $out/share/autosort.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Autosort is a weechat script to automatically or manually keep your buffers sorted";
     homepage = "https://github.com/de-vri-es/weechat-autosort";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix-bridge/default.nix b/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix-bridge/default.nix
index 5c734bf7de2be..24cf26fbaf559 100644
--- a/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix-bridge/default.nix
+++ b/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix-bridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, curl, fetchFromGitHub, cjson, olm, luaffi }:
+{ lib, stdenv, curl, fetchFromGitHub, cjson, olm, luaffi }:
 
 stdenv.mkDerivation {
   name = "weechat-matrix-bridge-2018-11-19";
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
     cp ${luaffi}/lib/lua/${luaffi.lua.luaversion}/ffi.so $out/lib/ffi.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A WeeChat script in Lua that implements the matrix.org chat protocol";
     homepage = "https://github.com/torhve/weechat-matrix-protocol-script";
     maintainers = with maintainers; [ ];
diff --git a/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix/default.nix b/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix/default.nix
index 0b60617cbb388..b77d9c984de4a 100644
--- a/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix/default.nix
+++ b/pkgs/applications/networking/irc/weechat/scripts/weechat-matrix/default.nix
@@ -1,5 +1,5 @@
 { buildPythonPackage
-, stdenv
+, lib, stdenv
 , python
 , fetchFromGitHub
 , pyopenssl
@@ -71,7 +71,7 @@ in buildPythonPackage {
 
   dontPatchShebangs = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python plugin for Weechat that lets Weechat communicate over the Matrix protocol";
     homepage = "https://github.com/poljar/weechat-matrix";
     license = licenses.isc;
diff --git a/pkgs/applications/networking/irc/weechat/scripts/weechat-notify-send/default.nix b/pkgs/applications/networking/irc/weechat/scripts/weechat-notify-send/default.nix
index d219aa481cdb8..b55266e5f3745 100644
--- a/pkgs/applications/networking/irc/weechat/scripts/weechat-notify-send/default.nix
+++ b/pkgs/applications/networking/irc/weechat/scripts/weechat-notify-send/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libnotify }:
+{ lib, stdenv, fetchFromGitHub, libnotify }:
 
 stdenv.mkDerivation rec {
   pname = "weechat-notify-send";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --replace "'notify-send'" "'${libnotify}/bin/notify-send'"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A WeeChat script that sends highlight and message notifications through notify-send";
     homepage = "https://github.com/s3rvac/weechat-notify-srnd";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/irc/weechat/scripts/weechat-otr/default.nix b/pkgs/applications/networking/irc/weechat/scripts/weechat-otr/default.nix
index c7f2958cf5536..987271e4ffa29 100644
--- a/pkgs/applications/networking/irc/weechat/scripts/weechat-otr/default.nix
+++ b/pkgs/applications/networking/irc/weechat/scripts/weechat-otr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll, buildEnv, fetchgit, fetchFromGitHub, python3Packages, gmp }:
+{ lib, stdenv, substituteAll, buildEnv, fetchgit, fetchFromGitHub, python3Packages, gmp }:
 
 let
   # pure-python-otr (potr) requires an older version of pycrypto, which is
@@ -61,7 +61,7 @@ in stdenv.mkDerivation rec {
     cp weechat_otr.py $out/share/weechat_otr.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mmb/weechat-otr";
     license = licenses.gpl3;
     maintainers = with maintainers; [ oxzi ];
diff --git a/pkgs/applications/networking/jmeter/default.nix b/pkgs/applications/networking/jmeter/default.nix
index 3f626a6ac483b..a8f947aebf77a 100644
--- a/pkgs/applications/networking/jmeter/default.nix
+++ b/pkgs/applications/networking/jmeter/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, jre, makeWrapper, coreutils }:
+{ fetchurl, lib, stdenv, jre, makeWrapper, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "jmeter";
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     timeout --kill=1s 1s $out/bin/jmeter-mirror-server.sh || test "$?" = "124"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 100% pure Java desktop application designed to load test functional behavior and measure performance";
     longDescription = ''
       The Apache JMeter desktop application is open source software, a 100%
diff --git a/pkgs/applications/networking/jnetmap/default.nix b/pkgs/applications/networking/jnetmap/default.nix
index e2a8a2d56bd14..bac0048cc28d3 100644
--- a/pkgs/applications/networking/jnetmap/default.nix
+++ b/pkgs/applications/networking/jnetmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "jnetmap";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
         --add-flags "-jar \"$out/lib/jnetmap.jar\""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical network monitoring and documentation tool";
     homepage = "http://www.rakudave.ch/jnetmap/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/libcoap/default.nix b/pkgs/applications/networking/libcoap/default.nix
index 2448e8a76f35a..188d19d596824 100644
--- a/pkgs/applications/networking/libcoap/default.nix
+++ b/pkgs/applications/networking/libcoap/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, automake, autoconf, which, pkgconfig, libtool, stdenv }:
+{ fetchFromGitHub, automake, autoconf, which, pkgconfig, libtool, lib, stdenv }:
 stdenv.mkDerivation rec {
   pname = "libcoap";
   version = "4.2.1";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "--disable-documentation"
     "--disable-shared"
   ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/obgm/libcoap";
     description = "A CoAP (RFC 7252) implementation in C";
     platforms = platforms.linux;
diff --git a/pkgs/applications/networking/lieer/default.nix b/pkgs/applications/networking/lieer/default.nix
index a2c05bda63863..83d009e40e83c 100644
--- a/pkgs/applications/networking/lieer/default.nix
+++ b/pkgs/applications/networking/lieer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "lieer";
@@ -19,7 +19,7 @@ python3Packages.buildPythonApplication rec {
     setuptools
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description      = "Fast email-fetching and two-way tag synchronization between notmuch and GMail";
     longDescription  = ''
       This program can pull email and labels (and changes to labels)
diff --git a/pkgs/applications/networking/linssid/default.nix b/pkgs/applications/networking/linssid/default.nix
index f458e03913ba3..91c299d4fdab7 100644
--- a/pkgs/applications/networking/linssid/default.nix
+++ b/pkgs/applications/networking/linssid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qtbase, qtsvg, qmake, pkgconfig, boost, wirelesstools, iw, qwt, wrapQtAppsHook }:
+{ lib, stdenv, fetchurl, qtbase, qtsvg, qmake, pkgconfig, boost, wirelesstools, iw, qwt, wrapQtAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "linssid";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
   qtWrapperArgs =
     [ ''--prefix PATH : ${stdenv.lib.makeBinPath [ wirelesstools iw ]}'' ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical wireless scanning for Linux";
     homepage = "https://sourceforge.net/projects/linssid/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/mailreaders/aerc/default.nix b/pkgs/applications/networking/mailreaders/aerc/default.nix
index 781e6c8369d0b..1bd8cbeceeb8b 100644
--- a/pkgs/applications/networking/mailreaders/aerc/default.nix
+++ b/pkgs/applications/networking/mailreaders/aerc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchurl
+{ lib, stdenv, buildGoModule, fetchurl
 , go, ncurses, notmuch, scdoc
 , python3, perl, w3m, dante
 , fetchFromGitHub
@@ -53,7 +53,7 @@ buildGoModule rec {
       ${stdenv.lib.makeBinPath [ w3m dante ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An email client for your terminal";
     homepage = "https://aerc-mail.org/";
     maintainers = with maintainers; [ tadeokondrak ];
diff --git a/pkgs/applications/networking/mailreaders/afew/default.nix b/pkgs/applications/networking/mailreaders/afew/default.nix
index 129120609ca55..dbc55850f9fd1 100644
--- a/pkgs/applications/networking/mailreaders/afew/default.nix
+++ b/pkgs/applications/networking/mailreaders/afew/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, notmuch }:
+{ lib, stdenv, python3Packages, notmuch }:
 
 python3Packages.buildPythonApplication rec {
   pname = "afew";
@@ -36,7 +36,7 @@ python3Packages.buildPythonApplication rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/afewmail/afew";
     description = "An initial tagging script for notmuch mail";
     license = licenses.isc;
diff --git a/pkgs/applications/networking/mailreaders/alpine/default.nix b/pkgs/applications/networking/mailreaders/alpine/default.nix
index 83c2f3ca7ac3c..62882818d726e 100644
--- a/pkgs/applications/networking/mailreaders/alpine/default.nix
+++ b/pkgs/applications/networking/mailreaders/alpine/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ncurses, tcl, openssl, pam, kerberos
+{lib, stdenv, fetchurl, ncurses, tcl, openssl, pam, kerberos
 , openldap
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     "--with-c-client-target=slx"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Console mail reader";
     license = licenses.asl20;
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/applications/networking/mailreaders/astroid/default.nix b/pkgs/applications/networking/mailreaders/astroid/default.nix
index 171136ce22cad..c49866ed9c6c8 100644
--- a/pkgs/applications/networking/mailreaders/astroid/default.nix
+++ b/pkgs/applications/networking/mailreaders/astroid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, gnome3, gmime3, webkitgtk
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, gnome3, gmime3, webkitgtk
 , libsass, notmuch, boost, wrapGAppsHook, glib-networking, protobuf, vim_configurable
 , gtkmm3, libpeas, gsettings-desktop-schemas
 , python3, python3Packages
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     wrapProgram "$out/bin/astroid" --set CHARSET=en_us.UTF-8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://astroidmail.github.io/";
     description = "GTK frontend to the notmuch mail system";
     maintainers = with maintainers; [ bdimcheff SuprDewd ];
diff --git a/pkgs/applications/networking/mailreaders/balsa/default.nix b/pkgs/applications/networking/mailreaders/balsa/default.nix
index 055aa15b2ec8d..2570e425ae7f5 100644
--- a/pkgs/applications/networking/mailreaders/balsa/default.nix
+++ b/pkgs/applications/networking/mailreaders/balsa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , glib
 , gmime3
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pawsa.fedorapeople.org/balsa/";
     description = "An e-mail client for GNOME";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/networking/mailreaders/evolution/evolution-ews/default.nix b/pkgs/applications/networking/mailreaders/evolution/evolution-ews/default.nix
index d3f5988b4747f..65cb888ad6f7a 100644
--- a/pkgs/applications/networking/mailreaders/evolution/evolution-ews/default.nix
+++ b/pkgs/applications/networking/mailreaders/evolution/evolution-ews/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnome3, cmake, gettext, intltool, pkg-config, evolution-data-server
+{ lib, stdenv, fetchurl, gnome3, cmake, gettext, intltool, pkg-config, evolution-data-server
 , sqlite, gtk3, webkitgtk, libgdata, libmspack }:
 
 stdenv.mkDerivation rec {
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Evolution connector for Microsoft Exchange Server protocols";
     homepage = "https://gitlab.gnome.org/GNOME/evolution-ews";
     license = "LGPL-2.1-only OR LGPL-3.0-only"; # https://gitlab.gnome.org/GNOME/evolution-ews/issues/111
diff --git a/pkgs/applications/networking/mailreaders/lumail/default.nix b/pkgs/applications/networking/mailreaders/lumail/default.nix
index 3dd03c9712032..0929919dcd062 100644
--- a/pkgs/applications/networking/mailreaders/lumail/default.nix
+++ b/pkgs/applications/networking/mailreaders/lumail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, lua, file, ncurses, gmime, pcre-cpp
+{ lib, stdenv, fetchurl, pkgconfig, lua, file, ncurses, gmime, pcre-cpp
 , perl, perlPackages, makeWrapper
 , debugBuild ? false
 , alternativeGlobalConfigFilePath ? null
@@ -72,7 +72,7 @@ stdenv.mkDerivation {
     "LUMAIL_LIBS=$(out)/etc/lumail2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Console-based email client";
     homepage = "https://lumail.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/mailreaders/mailnag/goa-plugin.nix b/pkgs/applications/networking/mailreaders/mailnag/goa-plugin.nix
index b2eccdc134bc8..4f60135cca198 100644
--- a/pkgs/applications/networking/mailreaders/mailnag/goa-plugin.nix
+++ b/pkgs/applications/networking/mailreaders/mailnag/goa-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3Packages
 , gobject-introspection
@@ -21,7 +21,7 @@ python3Packages.buildPythonPackage rec {
     gnome-online-accounts
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mailnag GNOME Online Accounts plugin.";
     homepage = "https://github.com/pulb/mailnag-goa-plugin";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/mailreaders/mailpile/default.nix b/pkgs/applications/networking/mailreaders/mailpile/default.nix
index 6bd0995623db2..3cd02e7467c57 100644
--- a/pkgs/applications/networking/mailreaders/mailpile/default.nix
+++ b/pkgs/applications/networking/mailreaders/mailpile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages, gnupg1orig, openssl, git }:
+{ lib, stdenv, fetchFromGitHub, python2Packages, gnupg1orig, openssl, git }:
 
 python2Packages.buildPythonApplication rec {
   pname = "mailpile";
@@ -39,7 +39,7 @@ python2Packages.buildPythonApplication rec {
   # No tests were found
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern, fast web-mail client with user-friendly encryption and privacy features";
     homepage = "https://www.mailpile.is/";
     license = [ licenses.asl20 licenses.agpl3 ];
diff --git a/pkgs/applications/networking/mailreaders/mailspring/default.nix b/pkgs/applications/networking/mailreaders/mailspring/default.nix
index eb946e267b28a..f0ab5f148f148 100644
--- a/pkgs/applications/networking/mailreaders/mailspring/default.nix
+++ b/pkgs/applications/networking/mailreaders/mailspring/default.nix
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
       --replace /usr/bin $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A beautiful, fast and maintained fork of Nylas Mail by one of the original authors";
     longDescription = ''
       Mailspring is an open-source mail client forked from Nylas Mail and built with Electron.
diff --git a/pkgs/applications/networking/mailreaders/meli/default.nix b/pkgs/applications/networking/mailreaders/meli/default.nix
index 4f3a1ef3901fc..519448c3ade11 100644
--- a/pkgs/applications/networking/mailreaders/meli/default.nix
+++ b/pkgs/applications/networking/mailreaders/meli/default.nix
@@ -49,7 +49,7 @@ rustPlatform.buildRustPackage rec {
     wrapProgram $out/bin/meli --set LD_LIBRARY_PATH ${notmuch}/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Experimental terminal mail client aiming for configurability and extensibility with sane defaults";
     homepage = "https://meli.delivery";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/mailreaders/mlarchive2maildir/default.nix b/pkgs/applications/networking/mailreaders/mlarchive2maildir/default.nix
index ce13a4de8d092..ea10bf8924887 100644
--- a/pkgs/applications/networking/mailreaders/mlarchive2maildir/default.nix
+++ b/pkgs/applications/networking/mailreaders/mlarchive2maildir/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, notmuch }:
+{ lib, stdenv, python3, notmuch }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "mlarchive2maildir";
@@ -19,7 +19,7 @@ python3.pkgs.buildPythonApplication rec {
     six
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/flokli/mlarchive2maildir";
     description = "Imports mail from (pipermail) archives into a maildir";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/mailreaders/mmh/default.nix b/pkgs/applications/networking/mailreaders/mmh/default.nix
index 6bd977bd319b4..5fcc060ffbfdd 100644
--- a/pkgs/applications/networking/mailreaders/mmh/default.nix
+++ b/pkgs/applications/networking/mailreaders/mmh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, autoreconfHook, flex }:
+{ lib, stdenv, fetchurl, ncurses, autoreconfHook, flex }:
 let rev = "431604647f89d5aac7b199a7883e98e56e4ccf9e";
 in stdenv.mkDerivation rec {
   pname = "mmh-unstable";
@@ -18,7 +18,7 @@ in stdenv.mkDerivation rec {
   buildInputs = [ ncurses ];
   nativeBuildInputs = [ autoreconfHook flex ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of electronic mail handling programs";
     homepage = "http://marmaro.de/prog/mmh";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/mailreaders/msgviewer/default.nix b/pkgs/applications/networking/mailreaders/msgviewer/default.nix
index 3461b3b560f95..d3bb47a911bde 100644
--- a/pkgs/applications/networking/mailreaders/msgviewer/default.nix
+++ b/pkgs/applications/networking/mailreaders/msgviewer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, unzip, jre, runtimeShell }:
+{ lib, stdenv, fetchurl, makeWrapper, unzip, jre, runtimeShell }:
 
 let
   version = "1.9";
@@ -28,7 +28,7 @@ in stdenv.mkDerivation {
 
   nativeBuildInputs = [ makeWrapper unzip ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Viewer for .msg files (MS Outlook)";
     homepage    = "https://www.washington.edu/alpine/";
     license     = licenses.asl20;
diff --git a/pkgs/applications/networking/mailreaders/neomutt/default.nix b/pkgs/applications/networking/mailreaders/neomutt/default.nix
index cf78da9a50484..104e0da9a81e4 100644
--- a/pkgs/applications/networking/mailreaders/neomutt/default.nix
+++ b/pkgs/applications/networking/mailreaders/neomutt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gettext, makeWrapper, tcl, which, writeScript
+{ lib, stdenv, fetchFromGitHub, gettext, makeWrapper, tcl, which, writeScript
 , ncurses, perl , cyrus_sasl, gss, gpgme, kerberos, libidn, libxml2, notmuch, openssl
 , lmdb, libxslt, docbook_xsl, docbook_xml_dtd_42, w3m, mailcap, runtimeShell, sqlite, zlib
 , glibcLocales
@@ -94,7 +94,7 @@ stdenv.mkDerivation rec {
   checkTarget = "test";
   postCheck = "unset NEOMUTT_TEST_DIR";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small but very powerful text-based mail client";
     homepage    = "http://www.neomutt.org";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/networking/mailreaders/notmuch-addrlookup/default.nix b/pkgs/applications/networking/mailreaders/notmuch-addrlookup/default.nix
index 19b90b534efb4..fcb92d3fcc119 100644
--- a/pkgs/applications/networking/mailreaders/notmuch-addrlookup/default.nix
+++ b/pkgs/applications/networking/mailreaders/notmuch-addrlookup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, glib, notmuch }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, glib, notmuch }:
 
 let
   version = "9";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   installPhase = "install -D notmuch-addrlookup $out/bin/notmuch-addrlookup";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Address lookup tool for Notmuch in C";
     homepage = "https://github.com/aperezdc/notmuch-addrlookup-c";
     maintainers = with maintainers; [ mog ];
diff --git a/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix b/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix
index 214f4311e6917..2e2b7da9a4ca6 100644
--- a/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix
+++ b/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gawk, mercury, pandoc, ncurses, gpgme }:
+{ lib, stdenv, fetchFromGitHub, gawk, mercury, pandoc, ncurses, gpgme }:
 
 stdenv.mkDerivation rec {
   pname = "notmuch-bower";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/wangp/bower";
     description = "A curses terminal client for the Notmuch email system";
     maintainers = with maintainers; [ erictapen ];
diff --git a/pkgs/applications/networking/mailreaders/thunderbird-bin/68.nix b/pkgs/applications/networking/mailreaders/thunderbird-bin/68.nix
index 47af8a2024390..fafd2c72c8891 100644
--- a/pkgs/applications/networking/mailreaders/thunderbird-bin/68.nix
+++ b/pkgs/applications/networking/mailreaders/thunderbird-bin/68.nix
@@ -1,6 +1,6 @@
 # This pakcage is keeped until Thunderbird 78 supports OpenPGP.
 # https://www.thunderbird.net/en-US/thunderbird/78.0.1/releasenotes/
-{ stdenv, fetchurl, config, makeWrapper
+{ lib, stdenv, fetchurl, config, makeWrapper
 , alsaLib
 , at-spi2-atk
 , atk
@@ -170,7 +170,7 @@ stdenv.mkDerivation {
     basePath = "pkgs/applications/networking/mailreaders/thunderbird-bin";
     baseUrl = "http://archive.mozilla.org/pub/thunderbird/releases/";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mozilla Thunderbird, a full-featured email client (binary package)";
     homepage = "http://www.mozilla.org/thunderbird/";
     license = {
diff --git a/pkgs/applications/networking/mailreaders/thunderbird/68.nix b/pkgs/applications/networking/mailreaders/thunderbird/68.nix
index 60dc12054841b..ec26384261f9f 100644
--- a/pkgs/applications/networking/mailreaders/thunderbird/68.nix
+++ b/pkgs/applications/networking/mailreaders/thunderbird/68.nix
@@ -327,7 +327,7 @@ stdenv.mkDerivation rec {
       gnugrep curl runtimeShell;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full-featured e-mail client";
     homepage = "https://www.thunderbird.net";
     maintainers = with maintainers; [
diff --git a/pkgs/applications/networking/mkchromecast/default.nix b/pkgs/applications/networking/mkchromecast/default.nix
index 34f5be71ef358..b682c9e7351a3 100644
--- a/pkgs/applications/networking/mkchromecast/default.nix
+++ b/pkgs/applications/networking/mkchromecast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3Packages
 , sox
@@ -75,7 +75,7 @@ python3Packages.buildPythonApplication rec {
       --replace './bin/audiodevice' '${placeholder "out"}/bin/audiodevice'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mkchromecast.com/";
     description = "Cast macOS and Linux Audio/Video to your Google Cast and Sonos Devices";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/modem-manager-gui/default.nix b/pkgs/applications/networking/modem-manager-gui/default.nix
index 64b1be363f34d..2b4dabbedc5de 100644
--- a/pkgs/applications/networking/modem-manager-gui/default.nix
+++ b/pkgs/applications/networking/modem-manager-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pkgconfig
 , python3
 , fetchFromGitLab
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     patchShebangs man/manhelper.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An app to send/receive SMS, make USSD requests, control mobile data usage and more";
     longDescription = ''
       A simple GTK based GUI compatible with Modem manager, Wader and oFono
diff --git a/pkgs/applications/networking/msmtp/default.nix b/pkgs/applications/networking/msmtp/default.nix
index a9d2158d20a47..468e65cf4d8ce 100644
--- a/pkgs/applications/networking/msmtp/default.nix
+++ b/pkgs/applications/networking/msmtp/default.nix
@@ -49,7 +49,7 @@ in stdenv.mkDerivation rec {
     chmod +x $out/bin/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple and easy to use SMTP client with excellent sendmail compatibility";
     homepage = "https://marlam.de/msmtp/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/mullvad-vpn/default.nix b/pkgs/applications/networking/mullvad-vpn/default.nix
index e6f5d6ac4ea27..8b78c49a2f573 100644
--- a/pkgs/applications/networking/mullvad-vpn/default.nix
+++ b/pkgs/applications/networking/mullvad-vpn/default.nix
@@ -80,7 +80,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mullvad/mullvadvpn-app";
     description = "Client for Mullvad VPN";
     changelog = "https://github.com/mullvad/mullvadvpn-app/blob/${version}/CHANGELOG.md";
diff --git a/pkgs/applications/networking/ndppd/default.nix b/pkgs/applications/networking/ndppd/default.nix
index 931453624811e..ccaf3e0bbbb8b 100644
--- a/pkgs/applications/networking/ndppd/default.nix
+++ b/pkgs/applications/networking/ndppd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gzip }:
+{ lib, stdenv, fetchFromGitHub, gzip }:
 
 stdenv.mkDerivation rec {
   pname = "ndppd";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp ndppd.conf-dist $out/etc/ndppd.conf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon that proxies NDP (Neighbor Discovery Protocol) messages between interfaces";
     homepage = "https://github.com/DanielAdolfsson/ndppd";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/newsreaders/liferea/default.nix b/pkgs/applications/networking/newsreaders/liferea/default.nix
index 8ec4608023750..f4e4c8279de84 100644
--- a/pkgs/applications/networking/newsreaders/liferea/default.nix
+++ b/pkgs/applications/networking/newsreaders/liferea/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkg-config
 , intltool
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     gappsWrapperArgs+=(--prefix PYTHONPATH : "$program_PYTHONPATH")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GTK-based news feed aggregator";
     homepage = "http://lzone.de/liferea/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/networking/newsreaders/pan/default.nix b/pkgs/applications/networking/newsreaders/pan/default.nix
index 6dc0630d2db2f..ef022306d4bfe 100644
--- a/pkgs/applications/networking/newsreaders/pan/default.nix
+++ b/pkgs/applications/networking/newsreaders/pan/default.nix
@@ -1,5 +1,5 @@
 { spellChecking ? true
-, stdenv, fetchurl, pkgconfig, gtk3, gtkspell3 ? null
+, lib, stdenv, fetchurl, pkgconfig, gtk3, gtkspell3 ? null
 , gmime2, gettext, intltool, itstool, libxml2, libnotify, gnutls
 , makeWrapper, gnupg
 , gnomeSupport ? true, libsecret, gcr
@@ -37,7 +37,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GTK-based Usenet newsreader good at both text and binaries";
     homepage = "http://pan.rebelbase.com/";
     maintainers = [ maintainers.eelco ];
diff --git a/pkgs/applications/networking/newsreaders/quiterss/default.nix b/pkgs/applications/networking/newsreaders/quiterss/default.nix
index 1cc4be8cb27ac..176ce43af5f75 100644
--- a/pkgs/applications/networking/newsreaders/quiterss/default.nix
+++ b/pkgs/applications/networking/newsreaders/quiterss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qmake, pkg-config, wrapQtAppsHook
+{ lib, stdenv, fetchFromGitHub, qmake, pkg-config, wrapQtAppsHook
 , qtbase, qttools, qtwebkit, sqlite
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ qmake pkg-config wrapQtAppsHook ];
   buildInputs = [ qtbase qttools qtwebkit sqlite.dev ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Qt-based RSS/Atom news feed reader";
     longDescription = ''
       QuiteRSS is a open-source cross-platform RSS/Atom news feeds reader
diff --git a/pkgs/applications/networking/newsreaders/slrn/default.nix b/pkgs/applications/networking/newsreaders/slrn/default.nix
index 1cc9c39c991d5..e49ffe15ee28a 100644
--- a/pkgs/applications/networking/newsreaders/slrn/default.nix
+++ b/pkgs/applications/networking/newsreaders/slrn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , slang, ncurses, openssl }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ slang ncurses openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The slrn (S-Lang read news) newsreader";
     homepage = "http://slrn.sourceforge.net/index.html";
     maintainers = with maintainers; [ ehmry ];
diff --git a/pkgs/applications/networking/offrss/default.nix b/pkgs/applications/networking/offrss/default.nix
index 03159a61a404c..19de00d7436ea 100644
--- a/pkgs/applications/networking/offrss/default.nix
+++ b/pkgs/applications/networking/offrss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, curl, libmrss, podofo, libiconv }:
+{ lib, stdenv, fetchurl, curl, libmrss, podofo, libiconv }:
 
 stdenv.mkDerivation {
   name = "offrss-1.3";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     sha256 = "1akw1x84jj2m9z60cvlvmz21qwlaywmw18pl7lgp3bj5nw6250p6";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://vicerveza.homeunix.net/~viric/cgi-bin/offrss";
     description = "Offline RSS/Atom reader";
     license = licenses.agpl3Plus;
diff --git a/pkgs/applications/networking/omping/default.nix b/pkgs/applications/networking/omping/default.nix
index 33d5a5f511118..7e7cd47dbd0ab 100644
--- a/pkgs/applications/networking/omping/default.nix
+++ b/pkgs/applications/networking/omping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "omping";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open Multicast Ping (omping) is a tool for testing IPv4/IPv6 multicast connectivity on a LAN";
     license = licenses.mit;
     platforms = platforms.unix;
diff --git a/pkgs/applications/networking/openbazaar/client.nix b/pkgs/applications/networking/openbazaar/client.nix
index 1d055520d1f6c..4352c44f72a42 100644
--- a/pkgs/applications/networking/openbazaar/client.nix
+++ b/pkgs/applications/networking/openbazaar/client.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gcc-unwrapped
 , dpkg
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [ gcc-unwrapped.lib ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Decentralized Peer to Peer Marketplace for Bitcoin - client";
     homepage = "https://www.openbazaar.org/";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/openbazaar/default.nix b/pkgs/applications/networking/openbazaar/default.nix
index aa341b292245a..caddae6d7752c 100644
--- a/pkgs/applications/networking/openbazaar/default.nix
+++ b/pkgs/applications/networking/openbazaar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 }:
 
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
       $out/bin/openbazaard
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Decentralized Peer to Peer Marketplace for Bitcoin - daemon";
     homepage = "https://www.openbazaar.org/";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/owamp/default.nix b/pkgs/applications/networking/owamp/default.nix
index 3608ef982a9b8..24369bfc8d552 100644
--- a/pkgs/applications/networking/owamp/default.nix
+++ b/pkgs/applications/networking/owamp/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub
+{lib, stdenv, fetchFromGitHub
 , autoconf, automake, mandoc }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     ./bootstrap
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://software.internet2.edu/owamp/";
     description = ''A tool for performing one-way active measurements'';
     platforms = platforms.linux;
diff --git a/pkgs/applications/networking/owncloud-client/default.nix b/pkgs/applications/networking/owncloud-client/default.nix
index ed8826729ccfd..c1711497f781b 100644
--- a/pkgs/applications/networking/owncloud-client/default.nix
+++ b/pkgs/applications/networking/owncloud-client/default.nix
@@ -21,7 +21,7 @@ mkDerivation rec {
     "-DNO_SHIBBOLETH=1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Synchronise your ownCloud with your computer using this desktop client";
     homepage = "https://owncloud.org";
     maintainers = [ maintainers.qknight ];
diff --git a/pkgs/applications/networking/p2p/deluge/1.nix b/pkgs/applications/networking/p2p/deluge/1.nix
index aa70f969d221a..4171efb7ce293 100644
--- a/pkgs/applications/networking/p2p/deluge/1.nix
+++ b/pkgs/applications/networking/p2p/deluge/1.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, intltool, libtorrent-rasterbar, pythonPackages }:
+{ lib, stdenv, fetchurl, fetchpatch, intltool, libtorrent-rasterbar, pythonPackages }:
 
 pythonPackages.buildPythonPackage rec {
   pname = "deluge";
@@ -31,7 +31,7 @@ pythonPackages.buildPythonPackage rec {
      cp deluge/data/share/applications/deluge.desktop $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://deluge-torrent.org";
     description = "Torrent client";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/p2p/deluge/default.nix b/pkgs/applications/networking/p2p/deluge/default.nix
index f9c421c408735..068776fe17a66 100644
--- a/pkgs/applications/networking/p2p/deluge/default.nix
+++ b/pkgs/applications/networking/p2p/deluge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, libtorrent-rasterbar, pythonPackages
+{ lib, stdenv, fetchurl, intltool, libtorrent-rasterbar, pythonPackages
 , gtk3, glib, gobject-introspection, librsvg, wrapGAppsHook }:
 
 pythonPackages.buildPythonPackage rec {
@@ -34,7 +34,7 @@ pythonPackages.buildPythonPackage rec {
      cp deluge/ui/data/share/applications/deluge.desktop $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://deluge-torrent.org";
     description = "Torrent client";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/p2p/eiskaltdcpp/default.nix b/pkgs/applications/networking/p2p/eiskaltdcpp/default.nix
index 7bb0866e12f9e..7c5ffabd860f1 100644
--- a/pkgs/applications/networking/p2p/eiskaltdcpp/default.nix
+++ b/pkgs/applications/networking/p2p/eiskaltdcpp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, qt4, boost, bzip2, libX11
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, qt4, boost, bzip2, libX11
 , fetchpatch, libiconv, pcre-cpp, libidn, lua5, miniupnpc, aspell, gettext }:
 
 stdenv.mkDerivation rec {
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     "-DWITH_LUASCRIPTS=ON"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cross-platform program that uses the Direct Connect and ADC protocols";
     homepage = "https://github.com/eiskaltdcpp/eiskaltdcpp";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/p2p/frostwire/default.nix b/pkgs/applications/networking/p2p/frostwire/default.nix
index 65e2165f64eee..4253969a30ad2 100644
--- a/pkgs/applications/networking/p2p/frostwire/default.nix
+++ b/pkgs/applications/networking/p2p/frostwire/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gradle, perl, jre, makeWrapper, makeDesktopItem, mplayer }:
+{ lib, stdenv, fetchFromGitHub, gradle, perl, jre, makeWrapper, makeDesktopItem, mplayer }:
 
 let
   version = "6.6.7-build-529";
@@ -84,7 +84,7 @@ in stdenv.mkDerivation {
       --add-flags "-Djava.library.path=$out/lib -jar $out/share/java/frostwire.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.frostwire.com/";
     description = "BitTorrent Client and Cloud File Downloader";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/p2p/frostwire/frostwire-bin.nix b/pkgs/applications/networking/p2p/frostwire/frostwire-bin.nix
index 8ef8740f4d2ac..3dbbbbe072d20 100644
--- a/pkgs/applications/networking/p2p/frostwire/frostwire-bin.nix
+++ b/pkgs/applications/networking/p2p/frostwire/frostwire-bin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 with stdenv.lib;
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${jre}/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.frostwire.com/";
     description = "BitTorrent Client and Cloud File Downloader";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/p2p/gnunet/default.nix b/pkgs/applications/networking/p2p/gnunet/default.nix
index 618ca07491257..20fb5d4e79c22 100644
--- a/pkgs/applications/networking/p2p/gnunet/default.nix
+++ b/pkgs/applications/networking/p2p/gnunet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, adns, curl, gettext, gmp, gnutls, libextractor
+{ lib, stdenv, fetchurl, adns, curl, gettext, gmp, gnutls, libextractor
 , libgcrypt, libgnurl, libidn, libmicrohttpd, libtool, libunistring
 , makeWrapper, ncurses, pkgconfig, libxml2, sqlite, zlib
 , libpulseaudio, libopus, libogg, jansson, libsodium }:
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     make -k check
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNU's decentralized anonymous and censorship-resistant P2P framework";
 
     longDescription = ''
diff --git a/pkgs/applications/networking/p2p/ncdc/default.nix b/pkgs/applications/networking/p2p/ncdc/default.nix
index c956f26b11653..e479da0f22a85 100644
--- a/pkgs/applications/networking/p2p/ncdc/default.nix
+++ b/pkgs/applications/networking/p2p/ncdc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, zlib, bzip2, sqlite, pkgconfig, glib, gnutls }:
+{ lib, stdenv, fetchurl, ncurses, zlib, bzip2, sqlite, pkgconfig, glib, gnutls }:
 
 stdenv.mkDerivation rec {
   pname = "ncdc";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ ncurses zlib bzip2 sqlite glib gnutls ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern and lightweight direct connect client with a friendly ncurses interface";
     homepage = "https://dev.yorhel.nl/ncdc";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/p2p/opentracker/default.nix b/pkgs/applications/networking/p2p/opentracker/default.nix
index 8beb2f7d37705..4e127a1e7b8a5 100644
--- a/pkgs/applications/networking/p2p/opentracker/default.nix
+++ b/pkgs/applications/networking/p2p/opentracker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, libowfat, zlib }:
+{ lib, stdenv, fetchgit, libowfat, zlib }:
 
 stdenv.mkDerivation {
   name = "opentracker-2018-05-26";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://erdgeist.org/arts/software/opentracker/";
     license = licenses.beerware;
     platforms = platforms.linux;
diff --git a/pkgs/applications/networking/p2p/retroshare/default.nix b/pkgs/applications/networking/p2p/retroshare/default.nix
index a6a0ab2728739..412016e4877a5 100644
--- a/pkgs/applications/networking/p2p/retroshare/default.nix
+++ b/pkgs/applications/networking/p2p/retroshare/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libupnp, gpgme, gnome3, glib, libssh, pkgconfig, protobuf, bzip2
+{ lib, stdenv, fetchFromGitHub, libupnp, gpgme, gnome3, glib, libssh, pkgconfig, protobuf, bzip2
 , libXScrnSaver, speex, curl, libxml2, libxslt, sqlcipher, libmicrohttpd, opencv, qmake, ffmpeg_3
 , qtmultimedia, qtx11extras, qttools }:
 
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     cp libbitdht/src/bitdht/bdboot.txt $out/share/retroshare
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "";
     homepage = "http://retroshare.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/networking/p2p/stig/default.nix b/pkgs/applications/networking/p2p/stig/default.nix
index d06a4d4d418a9..08da6cdf6fab4 100644
--- a/pkgs/applications/networking/p2p/stig/default.nix
+++ b/pkgs/applications/networking/p2p/stig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3Packages
 }:
@@ -59,7 +59,7 @@ python3Packages.buildPythonApplication rec {
     "--deselect=tests/client_test/aiotransmission_test/rpc_test.py"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TUI and CLI for the BitTorrent client Transmission";
     homepage = "https://github.com/rndusr/stig";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/p2p/synapse-bt/default.nix b/pkgs/applications/networking/p2p/synapse-bt/default.nix
index e2847d88f8a78..ae2c3c2469fc5 100644
--- a/pkgs/applications/networking/p2p/synapse-bt/default.nix
+++ b/pkgs/applications/networking/p2p/synapse-bt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, CoreServices, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, CoreServices, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "synapse-bt";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoBuildFlags = [ "--all" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flexible and fast BitTorrent daemon";
     homepage = "https://synapse-bt.org/";
     license = licenses.isc;
diff --git a/pkgs/applications/networking/p2p/tixati/default.nix b/pkgs/applications/networking/p2p/tixati/default.nix
index f8a70d322f03d..7152570b6aca0 100644
--- a/pkgs/applications/networking/p2p/tixati/default.nix
+++ b/pkgs/applications/networking/p2p/tixati/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glib, zlib, dbus, dbus-glib, gtk2, gdk-pixbuf, cairo, pango }:
+{ lib, stdenv, fetchurl, glib, zlib, dbus, dbus-glib, gtk2, gdk-pixbuf, cairo, pango }:
 
 stdenv.mkDerivation rec {
   pname = "tixati";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Torrent client";
     homepage = "http://www.tixati.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/p2p/torrential/default.nix b/pkgs/applications/networking/p2p/torrential/default.nix
index d62e3b3b5a3f4..ef2b97563bbcd 100644
--- a/pkgs/applications/networking/p2p/torrential/default.nix
+++ b/pkgs/applications/networking/p2p/torrential/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , cmake
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Download torrents in style with this speedy, minimalist torrent client for elementary OS";
     homepage = "https://github.com/davidmhewitt/torrential";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/networking/p2p/transmission-remote-gtk/default.nix b/pkgs/applications/networking/p2p/transmission-remote-gtk/default.nix
index 8e74b82b69d38..fe93657048a91 100644
--- a/pkgs/applications/networking/p2p/transmission-remote-gtk/default.nix
+++ b/pkgs/applications/networking/p2p/transmission-remote-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoconf, automake, libtool, wrapGAppsHook, fetchFromGitHub, pkgconfig
+{ lib, stdenv, autoconf, automake, libtool, wrapGAppsHook, fetchFromGitHub, pkgconfig
 , intltool, gtk3, json-glib, curl, glib, autoconf-archive, appstream-glib, fetchpatch }:
 
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false; # fails with style validation error
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK remote control for the Transmission BitTorrent client";
     homepage = "https://github.com/ajf8/transmission-remote-gtk";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/p2p/tremc/default.nix b/pkgs/applications/networking/p2p/tremc/default.nix
index 485366afe939a..4d3b3d3f374d5 100644
--- a/pkgs/applications/networking/p2p/tremc/default.nix
+++ b/pkgs/applications/networking/p2p/tremc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages
+{ lib, stdenv, fetchFromGitHub, python3Packages
 , x11Support ? !stdenv.isDarwin
 , xclip ? null
 , pbcopy ? null
@@ -41,7 +41,7 @@ python3Packages.buildPythonApplication rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Curses interface for transmission";
     homepage = "https://github.com/tremc/tremc";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/p2p/tribler/default.nix b/pkgs/applications/networking/p2p/tribler/default.nix
index 83f517e625a4a..474d6a0c9f10a 100644
--- a/pkgs/applications/networking/p2p/tribler/default.nix
+++ b/pkgs/applications/networking/p2p/tribler/default.nix
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
     cp $out/Tribler/Main/Build/Ubuntu/tribler.1 $out/share/man/man1/tribler.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ xvapx ];
     homepage = "https://www.tribler.org/";
     description = "A completely decentralised P2P filesharing client based on the Bittorrent protocol";
diff --git a/pkgs/applications/networking/p2p/vuze/default.nix b/pkgs/applications/networking/p2p/vuze/default.nix
index be2421ef4d264..557914439a9cc 100644
--- a/pkgs/applications/networking/p2p/vuze/default.nix
+++ b/pkgs/applications/networking/p2p/vuze/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchsvn, jdk, jre, ant, swt, makeWrapper }:
+{ lib, stdenv, fetchsvn, jdk, jre, ant, swt, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "vuze";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       --add-flags "-Xmx256m -Djava.library.path=${swt}/lib -cp $out/share/java/Vuze_${version}-00.jar:${swt}/jars/swt.jar org.gudy.azureus2.ui.swt.Main"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Torrent client";
     homepage = "http://www.vuze.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/p2p/zeronet/default.nix b/pkgs/applications/networking/p2p/zeronet/default.nix
index ce5a99b1e5fc5..7deddf8578bb0 100644
--- a/pkgs/applications/networking/p2p/zeronet/default.nix
+++ b/pkgs/applications/networking/p2p/zeronet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "zeronet";
@@ -32,7 +32,7 @@ python3Packages.buildPythonApplication rec {
       --set PATH ${python3Packages.python}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Decentralized websites using Bitcoin crypto and BitTorrent network";
     homepage = "https://zeronet.io/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/pcloud/default.nix b/pkgs/applications/networking/pcloud/default.nix
index 1b094fc442a65..4229fef4fe6f8 100644
--- a/pkgs/applications/networking/pcloud/default.nix
+++ b/pkgs/applications/networking/pcloud/default.nix
@@ -16,7 +16,7 @@
 
 {
   # Build dependencies
-  appimageTools, autoPatchelfHook, fetchzip, stdenv,
+  appimageTools, autoPatchelfHook, fetchzip, lib, stdenv,
 
   # Runtime dependencies;
   # A few additional ones (e.g. Node) are already shipped together with the
@@ -100,7 +100,7 @@ in stdenv.mkDerivation {
     chmod +x bin/pcloud
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Secure and simple to use cloud storage for your files; pCloud Drive, Electron Edition";
     homepage = "https://www.pcloud.com/";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/ping/default.nix b/pkgs/applications/networking/ping/default.nix
index 8e4125ac72aad..a2d614ff54205 100644
--- a/pkgs/applications/networking/ping/default.nix
+++ b/pkgs/applications/networking/ping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A helpful tool that lets you debug what part of your API is causing you issues";
     homepage = "https://github.com/jeremyvaartjes/ping";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/networking/pjsip/default.nix b/pkgs/applications/networking/pjsip/default.nix
index 7319dd4a44fa3..60b94bbf7f944 100644
--- a/pkgs/applications/networking/pjsip/default.nix
+++ b/pkgs/applications/networking/pjsip/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, libsamplerate, alsaLib, AppKit }:
+{ lib, stdenv, fetchFromGitHub, openssl, libsamplerate, alsaLib, AppKit }:
 
 stdenv.mkDerivation rec {
   pname = "pjsip";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
   # We need the libgcc_s.so.1 loadable (for pthread_cancel to work)
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multimedia communication library written in C, implementing standard based protocols such as SIP, SDP, RTP, STUN, TURN, and ICE";
     homepage = "https://pjsip.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/networking/protocol/default.nix b/pkgs/applications/networking/protocol/default.nix
index 31b1bd6086ad5..70723f486460a 100644
--- a/pkgs/applications/networking/protocol/default.nix
+++ b/pkgs/applications/networking/protocol/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub }:
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub }:
 
 buildPythonApplication {
   pname = "protocol-unstable";
@@ -11,7 +11,7 @@ buildPythonApplication {
     sha256 = "13l10jhf4vghanmhh3pn91b2jdciispxy0qadz4n08blp85qn9cm";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ASCII Header Generator for Network Protocols";
     homepage = "https://github.com/luismartingarcia/protocol";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/ps2client/default.nix b/pkgs/applications/networking/ps2client/default.nix
index 444a6dcf45c7d..87d4e75c33e3a 100644
--- a/pkgs/applications/networking/ps2client/default.nix
+++ b/pkgs/applications/networking/ps2client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   version = "unstable-2018-10-18";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     make PREFIX=$out install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop clients to interact with ps2link and ps2netfs";
     homepage = "https://github.com/ps2dev/ps2client";
     license = licenses.bsd3;
diff --git a/pkgs/applications/networking/pyload/default.nix b/pkgs/applications/networking/pyload/default.nix
index e81b8dc37ca50..dcfa88d9d4cd2 100644
--- a/pkgs/applications/networking/pyload/default.nix
+++ b/pkgs/applications/networking/pyload/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, pythonPackages, gocr, unrar, rhino, spidermonkey_38 }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, pythonPackages, gocr, unrar, rhino, spidermonkey_38 }:
 
 let
   beautifulsoup = pythonPackages.callPackage ./beautifulsoup.nix {
@@ -50,7 +50,7 @@ in pythonPackages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free and open source downloader for 1-click-hosting sites";
     homepage = "https://github.com/pyload/pyload";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/qv2ray/default.nix b/pkgs/applications/networking/qv2ray/default.nix
index f4d41ee79e6df..fa8609ef532c6 100644
--- a/pkgs/applications/networking/qv2ray/default.nix
+++ b/pkgs/applications/networking/qv2ray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchFromGitHub
 , qmake
@@ -56,7 +56,7 @@ mkDerivation rec {
     qttools
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An GUI frontend to v2ray";
     homepage = "https://qv2ray.github.io/en/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/remote/anydesk/default.nix b/pkgs/applications/networking/remote/anydesk/default.nix
index 643efd0f0f276..50516eab2f0ec 100644
--- a/pkgs/applications/networking/remote/anydesk/default.nix
+++ b/pkgs/applications/networking/remote/anydesk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, makeDesktopItem
+{ lib, stdenv, fetchurl, makeWrapper, makeDesktopItem
 , atk, cairo, gdk-pixbuf, glib, gnome2, gtk2, libGLU, libGL, pango, xorg
 , lsb-release, freetype, fontconfig, polkit, polkit_gnome
 , pulseaudio }:
@@ -79,7 +79,7 @@ in stdenv.mkDerivation rec {
       --subst-var out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit description;
     homepage = "https://www.anydesk.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/remote/nice-dcv-client/default.nix b/pkgs/applications/networking/remote/nice-dcv-client/default.nix
index 19e65c0bdb3db..3344174cb2a01 100644
--- a/pkgs/applications/networking/remote/nice-dcv-client/default.nix
+++ b/pkgs/applications/networking/remote/nice-dcv-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , glib
 , libX11
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
     rm $out/lib64/dcvviewer/gio/modules/libdconfsettings.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-performance remote display protocol";
     homepage = "https://aws.amazon.com/hpc/dcv/";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/remote/vmware-horizon-client/default.nix b/pkgs/applications/networking/remote/vmware-horizon-client/default.nix
index 09b7011c3164a..7d5b965e60fef 100644
--- a/pkgs/applications/networking/remote/vmware-horizon-client/default.nix
+++ b/pkgs/applications/networking/remote/vmware-horizon-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildFHSUserEnv, fetchurl, makeWrapper, makeDesktopItem, libxslt, atk
+{ lib, stdenv, buildFHSUserEnv, fetchurl, makeWrapper, makeDesktopItem, libxslt, atk
 , fontconfig, freetype, gdk-pixbuf, glib, gtk2, libudev0-shim, libxml2
 , pango, pixman, libX11, libXext, libXinerama, libXrandr , libXrender
 , libXtst, libXcursor, libXi, libxkbfile , libXScrnSaver, zlib, liberation_ttf
@@ -70,7 +70,7 @@ in stdenv.mkDerivation {
     ln -s "${vmwareFHSUserEnv}/bin/vmware-view" "$out/bin/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows you to connect to your VMware Horizon virtual desktop";
     homepage = "https://www.vmware.com/go/viewclients";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/remote/waypipe/default.nix b/pkgs/applications/networking/remote/waypipe/default.nix
index d325351982631..fcbad67038cec 100644
--- a/pkgs/applications/networking/remote/waypipe/default.nix
+++ b/pkgs/applications/networking/remote/waypipe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab
+{ lib, stdenv, fetchFromGitLab
 , meson, ninja, pkg-config, scdoc
 , openssh
 , mesa, lz4, zstd, ffmpeg, libva
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     mesa lz4 zstd ffmpeg libva
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A network proxy for Wayland clients (applications)";
     longDescription = ''
       waypipe is a proxy for Wayland clients. It forwards Wayland messages and
diff --git a/pkgs/applications/networking/remote/wayvnc/default.nix b/pkgs/applications/networking/remote/wayvnc/default.nix
index e8fbec0d91a95..aa15ea97ecb62 100644
--- a/pkgs/applications/networking/remote/wayvnc/default.nix
+++ b/pkgs/applications/networking/remote/wayvnc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, pkg-config, ninja, scdoc
+{ lib, stdenv, fetchFromGitHub, meson, pkg-config, ninja, scdoc
 , pixman, libxkbcommon, wayland, neatvnc, libdrm, libX11, aml
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson pkg-config ninja scdoc wayland ];
   buildInputs = [ pixman libxkbcommon wayland neatvnc libdrm libX11 aml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A VNC server for wlroots based Wayland compositors";
     longDescription = ''
       This is a VNC server for wlroots based Wayland compositors. It attaches
diff --git a/pkgs/applications/networking/remote/x2goclient/default.nix b/pkgs/applications/networking/remote/x2goclient/default.nix
index 047458067357c..6401393acda5a 100644
--- a/pkgs/applications/networking/remote/x2goclient/default.nix
+++ b/pkgs/applications/networking/remote/x2goclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, cups, libssh, libXpm, nx-libs, openldap, openssh
+{ lib, stdenv, fetchgit, cups, libssh, libXpm, nx-libs, openldap, openssh
 , mkDerivation, qtbase, qtsvg, qtx11extras, qttools, phonon, pkgconfig }:
 
 mkDerivation {
@@ -30,7 +30,7 @@ mkDerivation {
 
   qtWrapperArgs = [ ''--suffix PATH : ${nx-libs}/bin:${openssh}/libexec'' ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical NoMachine NX3 remote desktop client";
     homepage = "http://x2go.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/remote/x2goserver/default.nix b/pkgs/applications/networking/remote/x2goserver/default.nix
index 1c20bd8b7a828..f30b21464e378 100644
--- a/pkgs/applications/networking/remote/x2goserver/default.nix
+++ b/pkgs/applications/networking/remote/x2goserver/default.nix
@@ -83,7 +83,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Remote desktop application, server component";
     homepage = "http://x2go.org/";
     platforms = stdenv.lib.platforms.linux;
diff --git a/pkgs/applications/networking/remote/xrdp/default.nix b/pkgs/applications/networking/remote/xrdp/default.nix
index 9941951225ca3..faa65379de493 100644
--- a/pkgs/applications/networking/remote/xrdp/default.nix
+++ b/pkgs/applications/networking/remote/xrdp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, which, perl, autoconf, automake, libtool, openssl, systemd, pam, fuse, libjpeg, libopus, nasm, xorg }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, which, perl, autoconf, automake, libtool, openssl, systemd, pam, fuse, libjpeg, libopus, nasm, xorg }:
 
 let
   xorgxrdp = stdenv.mkDerivation rec {
@@ -94,7 +94,7 @@ let
 
     enableParallelBuilding = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "An open source RDP server";
       homepage = "https://github.com/neutrinolabs/xrdp";
       license = licenses.asl20;
diff --git a/pkgs/applications/networking/resilio-sync/default.nix b/pkgs/applications/networking/resilio-sync/default.nix
index 537e0fc818004..ecdc216073770 100644
--- a/pkgs/applications/networking/resilio-sync/default.nix
+++ b/pkgs/applications/networking/resilio-sync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ... }:
+{ lib, stdenv, fetchurl, ... }:
 
 let
   arch = {
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
       --set-rpath ${libPath} "$out/bin/rslsync"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically sync files via secure, distributed technology";
     homepage    = "https://www.resilio.com/";
     license     = licenses.unfreeRedistributable;
diff --git a/pkgs/applications/networking/scaleft/default.nix b/pkgs/applications/networking/scaleft/default.nix
index b1a754193ebfd..67fb66feabb76 100644
--- a/pkgs/applications/networking/scaleft/default.nix
+++ b/pkgs/applications/networking/scaleft/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, rpmextract, patchelf, bash }:
+{ lib, stdenv, fetchurl, rpmextract, patchelf, bash }:
 
 stdenv.mkDerivation rec {
   pname = "scaleft";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     patchShebangs $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ScaleFT provides Zero Trust software which you can use to secure your internal servers and services";
     homepage = "https://www.scaleft.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/networking/shellhub-agent/default.nix b/pkgs/applications/networking/shellhub-agent/default.nix
index 0aa78482e5aca..db9e112a06398 100644
--- a/pkgs/applications/networking/shellhub-agent/default.nix
+++ b/pkgs/applications/networking/shellhub-agent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , genericUpdater
@@ -31,7 +31,7 @@ buildGoModule rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Enables easy access any Linux device behind firewall and NAT";
     longDescription = ''
diff --git a/pkgs/applications/networking/sieve-connect/default.nix b/pkgs/applications/networking/sieve-connect/default.nix
index c81cc78a9b551..d4866d9f1a41e 100644
--- a/pkgs/applications/networking/sieve-connect/default.nix
+++ b/pkgs/applications/networking/sieve-connect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, perlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "sieve-connect";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
         TermReadKey TermReadLineGnu ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A client for the MANAGESIEVE Protocol";
     longDescription = ''
       This is sieve-connect. A client for the ManageSieve protocol,
diff --git a/pkgs/applications/networking/sniffers/etherape/default.nix b/pkgs/applications/networking/sniffers/etherape/default.nix
index 4cc4487c90ada..aba93e2d6d0b7 100644
--- a/pkgs/applications/networking/sniffers/etherape/default.nix
+++ b/pkgs/applications/networking/sniffers/etherape/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libtool, gtk3, libpcap, goocanvas2,
+{ lib, stdenv, fetchurl, pkgconfig, libtool, gtk3, libpcap, goocanvas2,
 popt, itstool, libxml2 }:
 
 stdenv.mkDerivation rec {
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     libtool gtk3 libpcap goocanvas2 popt
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://etherape.sourceforge.net/";
     license = stdenv.lib.licenses.gpl2Plus;
     platforms = with platforms; linux;
diff --git a/pkgs/applications/networking/sniffers/ettercap/default.nix b/pkgs/applications/networking/sniffers/ettercap/default.nix
index 8489b414cbc59..d3bfc148c42fe 100644
--- a/pkgs/applications/networking/sniffers/ettercap/default.nix
+++ b/pkgs/applications/networking/sniffers/ettercap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libpcap, libnet, zlib, curl, pcre
+{ lib, stdenv, fetchFromGitHub, cmake, libpcap, libnet, zlib, curl, pcre
 , openssl, ncurses, glib, gtk3, atk, pango, flex, bison, geoip, harfbuzz
 , pkgconfig }:
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   # TODO: Remove after the next release (0.8.4 should work without this):
   NIX_CFLAGS_COMPILE = [ "-I${harfbuzz.dev}/include/harfbuzz" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Comprehensive suite for man in the middle attacks";
     longDescription = ''
       Ettercap is a comprehensive suite for man in the middle attacks. It
diff --git a/pkgs/applications/networking/sniffers/kismet/default.nix b/pkgs/applications/networking/sniffers/kismet/default.nix
index 61d149ba5b8ea..56260bd06fa63 100644
--- a/pkgs/applications/networking/sniffers/kismet/default.nix
+++ b/pkgs/applications/networking/sniffers/kismet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libpcap, pcre, libnl, zlib, libmicrohttpd
+{ lib, stdenv, fetchurl, pkgconfig, libpcap, pcre, libnl, zlib, libmicrohttpd
 , sqlite, protobuf, protobufc, libusb1, libcap, binutils, elfutils
 , withNetworkManager ? false, glib, networkmanager
 , withPython ? false, python3
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wireless network sniffer";
     homepage = "https://www.kismetwireless.net/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/sniffers/sngrep/default.nix b/pkgs/applications/networking/sniffers/sngrep/default.nix
index 9dda62b3badbf..b7a17896ec337 100644
--- a/pkgs/applications/networking/sniffers/sngrep/default.nix
+++ b/pkgs/applications/networking/sniffers/sngrep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoconf, automake, fetchFromGitHub, libpcap, ncurses, openssl, pcre }:
+{ lib, stdenv, autoconf, automake, fetchFromGitHub, libpcap, ncurses, openssl, pcre }:
 
 stdenv.mkDerivation rec {
   pname = "sngrep";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "./bootstrap.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for displaying SIP calls message flows from terminal";
     homepage = "https://github.com/irontec/sngrep";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/sniffers/whsniff/default.nix b/pkgs/applications/networking/sniffers/whsniff/default.nix
index d2e5803d58a13..6674808e91ba8 100644
--- a/pkgs/applications/networking/sniffers/whsniff/default.nix
+++ b/pkgs/applications/networking/sniffers/whsniff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libusb1 }:
+{ lib, stdenv, fetchFromGitHub, libusb1 }:
 
 stdenv.mkDerivation rec {
   pname = "whsniff";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/homewsn/whsniff";
     description = "Packet sniffer for 802.15.4 wireless networks";
     maintainers = with maintainers; [ snicket2100 ];
diff --git a/pkgs/applications/networking/sniffers/wireshark/default.nix b/pkgs/applications/networking/sniffers/wireshark/default.nix
index c5008bf0790bb..0497472b90e31 100644
--- a/pkgs/applications/networking/sniffers/wireshark/default.nix
+++ b/pkgs/applications/networking/sniffers/wireshark/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, pcre, perl, flex, bison, gettext, libpcap, libnl, c-ares
+{ lib, stdenv, fetchurl, pkgconfig, pcre, perl, flex, bison, gettext, libpcap, libnl, c-ares
 , gnutls, libgcrypt, libgpgerror, geoip, openssl, lua5, python3, libcap, glib
 , libssh, nghttp2, zlib, cmake, fetchpatch, makeWrapper
 , withQt ? true, qt5 ? null
@@ -99,7 +99,7 @@ in stdenv.mkDerivation {
     export WIRESHARK_RUN_FROM_BUILD_DIRECTORY=1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.wireshark.org/";
     description = "Powerful network protocol analyzer";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/sniproxy/default.nix b/pkgs/applications/networking/sniproxy/default.nix
index 301802d322bd9..f3eae72970fb6 100644
--- a/pkgs/applications/networking/sniproxy/default.nix
+++ b/pkgs/applications/networking/sniproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, gettext, libev, pcre, pkgconfig, udns }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, gettext, libev, pcre, pkgconfig, udns }:
 
 stdenv.mkDerivation rec {
   pname = "sniproxy";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ gettext libev pcre udns ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Transparent TLS and HTTP layer 4 proxy with SNI support";
     license = licenses.bsd2;
diff --git a/pkgs/applications/networking/soapui/default.nix b/pkgs/applications/networking/soapui/default.nix
index 32a6423243e6b..12301981f6537 100644
--- a/pkgs/applications/networking/soapui/default.nix
+++ b/pkgs/applications/networking/soapui/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, writeText, jdk, maven, makeWrapper }:
+{ fetchurl, lib, stdenv, writeText, jdk, maven, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "soapui";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     '')
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Most Advanced REST & SOAP Testing Tool in the World";
     homepage = "https://www.soapui.org/";
     license = "SoapUI End User License Agreement";
diff --git a/pkgs/applications/networking/super-productivity/default.nix b/pkgs/applications/networking/super-productivity/default.nix
index 3c4c0f0df3c05..065caa3d77e50 100644
--- a/pkgs/applications/networking/super-productivity/default.nix
+++ b/pkgs/applications/networking/super-productivity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg, makeWrapper
+{ lib, stdenv, fetchurl, dpkg, makeWrapper
 , alsaLib, atk, cairo, cups, curl, dbus, expat, fontconfig, freetype, glib
 , gnome2, gtk3, gdk-pixbuf, libnotify, libxcb, nspr, nss, pango
 , systemd, xorg, xprintidle-ng }:
@@ -96,7 +96,7 @@ in stdenv.mkDerivation {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "To Do List / Time Tracker with Jira Integration";
     homepage = "https://super-productivity.com";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/sync/acd_cli/default.nix b/pkgs/applications/networking/sync/acd_cli/default.nix
index c95647c784057..2f83873fbf8ef 100644
--- a/pkgs/applications/networking/sync/acd_cli/default.nix
+++ b/pkgs/applications/networking/sync/acd_cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonApplication, fuse
+{ lib, stdenv, fetchFromGitHub, buildPythonApplication, fuse
 , appdirs, colorama, dateutil, requests, requests_toolbelt
 , fusepy, sqlalchemy }:
 
@@ -30,7 +30,7 @@ buildPythonApplication rec {
     lnOverBin acd_cli.py acdcli
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line interface and FUSE filesystem for Amazon Cloud Drive";
     homepage = "https://github.com/yadayada/acd_cli";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/sync/casync/default.nix b/pkgs/applications/networking/sync/casync/default.nix
index 461de492ae2db..847e5c21da8ca 100644
--- a/pkgs/applications/networking/sync/casync/default.nix
+++ b/pkgs/applications/networking/sync/casync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, ninja, pkgconfig, python3, sphinx
 , acl, curl, fuse, libselinux, udev, xz, zstd
 , fuseSupport ? true
@@ -42,7 +42,7 @@ stdenv.mkDerivation {
     export LC_ALL="en_US.utf-8"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Content-Addressable Data Synchronizer";
     homepage    = "https://github.com/systemd/casync";
     license     = licenses.lgpl21;
diff --git a/pkgs/applications/networking/sync/desync/default.nix b/pkgs/applications/networking/sync/desync/default.nix
index 7f7d2fb277a19..689a2b3fddaaf 100644
--- a/pkgs/applications/networking/sync/desync/default.nix
+++ b/pkgs/applications/networking/sync/desync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "desync";
@@ -16,7 +16,7 @@ buildGoModule rec {
   # nix builder doesn't have access to test data; tests fail for reasons unrelated to binary being bad.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Content-addressed binary distribution system";
     longDescription = "An alternate implementation of the casync protocol and storage mechanism with a focus on production-readiness";
     homepage = "https://github.com/folbricht/desync";
diff --git a/pkgs/applications/networking/sync/lsyncd/default.nix b/pkgs/applications/networking/sync/lsyncd/default.nix
index 9573e1717de90..06371f80ffe98 100644
--- a/pkgs/applications/networking/sync/lsyncd/default.nix
+++ b/pkgs/applications/networking/sync/lsyncd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, cmake, lua, pkgconfig, rsync,
+{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, lua, pkgconfig, rsync,
   asciidoc, libxml2, docbook_xml_dtd_45, docbook_xsl, libxslt }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     asciidoc libxml2 docbook_xml_dtd_45 docbook_xsl libxslt
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/axkibe/lsyncd";
     description = "A utility that synchronizes local directories with remote targets";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/sync/onedrive/default.nix b/pkgs/applications/networking/sync/onedrive/default.nix
index b41178922af98..a6175af3511d5 100644
--- a/pkgs/applications/networking/sync/onedrive/default.nix
+++ b/pkgs/applications/networking/sync/onedrive/default.nix
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     installShellCompletion --zsh  --name _${pname} contrib/completions/complete.zsh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A complete tool to interact with OneDrive on Linux";
     homepage = "https://github.com/abraunegg/onedrive";
     license = licenses.gpl3;
diff --git a/pkgs/applications/networking/sync/rclone/browser.nix b/pkgs/applications/networking/sync/rclone/browser.nix
index fb2020f0d3a20..8dbbc0cf2218d 100644
--- a/pkgs/applications/networking/sync/rclone/browser.nix
+++ b/pkgs/applications/networking/sync/rclone/browser.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, wrapQtAppsHook, qtbase }:
+{ lib, stdenv, fetchFromGitHub, cmake, wrapQtAppsHook, qtbase }:
 
 stdenv.mkDerivation rec {
   pname = "rclone-browser";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ qtbase ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Graphical Frontend to Rclone written in Qt";
     license = licenses.unlicense;
diff --git a/pkgs/applications/networking/sync/rclone/default.nix b/pkgs/applications/networking/sync/rclone/default.nix
index 2f0a9a044f24d..75c6e877a1f22 100644
--- a/pkgs/applications/networking/sync/rclone/default.nix
+++ b/pkgs/applications/networking/sync/rclone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, buildPackages, installShellFiles }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, buildPackages, installShellFiles }:
 
 buildGoModule rec {
   pname = "rclone";
@@ -36,7 +36,7 @@ buildGoModule rec {
       done
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line program to sync files and directories to and from major cloud storage";
     homepage = "https://rclone.org";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/sync/rsync/base.nix b/pkgs/applications/networking/sync/rsync/base.nix
index da00b4cbc2eee..7c7d3a1f418e2 100644
--- a/pkgs/applications/networking/sync/rsync/base.nix
+++ b/pkgs/applications/networking/sync/rsync/base.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 rec {
   version = "3.2.3";
@@ -13,7 +13,7 @@ rec {
     sha256 = "1wj21v57v135n6fnmlm2dxmb9lhrrg62jgkggldp1gb7d6s4arny";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast incremental file transfer utility";
     homepage = "https://rsync.samba.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/sync/rsync/default.nix b/pkgs/applications/networking/sync/rsync/default.nix
index e07fecbf89363..f8fe9b6669660 100644
--- a/pkgs/applications/networking/sync/rsync/default.nix
+++ b/pkgs/applications/networking/sync/rsync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, libiconv, zlib, popt
+{ lib, stdenv, fetchurl, perl, libiconv, zlib, popt
 , enableACLs ? !(stdenv.isDarwin || stdenv.isSunOS || stdenv.isFreeBSD), acl ? null
 , enableLZ4 ? true, lz4 ? null
 , enableOpenSSL ? true, openssl ? null
@@ -15,7 +15,7 @@ assert enableXXHash -> xxHash != null;
 assert enableZstd -> zstd != null;
 
 let
-  base = import ./base.nix { inherit stdenv fetchurl; };
+  base = import ./base.nix { inherit lib stdenv fetchurl; };
 in
 stdenv.mkDerivation rec {
   name = "rsync-${base.version}";
diff --git a/pkgs/applications/networking/sync/rsync/rrsync.nix b/pkgs/applications/networking/sync/rsync/rrsync.nix
index 19be478b0f1e1..2ec940d52a8b7 100644
--- a/pkgs/applications/networking/sync/rsync/rrsync.nix
+++ b/pkgs/applications/networking/sync/rsync/rrsync.nix
@@ -1,7 +1,7 @@
-{ stdenv, fetchurl, perl, rsync }:
+{ lib, stdenv, fetchurl, perl, rsync }:
 
 let
-  base = import ./base.nix { inherit stdenv fetchurl; };
+  base = import ./base.nix { inherit stdenv lib fetchurl; };
 in
 stdenv.mkDerivation {
   name = "rrsync-${base.version}";
diff --git a/pkgs/applications/networking/syncthing-gtk/default.nix b/pkgs/applications/networking/syncthing-gtk/default.nix
index e432b37951725..a7f9c5f9f4be9 100644
--- a/pkgs/applications/networking/syncthing-gtk/default.nix
+++ b/pkgs/applications/networking/syncthing-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, libnotify, librsvg, killall
+{ lib, stdenv, fetchFromGitHub, fetchpatch, libnotify, librsvg, killall
 , gtk3, libappindicator-gtk3, substituteAll, syncthing, wrapGAppsHook
 , gnome3, buildPythonApplication, dateutil, pyinotify, pygobject3
 , bcrypt, gobject-introspection, gsettings-desktop-schemas
@@ -55,7 +55,7 @@ buildPythonApplication rec {
     substituteInPlace syncthing-gtk.desktop --replace "/usr/bin/syncthing-gtk" "$out/bin/syncthing-gtk"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK3 & python based GUI for Syncthing";
     homepage = "https://github.com/syncthing/syncthing-gtk";
     license = licenses.gpl2;
diff --git a/pkgs/applications/networking/termius/default.nix b/pkgs/applications/networking/termius/default.nix
index b4907cc8bdaee..ff4a847aefe55 100644
--- a/pkgs/applications/networking/termius/default.nix
+++ b/pkgs/applications/networking/termius/default.nix
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
       "''${gappsWrapperArgs[@]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true;
     description = "A cross-platform SSH client with cloud data sync and more";
     homepage = "https://termius.com/";
diff --git a/pkgs/applications/networking/testssl/default.nix b/pkgs/applications/networking/testssl/default.nix
index 0e0727d464f80..611f4cf0c1f71 100644
--- a/pkgs/applications/networking/testssl/default.nix
+++ b/pkgs/applications/networking/testssl/default.nix
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/testssl.sh --prefix PATH ':' ${lib.makeBinPath buildInputs}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI tool to check a server's TLS/SSL capabilities";
     longDescription = ''
       CLI tool which checks a server's service on any port for the support of
diff --git a/pkgs/applications/networking/tsung/default.nix b/pkgs/applications/networking/tsung/default.nix
index 7b142249687da..41bc6c64da806 100644
--- a/pkgs/applications/networking/tsung/default.nix
+++ b/pkgs/applications/networking/tsung/default.nix
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
         --set PERL5LIB "${perlPackages.makePerlPath [ perlPackages.TemplateToolkit ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://tsung.erlang-projects.org/";
     description = "A high-performance benchmark framework for various protocols including HTTP, XMPP, LDAP, etc";
     longDescription = ''
diff --git a/pkgs/applications/networking/umurmur/default.nix b/pkgs/applications/networking/umurmur/default.nix
index d16c1bb944a2d..05aa66eb39cbb 100644
--- a/pkgs/applications/networking/umurmur/default.nix
+++ b/pkgs/applications/networking/umurmur/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, openssl, protobufc, libconfig }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, openssl, protobufc, libconfig }:
 
 stdenv.mkDerivation rec {
   pname = "umurmur";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "--enable-shmapi"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minimalistic Murmur (Mumble server)";
     license = licenses.bsd3;
     homepage = "https://github.com/umurmur/umurmur";
diff --git a/pkgs/applications/networking/versus/default.nix b/pkgs/applications/networking/versus/default.nix
index 1d2875e44e643..5e1b1e873c936 100644
--- a/pkgs/applications/networking/versus/default.nix
+++ b/pkgs/applications/networking/versus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "versus";
@@ -13,7 +13,7 @@ buildGoModule rec {
 
   vendorSha256 = "1d12jcd8crxcgp5m8ga691wivim4cg8cbz4pzgxp0jhzg9jplpbv";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Benchmark multiple API endpoints against each other";
     homepage = "https://github.com/INFURA/versus";
     license = licenses.mit;
diff --git a/pkgs/applications/networking/vnstat/default.nix b/pkgs/applications/networking/vnstat/default.nix
index cd0f65d4d4549..1db6943264269 100644
--- a/pkgs/applications/networking/vnstat/default.nix
+++ b/pkgs/applications/networking/vnstat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gd, ncurses, sqlite, check }:
+{ lib, stdenv, fetchurl, pkgconfig, gd, ncurses, sqlite, check }:
 
 stdenv.mkDerivation rec {
   pname = "vnstat";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Console-based network statistics utility for Linux";
     longDescription = ''
       vnStat is a console-based network traffic monitor for Linux and BSD that
diff --git a/pkgs/applications/networking/weather/meteo/default.nix b/pkgs/applications/networking/weather/meteo/default.nix
index c0591f24c96d9..3393dea929e6d 100644
--- a/pkgs/applications/networking/weather/meteo/default.nix
+++ b/pkgs/applications/networking/weather/meteo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, vala, python3, pkgconfig, meson, ninja, gtk3
+{ lib, stdenv, fetchFromGitLab, vala, python3, pkgconfig, meson, ninja, gtk3
 , json-glib, libsoup, webkitgtk, geocode-glib, nix-update-script
 , libappindicator, desktop-file-utils, appstream, wrapGAppsHook }:
 
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Know the forecast of the next hours & days";
     homepage = "https://gitlab.com/bitseater/meteo";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/networking/znc/default.nix b/pkgs/applications/networking/znc/default.nix
index 3487c72d40873..7e5231285451f 100644
--- a/pkgs/applications/networking/znc/default.nix
+++ b/pkgs/applications/networking/znc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, pkgconfig
+{ lib, stdenv, fetchurl, openssl, pkgconfig
 , withPerl ? false, perl
 , withPython ? false, python3
 , withTcl ? false, tcl
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
   ] ++ optional (!withIPv6) [ "--disable-ipv6" ]
     ++ optional withDebug [ "--enable-debug" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced IRC bouncer";
     homepage = "https://wiki.znc.in/ZNC";
     maintainers = with maintainers; [ schneefux lnl7 ];
diff --git a/pkgs/applications/networking/znc/modules.nix b/pkgs/applications/networking/znc/modules.nix
index c045598fc3b50..964afa459f4c0 100644
--- a/pkgs/applications/networking/znc/modules.nix
+++ b/pkgs/applications/networking/znc/modules.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, znc }:
+{ lib, stdenv, fetchFromGitHub, znc }:
 
 let
   zncDerivation = a@{
@@ -29,7 +29,7 @@ in {
       sha256 = "1k7ifpqqzzf2j7w795q4mx1nvmics2higzjqr3mid3lp43sqg5s6";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Request backlog for IRC channels.";
       homepage = "https://github.com/fruitiex/znc-backlog/";
       license = licenses.asl20;
@@ -49,7 +49,7 @@ in {
       sha256 = "1jaspnrbv3pzsnbysqygc8s8g3q07zx5nlrdpgwv9j8aryg0pcnh";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "ZNC module for client specific buffers";
       homepage = "https://github.com/CyberShadow/znc-clientbuffer";
       license = licenses.asl20;
@@ -69,7 +69,7 @@ in {
       sha256 = "0ikd3dzjjlr0gs0ikqfk50msm6mij99ln2rjzqavh58iwzr7n5r8";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "ZNC clientaway module";
       homepage = "https://github.com/kylef/znc-contrib";
       license = licenses.gpl2;
@@ -109,7 +109,7 @@ in {
       sha256 = "0ikd3dzjjlr0gs0ikqfk50msm6mij99ln2rjzqavh58iwzr7n5r8";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "ZNC ignore module";
       homepage = "https://github.com/kylef/znc-contrib";
       license = licenses.gpl2;
@@ -129,7 +129,7 @@ in {
       sha256 = "1gjr8yqgpkpcc18rf0zfgil3rcd1ihqk0q9f8rwbfvs5381h3c58";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Palaver ZNC module";
       homepage = "https://github.com/cocodelabs/znc-palaver";
       license = licenses.mit;
@@ -149,7 +149,7 @@ in {
       sha256 = "0mgfajljy035051b2sx70i8xrb51zw9q2z64kf85zw1lynihzyh4";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "An advanced playback module for ZNC";
       homepage = "https://github.com/jpnurmi/znc-playback";
       license = licenses.asl20;
diff --git a/pkgs/applications/office/abiword/default.nix b/pkgs/applications/office/abiword/default.nix
index 4aa3f936b539d..1a9073056e77c 100644
--- a/pkgs/applications/office/abiword/default.nix
+++ b/pkgs/applications/office/abiword/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk3, fribidi
+{ lib, stdenv, fetchurl, pkgconfig, gtk3, fribidi
 , libpng, popt, libgsf, enchant, wv, librsvg, bzip2, libjpeg, perl
 , boost, libxslt, goffice, wrapGAppsHook, gnome3
 }:
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     libgsf enchant wv libjpeg perl boost libxslt goffice gnome3.adwaita-icon-theme
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Word processing program, similar to Microsoft Word";
     homepage = "https://www.abisource.com/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/office/aesop/default.nix b/pkgs/applications/office/aesop/default.nix
index 0e76c101545b0..aefa786d06091 100644
--- a/pkgs/applications/office/aesop/default.nix
+++ b/pkgs/applications/office/aesop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, vala, fetchFromGitHub, nix-update-script, pantheon, pkgconfig, meson, ninja, python3, gtk3
+{ lib, stdenv, vala, fetchFromGitHub, nix-update-script, pantheon, pkgconfig, meson, ninja, python3, gtk3
 , desktop-file-utils, json-glib, libsoup, libgee, poppler, wrapGAppsHook, fetchpatch }:
 
 stdenv.mkDerivation rec {
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The simplest PDF viewer around";
     homepage = "https://github.com/lainsce/aesop";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/office/agenda/default.nix b/pkgs/applications/office/agenda/default.nix
index 32cb2988ae301..9308fc6c6eac4 100644
--- a/pkgs/applications/office/agenda/default.nix
+++ b/pkgs/applications/office/agenda/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple, fast, no-nonsense to-do (task) list designed for elementary OS";
     homepage = "https://github.com/dahenson/agenda";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/office/atlassian-cli/default.nix b/pkgs/applications/office/atlassian-cli/default.nix
index ec8e2b396c589..d743baaed7e49 100644
--- a/pkgs/applications/office/atlassian-cli/default.nix
+++ b/pkgs/applications/office/atlassian-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jre }:
+{ lib, stdenv, fetchzip, jre }:
 
 stdenv.mkDerivation rec {
   pname = "atlassian-cli";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An integrated family of CLI’s for various Atlassian applications";
     homepage = "https://bobswift.atlassian.net/wiki/spaces/ACLI/overview";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/applications/office/beamerpresenter/default.nix b/pkgs/applications/office/beamerpresenter/default.nix
index d18a757f6bb82..c07b4c5e1aa19 100644
--- a/pkgs/applications/office/beamerpresenter/default.nix
+++ b/pkgs/applications/office/beamerpresenter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, installShellFiles,
+{ lib, stdenv, mkDerivation, fetchFromGitHub, installShellFiles,
   qmake, qtbase, poppler, qtmultimedia }:
 
 mkDerivation rec {
@@ -30,7 +30,7 @@ mkDerivation rec {
     installManPage man/*.{1,5}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple dual screen pdf presentation software";
     homepage = "https://github.com/stiglers-eponym/BeamerPresenter";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/office/bookworm/default.nix b/pkgs/applications/office/bookworm/default.nix
index 90b6c2fefc532..e6fa2884febb6 100644
--- a/pkgs/applications/office/bookworm/default.nix
+++ b/pkgs/applications/office/bookworm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pantheon, vala, python3, python2, pkgconfig, libxml2, meson, ninja, gtk3, gnome3, glib, webkitgtk, libgee
+{ lib, stdenv, fetchFromGitHub, pantheon, vala, python3, python2, pkgconfig, libxml2, meson, ninja, gtk3, gnome3, glib, webkitgtk, libgee
 , gobject-introspection, sqlite, poppler, poppler_utils, html2text, curl, gnugrep, coreutils, bash, unzip, unar, wrapGAppsHook
 , appstream, desktop-file-utils }:
 
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     patchShebangs $out/share/bookworm/scripts/tasks/*.sh
   '';
 
-   meta = with stdenv.lib; {
+   meta = with lib; {
      description = "A simple, focused eBook reader";
      longDescription = ''
        Read the books you love without having to worry about different format complexities like epub, pdf, mobi, cbr, etc.
diff --git a/pkgs/applications/office/cb2bib/default.nix b/pkgs/applications/office/cb2bib/default.nix
index f5b8b437249f2..e57d490f05c14 100644
--- a/pkgs/applications/office/cb2bib/default.nix
+++ b/pkgs/applications/office/cb2bib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qmake, qtbase, qtwebkit, qtx11extras, lzo, libX11 }:
+{ lib, stdenv, fetchurl, qmake, qtbase, qtwebkit, qtx11extras, lzo, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "cb2bib";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     runHook postConfigure
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rapidly extract unformatted, or unstandardized bibliographic references from email alerts, journal Web pages and PDF files";
     homepage = "http://www.molspaces.com/d_cb2bib-overview.php";
     maintainers = with maintainers; [ edwtjo ];
diff --git a/pkgs/applications/office/docear/default.nix b/pkgs/applications/office/docear/default.nix
index fb9578c909dfd..e14fee010e87f 100644
--- a/pkgs/applications/office/docear/default.nix
+++ b/pkgs/applications/office/docear/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, runtimeShell, makeWrapper
+{lib, stdenv, fetchurl, runtimeShell, makeWrapper
 , oraclejre
 , antialiasFont ? true
 }:
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
     chmod 0755 $out/bin/docear
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A unique solution to academic literature management";
     homepage = "http://www.docear.org/";
     # Licenses at: http://www.docear.org/software/download/
diff --git a/pkgs/applications/office/elementary-planner/default.nix b/pkgs/applications/office/elementary-planner/default.nix
index acade32d744dc..ff40d944c8321 100644
--- a/pkgs/applications/office/elementary-planner/default.nix
+++ b/pkgs/applications/office/elementary-planner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -66,7 +66,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Task manager with Todoist support designed for GNU/Linux 🚀️";
     homepage = "https://planner-todo.web.app";
     license = licenses.gpl3;
diff --git a/pkgs/applications/office/envelope/default.nix b/pkgs/applications/office/envelope/default.nix
index 450b52bc0ca11..6dc46d9dec6c6 100644
--- a/pkgs/applications/office/envelope/default.nix
+++ b/pkgs/applications/office/envelope/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Personal finance manager for elementary OS";
     homepage = "https://github.com/cjfloss/envelope";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/office/espanso/default.nix b/pkgs/applications/office/espanso/default.nix
index 14ac9ccbb30ea..594c95d3d9558 100644
--- a/pkgs/applications/office/espanso/default.nix
+++ b/pkgs/applications/office/espanso/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , pkgconfig
@@ -42,7 +42,7 @@ rustPlatform.buildRustPackage rec {
   # Some tests require networking
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform Text Expander written in Rust";
     homepage = "https://espanso.org";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/office/flexibee/default.nix b/pkgs/applications/office/flexibee/default.nix
index 52e58c5c9ccb2..9dbdae3f0206f 100644
--- a/pkgs/applications/office/flexibee/default.nix
+++ b/pkgs/applications/office/flexibee/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 let
   version = "2020.2.6";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client for an accouting economic system";
     homepage = "https://www.flexibee.eu/";
     license = licenses.unfree;
diff --git a/pkgs/applications/office/gnumeric/default.nix b/pkgs/applications/office/gnumeric/default.nix
index b0609863c5adb..ab8ec82124487 100644
--- a/pkgs/applications/office/gnumeric/default.nix
+++ b/pkgs/applications/office/gnumeric/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkg-config, intltool, perlPackages
+{ lib, stdenv, fetchurl, pkg-config, intltool, perlPackages
 , goffice, gnome3, wrapGAppsHook, gtk3, bison, python3Packages
 , itstool
 }:
@@ -32,7 +32,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The GNOME Office Spreadsheet";
     license = stdenv.lib.licenses.gpl2Plus;
     homepage = "http://projects.gnome.org/gnumeric/";
diff --git a/pkgs/applications/office/grisbi/default.nix b/pkgs/applications/office/grisbi/default.nix
index 812218d0a38fa..f52f9a3e90995 100644
--- a/pkgs/applications/office/grisbi/default.nix
+++ b/pkgs/applications/office/grisbi/default.nix
@@ -1,5 +1,5 @@
 { fetchurl
-, stdenv
+, lib, stdenv
 , gtk
 , pkgconfig
 , libgsf
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     gnome3.adwaita-icon-theme
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A personnal accounting application";
     longDescription = ''
       Grisbi is an application written by French developers, so it perfectly
diff --git a/pkgs/applications/office/gtg/default.nix b/pkgs/applications/office/gtg/default.nix
index 31266bf6142b1..52558df5da810 100644
--- a/pkgs/applications/office/gtg/default.nix
+++ b/pkgs/applications/office/gtg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , python3Packages
@@ -61,7 +61,7 @@ python3Packages.buildPythonApplication rec {
 
   checkPhase = "xvfb-run python3 ../run-tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = " A personal tasks and TODO-list items organizer";
     longDescription = ''
       "Getting Things GNOME" (GTG) is a personal tasks and ToDo list organizer inspired by the "Getting Things Done" (GTD) methodology.
diff --git a/pkgs/applications/office/homebank/default.nix b/pkgs/applications/office/homebank/default.nix
index dcda1c41e3c65..a0df714411421 100644
--- a/pkgs/applications/office/homebank/default.nix
+++ b/pkgs/applications/office/homebank/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, gtk, pkgconfig, libofx, intltool, wrapGAppsHook
+{ fetchurl, lib, stdenv, gtk, pkgconfig, libofx, intltool, wrapGAppsHook
 , libsoup, gnome3 }:
 
 stdenv.mkDerivation rec {
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ gtk libofx intltool libsoup
     gnome3.adwaita-icon-theme ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free, easy, personal accounting for everyone";
     homepage = "http://homebank.free.fr/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/office/ib/controller/default.nix b/pkgs/applications/office/ib/controller/default.nix
index 7be7e4467b52f..35aebf2326062 100644
--- a/pkgs/applications/office/ib/controller/default.nix
+++ b/pkgs/applications/office/ib/controller/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, jdk, ib-tws, xpra }:
+{ lib, stdenv, fetchurl, unzip, jdk, ib-tws, xpra }:
 
 stdenv.mkDerivation rec {
   version = "2.14.0";
@@ -152,7 +152,7 @@ stdenv.mkDerivation rec {
     '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automation Controller for the Trader Work Station of Interactive Brokers";
     homepage = "https://github.com/ib-controller/ib-controller";
     license = licenses.gpl3;
diff --git a/pkgs/applications/office/ib/tws/default.nix b/pkgs/applications/office/ib/tws/default.nix
index b8b31bed7c5e0..403f675cb4ee3 100644
--- a/pkgs/applications/office/ib/tws/default.nix
+++ b/pkgs/applications/office/ib/tws/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, requireFile, jdk }:
+{ lib, stdenv, requireFile, jdk }:
 
 stdenv.mkDerivation rec {
   version = "9542";
@@ -86,7 +86,7 @@ stdenv.mkDerivation rec {
     chmod u+x $out/bin/ib-gw
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Trader Work Station of Interactive Brokers";
     homepage = "https://www.interactivebrokers.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/office/jabref/default.nix b/pkgs/applications/office/jabref/default.nix
index 03da2170b3d35..c593111f2f4af 100644
--- a/pkgs/applications/office/jabref/default.nix
+++ b/pkgs/applications/office/jabref/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, makeDesktopItem, wrapGAppsHook, gtk3, gsettings-desktop-schemas
+{ lib, stdenv, fetchurl, makeWrapper, makeDesktopItem, wrapGAppsHook, gtk3, gsettings-desktop-schemas
 , zlib , libX11, libXext, libXi, libXrender, libXtst, libGL, alsaLib, libav, cairo, freetype, pango, gdk-pixbuf, glib }:
 
 stdenv.mkDerivation rec {
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
     cp unpacked/org.jabref/icons/jabref.svg $out/share/icons/jabref.svg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source bibliography reference manager";
     homepage = "https://www.jabref.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/office/jameica/default.nix b/pkgs/applications/office/jameica/default.nix
index 6dc124c6a2001..1585ebb4da736 100644
--- a/pkgs/applications/office/jameica/default.nix
+++ b/pkgs/applications/office/jameica/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeDesktopItem, makeWrapper, ant, jdk, jre, gtk2, glib, xorg, Cocoa }:
+{ lib, stdenv, fetchFromGitHub, makeDesktopItem, makeWrapper, ant, jdk, jre, gtk2, glib, xorg, Cocoa }:
 
 let
   _version = "2.8.6";
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
       --run "cd $out/share/java/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.willuhn.de/products/jameica/";
     description = "Free Runtime Environment for Java Applications";
     longDescription = ''
diff --git a/pkgs/applications/office/khronos/default.nix b/pkgs/applications/office/khronos/default.nix
index b5cb94cda9b2f..d35f8eec2eb17 100644
--- a/pkgs/applications/office/khronos/default.nix
+++ b/pkgs/applications/office/khronos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Track each task's time in a simple inobtrusive way";
     homepage = "https://github.com/lainsce/khronos";
     maintainers = with maintainers; [ xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/office/ledger-autosync/default.nix b/pkgs/applications/office/ledger-autosync/default.nix
index 3a0f362dcf724..57d7e78d32ae1 100644
--- a/pkgs/applications/office/ledger-autosync/default.nix
+++ b/pkgs/applications/office/ledger-autosync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, ledger, hledger, useLedger ? true, useHledger ? true }:
+{ lib, stdenv, python3Packages, fetchFromGitHub, ledger, hledger, useLedger ? true, useHledger ? true }:
 
 python3Packages.buildPythonApplication rec {
   pname = "ledger-autosync";
@@ -42,7 +42,7 @@ python3Packages.buildPythonApplication rec {
     nosetests -a generic -a ledger -a hledger
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/egh/ledger-autosync";
     description = "OFX/CSV autosync for ledger and hledger";
     license = licenses.gpl3;
diff --git a/pkgs/applications/office/marp/default.nix b/pkgs/applications/office/marp/default.nix
index 5b05a9f164b74..e498f39949b9b 100644
--- a/pkgs/applications/office/marp/default.nix
+++ b/pkgs/applications/office/marp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, atomEnv, libXScrnSaver, gtk2 }:
+{ lib, stdenv, fetchurl, atomEnv, libXScrnSaver, gtk2 }:
 
 stdenv.mkDerivation rec {
   pname = "marp";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
       $out/bin/Marp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Markdown presentation writer, powered by Electron";
     homepage = "https://yhatt.github.io/marp/";
     license = licenses.mit;
diff --git a/pkgs/applications/office/mendeley/default.nix b/pkgs/applications/office/mendeley/default.nix
index 192585bd4b5ee..45af12ae0e350 100644
--- a/pkgs/applications/office/mendeley/default.nix
+++ b/pkgs/applications/office/mendeley/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, mkDerivation, dpkg, which
+{ fetchurl, lib, stdenv, mkDerivation, dpkg, which
 , makeWrapper
 , alsaLib
 , desktop-file-utils
@@ -136,7 +136,7 @@ mkDerivation {
 
   updateScript = import ./update.nix { inherit writeScript runtimeShell; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.mendeley.com";
     description = "A reference manager and academic social network";
     license = licenses.unfree;
diff --git a/pkgs/applications/office/moneyplex/default.nix b/pkgs/applications/office/moneyplex/default.nix
index 85d9715bf396c..cdea3cede11d0 100644
--- a/pkgs/applications/office/moneyplex/default.nix
+++ b/pkgs/applications/office/moneyplex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, patchelf, coreutils, pcsclite
+{ lib, stdenv, fetchurl, patchelf, coreutils, pcsclite
 , zlib, glib, gdk-pixbuf, gtk2, cairo, pango, libX11, atk, openssl
 , runtimeShell }:
 
@@ -111,7 +111,7 @@ stdenv.mkDerivation {
     '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Moneyplex online banking software";
     maintainers = with maintainers; [ tstrobel ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/office/mytetra/default.nix b/pkgs/applications/office/mytetra/default.nix
index 45d9e29ebe9a8..f48ec3fb237c6 100644
--- a/pkgs/applications/office/mytetra/default.nix
+++ b/pkgs/applications/office/mytetra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, qmake, qtsvg, makeWrapper, xdg_utils }:
+{ lib, stdenv, mkDerivation, fetchurl, qmake, qtsvg, makeWrapper, xdg_utils }:
 
 let
   version = "1.44.55";
@@ -29,7 +29,7 @@ in mkDerivation {
       --prefix PATH : ${xdg_utils}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Smart manager for information collecting";
     homepage = "https://webhamster.ru/site/page/index/articles/projectcode/138";
     license = licenses.gpl3;
diff --git a/pkgs/applications/office/notes-up/default.nix b/pkgs/applications/office/notes-up/default.nix
index 6936387fb3cca..291e6f394930b 100644
--- a/pkgs/applications/office/notes-up/default.nix
+++ b/pkgs/applications/office/notes-up/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Markdown notes editor and manager designed for elementary OS"
     + stdenv.lib.optionalString withPantheon " - built with Contractor support";
     homepage = "https://github.com/Philip-Scott/Notes-up";
diff --git a/pkgs/applications/office/osmo/default.nix b/pkgs/applications/office/osmo/default.nix
index 507acb862a929..3513e44ed0c0f 100644
--- a/pkgs/applications/office/osmo/default.nix
+++ b/pkgs/applications/office/osmo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk3, libxml2, gettext, libical, libnotify
+{ lib, stdenv, fetchurl, pkgconfig, gtk3, libxml2, gettext, libical, libnotify
 , libarchive, gspell, webkitgtk, libgringotts, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ gtk3 libxml2 libical libnotify libarchive
     gspell webkitgtk libgringotts ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A handy personal organizer";
     homepage = "http://clayo.org/osmo/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/office/p3x-onenote/default.nix b/pkgs/applications/office/p3x-onenote/default.nix
index 55854be1020f9..1653e9ec8223b 100644
--- a/pkgs/applications/office/p3x-onenote/default.nix
+++ b/pkgs/applications/office/p3x-onenote/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appimageTools, desktop-file-utils, fetchurl }:
+{ lib, stdenv, appimageTools, desktop-file-utils, fetchurl }:
 
 let
   version = "2020.10.111";
@@ -45,7 +45,7 @@ appimageTools.wrapType2 rec {
       --delete-original $out/p3x-onenote.desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/patrikx3/onenote";
     description = "Linux Electron Onenote - A Linux compatible version of OneNote";
     license = licenses.mit;
diff --git a/pkgs/applications/office/pinpoint/default.nix b/pkgs/applications/office/pinpoint/default.nix
index ce175d8517f51..6326df87ed2ea 100644
--- a/pkgs/applications/office/pinpoint/default.nix
+++ b/pkgs/applications/office/pinpoint/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, pkgconfig, autoconf, automake, clutter, clutter-gst
+{ fetchurl, lib, stdenv, pkgconfig, autoconf, automake, clutter, clutter-gst
 , gdk-pixbuf, cairo, clutter-gtk }:
 
 stdenv.mkDerivation rec {
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ autoconf automake clutter clutter-gst gdk-pixbuf
                   cairo clutter-gtk ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/action/show/Apps/Pinpoint";
     description = "A tool for making hackers do excellent presentations";
     license = licenses.lgpl21;
diff --git a/pkgs/applications/office/planner/default.nix b/pkgs/applications/office/planner/default.nix
index f33946d6b5a2d..dab567db898c7 100644
--- a/pkgs/applications/office/planner/default.nix
+++ b/pkgs/applications/office/planner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , pkgconfig
 , intltool
@@ -56,7 +56,7 @@ in stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Planner";
     description = "Project management application for GNOME";
     longDescription = ''
diff --git a/pkgs/applications/office/portfolio/default.nix b/pkgs/applications/office/portfolio/default.nix
index d89284f90e5bf..e9ab18f638f97 100644
--- a/pkgs/applications/office/portfolio/default.nix
+++ b/pkgs/applications/office/portfolio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoPatchelfHook
 , fetchurl
 , glibc
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     ln -s $out/portfolio/icon.xpm $out/share/pixmaps/portfolio.xpm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple tool to calculate the overall performance of an investment portfolio";
     homepage = "https://www.portfolio-performance.info/";
     license = licenses.epl10;
diff --git a/pkgs/applications/office/scribus/unstable.nix b/pkgs/applications/office/scribus/unstable.nix
index bb855feebab5f..8745dd37c98da 100644
--- a/pkgs/applications/office/scribus/unstable.nix
+++ b/pkgs/applications/office/scribus/unstable.nix
@@ -22,7 +22,7 @@
 , qtbase
 , qtimageformats
 , qttools
-, stdenv
+, lib, stdenv
 }:
 
 let
@@ -70,7 +70,7 @@ mkDerivation rec {
     qttools
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [
       erictapen
       kiwi
diff --git a/pkgs/applications/office/skanlite/default.nix b/pkgs/applications/office/skanlite/default.nix
index 8e583f99a1a4b..7436054715d89 100644
--- a/pkgs/applications/office/skanlite/default.nix
+++ b/pkgs/applications/office/skanlite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, cmake, extra-cmake-modules, qtbase,
+{ lib, stdenv, mkDerivation, fetchurl, cmake, extra-cmake-modules, qtbase,
   kcoreaddons, kdoctools, ki18n, kio, kxmlgui, ktextwidgets,
   libksane
 }:
@@ -21,7 +21,7 @@ in mkDerivation rec {
     libksane
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "KDE simple image scanning application";
     homepage    = "http://www.kde.org/applications/graphics/skanlite/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/office/softmaker/generic.nix b/pkgs/applications/office/softmaker/generic.nix
index fbde26058e1bf..7d936f400b87a 100644
--- a/pkgs/applications/office/softmaker/generic.nix
+++ b/pkgs/applications/office/softmaker/generic.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoPatchelfHook, makeDesktopItem, makeWrapper, copyDesktopItems
+{ lib, stdenv, fetchurl, autoPatchelfHook, makeDesktopItem, makeWrapper, copyDesktopItems
 
   # Dynamic Libraries
 , curl, libGL, libX11, libXext, libXmu, libXrandr, libXrender
@@ -119,7 +119,7 @@ in stdenv.mkDerivation {
 
   desktopItems = builtins.attrValues desktopItems;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An office suite with a word processor, spreadsheet and presentation program";
     homepage = "https://www.softmaker.com/";
     license = licenses.unfree;
diff --git a/pkgs/applications/office/spice-up/default.nix b/pkgs/applications/office/spice-up/default.nix
index 0cf7e8c53f145..f40bc44e6eb83 100644
--- a/pkgs/applications/office/spice-up/default.nix
+++ b/pkgs/applications/office/spice-up/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create simple and beautiful presentations";
     homepage = "https://github.com/Philip-Scott/Spice-up";
     maintainers = with maintainers; [ samdroid-apps xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/office/tagainijisho/default.nix b/pkgs/applications/office/tagainijisho/default.nix
index 5216c896e72d2..18126b5e2b762 100644
--- a/pkgs/applications/office/tagainijisho/default.nix
+++ b/pkgs/applications/office/tagainijisho/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qt4, cmake, sqlite }:
+{ lib, stdenv, fetchurl, qt4, cmake, sqlite }:
 
 stdenv.mkDerivation {
   name = "tagainijisho-1.0.3";
@@ -10,7 +10,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ qt4 sqlite ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, open-source Japanese dictionary and kanji lookup tool";
     homepage = "https://www.tagaini.net/";
     license = with licenses; [
diff --git a/pkgs/applications/office/timekeeper/default.nix b/pkgs/applications/office/timekeeper/default.nix
index 60b4bad60bb42..ba9390251fc53 100644
--- a/pkgs/applications/office/timekeeper/default.nix
+++ b/pkgs/applications/office/timekeeper/default.nix
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     install -Dm755 TimeKeeper/TimeKeeper $out/bin/timekeeper
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Log hours worked and make reports";
     homepage = "https://github.com/bburdette/TimeKeeper";
     maintainers = with maintainers; [ bburdette ];
diff --git a/pkgs/applications/office/timetable/default.nix b/pkgs/applications/office/timetable/default.nix
index 838b1724ee86c..fa70fdd308233 100644
--- a/pkgs/applications/office/timetable/default.nix
+++ b/pkgs/applications/office/timetable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , glib
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plot out your own timetable for the week and organize it";
     homepage = "https://github.com/lainsce/timetable";
     maintainers = [ maintainers.xiorcale ] ++ pantheon.maintainers;
diff --git a/pkgs/applications/office/timeular/default.nix b/pkgs/applications/office/timeular/default.nix
index f0fc5c3738cc9..63f86171dce9b 100644
--- a/pkgs/applications/office/timeular/default.nix
+++ b/pkgs/applications/office/timeular/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   fetchurl,
   appimageTools,
   libsecret
@@ -30,7 +30,7 @@ in appimageTools.wrapType2 rec {
     substituteInPlace $out/share/applications/timeular.desktop --replace 'Exec=AppRun' 'Exec=${pname}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Timetracking by flipping 8-sided dice";
     longDescription = ''
       The Timeular Tracker is an 8-sided dice that sits on your desk.
diff --git a/pkgs/applications/office/todoman/default.nix b/pkgs/applications/office/todoman/default.nix
index 1c536458369d7..dc788a6f19574 100644
--- a/pkgs/applications/office/todoman/default.nix
+++ b/pkgs/applications/office/todoman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python3
 , glibcLocales
 , installShellFiles
@@ -60,7 +60,7 @@ buildPythonApplication rec {
     rm tests/test_cli.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pimutils/todoman";
     description = "Standards-based task manager based on iCalendar";
     longDescription = ''
diff --git a/pkgs/applications/office/treesheets/default.nix b/pkgs/applications/office/treesheets/default.nix
index d316d42870728..552d28d1e9507 100644
--- a/pkgs/applications/office/treesheets/default.nix
+++ b/pkgs/applications/office/treesheets/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, wxGTK, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, wxGTK, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "treesheets";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
       --replace "Icon=images/treesheets.svg" "Icon=$out/share/libexec/images/treesheets.svg"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free Form Data Organizer";
 
     longDescription = ''
diff --git a/pkgs/applications/office/trilium/default.nix b/pkgs/applications/office/trilium/default.nix
index 217f1fd85d62b..bd067688fb48b 100644
--- a/pkgs/applications/office/trilium/default.nix
+++ b/pkgs/applications/office/trilium/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, nixosTests, fetchurl, autoPatchelfHook, atomEnv, makeWrapper, makeDesktopItem, gtk3, wrapGAppsHook, zlib, libxkbfile }:
+{ lib, stdenv, nixosTests, fetchurl, autoPatchelfHook, atomEnv, makeWrapper, makeDesktopItem, gtk3, wrapGAppsHook, zlib, libxkbfile }:
 
 let
   description = "Trilium Notes is a hierarchical note taking application with focus on building large personal knowledge bases";
@@ -11,7 +11,7 @@ let
     categories = "Office";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit description;
     homepage = "https://github.com/zadam/trilium";
     license = licenses.agpl3;
diff --git a/pkgs/applications/office/tudu/default.nix b/pkgs/applications/office/tudu/default.nix
index 6094e02c5c1b6..e353b43c74795 100644
--- a/pkgs/applications/office/tudu/default.nix
+++ b/pkgs/applications/office/tudu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "tudu";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
       --replace 'echo "main()' 'echo "int main()'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ncurses-based hierarchical todo list manager with vim-like keybindings";
     homepage = "https://code.meskio.net/tudu/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/office/watson/default.nix b/pkgs/applications/office/watson/default.nix
index 00fa9416e1725..30992e60a6fc0 100644
--- a/pkgs/applications/office/watson/default.nix
+++ b/pkgs/applications/office/watson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, installShellFiles }:
 
 with pythonPackages;
 
@@ -26,7 +26,7 @@ buildPythonApplication rec {
   propagatedBuildInputs = [ arrow click click-didyoumean requests ];
   nativeBuildInputs = [ installShellFiles ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tailordev.github.io/Watson/";
     description = "A wonderful CLI to track your time!";
     license = licenses.mit;
diff --git a/pkgs/applications/office/wordgrinder/default.nix b/pkgs/applications/office/wordgrinder/default.nix
index e50e319f319c1..921ce4d5f3d25 100644
--- a/pkgs/applications/office/wordgrinder/default.nix
+++ b/pkgs/applications/office/wordgrinder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, makeWrapper
+{ lib, stdenv, fetchFromGitHub, pkgconfig, makeWrapper
 , lua52Packages, libXft, ncurses, ninja, readline, zlib }:
 
 stdenv.mkDerivation rec {
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/xwordgrinder --set LUA_CPATH "${lua52Packages.luafilesystem}/lib/lua/5.2/lfs.so";
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Text-based word processor";
     homepage = "https://cowlark.com/wordgrinder";
     license = licenses.mit;
diff --git a/pkgs/applications/office/zim/default.nix b/pkgs/applications/office/zim/default.nix
index 05a3c2de9b47f..f34a3e806af76 100644
--- a/pkgs/applications/office/zim/default.nix
+++ b/pkgs/applications/office/zim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3Packages, gtk3, gobject-introspection, wrapGAppsHook, gnome3 }:
+{ lib, stdenv, fetchurl, python3Packages, gtk3, gobject-introspection, wrapGAppsHook, gnome3 }:
 
 #
 # TODO: Declare configuration options for the following optional dependencies:
@@ -32,7 +32,7 @@ python3Packages.buildPythonApplication rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A desktop wiki";
     homepage = "http://zim-wiki.org";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/office/zotero/default.nix b/pkgs/applications/office/zotero/default.nix
index d615f2a06f110..4b41655b9aea5 100644
--- a/pkgs/applications/office/zotero/default.nix
+++ b/pkgs/applications/office/zotero/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, wrapGAppsHook, makeDesktopItem
+{ lib, stdenv, fetchurl, wrapGAppsHook, makeDesktopItem
 , atk
 , cairo
 , coreutils
@@ -138,7 +138,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.zotero.org";
     description = "Collect, organize, cite, and share your research sources";
     license = licenses.agpl3;
diff --git a/pkgs/applications/qubes/qubes-core-vchan-xen/default.nix b/pkgs/applications/qubes/qubes-core-vchan-xen/default.nix
index f4d1b27478d44..3a1359ca573dd 100644
--- a/pkgs/applications/qubes/qubes-core-vchan-xen/default.nix
+++ b/pkgs/applications/qubes/qubes-core-vchan-xen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , xen_4_10
 }:
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     make install DESTDIR=$out PREFIX=/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Libraries required for the higher-level Qubes daemons and tools";
     homepage = "https://qubes-os.org";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/radio/airspy/default.nix b/pkgs/applications/radio/airspy/default.nix
index 67a59b68cd5b8..f006eeb6756e6 100644
--- a/pkgs/applications/radio/airspy/default.nix
+++ b/pkgs/applications/radio/airspy/default.nix
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   cmakeFlags =
     lib.optionals stdenv.isLinux [ "-DINSTALL_UDEV_RULES=ON" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/airspy/airspyone_host";
     description = "Host tools and driver library for the AirSpy SDR";
     license = licenses.bsd3;
diff --git a/pkgs/applications/radio/aldo/default.nix b/pkgs/applications/radio/aldo/default.nix
index 83bb520272ea3..b850ea1014c63 100644
--- a/pkgs/applications/radio/aldo/default.nix
+++ b/pkgs/applications/radio/aldo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, libao, autoreconfHook }:
+{ lib, stdenv, fetchgit, libao, autoreconfHook }:
 
 let
   pname = "aldo";
@@ -16,7 +16,7 @@ in stdenv.mkDerivation {
 
   buildInputs = [ libao ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Morse code training program";
     homepage = "http://aldo.nongnu.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/radio/chirp/default.nix b/pkgs/applications/radio/chirp/default.nix
index 8fb719567d55a..6b84e47909dde 100644
--- a/pkgs/applications/radio/chirp/default.nix
+++ b/pkgs/applications/radio/chirp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python2
 }:
@@ -15,7 +15,7 @@ python2.pkgs.buildPythonApplication rec {
     pygtk pyserial libxml2 future
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, open-source tool for programming your amateur radio";
     homepage = "https://chirp.danplanet.com/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/radio/cubicsdr/default.nix b/pkgs/applications/radio/cubicsdr/default.nix
index c0dd4346d40a5..d3b5b12836fd4 100644
--- a/pkgs/applications/radio/cubicsdr/default.nix
+++ b/pkgs/applications/radio/cubicsdr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, cmake, fftw, hamlib, libpulseaudio, libGL, libX11, liquid-dsp,
+{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, fftw, hamlib, libpulseaudio, libGL, libX11, liquid-dsp,
   pkgconfig, soapysdr-with-plugins, wxGTK31-gtk3, enableDigitalLab ? false }:
 
 stdenv.mkDerivation rec {
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
   cmakeFlags = [ "-DUSE_HAMLIB=ON" ]
     ++ stdenv.lib.optional enableDigitalLab "-DENABLE_DIGITAL_LAB=ON";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://cubicsdr.com";
     description = "Software Defined Radio application";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/radio/dablin/default.nix b/pkgs/applications/radio/dablin/default.nix
index 287649ddbe1e8..0fb7317428efb 100644
--- a/pkgs/applications/radio/dablin/default.nix
+++ b/pkgs/applications/radio/dablin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , mpg123, SDL2, gnome3, faad2, pcre
 } :
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ faad2 mpg123 SDL2 gnome3.gtkmm pcre ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Play DAB/DAB+ from ETI-NI aligned stream";
     homepage = "https://github.com/Opendigitalradio/dablin";
     license = with licenses; [ gpl3 lgpl21 ];
diff --git a/pkgs/applications/radio/dabtools/default.nix b/pkgs/applications/radio/dabtools/default.nix
index 401e207ba4f62..04d1e6056de36 100644
--- a/pkgs/applications/radio/dabtools/default.nix
+++ b/pkgs/applications/radio/dabtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , libusb1, rtl-sdr, fftw
 } :
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ cmake pkgconfig ];
   buildInputs = [ rtl-sdr fftw libusb1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Commandline tools for DAB and DAB+ digital radio broadcasts";
     homepage = "https://github.com/Opendigitalradio/dabtools";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/radio/dmrconfig/default.nix b/pkgs/applications/radio/dmrconfig/default.nix
index 47b72669f8fda..4bf523a8b8b38 100644
--- a/pkgs/applications/radio/dmrconfig/default.nix
+++ b/pkgs/applications/radio/dmrconfig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , libusb1, systemd }:
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     install 99-dmr.rules $out/lib/udev/rules.d/99-dmr.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configuration utility for DMR radios";
     longDescription = ''
       DMRconfig is a utility for programming digital radios via USB programming cable.
diff --git a/pkgs/applications/radio/dsd/default.nix b/pkgs/applications/radio/dsd/default.nix
index 1aa04dc43d721..4b9fbcd6af257 100644
--- a/pkgs/applications/radio/dsd/default.nix
+++ b/pkgs/applications/radio/dsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake
+{ lib, stdenv, fetchFromGitHub, cmake
 , mbelib, libsndfile, itpp
 , portaudioSupport ? true, portaudio ? null
 }:
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH''${DYLD_LIBRARY_PATH:+:}$PWD
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Digital Speech Decoder";
     longDescription = ''
       DSD is able to decode several digital voice formats from discriminator
diff --git a/pkgs/applications/radio/dump1090/default.nix b/pkgs/applications/radio/dump1090/default.nix
index 6e70a9f8d0327..f97ffb4d8070d 100644
--- a/pkgs/applications/radio/dump1090/default.nix
+++ b/pkgs/applications/radio/dump1090/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , libbladeRF
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     cp -vr public_html $out/share/dump1090
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple Mode S decoder for RTLSDR devices";
     homepage = "https://github.com/flightaware/dump1090";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/radio/ebook2cw/default.nix b/pkgs/applications/radio/ebook2cw/default.nix
index 5bd9e47ab7163..4c8cd53ebd4df 100644
--- a/pkgs/applications/radio/ebook2cw/default.nix
+++ b/pkgs/applications/radio/ebook2cw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, lame, libvorbis, gettext }:
+{ lib, stdenv, fetchgit, lame, libvorbis, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "ebook2cw";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert ebooks to Morse MP3s/OGGs";
     homepage = "http://fkurz.net/ham/ebook2cw.html";
     license = licenses.gpl2;
diff --git a/pkgs/applications/radio/gnss-sdr/default.nix b/pkgs/applications/radio/gnss-sdr/default.nix
index 782640c95dfc0..f48a21db75e75 100644
--- a/pkgs/applications/radio/gnss-sdr/default.nix
+++ b/pkgs/applications/radio/gnss-sdr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , armadillo
 , boost
 , cmake
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     "-DGFORTRAN=YES"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source Global Navigation Satellite Systems software-defined receiver";
     homepage = "https://gnss-sdr.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/radio/gnuradio/ais.nix b/pkgs/applications/radio/gnuradio/ais.nix
index 82187230ee3e3..9c993de65d014 100644
--- a/pkgs/applications/radio/gnuradio/ais.nix
+++ b/pkgs/applications/radio/gnuradio/ais.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio
 , makeWrapper, cppunit, gr-osmosdr, log4cpp
 , pythonSupport ? true, python, swig
 }:
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnuradio block for ais";
     homepage = "https://github.com/bistromath/gr-ais";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/radio/gnuradio/gsm.nix b/pkgs/applications/radio/gnuradio/gsm.nix
index b41e7cdb682e2..39834540ff814 100644
--- a/pkgs/applications/radio/gnuradio/gsm.nix
+++ b/pkgs/applications/radio/gnuradio/gsm.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio, log4cpp
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio, log4cpp
 , makeWrapper, cppunit, libosmocore, gr-osmosdr
 , pythonSupport ? true, python, swig
 }:
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnuradio block for gsm";
     homepage = "https://github.com/ptrkrysik/gr-gsm";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/radio/gnuradio/limesdr.nix b/pkgs/applications/radio/gnuradio/limesdr.nix
index f7ec95f8e71b4..1033b25cb3db1 100644
--- a/pkgs/applications/radio/gnuradio/limesdr.nix
+++ b/pkgs/applications/radio/gnuradio/limesdr.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, boost, gnuradio
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, boost, gnuradio
 , pythonSupport ? true, python, swig, limesuite, log4cpp
 } :
 
@@ -28,7 +28,7 @@ in stdenv.mkDerivation {
   ] ++ stdenv.lib.optionals pythonSupport [ python ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnuradio source and sink blocks for LimeSDR";
     homepage = "https://wiki.myriadrf.org/Gr-limesdr_Plugin_for_GNURadio";
     license = licenses.mit;
diff --git a/pkgs/applications/radio/gnuradio/nacl.nix b/pkgs/applications/radio/gnuradio/nacl.nix
index 7ddac3c227269..e87d2a71b1c9a 100644
--- a/pkgs/applications/radio/gnuradio/nacl.nix
+++ b/pkgs/applications/radio/gnuradio/nacl.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio, uhd
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio, uhd
 , makeWrapper, libsodium, cppunit, log4cpp
 , pythonSupport ? true, python, swig
 }:
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnuradio block for encryption";
     homepage = "https://github.com/stwunsch/gr-nacl";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/radio/gnuradio/osmosdr.nix b/pkgs/applications/radio/gnuradio/osmosdr.nix
index 50889c66d6b5c..90adcf5ffaef6 100644
--- a/pkgs/applications/radio/gnuradio/osmosdr.nix
+++ b/pkgs/applications/radio/gnuradio/osmosdr.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, cmake, pkg-config, makeWrapper
+{ lib, stdenv, fetchgit, cmake, pkg-config, makeWrapper
 , boost
 , pythonSupport ? true, python, swig
 , airspy
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnuradio block for OsmoSDR and rtl-sdr";
     homepage = "https://sdr.osmocom.org/trac/wiki/GrOsmoSDR";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/radio/gnuradio/rds.nix b/pkgs/applications/radio/gnuradio/rds.nix
index f28ec8ded2db5..3c90a8ad98554 100644
--- a/pkgs/applications/radio/gnuradio/rds.nix
+++ b/pkgs/applications/radio/gnuradio/rds.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio, log4cpp
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, boost, gnuradio, log4cpp
 , makeWrapper, pythonSupport ? true, python, swig
 }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnuradio block for radio data system";
     homepage = "https://github.com/bastibl/gr-rds";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/radio/gqrx/default.nix b/pkgs/applications/radio/gqrx/default.nix
index 31e6bc3754016..a4a1dfa61e409 100644
--- a/pkgs/applications/radio/gqrx/default.nix
+++ b/pkgs/applications/radio/gqrx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, qtbase, qtsvg, gnuradio, boost, gr-osmosdr
+{ lib, stdenv, fetchFromGitHub, cmake, qtbase, qtsvg, gnuradio, boost, gr-osmosdr
 , mkDerivation
 # drivers (optional):
 , rtl-sdr, hackrf
@@ -28,7 +28,7 @@ mkDerivation rec {
     install -vD $src/resources/icons/gqrx.svg -t "$out/share/pixmaps/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Software defined radio (SDR) receiver";
     longDescription = ''
       Gqrx is a software defined radio receiver powered by GNU Radio and the Qt
diff --git a/pkgs/applications/radio/hackrf/default.nix b/pkgs/applications/radio/hackrf/default.nix
index b0aaddcdc6b63..41df55a890d04 100644
--- a/pkgs/applications/radio/hackrf/default.nix
+++ b/pkgs/applications/radio/hackrf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, libusb1, fftwSinglePrec }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, libusb1, fftwSinglePrec }:
 
 stdenv.mkDerivation rec {
   pname = "hackrf";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     cd host
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source SDR platform";
     homepage = "https://greatscottgadgets.com/hackrf/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/radio/kalibrate-hackrf/default.nix b/pkgs/applications/radio/kalibrate-hackrf/default.nix
index 273d2d8c8e37c..dc6b1325cf1cb 100644
--- a/pkgs/applications/radio/kalibrate-hackrf/default.nix
+++ b/pkgs/applications/radio/kalibrate-hackrf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, fftw, hackrf, libusb1 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, fftw, hackrf, libusb1 }:
 
 stdenv.mkDerivation {
   name = "kalibrate-hackrf-unstable-20160827";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     mv $out/bin/kal $out/bin/kal-hackrf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calculate local oscillator frequency offset in hackrf devices";
     longDescription = ''
       Kalibrate, or kal, can scan for GSM base stations in a given frequency
diff --git a/pkgs/applications/radio/kalibrate-rtl/default.nix b/pkgs/applications/radio/kalibrate-rtl/default.nix
index 38913e827d09b..536e83297c331 100644
--- a/pkgs/applications/radio/kalibrate-rtl/default.nix
+++ b/pkgs/applications/radio/kalibrate-rtl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, pkgconfig, fftw, rtl-sdr, libusb1 }:
+{ lib, stdenv, fetchgit, autoreconfHook, pkgconfig, fftw, rtl-sdr, libusb1 }:
 
 stdenv.mkDerivation {
   name = "kalibrate-rtl-20131214";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ fftw rtl-sdr libusb1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calculate local oscillator frequency offset in RTL-SDR devices";
     longDescription = ''
       Kalibrate, or kal, can scan for GSM base stations in a given frequency
diff --git a/pkgs/applications/radio/limesuite/default.nix b/pkgs/applications/radio/limesuite/default.nix
index 25f49c3a2d653..4272075a042b1 100644
--- a/pkgs/applications/radio/limesuite/default.nix
+++ b/pkgs/applications/radio/limesuite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake
+{ lib, stdenv, fetchFromGitHub, cmake
 , sqlite, wxGTK30-gtk3, libusb1, soapysdr
 , mesa_glu, libX11, gnuplot, fltk
 } :
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     install -Dm444 -t $out/share/limesuite bin/Release/lms7suite_mcu/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Driver and GUI for LMS7002M-based SDR platforms";
     homepage = "https://github.com/myriadrf/LimeSuite";
     license = licenses.asl20;
diff --git a/pkgs/applications/radio/multimon-ng/default.nix b/pkgs/applications/radio/multimon-ng/default.nix
index a51a67135c051..2524b48c9c27f 100644
--- a/pkgs/applications/radio/multimon-ng/default.nix
+++ b/pkgs/applications/radio/multimon-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qt4, qmake4Hook, libpulseaudio }:
+{ lib, stdenv, fetchFromGitHub, qt4, qmake4Hook, libpulseaudio }:
 let
   version = "1.1.9";
 in
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     cp multimon-ng $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multimon is a digital baseband audio protocol decoder";
     longDescription = ''
       multimon-ng a fork of multimon, a digital baseband audio
diff --git a/pkgs/applications/radio/qradiolink/default.nix b/pkgs/applications/radio/qradiolink/default.nix
index 4c792811dc59f..24c5f987f1764 100644
--- a/pkgs/applications/radio/qradiolink/default.nix
+++ b/pkgs/applications/radio/qradiolink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, alsaLib, boost
+{ lib, stdenv, fetchFromGitHub, alsaLib, boost
 , qt4, libpulseaudio, codec2, libconfig
 , gnuradio, gr-osmosdr, gsm
 , libopus, libjpeg, protobuf, qwt, speex
@@ -50,7 +50,7 @@ in stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SDR transceiver application for analog and digital modes";
     homepage = "http://qradiolink.org/";
     license = licenses.agpl3;
diff --git a/pkgs/applications/radio/qsstv/default.nix b/pkgs/applications/radio/qsstv/default.nix
index d5d12a7140312..ddf1d6c6febd0 100644
--- a/pkgs/applications/radio/qsstv/default.nix
+++ b/pkgs/applications/radio/qsstv/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, qtbase, qmake, openjpeg, pkgconfig, fftw,
+{ mkDerivation, lib, stdenv, fetchurl, qtbase, qmake, openjpeg, pkgconfig, fftw,
   libpulseaudio, alsaLib, hamlib, libv4l, fftwFloat }:
 
 mkDerivation rec {
@@ -25,7 +25,7 @@ mkDerivation rec {
     install -D qsstv/icons/qsstv.png $out/share/pixmaps/qsstv.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt-based slow-scan TV and fax";
     homepage = "http://users.telenet.be/on4qz/";
     platforms = platforms.linux;
diff --git a/pkgs/applications/radio/quisk/default.nix b/pkgs/applications/radio/quisk/default.nix
index 86edfadcce11c..c0dab8773c71a 100644
--- a/pkgs/applications/radio/quisk/default.nix
+++ b/pkgs/applications/radio/quisk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python38Packages, fetchPypi
+{ lib, stdenv, python38Packages, fetchPypi
 , fftw, alsaLib, pulseaudio, wxPython_4_0 }:
 
 python38Packages.buildPythonApplication rec {
@@ -16,7 +16,7 @@ python38Packages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A SDR transceiver for radios that use the Hermes protocol";
     longDescription = ''
       QUISK is a Software Defined Radio (SDR) transceiver. You supply radio
diff --git a/pkgs/applications/radio/rtl-ais/default.nix b/pkgs/applications/radio/rtl-ais/default.nix
index f806f07d597d1..9f917329168d7 100644
--- a/pkgs/applications/radio/rtl-ais/default.nix
+++ b/pkgs/applications/radio/rtl-ais/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libusb1, rtl-sdr }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libusb1, rtl-sdr }:
 
 stdenv.mkDerivation {
   name = "rtl-ais";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple AIS tuner and generic dual-frequency FM demodulator";
     homepage = "https://github.com/dgiardini/rtl-ais";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/radio/rtl-sdr/default.nix b/pkgs/applications/radio/rtl-sdr/default.nix
index 7e044296b02cc..3f69f40424e3c 100644
--- a/pkgs/applications/radio/rtl-sdr/default.nix
+++ b/pkgs/applications/radio/rtl-sdr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchpatch, cmake, pkgconfig, libusb1 }:
+{ lib, stdenv, fetchgit, fetchpatch, cmake, pkgconfig, libusb1 }:
 
 stdenv.mkDerivation rec {
   pname = "rtl-sdr";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     echo "Requires: libusb-1.0" >> "$pcfile"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Turns your Realtek RTL2832 based DVB dongle into a SDR receiver";
     homepage = "http://sdr.osmocom.org/trac/wiki/rtl-sdr";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/radio/rtl_433/default.nix b/pkgs/applications/radio/rtl_433/default.nix
index c84160c19eaee..6f4460e6d6eb0 100644
--- a/pkgs/applications/radio/rtl_433/default.nix
+++ b/pkgs/applications/radio/rtl_433/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , libusb1, rtl-sdr, soapysdr-with-plugins
 }:
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Decode traffic from devices that broadcast on 433.9 MHz, 868 MHz, 315 MHz, 345 MHz and 915 MHz";
     homepage = "https://github.com/merbanan/rtl_433";
     license = licenses.gpl2;
diff --git a/pkgs/applications/radio/soapyairspy/default.nix b/pkgs/applications/radio/soapyairspy/default.nix
index 4a69e52741e7f..0541c3abf9149 100644
--- a/pkgs/applications/radio/soapyairspy/default.nix
+++ b/pkgs/applications/radio/soapyairspy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake
+{ lib, stdenv, fetchFromGitHub, cmake
 , airspy, soapysdr
 } :
 
@@ -21,7 +21,7 @@ in stdenv.mkDerivation {
 
   cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapyAirspy";
     description = "SoapySDR plugin for Airspy devices";
     license = licenses.mit;
diff --git a/pkgs/applications/radio/soapyaudio/default.nix b/pkgs/applications/radio/soapyaudio/default.nix
index ce5811b009ee7..e12cced055c2f 100644
--- a/pkgs/applications/radio/soapyaudio/default.nix
+++ b/pkgs/applications/radio/soapyaudio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config
 , hamlib, rtaudio, alsaLib, libpulseaudio, libjack2, libusb1, soapysdr
 } :
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "-DUSE_HAMLIB=ON"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapyAudio";
     description = "SoapySDR plugin for amateur radio and audio devices";
     license = licenses.mit;
diff --git a/pkgs/applications/radio/soapybladerf/default.nix b/pkgs/applications/radio/soapybladerf/default.nix
index 7e2e17a845584..db9ad67ad4011 100644
--- a/pkgs/applications/radio/soapybladerf/default.nix
+++ b/pkgs/applications/radio/soapybladerf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , libbladeRF, soapysdr
 } :
 
@@ -22,7 +22,7 @@ in stdenv.mkDerivation {
   cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapyBladeRF";
     description = "SoapySDR plugin for BladeRF devices";
     license = licenses.lgpl21;
diff --git a/pkgs/applications/radio/soapyhackrf/default.nix b/pkgs/applications/radio/soapyhackrf/default.nix
index e472b1cc3ae9b..105f0f423f463 100644
--- a/pkgs/applications/radio/soapyhackrf/default.nix
+++ b/pkgs/applications/radio/soapyhackrf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , hackrf, soapysdr
 } :
 
@@ -21,7 +21,7 @@ in stdenv.mkDerivation {
 
   cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapyHackRF";
     description = "SoapySDR plugin for HackRF devices";
     license = licenses.mit;
diff --git a/pkgs/applications/radio/soapyremote/default.nix b/pkgs/applications/radio/soapyremote/default.nix
index b49debdb1af0b..1433b1e9abba8 100644
--- a/pkgs/applications/radio/soapyremote/default.nix
+++ b/pkgs/applications/radio/soapyremote/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, soapysdr, avahi }:
+{ lib, stdenv, fetchFromGitHub, cmake, soapysdr, avahi }:
 
 let
   version = "0.5.2";
@@ -19,7 +19,7 @@ in stdenv.mkDerivation {
 
   cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapyRemote";
     description = "SoapySDR plugin for remote access to SDRs";
     license = licenses.boost;
diff --git a/pkgs/applications/radio/soapyrtlsdr/default.nix b/pkgs/applications/radio/soapyrtlsdr/default.nix
index 8f342190ba7e1..4be9e20d1f587 100644
--- a/pkgs/applications/radio/soapyrtlsdr/default.nix
+++ b/pkgs/applications/radio/soapyrtlsdr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , rtl-sdr, soapysdr
 } :
 
@@ -21,7 +21,7 @@ in stdenv.mkDerivation {
 
   cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapyRTLSDR";
     description = "SoapySDR plugin for RTL-SDR devices";
     license = licenses.mit;
diff --git a/pkgs/applications/radio/soapysdr/default.nix b/pkgs/applications/radio/soapysdr/default.nix
index 676f7d3c839e2..87f69377c62b3 100644
--- a/pkgs/applications/radio/soapysdr/default.nix
+++ b/pkgs/applications/radio/soapysdr/default.nix
@@ -45,7 +45,7 @@ in stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapySDR";
     description = "Vendor and platform neutral SDR support library";
     license = licenses.boost;
diff --git a/pkgs/applications/radio/soapyuhd/default.nix b/pkgs/applications/radio/soapyuhd/default.nix
index b2223d1abb70d..864ceff4e1ddb 100644
--- a/pkgs/applications/radio/soapyuhd/default.nix
+++ b/pkgs/applications/radio/soapyuhd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config
 , uhd, boost, soapysdr
 } :
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     sed -i "s:DESTINATION .*uhd/modules:DESTINATION $out/lib/uhd/modules:" CMakeLists.txt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pothosware/SoapyAirspy";
     description = "SoapySDR plugin for UHD devices";
     license = licenses.gpl3Only;
diff --git a/pkgs/applications/radio/soundmodem/default.nix b/pkgs/applications/radio/soundmodem/default.nix
index d7410f9280943..7f1332a45a6ac 100644
--- a/pkgs/applications/radio/soundmodem/default.nix
+++ b/pkgs/applications/radio/soundmodem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkg-config, alsaLib, audiofile, gtk2, libxml2 }:
+{ lib, stdenv, fetchurl, pkg-config, alsaLib, audiofile, gtk2, libxml2 }:
 
 stdenv.mkDerivation rec {
   name = "soundmodem";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Audio based modem for ham radio supporting ax.25";
     longDescription = ''
       This software allows a standard PC soundcard to be used as a packet radio "modem". The whole processing is done on the main processor CPU.
diff --git a/pkgs/applications/radio/svxlink/default.nix b/pkgs/applications/radio/svxlink/default.nix
index 185e08f4062f5..f2688db4ad1d0 100644
--- a/pkgs/applications/radio/svxlink/default.nix
+++ b/pkgs/applications/radio/svxlink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, pkgconfig, fetchFromGitHub, makeDesktopItem, alsaLib, speex
+{ lib, stdenv, cmake, pkgconfig, fetchFromGitHub, makeDesktopItem, alsaLib, speex
 , libopus, curl, gsm, libgcrypt, libsigcxx, popt, qtbase, qttools
 , wrapQtAppsHook, rtl-sdr, tcl, doxygen, groff }:
 
@@ -56,7 +56,7 @@ in stdenv.mkDerivation rec {
     wrapQtApp $out/bin/qtel
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced repeater controller and EchoLink software";
     longDescription = ''
       Advanced repeater controller and EchoLink software for Linux including a
diff --git a/pkgs/applications/radio/tlf/default.nix b/pkgs/applications/radio/tlf/default.nix
index fd9ab82b321cb..a9fd0102dd17d 100644
--- a/pkgs/applications/radio/tlf/default.nix
+++ b/pkgs/applications/radio/tlf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, autoconf, automake, pkgconfig, glib
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, autoconf, automake, pkgconfig, glib
 , perl, ncurses5, hamlib, xmlrpc_c }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     ln -s ${ncurses5.out}/lib/libtinfo.so.5 $out/lib/libtinfo.so.5
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced ham radio logging and contest program";
     longDescription = ''
       TLF is a curses based console mode general logging and contest program for
diff --git a/pkgs/applications/radio/tqsl/default.nix b/pkgs/applications/radio/tqsl/default.nix
index 3f060f9154339..f0dd916a33542 100644
--- a/pkgs/applications/radio/tqsl/default.nix
+++ b/pkgs/applications/radio/tqsl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, cmake, expat, openssl, zlib, db, curl, wxGTK }:
+{ lib, stdenv, fetchurl, makeWrapper, cmake, expat, openssl, zlib, db, curl, wxGTK }:
 
 stdenv.mkDerivation rec {
   pname = "tqsl";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     wxGTK
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Software for using the ARRL Logbook of the World";
     homepage = "https://www.arrl.org/tqsl-download";
     license = licenses.bsd3;
diff --git a/pkgs/applications/radio/uhd/default.nix b/pkgs/applications/radio/uhd/default.nix
index d9276f6f1f1f7..033c2c4e2a677 100644
--- a/pkgs/applications/radio/uhd/default.nix
+++ b/pkgs/applications/radio/uhd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchFromGitHub
 , cmake
@@ -141,7 +141,7 @@ stdenv.mkDerivation rec {
     mv $out/lib/uhd/utils/uhd-usrp.rules $out/lib/udev/rules.d/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "USRP Hardware Driver (for Software Defined Radio)";
     longDescription = ''
       The USRP Hardware Driver (UHD) software is the hardware driver for all
diff --git a/pkgs/applications/radio/unixcw/default.nix b/pkgs/applications/radio/unixcw/default.nix
index fe31fd133e798..ec449517fcf77 100644
--- a/pkgs/applications/radio/unixcw/default.nix
+++ b/pkgs/applications/radio/unixcw/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, libpulseaudio, alsaLib , pkgconfig, qt5}:
+{lib, stdenv, fetchurl, libpulseaudio, alsaLib , pkgconfig, qt5}:
 stdenv.mkDerivation rec {
   pname = "unixcw";
   version = "3.5.1";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   buildInputs = [libpulseaudio alsaLib pkgconfig qt5.qtbase];
   CFLAGS   ="-lasound -lpulse-simple";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sound characters as Morse code on the soundcard or console speaker";
     longDescription = ''
        unixcw is a project providing libcw library and a set of programs
diff --git a/pkgs/applications/radio/wsjtx/default.nix b/pkgs/applications/radio/wsjtx/default.nix
index b11b6b474c645..debbaf0606f4f 100644
--- a/pkgs/applications/radio/wsjtx/default.nix
+++ b/pkgs/applications/radio/wsjtx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, asciidoc, asciidoctor, autoconf, automake, cmake,
+{ lib, stdenv, fetchurl, asciidoc, asciidoctor, autoconf, automake, cmake,
   docbook_xsl, fftw, fftwFloat, gfortran, libtool, libusb1, qtbase,
   qtmultimedia, qtserialport, qttools, texinfo, wrapQtAppsHook }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   # Remove Git dependency from superbuild since sources are included
   patches = [ ./super.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Weak-signal digital communication modes for amateur radio";
     longDescription = ''
       WSJT-X implements communication protocols or "modes" called FT4, FT8, JT4,
diff --git a/pkgs/applications/radio/xlog/default.nix b/pkgs/applications/radio/xlog/default.nix
index e92c216466fc3..04797140b02b3 100644
--- a/pkgs/applications/radio/xlog/default.nix
+++ b/pkgs/applications/radio/xlog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glib, gtk2, pkgconfig, hamlib }:
+{ lib, stdenv, fetchurl, glib, gtk2, pkgconfig, hamlib }:
 stdenv.mkDerivation rec {
   pname = "xlog";
   version = "2.0.19";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ glib pkgconfig gtk2 hamlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An amateur radio logging program";
     longDescription =
       '' Xlog is an amateur radio logging program.
diff --git a/pkgs/applications/science/astronomy/gpredict/default.nix b/pkgs/applications/science/astronomy/gpredict/default.nix
index 1ae80c0b0aa6a..a089bf6534b4b 100644
--- a/pkgs/applications/science/astronomy/gpredict/default.nix
+++ b/pkgs/applications/science/astronomy/gpredict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool
+{ lib, stdenv, fetchurl, pkgconfig, intltool
 , gtk3, glib, curl, goocanvas2, gpsd
 , hamlib, wrapGAppsHook
 }:
@@ -17,7 +17,7 @@ in stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig intltool wrapGAppsHook ];
   buildInputs = [ curl glib gtk3 goocanvas2 gpsd hamlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Real time satellite tracking and orbit prediction";
     longDescription = ''
       Gpredict is a real time satellite tracking and orbit prediction program
diff --git a/pkgs/applications/science/astronomy/phd2/default.nix b/pkgs/applications/science/astronomy/phd2/default.nix
index 7ddad3852277d..054a73dec7a05 100644
--- a/pkgs/applications/science/astronomy/phd2/default.nix
+++ b/pkgs/applications/science/astronomy/phd2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, cmake, gtk3, wxGTK30-gtk3,
+{ lib, stdenv, fetchFromGitHub, pkg-config, cmake, gtk3, wxGTK30-gtk3,
   curl, gettext, glib, indilib, libnova, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     mv $out/bin/.phd2.bin-wrapped $out/bin/.phd2-wrapped.bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://openphdguiding.org/";
     description = "Telescope auto-guidance application";
     license = licenses.bsd3;
diff --git a/pkgs/applications/science/astronomy/siril/default.nix b/pkgs/applications/science/astronomy/siril/default.nix
index 7ae3e011973e1..cd78b644eb052 100644
--- a/pkgs/applications/science/astronomy/siril/default.nix
+++ b/pkgs/applications/science/astronomy/siril/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, fetchFromGitHub, pkg-config, meson, ninja,
+{ lib, stdenv, fetchFromGitLab, fetchFromGitHub, pkg-config, meson, ninja,
   git, criterion, wrapGAppsHook, gtk3, libconfig, gnuplot, opencv,
   fftwFloat, cfitsio, gsl, exiv2, curl, librtprocess, ffmpeg,
   libraw, libtiff, libpng, libjpeg, libheif, ffms
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     cd nixbld
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.siril.org/";
     description = "Astronomical image processing tool";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/astronomy/xearth/default.nix b/pkgs/applications/science/astronomy/xearth/default.nix
index 752e25b4d8d3a..57054cc491ac9 100644
--- a/pkgs/applications/science/astronomy/xearth/default.nix
+++ b/pkgs/applications/science/astronomy/xearth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, imake, gccmakedep, libXt, libXext }:
+{ lib, stdenv, fetchurl, imake, gccmakedep, libXt, libXext }:
 
 stdenv.mkDerivation rec {
   pname = "xearth";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   installFlags = [ "DESTDIR=$(out)/" "BINDIR=bin" "MANDIR=man/man1"];
   installTargets = [ "install" "install.man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sets the X root window to an image of the Earth";
     homepage = "http://xplanet.org";
     longDescription =
diff --git a/pkgs/applications/science/astronomy/xplanet/default.nix b/pkgs/applications/science/astronomy/xplanet/default.nix
index a314678b6ea3a..63a1feab42f1f 100644
--- a/pkgs/applications/science/astronomy/xplanet/default.nix
+++ b/pkgs/applications/science/astronomy/xplanet/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, fetchpatch, pkgconfig, freetype, pango, libpng, libtiff
+{lib, stdenv, fetchurl, fetchpatch, pkgconfig, freetype, pango, libpng, libtiff
 , giflib, libjpeg, netpbm}:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-Wno-error=c++11-narrowing";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Renders an image of the earth or other planets into the X root window";
     homepage = "http://xplanet.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/biology/EZminc/default.nix b/pkgs/applications/science/biology/EZminc/default.nix
index f9d3e4d4e1279..17d8944128e2d 100644
--- a/pkgs/applications/science/biology/EZminc/default.nix
+++ b/pkgs/applications/science/biology/EZminc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, libminc, bicpl, itk4, fftwFloat, gsl }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, libminc, bicpl, itk4, fftwFloat, gsl }:
 
 stdenv.mkDerivation rec {
   pname = "EZminc";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
                  "-DEZMINC_BUILD_MRFSEG=TRUE"
                  "-DEZMINC_BUILD_DD=TRUE" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/${pname}";
     description = "Collection of Perl and shell scripts for processing MINC files";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/N3/default.nix b/pkgs/applications/science/biology/N3/default.nix
index 13ffc305d3926..2f4aa4ce3927e 100644
--- a/pkgs/applications/science/biology/N3/default.nix
+++ b/pkgs/applications/science/biology/N3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper,
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper,
   perlPackages,
   libminc, EBTKS }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/N3";
     description = "MRI non-uniformity correction for MINC files";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/ants/default.nix b/pkgs/applications/science/biology/ants/default.nix
index caf759ce7e3f4..7aa41bdf6f04a 100644
--- a/pkgs/applications/science/biology/ants/default.nix
+++ b/pkgs/applications/science/biology/ants/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, cmake, makeWrapper, itk4, vtk_7, Cocoa }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, makeWrapper, itk4, vtk_7, Cocoa }:
 
 stdenv.mkDerivation rec {
   pname    = "ANTs";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ANTsX/ANTs";
     description = "Advanced normalization toolkit for medical image registration and other processing";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/aragorn/default.nix b/pkgs/applications/science/biology/aragorn/default.nix
index 168bd5c6aa683..fa0c10b00c205 100644
--- a/pkgs/applications/science/biology/aragorn/default.nix
+++ b/pkgs/applications/science/biology/aragorn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "1.2.38";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/man/1 && cp aragorn.1 $out/man/1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Detects tRNA, mtRNA, and tmRNA genes in nucleotide sequences";
     homepage = "http://mbio-serv2.mbioekol.lu.se/ARAGORN/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/biology/bayescan/default.nix b/pkgs/applications/science/biology/bayescan/default.nix
index 4e216fbdbe63f..7c4f198b8427a 100644
--- a/pkgs/applications/science/biology/bayescan/default.nix
+++ b/pkgs/applications/science/biology/bayescan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, llvmPackages }:
+{ lib, stdenv, fetchurl, unzip, llvmPackages }:
 
 stdenv.mkDerivation rec {
   pname = "bayescan";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     cp -r ../*pdf ../input_examples ../"R functions" $out/share/doc/bayescan
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Detecting natural selection from population-based genetic data";
     homepage = "http://cmpg.unibe.ch/software/BayeScan";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/biology/bcftools/default.nix b/pkgs/applications/science/biology/bcftools/default.nix
index d1b033dc4e23f..f4e2db01fbc56 100644
--- a/pkgs/applications/science/biology/bcftools/default.nix
+++ b/pkgs/applications/science/biology/bcftools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, htslib, zlib, bzip2, lzma, curl, perl, python, bash }:
+{ lib, stdenv, fetchurl, htslib, zlib, bzip2, lzma, curl, perl, python, bash }:
 
 stdenv.mkDerivation rec {
   pname = "bcftools";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for manipulating BCF2/VCF/gVCF format, SNP and short indel sequence variants";
     license = licenses.mit;
     homepage = "http://www.htslib.org/";
diff --git a/pkgs/applications/science/biology/bedtools/default.nix b/pkgs/applications/science/biology/bedtools/default.nix
index f92e912f6800e..cfa22ae5ac8be 100644
--- a/pkgs/applications/science/biology/bedtools/default.nix
+++ b/pkgs/applications/science/biology/bedtools/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, zlib, python, bzip2, lzma}:
+{lib, stdenv, fetchFromGitHub, zlib, python, bzip2, lzma}:
 
 stdenv.mkDerivation rec {
   pname = "bedtools";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   buildPhase = "make prefix=$out SHELL=${stdenv.shell} CXX=${cxx} CC=${cc} -j $NIX_BUILD_CORES";
   installPhase = "make prefix=$out SHELL=${stdenv.shell} CXX=${cxx} CC=${cc} install";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A powerful toolset for genome arithmetic";
     license = licenses.gpl2;
     homepage = "https://bedtools.readthedocs.io/en/latest/";
diff --git a/pkgs/applications/science/biology/bftools/default.nix b/pkgs/applications/science/biology/bftools/default.nix
index 2ecefee340fd6..89ebdcee65b92 100644
--- a/pkgs/applications/science/biology/bftools/default.nix
+++ b/pkgs/applications/science/biology/bftools/default.nix
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ makeWrapper ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A bundle of scripts for using Bio-Formats on the command line with bioformats_package.jar already included";
     license = licenses.gpl2;
     platforms = platforms.all;
diff --git a/pkgs/applications/science/biology/blast/default.nix b/pkgs/applications/science/biology/blast/default.nix
index 95a1b905e9e24..a72f16938d410 100644
--- a/pkgs/applications/science/biology/blast/default.nix
+++ b/pkgs/applications/science/biology/blast/default.nix
@@ -94,7 +94,7 @@ stdenv.mkDerivation rec {
   # Many tests require either network access or locally available databases
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''Basic Local Alignment Search Tool (BLAST) finds regions of
     similarity between biological sequences'';
     homepage = "https://blast.ncbi.nlm.nih.gov/Blast.cgi";
diff --git a/pkgs/applications/science/biology/bowtie/default.nix b/pkgs/applications/science/biology/bowtie/default.nix
index 964eeddb461da..916bba5c05124 100644
--- a/pkgs/applications/science/biology/bowtie/default.nix
+++ b/pkgs/applications/science/biology/bowtie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib }:
+{ lib, stdenv, fetchFromGitHub, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "bowtie";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ultrafast memory-efficient short read aligner";
     license = licenses.artistic2;
     homepage = "http://bowtie-bio.sf.net/bowtie";
diff --git a/pkgs/applications/science/biology/bowtie2/default.nix b/pkgs/applications/science/biology/bowtie2/default.nix
index 603e5892ff119..715f5bb8bfa68 100644
--- a/pkgs/applications/science/biology/bowtie2/default.nix
+++ b/pkgs/applications/science/biology/bowtie2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, tbb, zlib }:
+{ lib, stdenv, fetchFromGitHub, cmake, tbb, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "bowtie2";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ tbb zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ultrafast and memory-efficient tool for aligning sequencing reads to long reference sequences";
     license = licenses.gpl3;
     homepage = "http://bowtie-bio.sf.net/bowtie2";
diff --git a/pkgs/applications/science/biology/bwa/default.nix b/pkgs/applications/science/biology/bwa/default.nix
index 10859d9e8c138..a2a11b1d4517f 100644
--- a/pkgs/applications/science/biology/bwa/default.nix
+++ b/pkgs/applications/science/biology/bwa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib }:
+{ lib, stdenv, fetchurl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "bwa";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     install -vD -t $out/include bwt.h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A software package for mapping low-divergent sequences against a large reference genome, such as the human genome";
     license     = licenses.gpl3;
     homepage    = "http://bio-bwa.sourceforge.net/";
diff --git a/pkgs/applications/science/biology/cd-hit/default.nix b/pkgs/applications/science/biology/cd-hit/default.nix
index 0db788b0f7431..94012b1c2ff44 100644
--- a/pkgs/applications/science/biology/cd-hit/default.nix
+++ b/pkgs/applications/science/biology/cd-hit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, zlib, perl, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, zlib, perl, perlPackages }:
 
 stdenv.mkDerivation rec {
   version = "4.8.1";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/plot_2d.pl --prefix PERL5LIB : $PERL5LIB
     wrapProgram $out/bin/clstr_list_sort.pl --prefix PERL5LIB : $PERL5LIB
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clustering and comparing protein or nucleotide sequences";
     homepage = "http://weizhongli-lab.org/cd-hit/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/biology/clustal-omega/default.nix b/pkgs/applications/science/biology/clustal-omega/default.nix
index 71cf879853767..6377e1fce855d 100644
--- a/pkgs/applications/science/biology/clustal-omega/default.nix
+++ b/pkgs/applications/science/biology/clustal-omega/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, argtable }:
+{ lib, stdenv, fetchurl, argtable }:
 
 stdenv.mkDerivation rec {
   version = "1.2.4";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "General purpose multiple sequence alignment program for protein and DNA/RNA";
     homepage = "http://www.clustal.org/omega/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/biology/cmtk/default.nix b/pkgs/applications/science/biology/cmtk/default.nix
index 7aef4c0728193..ea4f55ba475a5 100644
--- a/pkgs/applications/science/biology/cmtk/default.nix
+++ b/pkgs/applications/science/biology/cmtk/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, cmake}:
+{lib, stdenv, fetchurl, cmake}:
 
 stdenv.mkDerivation {
   name = "cmtk-3.3.1";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
 
   NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-Wno-error=c++11-narrowing";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description     = "Computational Morphometry Toolkit ";
     longDescription = ''A software toolkit for computational morphometry of
       biomedical images, CMTK comprises a set of command line tools and a
diff --git a/pkgs/applications/science/biology/conglomerate/default.nix b/pkgs/applications/science/biology/conglomerate/default.nix
index 8fb8e17eef860..592ab2cd66332 100644
--- a/pkgs/applications/science/biology/conglomerate/default.nix
+++ b/pkgs/applications/science/biology/conglomerate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, coreutils, perlPackages, bicpl, libminc, zlib, minc_tools,
+{ lib, stdenv, fetchFromGitHub, cmake, coreutils, perlPackages, bicpl, libminc, zlib, minc_tools,
   makeWrapper }:
 
 stdenv.mkDerivation rec {
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/conglomerate";
     description = "More command-line utilities for working with MINC files";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/dcm2niix/default.nix b/pkgs/applications/science/biology/dcm2niix/default.nix
index a59e5d2be2d5d..7ec5476cb8261 100644
--- a/pkgs/applications/science/biology/dcm2niix/default.nix
+++ b/pkgs/applications/science/biology/dcm2niix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , libyamlcpp
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake git ];
   buildInputs = [ libyamlcpp ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DICOM to NIfTI converter";
     longDescription = ''
       dcm2niix is a designed to convert neuroimaging data from the
diff --git a/pkgs/applications/science/biology/delly/default.nix b/pkgs/applications/science/biology/delly/default.nix
index 8f4dd77452692..7a7e3f13c7a3c 100644
--- a/pkgs/applications/science/biology/delly/default.nix
+++ b/pkgs/applications/science/biology/delly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchFromGitHub, htslib, zlib, bzip2, lzma, ncurses, boost }:
+{ lib, stdenv, fetchpatch, fetchFromGitHub, htslib, zlib, bzip2, lzma, ncurses, boost }:
 
 stdenv.mkDerivation rec {
   pname = "delly";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Structural variant caller for mapped DNA sequenced data";
     license = licenses.bsd3;
     maintainers = with maintainers; [ scalavision ];
diff --git a/pkgs/applications/science/biology/diamond/default.nix b/pkgs/applications/science/biology/diamond/default.nix
index dd1e13ec7162e..2e11c1d8c58cb 100644
--- a/pkgs/applications/science/biology/diamond/default.nix
+++ b/pkgs/applications/science/biology/diamond/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, zlib }:
+{ lib, stdenv, fetchurl, cmake, zlib }:
 
 stdenv.mkDerivation {
   name = "diamond-0.8.36";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Accelerated BLAST compatible local sequence aligner";
     longDescription = ''
       A sequence aligner for protein and translated DNA
diff --git a/pkgs/applications/science/biology/ecopcr/default.nix b/pkgs/applications/science/biology/ecopcr/default.nix
index 2e744c7b2b9ee..b3029f586add4 100644
--- a/pkgs/applications/science/biology/ecopcr/default.nix
+++ b/pkgs/applications/science/biology/ecopcr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gcc, zlib, python27 }:
+{ lib, stdenv, fetchurl, gcc, zlib, python27 }:
 
 stdenv.mkDerivation rec {
   name = "ecopcr-0.8.0";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 	chmod a+x $out/bin/ecoPCRFormat
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Electronic PCR software tool";
     longDescription = ''
       ecoPCR is an electronic PCR software developed by the LECA. It
diff --git a/pkgs/applications/science/biology/eggnog-mapper/default.nix b/pkgs/applications/science/biology/eggnog-mapper/default.nix
index 3ef52e543933b..c6defb245c7f9 100644
--- a/pkgs/applications/science/biology/eggnog-mapper/default.nix
+++ b/pkgs/applications/science/biology/eggnog-mapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, makeWrapper, python27Packages, wget, diamond, hmmer }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, makeWrapper, python27Packages, wget, diamond, hmmer }:
 
 python27Packages.buildPythonApplication rec {
   pname = "eggnog-mapper";
@@ -30,7 +30,7 @@ python27Packages.buildPythonApplication rec {
   # the user can download only those that interest them.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast genome-wide functional annotation through orthology assignment";
     license = licenses.gpl2;
     homepage = "https://github.com/eggnogdb/eggnog-mapper/wiki";
diff --git a/pkgs/applications/science/biology/est-sfs/default.nix b/pkgs/applications/science/biology/est-sfs/default.nix
index 1b15c06c670a1..814baa45d8c13 100644
--- a/pkgs/applications/science/biology/est-sfs/default.nix
+++ b/pkgs/applications/science/biology/est-sfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gsl }:
+{ lib, stdenv, fetchurl, gsl }:
 
 stdenv.mkDerivation rec {
   pname = "est-sfs";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp est-sfs-documentation.pdf $out/share/doc/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/est-usfs";
     description = "Estimate the unfolded site frequency spectrum and ancestral states";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/biology/exonerate/default.nix b/pkgs/applications/science/biology/exonerate/default.nix
index b2c49ab007676..9f87d0117df59 100644
--- a/pkgs/applications/science/biology/exonerate/default.nix
+++ b/pkgs/applications/science/biology/exonerate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glib, pkgconfig }:
+{ lib, stdenv, fetchurl, glib, pkgconfig }:
 
 stdenv.mkDerivation rec {
   version = "2.4.0";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generic tool for sequence alignment";
     homepage = "https://www.ebi.ac.uk/about/vertebrate-genomics/software/exonerate";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/biology/fastp/default.nix b/pkgs/applications/science/biology/fastp/default.nix
index c68486dbcd6be..e396c8597d24b 100644
--- a/pkgs/applications/science/biology/fastp/default.nix
+++ b/pkgs/applications/science/biology/fastp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , zlib
 }:
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -D fastp $out/bin/fastp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ultra-fast all-in-one FASTQ preprocessor";
     license = licenses.mit;
     homepage = "https://github.com/OpenGene/fastp";
diff --git a/pkgs/applications/science/biology/freebayes/default.nix b/pkgs/applications/science/biology/freebayes/default.nix
index bd80df56cb905..32ab614b9682e 100644
--- a/pkgs/applications/science/biology/freebayes/default.nix
+++ b/pkgs/applications/science/biology/freebayes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib, bzip2, lzma }:
+{ lib, stdenv, fetchFromGitHub, zlib, bzip2, lzma }:
 
 stdenv.mkDerivation rec {
   pname = "freebayes";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -vD bin/freebayes bin/bamleftalign scripts/* -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bayesian haplotype-based polymorphism discovery and genotyping";
     license     = licenses.mit;
     homepage    = "https://github.com/ekg/freebayes";
diff --git a/pkgs/applications/science/biology/hisat2/default.nix b/pkgs/applications/science/biology/hisat2/default.nix
index e641489b86c9b..ab8e26f92a0de 100644
--- a/pkgs/applications/science/biology/hisat2/default.nix
+++ b/pkgs/applications/science/biology/hisat2/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, unzip, which, python3, perl}:
+{lib, stdenv, fetchFromGitHub, unzip, which, python3, perl}:
 
 stdenv.mkDerivation rec {
   pname = "hisat2";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
        $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graph based aligner";
     license = licenses.gpl3;
     homepage = "https://ccb.jhu.edu/software/hisat2/index.shtml";
diff --git a/pkgs/applications/science/biology/hmmer/default.nix b/pkgs/applications/science/biology/hmmer/default.nix
index 3b1420a18819c..0f83178626bf6 100644
--- a/pkgs/applications/science/biology/hmmer/default.nix
+++ b/pkgs/applications/science/biology/hmmer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "3.3.2";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0s9wf6n0qanbx8qs6igfl3vyjikwbrvh4d9d6mv54yp3xysykzlj";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Biosequence analysis using profile hidden Markov models";
     longDescription = ''
       HMMER is used for searching sequence databases for sequence homologs, and for making sequence alignments. It implements methods using probabilistic models called profile hidden Markov models (profile HMMs).
diff --git a/pkgs/applications/science/biology/igv/default.nix b/pkgs/applications/science/biology/igv/default.nix
index 3f9cb1a288b37..ff05ef4b8df61 100644
--- a/pkgs/applications/science/biology/igv/default.nix
+++ b/pkgs/applications/science/biology/igv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jdk11 }:
+{ lib, stdenv, fetchzip, jdk11 }:
 
 stdenv.mkDerivation rec {
   pname = "igv";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/igvtools
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.broadinstitute.org/igv/";
     description = "A visualization tool for interactive exploration of genomic datasets";
     license = licenses.mit;
diff --git a/pkgs/applications/science/biology/inormalize/default.nix b/pkgs/applications/science/biology/inormalize/default.nix
index e6293bb90ef38..8ea115c6b25df 100644
--- a/pkgs/applications/science/biology/inormalize/default.nix
+++ b/pkgs/applications/science/biology/inormalize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper,
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper,
   perlPackages,
   libminc, EBTKS }:
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/${pname}";
     description = "Program to normalize intensity of MINC files";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/itsx/default.nix b/pkgs/applications/science/biology/itsx/default.nix
index 6f66cfc9cc370..843f0df57924b 100644
--- a/pkgs/applications/science/biology/itsx/default.nix
+++ b/pkgs/applications/science/biology/itsx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, hmmer, perl }:
+{ lib, stdenv, fetchurl, hmmer, perl }:
 
 stdenv.mkDerivation rec {
   version = "1.1.1";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp -r ITSx_db $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Improved software detection and extraction of ITS1 and ITS2 from ribosomal ITS sequences of fungi and other eukaryotes for use in environmental sequencing";
     homepage = "https://microbiology.se/software/itsx/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/biology/kallisto/default.nix b/pkgs/applications/science/biology/kallisto/default.nix
index 014ae14cc7948..203d0520660f0 100644
--- a/pkgs/applications/science/biology/kallisto/default.nix
+++ b/pkgs/applications/science/biology/kallisto/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, cmake, hdf5, zlib }:
+{ lib, stdenv, fetchFromGitHub, autoconf, cmake, hdf5, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "kallisto";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   # Parallel build fails in some cases: https://github.com/pachterlab/kallisto/issues/160
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Program for quantifying abundances of transcripts from RNA-Seq data";
     homepage = "https://pachterlab.github.io/kallisto";
     license = licenses.bsd2;
diff --git a/pkgs/applications/science/biology/kent/default.nix b/pkgs/applications/science/biology/kent/default.nix
index 2ca5ad191d920..26c55d3dc383a 100644
--- a/pkgs/applications/science/biology/kent/default.nix
+++ b/pkgs/applications/science/biology/kent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , libpng
 , libuuid
 , zlib
@@ -66,7 +66,7 @@ stdenv.mkDerivation rec {
     cp $NIX_BUILD_TOP/bin/x86_64/* $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "UCSC Genome Bioinformatics Group's suite of biological analysis tools, i.e. the kent utilities";
     license = licenses.unfree;
     maintainers = with maintainers; [ scalavision ];
diff --git a/pkgs/applications/science/biology/kssd/default.nix b/pkgs/applications/science/biology/kssd/default.nix
index 621a8ce157655..ef853d0cd47c2 100644
--- a/pkgs/applications/science/biology/kssd/default.nix
+++ b/pkgs/applications/science/biology/kssd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, automake, autoconf, libtool }:
+{ lib, stdenv, fetchurl, zlib, automake, autoconf, libtool }:
 
 stdenv.mkDerivation rec {
   pname = "kssd";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
       install -vD kssd $out/bin/kssd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "K-mer substring space decomposition";
     license     = licenses.asl20;
     homepage    = "https://github.com/yhg926/public_kssd";
diff --git a/pkgs/applications/science/biology/last/default.nix b/pkgs/applications/science/biology/last/default.nix
index 6db7ae55da84a..3a36a2194a134 100644
--- a/pkgs/applications/science/biology/last/default.nix
+++ b/pkgs/applications/science/biology/last/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, zlib, python3, parallel }:
+{ lib, stdenv, fetchurl, unzip, zlib, python3, parallel }:
 
 stdenv.mkDerivation rec {
   pname = "last";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Genomic sequence aligner";
     homepage = "http://last.cbrc.jp/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/biology/lumpy/default.nix b/pkgs/applications/science/biology/lumpy/default.nix
index f6267a2e017f8..91a001744474c 100644
--- a/pkgs/applications/science/biology/lumpy/default.nix
+++ b/pkgs/applications/science/biology/lumpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, htslib, zlib, curl, openssl, samblaster, sambamba
+{ lib, stdenv, fetchFromGitHub, htslib, zlib, curl, openssl, samblaster, sambamba
 , samtools, hexdump, python2Packages, which }:
 
 let
@@ -39,7 +39,7 @@ in stdenv.mkDerivation rec {
     sed -i 's|/build/source|'$out'|' $out/bin/lumpyexpress.config
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Probabilistic structural variant caller";
     homepage = "https://github.com/arq5x/lumpy-sv";
     maintainers = with maintainers; [ jbedo ];
diff --git a/pkgs/applications/science/biology/macse/default.nix b/pkgs/applications/science/biology/macse/default.nix
index 59938addbe825..c78e142dcc6b9 100644
--- a/pkgs/applications/science/biology/macse/default.nix
+++ b/pkgs/applications/science/biology/macse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "macse";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiple alignment of coding sequences";
     homepage = "https://bioweb.supagro.inra.fr/macse/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/biology/manta/default.nix b/pkgs/applications/science/biology/manta/default.nix
index f0f0575e055a2..1f46e0141da33 100644
--- a/pkgs/applications/science/biology/manta/default.nix
+++ b/pkgs/applications/science/biology/manta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, zlib, python2 }:
+{ lib, stdenv, fetchFromGitHub, cmake, zlib, python2 }:
 
 stdenv.mkDerivation rec {
   pname = "manta";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     PYTHONPATH=$out/lib/python/pyflow:$PYTHONPATH python -c 'import pyflowTaskWrapper; import pyflow'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Structural variant caller";
     license = licenses.gpl3;
     homepage = "https://github.com/Illumina/manta";
diff --git a/pkgs/applications/science/biology/megahit/default.nix b/pkgs/applications/science/biology/megahit/default.nix
index 3168ecb1cf832..ee2f16f389b25 100644
--- a/pkgs/applications/science/biology/megahit/default.nix
+++ b/pkgs/applications/science/biology/megahit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, zlib }:
+{ lib, stdenv, fetchFromGitHub, cmake, zlib }:
 
 stdenv.mkDerivation rec {
   pname    = "megahit";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ultra-fast single-node solution for large and complex metagenomics assembly via succinct de Bruijn graph";
     license     = licenses.gpl3;
     homepage    = "https://github.com/voutcn/megahit";
diff --git a/pkgs/applications/science/biology/minc-tools/default.nix b/pkgs/applications/science/biology/minc-tools/default.nix
index 897c1994a5008..3dece25915b47 100644
--- a/pkgs/applications/science/biology/minc-tools/default.nix
+++ b/pkgs/applications/science/biology/minc-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper, flex, bison, perl, TextFormat,
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper, flex, bison, perl, TextFormat,
   libminc, libjpeg, nifticlib, zlib }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/minc-tools";
     description = "Command-line utilities for working with MINC files";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/minc-widgets/default.nix b/pkgs/applications/science/biology/minc-widgets/default.nix
index 497c39a52a4c2..3af227d70a5a0 100644
--- a/pkgs/applications/science/biology/minc-widgets/default.nix
+++ b/pkgs/applications/science/biology/minc-widgets/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper,
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper,
   perlPackages,
   libminc, octave, coreutils, minc_tools }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/${pname}";
     description = "Collection of Perl and shell scripts for processing MINC files";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/minia/default.nix b/pkgs/applications/science/biology/minia/default.nix
index 2a80de733b08f..6b6bc300e0d9f 100644
--- a/pkgs/applications/science/biology/minia/default.nix
+++ b/pkgs/applications/science/biology/minia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, hdf5, boost }:
+{ lib, stdenv, fetchFromGitHub, cmake, hdf5, boost }:
 
 stdenv.mkDerivation rec {
   pname = "minia";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     rm -rf thirdparty/gatb-core/gatb-core/thirdparty/{hdf5,boost}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Short read genome assembler";
     homepage = "https://github.com/GATB/minia";
     license = licenses.agpl3;
diff --git a/pkgs/applications/science/biology/minimap2/default.nix b/pkgs/applications/science/biology/minimap2/default.nix
index e33a17537910b..ae327e2c43fd7 100644
--- a/pkgs/applications/science/biology/minimap2/default.nix
+++ b/pkgs/applications/science/biology/minimap2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib }:
+{ lib, stdenv, fetchFromGitHub, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "minimap2";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp minimap2.1 $out/share/man/man1
   '';
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A versatile pairwise aligner for genomic and spliced nucleotide sequences";
     homepage = "https://lh3.github.io/minimap2";
     license = licenses.mit;
diff --git a/pkgs/applications/science/biology/mni_autoreg/default.nix b/pkgs/applications/science/biology/mni_autoreg/default.nix
index 40ec9e0de6d21..b0ec8a70e149a 100644
--- a/pkgs/applications/science/biology/mni_autoreg/default.nix
+++ b/pkgs/applications/science/biology/mni_autoreg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper, perlPackages, libminc }:
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper, perlPackages, libminc }:
 
 stdenv.mkDerivation rec {
   pname = "mni_autoreg";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/mni_autoreg";
     description = "Tools for automated registration using the MINC image format";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/mosdepth/default.nix b/pkgs/applications/science/biology/mosdepth/default.nix
index d2b05943f7cea..4815ddf2f75c9 100644
--- a/pkgs/applications/science/biology/mosdepth/default.nix
+++ b/pkgs/applications/science/biology/mosdepth/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, nim, htslib, pcre}:
+{lib, stdenv, fetchFromGitHub, nim, htslib, pcre}:
 
 let
   hts-nim = fetchFromGitHub {
@@ -36,7 +36,7 @@ in stdenv.mkDerivation rec {
 
   installPhase = "install -Dt $out/bin mosdepth";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "fast BAM/CRAM depth calculation for WGS, exome, or targeted sequencing";
     license = licenses.mit;
     homepage = "https://github.com/brentp/mosdepth";
diff --git a/pkgs/applications/science/biology/mrbayes/default.nix b/pkgs/applications/science/biology/mrbayes/default.nix
index 0ebd144112166..9acfea1a14631 100644
--- a/pkgs/applications/science/biology/mrbayes/default.nix
+++ b/pkgs/applications/science/biology/mrbayes/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, readline}:
+{lib, stdenv, fetchurl, readline}:
 
 stdenv.mkDerivation rec {
   # FIXME: replace Makefile so we can build MPI & MAC support
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   builder = ./builder.sh;
   buildInputs = [readline];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description     = "Bayesian Inference of Phylogeny";
     longDescription = ''
       Bayesian inference of phylogeny is based upon a
diff --git a/pkgs/applications/science/biology/muscle/default.nix b/pkgs/applications/science/biology/muscle/default.nix
index 7ed18349259e3..e7c1040e59308 100644
--- a/pkgs/applications/science/biology/muscle/default.nix
+++ b/pkgs/applications/science/biology/muscle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   _name   = "muscle";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     install -vD muscle $out/bin/muscle
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multiple sequence alignment method with reduced time and space complexity";
     license     = licenses.publicDomain;
     homepage    = "https://www.drive5.com/muscle/";
diff --git a/pkgs/applications/science/biology/neuron/default.nix b/pkgs/applications/science/biology/neuron/default.nix
index 8cad5f466c5f0..048a9a5644d0d 100644
--- a/pkgs/applications/science/biology/neuron/default.nix
+++ b/pkgs/applications/science/biology/neuron/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , automake
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = [ readline ncurses which libtool ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simulation environment for empirically-based simulations of neurons and networks of neurons";
 
     longDescription = "NEURON is a simulation environment for developing and exercising models of
diff --git a/pkgs/applications/science/biology/niftyreg/default.nix b/pkgs/applications/science/biology/niftyreg/default.nix
index 4e965d70fe310..d5f625893e925 100644
--- a/pkgs/applications/science/biology/niftyreg/default.nix
+++ b/pkgs/applications/science/biology/niftyreg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, zlib }:
+{ lib, stdenv, fetchurl, cmake, zlib }:
 
 stdenv.mkDerivation rec {
   pname   = "niftyreg";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cmictig.cs.ucl.ac.uk/wiki/index.php/NiftyReg";
     description = "Medical image registration software";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/niftyseg/default.nix b/pkgs/applications/science/biology/niftyseg/default.nix
index 98cca7815eaa7..215ee35d78a47 100644
--- a/pkgs/applications/science/biology/niftyseg/default.nix
+++ b/pkgs/applications/science/biology/niftyseg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, eigen, zlib }:
+{ lib, stdenv, fetchurl, cmake, eigen, zlib }:
 
 stdenv.mkDerivation rec {
   pname   = "niftyseg";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ eigen zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cmictig.cs.ucl.ac.uk/research/software/software-nifty/niftyseg";
     description = "Software for medical image segmentation, bias field correction, and cortical thickness calculation";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/science/biology/octopus/default.nix b/pkgs/applications/science/biology/octopus/default.nix
index 7dee07275a0f0..b7a4a4c1a2a0a 100644
--- a/pkgs/applications/science/biology/octopus/default.nix
+++ b/pkgs/applications/science/biology/octopus/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, cmake, boost, gmp, htslib, zlib, lzma, pkg-config}:
+{lib, stdenv, fetchFromGitHub, cmake, boost, gmp, htslib, zlib, lzma, pkg-config}:
 
 stdenv.mkDerivation rec {
   pname = "octopus";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     mv $out/octopus $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bayesian haplotype-based mutation calling";
     license = licenses.mit;
     homepage = "https://github.com/luntergroup/octopus";
diff --git a/pkgs/applications/science/biology/picard-tools/default.nix b/pkgs/applications/science/biology/picard-tools/default.nix
index af29dd77ac28d..d18ca2e2a4f8b 100644
--- a/pkgs/applications/science/biology/picard-tools/default.nix
+++ b/pkgs/applications/science/biology/picard-tools/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, jre, makeWrapper}:
+{lib, stdenv, fetchurl, jre, makeWrapper}:
 
 stdenv.mkDerivation rec {
   pname = "picard-tools";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/picard --add-flags "-jar $out/libexec/picard/picard.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for high-throughput sequencing (HTS) data and formats such as SAM/BAM/CRAM and VCF";
     license = licenses.mit;
     homepage = "https://broadinstitute.github.io/picard/";
diff --git a/pkgs/applications/science/biology/platypus/default.nix b/pkgs/applications/science/biology/platypus/default.nix
index 30e45d5af0ecb..30bc68fb0e874 100644
--- a/pkgs/applications/science/biology/platypus/default.nix
+++ b/pkgs/applications/science/biology/platypus/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, python27, htslib, zlib, makeWrapper}:
+{lib, stdenv, fetchFromGitHub, python27, htslib, zlib, makeWrapper}:
 
 let python = python27.withPackages (ps: with ps; [ cython ]);
 
@@ -28,7 +28,7 @@ in stdenv.mkDerivation {
     makeWrapper ${python}/bin/python $out/bin/platypus --add-flags "$out/libexec/platypus/bin/Platypus.py"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Platypus variant caller";
     license = licenses.gpl3;
     homepage = "https://github.com/andyrimmer/Platypus";
diff --git a/pkgs/applications/science/biology/prodigal/default.nix b/pkgs/applications/science/biology/prodigal/default.nix
index ba51c93c38c25..70069fe541d19 100644
--- a/pkgs/applications/science/biology/prodigal/default.nix
+++ b/pkgs/applications/science/biology/prodigal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "prodigal";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     "INSTALLDIR=$(out)/bin"
   ];
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, reliable protein-coding gene prediction for prokaryotic genomes";
     homepage = "https://github.com/hyattpd/Prodigal";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/biology/raxml/default.nix b/pkgs/applications/science/biology/raxml/default.nix
index a77505c1b3f81..e4019295ece14 100644
--- a/pkgs/applications/science/biology/raxml/default.nix
+++ b/pkgs/applications/science/biology/raxml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgs
 , mpi ? false
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin && cp raxmlHPC-PTHREADS-SSE3 $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for Phylogenetic Analysis and Post-Analysis of Large Phylogenies";
     license = licenses.gpl3;
     homepage = "https://sco.h-its.org/exelixis/web/software/raxml/";
diff --git a/pkgs/applications/science/biology/sambamba/default.nix b/pkgs/applications/science/biology/sambamba/default.nix
index 7e33a66121890..8802736efac81 100644
--- a/pkgs/applications/science/biology/sambamba/default.nix
+++ b/pkgs/applications/science/biology/sambamba/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, which, dmd, ldc, zlib }:
+{ lib, stdenv, fetchFromGitHub, python3, which, dmd, ldc, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "sambamba";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp bin/sambamba-${version} $out/bin/sambamba
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SAM/BAM processing tool";
     homepage = "https://lomereiter.github.io/sambamba/";
     maintainers = with maintainers; [ jbedo ];
diff --git a/pkgs/applications/science/biology/samblaster/default.nix b/pkgs/applications/science/biology/samblaster/default.nix
index 6846e3c84fae4..48c19666ba046 100644
--- a/pkgs/applications/science/biology/samblaster/default.nix
+++ b/pkgs/applications/science/biology/samblaster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "samblaster";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp samblaster $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for marking duplicates and extracting discordant/split reads from SAM/BAM files";
     maintainers = with maintainers; [ jbedo ];
     license = licenses.mit;
diff --git a/pkgs/applications/science/biology/samtools/default.nix b/pkgs/applications/science/biology/samtools/default.nix
index 27ed79a1f6ca5..7dd78ee2e635c 100644
--- a/pkgs/applications/science/biology/samtools/default.nix
+++ b/pkgs/applications/science/biology/samtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, htslib, perl, ncurses ? null }:
+{ lib, stdenv, fetchurl, zlib, htslib, perl, ncurses ? null }:
 
 stdenv.mkDerivation rec {
   pname = "samtools";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for manipulating SAM/BAM/CRAM format";
     license = licenses.mit;
     homepage = "http://www.htslib.org/";
diff --git a/pkgs/applications/science/biology/samtools/samtools_0_1_19.nix b/pkgs/applications/science/biology/samtools/samtools_0_1_19.nix
index d62c2a1fe7b1a..590f10dd87a1a 100644
--- a/pkgs/applications/science/biology/samtools/samtools_0_1_19.nix
+++ b/pkgs/applications/science/biology/samtools/samtools_0_1_19.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib }:
+{ lib, stdenv, fetchurl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "samtools";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp samtools.1 $out/share/man
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for manipulating SAM/BAM/CRAM format";
     license = licenses.mit;
     homepage = "http://samtools.sourceforge.net/";
diff --git a/pkgs/applications/science/biology/seaview/default.nix b/pkgs/applications/science/biology/seaview/default.nix
index dfee979478251..27d83f3bf89ed 100644
--- a/pkgs/applications/science/biology/seaview/default.nix
+++ b/pkgs/applications/science/biology/seaview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, coreutils, fltk, libjpeg }:
+{ lib, stdenv, fetchurl, coreutils, fltk, libjpeg }:
 
 stdenv.mkDerivation rec {
   version = "5.0.4";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   patchPhase = "sed -i 's#PATH=/bin:/usr/bin rm#'${coreutils}/bin/rm'#' seaview.cxx";
   installPhase = "mkdir -p $out/bin; cp seaview $out/bin";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for molecular phylogeny";
     longDescription = ''
       SeaView is a multiplatform, graphical user interface for multiple sequence alignment and molecular phylogeny.
diff --git a/pkgs/applications/science/biology/snpeff/default.nix b/pkgs/applications/science/biology/snpeff/default.nix
index 941f107a580fe..32701af8392cc 100644
--- a/pkgs/applications/science/biology/snpeff/default.nix
+++ b/pkgs/applications/science/biology/snpeff/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, jre, unzip, makeWrapper}:
+{lib, stdenv, fetchurl, jre, unzip, makeWrapper}:
 
 stdenv.mkDerivation rec {
   pname = "snpeff";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/snpsift --add-flags "-jar $out/libexec/snpeff/SnpSift.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Genetic variant annotation and effect prediction toolbox";
     license = licenses.lgpl3;
     homepage = "http://snpeff.sourceforge.net/";
diff --git a/pkgs/applications/science/biology/somatic-sniper/default.nix b/pkgs/applications/science/biology/somatic-sniper/default.nix
index 298bb98ec990c..034409cfb013d 100644
--- a/pkgs/applications/science/biology/somatic-sniper/default.nix
+++ b/pkgs/applications/science/biology/somatic-sniper/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, cmake, zlib, ncurses}:
+{lib, stdenv, fetchFromGitHub, cmake, zlib, ncurses}:
 
 stdenv.mkDerivation rec {
   pname = "somatic-sniper";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Identify single nucleotide positions that are different between tumor and normal";
     license = licenses.mit;
     homepage = "https://github.com/genome/somatic-sniper";
diff --git a/pkgs/applications/science/biology/sortmerna/default.nix b/pkgs/applications/science/biology/sortmerna/default.nix
index 4e32669dfca92..01c65f4bcff48 100644
--- a/pkgs/applications/science/biology/sortmerna/default.nix
+++ b/pkgs/applications/science/biology/sortmerna/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, rocksdb, rapidjson, pkgconfig, fetchFromGitHub, fetchpatch, zlib }:
+{ lib, stdenv, cmake, rocksdb, rapidjson, pkgconfig, fetchFromGitHub, fetchpatch, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "sortmerna";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
         "target_link_libraries(sortmerna Threads::Threads"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for filtering, mapping, and OTU-picking from shotgun genomics data";
     license = licenses.lgpl3;
     platforms = platforms.x86_64;
diff --git a/pkgs/applications/science/biology/spades/default.nix b/pkgs/applications/science/biology/spades/default.nix
index 776719579d979..ec381693aedfb 100644
--- a/pkgs/applications/science/biology/spades/default.nix
+++ b/pkgs/applications/science/biology/spades/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, bzip2, cmake, python3 }:
+{ lib, stdenv, fetchurl, zlib, bzip2, cmake, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "SPAdes";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   sourceRoot = "${pname}-${version}/src";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "St. Petersburg genome assembler: assembly toolkit containing various assembly pipelines";
     license = licenses.gpl2;
     homepage = "http://cab.spbu.ru/software/spades/";
diff --git a/pkgs/applications/science/biology/star/default.nix b/pkgs/applications/science/biology/star/default.nix
index f2e1a2a8fee55..a7fe948ecfd60 100644
--- a/pkgs/applications/science/biology/star/default.nix
+++ b/pkgs/applications/science/biology/star/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib }:
+{ lib, stdenv, fetchFromGitHub, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "star";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Spliced Transcripts Alignment to a Reference";
     homepage = "https://github.com/alexdobin/STAR";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/science/biology/strelka/default.nix b/pkgs/applications/science/biology/strelka/default.nix
index a32eddcb1cd93..8585f3770fbcd 100644
--- a/pkgs/applications/science/biology/strelka/default.nix
+++ b/pkgs/applications/science/biology/strelka/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, cmake, zlib, python2}:
+{lib, stdenv, fetchFromGitHub, cmake, zlib, python2}:
 
 stdenv.mkDerivation rec {
   pname = "strelka";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Germline and small variant caller";
     license = licenses.gpl3;
     homepage = "https://github.com/Illumina/strelka";
diff --git a/pkgs/applications/science/biology/sumatools/default.nix b/pkgs/applications/science/biology/sumatools/default.nix
index 1e3b479d54fc7..2a30f33172b95 100644
--- a/pkgs/applications/science/biology/sumatools/default.nix
+++ b/pkgs/applications/science/biology/sumatools/default.nix
@@ -1,8 +1,8 @@
-{ gccStdenv, fetchFromGitLab, zlib }:
+{ lib, gccStdenv, fetchFromGitLab, zlib }:
 
 let
   stdenv = gccStdenv;
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and exact comparison and clustering of sequences";
     homepage = "https://metabarcoding.org/sumatra";
     maintainers = [ maintainers.bzizou ];
diff --git a/pkgs/applications/science/biology/svaba/default.nix b/pkgs/applications/science/biology/svaba/default.nix
index ae8dc95d6fea2..87b77f6ac0456 100644
--- a/pkgs/applications/science/biology/svaba/default.nix
+++ b/pkgs/applications/science/biology/svaba/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, zlib, bzip2, lzma, fetchFromGitHub } :
+{ lib, stdenv, zlib, bzip2, lzma, fetchFromGitHub } :
 
 stdenv.mkDerivation rec {
   version = "1.1.0";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Structural variant and INDEL caller for DNA sequencing data, using genome-wide local assembly";
     license = licenses.gpl3;
     homepage = "https://github.com/walaj/svaba";
diff --git a/pkgs/applications/science/biology/tebreak/default.nix b/pkgs/applications/science/biology/tebreak/default.nix
index 82c624ba7cd9e..b70ac29e38f79 100644
--- a/pkgs/applications/science/biology/tebreak/default.nix
+++ b/pkgs/applications/science/biology/tebreak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, last, exonerate, minia, python3Packages, bwa
+{ lib, stdenv, fetchFromGitHub, last, exonerate, minia, python3Packages, bwa
 , samtools, findutils, python }:
 
 python3Packages.buildPythonApplication rec {
@@ -38,7 +38,7 @@ python3Packages.buildPythonApplication rec {
     ${python.interpreter} checktest.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Find and characterise transposable element insertions";
     homepage = "https://github.com/adamewing/tebreak";
     license = licenses.mit;
diff --git a/pkgs/applications/science/biology/trimal/default.nix b/pkgs/applications/science/biology/trimal/default.nix
index 8d7e62b614316..b27a63a2135ae 100755
--- a/pkgs/applications/science/biology/trimal/default.nix
+++ b/pkgs/applications/science/biology/trimal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "trimal";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp -a trimal readal statal $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for the automated removal of spurious sequences or poorly aligned regions from a multiple sequence alignment";
     license = licenses.gpl3;
     platforms = platforms.linux;
diff --git a/pkgs/applications/science/biology/varscan/default.nix b/pkgs/applications/science/biology/varscan/default.nix
index 2c395650e175d..65a19b83a70ec 100644
--- a/pkgs/applications/science/biology/varscan/default.nix
+++ b/pkgs/applications/science/biology/varscan/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, jre, makeWrapper}:
+{lib, stdenv, fetchurl, jre, makeWrapper}:
 
 stdenv.mkDerivation rec {
   pname = "varscan";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/varscan --add-flags "-jar $out/libexec/varscan/varscan.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Variant calling and somatic mutation/CNV detection for next-generation sequencing data";
     # VarScan 2 is free for non-commercial use by academic,
     # government, and non-profit/not-for-profit institutions. A
diff --git a/pkgs/applications/science/biology/vcftools/default.nix b/pkgs/applications/science/biology/vcftools/default.nix
index 52957b58bc929..61b2ea143b8d5 100755
--- a/pkgs/applications/science/biology/vcftools/default.nix
+++ b/pkgs/applications/science/biology/vcftools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib, autoreconfHook, pkgconfig, perl }:
+{ lib, stdenv, fetchFromGitHub, zlib, autoreconfHook, pkgconfig, perl }:
 
 stdenv.mkDerivation rec {
   pname = "vcftools";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ autoreconfHook pkgconfig zlib perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of tools written in Perl and C++ for working with VCF files, such as those generated by the 1000 Genomes Project";
     license = licenses.lgpl3;
     platforms = platforms.linux;
diff --git a/pkgs/applications/science/biology/whisper/default.nix b/pkgs/applications/science/biology/whisper/default.nix
index 9e336600202b3..8552eede170bc 100644
--- a/pkgs/applications/science/biology/whisper/default.nix
+++ b/pkgs/applications/science/biology/whisper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl }:
+{ lib, stdenv, fetchFromGitHub, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "whisper";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Short read sequence mapper";
     license = licenses.gpl3;
     homepage = "https://github.com/refresh-bio/whisper";
diff --git a/pkgs/applications/science/chemistry/d-seams/default.nix b/pkgs/applications/science/chemistry/d-seams/default.nix
index 72962455ac90b..cbe73bb7edc25 100644
--- a/pkgs/applications/science/chemistry/d-seams/default.nix
+++ b/pkgs/applications/science/chemistry/d-seams/default.nix
@@ -15,7 +15,7 @@ clangStdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake lua luaPackages.luafilesystem ];
   buildInputs = [ fmt rang libyamlcpp eigen catch2 boost gsl liblapack blas ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "d-SEAMS: Deferred Structural Elucidation Analysis for Molecular Simulations";
     longDescription = ''
diff --git a/pkgs/applications/science/chemistry/jmol/default.nix b/pkgs/applications/science/chemistry/jmol/default.nix
index e09abccad121e..aa52fee0890d6 100644
--- a/pkgs/applications/science/chemistry/jmol/default.nix
+++ b/pkgs/applications/science/chemistry/jmol/default.nix
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
      description = "A Java 3D viewer for chemical structures";
      homepage = "https://sourceforge.net/projects/jmol";
      license = licenses.lgpl2;
diff --git a/pkgs/applications/science/chemistry/molden/default.nix b/pkgs/applications/science/chemistry/molden/default.nix
index 0d7e81cd9dabb..ac3dd513f34b2 100644
--- a/pkgs/applications/science/chemistry/molden/default.nix
+++ b/pkgs/applications/science/chemistry/molden/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, gfortran, libGLU, xorg } :
+{ lib, stdenv, fetchurl, which, gfortran, libGLU, xorg } :
 
 stdenv.mkDerivation rec {
   version = "6.3";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
      description = "Display and manipulate molecular structures";
      homepage = "http://www.cmbi.ru.nl/molden/";
      license = {
diff --git a/pkgs/applications/science/chemistry/octopus/default.nix b/pkgs/applications/science/chemistry/octopus/default.nix
index 05f93a1a2055c..74ed1873efedd 100644
--- a/pkgs/applications/science/chemistry/octopus/default.nix
+++ b/pkgs/applications/science/chemistry/octopus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, symlinkJoin, gfortran, perl, procps
+{ lib, stdenv, fetchFromGitLab, symlinkJoin, gfortran, perl, procps
 , libyaml, libxc, fftw, blas, lapack, gsl, netcdf, arpack, autoreconfHook
 , python3
 }:
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Real-space time dependent density-functional theory code";
     homepage = "https://octopus-code.org";
     maintainers = with maintainers; [ markuskowa ];
diff --git a/pkgs/applications/science/chemistry/openmolcas/default.nix b/pkgs/applications/science/chemistry/openmolcas/default.nix
index 334a85d3a5f0f..1297e595b9a8e 100644
--- a/pkgs/applications/science/chemistry/openmolcas/default.nix
+++ b/pkgs/applications/science/chemistry/openmolcas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, cmake, gfortran, perl
+{ lib, stdenv, fetchFromGitLab, cmake, gfortran, perl
 , openblas, hdf5-cpp, python3, texlive
 , armadillo, openmpi, globalarrays, openssh
 , makeWrapper, fetchpatch
@@ -65,7 +65,7 @@ in stdenv.mkDerivation {
     wrapProgram $out/bin/pymolcas --set MOLCAS $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced quantum chemistry software package";
     homepage = "https://gitlab.com/Molcas/OpenMolcas";
     maintainers = [ maintainers.markuskowa ];
diff --git a/pkgs/applications/science/chemistry/quantum-espresso/default.nix b/pkgs/applications/science/chemistry/quantum-espresso/default.nix
index 071091f2ecf20..717ff1dba82b8 100644
--- a/pkgs/applications/science/chemistry/quantum-espresso/default.nix
+++ b/pkgs/applications/science/chemistry/quantum-espresso/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , gfortran, fftw, blas, lapack
 , mpi ? null
 }:
@@ -27,7 +27,7 @@ configureFlags = if (mpi != null) then [ "LD=${mpi}/bin/mpif90" ] else [ "LD=${g
 
   makeFlags = [ "all" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Electronic-structure calculations and materials modeling at the nanoscale";
     longDescription = ''
         Quantum ESPRESSO is an integrated suite of Open-Source computer codes for
diff --git a/pkgs/applications/science/chemistry/siesta/default.nix b/pkgs/applications/science/chemistry/siesta/default.nix
index c053c0a09cdf7..cb4667adcab46 100644
--- a/pkgs/applications/science/chemistry/siesta/default.nix
+++ b/pkgs/applications/science/chemistry/siesta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , gfortran, blas, lapack
 , mpi ? null, scalapack
 }:
@@ -46,7 +46,7 @@ stdenv.mkDerivation {
     cp -a siesta $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A first-principles materials simulation code using DFT";
     longDescription = ''
          SIESTA is both a method and its computer program
diff --git a/pkgs/applications/science/electronics/alliance/default.nix b/pkgs/applications/science/electronics/alliance/default.nix
index 861f6cea0b4b3..081a4cab1df2f 100644
--- a/pkgs/applications/science/electronics/alliance/default.nix
+++ b/pkgs/applications/science/electronics/alliance/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , xorgproto, motif, libX11, libXt, libXpm, bison
 , flex, automake, autoconf, libtool, runtimeShell
 }:
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/alliance-uninstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Complete set of free CAD tools and portable libraries for VLSI design";
     homepage = "http://www-asim.lip6.fr/recherche/alliance/";
     license = with licenses; gpl2Plus;
diff --git a/pkgs/applications/science/electronics/bitscope/common.nix b/pkgs/applications/science/electronics/bitscope/common.nix
index acbdeb8cfaa2f..8aade9dd2c89a 100644
--- a/pkgs/applications/science/electronics/bitscope/common.nix
+++ b/pkgs/applications/science/electronics/bitscope/common.nix
@@ -7,7 +7,7 @@
 , gtk2-x11
 , makeWrapper
 , pango
-, stdenv
+, lib, stdenv
 , xorg
 }:
 
@@ -22,7 +22,7 @@ let
 
     name = "${toolName}-${version}";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://bitscope.com/software/";
       license = licenses.unfree;
       platforms = [ "x86_64-linux" ];
diff --git a/pkgs/applications/science/electronics/csxcad/default.nix b/pkgs/applications/science/electronics/csxcad/default.nix
index f1ea93760039e..d9953a7857390 100644
--- a/pkgs/applications/science/electronics/csxcad/default.nix
+++ b/pkgs/applications/science/electronics/csxcad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , fparser
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A C++ library to describe geometrical objects";
     homepage = "https://github.com/thliebig/CSXCAD";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/science/electronics/diylc/default.nix b/pkgs/applications/science/electronics/diylc/default.nix
index 28f12ee221462..70d07460a7518 100644
--- a/pkgs/applications/science/electronics/diylc/default.nix
+++ b/pkgs/applications/science/electronics/diylc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, unzip, bash, jre8 }:
+{ lib, stdenv, fetchurl, makeDesktopItem, unzip, bash, jre8 }:
 
 let
   pname = "diylc";
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/diylc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi platform circuit layout and schematic drawing tool";
     homepage = "https://bancika.github.io/diy-layout-creator/";
     changelog = "https://github.com/bancika/diy-layout-creator/releases";
diff --git a/pkgs/applications/science/electronics/dsview/libsigrok4dsl.nix b/pkgs/applications/science/electronics/dsview/libsigrok4dsl.nix
index 7915cb0ba4ae7..a2fcb9a929d77 100644
--- a/pkgs/applications/science/electronics/dsview/libsigrok4dsl.nix
+++ b/pkgs/applications/science/electronics/dsview/libsigrok4dsl.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, autoreconfHook,
+{ lib, stdenv, pkgconfig, autoreconfHook,
 glib, libzip, libserialport, check, libusb1, libftdi,
 systemd, alsaLib, dsview
 }:
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     glib libzip libserialport libusb1 libftdi systemd check alsaLib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fork of the sigrok library for usage with DSView";
     homepage = "https://www.dreamsourcelab.com/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/science/electronics/dsview/libsigrokdecode4dsl.nix b/pkgs/applications/science/electronics/dsview/libsigrokdecode4dsl.nix
index 72b2fa1b6854f..2bab4b681d3fa 100644
--- a/pkgs/applications/science/electronics/dsview/libsigrokdecode4dsl.nix
+++ b/pkgs/applications/science/electronics/dsview/libsigrokdecode4dsl.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, autoreconfHook,
+{ lib, stdenv, pkgconfig, autoreconfHook,
 glib, check, python3, dsview
 }:
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     python3 glib check
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fork of the sigrokdecode library for usage with DSView";
     homepage = "https://www.dreamsourcelab.com/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/science/electronics/eagle/eagle.nix b/pkgs/applications/science/electronics/eagle/eagle.nix
index 400e5e3009759..130146e0d9a11 100644
--- a/pkgs/applications/science/electronics/eagle/eagle.nix
+++ b/pkgs/applications/science/electronics/eagle/eagle.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, makeDesktopItem
+{ lib, stdenv, mkDerivation, fetchurl, makeDesktopItem
 , libXrender, libXrandr, libXcursor, libX11, libXext, libXi, libxcb
  , libGL, glib, nss, nspr, expat, alsaLib
 , qtbase, qtdeclarative, qtsvg, qtlocation, qtwebchannel, qtwebengine
@@ -70,7 +70,7 @@ let
       ln -s "$out/eagle-${version}/bin/eagle-logo.png" "$out"/share/icons/eagle.png
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Schematic editor and PCB layout tool from Autodesk (formerly CadSoft)";
       homepage = "https://www.autodesk.com/products/eagle/overview";
       license = licenses.unfree;
diff --git a/pkgs/applications/science/electronics/eagle/eagle7.nix b/pkgs/applications/science/electronics/eagle/eagle7.nix
index 5546bb9104555..d826d2d2c24a6 100644
--- a/pkgs/applications/science/electronics/eagle/eagle7.nix
+++ b/pkgs/applications/science/electronics/eagle/eagle7.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, patchelf, zlib, freetype, fontconfig
+{ lib, stdenv, fetchurl, makeDesktopItem, patchelf, zlib, freetype, fontconfig
 , openssl, libXrender, libXrandr, libXcursor, libX11, libXext, libXi
 , libxcb, cups, xkeyboardconfig, runtimeShell
 }:
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
     ln -s "$out/eagle-${version}/bin/eagleicon50.png" "$out"/share/icons/eagle.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Schematic editor and PCB layout tool from CadSoft";
     homepage = "http://www.cadsoftusa.com/";
     license = licenses.unfree;
diff --git a/pkgs/applications/science/electronics/fparser/default.nix b/pkgs/applications/science/electronics/fparser/default.nix
index 55e40ca2b00bd..73db0575d0b1b 100644
--- a/pkgs/applications/science/electronics/fparser/default.nix
+++ b/pkgs/applications/science/electronics/fparser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 }:
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C++ Library for Evaluating Mathematical Functions";
     homepage = "https://github.com/thliebig/fparser";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/science/electronics/geda/default.nix b/pkgs/applications/science/electronics/geda/default.nix
index 54ab7ec57e277..c9a3dcf1aa033 100644
--- a/pkgs/applications/science/electronics/geda/default.nix
+++ b/pkgs/applications/science/electronics/geda/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, guile, gtk2, flex, gawk, perl }:
+{ lib, stdenv, fetchurl, pkgconfig, guile, gtk2, flex, gawk, perl }:
 
 stdenv.mkDerivation {
   pname = "geda";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ guile gtk2 flex gawk perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Full GPL'd suite of Electronic Design Automation tools";
     homepage = "http://www.geda-project.org/";
     maintainers = with maintainers; [ pjones ];
diff --git a/pkgs/applications/science/electronics/gerbv/default.nix b/pkgs/applications/science/electronics/gerbv/default.nix
index b0317551df8dd..a44a892eabebe 100644
--- a/pkgs/applications/science/electronics/gerbv/default.nix
+++ b/pkgs/applications/science/electronics/gerbv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, pkgconfig, gettext, libtool, automake, autoconf, cairo, gtk2, autoreconfHook }:
+{ lib, stdenv, fetchgit, pkgconfig, gettext, libtool, automake, autoconf, cairo, gtk2, autoreconfHook }:
 
 stdenv.mkDerivation {
   pname = "gerbv";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   configureFlags = ["--disable-update-desktop-database"];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Gerber (RS-274X) viewer";
     homepage = "http://gerbv.geda-project.org/";
     maintainers = with maintainers; [ mog ];
diff --git a/pkgs/applications/science/electronics/hal-hardware-analyzer/default.nix b/pkgs/applications/science/electronics/hal-hardware-analyzer/default.nix
index 896a2a0108443..47f901c0ba583 100644
--- a/pkgs/applications/science/electronics/hal-hardware-analyzer/default.nix
+++ b/pkgs/applications/science/electronics/hal-hardware-analyzer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, ninja, pkgconfig, python3Packages
+{ lib, stdenv, fetchFromGitHub, cmake, ninja, pkgconfig, python3Packages
 , boost, rapidjson, qtbase, qtsvg, igraph, spdlog, wrapQtAppsHook
 , fmt, graphviz, llvmPackages ? null
 }:
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
   # the qt mkDerivation - the latter forcibly overrides this.
   cmakeBuildType = "MinSizeRel";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A comprehensive reverse engineering and manipulation framework for gate-level netlists";
     homepage = "https://github.com/emsec/hal";
     license = licenses.mit;
diff --git a/pkgs/applications/science/electronics/hyp2mat/default.nix b/pkgs/applications/science/electronics/hyp2mat/default.nix
index 154b68dd5aa21..01d587fc17232 100644
--- a/pkgs/applications/science/electronics/hyp2mat/default.nix
+++ b/pkgs/applications/science/electronics/hyp2mat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , bison
 , flex
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Import Hyperlynx Boardsim files to openEMS, an open source 3D full-wave electromagnetic field solver";
     homepage = "https://github.com/koendv/hyp2mat";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/science/electronics/kicad/i18n.nix b/pkgs/applications/science/electronics/kicad/i18n.nix
index 95cea4fd7fc47..9a93e4ca7ce6c 100644
--- a/pkgs/applications/science/electronics/kicad/i18n.nix
+++ b/pkgs/applications/science/electronics/kicad/i18n.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , cmake
 , gettext
 , src
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
   pname = "kicad-i18n";
 
   nativeBuildInputs = [ cmake gettext ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl2; # https://github.com/KiCad/kicad-i18n/issues/3
     platforms = platforms.all;
   };
diff --git a/pkgs/applications/science/electronics/librepcb/default.nix b/pkgs/applications/science/electronics/librepcb/default.nix
index 4b0a4108ab22b..394a178761551 100644
--- a/pkgs/applications/science/electronics/librepcb/default.nix
+++ b/pkgs/applications/science/electronics/librepcb/default.nix
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     wrapQtApp $out/bin/librepcb
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free EDA software to develop printed circuit boards";
     homepage    = "https://librepcb.org/";
     maintainers = with maintainers; [ luz thoughtpolice ];
diff --git a/pkgs/applications/science/electronics/magic-vlsi/default.nix b/pkgs/applications/science/electronics/magic-vlsi/default.nix
index d6c9011efa681..82d8dbd2ddc44 100644
--- a/pkgs/applications/science/electronics/magic-vlsi/default.nix
+++ b/pkgs/applications/science/electronics/magic-vlsi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python3
 , m4
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     ./0002-fix-format-security.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VLSI layout tool written in Tcl";
     homepage    = "http://opencircuitdesign.com/magic/";
     license     = licenses.mit;
diff --git a/pkgs/applications/science/electronics/ngspice/default.nix b/pkgs/applications/science/electronics/ngspice/default.nix
index 5113dc778f62d..f8fbdffc63405 100644
--- a/pkgs/applications/science/electronics/ngspice/default.nix
+++ b/pkgs/applications/science/electronics/ngspice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , bison
 , flex
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--enable-x" "--with-x" "--with-readline" "--enable-xspice" "--enable-cider" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Next Generation Spice (Electronic Circuit Simulator)";
     homepage = "http://ngspice.sourceforge.net";
     license = with licenses; [ "BSD" gpl2 ];
diff --git a/pkgs/applications/science/electronics/pcb/default.nix b/pkgs/applications/science/electronics/pcb/default.nix
index 4309f52e8b150..47de21739472c 100644
--- a/pkgs/applications/science/electronics/pcb/default.nix
+++ b/pkgs/applications/science/electronics/pcb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , gtk2
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     "--disable-update-desktop-database"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Printed Circuit Board editor";
     homepage = "http://pcb.geda-project.org/";
     maintainers = with maintainers; [ mog ];
diff --git a/pkgs/applications/science/electronics/verilator/default.nix b/pkgs/applications/science/electronics/verilator/default.nix
index ce8ebe42ea874..27423e7530807 100644
--- a/pkgs/applications/science/electronics/verilator/default.nix
+++ b/pkgs/applications/science/electronics/verilator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , perl, flex, bison
 }:
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   doCheck = false;
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and robust (System)Verilog simulator/compiler";
     homepage    = "https://www.veripool.org/wiki/verilator";
     license     = licenses.lgpl3;
diff --git a/pkgs/applications/science/electronics/verilog/default.nix b/pkgs/applications/science/electronics/verilog/default.nix
index 6217df2db8f84..081ca65f315e3 100644
--- a/pkgs/applications/science/electronics/verilog/default.nix
+++ b/pkgs/applications/science/electronics/verilog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoconf
 , bison
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Icarus Verilog compiler";
     homepage    = "http://iverilog.icarus.com/";  # https does not work
     license     = with licenses; [ gpl2Plus lgpl21Plus ];
diff --git a/pkgs/applications/science/electronics/vhd2vl/default.nix b/pkgs/applications/science/electronics/vhd2vl/default.nix
index be9e890fc8d55..4014f53f649f7 100644
--- a/pkgs/applications/science/electronics/vhd2vl/default.nix
+++ b/pkgs/applications/science/electronics/vhd2vl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , bison
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     cp src/vhd2vl $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VHDL to Verilog converter";
     homepage = "https://github.com/ldoolitt/vhd2vl";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/science/electronics/xcircuit/default.nix b/pkgs/applications/science/electronics/xcircuit/default.nix
index 52fe9b0374143..d7bdf5c67c06c 100644
--- a/pkgs/applications/science/electronics/xcircuit/default.nix
+++ b/pkgs/applications/science/electronics/xcircuit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, automake, pkgconfig
+{ lib, stdenv, fetchurl, autoreconfHook, automake, pkgconfig
 , cairo, ghostscript, ngspice, tcl, tk, xorg, zlib }:
 
 let
@@ -25,7 +25,7 @@ in stdenv.mkDerivation {
 
   buildInputs = with xorg; [ cairo ghostscript libSM libXt libICE libX11 libXpm tcl tk zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generic drawing program tailored to circuit diagrams";
     homepage = "http://opencircuitdesign.com/xcircuit";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/geometry/antiprism/default.nix b/pkgs/applications/science/geometry/antiprism/default.nix
index 4691291a4257a..8dee645646c51 100644
--- a/pkgs/applications/science/geometry/antiprism/default.nix
+++ b/pkgs/applications/science/geometry/antiprism/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , libX11
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ libX11 libGLU libGL.dev freeglut.dev ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.antiprism.com";
     description = "A collection of programs for generating, manipulating, transforming and viewing polyhedra";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/science/geometry/drgeo/default.nix b/pkgs/applications/science/geometry/drgeo/default.nix
index 7bae3d414cbf9..a147cb305ccc6 100644
--- a/pkgs/applications/science/geometry/drgeo/default.nix
+++ b/pkgs/applications/science/geometry/drgeo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libglade, gtk2, guile, libxml2, perl
+{ lib, stdenv, fetchurl, libglade, gtk2, guile, libxml2, perl
 , intltool, libtool, pkgconfig }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp drgeo.desktop.in drgeo.desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interactive geometry program";
     homepage = "https://sourceforge.net/projects/ofset";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/logic/abc/default.nix b/pkgs/applications/science/logic/abc/default.nix
index 0e60122a59887..cbcd452033ca0 100644
--- a/pkgs/applications/science/logic/abc/default.nix
+++ b/pkgs/applications/science/logic/abc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , readline, cmake
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   # needed by yosys
   passthru.rev = src.rev;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for squential logic synthesis and formal verification";
     homepage    = "https://people.eecs.berkeley.edu/~alanmi/abc";
     license     = licenses.mit;
diff --git a/pkgs/applications/science/logic/acgtk/default.nix b/pkgs/applications/science/logic/acgtk/default.nix
index ccd0800050761..48563248773fe 100644
--- a/pkgs/applications/science/logic/acgtk/default.nix
+++ b/pkgs/applications/science/logic/acgtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dune, ocamlPackages }:
+{ lib, stdenv, fetchurl, dune, ocamlPackages }:
 
 stdenv.mkDerivation {
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
 
   inherit (dune) installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://acg.loria.fr/";
     description = "A toolkit for developing ACG signatures and lexicon";
     license = licenses.cecill20;
diff --git a/pkgs/applications/science/logic/aspino/default.nix b/pkgs/applications/science/logic/aspino/default.nix
index c1cf9034c02a3..f9cc97893da8f 100644
--- a/pkgs/applications/science/logic/aspino/default.nix
+++ b/pkgs/applications/science/logic/aspino/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, zlib, boost }:
+{ lib, stdenv, fetchurl, fetchFromGitHub, zlib, boost }:
 
 let
   glucose' = fetchurl {
@@ -38,7 +38,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SAT/PseudoBoolean/MaxSat/ASP solver using glucose";
     maintainers = with maintainers; [ gebner ];
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/logic/boolector/default.nix b/pkgs/applications/science/logic/boolector/default.nix
index 0364a76639aac..2898ce4e1f660 100644
--- a/pkgs/applications/science/logic/boolector/default.nix
+++ b/pkgs/applications/science/logic/boolector/default.nix
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
     cp $out/include/boolector/btortypes.h $out/include/btortypes.h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extremely fast SMT solver for bit-vectors and arrays";
     homepage    = "https://boolector.github.io";
     license     = licenses.mit;
diff --git a/pkgs/applications/science/logic/btor2tools/default.nix b/pkgs/applications/science/logic/btor2tools/default.nix
index 7d2aed7596e88..355274d1e1cd8 100644
--- a/pkgs/applications/science/logic/btor2tools/default.nix
+++ b/pkgs/applications/science/logic/btor2tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, fetchFromGitHub, fixDarwinDylibNames }:
+{ lib, stdenv, cmake, fetchFromGitHub, fixDarwinDylibNames }:
 
 stdenv.mkDerivation rec {
   pname = "btor2tools";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "dev" "lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A generic parser and tool package for the BTOR2 format";
     homepage    = "https://github.com/Boolector/btor2tools";
     license     = licenses.mit;
diff --git a/pkgs/applications/science/logic/cadical/default.nix b/pkgs/applications/science/logic/cadical/default.nix
index e3707ff7dab12..ca5e6b5c41952 100644
--- a/pkgs/applications/science/logic/cadical/default.nix
+++ b/pkgs/applications/science/logic/cadical/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "cadical";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -Dm0755 {LICEN?E,README*,VERSION} "$out/share/doc/${pname}-${version}/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simplified Satisfiability Solver";
     maintainers = with maintainers; [ shnarazk ];
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/logic/cedille/default.nix b/pkgs/applications/science/logic/cedille/default.nix
index 7b181790f1401..2b099e7664a64 100644
--- a/pkgs/applications/science/logic/cedille/default.nix
+++ b/pkgs/applications/science/logic/cedille/default.nix
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     cp -r lib/ $out/lib/cedille/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interactive theorem-prover and dependently typed programming language, based on extrinsic (aka Curry-style) type theory";
     homepage = "https://cedille.github.io/";
     license = licenses.mit;
diff --git a/pkgs/applications/science/logic/celf/default.nix b/pkgs/applications/science/logic/celf/default.nix
index 9dc20a61a4d2c..044a6f3ca1c47 100644
--- a/pkgs/applications/science/logic/celf/default.nix
+++ b/pkgs/applications/science/logic/celf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, smlnj }:
+{ lib, stdenv, fetchFromGitHub, smlnj }:
 
 stdenv.mkDerivation rec {
   pname = "celf";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     ./.mkexec ${smlnj}/bin/sml $out/bin celf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linear logic programming system";
     homepage = "https://github.com/clf/celf";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/logic/clprover/clprover.nix b/pkgs/applications/science/logic/clprover/clprover.nix
index e53bbe6883718..f3049a659d119 100644
--- a/pkgs/applications/science/logic/clprover/clprover.nix
+++ b/pkgs/applications/science/logic/clprover/clprover.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation {
   pname = "clprover";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     cp -r examples $out/share/clprover/examples
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Resolution-based theorem prover for Coalition Logic implemented in C++";
     homepage = "http://cgi.csc.liv.ac.uk/~ullrich/CLProver++/";
     license = licenses.gpl3; # Note that while the website states that it is GPLv2 but the file in the zip as well as the comments in the source state it is GPLv3
diff --git a/pkgs/applications/science/logic/coq/default.nix b/pkgs/applications/science/logic/coq/default.nix
index 9d0876d8d054c..fae17a5e09f25 100644
--- a/pkgs/applications/science/logic/coq/default.nix
+++ b/pkgs/applications/science/logic/coq/default.nix
@@ -5,10 +5,10 @@
 # - The exact version can be specified through the `version` argument to
 #   the derivation; it defaults to the latest stable version.
 
-{ stdenv, fetchzip, writeText, pkgconfig, gnumake42
+{ lib, stdenv, fetchzip, writeText, pkgconfig, gnumake42
 , customOCamlPackages ? null
 , ocamlPackages_4_05, ocamlPackages_4_09, ocamlPackages_4_10, ncurses
-, buildIde ? !(stdenv.isDarwin && stdenv.lib.versionAtLeast version "8.10")
+, buildIde ? !(stdenv.isDarwin && lib.versionAtLeast version "8.10")
 , glib, gnome3, wrapGAppsHook
 , csdp ? null
 , version, coq-version ? null,
@@ -166,7 +166,7 @@ self = stdenv.mkDerivation {
     ln -s $out/lib/coq $OCAMLFIND_DESTDIR/coq
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Coq proof assistant";
     longDescription = ''
       Coq is a formal proof management system.  It provides a formal language
diff --git a/pkgs/applications/science/logic/coq2html/default.nix b/pkgs/applications/science/logic/coq2html/default.nix
index e53e8e7392c0a..46f2ebd775bfc 100644
--- a/pkgs/applications/science/logic/coq2html/default.nix
+++ b/pkgs/applications/science/logic/coq2html/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, ocaml }:
+{ lib, stdenv, fetchgit, ocaml }:
 
 let
   version = "20170720";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     cp coq2html $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTML documentation generator for Coq source files";
     longDescription = ''
       coq2html is an HTML documentation generator for Coq source files. It is
diff --git a/pkgs/applications/science/logic/cryptominisat/default.nix b/pkgs/applications/science/logic/cryptominisat/default.nix
index ddbb140c9baae..042a4b23566c1 100644
--- a/pkgs/applications/science/logic/cryptominisat/default.nix
+++ b/pkgs/applications/science/logic/cryptominisat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, python3, xxd, boost, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, cmake, python3, xxd, boost, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "cryptominisat";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ python3 boost ];
   nativeBuildInputs = [ cmake xxd ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An advanced SAT Solver";
     homepage    = "https://github.com/msoos/cryptominisat";
     license     = licenses.mit;
diff --git a/pkgs/applications/science/logic/cubicle/default.nix b/pkgs/applications/science/logic/cubicle/default.nix
index bfb6a57fb33a6..aa3fba635ffc1 100644
--- a/pkgs/applications/science/logic/cubicle/default.nix
+++ b/pkgs/applications/science/logic/cubicle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocamlPackages }:
+{ lib, stdenv, fetchurl, ocamlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "cubicle";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = with ocamlPackages; [ ocaml findlib functory ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source model checker for verifying safety properties of array-based systems";
     homepage = "http://cubicle.lri.fr/";
     license = licenses.asl20;
diff --git a/pkgs/applications/science/logic/cvc3/default.nix b/pkgs/applications/science/logic/cvc3/default.nix
index be80565115fe3..63efe0a2d05b4 100644
--- a/pkgs/applications/science/logic/cvc3/default.nix
+++ b/pkgs/applications/science/logic/cvc3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, flex, bison, gmp, perl }:
+{ lib, stdenv, fetchurl, flex, bison, gmp, perl }:
 
 stdenv.mkDerivation rec {
     pname = "cvc3";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A prover for satisfiability modulo theory (SMT)";
     maintainers = with maintainers;
       [ raskin ];
diff --git a/pkgs/applications/science/logic/cvc4/default.nix b/pkgs/applications/science/logic/cvc4/default.nix
index 1a92247c54d39..fd31a5732e388 100644
--- a/pkgs/applications/science/logic/cvc4/default.nix
+++ b/pkgs/applications/science/logic/cvc4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, cln, gmp, git, swig, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, cln, gmp, git, swig, pkgconfig
 , readline, libantlr3c, boost, jdk, python3, antlr3_4
 }:
 
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     "-DCMAKE_BUILD_TYPE=Production"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-performance theorem prover and SMT solver";
     homepage    = "http://cvc4.cs.stanford.edu/web/";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/science/logic/drat-trim/default.nix b/pkgs/applications/science/logic/drat-trim/default.nix
index 81e20df334244..c58a29dc28944 100644
--- a/pkgs/applications/science/logic/drat-trim/default.nix
+++ b/pkgs/applications/science/logic/drat-trim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "drat-trim-unstable";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     install -Dt $out/bin drat-trim lrat-check
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A proof checker for unSAT proofs";
     longDescription = ''
       DRAT-trim is a satisfiability proof checking and trimming
diff --git a/pkgs/applications/science/logic/eprover/default.nix b/pkgs/applications/science/logic/eprover/default.nix
index a3844dc3700b2..14c46f88b27c5 100644
--- a/pkgs/applications/science/logic/eprover/default.nix
+++ b/pkgs/applications/science/logic/eprover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which }:
+{ lib, stdenv, fetchurl, which }:
 
 stdenv.mkDerivation rec {
   pname = "eprover";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "--man-prefix=$(out)/share/man"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automated theorem prover for full first-order logic with equality";
     homepage = "http://www.eprover.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/logic/fast-downward/default.nix b/pkgs/applications/science/logic/fast-downward/default.nix
index cc14fd7706aba..bc825703ee3a9 100644
--- a/pkgs/applications/science/logic/fast-downward/default.nix
+++ b/pkgs/applications/science/logic/fast-downward/default.nix
@@ -50,7 +50,7 @@ stdenv.mkDerivation {
       --replace 'args.build = "release"' "args.build = \"$out/libexec/fast-downward\""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A domain-independent planning system";
     homepage = "http://www.fast-downward.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/science/logic/glucose/default.nix b/pkgs/applications/science/logic/glucose/default.nix
index 0a8fad484da73..5ba8208d6e18a 100644
--- a/pkgs/applications/science/logic/glucose/default.nix
+++ b/pkgs/applications/science/logic/glucose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib }:
+{ lib, stdenv, fetchurl, zlib }:
 stdenv.mkDerivation rec {
   pname = "glucose";
   version = "4.1";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -Dm0755 ../{LICEN?E,README*,Changelog*} "$out/share/doc/${pname}-${version}/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern, parallel SAT solver (sequential version)";
     license = licenses.mit;
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/logic/glucose/syrup.nix b/pkgs/applications/science/logic/glucose/syrup.nix
index 816f8504a52e3..17342858fb8f3 100644
--- a/pkgs/applications/science/logic/glucose/syrup.nix
+++ b/pkgs/applications/science/logic/glucose/syrup.nix
@@ -1,4 +1,4 @@
-{ stdenv, zlib, glucose }:
+{ lib, stdenv, zlib, glucose }:
 stdenv.mkDerivation rec {
   pname = "glucose-syrup";
   version = glucose.version;
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     install -Dm0755 ../{LICEN?E,README*,Changelog*} "$out/share/doc/${pname}-${version}/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern, parallel SAT solver (parallel version)";
     license = licenses.unfreeRedistributable;
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/logic/hol/default.nix b/pkgs/applications/science/logic/hol/default.nix
index dbafee7d6000a..6fc7286154aef 100644
--- a/pkgs/applications/science/logic/hol/default.nix
+++ b/pkgs/applications/science/logic/hol/default.nix
@@ -1,4 +1,4 @@
-{stdenv, pkgs, fetchurl, graphviz, fontconfig, liberation_ttf,
+{lib, stdenv, pkgs, fetchurl, graphviz, fontconfig, liberation_ttf,
  experimentalKernel ? true}:
 
 let
@@ -65,7 +65,7 @@ stdenv.mkDerivation {
     # ln -s $out/src/hol4.${version}/bin $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interactive theorem prover based on Higher-Order Logic";
     longDescription = ''
       HOL4 is the latest version of the HOL interactive proof
diff --git a/pkgs/applications/science/logic/hol_light/default.nix b/pkgs/applications/science/logic/hol_light/default.nix
index 9c3030517e327..24faa98f777ba 100644
--- a/pkgs/applications/science/logic/hol_light/default.nix
+++ b/pkgs/applications/science/logic/hol_light/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, runtimeShell, fetchFromGitHub, fetchpatch, ocaml, num, camlp5 }:
+{ lib, stdenv, runtimeShell, fetchFromGitHub, fetchpatch, ocaml, num, camlp5 }:
 
 let
   load_num =
@@ -45,7 +45,7 @@ stdenv.mkDerivation {
     chmod a+x "$out/bin/hol_light"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interactive theorem prover based on Higher-Order Logic";
     homepage    = "http://www.cl.cam.ac.uk/~jrh13/hol-light/";
     license     = licenses.bsd2;
diff --git a/pkgs/applications/science/logic/iprover/default.nix b/pkgs/applications/science/logic/iprover/default.nix
index 310a95d7e7a60..1f02d30cf2531 100644
--- a/pkgs/applications/science/logic/iprover/default.nix
+++ b/pkgs/applications/science/logic/iprover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, eprover, zlib }:
+{ lib, stdenv, fetchurl, ocaml, eprover, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "iprover";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     chmod a+x  "$out"/bin/iprover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An automated first-order logic theorem prover";
     homepage = "http://www.cs.man.ac.uk/~korovink/iprover/";
     maintainers = with maintainers; [ raskin gebner ];
diff --git a/pkgs/applications/science/logic/isabelle/default.nix b/pkgs/applications/science/logic/isabelle/default.nix
index a12d75eabbe9a..9472d4b9b29bb 100644
--- a/pkgs/applications/science/logic/isabelle/default.nix
+++ b/pkgs/applications/science/logic/isabelle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, nettools, java, polyml, z3, rlwrap }:
+{ lib, stdenv, fetchurl, perl, nettools, java, polyml, z3, rlwrap }:
 # nettools needed for hostname
 
 stdenv.mkDerivation rec {
@@ -66,7 +66,7 @@ stdenv.mkDerivation rec {
     bin/isabelle install $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A generic proof assistant";
 
     longDescription = ''
diff --git a/pkgs/applications/science/logic/key/default.nix b/pkgs/applications/science/logic/key/default.nix
index b08c4d84d1fcf..531081beafaf3 100644
--- a/pkgs/applications/science/logic/key/default.nix
+++ b/pkgs/applications/science/logic/key/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , unzip
 , jdk
@@ -56,7 +56,7 @@ in stdenv.mkDerivation rec {
     touch $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Java formal verification tool";
     homepage = "https://www.key-project.org"; # also https://formal.iti.kit.edu/key/
     longDescription = ''
diff --git a/pkgs/applications/science/logic/lean/default.nix b/pkgs/applications/science/logic/lean/default.nix
index f5b7ccd76b175..5bf33a8a3591e 100644
--- a/pkgs/applications/science/logic/lean/default.nix
+++ b/pkgs/applications/science/logic/lean/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, gmp, coreutils }:
+{ lib, stdenv, fetchFromGitHub, cmake, gmp, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "lean";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
       --replace "greadlink" "${coreutils}/bin/readlink"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic and interactive theorem prover";
     homepage    = "https://leanprover.github.io/";
     changelog   = "https://github.com/leanprover-community/lean/blob/v${version}/doc/changes.md";
diff --git a/pkgs/applications/science/logic/lean2/default.nix b/pkgs/applications/science/logic/lean2/default.nix
index 9ac4f2a6c6bbe..b3c6a51d440af 100644
--- a/pkgs/applications/science/logic/lean2/default.nix
+++ b/pkgs/applications/science/logic/lean2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, gmp, mpfr, python
+{ lib, stdenv, fetchFromGitHub, cmake, gmp, mpfr, python
 , gperftools, ninja, makeWrapper }:
 
 stdenv.mkDerivation {
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     wrapProgram $out/bin/linja --prefix PATH : $out/bin:${ninja}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic and interactive theorem prover (version with HoTT support)";
     homepage    = "http://leanprover.github.io";
     license     = licenses.asl20;
diff --git a/pkgs/applications/science/logic/leo2/default.nix b/pkgs/applications/science/logic/leo2/default.nix
index b43bfb8013582..520c47d7500bb 100644
--- a/pkgs/applications/science/logic/leo2/default.nix
+++ b/pkgs/applications/science/logic/leo2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, eprover, ocaml, perl, zlib }:
+{ lib, stdenv, fetchurl, makeWrapper, eprover, ocaml, perl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "leo2";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
       --add-flags "--atprc $out/etc/leoatprc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-performance typed higher order prover";
     maintainers = [ maintainers.raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/science/logic/lingeling/default.nix b/pkgs/applications/science/logic/lingeling/default.nix
index 1805f6cdcc891..08bd0e4d63759 100644
--- a/pkgs/applications/science/logic/lingeling/default.nix
+++ b/pkgs/applications/science/logic/lingeling/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , aiger
 }:
 
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
 
   outputs = [ "out" "dev" "lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast SAT solver";
     homepage    = "http://fmv.jku.at/lingeling/";
     license     = licenses.mit;
diff --git a/pkgs/applications/science/logic/mcrl2/default.nix b/pkgs/applications/science/logic/mcrl2/default.nix
index 584988f2b408e..56898f163b99c 100644
--- a/pkgs/applications/science/logic/mcrl2/default.nix
+++ b/pkgs/applications/science/logic/mcrl2/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, cmake, libGLU, libGL, qt5, boost}:
+{lib, stdenv, fetchurl, cmake, libGLU, libGL, qt5, boost}:
 
 stdenv.mkDerivation rec {
   version = "201707";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ libGLU libGL qt5.qtbase boost ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A toolset for model-checking concurrent systems and protocols";
     longDescription = ''
       A formal specification language with an associated toolset,
diff --git a/pkgs/applications/science/logic/metis-prover/default.nix b/pkgs/applications/science/logic/metis-prover/default.nix
index 5755abfd90788..e30a897e56594 100644
--- a/pkgs/applications/science/logic/metis-prover/default.nix
+++ b/pkgs/applications/science/logic/metis-prover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl, mlton }:
+{ lib, stdenv, fetchFromGitHub, perl, mlton }:
 
 stdenv.mkDerivation {
   pname = "metis-prover";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     install -Dm0755 bin/mlton/metis $out/bin/metis
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic theorem prover for first-order logic with equality";
     homepage = "http://www.gilith.com/research/metis/";
     license = licenses.mit;
diff --git a/pkgs/applications/science/logic/minisat/default.nix b/pkgs/applications/science/logic/minisat/default.nix
index df1800e6c31b0..10d3808827441 100644
--- a/pkgs/applications/science/logic/minisat/default.nix
+++ b/pkgs/applications/science/logic/minisat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, zlib }:
+{ lib, stdenv, fetchFromGitHub, cmake, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "minisat";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compact and readable SAT solver";
     maintainers = with maintainers; [ gebner raskin ];
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/logic/open-wbo/default.nix b/pkgs/applications/science/logic/open-wbo/default.nix
index c314127e74bfe..77db8ae3384da 100644
--- a/pkgs/applications/science/logic/open-wbo/default.nix
+++ b/pkgs/applications/science/logic/open-wbo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib, gmp }:
+{ lib, stdenv, fetchFromGitHub, zlib, gmp }:
 
 stdenv.mkDerivation {
   name = "open-wbo-2.0";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     install -Dm0755 open-wbo_release $out/bin/open-wbo
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "State-of-the-art MaxSAT and Pseudo-Boolean solver";
     maintainers = with maintainers; [ gebner ];
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/logic/opensmt/default.nix b/pkgs/applications/science/logic/opensmt/default.nix
index 03b3ce4ff0b77..3b4dd20931cbc 100644
--- a/pkgs/applications/science/logic/opensmt/default.nix
+++ b/pkgs/applications/science/logic/opensmt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, automake, libtool, autoconf, intltool, perl
+{ lib, stdenv, fetchurl, automake, libtool, autoconf, intltool, perl
 , gmpxx, flex, bison
 }:
 
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ automake libtool autoconf intltool perl gmpxx flex bison ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A satisfiability modulo theory (SMT) solver";
     maintainers = [ maintainers.raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/science/logic/poly/default.nix b/pkgs/applications/science/logic/poly/default.nix
index ee50a2d850401..db124c379cad8 100644
--- a/pkgs/applications/science/logic/poly/default.nix
+++ b/pkgs/applications/science/logic/poly/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, gmp, cmake, python}:
+{lib, stdenv, fetchFromGitHub, gmp, cmake, python}:
 
 stdenv.mkDerivation rec {
   pname = "libpoly";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ gmp python ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/SRI-CSL/libpoly";
     description = "C library for manipulating polynomials";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/science/logic/prooftree/default.nix b/pkgs/applications/science/logic/prooftree/default.nix
index 98313e48cb271..4db3c333e97eb 100644
--- a/pkgs/applications/science/logic/prooftree/default.nix
+++ b/pkgs/applications/science/logic/prooftree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, ncurses, ocamlPackages }:
+{ lib, stdenv, fetchurl, pkgconfig, ncurses, ocamlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "prooftree";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   dontAddPrefix = true;
   configureFlags = [ "--prefix" "$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program for proof-tree visualization";
     longDescription = ''
       Prooftree is a program for proof-tree visualization during interactive
diff --git a/pkgs/applications/science/logic/spass/default.nix b/pkgs/applications/science/logic/spass/default.nix
index ece6f0b9f6a85..77b297b4fbbbd 100644
--- a/pkgs/applications/science/logic/spass/default.nix
+++ b/pkgs/applications/science/logic/spass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bison, flex }:
+{ lib, stdenv, fetchurl, bison, flex }:
 
 let
   baseVersion="3";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     install -m0755 SPASS ${extraTools} $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automated theorem prover for first-order logic";
     maintainers = with maintainers;
     [
diff --git a/pkgs/applications/science/logic/stp/default.nix b/pkgs/applications/science/logic/stp/default.nix
index fcffc239b48f0..42926a870816b 100644
--- a/pkgs/applications/science/logic/stp/default.nix
+++ b/pkgs/applications/science/logic/stp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, boost, bison, flex, fetchFromGitHub, perl
+{ lib, stdenv, cmake, boost, bison, flex, fetchFromGitHub, perl
 , python3, python3Packages, zlib, minisat, cryptominisat }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple Theorem Prover";
     maintainers = with maintainers; [ ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/science/logic/tptp/default.nix b/pkgs/applications/science/logic/tptp/default.nix
index 4c63f8e72a36d..9c91eaddfc47e 100644
--- a/pkgs/applications/science/logic/tptp/default.nix
+++ b/pkgs/applications/science/logic/tptp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, yap, tcsh, perl, patchelf }:
+{ lib, stdenv, fetchurl, yap, tcsh, perl, patchelf }:
 
 stdenv.mkDerivation rec {
   pname = "TPTP";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     ln -s $sharedir/Scripts/tptp4X $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Thousands of problems for theorem provers and tools";
     maintainers = with maintainers; [ raskin gebner ];
     # 6.3 GiB of data. Installation is unpacking and editing a few files.
diff --git a/pkgs/applications/science/logic/vampire/default.nix b/pkgs/applications/science/logic/vampire/default.nix
index dca03823e9eaf..b885445444620 100644
--- a/pkgs/applications/science/logic/vampire/default.nix
+++ b/pkgs/applications/science/logic/vampire/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, z3, zlib }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, z3, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "vampire";
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     install -m0755 -D vampire_z3_rel* $out/bin/vampire
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://vprover.github.io/";
     description = "The Vampire Theorem Prover";
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/logic/verit/default.nix b/pkgs/applications/science/logic/verit/default.nix
index f20a832415714..81acbe4f2d0b7 100644
--- a/pkgs/applications/science/logic/verit/default.nix
+++ b/pkgs/applications/science/logic/verit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, gmp, flex, bison }:
+{ lib, stdenv, fetchurl, autoreconfHook, gmp, flex, bison }:
 
 stdenv.mkDerivation {
   pname = "veriT";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     mkdir -p $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open, trustable and efficient SMT-solver";
     homepage = "http://www.verit-solver.org/";
     license = licenses.bsd3;
diff --git a/pkgs/applications/science/logic/why3/default.nix b/pkgs/applications/science/logic/why3/default.nix
index eacff32bdf62e..deb40c742847d 100644
--- a/pkgs/applications/science/logic/why3/default.nix
+++ b/pkgs/applications/science/logic/why3/default.nix
@@ -1,4 +1,4 @@
-{ callPackage, fetchurl, fetchpatch, stdenv
+{ callPackage, fetchurl, fetchpatch, lib, stdenv
 , ocamlPackages, coqPackages, rubber, hevea, emacs }:
 
 stdenv.mkDerivation {
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
 
   passthru.withProvers = callPackage ./with-provers.nix {};
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A platform for deductive program verification";
     homepage    = "http://why3.lri.fr/";
     license     = licenses.lgpl21;
diff --git a/pkgs/applications/science/logic/yices/default.nix b/pkgs/applications/science/logic/yices/default.nix
index b8dd528a11c1e..a01a07b895407 100644
--- a/pkgs/applications/science/logic/yices/default.nix
+++ b/pkgs/applications/science/logic/yices/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gmp-static, gperf, autoreconfHook, libpoly }:
+{ lib, stdenv, fetchFromGitHub, gmp-static, gperf, autoreconfHook, libpoly }:
 
 stdenv.mkDerivation rec {
   pname = "yices";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
       ln -sfr $out/lib/libyices.so.{${version},${ver_XdotY}}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-performance theorem prover and SMT solver";
     homepage    = "http://yices.csl.sri.com";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/science/machine-learning/fasttext/default.nix b/pkgs/applications/science/machine-learning/fasttext/default.nix
index 64124594e1e22..d05f93a4653ae 100644
--- a/pkgs/applications/science/machine-learning/fasttext/default.nix
+++ b/pkgs/applications/science/machine-learning/fasttext/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, cmake}:
+{lib, stdenv, fetchFromGitHub, cmake}:
 
 stdenv.mkDerivation rec {
   pname = "fasttext";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for text classification and representation learning";
     homepage = "https://fasttext.cc/";
     license = licenses.mit;
diff --git a/pkgs/applications/science/machine-learning/finalfrontier/default.nix b/pkgs/applications/science/machine-learning/finalfrontier/default.nix
index f1a2dbaa54fb6..f2468572101ec 100644
--- a/pkgs/applications/science/machine-learning/finalfrontier/default.nix
+++ b/pkgs/applications/science/machine-learning/finalfrontier/default.nix
@@ -42,7 +42,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion finalfrontier.{bash,fish,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for training word and subword embeddings";
     homepage = "https://github.com/finalfusion/finalfrontier/";
     license = licenses.asl20;
diff --git a/pkgs/applications/science/machine-learning/finalfusion-utils/default.nix b/pkgs/applications/science/machine-learning/finalfusion-utils/default.nix
index eeeafdd3d98cd..d976431e55495 100644
--- a/pkgs/applications/science/machine-learning/finalfusion-utils/default.nix
+++ b/pkgs/applications/science/machine-learning/finalfusion-utils/default.nix
@@ -46,7 +46,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion finalfusion.{bash,fish,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for converting, quantizing, and querying word embeddings";
     homepage = "https://github.com/finalfusion/finalfusion-utils/";
     license = licenses.asl20;
diff --git a/pkgs/applications/science/machine-learning/labelimg/default.nix b/pkgs/applications/science/machine-learning/labelimg/default.nix
index 18c304e831653..4bfd4b9421f61 100644
--- a/pkgs/applications/science/machine-learning/labelimg/default.nix
+++ b/pkgs/applications/science/machine-learning/labelimg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, qt5 }:
+{ lib, stdenv, python3Packages, fetchFromGitHub, qt5 }:
   python3Packages.buildPythonApplication rec {
     pname = "labelImg";
     version = "1.8.3";
@@ -27,7 +27,7 @@
     preFixup = ''
       makeWrapperArgs+=("''${qtWrapperArgs[@]}")
     '';
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A graphical image annotation tool and label object bounding boxes in images";
       homepage = "https://github.com/tzutalin/labelImg";
       license = licenses.mit;
diff --git a/pkgs/applications/science/machine-learning/shogun/default.nix b/pkgs/applications/science/machine-learning/shogun/default.nix
index f448e66d94b96..7d052c6c5e9ec 100644
--- a/pkgs/applications/science/machine-learning/shogun/default.nix
+++ b/pkgs/applications/science/machine-learning/shogun/default.nix
@@ -88,7 +88,7 @@ stdenv.mkDerivation rec {
     (flag "OpenCV" opencvSupport)
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A toolbox which offers a wide range of efficient and unified machine learning methods";
     homepage = "http://shogun-toolbox.org/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/math/R/default.nix b/pkgs/applications/science/math/R/default.nix
index e4fbe8a7f2dec..2191511a9c57c 100644
--- a/pkgs/applications/science/math/R/default.nix
+++ b/pkgs/applications/science/math/R/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bzip2, gfortran, libX11, libXmu, libXt, libjpeg, libpng
+{ lib, stdenv, fetchurl, bzip2, gfortran, libX11, libXmu, libXt, libjpeg, libpng
 , libtiff, ncurses, pango, pcre2, perl, readline, tcl, texLive, tk, xz, zlib
 , less, texinfo, graphviz, icu, pkgconfig, bison, imake, which, jdk, blas, lapack
 , curl, Cocoa, Foundation, libobjc, libcxx, tzdata, fetchpatch
@@ -86,7 +86,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.r-project.org/";
     description = "Free software environment for statistical computing and graphics";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/science/math/almonds/default.nix b/pkgs/applications/science/math/almonds/default.nix
index 9edb0747b31e4..7271b6d8755c2 100644
--- a/pkgs/applications/science/math/almonds/default.nix
+++ b/pkgs/applications/science/math/almonds/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchFromGitHub, ncurses }:
+{ lib, stdenv, python3, fetchFromGitHub, ncurses }:
 
 with python3.pkgs; buildPythonApplication rec {
   pname = "almonds";
@@ -17,7 +17,7 @@ with python3.pkgs; buildPythonApplication rec {
 
   checkPhase = "py.test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal Mandelbrot fractal viewer";
     homepage = "https://github.com/Tenchi2xh/Almonds";
     license = licenses.mit;
diff --git a/pkgs/applications/science/math/bliss/default.nix b/pkgs/applications/science/math/bliss/default.nix
index 9ab90134aad41..fe68d9d245c52 100644
--- a/pkgs/applications/science/math/bliss/default.nix
+++ b/pkgs/applications/science/math/bliss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, doxygen }:
+{ lib, stdenv, fetchurl, unzip, doxygen }:
 
 stdenv.mkDerivation rec {
   pname = "bliss";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     mv *.h *.hh $out/include/bliss
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source tool for computing automorphism groups and canonical forms of graphs. It has both a command line user interface as well as C++ and C programming language APIs";
     homepage = "http://www.tcs.hut.fi/Software/bliss/";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/science/math/caffe/default.nix b/pkgs/applications/science/math/caffe/default.nix
index c99adea9a6402..565c6a17672dc 100644
--- a/pkgs/applications/science/math/caffe/default.nix
+++ b/pkgs/applications/science/math/caffe/default.nix
@@ -125,7 +125,7 @@ stdenv.mkDerivation rec {
       -weights "${test_model_weights}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Deep learning framework";
     longDescription = ''
       Caffe is a deep learning framework made with expression, speed, and
diff --git a/pkgs/applications/science/math/calculix/default.nix b/pkgs/applications/science/math/calculix/default.nix
index e37e9d0910c3a..e9766b32c2a48 100644
--- a/pkgs/applications/science/math/calculix/default.nix
+++ b/pkgs/applications/science/math/calculix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gfortran, arpack, spooles, blas, lapack }:
+{ lib, stdenv, fetchurl, gfortran, arpack, spooles, blas, lapack }:
 
 stdenv.mkDerivation rec {
   pname = "calculix";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     install -Dm0755 ccx_${version} $out/bin/ccx
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.calculix.de/";
     description = "Three-dimensional structural finite element program";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/science/math/cemu/default.nix b/pkgs/applications/science/math/cemu/default.nix
index b41135229dd79..65dd05d3d62da 100644
--- a/pkgs/applications/science/math/cemu/default.nix
+++ b/pkgs/applications/science/math/cemu/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 , mkDerivation
 , SDL2
 , libGL
@@ -42,7 +42,7 @@ mkDerivation rec {
     "gui/qt"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     changelog = "https://github.com/CE-Programming/CEmu/releases/tag/v${version}";
     description = "Third-party TI-84 Plus CE / TI-83 Premium CE emulator, focused on developer features";
     homepage = "https://ce-programming.github.io/CEmu";
diff --git a/pkgs/applications/science/math/clp/default.nix b/pkgs/applications/science/math/clp/default.nix
index 97ef3dd7543f3..26c277c2685f2 100644
--- a/pkgs/applications/science/math/clp/default.nix
+++ b/pkgs/applications/science/math/clp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib }:
+{ lib, stdenv, fetchurl, zlib }:
 
 stdenv.mkDerivation rec {
   version = "1.17.6";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.epl10;
     homepage = "https://github.com/coin-or/Clp";
     description = "An open-source linear programming solver written in C++";
diff --git a/pkgs/applications/science/math/colpack/default.nix b/pkgs/applications/science/math/colpack/default.nix
index 13a75ce4db2d0..f203852c96575 100644
--- a/pkgs/applications/science/math/colpack/default.nix
+++ b/pkgs/applications/science/math/colpack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, gettext }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, gettext }:
 
 stdenv.mkDerivation rec {
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     ./configure --prefix=$out --enable-openmp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A package comprising of implementations of algorithms for
     vertex coloring and derivative computation";
     homepage = "http://cscapes.cs.purdue.edu/coloringpage/software.htm#functionalities";
diff --git a/pkgs/applications/science/math/cplex/default.nix b/pkgs/applications/science/math/cplex/default.nix
index ec13f5252f13c..39213aff09a6e 100644
--- a/pkgs/applications/science/math/cplex/default.nix
+++ b/pkgs/applications/science/math/cplex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, openjdk, gtk2, xorg, glibcLocales, releasePath ? null }:
+{ lib, stdenv, makeWrapper, openjdk, gtk2, xorg, glibcLocales, releasePath ? null }:
 
 # To use this package, you need to download your own cplex installer from IBM
 # and override the releasePath attribute to point to the location of the file.  
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
     libSuffix = "${version}0";
   };
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimization solver for mathematical programming";
     homepage = "https://www.ibm.com/be-en/marketplace/ibm-ilog-cplex";
     license = licenses.unfree;
diff --git a/pkgs/applications/science/math/form/default.nix b/pkgs/applications/science/math/form/default.nix
index 091372792901c..00f7d7e453656 100644
--- a/pkgs/applications/science/math/form/default.nix
+++ b/pkgs/applications/science/math/form/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gmp, zlib }:
+{ lib, stdenv, fetchurl, gmp, zlib }:
 
 stdenv.mkDerivation {
   version = "4.2.1";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ gmp zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The FORM project for symbolic manipulation of very big expressions";
     homepage = "https://www.nikhef.nl/~form/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/math/geogebra/default.nix b/pkgs/applications/science/math/geogebra/default.nix
index a0548ffb232b3..a20b43c875e2b 100644
--- a/pkgs/applications/science/math/geogebra/default.nix
+++ b/pkgs/applications/science/math/geogebra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeDesktopItem, makeWrapper, unzip, language ? "en_US" }:
+{ lib, stdenv, fetchurl, jre, makeDesktopItem, makeWrapper, unzip, language ? "en_US" }:
 let
   pname = "geogebra";
   version = "5-0-609-0";
@@ -19,7 +19,7 @@ let
     mimeType = "application/vnd.geogebra.file;application/vnd.geogebra.tool;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynamic mathematics software with graphics, algebra and spreadsheets";
     longDescription = ''
       Dynamic mathematics software for all levels of education that brings
diff --git a/pkgs/applications/science/math/getdp/default.nix b/pkgs/applications/science/math/getdp/default.nix
index ae93e89f1416d..915c7e1147f1f 100644
--- a/pkgs/applications/science/math/getdp/default.nix
+++ b/pkgs/applications/science/math/getdp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, gfortran, blas, lapack, openmpi, petsc, python3 }:
+{ lib, stdenv, fetchurl, cmake, gfortran, blas, lapack, openmpi, petsc, python3 }:
 
 stdenv.mkDerivation rec {
   name = "getdp-${version}";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake gfortran ];
   buildInputs = [ blas lapack openmpi petsc python3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A General Environment for the Treatment of Discrete Problems";
     longDescription = ''
       GetDP is a free finite element solver using mixed elements to discretize
diff --git a/pkgs/applications/science/math/giac/default.nix b/pkgs/applications/science/math/giac/default.nix
index b090274919bd4..7825fc1d9a2e2 100644
--- a/pkgs/applications/science/math/giac/default.nix
+++ b/pkgs/applications/science/math/giac/default.nix
@@ -100,7 +100,7 @@ stdenv.mkDerivation rec {
     done;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free computer algebra system (CAS)";
     homepage = "https://www-fourier.ujf-grenoble.fr/~parisse/giac.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/science/math/ginac/default.nix b/pkgs/applications/science/math/ginac/default.nix
index 3c129e8033bdf..e20e15edeff1a 100644
--- a/pkgs/applications/science/math/ginac/default.nix
+++ b/pkgs/applications/science/math/ginac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cln, pkgconfig, readline, gmp, python }:
+{ lib, stdenv, fetchurl, cln, pkgconfig, readline, gmp, python }:
 
 stdenv.mkDerivation rec {
   name = "ginac-1.8.0";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--disable-rpath" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GiNaC is Not a CAS";
     homepage    = "http://www.ginac.de/";
     maintainers = with maintainers; [ lovek323 ];
diff --git a/pkgs/applications/science/math/gretl/default.nix b/pkgs/applications/science/math/gretl/default.nix
index 7d77453cbab0c..b68a02e9ebbd0 100644
--- a/pkgs/applications/science/math/gretl/default.nix
+++ b/pkgs/applications/science/math/gretl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, curl, fftw, gmp, gnuplot, gtk3, gtksourceview3, json-glib
+{ lib, stdenv, fetchurl, curl, fftw, gmp, gnuplot, gtk3, gtksourceview3, json-glib
 , lapack, libxml2, mpfr, openblas, pkg-config, readline }:
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A software package for econometric analysis";
     longDescription = ''
       gretl is a cross-platform software package for econometric analysis,
diff --git a/pkgs/applications/science/math/gurobi/default.nix b/pkgs/applications/science/math/gurobi/default.nix
index 1aa7bce07c5dc..f2f406991e304 100644
--- a/pkgs/applications/science/math/gurobi/default.nix
+++ b/pkgs/applications/science/math/gurobi/default.nix
@@ -48,7 +48,7 @@ in stdenv.mkDerivation rec {
 
   passthru.libSuffix = lib.replaceStrings ["."] [""] majorVersion;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimization solver for mathematical programming";
     homepage = "https://www.gurobi.com";
     license = licenses.unfree;
diff --git a/pkgs/applications/science/math/hmetis/default.nix b/pkgs/applications/science/math/hmetis/default.nix
index b5e99a8dd75be..f25a0f13c7fb0 100644
--- a/pkgs/applications/science/math/hmetis/default.nix
+++ b/pkgs/applications/science/math/hmetis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ghostscript }:
+{ lib, stdenv, fetchurl, ghostscript }:
 
 stdenv.mkDerivation rec {
   pname = "hmetis";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     mv libhmetis.a $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "hMETIS is a set of programs for partitioning hypergraphs";
     homepage = "http://glaros.dtc.umn.edu/gkhome/metis/hmetis/overview";
     license = licenses.unfree;
diff --git a/pkgs/applications/science/math/jags/default.nix b/pkgs/applications/science/math/jags/default.nix
index 122c62888476f..2e59866513427 100644
--- a/pkgs/applications/science/math/jags/default.nix
+++ b/pkgs/applications/science/math/jags/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, gfortran, blas, lapack}:
+{lib, stdenv, fetchurl, gfortran, blas, lapack}:
 
 stdenv.mkDerivation rec {
   name = "JAGS-4.3.0";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
   buildInputs = [gfortran blas lapack];
   configureFlags = [ "--with-blas=-lblas" "--with-lapack=-llapack" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Just Another Gibbs Sampler";
     license     = licenses.gpl2;
     homepage    = "http://mcmc-jags.sourceforge.net";
diff --git a/pkgs/applications/science/math/lp_solve/default.nix b/pkgs/applications/science/math/lp_solve/default.nix
index 673c28ffa77f1..f944499af401c 100644
--- a/pkgs/applications/science/math/lp_solve/default.nix
+++ b/pkgs/applications/science/math/lp_solve/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
 
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Mixed Integer Linear Programming (MILP) solver";
     homepage    = "http://lpsolve.sourceforge.net";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/science/math/lrcalc/default.nix b/pkgs/applications/science/math/lrcalc/default.nix
index ddd470e621a09..96eb779645169 100644
--- a/pkgs/applications/science/math/lrcalc/default.nix
+++ b/pkgs/applications/science/math/lrcalc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromBitbucket
 , fetchpatch
 , autoreconfHook
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Littlewood-Richardson calculator";
     homepage = "http://math.rutgers.edu/~asbuch/lrcalc/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/science/math/mathematica/default.nix b/pkgs/applications/science/math/mathematica/default.nix
index ea9a9c1b7554d..e91ad5e5f8c95 100644
--- a/pkgs/applications/science/math/mathematica/default.nix
+++ b/pkgs/applications/science/math/mathematica/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , coreutils
 , patchelf
 , requireFile
@@ -154,7 +154,7 @@ stdenv.mkDerivation rec {
   # we did this in prefixup already
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wolfram Mathematica computational software system";
     homepage = "http://www.wolfram.com/mathematica/";
     license = licenses.unfree;
diff --git a/pkgs/applications/science/math/mxnet/default.nix b/pkgs/applications/science/math/mxnet/default.nix
index 68df53aee3934..ab360a9638524 100644
--- a/pkgs/applications/science/math/mxnet/default.nix
+++ b/pkgs/applications/science/math/mxnet/default.nix
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     rm "$out"/lib/*.a
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight, Portable, Flexible Distributed/Mobile Deep Learning with Dynamic, Mutation-aware Dataflow Dep Scheduler";
     homepage = "https://mxnet.incubator.apache.org/";
     maintainers = with maintainers; [ abbradar ];
diff --git a/pkgs/applications/science/math/nasc/default.nix b/pkgs/applications/science/math/nasc/default.nix
index 9d14df5a79885..40406cc45889a 100644
--- a/pkgs/applications/science/math/nasc/default.nix
+++ b/pkgs/applications/science/math/nasc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , python3
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Do maths like a normal person, designed for elementary OS";
     longDescription = ''
       It’s an app where you do maths like a normal person. It lets you
diff --git a/pkgs/applications/science/math/palp/default.nix b/pkgs/applications/science/math/palp/default.nix
index 9ae4fe1ba920c..b5b9577d4930b 100644
--- a/pkgs/applications/science/math/palp/default.nix
+++ b/pkgs/applications/science/math/palp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , dimensions ? 6 # works for <= dimensions dimensions, but is only optimized for that exact value
 , doSymlink ? true # symlink the executables to the default location (without dimension postfix)
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Package for Analyzing Lattice Polytopes";
     longDescription = ''
       A Package for Analyzing Lattice Polytopes (PALP) is a set of C
diff --git a/pkgs/applications/science/math/pari/default.nix b/pkgs/applications/science/math/pari/default.nix
index 7ec42d11ab14d..dd965e17c73c6 100644
--- a/pkgs/applications/science/math/pari/default.nix
+++ b/pkgs/applications/science/math/pari/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gmp
 , readline
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "all" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Computer algebra system for high-performance number theory computations";
     longDescription = ''
        PARI/GP is a widely used computer algebra system designed for fast
diff --git a/pkgs/applications/science/math/pari/gp2c.nix b/pkgs/applications/science/math/pari/gp2c.nix
index 082ff60c3e8db..23183f83b36b6 100644
--- a/pkgs/applications/science/math/pari/gp2c.nix
+++ b/pkgs/applications/science/math/pari/gp2c.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pari
 , fetchurl
 , perl }:
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "--with-paricfg=${pari}/lib/pari/pari.cfg"
     "--with-perl=${perl}/bin/perl" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =  "A compiler to translate GP scripts to PARI programs";
     homepage = "http://pari.math.u-bordeaux.fr/";
     downloadPage = "http://pari.math.u-bordeaux.fr/download.html";
diff --git a/pkgs/applications/science/math/pynac/default.nix b/pkgs/applications/science/math/pynac/default.nix
index e3474d865e2de..d49285c3e2f04 100644
--- a/pkgs/applications/science/math/pynac/default.nix
+++ b/pkgs/applications/science/math/pynac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchurl
 , autoreconfHook
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python is Not a CAS -- modified version of Ginac";
     longDescription = ''
       Pynac -- "Python is Not a CAS" is a modified version of Ginac that
diff --git a/pkgs/applications/science/math/qalculate-gtk/default.nix b/pkgs/applications/science/math/qalculate-gtk/default.nix
index ba7ac5505e4e6..d7d880df04035 100644
--- a/pkgs/applications/science/math/qalculate-gtk/default.nix
+++ b/pkgs/applications/science/math/qalculate-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, intltool, autoreconfHook, pkgconfig, libqalculate, gtk3, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, intltool, autoreconfHook, pkgconfig, libqalculate, gtk3, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "qalculate-gtk";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libqalculate gtk3 ];
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The ultimate desktop calculator";
     homepage = "http://qalculate.github.io";
     maintainers = with maintainers; [ gebner ];
diff --git a/pkgs/applications/science/math/ries/default.nix b/pkgs/applications/science/math/ries/default.nix
index 4adf3ef2096e0..e46553d7b09ed 100644
--- a/pkgs/applications/science/math/ries/default.nix
+++ b/pkgs/applications/science/math/ries/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 stdenv.mkDerivation {
   name = "ries-2018-04-11";
 
@@ -10,7 +10,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mrob.com/pub/ries/";
     description = "Tool to produce a list of equations that approximately solve to a given number";
     platforms = platforms.all;
diff --git a/pkgs/applications/science/math/rofi-calc/default.nix b/pkgs/applications/science/math/rofi-calc/default.nix
index ebf2d2f0475d1..e7cf98c726665 100644
--- a/pkgs/applications/science/math/rofi-calc/default.nix
+++ b/pkgs/applications/science/math/rofi-calc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkgconfig
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     sed "s|qalc_binary = \"qalc\"|qalc_binary = \"${libqalculate}/bin/qalc\"|" -i src/calc.c
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Do live calculations in rofi!";
     homepage = "https://github.com/svenstaro/rofi-calc";
     license = licenses.mit;
diff --git a/pkgs/applications/science/math/sage/sage.nix b/pkgs/applications/science/math/sage/sage.nix
index e2acef7b8eb55..b9256e32f8b13 100644
--- a/pkgs/applications/science/math/sage/sage.nix
+++ b/pkgs/applications/science/math/sage/sage.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , makeWrapper
 , sage-tests
 , sage-with-env
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
     kernelspec = jupyter-kernel-definition;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open Source Mathematics Software, free alternative to Magma, Maple, Mathematica, and Matlab";
     license = licenses.gpl2;
     maintainers = teams.sage.members;
diff --git a/pkgs/applications/science/math/wxmaxima/default.nix b/pkgs/applications/science/math/wxmaxima/default.nix
index 7a81a0d679a3f..89bdc4155481a 100644
--- a/pkgs/applications/science/math/wxmaxima/default.nix
+++ b/pkgs/applications/science/math/wxmaxima/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , wrapGAppsHook, cmake, gettext
 , maxima, wxGTK, gnome3 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     gappsWrapperArgs+=(--prefix PATH ":" ${maxima}/bin)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross platform GUI for the computer algebra system Maxima";
     license = licenses.gpl2;
     homepage = "https://wxmaxima-developers.github.io/wxmaxima/";
diff --git a/pkgs/applications/science/math/zegrapher/default.nix b/pkgs/applications/science/math/zegrapher/default.nix
index c9eb72cca4331..32633eb8015d6 100644
--- a/pkgs/applications/science/math/zegrapher/default.nix
+++ b/pkgs/applications/science/math/zegrapher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , qmake
 , wrapQtAppsHook
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     boost
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zegrapher.com/";
     description = "An open source math plotter";
     longDescription = ''
diff --git a/pkgs/applications/science/misc/convertall/default.nix b/pkgs/applications/science/misc/convertall/default.nix
index 63ed18c89b2fa..9a7ac2a8b13c4 100644
--- a/pkgs/applications/science/misc/convertall/default.nix
+++ b/pkgs/applications/science/misc/convertall/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, wrapQtAppsHook }:
+{ lib, stdenv, fetchFromGitHub, python3, wrapQtAppsHook }:
 
 let
   inherit (python3.pkgs) wrapPython pyqt5;
@@ -27,7 +27,7 @@ in stdenv.mkDerivation rec {
     makeQtWrapper $out/share/convertall/convertall.py $out/bin/convertall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://convertall.bellz.org/";
     description = "Graphical unit converter";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/science/misc/gephi/default.nix b/pkgs/applications/science/misc/gephi/default.nix
index b6b53013cb4be..95112fa9098e6 100644
--- a/pkgs/applications/science/misc/gephi/default.nix
+++ b/pkgs/applications/science/misc/gephi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jdk, maven, javaPackages }:
+{ lib, stdenv, fetchFromGitHub, jdk, maven, javaPackages }:
 
 let
   version = "0.9.2";
@@ -55,7 +55,7 @@ stdenv.mkDerivation {
     echo "jdkhome=${jdk}" >> $out/etc/gephi.conf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A platform for visualizing and manipulating large graphs";
     homepage = "https://gephi.org";
     license = licenses.gpl3;
diff --git a/pkgs/applications/science/misc/gplates/default.nix b/pkgs/applications/science/misc/gplates/default.nix
index ade58b28ab64b..d0315d1596742 100644
--- a/pkgs/applications/science/misc/gplates/default.nix
+++ b/pkgs/applications/science/misc/gplates/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qt4, qwt6_qt4, libGLU, libGL, glew, gdal, cgal
+{ lib, stdenv, fetchurl, qt4, qwt6_qt4, libGLU, libGL, glew, gdal, cgal
 , proj, boost, cmake, python2, doxygen, graphviz, gmp, mpfr }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_LINK="-ldl -lpthread -lutil";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop software for the interactive visualisation of plate-tectonics";
     homepage = "https://www.gplates.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/science/misc/netlogo/default.nix b/pkgs/applications/science/misc/netlogo/default.nix
index af892441a4723..b22c6294fba6f 100644
--- a/pkgs/applications/science/misc/netlogo/default.nix
+++ b/pkgs/applications/science/misc/netlogo/default.nix
@@ -1,4 +1,4 @@
-{ jre, stdenv, fetchurl, makeWrapper, makeDesktopItem }:
+{ jre, lib, stdenv, fetchurl, makeWrapper, makeDesktopItem }:
 
 let
 
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     cp ${desktopItem}/share/applications/* $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multi-agent programmable modeling environment";
     longDescription = ''
       NetLogo is a multi-agent programmable modeling environment. It is used by
diff --git a/pkgs/applications/science/misc/openmodelica/default.nix b/pkgs/applications/science/misc/openmodelica/default.nix
index 589b137002305..8b027b52687eb 100644
--- a/pkgs/applications/science/misc/openmodelica/default.nix
+++ b/pkgs/applications/science/misc/openmodelica/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchgit, fetchsvn, autoconf, automake, libtool, gfortran, clang, cmake, gnumake,
+{lib, stdenv, fetchgit, fetchsvn, autoconf, automake, libtool, gfortran, clang, cmake, gnumake,
 hwloc, jre, lapack, blas, hdf5, expat, ncurses, readline, qt4, webkitgtk, which,
 lp_solve, omniorb, sqlite, libatomic_ops, pkgconfig, file, gettext, flex, bison,
 doxygen, boost, openscenegraph, gnome2, xorg, git, bash, gtk2, makeWrapper }:
@@ -42,7 +42,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open-source Modelica-based modeling and simulation environment";
     homepage    = "https://openmodelica.org";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/science/misc/openmvs/default.nix b/pkgs/applications/science/misc/openmvs/default.nix
index f8533677b7ae4..ec22aaa599b27 100644
--- a/pkgs/applications/science/misc/openmvs/default.nix
+++ b/pkgs/applications/science/misc/openmvs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, cmake
+{ lib, stdenv, fetchFromGitHub, pkgconfig, cmake
 , eigen, opencv, ceres-solver, cgal, boost, vcg
 , gmp, mpfr, glog, gflags, libjpeg_turbo }:
 
@@ -50,7 +50,7 @@ stdenv.mkDerivation {
 
   dontUseCmakeBuildDir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for computer-vision scientists and especially targeted to the Multi-View Stereo reconstruction community";
     homepage = "http://cdcseacave.github.io/openMVS/";
     license = licenses.agpl3;
diff --git a/pkgs/applications/science/misc/rink/default.nix b/pkgs/applications/science/misc/rink/default.nix
index 0b1ef2b16ea9e..5670969e7a2d6 100644
--- a/pkgs/applications/science/misc/rink/default.nix
+++ b/pkgs/applications/science/misc/rink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, openssl, pkg-config, ncurses }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, openssl, pkg-config, ncurses }:
 
 rustPlatform.buildRustPackage rec {
   version = "0.5.1";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
   # Some tests fail and/or attempt to use internet servers.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unit-aware calculator";
     homepage = "https://rinkcalc.app";
     license = with licenses; [ mpl20 gpl3 ];
diff --git a/pkgs/applications/science/misc/root/5.nix b/pkgs/applications/science/misc/root/5.nix
index c42f80da352a8..d8e6ae06a24b1 100644
--- a/pkgs/applications/science/misc/root/5.nix
+++ b/pkgs/applications/science/misc/root/5.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, cmake, pcre, pkg-config, python2
+{ lib, stdenv, fetchurl, fetchpatch, cmake, pcre, pkg-config, python2
 , libX11, libXpm, libXft, libXext, libGLU, libGL, zlib, libxml2, lz4, lzma, gsl_1, xxHash
 , Cocoa, OpenGL, noSplash ? false }:
 
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://root.cern.ch/";
     description = "A data analysis framework";
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/misc/root/default.nix b/pkgs/applications/science/misc/root/default.nix
index 2e9fcdb35a214..8bfde114beb4f 100644
--- a/pkgs/applications/science/misc/root/default.nix
+++ b/pkgs/applications/science/misc/root/default.nix
@@ -89,7 +89,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://root.cern.ch/";
     description = "A data analysis framework";
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/misc/snakemake/default.nix b/pkgs/applications/science/misc/snakemake/default.nix
index a03f7682a51c4..6b3c405a9ac2e 100644
--- a/pkgs/applications/science/misc/snakemake/default.nix
+++ b/pkgs/applications/science/misc/snakemake/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "snakemake";
@@ -28,7 +28,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false; # Tests depend on Google Cloud credentials at ${HOME}/gcloud-service-key.json
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://snakemake.readthedocs.io";
     license = licenses.mit;
     description = "Python-based execution environment for make-like workflows";
diff --git a/pkgs/applications/science/molecular-dynamics/dl-poly-classic/default.nix b/pkgs/applications/science/molecular-dynamics/dl-poly-classic/default.nix
index 51978e95766d7..16d858b00bed8 100644
--- a/pkgs/applications/science/molecular-dynamics/dl-poly-classic/default.nix
+++ b/pkgs/applications/science/molecular-dynamics/dl-poly-classic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , gfortran, mpi
 }:
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     cp -v ../execute/DLPOLY.X $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.ccp5.ac.uk/DL_POLY_C";
     description = "DL_POLY Classic is a general purpose molecular dynamics simulation package";
     license = licenses.bsdOriginal;
diff --git a/pkgs/applications/science/molecular-dynamics/gromacs/default.nix b/pkgs/applications/science/molecular-dynamics/gromacs/default.nix
index 84dd3b729b2bb..6a243c1d91745 100644
--- a/pkgs/applications/science/molecular-dynamics/gromacs/default.nix
+++ b/pkgs/applications/science/molecular-dynamics/gromacs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cmake
 , hwloc
@@ -54,7 +54,7 @@ in stdenv.mkDerivation rec {
     ]
   );
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.gromacs.org";
     license = licenses.gpl2;
     description = "Molecular dynamics software package";
diff --git a/pkgs/applications/science/molecular-dynamics/lammps/default.nix b/pkgs/applications/science/molecular-dynamics/lammps/default.nix
index 5dc31695c60d7..561bb119f12ee 100644
--- a/pkgs/applications/science/molecular-dynamics/lammps/default.nix
+++ b/pkgs/applications/science/molecular-dynamics/lammps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , libpng, gzip, fftw, blas, lapack
 , mpi ? null
 }:
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
     cp -v liblammps* $out/lib/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Classical Molecular Dynamics simulation code";
     longDescription = ''
       LAMMPS is a classical molecular dynamics simulation code designed to
diff --git a/pkgs/applications/science/molecular-dynamics/viennarna/default.nix b/pkgs/applications/science/molecular-dynamics/viennarna/default.nix
index a68feaea1ef52..b3af602f578f1 100644
--- a/pkgs/applications/science/molecular-dynamics/viennarna/default.nix
+++ b/pkgs/applications/science/molecular-dynamics/viennarna/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gsl
 , mpfr
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     "--with-kinwalker"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prediction and comparison of RNA secondary structures";
     homepage = "https://www.tbi.univie.ac.at/RNA/";
     license = licenses.unfree;
diff --git a/pkgs/applications/science/physics/elmerfem/default.nix b/pkgs/applications/science/physics/elmerfem/default.nix
index 7e10ecaba36fe..6fa25ce66aeb7 100644
--- a/pkgs/applications/science/physics/elmerfem/default.nix
+++ b/pkgs/applications/science/physics/elmerfem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, git, gfortran, openmpi, blas, liblapack, qt4, qwt6_qt4, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, cmake, git, gfortran, openmpi, blas, liblapack, qt4, qwt6_qt4, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "elmerfem";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     ./fix-cmake.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://elmerfem.org/";
     description = "A finite element software for multiphysical problems";
     platforms = platforms.unix;
diff --git a/pkgs/applications/science/physics/quantomatic/default.nix b/pkgs/applications/science/physics/quantomatic/default.nix
index a9c83310b2ff4..c1400869a2589 100644
--- a/pkgs/applications/science/physics/quantomatic/default.nix
+++ b/pkgs/applications/science/physics/quantomatic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "quantomatic";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/quantomatic --add-flags "-jar $out/libexec/quantomatic/quantomatic.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A piece of software for reasoning about monoidal theories; in particular, quantum information processing";
     license = licenses.gpl3;
     homepage = "https://quantomatic.github.io/";
diff --git a/pkgs/applications/science/physics/sherpa/default.nix b/pkgs/applications/science/physics/sherpa/default.nix
index 93e402ec3ceb6..9a3af78240ee5 100644
--- a/pkgs/applications/science/physics/sherpa/default.nix
+++ b/pkgs/applications/science/physics/sherpa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gfortran, hepmc2, fastjet, lhapdf, rivet, sqlite }:
+{ lib, stdenv, fetchurl, gfortran, hepmc2, fastjet, lhapdf, rivet, sqlite }:
 
 stdenv.mkDerivation rec {
   pname = "sherpa";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     "--enable-rivet=${rivet}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simulation of High-Energy Reactions of PArticles in lepton-lepton, lepton-photon, photon-photon, lepton-hadron and hadron-hadron collisions";
     license = licenses.gpl2;
     homepage = "https://gitlab.com/sherpa-team/sherpa";
diff --git a/pkgs/applications/science/physics/xfitter/default.nix b/pkgs/applications/science/physics/xfitter/default.nix
index cbb097350c713..0713825ccef04 100644
--- a/pkgs/applications/science/physics/xfitter/default.nix
+++ b/pkgs/applications/science/physics/xfitter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, apfel, apfelgrid, applgrid, blas, gfortran, lhapdf, lapack, libyaml, lynx
+{ lib, stdenv, fetchurl, apfel, apfelgrid, applgrid, blas, gfortran, lhapdf, lapack, libyaml, lynx
 , mela, root5, qcdnum, which, libtirpc
 }:
 
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE = [ "-I${libtirpc.dev}/include/tirpc" ];
   NIX_LDFLAGS = [ "-ltirpc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The xFitter project is an open source QCD fit framework ready to extract PDFs and assess the impact of new data";
     license     = licenses.gpl3;
     homepage    = "https://www.xfitter.org/xFitter";
diff --git a/pkgs/applications/science/programming/fdr/default.nix b/pkgs/applications/science/programming/fdr/default.nix
index 4eeca5c1759bc..3ac8267d8aeaf 100644
--- a/pkgs/applications/science/programming/fdr/default.nix
+++ b/pkgs/applications/science/programming/fdr/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, qtbase, qtx11extras, ncurses5, xorg, zlib, python27Packages}:
+{lib, stdenv, fetchurl, qtbase, qtx11extras, ncurses5, xorg, zlib, python27Packages}:
 stdenv.mkDerivation {
   name = "fdr-4.2.3";
   src = fetchurl {
@@ -58,7 +58,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.cs.ox.ac.uk/projects/fdr/";
     description = "The CSP refinement checker";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/applications/science/programming/groove/default.nix b/pkgs/applications/science/programming/groove/default.nix
index 87b7b02317a27..958c452b9fceb 100644
--- a/pkgs/applications/science/programming/groove/default.nix
+++ b/pkgs/applications/science/programming/groove/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, makeWrapper, makeDesktopItem, icoutils, jre }:
+{ lib, stdenv, fetchurl, unzip, makeWrapper, makeDesktopItem, icoutils, jre }:
 
 let
   desktopItem = makeDesktopItem {
@@ -44,7 +44,7 @@ in stdenv.mkDerivation rec {
     icotool -x -i 2 -o $out/share/icons/hicolor/16x16/apps/groove.png groove-green-g.ico
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GRaphs for Object-Oriented VErification";
     homepage = "http://groove.cs.utwente.nl/";
     license = licenses.asl20;
diff --git a/pkgs/applications/science/programming/plm/default.nix b/pkgs/applications/science/programming/plm/default.nix
index ebfb6471c6323..852502e73b0f5 100644
--- a/pkgs/applications/science/programming/plm/default.nix
+++ b/pkgs/applications/science/programming/plm/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, makeWrapper, jre, gcc, valgrind}:
+{lib, stdenv, fetchurl, makeWrapper, jre, gcc, valgrind}:
 # gcc and valgrind are not strict dependencies, they could be made
 # optional. They are here because plm can only help you learn C if you
 # have them installed.
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "$PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free cross-platform programming exerciser";
     license = licenses.gpl3;
     maintainers = [ ];
diff --git a/pkgs/applications/science/robotics/betaflight-configurator/default.nix b/pkgs/applications/science/robotics/betaflight-configurator/default.nix
index 66b9a1ef63a17..0b39c60b28331 100644
--- a/pkgs/applications/science/robotics/betaflight-configurator/default.nix
+++ b/pkgs/applications/science/robotics/betaflight-configurator/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip, makeDesktopItem, nwjs, wrapGAppsHook, gsettings-desktop-schemas, gtk3 }:
+{lib, stdenv, fetchurl, unzip, makeDesktopItem, nwjs, wrapGAppsHook, gsettings-desktop-schemas, gtk3 }:
 
 let
   pname = "betaflight-configurator";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${nwjs}/bin/nw $out/bin/${pname} --add-flags $out/opt/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Betaflight flight control system configuration tool";
     longDescription = ''
       A crossplatform configuration tool for the Betaflight flight control system.
diff --git a/pkgs/applications/science/robotics/mission-planner/default.nix b/pkgs/applications/science/robotics/mission-planner/default.nix
index 5ae04d8a84b73..a299a66704d1e 100644
--- a/pkgs/applications/science/robotics/mission-planner/default.nix
+++ b/pkgs/applications/science/robotics/mission-planner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, makeWrapper, unzip, mono6 }:
+{ lib, stdenv, fetchurl, makeDesktopItem, makeWrapper, unzip, mono6 }:
 
 let
   pname = "mission-planner";
@@ -44,7 +44,7 @@ in stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ArduPilot ground station";
     longDescription = ''
       Full-featured ground station application for the ArduPilot open source
diff --git a/pkgs/applications/science/robotics/sumorobot-manager/default.nix b/pkgs/applications/science/robotics/sumorobot-manager/default.nix
index 68b91dafb736a..bd056a2ec21c2 100644
--- a/pkgs/applications/science/robotics/sumorobot-manager/default.nix
+++ b/pkgs/applications/science/robotics/sumorobot-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, qt5, fetchFromGitHub, wrapPython, pyqt5, pyserial }:
+{ lib, stdenv, python3, qt5, fetchFromGitHub, wrapPython, pyqt5, pyserial }:
  
 stdenv.mkDerivation rec {
   pname = "sumorobot-manager";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     wrapPythonProgramsIn "$out/opt" "$pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop App for managing SumoRobots";
     homepage = "https://www.robokoding.com/kits/sumorobot/sumomanager/";
     license = licenses.mit;
diff --git a/pkgs/applications/search/grepcidr/default.nix b/pkgs/applications/search/grepcidr/default.nix
index 125e67938ecde..bdc660db45fc5 100644
--- a/pkgs/applications/search/grepcidr/default.nix
+++ b/pkgs/applications/search/grepcidr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "grepcidr";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Filter IPv4 and IPv6 addresses matching CIDR patterns";
     homepage = "http://www.pc-tools.net/unix/grepcidr/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/search/grepm/default.nix b/pkgs/applications/search/grepm/default.nix
index d03d26d00004d..7fef36d910eec 100644
--- a/pkgs/applications/search/grepm/default.nix
+++ b/pkgs/applications/search/grepm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, mutt }:
+{ lib, stdenv, fetchurl, perlPackages, mutt }:
 
 stdenv.mkDerivation {
   pname = "grepm";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
       $out/bin/grepm
   '';
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wrapper for grepmail utilizing mutt";
     homepage = "http://www.barsnick.net/sw/grepm.html";
     license = licenses.free;
diff --git a/pkgs/applications/search/recoll/default.nix b/pkgs/applications/search/recoll/default.nix
index 4939fcf566271..6d6f58fb5e208 100644
--- a/pkgs/applications/search/recoll/default.nix
+++ b/pkgs/applications/search/recoll/default.nix
@@ -91,7 +91,7 @@ mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full-text search tool";
     longDescription = ''
       Recoll is an Xapian frontend that can search through files, archive
diff --git a/pkgs/applications/system/monitor/default.nix b/pkgs/applications/system/monitor/default.nix
index 30ae9e51e9eb6..11bdeeb3bf624 100644
--- a/pkgs/applications/system/monitor/default.nix
+++ b/pkgs/applications/system/monitor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manage processes and monitor system resources";
     longDescription = ''
       Manage processes and monitor system resources.
diff --git a/pkgs/applications/terminal-emulators/eterm/default.nix b/pkgs/applications/terminal-emulators/eterm/default.nix
index b51acd9fa7284..b72b31babe0b3 100644
--- a/pkgs/applications/terminal-emulators/eterm/default.nix
+++ b/pkgs/applications/terminal-emulators/eterm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , libX11, libXext, libXaw
 , pkgconfig, imlib2, libast }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libX11 libXext libXaw imlib2 ];
   propagatedBuildInputs = [ libast ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal emulator";
     homepage = "http://www.eterm.org";
     license = licenses.bsd2;
diff --git a/pkgs/applications/terminal-emulators/evilvte/default.nix b/pkgs/applications/terminal-emulators/evilvte/default.nix
index 7a5284a527a67..40e723f168255 100644
--- a/pkgs/applications/terminal-emulators/evilvte/default.nix
+++ b/pkgs/applications/terminal-emulators/evilvte/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, makeWrapper, pkgconfig,
+{ lib, stdenv, fetchgit, makeWrapper, pkgconfig,
   gnome2, glib, pango, cairo, gdk-pixbuf, atk, freetype, xorg,
   configH ? ""
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     make
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VTE based, highly customizable terminal emulator";
     homepage = "http://www.calno.com/evilvte";
     license = licenses.gpl2;
diff --git a/pkgs/applications/terminal-emulators/germinal/default.nix b/pkgs/applications/terminal-emulators/germinal/default.nix
index b44e48fafae90..12d82290b1a6d 100644
--- a/pkgs/applications/terminal-emulators/germinal/default.nix
+++ b/pkgs/applications/terminal-emulators/germinal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkg-config
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     runHook postFixup
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal terminal emulator";
     homepage = "https://github.com/Keruspe/Germinal";
     license = with licenses; gpl3Plus;
diff --git a/pkgs/applications/terminal-emulators/guake/default.nix b/pkgs/applications/terminal-emulators/guake/default.nix
index 481c7255441f8..bdb3e65ed98aa 100644
--- a/pkgs/applications/terminal-emulators/guake/default.nix
+++ b/pkgs/applications/terminal-emulators/guake/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3
 , glibcLocales
@@ -66,7 +66,7 @@ python3.pkgs.buildPythonApplication rec {
     gappsWrapperArgs+=(--prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [ libutempter ]}")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Drop-down terminal for GNOME";
     homepage = "http://guake-project.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/terminal-emulators/havoc/default.nix b/pkgs/applications/terminal-emulators/havoc/default.nix
index a6d5278fc3c5a..61fd5831dc98a 100644
--- a/pkgs/applications/terminal-emulators/havoc/default.nix
+++ b/pkgs/applications/terminal-emulators/havoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgconfig, libxkbcommon, wayland, wayland-protocols }:
 
 stdenv.mkDerivation rec {
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     install -D -m 644 README.md -t $out/share/doc/${pname}-${version}/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal terminal emulator for Wayland";
     homepage = "https://github.com/ii8/havoc";
     license = with licenses; [ mit publicDomain ];
diff --git a/pkgs/applications/terminal-emulators/iterm2/default.nix b/pkgs/applications/terminal-emulators/iterm2/default.nix
index e273eda45c315..ff5c7f8dae468 100644
--- a/pkgs/applications/terminal-emulators/iterm2/default.nix
+++ b/pkgs/applications/terminal-emulators/iterm2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
  /*
  This derivation is impure: it relies on an Xcode toolchain being installed
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
      (deny file-read* file-write* process-exec mach-lookup (subpath "/usr/local") (with no-log))
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A replacement for Terminal and the successor to iTerm";
     homepage = "https://www.iterm2.com/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/terminal-emulators/kitty/default.nix b/pkgs/applications/terminal-emulators/kitty/default.nix
index 2fa03a97e8bc9..b7541f2528d65 100644
--- a/pkgs/applications/terminal-emulators/kitty/default.nix
+++ b/pkgs/applications/terminal-emulators/kitty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll, fetchFromGitHub, python3Packages, libunistring,
+{ lib, stdenv, substituteAll, fetchFromGitHub, python3Packages, libunistring,
   harfbuzz, fontconfig, pkgconfig, ncurses, imagemagick, xsel,
   libstartup_notification, libGL, libX11, libXrandr, libXinerama, libXcursor,
   libxkbcommon, libXi, libXext, wayland-protocols, wayland,
@@ -132,7 +132,7 @@ buildPythonApplication rec {
     echo "$terminfo" >> $out/nix-support/propagated-user-env-packages
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kovidgoyal/kitty";
     description = "A modern, hackable, featureful, OpenGL based terminal emulator";
     license = licenses.gpl3;
diff --git a/pkgs/applications/terminal-emulators/lilyterm/default.nix b/pkgs/applications/terminal-emulators/lilyterm/default.nix
index 28f9625b5b667..96029259f15f2 100644
--- a/pkgs/applications/terminal-emulators/lilyterm/default.nix
+++ b/pkgs/applications/terminal-emulators/lilyterm/default.nix
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     "--enable-safe-mode"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast, lightweight terminal emulator";
     longDescription = ''
       LilyTerm is a terminal emulator based off of libvte that aims to be fast and lightweight.
diff --git a/pkgs/applications/terminal-emulators/mrxvt/default.nix b/pkgs/applications/terminal-emulators/mrxvt/default.nix
index 4dc70133ec479..e273e96cbedf6 100644
--- a/pkgs/applications/terminal-emulators/mrxvt/default.nix
+++ b/pkgs/applications/terminal-emulators/mrxvt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXft, libXi, xorgproto, libSM, libICE
+{ lib, stdenv, fetchurl, libX11, libXft, libXi, xorgproto, libSM, libICE
 , freetype, pkgconfig, which }:
 
 stdenv.mkDerivation {
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     sha256 = "1mqhmnlz32lvld9rc6c1hyz7gjw4anwf39yhbsjkikcgj1das0zl";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight multitabbed feature-rich X11 terminal emulator";
     longDescription = "
     	Multitabbed lightweight terminal emulator based on rxvt.
diff --git a/pkgs/applications/terminal-emulators/nimmm/default.nix b/pkgs/applications/terminal-emulators/nimmm/default.nix
index 383057ca65518..648a3906fb502 100644
--- a/pkgs/applications/terminal-emulators/nimmm/default.nix
+++ b/pkgs/applications/terminal-emulators/nimmm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nim, termbox, pcre }:
+{ lib, stdenv, fetchFromGitHub, nim, termbox, pcre }:
 
 let
   noise = fetchFromGitHub {
@@ -45,7 +45,7 @@ in stdenv.mkDerivation rec {
     install -Dt $out/bin src/nimmm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal file manager written in nim";
     homepage = "https://github.com/joachimschmidt557/nimmm";
     license = licenses.gpl3;
diff --git a/pkgs/applications/terminal-emulators/roxterm/default.nix b/pkgs/applications/terminal-emulators/roxterm/default.nix
index 88ff0dc460ecb..93c3ab099c96f 100644
--- a/pkgs/applications/terminal-emulators/roxterm/default.nix
+++ b/pkgs/applications/terminal-emulators/roxterm/default.nix
@@ -1,7 +1,7 @@
 { at-spi2-core, cmake, dbus, dbus-glib, docbook_xsl, epoxy, fetchpatch, fetchFromGitHub
 , glib, gtk3, harfbuzz, libXdmcp, libXtst, libpthreadstubs
 , libselinux, libsepol, libtasn1, libxkbcommon, libxslt, p11-kit, pcre2
-, pkgconfig, stdenv, util-linuxMinimal, vte, wrapGAppsHook, xmlto
+, pkgconfig, lib, stdenv, util-linuxMinimal, vte, wrapGAppsHook, xmlto
 }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
       libsepol libxkbcommon epoxy at-spi2-core libXtst libtasn1 p11-kit
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/realh/roxterm";
     license = licenses.gpl3;
     description = "Tabbed, VTE-based terminal emulator";
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-autocomplete-all-the-things/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-autocomplete-all-the-things/default.nix
index a4e03fa347f0e..6217bc0659a22 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-autocomplete-all-the-things/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-autocomplete-all-the-things/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "urxvt-autocomplete-all-the-things";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp autocomplete-ALL-the-things $out/lib/urxvt/perl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "urxvt plugin allowing user to easily complete arbitrary text";
     homepage = "https://github.com/Vifon/autocomplete-ALL-the-things";
     license = licenses.gpl3;
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-font-size/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-font-size/default.nix
index f81709b973900..beecb3e278d5a 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-font-size/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-font-size/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xrdb, xlsfonts }:
+{ lib, stdenv, fetchFromGitHub, xrdb, xlsfonts }:
 
 stdenv.mkDerivation {
   name = "urxvt-font-size-2015-05-22";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     cp font-size $out/lib/urxvt/perl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Change the urxvt font size on the fly";
     homepage = "https://github.com/majutsushi/urxvt-font-size";
     license = licenses.mit;
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perl/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perl/default.nix
index 0c95acd72057f..b9c72c97d6de5 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perl/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, wmctrl }:
+{ lib, stdenv, fetchFromGitHub, wmctrl }:
 
 stdenv.mkDerivation {
   name = "urxvt-perl-2015-01-16";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp newterm $out/lib/urxvt/perl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Perl extensions for the rxvt-unicode terminal emulator";
     homepage = "https://github.com/effigies/urxvt-perl";
     license = licenses.gpl3;
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perls/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perls/default.nix
index 53bb938c3330d..33bf75c841bf3 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perls/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-perls/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "urxvt-perls";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     $out/lib/urxvt/perl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Perl extensions for the rxvt-unicode terminal emulator";
     homepage = "https://github.com/muennich/urxvt-perls";
     license = licenses.gpl2;
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-resize-font/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-resize-font/default.nix
index a056e603f0044..95b369b70f99c 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-resize-font/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-resize-font/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "urxvt-resize-font";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     cp resize-font $out/lib/urxvt/perl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "URxvt Perl extension for resizing the font";
     homepage = "https://github.com/simmel/urxvt-resize-font";
     license = licenses.mit;
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-tabbedex/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-tabbedex/default.nix
index 71a55f9293c66..4fc32f55e070c 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-tabbedex/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-tabbedex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl }:
+{ lib, stdenv, fetchFromGitHub, perl }:
 
 stdenv.mkDerivation rec {
   pname = "urxvt-tabbedex";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tabbed plugin for rxvt-unicode with many enhancements (mina86's fork)";
     homepage = "https://github.com/mina86/urxvt-tabbedex";
     maintainers = with maintainers; [ abbradar ];
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-theme-switch/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-theme-switch/default.nix
index 5a84a9b472a5b..303555db7224f 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-theme-switch/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-theme-switch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   rev = "cfcbcc3dd5a5b09a3fec0f6a1fea95f4a36a48c4";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp color-themes $out/lib/urxvt/perl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "urxvt plugin that allows to switch color themes during runtime";
     homepage = "https://github.com/felixr/urxvt-theme-switch";
     license = "CCBYNC";
diff --git a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-vtwheel/default.nix b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-vtwheel/default.nix
index eb520f38bedbe..446126aad7485 100644
--- a/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-vtwheel/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt-unicode-plugins/urxvt-vtwheel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, perl }:
+{ lib, stdenv, fetchgit, perl }:
 
 stdenv.mkDerivation {
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     cp vtwheel $out/lib/urxvt/perl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pass mouse wheel commands to secondary screens (screen, less, nano, etc)";
     homepage = "https://aur.archlinux.org/packages/urxvt-vtwheel";
     license = licenses.mit;
diff --git a/pkgs/applications/terminal-emulators/rxvt/default.nix b/pkgs/applications/terminal-emulators/rxvt/default.nix
index c71973da13beb..2c89940f76063 100644
--- a/pkgs/applications/terminal-emulators/rxvt/default.nix
+++ b/pkgs/applications/terminal-emulators/rxvt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , pkgconfig, libtool
 , libX11, libXt, libXpm }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     LIBTOOL=${libtool}/bin/libtool ./configure --prefix=$out --enable-everything --enable-smart-resize --enable-256-color
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://rxvt.sourceforge.net/";
     description = "Colour vt102 terminal emulator with less features and lower memory consumption";
     longDescription = ''
diff --git a/pkgs/applications/terminal-emulators/sakura/default.nix b/pkgs/applications/terminal-emulators/sakura/default.nix
index 7cccec3b72fcb..6aa1c4b44df43 100644
--- a/pkgs/applications/terminal-emulators/sakura/default.nix
+++ b/pkgs/applications/terminal-emulators/sakura/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cmake
 , pkgconfig
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
       --suffix XDG_DATA_DIRS : ${gtk3}/share/gsettings-schemas/${gtk3.name}/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.pleyades.net/david/projects/sakura";
     description = "A terminal emulator based on GTK and VTE";
     longDescription = ''
diff --git a/pkgs/applications/terminal-emulators/stupidterm/default.nix b/pkgs/applications/terminal-emulators/stupidterm/default.nix
index 2016059d81e78..0d8c39a45f544 100644
--- a/pkgs/applications/terminal-emulators/stupidterm/default.nix
+++ b/pkgs/applications/terminal-emulators/stupidterm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, vte, gtk, pcre2 }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, vte, gtk, pcre2 }:
 
 stdenv.mkDerivation {
   pname = "stupidterm";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
       --replace "Exec=st" "Exec=$out/bin/stupidterm"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple wrapper around the VTE terminal emulator widget for GTK";
     homepage = "https://github.com/esmil/stupidterm";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/applications/terminal-emulators/terminator/default.nix b/pkgs/applications/terminal-emulators/terminator/default.nix
index 5de8109e3a4d2..80698c56cde7f 100644
--- a/pkgs/applications/terminal-emulators/terminator/default.nix
+++ b/pkgs/applications/terminal-emulators/terminator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3
 , keybinder3
@@ -61,7 +61,7 @@ python3.pkgs.buildPythonApplication rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal emulator with support for tiling and tabs";
     longDescription = ''
       The goal of this project is to produce a useful tool for arranging
diff --git a/pkgs/applications/terminal-emulators/termite/default.nix b/pkgs/applications/terminal-emulators/termite/default.nix
index 2f991ca1c7e68..20d1ad675a871 100644
--- a/pkgs/applications/terminal-emulators/termite/default.nix
+++ b/pkgs/applications/terminal-emulators/termite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig, vte, gtk3, ncurses, pcre2, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, pkgconfig, vte, gtk3, ncurses, pcre2, wrapGAppsHook }:
 
 let
 
@@ -67,7 +67,7 @@ in stdenv.mkDerivation rec {
     echo "$terminfo" >> $out/nix-support/propagated-user-env-packages
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple VTE-based terminal";
     license = licenses.lgpl2Plus;
     homepage = "https://github.com/thestinger/termite/";
diff --git a/pkgs/applications/terminal-emulators/tilda/default.nix b/pkgs/applications/terminal-emulators/tilda/default.nix
index 560a47a9cdb82..1ea50cfff7a13 100644
--- a/pkgs/applications/terminal-emulators/tilda/default.nix
+++ b/pkgs/applications/terminal-emulators/tilda/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkg-config
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
         --prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Gtk based drop down terminal for Linux and Unix";
     homepage = "https://github.com/lanoxx/tilda/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/terminal-emulators/tilix/default.nix b/pkgs/applications/terminal-emulators/tilix/default.nix
index 4707685e3dab3..ee9eac8e26754 100644
--- a/pkgs/applications/terminal-emulators/tilix/default.nix
+++ b/pkgs/applications/terminal-emulators/tilix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , meson
@@ -64,7 +64,7 @@ stdenv.mkDerivation {
       --replace "Exec=tilix" "Exec=$out/bin/tilix"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiling terminal emulator following the Gnome Human Interface Guidelines";
     homepage = "https://gnunn1.github.io/tilix-web";
     license = licenses.mpl20;
diff --git a/pkgs/applications/terminal-emulators/x3270/default.nix b/pkgs/applications/terminal-emulators/x3270/default.nix
index 747d26538764c..7bc4941caf195 100644
--- a/pkgs/applications/terminal-emulators/x3270/default.nix
+++ b/pkgs/applications/terminal-emulators/x3270/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, m4, expat
+{ lib, stdenv, fetchurl, openssl, m4, expat
 , libX11, libXt, libXaw, libXmu, bdftopcf, mkfontdir
 , fontadobe100dpi, fontadobeutopia100dpi, fontbh100dpi
 , fontbhlucidatypewriter100dpi, fontbitstream100dpi
@@ -35,7 +35,7 @@ in stdenv.mkDerivation rec {
     expat
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IBM 3270 terminal emulator for the X Window System";
     homepage = "http://x3270.bgp.nu/index.html";
     license = licenses.bsd3;
diff --git a/pkgs/applications/version-management/bcompare/default.nix b/pkgs/applications/version-management/bcompare/default.nix
index 5da3aee5d7b68..61ea5a9ddd4d6 100644
--- a/pkgs/applications/version-management/bcompare/default.nix
+++ b/pkgs/applications/version-management/bcompare/default.nix
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
   dontBuild = true;
   dontConfigure = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI application that allows to quickly and easily compare files and folders";
     longDescription = ''
       Beyond Compare is focused. Beyond Compare allows you to quickly and easily compare your files and folders.
diff --git a/pkgs/applications/version-management/blackbox/default.nix b/pkgs/applications/version-management/blackbox/default.nix
index 8c28a6789624c..aee0e92e8064d 100644
--- a/pkgs/applications/version-management/blackbox/default.nix
+++ b/pkgs/applications/version-management/blackbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   version = "1.20181219";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin && cp -r bin/* $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Safely store secrets in a VCS repo";
     maintainers = with maintainers; [ ericsagnes ];
     license     = licenses.mit;
diff --git a/pkgs/applications/version-management/cvs/default.nix b/pkgs/applications/version-management/cvs/default.nix
index 07a6b7c993c87..273433298fa1c 100644
--- a/pkgs/applications/version-management/cvs/default.nix
+++ b/pkgs/applications/version-management/cvs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, nano }:
+{ lib, stdenv, fetchurl, fetchpatch, nano }:
 
 stdenv.mkDerivation {
   name = "cvs-1.12.13";
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
 
   doCheck = false; # fails 1 of 1 tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cvs.nongnu.org";
     description = "Concurrent Versions System - a source control system";
     license = licenses.gpl2; # library is GPLv2, main is GPLv1
diff --git a/pkgs/applications/version-management/fossil/default.nix b/pkgs/applications/version-management/fossil/default.nix
index 6d39ae0931cdb..d68535e0a4c23 100644
--- a/pkgs/applications/version-management/fossil/default.nix
+++ b/pkgs/applications/version-management/fossil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , installShellFiles
 , tcl
 , libiconv
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     installShellCompletion --name fossil.bash tools/fossil-autocomplete.bash
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple, high-reliability, distributed software configuration management";
     longDescription = ''
       Fossil is a software configuration management system.  Fossil is
diff --git a/pkgs/applications/version-management/gerrit/default.nix b/pkgs/applications/version-management/gerrit/default.nix
index 5b4808e87a6bc..164a8b850051c 100644
--- a/pkgs/applications/version-management/gerrit/default.nix
+++ b/pkgs/applications/version-management/gerrit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "gerrit";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     ];
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gerritcodereview.com/index.md";
     license = licenses.asl20;
     description = "A web based code review and repository management for the git version control system";
diff --git a/pkgs/applications/version-management/git-and-tools/bfg-repo-cleaner/default.nix b/pkgs/applications/version-management/git-and-tools/bfg-repo-cleaner/default.nix
index 99c6323217ab8..1ffc065367507 100644
--- a/pkgs/applications/version-management/git-and-tools/bfg-repo-cleaner/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/bfg-repo-cleaner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 let
   version = "1.13.0";
@@ -26,7 +26,7 @@ in
       makeWrapper "${jre}/bin/java" $out/bin/bfg --add-flags "-cp $out/share/java/$jarName com.madgag.git.bfg.cli.Main"
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://rtyley.github.io/bfg-repo-cleaner/";
       # Descriptions taken with minor modification from the homepage of bfg-repo-cleaner
       description = "Removes large or troublesome blobs in a git repository like git-filter-branch does, but faster";
diff --git a/pkgs/applications/version-management/git-and-tools/bump2version/default.nix b/pkgs/applications/version-management/git-and-tools/bump2version/default.nix
index eb44f6d412b51..393edc57dcc8f 100644
--- a/pkgs/applications/version-management/git-and-tools/bump2version/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/bump2version/default.nix
@@ -18,7 +18,7 @@ buildPythonApplication rec {
     pytest tests/ -k 'not usage_string_fork'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Version-bump your software with a single command";
     longDescription = ''
       A small command line tool to simplify releasing software by updating
diff --git a/pkgs/applications/version-management/git-and-tools/diff-so-fancy/default.nix b/pkgs/applications/version-management/git-and-tools/diff-so-fancy/default.nix
index ffdb788745a79..42ebe89cd4aaf 100644
--- a/pkgs/applications/version-management/git-and-tools/diff-so-fancy/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/diff-so-fancy/default.nix
@@ -1,4 +1,4 @@
-{stdenv, git, perl, ncurses, coreutils, fetchFromGitHub, makeWrapper, ...}:
+{lib, stdenv, git, perl, ncurses, coreutils, fetchFromGitHub, makeWrapper, ...}:
 
 stdenv.mkDerivation rec {
   pname = "diff-so-fancy";
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/so-fancy/diff-so-fancy";
     description = "Good-looking diffs filter for git";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/fast-export/default.nix b/pkgs/applications/version-management/git-and-tools/fast-export/default.nix
index 80f048d057523..5aea15769c0b0 100644
--- a/pkgs/applications/version-management/git-and-tools/fast-export/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/fast-export/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, git, mercurial, makeWrapper}:
+{lib, stdenv, fetchFromGitHub, git, mercurial, makeWrapper}:
 
 stdenv.mkDerivation rec {
   pname = "fast-export";
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Import mercurial into git";
     homepage = "https://repo.or.cz/w/fast-export.git";
     license = licenses.gpl2;
diff --git a/pkgs/applications/version-management/git-and-tools/ghorg/default.nix b/pkgs/applications/version-management/git-and-tools/ghorg/default.nix
index 30049e8458778..f7ce118bbc7c0 100644
--- a/pkgs/applications/version-management/git-and-tools/ghorg/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/ghorg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "ghorg";
@@ -18,7 +18,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quickly clone an entire org/users repositories into one directory";
     longDescription = ''
       ghorg allows you to quickly clone all of an orgs, or users repos into a
diff --git a/pkgs/applications/version-management/git-and-tools/git-absorb/default.nix b/pkgs/applications/version-management/git-and-tools/git-absorb/default.nix
index d8e34f5700583..c4824b6c66f18 100644
--- a/pkgs/applications/version-management/git-and-tools/git-absorb/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-absorb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, installShellFiles, libiconv, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles, libiconv, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "git-absorb";
@@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tummychow/git-absorb";
     description = "git commit --fixup, but automatic";
     license = [ licenses.bsd3 ];
diff --git a/pkgs/applications/version-management/git-and-tools/git-annex-metadata-gui/default.nix b/pkgs/applications/version-management/git-and-tools/git-annex-metadata-gui/default.nix
index cb0103df227a1..1908b75392436 100644
--- a/pkgs/applications/version-management/git-and-tools/git-annex-metadata-gui/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-annex-metadata-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub, pyqt5, qt5, git-annex-adapter }:
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub, pyqt5, qt5, git-annex-adapter }:
 
 buildPythonApplication rec {
   pname = "git-annex-metadata-gui";
@@ -23,7 +23,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ pyqt5 git-annex-adapter ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/alpernebbi/git-annex-metadata-gui";
     description = "Graphical interface for git-annex metadata commands";
     maintainers = with maintainers; [ dotlambda ];
diff --git a/pkgs/applications/version-management/git-and-tools/git-annex-remote-rclone/default.nix b/pkgs/applications/version-management/git-and-tools/git-annex-remote-rclone/default.nix
index 260e8024a8cca..ea44d7278f376 100644
--- a/pkgs/applications/version-management/git-and-tools/git-annex-remote-rclone/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-annex-remote-rclone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rclone, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, rclone, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "git-annex-remote-rclone";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" "${stdenv.lib.makeBinPath [ rclone ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/DanielDent/git-annex-remote-rclone";
     description = "Use rclone supported cloud storage providers with git-annex";
     license = licenses.gpl3;
diff --git a/pkgs/applications/version-management/git-and-tools/git-bug/default.nix b/pkgs/applications/version-management/git-and-tools/git-bug/default.nix
index 7c345639e9f86..9ca5c707b5ce0 100644
--- a/pkgs/applications/version-management/git-and-tools/git-bug/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-bug/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "git-bug";
@@ -29,7 +29,7 @@ buildGoModule rec {
     install -D -m 0644 -t "$out/share/man/man1" doc/man/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Distributed bug tracker embedded in Git";
     homepage = "https://github.com/MichaelMure/git-bug";
     license = licenses.gpl3;
diff --git a/pkgs/applications/version-management/git-and-tools/git-bz/default.nix b/pkgs/applications/version-management/git-and-tools/git-bz/default.nix
index 7f199894924ee..20e6a993cab26 100644
--- a/pkgs/applications/version-management/git-and-tools/git-bz/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-bz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit
+{ lib, stdenv, fetchgit
 , asciidoc, docbook_xml_dtd_45, docbook_xsl, libxslt, makeWrapper, xmlto
 , pythonPackages }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
       --prefix PYTHONPATH : "$(toPythonPath "${pythonPackages.pysqlite}")"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bugzilla integration for git";
     longDescription = ''
       git-bz is a tool for integrating the Git command line with the
diff --git a/pkgs/applications/version-management/git-and-tools/git-cola/default.nix b/pkgs/applications/version-management/git-and-tools/git-cola/default.nix
index fa77b5307a37b..e7e0e009d1120 100644
--- a/pkgs/applications/version-management/git-and-tools/git-cola/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-cola/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, gettext, git, qt5 }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, gettext, git, qt5 }:
 
 let
   inherit (python3Packages) buildPythonApplication pyqt5 sip pyinotify;
@@ -26,7 +26,7 @@ in buildPythonApplication rec {
 
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/git-cola/git-cola";
     description = "A sleek and powerful Git GUI";
     license = licenses.gpl2;
diff --git a/pkgs/applications/version-management/git-and-tools/git-crypt/default.nix b/pkgs/applications/version-management/git-and-tools/git-crypt/default.nix
index 487f9b9625f49..08875dabd0fe9 100644
--- a/pkgs/applications/version-management/git-and-tools/git-crypt/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-crypt/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, git, gnupg, makeWrapper, openssl, stdenv
+{ fetchFromGitHub, git, gnupg, makeWrapper, openssl, lib, stdenv
 , libxslt, docbook_xsl
 }:
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/git-crypt --prefix PATH : $out/bin:${git}/bin:${gnupg}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.agwa.name/projects/git-crypt";
     description = "Transparent file encryption in git";
     longDescription = ''
diff --git a/pkgs/applications/version-management/git-and-tools/git-dit/default.nix b/pkgs/applications/version-management/git-and-tools/git-dit/default.nix
index 9ec4e25304245..e41a8b3a5258e 100644
--- a/pkgs/applications/version-management/git-and-tools/git-dit/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-dit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , openssl_1_0_2
 , zlib
@@ -45,7 +45,7 @@ buildRustPackage rec {
     Security
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Decentralized Issue Tracking for git";
     # This has not had a release in years and its cargo vendored dependencies
diff --git a/pkgs/applications/version-management/git-and-tools/git-extras/default.nix b/pkgs/applications/version-management/git-and-tools/git-extras/default.nix
index d322a141cd944..3f6ea7972baca 100644
--- a/pkgs/applications/version-management/git-and-tools/git-extras/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-extras/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, unixtools, which }:
+{ lib, stdenv, fetchzip, unixtools, which }:
 
 stdenv.mkDerivation rec {
   pname = "git-extras";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     install -D etc/git-extras-completion.zsh $out/share/zsh/site-functions/_git_extras
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tj/git-extras";
     description = "GIT utilities -- repo summary, repl, changelog population, author commit percentages and more";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-fame/default.nix b/pkgs/applications/version-management/git-and-tools/git-fame/default.nix
index 782579c704464..6084d496a565b 100644
--- a/pkgs/applications/version-management/git-and-tools/git-fame/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-fame/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bundlerEnv, ruby, bundlerUpdateScript }:
+{ lib, stdenv, bundlerEnv, ruby, bundlerUpdateScript }:
 
 bundlerEnv {
   inherit ruby;
@@ -9,7 +9,7 @@ bundlerEnv {
 
   passthru.updateScript = bundlerUpdateScript "gitAndTools.git-fame";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A command-line tool that helps you summarize and pretty-print collaborators based on contributions
       '';
diff --git a/pkgs/applications/version-management/git-and-tools/git-filter-repo/default.nix b/pkgs/applications/version-management/git-and-tools/git-filter-repo/default.nix
index c642f062c7b69..864ef51a58814 100644
--- a/pkgs/applications/version-management/git-and-tools/git-filter-repo/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-filter-repo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages }:
+{ lib, stdenv, fetchurl, pythonPackages }:
 
 stdenv.mkDerivation rec {
   pname = "git-filter-repo";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -Dm644 -t $out/share/man/man1 Documentation/man1/git-filter-repo.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/newren/git-filter-repo";
     description = "Quickly rewrite git repository history (filter-branch replacement)";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-gone/default.nix b/pkgs/applications/version-management/git-and-tools/git-gone/default.nix
index 13411ed4c41b2..f08f57ee8bee8 100644
--- a/pkgs/applications/version-management/git-and-tools/git-gone/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-gone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, makeWrapper, openssl, git, libiconv, Security, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkgconfig, makeWrapper, openssl, git, libiconv, Security, installShellFiles }:
 
 rustPlatform.buildRustPackage rec {
   pname = "git-gone";
@@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec {
     wrapProgram $out/bin/git-gone --prefix PATH : "${stdenv.lib.makeBinPath [ git ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cleanup stale Git branches of pull requests";
     homepage = "https://github.com/lunaryorn/git-gone";
     license = licenses.asl20;
diff --git a/pkgs/applications/version-management/git-and-tools/git-hub/default.nix b/pkgs/applications/version-management/git-and-tools/git-hub/default.nix
index 33b3d0bc167ca..ac3de7cbc9ec5 100644
--- a/pkgs/applications/version-management/git-and-tools/git-hub/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-hub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gitMinimal, python2Packages }:
+{ lib, stdenv, fetchFromGitHub, gitMinimal, python2Packages }:
 
 stdenv.mkDerivation rec {
   pname = "git-hub";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     rm -r $out/share/{doc,vim}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Git command line interface to GitHub";
     longDescription = ''
diff --git a/pkgs/applications/version-management/git-and-tools/git-ignore/default.nix b/pkgs/applications/version-management/git-and-tools/git-ignore/default.nix
index a2f319d82b0d6..4ef97a30a1f56 100644
--- a/pkgs/applications/version-management/git-and-tools/git-ignore/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-ignore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, installShellFiles, rustPlatform, pkgconfig, openssl, darwin }:
+{ lib, stdenv, fetchFromGitHub, installShellFiles, rustPlatform, pkgconfig, openssl, darwin }:
 
 with rustPlatform;
 
@@ -26,7 +26,7 @@ buildRustPackage rec {
     installManPage $releaseDir/build/git-ignore-*/out/git-ignore.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quickly and easily fetch .gitignore templates from gitignore.io";
     homepage = "https://github.com/sondr3/git-ignore";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/version-management/git-and-tools/git-interactive-rebase-tool/default.nix b/pkgs/applications/version-management/git-and-tools/git-interactive-rebase-tool/default.nix
index 1edd48f92f150..2b76fb3dea501 100644
--- a/pkgs/applications/version-management/git-and-tools/git-interactive-rebase-tool/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-interactive-rebase-tool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, ncurses5, fetchFromGitHub, rustPlatform, libiconv, Security }:
+{ lib, stdenv, ncurses5, fetchFromGitHub, rustPlatform, libiconv, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "git-interactive-rebase-tool";
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoParallelTestThreads = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/MitMaro/git-interactive-rebase-tool";
     description = "Native cross platform full feature terminal based sequence editor for git interactive rebase";
     changelog = "https://github.com/MitMaro/git-interactive-rebase-tool/releases/tag/${version}";
diff --git a/pkgs/applications/version-management/git-and-tools/git-my/default.nix b/pkgs/applications/version-management/git-and-tools/git-my/default.nix
index 2a8a262bf3048..d8ce7a42bb591 100644
--- a/pkgs/applications/version-management/git-and-tools/git-my/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-my/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "git-my";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -Dm755 -t "$out"/bin ./git-my
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "List remote branches if they're merged and/or available locally";
     homepage = "https://github.com/davidosomething/git-my";
diff --git a/pkgs/applications/version-management/git-and-tools/git-open/default.nix b/pkgs/applications/version-management/git-and-tools/git-open/default.nix
index f7b2120cca023..ac28e55595038 100644
--- a/pkgs/applications/version-management/git-and-tools/git-open/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-open/default.nix
@@ -1,4 +1,4 @@
-{stdenv, git, xdg_utils, gnugrep, fetchFromGitHub, makeWrapper}:
+{lib, stdenv, git, xdg_utils, gnugrep, fetchFromGitHub, makeWrapper}:
 
 stdenv.mkDerivation rec {
   pname = "git-open";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ git xdg_utils gnugrep ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/paulirish/git-open";
     description = "Open the GitHub page or website for a repository in your browser";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-radar/default.nix b/pkgs/applications/version-management/git-and-tools/git-radar/default.nix
index fc4b5850f5c70..1cd14aa969278 100644
--- a/pkgs/applications/version-management/git-and-tools/git-radar/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-radar/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub}:
+{lib, stdenv, fetchFromGitHub}:
 
 stdenv.mkDerivation rec {
   pname = "git-radar";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     ln -s $out/git-radar $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/michaeldfallen/git-radar";
     license = licenses.mit;
     description = "A tool you can add to your prompt to provide at-a-glance information on your git repo";
diff --git a/pkgs/applications/version-management/git-and-tools/git-recent/default.nix b/pkgs/applications/version-management/git-and-tools/git-recent/default.nix
index a01b84a948ada..b3a371063f365 100644
--- a/pkgs/applications/version-management/git-and-tools/git-recent/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-recent/default.nix
@@ -1,4 +1,4 @@
-{stdenv, git, less, fetchFromGitHub, makeWrapper
+{lib, stdenv, git, less, fetchFromGitHub, makeWrapper
 # util-linuxMinimal is included because we need the column command
 , util-linux
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ git less util-linux ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/paulirish/git-recent";
     description = "See your latest local git branches, formatted real fancy";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-remote-gcrypt/default.nix b/pkgs/applications/version-management/git-and-tools/git-remote-gcrypt/default.nix
index 04787b0ce25b2..16efc8cbca100 100644
--- a/pkgs/applications/version-management/git-and-tools/git-remote-gcrypt/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-remote-gcrypt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, docutils, makeWrapper
+{ lib, stdenv, fetchFromGitHub, docutils, makeWrapper
 , gnupg, curl, rsync, coreutils
 , gawk, gnused, gnugrep
 }:
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
                                                     gawk gnused gnugrep ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://spwhitton.name/tech/code/git-remote-gcrypt";
     description = "A git remote helper for GPG-encrypted remotes";
     license = licenses.gpl3;
diff --git a/pkgs/applications/version-management/git-and-tools/git-reparent/default.nix b/pkgs/applications/version-management/git-and-tools/git-reparent/default.nix
index c0de46264d05e..7bc4a05e53cfd 100644
--- a/pkgs/applications/version-management/git-and-tools/git-reparent/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-reparent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, git, gnused }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, git, gnused }:
 
 stdenv.mkDerivation rec {
   pname = "git-reparent";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/git-reparent --prefix PATH : "${stdenv.lib.makeBinPath [ git gnused ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Git command to recommit HEAD with a new set of parents";
     maintainers = [ maintainers.marsam ];
diff --git a/pkgs/applications/version-management/git-and-tools/git-secrets/default.nix b/pkgs/applications/version-management/git-and-tools/git-secrets/default.nix
index 1beff2a118df0..90c2b88422633 100644
--- a/pkgs/applications/version-management/git-and-tools/git-secrets/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-secrets/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, git, coreutils }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, git, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "git-secrets";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ git coreutils ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prevents you from committing secrets and credentials into git repositories";
     homepage = "https://github.com/awslabs/git-secrets";
     license = licenses.asl20;
diff --git a/pkgs/applications/version-management/git-and-tools/git-standup/default.nix b/pkgs/applications/version-management/git-and-tools/git-standup/default.nix
index ceb734f0f67fd..541baee50a7f3 100644
--- a/pkgs/applications/version-management/git-and-tools/git-standup/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-standup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, git }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, git }:
 
 stdenv.mkDerivation rec {
   pname = "git-standup";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ git ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recall what you did on the last working day";
     homepage = "https://github.com/kamranahmedse/git-standup";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-subrepo/default.nix b/pkgs/applications/version-management/git-and-tools/git-subrepo/default.nix
index 708014e4af8df..7fe9883c556da 100644
--- a/pkgs/applications/version-management/git-and-tools/git-subrepo/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-subrepo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, git, makeWrapper, which }:
+{ lib, stdenv, fetchFromGitHub, git, makeWrapper, which }:
 
 stdenv.mkDerivation rec {
   pname = "git-subrepo";
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${git}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ingydotnet/git-subrepo";
     description = "Git submodule alternative";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-subset/default.nix b/pkgs/applications/version-management/git-and-tools/git-subset/default.nix
index 9893e6dd7844e..dd6902af243a3 100644
--- a/pkgs/applications/version-management/git-and-tools/git-subset/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-subset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, curl, libiconv, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, curl, libiconv, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "git-subset";
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = [ openssl ] ++ stdenv.lib.optionals stdenv.isDarwin [ curl libiconv Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Super fast Git tree filtering";
     homepage = "https://github.com/jasonwhite/git-subset";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-test/default.nix b/pkgs/applications/version-management/git-and-tools/git-test/default.nix
index 27f9bcffa34e7..de345f17cf014 100644
--- a/pkgs/applications/version-management/git-and-tools/git-test/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-test/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, git }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, git }:
 
 stdenv.mkDerivation rec {
   pname = "git-test";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ git ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test your commits";
     homepage = "https://github.com/spotify/git-test";
     license = licenses.asl20;
diff --git a/pkgs/applications/version-management/git-and-tools/git-trim/default.nix b/pkgs/applications/version-management/git-and-tools/git-trim/default.nix
index 33534334bea70..d827797b33a89 100644
--- a/pkgs/applications/version-management/git-and-tools/git-trim/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-trim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, libiconv, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, libiconv, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "git-trim";
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
   # fails with sandbox
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically trims your branches whose tracking remote refs are merged or gone";
     homepage = "https://github.com/foriequal0/git-trim";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/git-vanity-hash/default.nix b/pkgs/applications/version-management/git-and-tools/git-vanity-hash/default.nix
index 839acc5cca594..77e077436169e 100644
--- a/pkgs/applications/version-management/git-and-tools/git-vanity-hash/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-vanity-hash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "git-vanity-hash";
@@ -18,7 +18,7 @@ rustPlatform.buildRustPackage rec {
     cp README.md $out/share/doc/git-vanity-hash
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/prasmussen/git-vanity-hash";
     description = "Tool for creating commit hashes with a specific prefix";
     license = [ licenses.mit ];
diff --git a/pkgs/applications/version-management/git-and-tools/git-when-merged/default.nix b/pkgs/applications/version-management/git-and-tools/git-when-merged/default.nix
index 8eee1469819d0..d020f351fedf5 100644
--- a/pkgs/applications/version-management/git-and-tools/git-when-merged/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-when-merged/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "git-when-merged";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -D --target-directory $out/bin/ bin/git-when-merged
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Helps you figure out when and why a commit was merged into a branch";
     longDescription = ''
diff --git a/pkgs/applications/version-management/git-and-tools/git-workspace/default.nix b/pkgs/applications/version-management/git-and-tools/git-workspace/default.nix
index 674bdd14247a3..aa869c754dc1c 100644
--- a/pkgs/applications/version-management/git-and-tools/git-workspace/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/git-workspace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , Security
@@ -21,7 +21,7 @@ rustPlatform.buildRustPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ openssl ] ++ stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sync personal and work git repositories from multiple providers";
     homepage = "https://github.com/orf/git-workspace";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/version-management/git-and-tools/gitbatch/default.nix b/pkgs/applications/version-management/git-and-tools/gitbatch/default.nix
index 99a127f3d8f8d..dc853be6772ec 100644
--- a/pkgs/applications/version-management/git-and-tools/gitbatch/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/gitbatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gitbatch-unstable";
@@ -15,7 +15,7 @@ buildGoPackage rec {
     sha256 = "0613vfqdn3k0w7fm25rqnqdr67w9vii3i56dfslqcn1vqjfrff3q";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Running git UI commands";
     homepage = "https://github.com/isacikgoz/gitbatch";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/gitflow/default.nix b/pkgs/applications/version-management/git-and-tools/gitflow/default.nix
index 1307573990a9a..b9bca127472e2 100644
--- a/pkgs/applications/version-management/git-and-tools/gitflow/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/gitflow/default.nix
@@ -1,4 +1,4 @@
-{ pkgs, stdenv, fetchFromGitHub }:
+{ pkgs, lib, stdenv, fetchFromGitHub }:
 
 with pkgs.lib;
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
       --suffix PATH : ${pkgs.git}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/petervanderdoes/gitflow";
     description = "Extend git with the Gitflow branching model";
     longDescription = ''
diff --git a/pkgs/applications/version-management/git-and-tools/gitin/default.nix b/pkgs/applications/version-management/git-and-tools/gitin/default.nix
index af9aef6d39c6e..c9111ea2c3227 100644
--- a/pkgs/applications/version-management/git-and-tools/gitin/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/gitin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoPackage
 , fetchFromGitHub
 , pkgconfig
@@ -23,7 +23,7 @@ buildGoPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libgit2_0_27 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/isacikgoz/gitin";
     description = "Text-based user interface for git";
     license = licenses.bsd3;
diff --git a/pkgs/applications/version-management/git-and-tools/gitstatus/default.nix b/pkgs/applications/version-management/git-and-tools/gitstatus/default.nix
index a6ca3126d5ce8..f4b74405eba21 100644
--- a/pkgs/applications/version-management/git-and-tools/gitstatus/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/gitstatus/default.nix
@@ -1,4 +1,4 @@
-{ callPackage, stdenv, fetchFromGitHub, git, zsh, ...}:
+{ callPackage, lib, stdenv, fetchFromGitHub, git, zsh, ...}:
 
 stdenv.mkDerivation rec {
   pname = "gitstatus";
@@ -73,7 +73,7 @@ stdenv.mkDerivation rec {
     wait $!
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "10x faster implementation of `git status` command";
     homepage = "https://github.com/romkatv/gitstatus";
     license = licenses.gpl3Only;
diff --git a/pkgs/applications/version-management/git-and-tools/gitui/default.nix b/pkgs/applications/version-management/git-and-tools/gitui/default.nix
index f89349aaeaa5f..20a446965f90d 100644
--- a/pkgs/applications/version-management/git-and-tools/gitui/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/gitui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, libiconv, perl, python3, Security, AppKit, openssl, xclip }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, libiconv, perl, python3, Security, AppKit, openssl, xclip }:
 rustPlatform.buildRustPackage rec {
   pname = "gitui";
   version = "0.11.0";
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
     ++ stdenv.lib.optional stdenv.isLinux xclip
     ++ stdenv.lib.optionals stdenv.isDarwin [ libiconv Security AppKit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Blazing fast terminal-ui for git written in rust";
     homepage = "https://github.com/extrawurst/gitui";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/grv/default.nix b/pkgs/applications/version-management/git-and-tools/grv/default.nix
index 64a4f8a823ce6..f7aae5ba8d27e 100644
--- a/pkgs/applications/version-management/git-and-tools/grv/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/grv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, curl, ncurses, pkgconfig, readline
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, curl, ncurses, pkgconfig, readline
 , cmake }:
 let
   version = "0.3.2";
@@ -40,7 +40,7 @@ buildGoPackage {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GRV is a terminal interface for viewing Git repositories";
     homepage = "https://github.com/rgburke/grv";
     license = licenses.gpl3;
diff --git a/pkgs/applications/version-management/git-and-tools/hub/default.nix b/pkgs/applications/version-management/git-and-tools/hub/default.nix
index 788512df85cda..4b189c55c8a84 100644
--- a/pkgs/applications/version-management/git-and-tools/hub/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/hub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, git, groff, installShellFiles, util-linux, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, git, groff, installShellFiles, util-linux, nixosTests }:
 
 buildGoPackage rec {
   pname = "hub";
@@ -37,7 +37,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests) hub; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line wrapper for git that makes you better at GitHub";
     license = licenses.mit;
     homepage = "https://hub.github.com/";
diff --git a/pkgs/applications/version-management/git-and-tools/lefthook/default.nix b/pkgs/applications/version-management/git-and-tools/lefthook/default.nix
index a13e4b33d38e6..ce7493088430d 100644
--- a/pkgs/applications/version-management/git-and-tools/lefthook/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/lefthook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 # Currently `buildGo114Module` is passed as `buildGoModule` from
 # `../default.nix`. Please remove the fixed 1.14 once a new release has been
@@ -21,7 +21,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and powerful Git hooks manager for any type of projects";
     homepage = "https://github.com/Arkweid/lefthook";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/pass-git-helper/default.nix b/pkgs/applications/version-management/git-and-tools/pass-git-helper/default.nix
index 5914378f5b35e..805afdf363c56 100644
--- a/pkgs/applications/version-management/git-and-tools/pass-git-helper/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/pass-git-helper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub, pyxdg, pytest }:
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub, pyxdg, pytest }:
 
 buildPythonApplication rec {
   pname   = "pass-git-helper";
@@ -17,7 +17,7 @@ buildPythonApplication rec {
     export HOME=$(mktemp -d)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/languitar/pass-git-helper";
     description = "A git credential helper interfacing with pass, the standard unix password manager";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/version-management/git-and-tools/radicle-upstream/default.nix b/pkgs/applications/version-management/git-and-tools/radicle-upstream/default.nix
index 9f0949aef5299..26f46066531e4 100644
--- a/pkgs/applications/version-management/git-and-tools/radicle-upstream/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/radicle-upstream/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appimageTools, gsettings-desktop-schemas, gtk3, autoPatchelfHook, zlib, fetchurl }:
+{ lib, stdenv, appimageTools, gsettings-desktop-schemas, gtk3, autoPatchelfHook, zlib, fetchurl }:
 
 let
   pname = "radicle-upstream";
@@ -54,7 +54,7 @@ appimageTools.wrapType2 {
       $out/share/icons/hicolor/512x512/apps/${pname}.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A decentralized app for code collaboration";
     homepage = "https://radicle.xyz/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/version-management/git-and-tools/scmpuff/default.nix b/pkgs/applications/version-management/git-and-tools/scmpuff/default.nix
index de8cb396b7fc5..69062d305b7a5 100644
--- a/pkgs/applications/version-management/git-and-tools/scmpuff/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/scmpuff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "scmpuff";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "0zrzzcs0i13pfwcqh8qb0sji54vh37rdr7qasg57y56cqpx16vl3";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Add numbered shortcuts to common git commands";
     homepage = "https://github.com/mroth/scmpuff";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-and-tools/stgit/default.nix b/pkgs/applications/version-management/git-and-tools/stgit/default.nix
index 1bad72296b4f7..3a37c798a0850 100644
--- a/pkgs/applications/version-management/git-and-tools/stgit/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/stgit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, git, installShellFiles }:
+{ lib, stdenv, python3Packages, fetchFromGitHub, git, installShellFiles }:
 
 python3Packages.buildPythonApplication rec {
   pname = "stgit";
@@ -21,7 +21,7 @@ python3Packages.buildPythonApplication rec {
     installShellCompletion --name _stg $out/share/stgit/completion/stgit.zsh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A patch manager implemented on top of Git";
     homepage = "http://procode.org/stgit/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/version-management/git-and-tools/svn-all-fast-export/default.nix b/pkgs/applications/version-management/git-and-tools/svn-all-fast-export/default.nix
index 75f6a96084128..8c73c00f00c28 100644
--- a/pkgs/applications/version-management/git-and-tools/svn-all-fast-export/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/svn-all-fast-export/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qmake, qtbase, qttools, subversion, apr }:
+{ lib, stdenv, fetchFromGitHub, qmake, qtbase, qttools, subversion, apr }:
 
 let
   version = "1.0.18";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
 
   NIX_LDFLAGS = "-lsvn_fs-1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/svn-all-fast-export/svn2git";
     description = "A fast-import based converter for an svn repo to git repos";
     license = licenses.gpl3;
diff --git a/pkgs/applications/version-management/git-and-tools/tig/default.nix b/pkgs/applications/version-management/git-and-tools/tig/default.nix
index 9415c0eecf165..1a469970caf2d 100644
--- a/pkgs/applications/version-management/git-and-tools/tig/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/tig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, asciidoc, xmlto, docbook_xsl, docbook_xml_dtd_45
+{ lib, stdenv, fetchFromGitHub, ncurses, asciidoc, xmlto, docbook_xsl, docbook_xml_dtd_45
 , readline, makeWrapper, git, libiconv, autoreconfHook, findXMLCatalogs, pkgconfig
 }:
 
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ':' "${git}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://jonas.github.io/tig/";
     description = "Text-mode interface for git";
     maintainers = with maintainers; [ bjornfor domenkozar qknight globin ];
diff --git a/pkgs/applications/version-management/git-and-tools/topgit/default.nix b/pkgs/applications/version-management/git-and-tools/topgit/default.nix
index 9577b56b6c732..cbb341ae3eb32 100644
--- a/pkgs/applications/version-management/git-and-tools/topgit/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/topgit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, git, perl }:
+{ lib, stdenv, fetchFromGitHub, git, perl }:
 
 stdenv.mkDerivation rec {
   pname = "topgit";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -Dm755 contrib/tg-completion.bash -t "$out/share/bash-completion/completions/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TopGit manages large amount of interdependent topic branches";
     homepage = "https://github.com/mackyle/topgit";
     license = licenses.gpl2;
diff --git a/pkgs/applications/version-management/git-and-tools/transcrypt/default.nix b/pkgs/applications/version-management/git-and-tools/transcrypt/default.nix
index c99c70379df45..faa4d66d7caed 100644
--- a/pkgs/applications/version-management/git-and-tools/transcrypt/default.nix
+++ b/pkgs/applications/version-management/git-and-tools/transcrypt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, git, makeWrapper, openssl, coreutils, util-linux, gnugrep, gnused, gawk }:
+{ lib, stdenv, fetchFromGitHub, git, makeWrapper, openssl, coreutils, util-linux, gnugrep, gnused, gawk }:
 
 stdenv.mkDerivation rec {
   pname = "transcrypt";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/transcrypt-depspathprefix
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Transparently encrypt files within a Git repository";
     longDescription = ''
       A script to configure transparent encryption of sensitive files stored in
diff --git a/pkgs/applications/version-management/git-backup/default.nix b/pkgs/applications/version-management/git-backup/default.nix
index d65e2cf6ebffa..bb6216471256a 100644
--- a/pkgs/applications/version-management/git-backup/default.nix
+++ b/pkgs/applications/version-management/git-backup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "git-backup";
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = [ openssl ] ++ stdenv.lib.optionals stdenv.isDarwin [ Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jsdw/git-backup";
     description = "A tool to help you backup your git repositories from services like GitHub";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/git-lfs/1.nix b/pkgs/applications/version-management/git-lfs/1.nix
index 5b2a9906a4f8e..3c758908cd49e 100644
--- a/pkgs/applications/version-management/git-lfs/1.nix
+++ b/pkgs/applications/version-management/git-lfs/1.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "git-lfs";
@@ -22,7 +22,7 @@ buildGoPackage rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Git extension for versioning large files";
     homepage    = "https://git-lfs.github.com/";
     license     = [ licenses.mit ];
diff --git a/pkgs/applications/version-management/git-lfs/default.nix b/pkgs/applications/version-management/git-lfs/default.nix
index d624981820877..3736c1c573d02 100644
--- a/pkgs/applications/version-management/git-lfs/default.nix
+++ b/pkgs/applications/version-management/git-lfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, ronn, installShellFiles }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, ronn, installShellFiles }:
 
 buildGoPackage rec {
   pname = "git-lfs";
@@ -27,7 +27,7 @@ buildGoPackage rec {
     installManPage go/src/${goPackagePath}/man/*.{1,5}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Git extension for versioning large files";
     homepage    = "https://git-lfs.github.com/";
     changelog   = "https://github.com/git-lfs/git-lfs/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/applications/version-management/git-repo/default.nix b/pkgs/applications/version-management/git-repo/default.nix
index e6f6e69fcaafa..fb0b153bc3ae7 100644
--- a/pkgs/applications/version-management/git-repo/default.nix
+++ b/pkgs/applications/version-management/git-repo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchFromGitHub, makeWrapper
 , python3, git, gnupg, less
 }:
 
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
       "${stdenv.lib.makeBinPath [ git gnupg less ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Android's repo management tool";
     longDescription = ''
       Repo is a Python script based on Git that helps manage many Git
diff --git a/pkgs/applications/version-management/git-up/default.nix b/pkgs/applications/version-management/git-up/default.nix
index 2a0a97771cbfe..57a40de9d4a44 100644
--- a/pkgs/applications/version-management/git-up/default.nix
+++ b/pkgs/applications/version-management/git-up/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages, git }:
+{ lib, stdenv, fetchurl, pythonPackages, git }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "git-up";
@@ -26,7 +26,7 @@ pythonPackages.buildPythonApplication rec {
     rm -r $out/${pythonPackages.python.sitePackages}/PyGitUp/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/msiemens/PyGitUp";
     description = "A git pull replacement that rebases all local branches when pulling";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/gitinspector/default.nix b/pkgs/applications/version-management/gitinspector/default.nix
index ac96706015539..68dd3c190bec7 100644
--- a/pkgs/applications/version-management/gitinspector/default.nix
+++ b/pkgs/applications/version-management/gitinspector/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, python2Packages}:
+{ lib, stdenv, fetchzip, python2Packages}:
 
 python2Packages.buildPythonApplication rec {
   pname = "gitinspector";
@@ -15,7 +15,7 @@ python2Packages.buildPythonApplication rec {
     unittest2
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ejwa/gitinspector";
     description = "Statistical analysis tool for git repositories";
     license = licenses.gpl3;
diff --git a/pkgs/applications/version-management/gitlab/gitaly/default.nix b/pkgs/applications/version-management/gitlab/gitaly/default.nix
index e8c99198df40e..c16e66c9e8182 100644
--- a/pkgs/applications/version-management/gitlab/gitaly/default.nix
+++ b/pkgs/applications/version-management/gitlab/gitaly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, fetchFromGitHub, buildGoModule, ruby
+{ lib, stdenv, fetchFromGitLab, fetchFromGitHub, buildGoModule, ruby
 , bundlerEnv, pkgconfig
 # libgit2 + dependencies
 , libgit2, openssl, zlib, pcre, http-parser }:
@@ -61,7 +61,7 @@ in buildGoModule rec {
 
   outputs = [ "out" "ruby" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/gitlab-org/gitaly";
     description = "A Git RPC service for handling all the git calls made by GitLab";
     platforms = platforms.linux;
diff --git a/pkgs/applications/version-management/gitlab/gitlab-shell/default.nix b/pkgs/applications/version-management/gitlab/gitlab-shell/default.nix
index 14f7ce0f81e84..d1b5958c751df 100644
--- a/pkgs/applications/version-management/gitlab/gitlab-shell/default.nix
+++ b/pkgs/applications/version-management/gitlab/gitlab-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, buildGoModule, ruby }:
+{ lib, stdenv, fetchFromGitLab, buildGoModule, ruby }:
 
 buildGoModule rec {
   pname = "gitlab-shell";
@@ -22,7 +22,7 @@ buildGoModule rec {
   '';
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SSH access and repository management app for GitLab";
     homepage = "http://www.gitlab.com/";
     platforms = platforms.linux;
diff --git a/pkgs/applications/version-management/gitlab/gitlab-workhorse/default.nix b/pkgs/applications/version-management/gitlab/gitlab-workhorse/default.nix
index e536d4fcbb1e3..b38485716d7d3 100644
--- a/pkgs/applications/version-management/gitlab/gitlab-workhorse/default.nix
+++ b/pkgs/applications/version-management/gitlab/gitlab-workhorse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, git, buildGoModule }:
+{ lib, stdenv, fetchFromGitLab, git, buildGoModule }:
 
 buildGoModule rec {
   pname = "gitlab-workhorse";
@@ -17,7 +17,7 @@ buildGoModule rec {
   buildFlagsArray = "-ldflags=-X main.Version=${version}";
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.gitlab.com/";
     platforms = platforms.linux;
     maintainers = with maintainers; [ fpletz globin talyz ];
diff --git a/pkgs/applications/version-management/gitless/default.nix b/pkgs/applications/version-management/gitless/default.nix
index 0cead50f03266..e53da902e138e 100644
--- a/pkgs/applications/version-management/gitless/default.nix
+++ b/pkgs/applications/version-management/gitless/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, python, stdenv }:
+{ fetchFromGitHub, python, lib, stdenv }:
 
 with python.pkgs;
 buildPythonApplication rec {
@@ -16,7 +16,7 @@ buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitless.com/";
     description = "A version control system built on top of Git";
     license = licenses.gpl2;
diff --git a/pkgs/applications/version-management/gitolite/default.nix b/pkgs/applications/version-management/gitolite/default.nix
index 5e2fdc087fe35..8dd2766ff0ed4 100644
--- a/pkgs/applications/version-management/gitolite/default.nix
+++ b/pkgs/applications/version-management/gitolite/default.nix
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     echo ${version} > $out/bin/VERSION
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Finely-grained git repository hosting";
     homepage    = "https://gitolite.com/gitolite/index.html";
     license     = licenses.gpl2;
diff --git a/pkgs/applications/version-management/gitoxide/default.nix b/pkgs/applications/version-management/gitoxide/default.nix
index f7a17e510f4b3..c345b8d7a80f6 100644
--- a/pkgs/applications/version-management/gitoxide/default.nix
+++ b/pkgs/applications/version-management/gitoxide/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "gitoxide";
@@ -20,7 +20,7 @@ rustPlatform.buildRustPackage rec {
   # Needed to get openssl-sys to use pkgconfig.
   OPENSSL_NO_VENDOR = 1;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line application for interacting with git repositories";
     homepage = "https://github.com/Byron/gitoxide";
     license = with licenses; [ mit /* or */ asl20 ];
diff --git a/pkgs/applications/version-management/gitstats/default.nix b/pkgs/applications/version-management/gitstats/default.nix
index b7432385a232b..ccd13ba818b42 100644
--- a/pkgs/applications/version-management/gitstats/default.nix
+++ b/pkgs/applications/version-management/gitstats/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, perl, python, gnuplot, coreutils, gnugrep }:
+{ lib, stdenv, fetchzip, perl, python, gnuplot, coreutils, gnugrep }:
 
 stdenv.mkDerivation rec {
   pname = "gitstats";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     install -Dm644 doc/gitstats.1 "$out"/share/man/man1/gitstats.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gitstats.sourceforge.net/";
     description = "Git history statistics generator";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/version-management/gource/default.nix b/pkgs/applications/version-management/gource/default.nix
index 683ad8711bf03..048ad4036652b 100644
--- a/pkgs/applications/version-management/gource/default.nix
+++ b/pkgs/applications/version-management/gource/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL2, ftgl, pkgconfig, libpng, libjpeg, pcre
+{ lib, stdenv, fetchurl, SDL2, ftgl, pkgconfig, libpng, libjpeg, pcre
 , SDL2_image, freetype, glew, libGLU, libGL, boost, glm
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gource.io/";
     description = "A Software version control visualization tool";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/version-management/meld/default.nix b/pkgs/applications/version-management/meld/default.nix
index 5068dc15f48ab..ecad825dc8b08 100644
--- a/pkgs/applications/version-management/meld/default.nix
+++ b/pkgs/applications/version-management/meld/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gettext
 , itstool
@@ -59,7 +59,7 @@ python3.pkgs.buildPythonApplication rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Visual diff and merge tool";
     homepage = "http://meldmerge.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/version-management/monotone/default.nix b/pkgs/applications/version-management/monotone/default.nix
index bf8e5652d99c7..e08ea3c8cd8a0 100644
--- a/pkgs/applications/version-management/monotone/default.nix
+++ b/pkgs/applications/version-management/monotone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, boost, zlib, botan, libidn
+{ lib, stdenv, fetchurl, boost, zlib, botan, libidn
 , lua, pcre, sqlite, perl, pkgconfig, expect
 , bzip2, gmp, openssl
 }:
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
 
   #doCheck = true; # some tests fail (and they take VERY long)
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free distributed version control system";
     maintainers = [ maintainers.raskin ];
     platforms = platforms.unix;
diff --git a/pkgs/applications/version-management/peru/default.nix b/pkgs/applications/version-management/peru/default.nix
index 4cf2a2e864ca9..d7ad9060879ec 100644
--- a/pkgs/applications/version-management/peru/default.nix
+++ b/pkgs/applications/version-management/peru/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "peru";
@@ -18,7 +18,7 @@ python3Packages.buildPythonApplication rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/buildinspace/peru";
     description = "A tool for including other people's code in your projects";
     license = licenses.mit;
diff --git a/pkgs/applications/version-management/pijul/default.nix b/pkgs/applications/version-management/pijul/default.nix
index 4a64057cf11f4..a4b8be651176b 100644
--- a/pkgs/applications/version-management/pijul/default.nix
+++ b/pkgs/applications/version-management/pijul/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchCrate
 , rustPlatform
 , pkg-config
@@ -32,7 +32,7 @@ rustPlatform.buildRustPackage rec {
       CoreServices Security SystemConfiguration
     ]));
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A distributed version control system";
     homepage = "https://pijul.org";
     license = with licenses; [ gpl2Plus ];
diff --git a/pkgs/applications/version-management/redmine/default.nix b/pkgs/applications/version-management/redmine/default.nix
index 4279fdd5f995c..ab5b4ffded58c 100644
--- a/pkgs/applications/version-management/redmine/default.nix
+++ b/pkgs/applications/version-management/redmine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bundlerEnv, ruby, makeWrapper }:
+{ lib, stdenv, fetchurl, bundlerEnv, ruby, makeWrapper }:
 
 let
   version = "4.1.1";
@@ -42,7 +42,7 @@ in
       makeWrapper ${rubyEnv.wrappedRuby}/bin/ruby $out/bin/rdm-mailhandler.rb --add-flags $out/share/redmine/extra/mail_handler/rdm-mailhandler.rb
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.redmine.org/";
       platforms = platforms.linux;
       maintainers = [ maintainers.aanderse ];
diff --git a/pkgs/applications/version-management/sit/default.nix b/pkgs/applications/version-management/sit/default.nix
index 7a082033af48d..bd8d5db36be09 100644
--- a/pkgs/applications/version-management/sit/default.nix
+++ b/pkgs/applications/version-management/sit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, cmake, libzip, gnupg,
+{ lib, stdenv, fetchFromGitHub, rustPlatform, cmake, libzip, gnupg,
   # Darwin
   libiconv, CoreFoundation, Security }:
 
@@ -23,7 +23,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "092yfpr2svp1qy7xis1q0sdkbsjmmswmdwb0rklrc0yhydcsghp9";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Serverless Information Tracker";
     homepage = "https://sit.fyi/";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/applications/version-management/smartgithg/default.nix b/pkgs/applications/version-management/smartgithg/default.nix
index 51fe70d3952f4..f2bd4bf576bc8 100644
--- a/pkgs/applications/version-management/smartgithg/default.nix
+++ b/pkgs/applications/version-management/smartgithg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeDesktopItem
 , jre
@@ -84,7 +84,7 @@ stdenv.mkDerivation rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for Git, Mercurial, Subversion";
     homepage = "https://www.syntevo.com/smartgit/";
     license = licenses.unfree;
diff --git a/pkgs/applications/version-management/sourcehut/builds.nix b/pkgs/applications/version-management/sourcehut/builds.nix
index 493402bd2b133..200d1d5384fb2 100644
--- a/pkgs/applications/version-management/sourcehut/builds.nix
+++ b/pkgs/applications/version-management/sourcehut/builds.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , buildGoModule
 , srht, redis, celery, pyyaml, markdown }:
@@ -47,7 +47,7 @@ in buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/builds.sr.ht";
     description = "Continuous integration service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/core.nix b/pkgs/applications/version-management/sourcehut/core.nix
index 4252fac1165c5..bcc47920ebebc 100644
--- a/pkgs/applications/version-management/sourcehut/core.nix
+++ b/pkgs/applications/version-management/sourcehut/core.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchNodeModules, buildPythonPackage
+{ lib, stdenv, fetchgit, fetchNodeModules, buildPythonPackage
 , pgpy, flask, bleach, humanize, html5lib, markdown, psycopg2, pygments
 , requests, sqlalchemy, cryptography, beautifulsoup4, sqlalchemy-utils, prometheus_client
 , celery, alembic, importlib-metadata, mistletoe
@@ -61,7 +61,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/srht";
     description = "Core modules for sr.ht";
     license = licenses.bsd3;
diff --git a/pkgs/applications/version-management/sourcehut/dispatch.nix b/pkgs/applications/version-management/sourcehut/dispatch.nix
index 552b643951d0f..c7c11cafc8b4a 100644
--- a/pkgs/applications/version-management/sourcehut/dispatch.nix
+++ b/pkgs/applications/version-management/sourcehut/dispatch.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , srht, pyyaml, PyGithub }:
 
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://dispatch.sr.ht/~sircmpwn/dispatch.sr.ht";
     description = "Task dispatcher and service integration tool for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/git.nix b/pkgs/applications/version-management/sourcehut/git.nix
index 46870dab413a2..3ef49b796645e 100644
--- a/pkgs/applications/version-management/sourcehut/git.nix
+++ b/pkgs/applications/version-management/sourcehut/git.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , buildGoModule
 , srht, minio, pygit2, scmsrht }:
@@ -69,7 +69,7 @@ in buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/git.sr.ht";
     description = "Git repository hosting service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/hg.nix b/pkgs/applications/version-management/sourcehut/hg.nix
index 81c51324eb9cf..d0e1409084694 100644
--- a/pkgs/applications/version-management/sourcehut/hg.nix
+++ b/pkgs/applications/version-management/sourcehut/hg.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchhg, buildPythonPackage
+{ lib, stdenv, fetchhg, buildPythonPackage
 , python
 , srht, hglib, scmsrht, unidiff }:
 
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/hg.sr.ht";
     description = "Mercurial repository hosting service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/hub.nix b/pkgs/applications/version-management/sourcehut/hub.nix
index b3cf8f0a9fb14..8ea4961e7d453 100644
--- a/pkgs/applications/version-management/sourcehut/hub.nix
+++ b/pkgs/applications/version-management/sourcehut/hub.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , srht }:
 
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/hub.sr.ht";
     description = "Project hub service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/lists.nix b/pkgs/applications/version-management/sourcehut/lists.nix
index d15aada60166a..a0b52a2d56408 100644
--- a/pkgs/applications/version-management/sourcehut/lists.nix
+++ b/pkgs/applications/version-management/sourcehut/lists.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , srht, asyncpg, aiosmtpd, pygit2, emailthreads }:
 
@@ -28,7 +28,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/lists.sr.ht";
     description = "Mailing list service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/man.nix b/pkgs/applications/version-management/sourcehut/man.nix
index 9f00180ff1864..26939d2bebec9 100644
--- a/pkgs/applications/version-management/sourcehut/man.nix
+++ b/pkgs/applications/version-management/sourcehut/man.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , srht, pygit2 }:
 
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/man.sr.ht";
     description = "Wiki service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/meta.nix b/pkgs/applications/version-management/sourcehut/meta.nix
index 8887bdbb95643..b6622d97487e3 100644
--- a/pkgs/applications/version-management/sourcehut/meta.nix
+++ b/pkgs/applications/version-management/sourcehut/meta.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , buildGoModule
 , pgpy, srht, redis, bcrypt, qrcode, stripe, zxcvbn, alembic, pystache
@@ -50,7 +50,7 @@ in buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/meta.sr.ht";
     description = "Account management service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/paste.nix b/pkgs/applications/version-management/sourcehut/paste.nix
index e5bb5b379d145..eaec8b710dd68 100644
--- a/pkgs/applications/version-management/sourcehut/paste.nix
+++ b/pkgs/applications/version-management/sourcehut/paste.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , srht, pyyaml }:
 
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/paste.sr.ht";
     description = "Ad-hoc text file hosting service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/scm.nix b/pkgs/applications/version-management/sourcehut/scm.nix
index 08739f6d8ab95..6e8b03835bc40 100644
--- a/pkgs/applications/version-management/sourcehut/scm.nix
+++ b/pkgs/applications/version-management/sourcehut/scm.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , srht, redis, pyyaml, buildsrht
 , writeText }:
 
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~sircmpwn/git.sr.ht";
     description = "Shared support code for sr.ht source control services.";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/sourcehut/todo.nix b/pkgs/applications/version-management/sourcehut/todo.nix
index 7528ae534fae9..357dcd4d2e2a1 100644
--- a/pkgs/applications/version-management/sourcehut/todo.nix
+++ b/pkgs/applications/version-management/sourcehut/todo.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, buildPythonPackage
+{ lib, stdenv, fetchgit, buildPythonPackage
 , python
 , srht, redis, alembic, pystache
 , pytest, factory_boy, writeText }:
@@ -34,7 +34,7 @@ buildPythonPackage rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://todo.sr.ht/~sircmpwn/todo.sr.ht";
     description = "Ticket tracking service for the sr.ht network";
     license = licenses.agpl3;
diff --git a/pkgs/applications/version-management/src/default.nix b/pkgs/applications/version-management/src/default.nix
index 58549fed73a3b..cddcd3d8aa294 100644
--- a/pkgs/applications/version-management/src/default.nix
+++ b/pkgs/applications/version-management/src/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python, rcs, git, makeWrapper }:
+{ lib, stdenv, fetchurl, python, rcs, git, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "src";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
       --suffix PATH ":" "${rcs}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple single-file revision control";
     longDescription = ''
       SRC, acronym of Simple Revision Control, is RCS/SCCS reloaded with a
diff --git a/pkgs/applications/version-management/sublime-merge/common.nix b/pkgs/applications/version-management/sublime-merge/common.nix
index ad540c46411da..6ed644d050e23 100644
--- a/pkgs/applications/version-management/sublime-merge/common.nix
+++ b/pkgs/applications/version-management/sublime-merge/common.nix
@@ -1,6 +1,6 @@
 { buildVersion, sha256, dev ? false }:
 
-{ fetchurl, stdenv, xorg, glib, libGL, glibcLocales, gtk3, cairo, pango, libredirect, makeWrapper, wrapGAppsHook
+{ fetchurl, lib, stdenv, xorg, glib, libGL, glibcLocales, gtk3, cairo, pango, libredirect, makeWrapper, wrapGAppsHook
 , pkexecPath ? "/run/wrappers/bin/pkexec"
 , writeScript, common-updater-scripts, curl, gnugrep, coreutils
 }:
@@ -117,7 +117,7 @@ in stdenv.mkDerivation (rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Git client from the makers of Sublime Text";
     homepage = "https://www.sublimemerge.com";
     maintainers = with maintainers; [ zookatron ];
diff --git a/pkgs/applications/version-management/subversion/default.nix b/pkgs/applications/version-management/subversion/default.nix
index dffe3fadd74b0..66d22e9d71824 100644
--- a/pkgs/applications/version-management/subversion/default.nix
+++ b/pkgs/applications/version-management/subversion/default.nix
@@ -5,7 +5,7 @@
 , perlBindings ? false
 , javahlBindings ? false
 , saslSupport ? false
-, stdenv, fetchurl, apr, aprutil, zlib, sqlite, openssl, lz4, utf8proc
+, lib, stdenv, fetchurl, apr, aprutil, zlib, sqlite, openssl, lz4, utf8proc
 , apacheHttpd ? null, expat, swig ? null, jdk ? null, python ? null, perl ? null
 , sasl ? null, serf ? null
 }:
@@ -95,7 +95,7 @@ let
     checkInputs = [ python ];
     doCheck = false; # fails 10 out of ~2300 tests
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A version control system intended to be a compelling replacement for CVS in the open source community";
       license = licenses.asl20;
       homepage = "http://subversion.apache.org/";
diff --git a/pkgs/applications/version-management/vcprompt/default.nix b/pkgs/applications/version-management/vcprompt/default.nix
index 85fe83996da31..d98f94477256e 100644
--- a/pkgs/applications/version-management/vcprompt/default.nix
+++ b/pkgs/applications/version-management/vcprompt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchhg, autoconf, sqlite }:
+{ lib, stdenv, fetchhg, autoconf, sqlite }:
 
 stdenv.mkDerivation rec {
   pname = "vcprompt";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     makeFlags="$makeFlags PREFIX=$out"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A little C program that prints a short string with barebones information
       about the current working directory for various version control systems
diff --git a/pkgs/applications/version-management/vcsh/default.nix b/pkgs/applications/version-management/vcsh/default.nix
index c4af492decea9..e272342fe95dc 100644
--- a/pkgs/applications/version-management/vcsh/default.nix
+++ b/pkgs/applications/version-management/vcsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which, git, ronn, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, which, git, ronn, perlPackages }:
 
 stdenv.mkDerivation {
   version = "1.20170915";       # date of commit we're pulling
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   installPhase = "make install PREFIX=$out";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Version Control System for $HOME";
     homepage = "https://github.com/RichiH/vcsh";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/video/avidemux/default.nix b/pkgs/applications/video/avidemux/default.nix
index 2dd6b12c14f87..69e33f986a8d8 100644
--- a/pkgs/applications/video/avidemux/default.nix
+++ b/pkgs/applications/video/avidemux/default.nix
@@ -88,7 +88,7 @@ stdenv.mkDerivation rec {
     fixupPhase
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fixounet.free.fr/avidemux/";
     description = "Free video editor designed for simple video editing tasks";
     maintainers = with maintainers; [ abbradar ma27 ];
diff --git a/pkgs/applications/video/avxsynth/default.nix b/pkgs/applications/video/avxsynth/default.nix
index e818ef585c177..aed1bcef381d2 100644
--- a/pkgs/applications/video/avxsynth/default.nix
+++ b/pkgs/applications/video/avxsynth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , cairo, ffmpeg_3, ffms, libjpeg, log4cpp, pango
 , avxeditSupport ? false, qt4 ? null
 }:
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
   buildInputs = [ cairo ffmpeg_3 ffms libjpeg log4cpp pango ]
     ++ optional avxeditSupport qt4;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A script system that allows advanced non-linear editing";
     homepage = "https://github.com/avxsynth/avxsynth";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/video/bombono/default.nix b/pkgs/applications/video/bombono/default.nix
index 05ba5ef19be7b..7e366da437899 100644
--- a/pkgs/applications/video/bombono/default.nix
+++ b/pkgs/applications/video/bombono/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , fetchpatch
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a DVD authoring program for personal computers";
     homepage = "https://www.bombono.org/";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/video/byzanz/default.nix b/pkgs/applications/video/byzanz/default.nix
index f5d40a5c34cc5..705bac06eb652 100644
--- a/pkgs/applications/video/byzanz/default.nix
+++ b/pkgs/applications/video/byzanz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, wrapGAppsHook, which, gnome3, glib, intltool, pkgconfig, libtool, cairo, gtk3, gst_all_1, xorg }:
+{ lib, stdenv, fetchgit, wrapGAppsHook, which, gnome3, glib, intltool, pkgconfig, libtool, cairo, gtk3, gst_all_1, xorg }:
 
 stdenv.mkDerivation {
   version = "0.2.3.alpha";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
   buildInputs = [ which gnome3.gnome-common glib intltool libtool cairo gtk3 xorg.xwininfo ]
   ++ (with gst_all_1; [ gstreamer gst-plugins-base gst-plugins-bad gst-plugins-good gst-plugins-ugly gst-libav wrapGAppsHook ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to record a running X desktop to an animation suitable for presentation in a web browser";
     homepage = "https://github.com/GNOME/byzanz";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/celluloid/default.nix b/pkgs/applications/video/celluloid/default.nix
index ca9ecb48188c3..b59a40c03a23c 100644
--- a/pkgs/applications/video/celluloid/default.nix
+++ b/pkgs/applications/video/celluloid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple GTK frontend for the mpv video player";
     longDescription = ''
       GNOME MPV interacts with mpv via the client API exported by libmpv,
diff --git a/pkgs/applications/video/clipgrab/default.nix b/pkgs/applications/video/clipgrab/default.nix
index fa6cf88440f17..7fcd3fce64d4b 100644
--- a/pkgs/applications/video/clipgrab/default.nix
+++ b/pkgs/applications/video/clipgrab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, ffmpeg_3
+{ lib, stdenv, fetchurl, makeDesktopItem, ffmpeg_3
 , qmake, qttools, mkDerivation
 , qtbase, qtdeclarative, qtlocation, qtquickcontrols2, qtwebchannel, qtwebengine
 }:
@@ -42,7 +42,7 @@ mkDerivation rec {
     cp -r ${desktopItem}/share/applications $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Video downloader for YouTube and other sites";
     longDescription = ''
       ClipGrab is a free downloader and converter for YouTube, Vimeo, Metacafe,
diff --git a/pkgs/applications/video/devede/default.nix b/pkgs/applications/video/devede/default.nix
index 921548b5c08ce..4b1b7ae0b602c 100644
--- a/pkgs/applications/video/devede/default.nix
+++ b/pkgs/applications/video/devede/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, python3Packages, ffmpeg_3, mplayer, vcdimager, cdrkit, dvdauthor
+{ lib, stdenv, fetchFromGitLab, python3Packages, ffmpeg_3, mplayer, vcdimager, cdrkit, dvdauthor
 , gtk3, gettext, wrapGAppsHook, gdk-pixbuf, gobject-introspection }:
 
 let
@@ -44,7 +44,7 @@ in buildPythonApplication rec {
       --replace "/usr/local/share" "$out/share"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DVD Creator for Linux";
     homepage = "http://www.rastersoft.com/programas/devede.html";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/droidcam/default.nix b/pkgs/applications/video/droidcam/default.nix
index dc6c0d330eb24..807399408bad1 100644
--- a/pkgs/applications/video/droidcam/default.nix
+++ b/pkgs/applications/video/droidcam/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , ffmpeg, libjpeg_turbo, gtk3, alsaLib, speex, libusbmuxd, libappindicator-gtk3
 , pkg-config
 }:
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux client for DroidCam app";
     homepage = "https://github.com/aramg/droidcam";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/video/dvdauthor/default.nix b/pkgs/applications/video/dvdauthor/default.nix
index af1fe24cbbf47..6ea3a53a0af20 100644
--- a/pkgs/applications/video/dvdauthor/default.nix
+++ b/pkgs/applications/video/dvdauthor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, imagemagick, libdvdread, libxml2, freetype, fribidi, libpng, zlib, pkgconfig
+{ lib, stdenv, fetchurl, imagemagick, libdvdread, libxml2, freetype, fribidi, libpng, zlib, pkgconfig
 , flex, bison }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     ./dvdauthor-imagemagick-0.7.0.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for generating DVD files to be played on standalone DVD players";
     homepage = "http://dvdauthor.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/video/dvdstyler/default.nix b/pkgs/applications/video/dvdstyler/default.nix
index b78f9ed816b78..e3f7f8a0702b3 100644
--- a/pkgs/applications/video/dvdstyler/default.nix
+++ b/pkgs/applications/video/dvdstyler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , flex, bison, gettext
 , xineUI, wxSVG
 , fontconfig
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" "${binPath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A DVD authoring software";
     longDescription = ''
     DVDStyler is a cross-platform free DVD authoring application for the
diff --git a/pkgs/applications/video/electronplayer/electronplayer.nix b/pkgs/applications/video/electronplayer/electronplayer.nix
index 577c85c6b27c2..a4ebbf159b881 100644
--- a/pkgs/applications/video/electronplayer/electronplayer.nix
+++ b/pkgs/applications/video/electronplayer/electronplayer.nix
@@ -1,4 +1,4 @@
-{ appimageTools, stdenv, fetchurl }:
+{ appimageTools, lib, stdenv, fetchurl }:
 let
   pname = "electronplayer";
   version = "2.0.8";
@@ -23,7 +23,7 @@ in appimageTools.wrapType2 {
     cp -r ${appimageContents}/usr/share/icons $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An electron based web video services player";
     homepage = "https://github.com/oscartbeaumont/ElectronPlayer";
     license = licenses.mit;
diff --git a/pkgs/applications/video/filebot/default.nix b/pkgs/applications/video/filebot/default.nix
index e9ae14e19aa29..ba0627fc0fa11 100644
--- a/pkgs/applications/video/filebot/default.nix
+++ b/pkgs/applications/video/filebot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openjdk11, makeWrapper, autoPatchelfHook
+{ lib, stdenv, fetchurl, openjdk11, makeWrapper, autoPatchelfHook
 , zlib, libzen, libmediainfo, curl, libmms, glib
 }:
 
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     ln -s $out/opt/filebot.sh $out/bin/filebot
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The ultimate TV and Movie Renamer";
     longDescription = ''
       FileBot is the ultimate tool for organizing and renaming your Movies, TV
diff --git a/pkgs/applications/video/gnome-mplayer/default.nix b/pkgs/applications/video/gnome-mplayer/default.nix
index 3bd7785f201ca..88dfe5b4b87d2 100644
--- a/pkgs/applications/video/gnome-mplayer/default.nix
+++ b/pkgs/applications/video/gnome-mplayer/default.nix
@@ -1,4 +1,4 @@
-{stdenv, substituteAll, fetchFromGitHub, pkgconfig, gettext, glib, gtk3, gmtk, dbus, dbus-glib
+{lib, stdenv, substituteAll, fetchFromGitHub, pkgconfig, gettext, glib, gtk3, gmtk, dbus, dbus-glib
 , libnotify, libpulseaudio, mplayer, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnome MPlayer, a simple GUI for MPlayer";
     homepage = "https://sites.google.com/site/kdekorte2/gnomemplayer";
     license = licenses.gpl2;
diff --git a/pkgs/applications/video/gpac/default.nix b/pkgs/applications/video/gpac/default.nix
index aa66155d17ac5..906d119dfc50b 100644
--- a/pkgs/applications/video/gpac/default.nix
+++ b/pkgs/applications/video/gpac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, zlib }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, zlib }:
 
 stdenv.mkDerivation rec {
   version = "1.0.1";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open Source multimedia framework for research and academic purposes";
     longDescription = ''
       GPAC is an Open Source multimedia framework for research and academic purposes.
diff --git a/pkgs/applications/video/handbrake/default.nix b/pkgs/applications/video/handbrake/default.nix
index 1e4b83da8144a..16db55f060d20 100644
--- a/pkgs/applications/video/handbrake/default.nix
+++ b/pkgs/applications/video/handbrake/default.nix
@@ -131,7 +131,7 @@ _EOF
     cd build
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://handbrake.fr/";
     description = "A tool for converting video files and ripping DVDs";
     longDescription = ''
diff --git a/pkgs/applications/video/hdhomerun-config-gui/default.nix b/pkgs/applications/video/hdhomerun-config-gui/default.nix
index e1631150b8be6..b44da238d1e16 100644
--- a/pkgs/applications/video/hdhomerun-config-gui/default.nix
+++ b/pkgs/applications/video/hdhomerun-config-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libhdhomerun, gcc, gnumake, pkg-config, gtk2 }:
+{ lib, stdenv, fetchurl, libhdhomerun, gcc, gnumake, pkg-config, gtk2 }:
 
 stdenv.mkDerivation rec {
   pname = "hdhomerun-config-gui";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -vDm 755 src/hdhomerun_config_gui $out/usr/bin/hdhomerun_config_gui
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for configuring Silicondust HDHomeRun TV tuners";
     homepage = "https://www.silicondust.com/support/linux";
     license = licenses.gpl3Only;
diff --git a/pkgs/applications/video/jellyfin-mpv-shim/default.nix b/pkgs/applications/video/jellyfin-mpv-shim/default.nix
index 475b04c58620a..fe06e9431f9d3 100644
--- a/pkgs/applications/video/jellyfin-mpv-shim/default.nix
+++ b/pkgs/applications/video/jellyfin-mpv-shim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub, callPackage
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub, callPackage
 , mpv, python-mpv-jsonipc, jellyfin-apiclient-python
 , pillow, tkinter, pystray, jinja2, pywebview }:
 
@@ -57,7 +57,7 @@ buildPythonApplication rec {
   doCheck = false;
   pythonImportsCheck = [ "jellyfin_mpv_shim" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/iwalton3/jellyfin-mpv-shim";
     description = "Allows casting of videos to MPV via the jellyfin mobile and web app";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/jellyfin-mpv-shim/shader-pack.nix b/pkgs/applications/video/jellyfin-mpv-shim/shader-pack.nix
index fd33e8c90b52b..89a601af4add1 100644
--- a/pkgs/applications/video/jellyfin-mpv-shim/shader-pack.nix
+++ b/pkgs/applications/video/jellyfin-mpv-shim/shader-pack.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "jellyfin-mpv-shim-shader-pack";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp -a . $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/iwalton3/default-shader-pack";
     description = "Preconfigured set of MPV shaders and configurations for MPV Shim media clients";
     license = with licenses; [ mit lgpl3Plus unlicense ];
diff --git a/pkgs/applications/video/jftui/default.nix b/pkgs/applications/video/jftui/default.nix
index 04ed4c16e2bf9..b050e2636ccb3 100644
--- a/pkgs/applications/video/jftui/default.nix
+++ b/pkgs/applications/video/jftui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , curl
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     install -Dm555 build/jftui $out/bin/jftui
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jellyfin Terminal User Interface ";
     homepage = "https://github.com/Aanok/jftui";
     license = licenses.unlicense;
diff --git a/pkgs/applications/video/kazam/default.nix b/pkgs/applications/video/kazam/default.nix
index 0cdd3db852571..d47b5fddf88c0 100644
--- a/pkgs/applications/video/kazam/default.nix
+++ b/pkgs/applications/video/kazam/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll, python3, gst_all_1, wrapGAppsHook, gobject-introspection
+{ lib, stdenv, fetchurl, substituteAll, python3, gst_all_1, wrapGAppsHook, gobject-introspection
 , gtk3, libwnck3, keybinder3, intltool, libcanberra-gtk3, libappindicator-gtk3, libpulseaudio
 , fetchpatch }:
 
@@ -40,7 +40,7 @@ python3.pkgs.buildPythonApplication rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A screencasting program created with design in mind";
     homepage = "https://code.launchpad.net/kazam";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/video/kodi/default.nix b/pkgs/applications/video/kodi/default.nix
index b295e8922484e..4726c1b7b5162 100644
--- a/pkgs/applications/video/kodi/default.nix
+++ b/pkgs/applications/video/kodi/default.nix
@@ -282,7 +282,7 @@ in stdenv.mkDerivation {
       pythonPackages = python2Packages;
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Media center";
       homepage    = "https://kodi.tv/";
       license     = licenses.gpl2;
diff --git a/pkgs/applications/video/kodi/plugins.nix b/pkgs/applications/video/kodi/plugins.nix
index f957722ce7569..a0ef8b7e8feb8 100644
--- a/pkgs/applications/video/kodi/plugins.nix
+++ b/pkgs/applications/video/kodi/plugins.nix
@@ -1,4 +1,4 @@
-{ stdenv, callPackage, fetchFromGitHub
+{ lib, stdenv, callPackage, fetchFromGitHub
 , cmake, kodiPlain, libcec_platform, tinyxml, rapidxml
 , steam, udev, libusb1, jsoncpp, libhdhomerun, zlib
 , python2Packages, expat, glib, nspr, nss, openssl
@@ -519,7 +519,7 @@ let self = rec {
       sha256 = "044kkzcpzvbyih4vys33r4hqw38xa82snmvl4qj1r80wnszc8af1";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "SFTP Virtual Filesystem add-on for Kodi";
       license = licenses.gpl2Plus;
       platforms = platforms.all;
@@ -541,7 +541,7 @@ let self = rec {
       sha256 = "01qhv095h5j67ispm4iw18pd3kl7a0mnjkgm92al9qqiyif8lzgh";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "LibArchive Virtual Filesystem add-on for Kodi";
       license = licenses.gpl2Plus;
       platforms = platforms.all;
diff --git a/pkgs/applications/video/makemkv/default.nix b/pkgs/applications/video/makemkv/default.nix
index 47fb6fc9b1b83..35b0d41907b87 100644
--- a/pkgs/applications/video/makemkv/default.nix
+++ b/pkgs/applications/video/makemkv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchurl
 , autoPatchelfHook
@@ -58,7 +58,7 @@ in mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert blu-ray and dvd to mkv";
     longDescription = ''
       makemkv is a one-click QT application that transcodes an encrypted
diff --git a/pkgs/applications/video/mapmap/default.nix b/pkgs/applications/video/mapmap/default.nix
index 003da6e6a9416..284cc4ae58ac9 100644
--- a/pkgs/applications/video/mapmap/default.nix
+++ b/pkgs/applications/video/mapmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , qttools
@@ -67,7 +67,7 @@ mkDerivation rec {
   #   rm -r $NIX_BUILD_TOP/__nix_qt5__
   # '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source video mapping software";
     homepage = "https://github.com/mapmapteam/mapmap";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/mediathekview/default.nix b/pkgs/applications/video/mediathekview/default.nix
index 7c7ceb914ae77..6a8731dd72eb9 100644
--- a/pkgs/applications/video/mediathekview/default.nix
+++ b/pkgs/applications/video/mediathekview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 stdenv.mkDerivation rec {
   version = "13.5.1";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
       --add-flags "-Xmx1G -Djava.net.preferIPv4Stack=true -jar $out/lib/MediathekView.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Offers access to the Mediathek of different tv stations (ARD, ZDF, Arte, etc.)";
     homepage = "https://mediathekview.de/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/mjpg-streamer/default.nix b/pkgs/applications/video/mjpg-streamer/default.nix
index b6856f1a18e36..a82839ef7548c 100644
--- a/pkgs/applications/video/mjpg-streamer/default.nix
+++ b/pkgs/applications/video/mjpg-streamer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libjpeg }:
+{ lib, stdenv, fetchFromGitHub, cmake, libjpeg }:
 
 stdenv.mkDerivation {
   pname = "mjpg-streamer";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     patchelf --set-rpath "$(patchelf --print-rpath $out/bin/mjpg_streamer):$out/lib/mjpg-streamer" $out/bin/mjpg_streamer
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jacksonliam/mjpg-streamer";
     description = "Takes JPGs from Linux-UVC compatible webcams, filesystem or other input plugins and streams them as M-JPEG via HTTP to webbrowsers, VLC and other software";
     platforms = platforms.linux;
diff --git a/pkgs/applications/video/mkclean/default.nix b/pkgs/applications/video/mkclean/default.nix
index 36cd2206070c3..05f1efc0f6101 100644
--- a/pkgs/applications/video/mkclean/default.nix
+++ b/pkgs/applications/video/mkclean/default.nix
@@ -1,4 +1,4 @@
-{ dos2unix, fetchurl, stdenv }:
+{ dos2unix, fetchurl, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   pname = "mkclean";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     mv release/gcc_linux_*/* $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tool to clean and optimize Matroska (.mkv / .mka / .mks / .mk3d) and WebM (.webm / .weba) files that have already been muxed";
     homepage = "https://www.matroska.org";
     license = licenses.bsdOriginal;
diff --git a/pkgs/applications/video/mkvtoolnix/default.nix b/pkgs/applications/video/mkvtoolnix/default.nix
index 77bacea2a2323..9ad64e72fd3a5 100644
--- a/pkgs/applications/video/mkvtoolnix/default.nix
+++ b/pkgs/applications/video/mkvtoolnix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, pkgconfig, autoconf, automake, libiconv, drake
+{ lib, stdenv, fetchFromGitLab, pkgconfig, autoconf, automake, libiconv, drake
 , ruby, docbook_xsl, file, xdg_utils, gettext, expat, boost, libebml, zlib
 , fmt, libmatroska, libogg, libvorbis, flac, libxslt, cmark, pcre2
 , withGUI ? true
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     wrapQtApp $out/bin/mkvtoolnix-gui
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform tools for Matroska";
     homepage    = "http://www.bunkus.org/videotools/mkvtoolnix/";
     license     = licenses.gpl2;
diff --git a/pkgs/applications/video/motion/default.nix b/pkgs/applications/video/motion/default.nix
index e25101250411c..b37326471621b 100644
--- a/pkgs/applications/video/motion/default.nix
+++ b/pkgs/applications/video/motion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , ffmpeg, libjpeg, libmicrohttpd }:
 
 stdenv.mkDerivation rec {
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ffmpeg libjpeg libmicrohttpd ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Monitors the video signal from cameras";
     homepage = "https://motion-project.github.io/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/video/mpc-qt/default.nix b/pkgs/applications/video/mpc-qt/default.nix
index d9d02ce792dc8..7c4126bb37c6a 100644
--- a/pkgs/applications/video/mpc-qt/default.nix
+++ b/pkgs/applications/video/mpc-qt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitLab, fetchpatch, pkg-config, qmake, qtx11extras, qttools, mpv }:
+{ lib, stdenv, mkDerivation, fetchFromGitLab, fetchpatch, pkg-config, qmake, qtx11extras, qttools, mpv }:
 
 mkDerivation rec {
   pname = "mpc-qt";
@@ -24,7 +24,7 @@ mkDerivation rec {
 
   qmakeFlags = [ "QMAKE_LUPDATE=${qttools.dev}/bin/lupdate" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Media Player Classic Qute Theater";
     homepage = "https://gitlab.com/mpc-qt/mpc-qt";
     license = licenses.gpl2;
diff --git a/pkgs/applications/video/mpv/default.nix b/pkgs/applications/video/mpv/default.nix
index 02135fe52ed1f..8d487fecfdeca 100644
--- a/pkgs/applications/video/mpv/default.nix
+++ b/pkgs/applications/video/mpv/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv, fetchFromGitHub, fetchpatch
+{ config, lib, stdenv, fetchFromGitHub, fetchpatch
 , addOpenGLRunpath, docutils, perl, pkgconfig, python3, wafHook, which
 , ffmpeg, freefont_ttf, freetype, libass, libpthreadstubs, mujs
 , nv-codec-headers, lua, libuchardet, libiconv ? null
@@ -217,7 +217,7 @@ in stdenv.mkDerivation rec {
     addOpenGLRunpath $out/bin/mpv
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A media player that supports many video formats (MPlayer and mplayer2 fork)";
     homepage = "https://mpv.io";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/video/mpv/scripts/mpris.nix b/pkgs/applications/video/mpv/scripts/mpris.nix
index 5f2a21ea7e440..020c38c8b5766 100644
--- a/pkgs/applications/video/mpv/scripts/mpris.nix
+++ b/pkgs/applications/video/mpv/scripts/mpris.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchFromGitHub, pkgconfig, glib, mpv-unwrapped }:
+{ lib, stdenv, fetchpatch, fetchFromGitHub, pkgconfig, glib, mpv-unwrapped }:
 
 stdenv.mkDerivation rec {
   pname = "mpv-mpris";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
   stripDebugList = [ "share/mpv/scripts" ];
   passthru.scriptName = "mpris.so";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MPRIS plugin for mpv";
     homepage = "https://github.com/hoyon/mpv-mpris";
     license = licenses.mit;
diff --git a/pkgs/applications/video/mpv/scripts/simple-mpv-webui.nix b/pkgs/applications/video/mpv/scripts/simple-mpv-webui.nix
index d51434e241c9a..0c0597d3afb2c 100644
--- a/pkgs/applications/video/mpv/scripts/simple-mpv-webui.nix
+++ b/pkgs/applications/video/mpv/scripts/simple-mpv-webui.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub }:
 stdenv.mkDerivation rec {
   pname = "simple-mpv-ui";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   '';
   passthru.scriptName = "webui.lua";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A web based user interface with controls for the mpv mediaplayer";
     homepage = "https://github.com/open-dynaMIX/simple-mpv-webui";
     maintainers = [ maintainers.cript0nauta ];
diff --git a/pkgs/applications/video/mpv/scripts/sponsorblock.nix b/pkgs/applications/video/mpv/scripts/sponsorblock.nix
index 8213e514d2bab..79ede806b0ca1 100644
--- a/pkgs/applications/video/mpv/scripts/sponsorblock.nix
+++ b/pkgs/applications/video/mpv/scripts/sponsorblock.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, python3 }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, python3 }:
 
 # Usage: `pkgs.mpv.override { scripts = [ pkgs.mpvScripts.sponsorblock ]; }`
 stdenv.mkDerivation {
@@ -41,7 +41,7 @@ stdenv.mkDerivation {
 
   passthru.scriptName = "sponsorblock.lua";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "mpv script to skip sponsored segments of YouTube videos";
     homepage = "https://github.com/po5/mpv_sponsorblock";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/mythtv/default.nix b/pkgs/applications/video/mythtv/default.nix
index db8d192b75876..5a7896546442f 100644
--- a/pkgs/applications/video/mythtv/default.nix
+++ b/pkgs/applications/video/mythtv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, which, qtbase, qtwebkit, qtscript, xlibsWrapper
+{ lib, stdenv, mkDerivation, fetchFromGitHub, which, qtbase, qtwebkit, qtscript, xlibsWrapper
 , libpulseaudio, fftwSinglePrec , lame, zlib, libGLU, libGL, alsaLib, freetype
 , perl, pkgconfig , libsamplerate, libbluray, lzo, libX11, libXv, libXrandr, libXvMC, libXinerama, libXxf86vm
 , libXmu , yasm, libuuid, taglib, libtool, autoconf, automake, file, exiv2, linuxHeaders
@@ -32,7 +32,7 @@ mkDerivation rec {
   configureFlags = 
     [ "--dvb-path=${linuxHeaders}/include" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.mythtv.org/";
     description = "Open Source DVR";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/video/natron/default.nix b/pkgs/applications/video/natron/default.nix
index dede7d6b29e07..75d271c4878a6 100644
--- a/pkgs/applications/video/natron/default.nix
+++ b/pkgs/applications/video/natron/default.nix
@@ -114,7 +114,7 @@ stdenv.mkDerivation {
       --set PYTHONPATH "$PYTHONPATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Node-graph based, open-source compositing software";
     longDescription = ''
       Node-graph based, open-source compositing software. Similar in
diff --git a/pkgs/applications/video/obs-studio/default.nix b/pkgs/applications/video/obs-studio/default.nix
index cdecde6b869af..1f8357324ea39 100644
--- a/pkgs/applications/video/obs-studio/default.nix
+++ b/pkgs/applications/video/obs-studio/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv
+{ config, lib, stdenv
 , mkDerivation
 , fetchFromGitHub
 , addOpenGLRunpath
@@ -110,7 +110,7 @@ in mkDerivation rec {
       addOpenGLRunpath $out/lib/obs-plugins/*.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free and open source software for video recording and live streaming";
     longDescription = ''
       This project is a rewrite of what was formerly known as "Open Broadcaster
diff --git a/pkgs/applications/video/obs-studio/obs-ndi.nix b/pkgs/applications/video/obs-studio/obs-ndi.nix
index a250a365ac63b..d9867b1bb2d25 100644
--- a/pkgs/applications/video/obs-studio/obs-ndi.nix
+++ b/pkgs/applications/video/obs-studio/obs-ndi.nix
@@ -5,7 +5,7 @@
 # mkdir -p ~/.config/obs-studio/plugins/bin
 # ln -s ~/.nix-profile/lib/obs-plugins/obs-ndi.so ~/.config/obs-studio/plugins/bin/
 
-{ stdenv, fetchFromGitHub, obs-studio, cmake, qtbase, ndi }:
+{ lib, stdenv, fetchFromGitHub, obs-studio, cmake, qtbase, ndi }:
 
 stdenv.mkDerivation rec {
   pname = "obs-ndi";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     "-DCMAKE_CXX_FLAGS=-I${obs-studio.src}/UI/obs-frontend-api"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network A/V plugin for OBS Studio";
     homepage = "https://github.com/Palakis/obs-ndi";
     maintainers = with maintainers; [ peti jshcmpbll ];
diff --git a/pkgs/applications/video/obs-studio/wlrobs.nix b/pkgs/applications/video/obs-studio/wlrobs.nix
index 14bc80dd38809..eba1508387b76 100644
--- a/pkgs/applications/video/obs-studio/wlrobs.nix
+++ b/pkgs/applications/video/obs-studio/wlrobs.nix
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
     "-Duse_dmabuf=${lib.boolToString dmabufSupport}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An obs-studio plugin that allows you to screen capture on wlroots based wayland compositors";
     homepage = "https://hg.sr.ht/~scoopta/wlrobs";
     maintainers = with maintainers; [ grahamc ];
diff --git a/pkgs/applications/video/olive-editor/default.nix b/pkgs/applications/video/olive-editor/default.nix
index b1e70cd037c7e..9356e4676a2a3 100644
--- a/pkgs/applications/video/olive-editor/default.nix
+++ b/pkgs/applications/video/olive-editor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, which, qmake, mkDerivation,
+{ lib, stdenv, fetchFromGitHub, pkgconfig, which, qmake, mkDerivation,
   qtmultimedia, wrapQtAppsHook, frei0r, opencolorio, ffmpeg-full,
   CoreFoundation }:
 
@@ -27,7 +27,7 @@ mkDerivation rec {
     qtmultimedia
   ] ++ stdenv.lib.optional stdenv.isDarwin CoreFoundation;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Professional open-source NLE video editor";
     homepage = "https://www.olivevideoeditor.org/";
     downloadPage = "https://www.olivevideoeditor.org/download.php";
diff --git a/pkgs/applications/video/openshot-qt/default.nix b/pkgs/applications/video/openshot-qt/default.nix
index ede47ad061f68..f3c0187d9cb38 100644
--- a/pkgs/applications/video/openshot-qt/default.nix
+++ b/pkgs/applications/video/openshot-qt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivationWith, fetchFromGitHub, fetchpatch
+{ lib, stdenv, mkDerivationWith, fetchFromGitHub, fetchpatch
 , doxygen, python3Packages, libopenshot
 , wrapGAppsHook, gtk3
 , qtsvg }:
@@ -42,7 +42,7 @@ mkDerivationWith python3Packages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://openshot.org/";
     description = "Free, open-source video editor";
     longDescription = ''
diff --git a/pkgs/applications/video/peek/default.nix b/pkgs/applications/video/peek/default.nix
index 6ca5c5bed2129..17f9d20695ea7 100644
--- a/pkgs/applications/video/peek/default.nix
+++ b/pkgs/applications/video/peek/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/phw/peek";
     description = "Simple animated GIF screen recorder with an easy to use interface";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/pitivi/default.nix b/pkgs/applications/video/pitivi/default.nix
index 7aef0bfd0353f..c56878dea3511 100644
--- a/pkgs/applications/video/pitivi/default.nix
+++ b/pkgs/applications/video/pitivi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchurl
 , pkg-config
@@ -96,7 +96,7 @@ python3Packages.buildPythonApplication rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Non-Linear video editor utilizing the power of GStreamer";
     homepage = "http://pitivi.org/";
     longDescription = ''
diff --git a/pkgs/applications/video/plex-media-player/default.nix b/pkgs/applications/video/plex-media-player/default.nix
index 107fd5f599abd..5f7f62a409b23 100644
--- a/pkgs/applications/video/plex-media-player/default.nix
+++ b/pkgs/applications/video/plex-media-player/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, pkgconfig, cmake, python3, mkDerivation
+{ lib, stdenv, fetchFromGitHub, fetchurl, pkgconfig, cmake, python3, mkDerivation
 , libX11, libXrandr, qtbase, qtwebchannel, qtwebengine, qtx11extras
 , libvdpau, SDL2, mpv, libGL }:
 let
@@ -38,7 +38,7 @@ in mkDerivation rec {
 
   passthru.updateScript = ./update.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Streaming media player for Plex";
     license = licenses.gpl2;
     maintainers = with maintainers; [ ];
diff --git a/pkgs/applications/video/plex-mpv-shim/default.nix b/pkgs/applications/video/plex-mpv-shim/default.nix
index 5006bf8ddaa4c..7738dd99d215a 100644
--- a/pkgs/applications/video/plex-mpv-shim/default.nix
+++ b/pkgs/applications/video/plex-mpv-shim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub, mpv, requests, python-mpv-jsonipc }:
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub, mpv, requests, python-mpv-jsonipc }:
 
 buildPythonApplication rec {
   pname = "plex-mpv-shim";
@@ -16,7 +16,7 @@ buildPythonApplication rec {
   # does not contain tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/iwalton3/plex-mpv-shim";
     description = "Allows casting of videos to MPV via the Plex mobile and web app";
     license = licenses.mit;
diff --git a/pkgs/applications/video/pyca/default.nix b/pkgs/applications/video/pyca/default.nix
index 0fed17bb99997..bf54c0a2d6ccd 100644
--- a/pkgs/applications/video/pyca/default.nix
+++ b/pkgs/applications/video/pyca/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub, pycurl, dateutil, configobj, sqlalchemy, sdnotify, flask }:
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub, pycurl, dateutil, configobj, sqlalchemy, sdnotify, flask }:
 
 buildPythonApplication rec {
   pname = "pyca";
@@ -20,7 +20,7 @@ buildPythonApplication rec {
     flask
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fully functional Opencast capture agent written in Python";
     homepage = "https://github.com/opencast/pyCA";
     license = licenses.lgpl3;
diff --git a/pkgs/applications/video/qmediathekview/default.nix b/pkgs/applications/video/qmediathekview/default.nix
index 7556727a80d3c..0de021a82a182 100644
--- a/pkgs/applications/video/qmediathekview/default.nix
+++ b/pkgs/applications/video/qmediathekview/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, qtbase, qttools, xz, boost, qmake, pkgconfig }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, qtbase, qttools, xz, boost, qmake, pkgconfig }:
 
 mkDerivation rec {
   pname = "QMediathekView";
@@ -22,7 +22,7 @@ mkDerivation rec {
 
   installFlags = [ "INSTALL_ROOT=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An alternative Qt-based front-end for the database maintained by the MediathekView project";
     inherit (src.meta) homepage;
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/video/qmplay2/default.nix b/pkgs/applications/video/qmplay2/default.nix
index a873c9e72ea79..ecedd730094cd 100644
--- a/pkgs/applications/video/qmplay2/default.nix
+++ b/pkgs/applications/video/qmplay2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , cmake
@@ -58,7 +58,7 @@ in stdenv.mkDerivation {
     ln -s $out/bin/QMPlay2 $out/bin/qmplay2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zaps166/QMPlay2/";
     description = "Qt-based Multimedia player";
     longDescription = ''
diff --git a/pkgs/applications/video/qstopmotion/default.nix b/pkgs/applications/video/qstopmotion/default.nix
index dbb2128b50bf8..008e73cd6ed78 100644
--- a/pkgs/applications/video/qstopmotion/default.nix
+++ b/pkgs/applications/video/qstopmotion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchurl
 , qtbase
@@ -64,7 +64,7 @@ mkDerivation rec {
     grep -rl 'qwt' . | xargs sed -i 's@<qwt/qwt_slider.h>@<qwt_slider.h>@g'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.qstopmotion.org";
     description = "Create stopmotion animation with a (web)camera";
     longDescription = ''
diff --git a/pkgs/applications/video/shotcut/default.nix b/pkgs/applications/video/shotcut/default.nix
index 1b3ca28504821..bae6a0ac7f377 100644
--- a/pkgs/applications/video/shotcut/default.nix
+++ b/pkgs/applications/video/shotcut/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , mkDerivation
@@ -83,7 +83,7 @@ mkDerivation rec {
     rev-prefix = "v";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, open source, cross-platform video editor";
     longDescription = ''
       An official binary for Shotcut, which includes all the
diff --git a/pkgs/applications/video/simplescreenrecorder/default.nix b/pkgs/applications/video/simplescreenrecorder/default.nix
index 7176f5e2f09c5..b42e14121529f 100644
--- a/pkgs/applications/video/simplescreenrecorder/default.nix
+++ b/pkgs/applications/video/simplescreenrecorder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, alsaLib, ffmpeg_3, libjack2, libX11, libXext, qtx11extras
+{ lib, stdenv, mkDerivation, fetchurl, alsaLib, ffmpeg_3, libjack2, libX11, libXext, qtx11extras
 , libXfixes, libGLU, libGL, pkgconfig, libpulseaudio, qtbase, cmake, ninja
 }:
 
@@ -29,7 +29,7 @@ mkDerivation rec {
     libpulseaudio qtbase qtx11extras
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A screen recorder for Linux";
     homepage = "https://www.maartenbaert.be/simplescreenrecorder";
     license = licenses.gpl3;
diff --git a/pkgs/applications/video/streamlink-twitch-gui/bin.nix b/pkgs/applications/video/streamlink-twitch-gui/bin.nix
index 1c88e3324b974..bc265d3e786be 100644
--- a/pkgs/applications/video/streamlink-twitch-gui/bin.nix
+++ b/pkgs/applications/video/streamlink-twitch-gui/bin.nix
@@ -109,7 +109,7 @@ stdenv.mkDerivation rec {
     categories = "AudioVideo;Network;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twitch.tv browser for Streamlink";
     longDescription = "Browse Twitch.tv and watch streams in your videoplayer of choice";
     homepage = "https://streamlink.github.io/streamlink-twitch-gui/";
diff --git a/pkgs/applications/video/tivodecode/default.nix b/pkgs/applications/video/tivodecode/default.nix
index 33e04b77c4b47..706dbc187377a 100644
--- a/pkgs/applications/video/tivodecode/default.nix
+++ b/pkgs/applications/video/tivodecode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   version = "0.2pre4";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     sha256 = "1pww5r2iygscqn20a1cz9xbfh18p84a6a5ifg4h5nvyn9b63k23q";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts a .TiVo file (produced by TiVoToGo) to a normal MPEG file";
     homepage = "http://tivodecode.sourceforge.net";
     platforms = platforms.unix;
diff --git a/pkgs/applications/video/uvccapture/default.nix b/pkgs/applications/video/uvccapture/default.nix
index f52ffa923d28a..70c3baa0b811d 100644
--- a/pkgs/applications/video/uvccapture/default.nix
+++ b/pkgs/applications/video/uvccapture/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libjpeg }:
+{ lib, stdenv, fetchurl, libjpeg }:
 
 let
   debianPatches = fetchurl {
@@ -41,7 +41,7 @@ stdenv.mkDerivation {
     cp -v debian/uvccapture.1 "$out/share/man/man1/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Capture image from USB webcam at a specified interval";
     license = licenses.gpl2Plus;
     platforms = platforms.linux;
diff --git a/pkgs/applications/video/vdr/plugins.nix b/pkgs/applications/video/vdr/plugins.nix
index e72de8e61f205..55ac94d8c6c78 100644
--- a/pkgs/applications/video/vdr/plugins.nix
+++ b/pkgs/applications/video/vdr/plugins.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchgit, vdr, alsaLib, fetchFromGitHub
+{ lib, stdenv, fetchurl, fetchgit, vdr, alsaLib, fetchFromGitHub
 , libvdpau, libxcb, xcbutilwm, graphicsmagick, libav, pcre, xorgserver, ffmpeg_3
 , libiconv, boost, libgcrypt, perl, util-linux, groff, libva, xorg, ncurses
 , callPackage
@@ -37,7 +37,7 @@ in {
 
     makeFlags = [ "DESTDIR=$(out)" ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://www.saunalahti.fi/~rahrenbe/vdr/femon/";
       description = "DVB Frontend Status Monitor plugin for VDR";
       maintainers = [ maintainers.ck3d ];
@@ -72,7 +72,7 @@ in {
       rev = "d19657bae399e79df107e316ca40922d21393f80";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/pesintta/vdr-plugin-vaapidevice";
       description = "VDR SoftHDDevice Plug-in (with VA-API VPP additions)";
       maintainers = [ maintainers.ck3d ];
@@ -118,7 +118,7 @@ in {
 
     installFlags = buildFlags;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://projects.vdr-developer.org/projects/plg-markad";
       description = "Ein Programm zum automatischen Setzen von Schnittmarken bei Werbeeinblendungen während einer Sendung.";
       maintainers = [ maintainers.ck3d ];
@@ -166,7 +166,7 @@ in {
 
     outputs = [ "out" "man" ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://winni.vdr-developer.org/epgsearch";
       description = "Searchtimer and replacement of the VDR program menu";
       maintainers = [ maintainers.ck3d ];
@@ -193,7 +193,7 @@ in {
       sha256 = "0n7idpxqx7ayd63scl6xwdx828ik4kb2mwz0c30cfjnmnxxd45lw";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/FernetMenta/vdr-plugin-vnsiserver";
       description = "VDR plugin to handle KODI clients.";
       maintainers = [ maintainers.ck3d ];
@@ -228,7 +228,7 @@ in {
 
     installPhase = ":";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://projects.vdr-developer.org/projects/plg-text2skin";
       description = "VDR Text2Skin Plugin";
       maintainers = [ maintainers.ck3d ];
@@ -329,7 +329,7 @@ in {
 
     installFlags = [ "DESTDIR=$(out)" ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/jowi24/vdr-fritz";
       description = "A plugin for VDR to access AVMs Fritz Box routers";
       maintainers = [ maintainers.ck3d ];
diff --git a/pkgs/applications/video/vlc/default.nix b/pkgs/applications/video/vlc/default.nix
index 1c52a89e98d4c..559398677a416 100644
--- a/pkgs/applications/video/vlc/default.nix
+++ b/pkgs/applications/video/vlc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook
+{ lib, stdenv, fetchurl, autoreconfHook
 , libarchive, perl, xorg, libdvdnav, libbluray
 , zlib, a52dec, libmad, faad2, ffmpeg_3, alsaLib
 , pkgconfig, dbus, fribidi, freefont_ttf, libebml, libmatroska
@@ -100,7 +100,7 @@ stdenv.mkDerivation rec {
     sed -i 's|^#define CONFIGURE_LINE.*$|#define CONFIGURE_LINE "<removed>"|g' config.h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform media player and streaming server";
     homepage = "http://www.videolan.org/vlc/";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/applications/video/vokoscreen/default.nix b/pkgs/applications/video/vokoscreen/default.nix
index 94d0de20ccf7b..c0b6853cf3290 100644
--- a/pkgs/applications/video/vokoscreen/default.nix
+++ b/pkgs/applications/video/vokoscreen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, mkDerivation
+{ lib, stdenv, fetchFromGitHub, mkDerivation
 , pkgconfig, qtbase, qttools, qmake, qtmultimedia, qtx11extras, alsaLib, libv4l, libXrandr
 , ffmpeg
 }:
@@ -38,7 +38,7 @@ mkDerivation rec {
     substituteInPlace settings/QvkSettings.cpp --subst-var-by ffmpeg ${ffmpeg}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple GUI screencast recorder, using ffmpeg";
     homepage = "https://linuxecke.volkoh.de/vokoscreen/vokoscreen.html";
     longDescription = ''
diff --git a/pkgs/applications/video/webtorrent_desktop/default.nix b/pkgs/applications/video/webtorrent_desktop/default.nix
index 961cb403f13c2..6b97fa63e0beb 100644
--- a/pkgs/applications/video/webtorrent_desktop/default.nix
+++ b/pkgs/applications/video/webtorrent_desktop/default.nix
@@ -2,7 +2,7 @@
   alsaLib, atk, cairo, cups, dbus, dpkg, expat, fetchurl, fetchzip, fontconfig, freetype,
   gdk-pixbuf, glib, gnome3, libX11, libXScrnSaver, libXcomposite, libXcursor,
   libXdamage, libXext, libXfixes, libXi, libXrandr, libXrender, libXtst,
-  libxcb, nspr, nss, stdenv, udev, libuuid, pango, at-spi2-atk, at-spi2-core
+  libxcb, nspr, nss, lib, stdenv, udev, libuuid, pango, at-spi2-atk, at-spi2-core
 }:
 
   let
@@ -84,7 +84,7 @@
         --replace /opt/webtorrent-desktop $out/libexec
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Streaming torrent app for Mac, Windows, and Linux";
       homepage = "https://webtorrent.io/desktop";
       license = licenses.mit;
diff --git a/pkgs/applications/video/wf-recorder/default.nix b/pkgs/applications/video/wf-recorder/default.nix
index 09b67149f5a93..0b8d1ad22b9fe 100644
--- a/pkgs/applications/video/wf-recorder/default.nix
+++ b/pkgs/applications/video/wf-recorder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkg-config, wayland, scdoc
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkg-config, wayland, scdoc
 , wayland-protocols, ffmpeg, x264, libpulseaudio, ocl-icd, opencl-headers
 }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     wayland-protocols ffmpeg x264 libpulseaudio ocl-icd opencl-headers
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility program for screen recording of wlroots-based compositors";
     inherit (src.meta) homepage;
     changelog = "https://github.com/ammen99/wf-recorder/releases/tag/v${version}";
diff --git a/pkgs/applications/video/wxcam/default.nix b/pkgs/applications/video/wxcam/default.nix
index 32712d5b9b07a..9294c4d2cde17 100644
--- a/pkgs/applications/video/wxcam/default.nix
+++ b/pkgs/applications/video/wxcam/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , pkgconfig
 , intltool
 , libX11, libXv, libSM
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     make install prefix="$out" wxcamdocdir="$out/share/doc/wxcam"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open-source, wxGTK-based webcam app for Linux";
     longDescription = ''
     wxCam is a webcam application for linux. It supports video recording
diff --git a/pkgs/applications/video/xine-ui/default.nix b/pkgs/applications/video/xine-ui/default.nix
index f52db04928a4b..c11d77c297447 100644
--- a/pkgs/applications/video/xine-ui/default.nix
+++ b/pkgs/applications/video/xine-ui/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, pkgconfig, xorg, libpng, xineLib, readline, ncurses, curl
+{lib, stdenv, fetchurl, pkgconfig, xorg, libpng, xineLib, readline, ncurses, curl
 , lirc, shared-mime-info, libjpeg }:
 
 stdenv.mkDerivation rec {
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
   LIRC_LIBS="-L ${lirc}/lib -llirc_client";
 #NIX_LDFLAGS = "-lXext -lgcc_s";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.xine-project.org/";
     description = "Xlib-based interface to Xine, a video player";
     platforms = platforms.linux;
diff --git a/pkgs/applications/video/xscast/default.nix b/pkgs/applications/video/xscast/default.nix
index f9e6a3d6521f3..050b5b32b1988 100644
--- a/pkgs/applications/video/xscast/default.nix
+++ b/pkgs/applications/video/xscast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, ffmpeg_3, imagemagick, dzen2, xorg }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, ffmpeg_3, imagemagick, dzen2, xorg }:
 
 stdenv.mkDerivation {
   pname = "xscast-unstable";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/KeyboardFire/xscast";
     license = licenses.mit;
     description = "Screencasts of windows with list of keystrokes overlayed";
diff --git a/pkgs/applications/video/xvidcap/default.nix b/pkgs/applications/video/xvidcap/default.nix
index 20d4d84741ccd..0f7f9390daca6 100644
--- a/pkgs/applications/video/xvidcap/default.nix
+++ b/pkgs/applications/video/xvidcap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, pkgconfig, gtk2
+{ lib, stdenv, fetchurl, perlPackages, pkgconfig, gtk2
 , scrollkeeper, libglade, libXmu, libX11, libXext, gettext
 , lame, libXfixes, libXdamage }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
   # !!! don't know why this is necessary
   NIX_LDFLAGS = "-lXext -lX11 -lz -lgcc_s";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Screencast video catpuring tool";
     homepage = "http://xvidcap.sourceforge.net/";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/applications/virtualization/8086tiny/default.nix b/pkgs/applications/virtualization/8086tiny/default.nix
index db76efb96e5f8..addab70c3b3de 100644
--- a/pkgs/applications/virtualization/8086tiny/default.nix
+++ b/pkgs/applications/virtualization/8086tiny/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , localBios ? true, nasm ? null
 , sdlSupport ? true, SDL ? null }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   
   builder = ./builder.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open-source small 8086 emulator";
     longDescription = ''
       8086tiny is a tiny, open-source (MIT), portable (little-endian hosts)
diff --git a/pkgs/applications/virtualization/aqemu/default.nix b/pkgs/applications/virtualization/aqemu/default.nix
index 9177f26450283..d31523e946ac9 100644
--- a/pkgs/applications/virtualization/aqemu/default.nix
+++ b/pkgs/applications/virtualization/aqemu/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, cmake, fetchFromGitHub, libvncserver, qemu, qtbase, stdenv
+{ mkDerivation, cmake, fetchFromGitHub, libvncserver, qemu, qtbase, lib, stdenv
 }:
 
 mkDerivation rec {
@@ -16,7 +16,7 @@ mkDerivation rec {
 
   buildInputs = [ libvncserver qtbase qemu ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A virtual machine manager GUI for qemu";
     homepage = "https://github.com/tobimensch/aqemu";
     license = licenses.gpl2;
diff --git a/pkgs/applications/virtualization/cntr/default.nix b/pkgs/applications/virtualization/cntr/default.nix
index ab9b63eb79b24..f7b7c99b5540a 100644
--- a/pkgs/applications/virtualization/cntr/default.nix
+++ b/pkgs/applications/virtualization/cntr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cntr";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "sha256-lblvun2T1qpFiowld77Ti2MFPzhs5pOWWRbErORXYCM=";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A container debugging tool based on FUSE";
     homepage = "https://github.com/Mic92/cntr";
     license = licenses.mit;
diff --git a/pkgs/applications/virtualization/conmon/default.nix b/pkgs/applications/virtualization/conmon/default.nix
index e143ebcca7557..2afb1e7874fdc 100644
--- a/pkgs/applications/virtualization/conmon/default.nix
+++ b/pkgs/applications/virtualization/conmon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , glib
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests = { inherit (nixosTests) cri-o podman; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/containers/conmon";
     description = "An OCI container runtime monitor";
     license = licenses.asl20;
diff --git a/pkgs/applications/virtualization/cri-o/default.nix b/pkgs/applications/virtualization/cri-o/default.nix
index 54ffb036f3c38..7914fd243270d 100644
--- a/pkgs/applications/virtualization/cri-o/default.nix
+++ b/pkgs/applications/virtualization/cri-o/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , btrfs-progs
 , buildGoModule
 , fetchFromGitHub
@@ -56,7 +56,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests) cri-o; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://cri-o.io";
     description = ''
       Open Container Initiative-based implementation of the
diff --git a/pkgs/applications/virtualization/docker-compose/default.nix b/pkgs/applications/virtualization/docker-compose/default.nix
index 766c81d6befee..e9e6092e1f9b4 100644
--- a/pkgs/applications/virtualization/docker-compose/default.nix
+++ b/pkgs/applications/virtualization/docker-compose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonApplication, fetchPypi, pythonOlder
 , installShellFiles
 , mock, pytest, nose
 , pyyaml, backports_ssl_match_hostname, colorama, docopt
@@ -39,7 +39,7 @@ buildPythonApplication rec {
     installShellCompletion --zsh contrib/completion/zsh/_docker-compose
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.docker.com/compose/";
     description = "Multi-container orchestration for Docker";
     license = licenses.asl20;
diff --git a/pkgs/applications/virtualization/docker-slim/default.nix b/pkgs/applications/virtualization/docker-slim/default.nix
index 9ba7ff5d66bc3..6c1ef95cd6f79 100644
--- a/pkgs/applications/virtualization/docker-slim/default.nix
+++ b/pkgs/applications/virtualization/docker-slim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoPackage
 , fetchFromGitHub
 , makeWrapper
@@ -36,7 +36,7 @@ buildGoPackage rec {
     wrapProgram "$out/bin/docker-slim" --add-flags '--state-path "$(pwd)"'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minify and secure Docker containers";
     homepage = "https://dockersl.im/";
     changelog = "https://github.com/docker-slim/docker-slim/blob/${version}/CHANGELOG.md";
diff --git a/pkgs/applications/virtualization/docker/distribution.nix b/pkgs/applications/virtualization/docker/distribution.nix
index a408d20f3ba0a..f41862c0dd15a 100644
--- a/pkgs/applications/virtualization/docker/distribution.nix
+++ b/pkgs/applications/virtualization/docker/distribution.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "distribution";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "1nx8b5a68rn81alp8wkkw6qd5v32mgf0fk23mxm60zdf63qk1nzw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Docker toolset to pack, ship, store, and deliver content";
     license = licenses.asl20;
     maintainers = [ maintainers.globin ];
diff --git a/pkgs/applications/virtualization/docker/proxy.nix b/pkgs/applications/virtualization/docker/proxy.nix
index cb3518d7d3da1..4859054d78d1d 100644
--- a/pkgs/applications/virtualization/docker/proxy.nix
+++ b/pkgs/applications/virtualization/docker/proxy.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   name = "docker-proxy-${rev}";
@@ -19,7 +19,7 @@ buildGoPackage rec {
     install -m755 -D ./go/bin/proxy $out/bin/docker-proxy
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Docker proxy binary to forward traffic between host and containers";
     license = licenses.asl20;
     homepage = "https://github.com/docker/libnetwork";
diff --git a/pkgs/applications/virtualization/driver/win-pvdrivers/default.nix b/pkgs/applications/virtualization/driver/win-pvdrivers/default.nix
index faa1076e2998c..e772a540b1836 100644
--- a/pkgs/applications/virtualization/driver/win-pvdrivers/default.nix
+++ b/pkgs/applications/virtualization/driver/win-pvdrivers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit }:
+{ lib, stdenv, fetchgit }:
 
 stdenv.mkDerivation  {
   name = "win-pvdrivers-git-20150701";
@@ -20,7 +20,7 @@ stdenv.mkDerivation  {
     cp -r amd64 $out/.
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Xen Subproject: Windows PV Driver";
     homepage = "http://xenproject.org/downloads/windows-pv-drivers.html";
     maintainers = [ maintainers.tstrobel ];
diff --git a/pkgs/applications/virtualization/driver/win-qemu/default.nix b/pkgs/applications/virtualization/driver/win-qemu/default.nix
index 97a1f0b3039b7..d8e233e352320 100644
--- a/pkgs/applications/virtualization/driver/win-qemu/default.nix
+++ b/pkgs/applications/virtualization/driver/win-qemu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, p7zip }:
+{ lib, stdenv, fetchurl, p7zip }:
 
 stdenv.mkDerivation  {
   name = "win-qemu-0.1.105-1";
@@ -28,7 +28,7 @@ stdenv.mkDerivation  {
     in
       (copy "amd64" "w8.1") + (copy "x86" "w8.1");
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Windows QEMU Drivers";
     homepage = "https://fedoraproject.org/wiki/Windows_Virtio_Drivers";
     maintainers = [ maintainers.tstrobel ];
diff --git a/pkgs/applications/virtualization/driver/win-signed-gplpv-drivers/default.nix b/pkgs/applications/virtualization/driver/win-signed-gplpv-drivers/default.nix
index c4684a20914fd..c4c5cb807284b 100644
--- a/pkgs/applications/virtualization/driver/win-signed-gplpv-drivers/default.nix
+++ b/pkgs/applications/virtualization/driver/win-signed-gplpv-drivers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, p7zip }:
+{ lib, stdenv, fetchurl, p7zip }:
 
 let
   src_x86 = fetchurl {
@@ -31,7 +31,7 @@ stdenv.mkDerivation  {
     cp amd64/* $out/amd64/.
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A collection of open source Window PV drivers that allow
       Windows to be para-virtualized.
diff --git a/pkgs/applications/virtualization/driver/win-spice/default.nix b/pkgs/applications/virtualization/driver/win-spice/default.nix
index f327512b128e1..ba823fa2a41c1 100644
--- a/pkgs/applications/virtualization/driver/win-spice/default.nix
+++ b/pkgs/applications/virtualization/driver/win-spice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, p7zip, win-virtio }:
+{ lib, stdenv, fetchurl, p7zip, win-virtio }:
 
 let
   src_usbdk_x86 = fetchurl {
@@ -60,7 +60,7 @@ stdenv.mkDerivation  {
     in
       (copy "amd64" "w8.1") + (copy "x86" "w8.1");
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Windows SPICE Drivers";
     homepage = "https://www.spice-space.org/";
     license = [ licenses.asl20 ]; # See https://github.com/vrozenfe/qxl-dod
diff --git a/pkgs/applications/virtualization/driver/win-virtio/default.nix b/pkgs/applications/virtualization/driver/win-virtio/default.nix
index f8a52f5b898d5..565fc4cf533b8 100644
--- a/pkgs/applications/virtualization/driver/win-virtio/default.nix
+++ b/pkgs/applications/virtualization/driver/win-virtio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, p7zip }:
+{ lib, stdenv, fetchurl, p7zip }:
 stdenv.mkDerivation rec {
   pname = "win-virtio";
   version = "0.1.141-1";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     in
       stdenv.lib.concatStringsSep "\n" ((map (copy "amd64" "w8.1") virtio) ++ (map (copy "x86" "w8.1") virtio));
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Windows VirtIO Drivers";
     homepage = "https://fedoraproject.org/wiki/Windows_Virtio_Drivers";
     maintainers = [ maintainers.tstrobel ];
diff --git a/pkgs/applications/virtualization/dumb-init/default.nix b/pkgs/applications/virtualization/dumb-init/default.nix
index 3d4df33300ed2..80a76432f08b2 100644
--- a/pkgs/applications/virtualization/dumb-init/default.nix
+++ b/pkgs/applications/virtualization/dumb-init/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glibc }:
+{ lib, stdenv, fetchFromGitHub, glibc }:
 
 stdenv.mkDerivation rec {
   pname = "dumb-init";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal init system for Linux containers";
     homepage = "https://github.com/Yelp/dumb-init";
     license = licenses.mit;
diff --git a/pkgs/applications/virtualization/dynamips/default.nix b/pkgs/applications/virtualization/dynamips/default.nix
index 6f35257b50fd3..7f3320101530c 100644
--- a/pkgs/applications/virtualization/dynamips/default.nix
+++ b/pkgs/applications/virtualization/dynamips/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libelf, libpcap }:
+{ lib, stdenv, fetchFromGitHub, cmake, libelf, libpcap }:
 
 stdenv.mkDerivation rec {
   pname = "dynamips";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DDYNAMIPS_CODE=stable" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Cisco router emulator";
     longDescription = ''
       Dynamips is an emulator computer program that was written to emulate Cisco
diff --git a/pkgs/applications/virtualization/ecs-agent/default.nix b/pkgs/applications/virtualization/ecs-agent/default.nix
index 691c74301e393..41a0931533310 100644
--- a/pkgs/applications/virtualization/ecs-agent/default.nix
+++ b/pkgs/applications/virtualization/ecs-agent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage }:
 
 buildGoPackage rec {
   pname   = "amazon-ecs-agent";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "1l6c2if6wpjmq2hh6k818w38s1rsbwgd6igqy948dwcrb1g1mixr";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The agent that runs on AWS EC2 container instances and starts containers on behalf of Amazon ECS";
     homepage    = "https://github.com/aws/amazon-ecs-agent";
     license     = licenses.asl20;
diff --git a/pkgs/applications/virtualization/firecracker/default.nix b/pkgs/applications/virtualization/firecracker/default.nix
index 98b95fa2bec3f..f041ea7460c18 100644
--- a/pkgs/applications/virtualization/firecracker/default.nix
+++ b/pkgs/applications/virtualization/firecracker/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv }:
+{ fetchurl, lib, stdenv }:
 
 let
   version = "0.23.0";
@@ -51,7 +51,7 @@ stdenv.mkDerivation {
     install -D jailer      $out/bin/jailer
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Secure, fast, minimal micro-container virtualization";
     homepage    = "http://firecracker-microvm.io";
     license     = licenses.asl20;
diff --git a/pkgs/applications/virtualization/firectl/default.nix b/pkgs/applications/virtualization/firectl/default.nix
index 523e96f347cc6..0b5fc5dac52b1 100644
--- a/pkgs/applications/virtualization/firectl/default.nix
+++ b/pkgs/applications/virtualization/firectl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "firectl";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line tool to run Firecracker microVMs";
     homepage = "https://github.com/firecracker-microvm/firectl";
     license = licenses.asl20;
diff --git a/pkgs/applications/virtualization/gvisor/default.nix b/pkgs/applications/virtualization/gvisor/default.nix
index 576f2d9e6f23e..54cf8094d6465 100644
--- a/pkgs/applications/virtualization/gvisor/default.nix
+++ b/pkgs/applications/virtualization/gvisor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildBazelPackage
 , fetchFromGitHub
 , cacert
@@ -91,7 +91,7 @@ in buildBazelPackage rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Container Runtime Sandbox";
     homepage = "https://github.com/google/gvisor";
     license = licenses.asl20;
diff --git a/pkgs/applications/virtualization/hercules/default.nix b/pkgs/applications/virtualization/hercules/default.nix
index 8746e66668ff2..f33055baacbcb 100644
--- a/pkgs/applications/virtualization/hercules/default.nix
+++ b/pkgs/applications/virtualization/hercules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "hercules";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0zg6rwz8ib4alibf8lygi8qn69xx8n92kbi8b3jhi1ymb32mf349";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IBM mainframe emulator";
     homepage = "http://www.hercules-390.eu";
     license = licenses.qpl;
diff --git a/pkgs/applications/virtualization/lkl/default.nix b/pkgs/applications/virtualization/lkl/default.nix
index 7a6ccc67bb50d..aee2d493a7061 100644
--- a/pkgs/applications/virtualization/lkl/default.nix
+++ b/pkgs/applications/virtualization/lkl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bc, python, bison, flex, fuse, libarchive
+{ lib, stdenv, fetchFromGitHub, bc, python, bison, flex, fuse, libarchive
 , buildPackages }:
 
 stdenv.mkDerivation rec {
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Linux kernel as a library";
     longDescription = ''
       LKL (Linux Kernel Library) aims to allow reusing the Linux kernel code as
diff --git a/pkgs/applications/virtualization/looking-glass-client/default.nix b/pkgs/applications/virtualization/looking-glass-client/default.nix
index 74370aafa40ed..e7c8cc4d47a8e 100644
--- a/pkgs/applications/virtualization/looking-glass-client/default.nix
+++ b/pkgs/applications/virtualization/looking-glass-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, SDL2, SDL2_ttf, spice-protocol
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, SDL2, SDL2_ttf, spice-protocol
 , fontconfig, libX11, freefont_ttf, nettle, libpthreadstubs, libXau, libXdmcp
 , libXi, libXext, wayland, libffi, libGLU, expat, libbfd
 }:
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
   sourceRoot = "source/client";
   NIX_CFLAGS_COMPILE = "-mavx"; # Fix some sort of AVX compiler problem.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A KVM Frame Relay (KVMFR) implementation";
     longDescription = ''
       Looking Glass is an open source application that allows the use of a KVM
diff --git a/pkgs/applications/virtualization/open-vm-tools/default.nix b/pkgs/applications/virtualization/open-vm-tools/default.nix
index 4cdce2172a211..a5c8d97693243 100644
--- a/pkgs/applications/virtualization/open-vm-tools/default.nix
+++ b/pkgs/applications/virtualization/open-vm-tools/default.nix
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ':' "${lib.makeBinPath [ iproute dbus systemd which ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/vmware/open-vm-tools";
     description = "Set of tools for VMWare guests to improve host-guest interaction";
     longDescription = ''
diff --git a/pkgs/applications/virtualization/podman/default.nix b/pkgs/applications/virtualization/podman/default.nix
index cd32c80f74ebd..39097c8e5b3bf 100644
--- a/pkgs/applications/virtualization/podman/default.nix
+++ b/pkgs/applications/virtualization/podman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , installShellFiles
@@ -62,7 +62,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests) podman; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://podman.io/";
     description = "A program for managing pods, containers and container images";
     license = licenses.asl20;
diff --git a/pkgs/applications/virtualization/qemu/default.nix b/pkgs/applications/virtualization/qemu/default.nix
index 5d4b891ad5de2..44dff9ad42a17 100644
--- a/pkgs/applications/virtualization/qemu/default.nix
+++ b/pkgs/applications/virtualization/qemu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, python, zlib, pkgconfig, glib
+{ lib, stdenv, fetchurl, fetchpatch, python, zlib, pkgconfig, glib
 , perl, pixman, vde2, alsaLib, texinfo, flex
 , bison, lzo, snappy, libaio, gnutls, nettle, curl
 , makeWrapper
@@ -6,7 +6,7 @@
 , CoreServices, Cocoa, Hypervisor, rez, setfile
 , numaSupport ? stdenv.isLinux && !stdenv.isAarch32, numactl
 , seccompSupport ? stdenv.isLinux, libseccomp
-, alsaSupport ? stdenv.lib.hasSuffix "linux" stdenv.hostPlatform.system && !nixosTestRunner
+, alsaSupport ? lib.hasSuffix "linux" stdenv.hostPlatform.system && !nixosTestRunner
 , pulseSupport ? !stdenv.isDarwin && !nixosTestRunner, libpulseaudio
 , sdlSupport ? !stdenv.isDarwin && !nixosTestRunner, SDL2
 , gtkSupport ? !stdenv.isDarwin && !xenSupport && !nixosTestRunner, gtk3, gettext, vte, wrapGAppsHook
@@ -23,7 +23,7 @@
 , tpmSupport ? true
 , hostCpuOnly ? false
 , hostCpuTargets ? (if hostCpuOnly
-                    then (stdenv.lib.optional stdenv.isx86_64 "i386-softmmu"
+                    then (lib.optional stdenv.isx86_64 "i386-softmmu"
                           ++ ["${stdenv.hostPlatform.qemuArch}-softmmu"])
                     else null)
 , nixosTestRunner ? false
@@ -180,7 +180,7 @@ stdenv.mkDerivation rec {
     qemu-system-i386 = "bin/qemu-system-i386";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.qemu.org/";
     description = "A generic and open source machine emulator and virtualizer";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/virtualization/qtemu/default.nix b/pkgs/applications/virtualization/qtemu/default.nix
index 29f0004be830b..4c0f441d78199 100644
--- a/pkgs/applications/virtualization/qtemu/default.nix
+++ b/pkgs/applications/virtualization/qtemu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitLab, pkgconfig, qmake, qtbase, qemu, makeWrapper }:
+{ lib, stdenv, mkDerivation, fetchFromGitLab, pkgconfig, qmake, qtbase, qemu, makeWrapper }:
 
 mkDerivation rec {
   pname = "qtemu";
@@ -35,7 +35,7 @@ mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt-based front-end for QEMU emulator";
     homepage = "https://qtemu.org";
     license = licenses.gpl2;
diff --git a/pkgs/applications/virtualization/remotebox/default.nix b/pkgs/applications/virtualization/remotebox/default.nix
index dcc5efb6504a7..fa4f105f6e838 100644
--- a/pkgs/applications/virtualization/remotebox/default.nix
+++ b/pkgs/applications/virtualization/remotebox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, perl, perlPackages }:
+{ lib, stdenv, fetchurl, makeWrapper, perl, perlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "remotebox";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     cp -pv packagers-readme/*.desktop $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VirtualBox client with remote management";
     homepage = "http://remotebox.knobgoblin.org.uk/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/virtualization/seabios/default.nix b/pkgs/applications/virtualization/seabios/default.nix
index cd03759045a0a..f97f13dab2a44 100644
--- a/pkgs/applications/virtualization/seabios/default.nix
+++ b/pkgs/applications/virtualization/seabios/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, iasl, python }:
+{ lib, stdenv, fetchurl, iasl, python }:
 
 stdenv.mkDerivation rec {
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     cp out/Csm16.bin $out/Csm16.bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source implementation of a 16bit X86 BIOS";
     longDescription = ''
       SeaBIOS is an open source implementation of a 16bit X86 BIOS.
diff --git a/pkgs/applications/virtualization/singularity/default.nix b/pkgs/applications/virtualization/singularity/default.nix
index b11f8d68189ca..13f84736d9ecb 100644
--- a/pkgs/applications/virtualization/singularity/default.nix
+++ b/pkgs/applications/virtualization/singularity/default.nix
@@ -65,7 +65,7 @@ buildGoPackage rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.sylabs.io/";
     description = "Application containers for linux";
     license = licenses.bsd3;
diff --git a/pkgs/applications/virtualization/spike/default.nix b/pkgs/applications/virtualization/spike/default.nix
index 0f397bc272a9f..12dfc713fd2c1 100644
--- a/pkgs/applications/virtualization/spike/default.nix
+++ b/pkgs/applications/virtualization/spike/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, dtc, nixosTests }:
+{ lib, stdenv, fetchgit, dtc, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "spike";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     can-run-hello-world = nixosTests.spike;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A RISC-V ISA Simulator";
     homepage = "https://github.com/riscv/riscv-isa-sim";
     license = licenses.bsd3;
diff --git a/pkgs/applications/virtualization/tini/default.nix b/pkgs/applications/virtualization/tini/default.nix
index e3b1ccd4ce242..dd7bcb19978c2 100644
--- a/pkgs/applications/virtualization/tini/default.nix
+++ b/pkgs/applications/virtualization/tini/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, glibc }:
+{ lib, stdenv, fetchFromGitHub, cmake, glibc }:
 
 stdenv.mkDerivation rec {
   version = "0.19.0";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ glibc glibc.static ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiny but valid init for containers";
     homepage = "https://github.com/krallin/tini";
     license = licenses.mit;
diff --git a/pkgs/applications/virtualization/virt-manager/default.nix b/pkgs/applications/virtualization/virt-manager/default.nix
index 9673e93d0cc86..4a6b539b4fbdb 100644
--- a/pkgs/applications/virtualization/virt-manager/default.nix
+++ b/pkgs/applications/virtualization/virt-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3Packages, intltool, file
+{ lib, stdenv, fetchurl, python3Packages, intltool, file
 , wrapGAppsHook, gtk-vnc, vte, avahi, dconf
 , gobject-introspection, libvirt-glib, system-libvirt
 , gsettings-desktop-schemas, glib, libosinfo, gnome3
@@ -56,7 +56,7 @@ python3Packages.buildPythonApplication rec {
   # Failed tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://virt-manager.org";
     description = "Desktop user interface for managing virtual machines";
     longDescription = ''
diff --git a/pkgs/applications/virtualization/virt-top/default.nix b/pkgs/applications/virtualization/virt-top/default.nix
index 692b5f01b5c6d..8ff90a4150dbb 100644
--- a/pkgs/applications/virtualization/virt-top/default.nix
+++ b/pkgs/applications/virtualization/virt-top/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchpatch, ocamlPackages, autoreconfHook }:
+{ lib, stdenv, fetchgit, fetchpatch, ocamlPackages, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "virt-top";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   buildPhase = "make opt";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A top-like utility for showing stats of virtualized domains";
     homepage = "https://people.redhat.com/~rjones/virt-top/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/virtualization/vpcs/default.nix b/pkgs/applications/virtualization/vpcs/default.nix
index ce08428eba0a1..33d707a50079f 100644
--- a/pkgs/applications/virtualization/vpcs/default.nix
+++ b/pkgs/applications/virtualization/vpcs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "vpcs";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple virtual PC simulator";
     longDescription = ''
       The VPCS (Virtual PC Simulator) can simulate up to 9 PCs. You can
diff --git a/pkgs/applications/window-managers/2bwm/default.nix b/pkgs/applications/window-managers/2bwm/default.nix
index 0a2dd63130eb7..4072c74d7f838 100644
--- a/pkgs/applications/window-managers/2bwm/default.nix
+++ b/pkgs/applications/window-managers/2bwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, patches
+{ lib, stdenv, fetchFromGitHub, patches
 , libxcb, xcbutilkeysyms, xcbutilwm
 , libX11, xcbutil, xcbutilxrm }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "make install DESTDIR=$out PREFIX=\"\"";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/venam/2bwm";
     description = "A fast floating WM written over the XCB library and derived from mcwm";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/afterstep/default.nix b/pkgs/applications/window-managers/afterstep/default.nix
index 001e624e1bed8..4bfe654380549 100644
--- a/pkgs/applications/window-managers/afterstep/default.nix
+++ b/pkgs/applications/window-managers/afterstep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , libjpeg, libtiff, libpng, freetype
 , fltk, gtk
 , libX11, libXext, libICE
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
      export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE $(pkg-config dbus-1 --cflags)"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A NEXTStep-inspired window manager";
     longDescription = ''
       AfterStep is a window manager for the Unix X Window
diff --git a/pkgs/applications/window-managers/awesome/default.nix b/pkgs/applications/window-managers/awesome/default.nix
index 609723b42d417..0409954cfb1fd 100644
--- a/pkgs/applications/window-managers/awesome/default.nix
+++ b/pkgs/applications/window-managers/awesome/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, luaPackages, cairo, librsvg, cmake, imagemagick, pkgconfig, gdk-pixbuf
+{ lib, stdenv, fetchFromGitHub, luaPackages, cairo, librsvg, cmake, imagemagick, pkgconfig, gdk-pixbuf
 , xorg, libstartup_notification, libxdg_basedir, libpthreadstubs
 , xcb-util-cursor, makeWrapper, pango, gobject-introspection
 , which, dbus, nettools, git, doxygen
@@ -82,7 +82,7 @@ stdenv.mkDerivation rec {
     inherit lua;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Highly configurable, dynamic window manager for X";
     homepage    = "https://awesomewm.org/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/window-managers/berry/default.nix b/pkgs/applications/window-managers/berry/default.nix
index 64b7f2c1d2b91..b2d28ca55f234 100644
--- a/pkgs/applications/window-managers/berry/default.nix
+++ b/pkgs/applications/window-managers/berry/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , libX11
 , libXext
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
                       FREETYPEINC="${freetype.dev}/include/freetype2" )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A healthy, bite-sized window manager";
     longDescription = ''
       berry is a healthy, bite-sized window manager written in C for unix
diff --git a/pkgs/applications/window-managers/bevelbar/default.nix b/pkgs/applications/window-managers/bevelbar/default.nix
index 40cebb572af35..74da42f88c94c 100644
--- a/pkgs/applications/window-managers/bevelbar/default.nix
+++ b/pkgs/applications/window-managers/bevelbar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, libXrandr, libXft }:
+{ lib, stdenv, fetchFromGitHub, libX11, libXrandr, libXft }:
 
 stdenv.mkDerivation rec {
   pname = "bevelbar";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An X11 status bar with fancy schmancy 1985-ish beveled borders";
     inherit (src.meta) homepage;
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/bspwm/default.nix b/pkgs/applications/window-managers/bspwm/default.nix
index 7c7bdbe22a784..c07c3389e3c0c 100644
--- a/pkgs/applications/window-managers/bspwm/default.nix
+++ b/pkgs/applications/window-managers/bspwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libxcb, libXinerama
+{ lib, stdenv, fetchFromGitHub, libxcb, libXinerama
 , xcbutil, xcbutilkeysyms, xcbutilwm
 }:
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiling window manager based on binary space partitioning";
     homepage = "https://github.com/baskerville/bspwm";
     maintainers = with maintainers; [ meisternu epitrochoid rvolosatovs ];
diff --git a/pkgs/applications/window-managers/btops/default.nix b/pkgs/applications/window-managers/btops/default.nix
index 132e2ba6ddd31..f0bb26f43e259 100644
--- a/pkgs/applications/window-managers/btops/default.nix
+++ b/pkgs/applications/window-managers/btops/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by https://github.com/kamilchm/go2nix v1.2.1
-{ stdenv, buildGoPackage, fetchgit }:
+{ lib, stdenv, buildGoPackage, fetchgit }:
 
 buildGoPackage rec {
   pname = "btops";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "bspwm desktop management that supports dymanic appending, removing, and renaming";
     homepage = "https://github.com/cmschuetz/btops";
     maintainers = with maintainers; [ mnacamura ];
diff --git a/pkgs/applications/window-managers/cage/default.nix b/pkgs/applications/window-managers/cage/default.nix
index 372ad1e27fc3d..e48be5809e9c9 100644
--- a/pkgs/applications/window-managers/cage/default.nix
+++ b/pkgs/applications/window-managers/cage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, ninja, pkg-config, wayland, scdoc, makeWrapper
 , wlroots, wayland-protocols, pixman, libxkbcommon
 , systemd, libGL, libX11
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
   # Tests Cage using the NixOS module by launching xterm:
   passthru.tests.basic-nixos-module-functionality = nixosTests.cage;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Wayland kiosk that runs a single, maximized application";
     homepage    = "https://www.hjdskes.nl/projects/cage/";
     license     = licenses.mit;
diff --git a/pkgs/applications/window-managers/cagebreak/default.nix b/pkgs/applications/window-managers/cagebreak/default.nix
index 36b3adb08e112..3d08259978975 100644
--- a/pkgs/applications/window-managers/cagebreak/default.nix
+++ b/pkgs/applications/window-managers/cagebreak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, ninja, pkg-config, wayland, scdoc, makeWrapper
 , wlroots, wayland-protocols, pixman, libxkbcommon
 , cairo , pango, fontconfig, pandoc, systemd
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.basic = nixosTests.cagebreak;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Wayland tiling compositor inspired by ratpoison";
     homepage = "https://github.com/project-repo/cagebreak";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/clfswm/default.nix b/pkgs/applications/window-managers/clfswm/default.nix
index e3864319f7bbc..1c6f92a38f292 100644
--- a/pkgs/applications/window-managers/clfswm/default.nix
+++ b/pkgs/applications/window-managers/clfswm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoconf, sbcl, lispPackages, xdpyinfo, texinfo4
+{ lib, stdenv, fetchgit, autoconf, sbcl, lispPackages, xdpyinfo, texinfo4
 , makeWrapper }:
 
 stdenv.mkDerivation {
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
     echo ${xdpyinfo} ${lispPackages.clx} ${lispPackages.cl-ppcre} > $out/nix-support/depends
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A(nother) Common Lisp FullScreen Window Manager";
     homepage    = "https://common-lisp.net/project/clfswm/";
     license     = licenses.gpl3;
diff --git a/pkgs/applications/window-managers/cwm/default.nix b/pkgs/applications/window-managers/cwm/default.nix
index 18baefdbf3eb6..dc80b54bc6936 100644
--- a/pkgs/applications/window-managers/cwm/default.nix
+++ b/pkgs/applications/window-managers/cwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, libXinerama, libXrandr, libXft, yacc, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, libX11, libXinerama, libXrandr, libXft, yacc, pkgconfig }:
 
 stdenv.mkDerivation rec {
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   prePatch = ''sed -i "s@/usr/local@$out@" Makefile'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight and efficient window manager for X11";
     homepage    = "https://github.com/leahneukirchen/cwm";
     maintainers = with maintainers; [ _0x4A6F mkf ];
diff --git a/pkgs/applications/window-managers/dwm/dwm-status.nix b/pkgs/applications/window-managers/dwm/dwm-status.nix
index c7c72b4d40257..470c8ae2acca5 100644
--- a/pkgs/applications/window-managers/dwm/dwm-status.nix
+++ b/pkgs/applications/window-managers/dwm/dwm-status.nix
@@ -27,7 +27,7 @@ rustPlatform.buildRustPackage rec {
     wrapProgram $out/bin/dwm-status --prefix "PATH" : "${stdenv.lib.makeBinPath bins}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Highly performant and configurable DWM status service";
     homepage = "https://github.com/Gerschtli/dwm-status";
     license = with licenses; [ mit ];
diff --git a/pkgs/applications/window-managers/dwm/git.nix b/pkgs/applications/window-managers/dwm/git.nix
index 3751a8de69f72..814b6167d17be 100644
--- a/pkgs/applications/window-managers/dwm/git.nix
+++ b/pkgs/applications/window-managers/dwm/git.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, libX11, libXinerama, libXft, patches ? [], conf ? null }:
+{ lib, stdenv, fetchgit, libX11, libXinerama, libXft, patches ? [], conf ? null }:
 
 let
   name = "dwm-git-20180602";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
 
   buildPhase = "make";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://suckless.org/";
     description = "Dynamic window manager for X, development version";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/evilwm/default.nix b/pkgs/applications/window-managers/evilwm/default.nix
index 64dc784e812f9..94562cd0d224b 100644
--- a/pkgs/applications/window-managers/evilwm/default.nix
+++ b/pkgs/applications/window-managers/evilwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl,  libX11, libXext, libXrandr, libXrender,
+{ lib, stdenv, fetchurl,  libX11, libXext, libXrandr, libXrender,
   xorgproto, patches ? [] }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   # Allow users set their own list of patches
   inherit patches;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.6809.org.uk/evilwm/";
     description = "Minimalist window manager for the X Window System";
 
diff --git a/pkgs/applications/window-managers/fbpanel/default.nix b/pkgs/applications/window-managers/fbpanel/default.nix
index c44bf5f0bd882..e927db36fdd57 100644
--- a/pkgs/applications/window-managers/fbpanel/default.nix
+++ b/pkgs/applications/window-managers/fbpanel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , libX11, libXmu, libXpm, gtk2, libpng, libjpeg, libtiff, librsvg, gdk-pixbuf, gdk-pixbuf-xlib
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS="-lX11";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A stand-alone panel";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/window-managers/hikari/default.nix b/pkgs/applications/window-managers/hikari/default.nix
index d23d6c07af0eb..8f9ec3e56a22c 100644
--- a/pkgs/applications/window-managers/hikari/default.nix
+++ b/pkgs/applications/window-managers/hikari/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip,
+{ lib, stdenv, fetchzip,
   pkgconfig, bmake,
   cairo, glib, libevdev, libinput, libxkbcommon, linux-pam, pango, pixman,
   libucl, wayland, wayland-protocols, wlroots,
@@ -65,7 +65,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stacking Wayland compositor which is actively developed on FreeBSD but also supports Linux";
     homepage    = "https://hikari.acmelabs.space";
     license     = licenses.bsd2;
diff --git a/pkgs/applications/window-managers/i3/blocks-gaps.nix b/pkgs/applications/window-managers/i3/blocks-gaps.nix
index 4a91865fecac9..f314f340beef4 100644
--- a/pkgs/applications/window-managers/i3/blocks-gaps.nix
+++ b/pkgs/applications/window-managers/i3/blocks-gaps.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, perl, makeWrapper
+{ fetchFromGitHub, lib, stdenv, perl, makeWrapper
 , iproute, acpi, sysstat, alsaUtils
 , scripts ? [ "bandwidth" "battery" "cpu_usage" "disk" "iface"
               "load_average" "memory" "volume" "wifi" ]
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${makeBinPath (optional (elem "volume" scripts) alsaUtils)}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A flexible scheduler for your i3bar blocks -- this is a fork to use with i3-gaps";
     homepage = "https://github.com/Airblader/i3blocks-gaps";
     license = licenses.gpl3;
diff --git a/pkgs/applications/window-managers/i3/default.nix b/pkgs/applications/window-managers/i3/default.nix
index 2ea2c8ac77663..3049e581b22ae 100644
--- a/pkgs/applications/window-managers/i3/default.nix
+++ b/pkgs/applications/window-managers/i3/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, which, pkgconfig, makeWrapper, installShellFiles, libxcb, xcbutilkeysyms
+{ fetchurl, lib, stdenv, which, pkgconfig, makeWrapper, installShellFiles, libxcb, xcbutilkeysyms
 , xcbutil, xcbutilwm, xcbutilxrm, libstartup_notification, libX11, pcre, libev
 , yajl, xcb-util-cursor, perl, pango, perlPackages, libxkbcommon
 , xorgserver, xvfb_run }:
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
 
   separateDebugInfo = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiling window manager";
     homepage    = "https://i3wm.org";
     maintainers = with maintainers; [ modulistic fpletz globin ];
diff --git a/pkgs/applications/window-managers/i3/easyfocus.nix b/pkgs/applications/window-managers/i3/easyfocus.nix
index 5c7a22eb76949..517971905f64c 100644
--- a/pkgs/applications/window-managers/i3/easyfocus.nix
+++ b/pkgs/applications/window-managers/i3/easyfocus.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, xorgproto, libxcb, xcbutilkeysyms
+{ lib, stdenv, fetchFromGitHub, pkgconfig, xorgproto, libxcb, xcbutilkeysyms
 , xorg , i3ipc-glib , glib
 }:
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     cp i3-easyfocus $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Focus and select windows in i3";
     homepage = "https://github.com/cornerman/i3-easyfocus";
     maintainers = with maintainers; [teto];
diff --git a/pkgs/applications/window-managers/i3/gaps.nix b/pkgs/applications/window-managers/i3/gaps.nix
index 10f86132ea9ad..e9759fc6b3303 100644
--- a/pkgs/applications/window-managers/i3/gaps.nix
+++ b/pkgs/applications/window-managers/i3/gaps.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, i3, autoreconfHook }:
+{ fetchurl, lib, stdenv, i3, autoreconfHook }:
 
 i3.overrideAttrs (oldAttrs : rec {
 
@@ -15,7 +15,7 @@ i3.overrideAttrs (oldAttrs : rec {
   # fatal error: GENERATED_config_enums.h: No such file or directory
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fork of the i3 tiling window manager with some additional features";
     homepage    = "https://github.com/Airblader/i3";
     maintainers = with maintainers; [ fmthoma ];
diff --git a/pkgs/applications/window-managers/i3/i3ipc-glib.nix b/pkgs/applications/window-managers/i3/i3ipc-glib.nix
index af353589a7ed8..36b48fa3b07e2 100644
--- a/pkgs/applications/window-managers/i3/i3ipc-glib.nix
+++ b/pkgs/applications/window-managers/i3/i3ipc-glib.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, xorgproto, libxcb
+{ lib, stdenv, fetchFromGitHub, pkgconfig, xorgproto, libxcb
 , autoreconfHook, json-glib, gtk-doc, which
 , gobject-introspection
 }:
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     gtkdocize
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A C interface library to i3wm";
     homepage = "https://github.com/acrisci/i3ipc-glib";
     maintainers = with maintainers; [teto];
diff --git a/pkgs/applications/window-managers/i3/layout-manager.nix b/pkgs/applications/window-managers/i3/layout-manager.nix
index 2d75aebc82284..a69a1cd5a33c1 100644
--- a/pkgs/applications/window-managers/i3/layout-manager.nix
+++ b/pkgs/applications/window-managers/i3/layout-manager.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, vim, makeWrapper, jq, rofi, xrandr, xdotool, i3, gawk, libnotify }:
+{ lib, stdenv, fetchFromGitHub, vim, makeWrapper, jq, rofi, xrandr, xdotool, i3, gawk, libnotify }:
 
 let
   path = stdenv.lib.makeBinPath [ vim jq rofi xrandr xdotool i3 gawk libnotify ];
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/klaxalk/i3-layout-manager";
     description = "Saving, loading and managing layouts for i3wm";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/i3/lock-color.nix b/pkgs/applications/window-managers/i3/lock-color.nix
index f07a1926f6e4c..7fe48189752c5 100644
--- a/pkgs/applications/window-managers/i3/lock-color.nix
+++ b/pkgs/applications/window-managers/i3/lock-color.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libxcb,
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libxcb,
   xcbutilkeysyms , xcbutilimage, pam, libX11, libev, cairo, libxkbcommon,
   libxkbfile, libjpeg_turbo, xcbutilxrm
 }:
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     mv $out/share/man/man1/i3lock.1 $out/share/man/man1/i3lock-color.1
     sed -i 's/\(^\|\s\|"\)i3lock\(\s\|$\)/\1i3lock-color\2/g' $out/share/man/man1/i3lock-color.1
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple screen locker like slock, enhanced version with extra configuration options";
     longDescription = ''
       Simple screen locker. After locking, a colored background (default: white) or
diff --git a/pkgs/applications/window-managers/i3/lock-fancy-rapid.nix b/pkgs/applications/window-managers/i3/lock-fancy-rapid.nix
index f6e24d979a458..8884b1d5100ce 100644
--- a/pkgs/applications/window-managers/i3/lock-fancy-rapid.nix
+++ b/pkgs/applications/window-managers/i3/lock-fancy-rapid.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, i3lock }:
+{ lib, stdenv, fetchFromGitHub, xorg, i3lock }:
 
 stdenv.mkDerivation rec {
   pname = "i3lock-fancy-rapid";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     install -D i3lock-fancy-rapid $out/bin/i3lock-fancy-rapid
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A faster implementation of i3lock-fancy";
     homepage = "https://github.com/yvbbrjdr/i3lock-fancy-rapid";
     maintainers = with maintainers; [ nickhu ];
diff --git a/pkgs/applications/window-managers/i3/lock-fancy.nix b/pkgs/applications/window-managers/i3/lock-fancy.nix
index c71ed04e48d3d..7e42a8efd7e92 100644
--- a/pkgs/applications/window-managers/i3/lock-fancy.nix
+++ b/pkgs/applications/window-managers/i3/lock-fancy.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, coreutils, scrot, imagemagick, gawk
+{ lib, stdenv, fetchFromGitHub, coreutils, scrot, imagemagick, gawk
 , i3lock-color, getopt, fontconfig
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     cp i3lock-fancy $out/bin/i3lock-fancy
     cp icons/lock*.png $out/share/i3lock-fancy/icons
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "i3lock is a bash script that takes a screenshot of the desktop, blurs the background and adds a lock icon and text";
     homepage = "https://github.com/meskarune/i3lock-fancy";
     maintainers = with maintainers; [ ];
diff --git a/pkgs/applications/window-managers/i3/lock.nix b/pkgs/applications/window-managers/i3/lock.nix
index 7a2812c2cfe01..3b991d091ce99 100644
--- a/pkgs/applications/window-managers/i3/lock.nix
+++ b/pkgs/applications/window-managers/i3/lock.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, which, pkgconfig, libxcb, xcbutilkeysyms, xcbutilimage,
+{ fetchurl, lib, stdenv, which, pkgconfig, libxcb, xcbutilkeysyms, xcbutilimage,
   xcbutilxrm, pam, libX11, libev, cairo, libxkbcommon, libxkbfile }:
 
 stdenv.mkDerivation rec {
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp *.1 $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple screen locker like slock";
     longDescription = ''
       Simple screen locker. After locking, a colored background (default: white) or
diff --git a/pkgs/applications/window-managers/i3/pystatus.nix b/pkgs/applications/window-managers/i3/pystatus.nix
index beefdaf891c6a..f8d12642999a9 100644
--- a/pkgs/applications/window-managers/i3/pystatus.nix
+++ b/pkgs/applications/window-managers/i3/pystatus.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , libpulseaudio
 , libnotify
@@ -45,7 +45,7 @@ python3Packages.buildPythonApplication rec {
   # no tests in tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/enkore/i3pystatus";
     description = "A complete replacement for i3status";
     longDescription = ''
diff --git a/pkgs/applications/window-managers/i3/status-rust.nix b/pkgs/applications/window-managers/i3/status-rust.nix
index 66373250f71d7..d49f8ff6bd6b7 100644
--- a/pkgs/applications/window-managers/i3/status-rust.nix
+++ b/pkgs/applications/window-managers/i3/status-rust.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , pkgconfig
@@ -37,7 +37,7 @@ rustPlatform.buildRustPackage rec {
   # Currently no tests are implemented, so we avoid building the package twice
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Very resource-friendly and feature-rich replacement for i3status";
     homepage = "https://github.com/greshake/i3status-rust";
     license = licenses.gpl3;
diff --git a/pkgs/applications/window-managers/i3/wk-switch.nix b/pkgs/applications/window-managers/i3/wk-switch.nix
index 51881975266d0..e7fd87aaf3b8e 100644
--- a/pkgs/applications/window-managers/i3/wk-switch.nix
+++ b/pkgs/applications/window-managers/i3/wk-switch.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "i3-wk-switch";
@@ -21,7 +21,7 @@ python3Packages.buildPythonApplication rec {
     cp i3-wk-switch.py "$out/bin/i3-wk-switch"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XMonad-like workspace switching for i3 and sway";
     maintainers = with maintainers; [ synthetica ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/window-managers/i3/wmfocus.nix b/pkgs/applications/window-managers/i3/wmfocus.nix
index 5c9f2b7795305..6f6a63eca0972 100644
--- a/pkgs/applications/window-managers/i3/wmfocus.nix
+++ b/pkgs/applications/window-managers/i3/wmfocus.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform
+{ lib, stdenv, fetchFromGitHub, rustPlatform
 , xorg, python3, pkgconfig, cairo, libxkbcommon }:
 
 rustPlatform.buildRustPackage rec {
@@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec {
   # users.
   cargoBuildFlags = [ "--features i3" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Visually focus windows by label";
     homepage = "https://github.com/svenstaro/wmfocus";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/icewm/default.nix b/pkgs/applications/window-managers/icewm/default.nix
index f07bc873b7ad8..425f562dfd52f 100644
--- a/pkgs/applications/window-managers/icewm/default.nix
+++ b/pkgs/applications/window-managers/icewm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , pkg-config
@@ -89,7 +89,7 @@ stdenv.mkDerivation rec {
     cp -r ../lib/themes/{gtk2,Natural,nice,nice2,warp3,warp4,yellowmotif} $out/share/icewm/themes/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple, lightweight X window manager";
     longDescription = ''
       IceWM is a window manager for the X Window System. The goal of IceWM is
diff --git a/pkgs/applications/window-managers/jwm/jwm-settings-manager.nix b/pkgs/applications/window-managers/jwm/jwm-settings-manager.nix
index d6fe5b4200c4d..58105ec219b50 100644
--- a/pkgs/applications/window-managers/jwm/jwm-settings-manager.nix
+++ b/pkgs/applications/window-managers/jwm/jwm-settings-manager.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, gettext, libXpm, libGL, fltk, hicolor-icon-theme, glib, gnome2, which }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, gettext, libXpm, libGL, fltk, hicolor-icon-theme, glib, gnome2, which }:
 
 stdenv.mkDerivation {
   pname = "jwm-settings-manager";
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
       --replace 'DESTINATION usr/share' "DESTINATION share"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full configuration manager for JWM";
     homepage = "https://joewing.net/projects/jwm";
     license = licenses.gpl3;
diff --git a/pkgs/applications/window-managers/leftwm/default.nix b/pkgs/applications/window-managers/leftwm/default.nix
index 13c0818101f7d..d0e883f89c8c5 100644
--- a/pkgs/applications/window-managers/leftwm/default.nix
+++ b/pkgs/applications/window-managers/leftwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, libX11, libXinerama, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, libX11, libXinerama, makeWrapper }:
 
 let
     rpath = stdenv.lib.makeLibraryPath [ libXinerama libX11 ];
@@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec {
     wrapProgram $out/bin/leftwm-worker --prefix LD_LIBRARY_PATH : "${rpath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiling window manager for the adventurer";
     homepage = "https://github.com/leftwm/leftwm";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/lemonbar/default.nix b/pkgs/applications/window-managers/lemonbar/default.nix
index 5bdb04688ca54..2a4004e554396 100644
--- a/pkgs/applications/window-managers/lemonbar/default.nix
+++ b/pkgs/applications/window-managers/lemonbar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, libxcb }:
+{ lib, stdenv, fetchurl, perl, libxcb }:
 
 stdenv.mkDerivation {
   name = "lemonbar-1.4";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
   
   prePatch = ''sed -i "s@/usr@$out@" Makefile'';
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight xcb based bar";
     homepage = "https://github.com/LemonBoy/bar";
     maintainers = [ maintainers.meisternu ];
diff --git a/pkgs/applications/window-managers/lwm/default.nix b/pkgs/applications/window-managers/lwm/default.nix
index 49cdc81b9ce0a..cf1088c822311 100644
--- a/pkgs/applications/window-managers/lwm/default.nix
+++ b/pkgs/applications/window-managers/lwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , imake, libX11, libSM, libXext, libICE }:
 
 stdenv.mkDerivation rec {
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     install -m644 lwm.man $out/share/man/man1/lwm.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight Window Manager";
     longDescription = ''
       lwm is a window manager for X that tries to keep out of your face. There
diff --git a/pkgs/applications/window-managers/neocomp/default.nix b/pkgs/applications/window-managers/neocomp/default.nix
index 57968922c390d..da6b5e2825d64 100644
--- a/pkgs/applications/window-managers/neocomp/default.nix
+++ b/pkgs/applications/window-managers/neocomp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , asciidoc
 , docbook_xml_dtd_45
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
       "#define MAX_PATH_LENGTH 128"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage        = "https://github.com/DelusionalLogic/NeoComp";
     license         = licenses.gpl3;
     maintainers     = with maintainers; [ twey ];
diff --git a/pkgs/applications/window-managers/notion/default.nix b/pkgs/applications/window-managers/notion/default.nix
index a00462e81113b..5d688f5e23533 100644
--- a/pkgs/applications/window-managers/notion/default.nix
+++ b/pkgs/applications/window-managers/notion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig
+{ lib, stdenv, fetchFromGitHub, pkgconfig
 , lua, gettext, which, groff, xmessage, xterm
 , readline, fontconfig, libX11, libXext, libSM
 , libXinerama, libXrandr, libXft
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" "${xmessage}/bin:${xterm}/bin" \
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiling tabbed window manager";
     homepage = "https://notionwm.net";
     license   = licenses.lgpl21;
diff --git a/pkgs/applications/window-managers/pekwm/default.nix b/pkgs/applications/window-managers/pekwm/default.nix
index dce727ee29b38..fcce16c08ba6e 100644
--- a/pkgs/applications/window-managers/pekwm/default.nix
+++ b/pkgs/applications/window-managers/pekwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , cmake
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     libpng
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight window manager";
     longDescription = ''
       pekwm is a window manager that once upon a time was based on the
diff --git a/pkgs/applications/window-managers/qtile/default.nix b/pkgs/applications/window-managers/qtile/default.nix
index 280ec067658ad..284a12e65f542 100644
--- a/pkgs/applications/window-managers/qtile/default.nix
+++ b/pkgs/applications/window-managers/qtile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python37Packages, glib, cairo, pango, pkgconfig, libxcb, xcbutilcursor }:
+{ lib, stdenv, fetchFromGitHub, python37Packages, glib, cairo, pango, pkgconfig, libxcb, xcbutilcursor }:
 
 let cairocffi-xcffib = python37Packages.cairocffi.override {
     withXcffib = true;
@@ -56,7 +56,7 @@ python37Packages.buildPythonApplication rec {
 
   doCheck = false; # Requires X server #TODO this can be worked out with the existing NixOS testing infrastructure.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.qtile.org/";
     license = licenses.mit;
     description = "A small, flexible, scriptable tiling window manager written in Python";
diff --git a/pkgs/applications/window-managers/ratpoison/default.nix b/pkgs/applications/window-managers/ratpoison/default.nix
index 4c7cdf1069f91..30195ab91471a 100644
--- a/pkgs/applications/window-managers/ratpoison/default.nix
+++ b/pkgs/applications/window-managers/ratpoison/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, perl, autoconf, automake
+{ lib, stdenv, fetchurl, pkgconfig, perl, autoconf, automake
 , libX11, xorgproto, libXt, libXpm, libXft, libXtst, libXi
 , libXrandr, fontconfig, freetype, readline
 }:
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     mv $out/share/ratpoison $contrib/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.nongnu.org/ratpoison/";
     description = "Simple mouse-free tiling window manager";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/window-managers/sawfish/default.nix b/pkgs/applications/window-managers/sawfish/default.nix
index 0625977451946..7615c6c4bd80d 100644
--- a/pkgs/applications/window-managers/sawfish/default.nix
+++ b/pkgs/applications/window-managers/sawfish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkg-config
 , which
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extensible, Lisp-based window manager";
     longDescription = ''
       Sawfish is an extensible window manager using a Lisp-based scripting language.
diff --git a/pkgs/applications/window-managers/spectrwm/default.nix b/pkgs/applications/window-managers/spectrwm/default.nix
index c3ab558948603..6598fefaebd28 100644
--- a/pkgs/applications/window-managers/spectrwm/default.nix
+++ b/pkgs/applications/window-managers/spectrwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, xorg }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, xorg }:
 
 stdenv.mkDerivation {
   pname = "spectrwm";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiling window manager";
     homepage    = "https://github.com/conformal/spectrwm";
     maintainers = with maintainers; [ christianharke ];
diff --git a/pkgs/applications/window-managers/stalonetray/default.nix b/pkgs/applications/window-managers/stalonetray/default.nix
index ad0baeb97dd25..47903bb2276e6 100644
--- a/pkgs/applications/window-managers/stalonetray/default.nix
+++ b/pkgs/applications/window-managers/stalonetray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, xorgproto }:
+{ lib, stdenv, fetchurl, libX11, xorgproto }:
 
 stdenv.mkDerivation rec {
   pname = "stalonetray";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stand alone tray";
     homepage = "http://stalonetray.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/window-managers/stumpish/default.nix b/pkgs/applications/window-managers/stumpish/default.nix
index c76a9ba762efe..c5c3d9db783e9 100644
--- a/pkgs/applications/window-managers/stumpish/default.nix
+++ b/pkgs/applications/window-managers/stumpish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll, fetchFromGitHub, gnused, ncurses, xorg, rlwrap }:
+{ lib, stdenv, substituteAll, fetchFromGitHub, gnused, ncurses, xorg, rlwrap }:
 
 stdenv.mkDerivation {
   pname = "stumpish";
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
     cp util/stumpish/stumpish $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/stumpwm/stumpwm-contrib";
     description = "STUMPwm Interactive SHell";
     license = licenses.gpl2;
diff --git a/pkgs/applications/window-managers/stumpwm/default.nix b/pkgs/applications/window-managers/stumpwm/default.nix
index b059423c23c47..4db5343498c7c 100644
--- a/pkgs/applications/window-managers/stumpwm/default.nix
+++ b/pkgs/applications/window-managers/stumpwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoconf, sbcl, lispPackages, xdpyinfo, texinfo4
+{ lib, stdenv, fetchgit, autoconf, sbcl, lispPackages, xdpyinfo, texinfo4
 , makeWrapper , rlwrap, gnused, gnugrep, coreutils, xprop
 , extraModulePaths ? []
 , version }:
@@ -93,7 +93,7 @@ stdenv.mkDerivation {
     inherit sbcl lispPackages contrib;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiling window manager for X11";
     homepage    = "https://github.com/stumpwm/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/window-managers/sway/bg.nix b/pkgs/applications/window-managers/sway/bg.nix
index 86301492c4687..a4532960619f9 100644
--- a/pkgs/applications/window-managers/sway/bg.nix
+++ b/pkgs/applications/window-managers/sway/bg.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, ninja, pkgconfig, scdoc
 , wayland, wayland-protocols, cairo, gdk-pixbuf
 }:
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "-Dgdk-pixbuf=enabled" "-Dman-pages=enabled"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wallpaper tool for Wayland compositors";
     longDescription = ''
       A wallpaper utility for Wayland compositors, that is compatible with any
diff --git a/pkgs/applications/window-managers/sway/contrib.nix b/pkgs/applications/window-managers/sway/contrib.nix
index fd44f4a5be50c..e04a6e1cb78cc 100644
--- a/pkgs/applications/window-managers/sway/contrib.nix
+++ b/pkgs/applications/window-managers/sway/contrib.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 
 , fetchurl
 , coreutils
@@ -55,7 +55,7 @@ grimshot = stdenv.mkDerivation rec {
     fi
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A helper for screenshots within sway";
     homepage = "https://github.com/swaywm/sway/tree/master/contrib";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/sway/default.nix b/pkgs/applications/window-managers/sway/default.nix
index 23dcf68bddf32..2b3c51a7340fc 100644
--- a/pkgs/applications/window-managers/sway/default.nix
+++ b/pkgs/applications/window-managers/sway/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchFromGitHub, makeWrapper
 , meson, ninja, pkg-config, wayland, scdoc
 , libxkbcommon, pcre, json_c, dbus, libevdev
 , pango, cairo, libinput, libcap, pam, gdk-pixbuf, librsvg
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     "-Ddefault-wallpaper=false"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An i3-compatible tiling Wayland compositor";
     longDescription = ''
       Sway is a tiling Wayland compositor and a drop-in replacement for the i3
diff --git a/pkgs/applications/window-managers/sway/idle.nix b/pkgs/applications/window-managers/sway/idle.nix
index 486ab79598dff..546999e603527 100644
--- a/pkgs/applications/window-managers/sway/idle.nix
+++ b/pkgs/applications/window-managers/sway/idle.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, ninja, pkgconfig, scdoc
 , wayland, wayland-protocols, systemd
 }:
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   mesonFlags = [ "-Dman-pages=enabled" "-Dlogind=enabled" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Idle management daemon for Wayland";
     longDescription = ''
       Sway's idle management daemon. It is compatible with any Wayland
diff --git a/pkgs/applications/window-managers/sway/lock-effects.nix b/pkgs/applications/window-managers/sway/lock-effects.nix
index 4bb4225d394d4..e90aaf5efc238 100644
--- a/pkgs/applications/window-managers/sway/lock-effects.nix
+++ b/pkgs/applications/window-managers/sway/lock-effects.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub,
+{ lib, stdenv, fetchFromGitHub,
   meson, ninja, pkgconfig, scdoc,
   wayland, wayland-protocols, libxkbcommon,
   cairo, gdk-pixbuf, pam
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "-Dpam=enabled" "-Dgdk-pixbuf=enabled" "-Dman-pages=enabled"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Screen locker for Wayland";
     longDescription = ''
       Swaylock, with fancy effects
diff --git a/pkgs/applications/window-managers/sway/lock-fancy.nix b/pkgs/applications/window-managers/sway/lock-fancy.nix
index 338d626d9908a..710dff73452d2 100644
--- a/pkgs/applications/window-managers/sway/lock-fancy.nix
+++ b/pkgs/applications/window-managers/sway/lock-fancy.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, coreutils, grim, gawk, swaylock
+{ lib, stdenv, fetchFromGitHub, coreutils, grim, gawk, swaylock
 , imagemagick, getopt, fontconfig, makeWrapper
 }:
 
@@ -37,7 +37,7 @@ in stdenv.mkDerivation rec {
       --prefix PATH : "${depsPath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This is an swaylock bash script that takes a screenshot of the desktop, blurs the background and adds a lock icon and text";
     homepage = "https://github.com/Big-B/swaylock-fancy";
     license = licenses.mit;
diff --git a/pkgs/applications/window-managers/sway/lock.nix b/pkgs/applications/window-managers/sway/lock.nix
index 7cbba5e981bfa..51e7bf345943d 100644
--- a/pkgs/applications/window-managers/sway/lock.nix
+++ b/pkgs/applications/window-managers/sway/lock.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, ninja, pkgconfig, scdoc
 , wayland, wayland-protocols, libxkbcommon, cairo, gdk-pixbuf, pam
 }:
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "-Dpam=enabled" "-Dgdk-pixbuf=enabled" "-Dman-pages=enabled"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Screen locker for Wayland";
     longDescription = ''
       swaylock is a screen locking utility for Wayland compositors.
diff --git a/pkgs/applications/window-managers/sxhkd/default.nix b/pkgs/applications/window-managers/sxhkd/default.nix
index ac28abc31d3f8..427f4c92f7bdd 100644
--- a/pkgs/applications/window-managers/sxhkd/default.nix
+++ b/pkgs/applications/window-managers/sxhkd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, asciidoc, libxcb, xcbutil, xcbutilkeysyms
+{ lib, stdenv, fetchFromGitHub, asciidoc, libxcb, xcbutil, xcbutilkeysyms
 , xcbutilwm
 }:
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple X hotkey daemon";
     homepage = "https://github.com/baskerville/sxhkd";
     license = licenses.bsd2;
diff --git a/pkgs/applications/window-managers/trayer/default.nix b/pkgs/applications/window-managers/trayer/default.nix
index 5c3d8710e35dc..e7fc397e123c2 100644
--- a/pkgs/applications/window-managers/trayer/default.nix
+++ b/pkgs/applications/window-managers/trayer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, gdk-pixbuf, gtk2 }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, gdk-pixbuf, gtk2 }:
 
 stdenv.mkDerivation rec {
   name = "trayer-1.1.8";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sargon/trayer-srg";
     license = licenses.mit;
     description = "A lightweight GTK2-based systray for UNIX desktop";
diff --git a/pkgs/applications/window-managers/vwm/default.nix b/pkgs/applications/window-managers/vwm/default.nix
index 8eb42bb9a97dc..1b70706d0d3e7 100644
--- a/pkgs/applications/window-managers/vwm/default.nix
+++ b/pkgs/applications/window-managers/vwm/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ncurses, pkgconfig, glib, libviper, libpseudo, gpm,
+{lib, stdenv, fetchurl, ncurses, pkgconfig, glib, libviper, libpseudo, gpm,
 libvterm}:
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ ncurses glib libviper libpseudo gpm libvterm ];
  
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://vwm.sourceforge.net/";
     description = "Dynamic window manager for the console";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/window-managers/windowchef/default.nix b/pkgs/applications/window-managers/windowchef/default.nix
index 0f65e4443ca46..f5a5e6dbd5c94 100644
--- a/pkgs/applications/window-managers/windowchef/default.nix
+++ b/pkgs/applications/window-managers/windowchef/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libxcb, libXrandr
+{ lib, stdenv, fetchFromGitHub, libxcb, libXrandr
 , xcbutil, xcbutilkeysyms, xcbutilwm, xcbproto
 }:
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A stacking window manager that cooks windows with orders from the Waitron";
     homepage = "https://github.com/tudurom/windowchef";
     maintainers = with maintainers; [ bhougland ];
diff --git a/pkgs/applications/window-managers/windowmaker/default.nix b/pkgs/applications/window-managers/windowmaker/default.nix
index 9f5d2e2539dff..6bb0586ffed70 100644
--- a/pkgs/applications/window-managers/windowmaker/default.nix
+++ b/pkgs/applications/window-managers/windowmaker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , libX11, libXext, libXft, libXmu, libXinerama, libXrandr, libXpm
 , imagemagick, libpng, libjpeg, libexif, libtiff, libungif, libwebp }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     "--disable-magick" # Many distros reported imagemagick fails to be found
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://windowmaker.org/";
     description = "NeXTSTEP-like window manager";
     longDescription = ''
diff --git a/pkgs/applications/window-managers/windowmaker/dockapps/AlsaMixer-app.nix b/pkgs/applications/window-managers/windowmaker/dockapps/AlsaMixer-app.nix
index 4ec021644011a..43080f2eae7d4 100644
--- a/pkgs/applications/window-managers/windowmaker/dockapps/AlsaMixer-app.nix
+++ b/pkgs/applications/window-managers/windowmaker/dockapps/AlsaMixer-app.nix
@@ -1,4 +1,4 @@
-{ stdenv, dockapps-sources, pkg-config, libX11, libXpm, libXext, alsaLib }:
+{ lib, stdenv, dockapps-sources, pkg-config, libX11, libXpm, libXext, alsaLib }:
 
 stdenv.mkDerivation rec {
   pname = "AlsaMixer.app";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     ln -s ${placeholder "out"}/bin/AlsaMixer.app ${placeholder "out"}/bin/AlsaMixer
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Alsa mixer application for Windowmaker";
     homepage = "https://www.dockapps.net/alsamixerapp";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/window-managers/windowmaker/dockapps/libdockapp.nix b/pkgs/applications/window-managers/windowmaker/dockapps/libdockapp.nix
index bcdef42a78a0e..aaf99ec932e62 100644
--- a/pkgs/applications/window-managers/windowmaker/dockapps/libdockapp.nix
+++ b/pkgs/applications/window-managers/windowmaker/dockapps/libdockapp.nix
@@ -1,4 +1,4 @@
-{ stdenv, dockapps-sources, autoreconfHook, pkg-config
+{ lib, stdenv, dockapps-sources, autoreconfHook, pkg-config
 , libX11, libXext, libXpm, mkfontdir, fontutil }:
 
 stdenv.mkDerivation rec {
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "--with-font=no"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library providing a framework for dockapps";
     homepage = "https://www.dockapps.net/libdockapp";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/window-managers/windowmaker/dockapps/wmCalClock.nix b/pkgs/applications/window-managers/windowmaker/dockapps/wmCalClock.nix
index f8ea781858a4f..9f49b4508c1ca 100644
--- a/pkgs/applications/window-managers/windowmaker/dockapps/wmCalClock.nix
+++ b/pkgs/applications/window-managers/windowmaker/dockapps/wmCalClock.nix
@@ -1,4 +1,4 @@
-{ stdenv, dockapps-sources
+{ lib, stdenv, dockapps-sources
 , libX11, libXpm, libXext }:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "DESTDIR=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Calendar clock with antialiased text";
     homepage = "https://www.dockapps.net/wmcalclock";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/window-managers/windowmaker/dockapps/wmsm-app.nix b/pkgs/applications/window-managers/windowmaker/dockapps/wmsm-app.nix
index dd25ee2b2fced..e427a85d0386c 100644
--- a/pkgs/applications/window-managers/windowmaker/dockapps/wmsm-app.nix
+++ b/pkgs/applications/window-managers/windowmaker/dockapps/wmsm-app.nix
@@ -1,4 +1,4 @@
-{ stdenv, dockapps-sources
+{ lib, stdenv, dockapps-sources
 , libX11
 , libXpm
 , libXext
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=${placeholder "out"}/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System monitor for Windowmaker";
     homepage = "https://www.dockapps.net/wmsmapp";
     license = licenses.gpl2;
diff --git a/pkgs/applications/window-managers/windowmaker/dockapps/wmsystemtray.nix b/pkgs/applications/window-managers/windowmaker/dockapps/wmsystemtray.nix
index 6ec62af5d36e4..cde55e0169858 100644
--- a/pkgs/applications/window-managers/windowmaker/dockapps/wmsystemtray.nix
+++ b/pkgs/applications/window-managers/windowmaker/dockapps/wmsystemtray.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libX11, libXpm, libXext, libXfixes, libXmu }:
+{ lib, stdenv, fetchurl, pkgconfig, libX11, libXpm, libXext, libXfixes, libXmu }:
 
 stdenv.mkDerivation rec {
   pname = "wmsystemtray";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libX11 libXpm libXext libXfixes libXmu ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A system tray for Windowmaker";
     homepage = "http://wmsystemtray.sourceforge.net";
     license = licenses.gpl2Only;
diff --git a/pkgs/applications/window-managers/wio/default.nix b/pkgs/applications/window-managers/wio/default.nix
index b597cf978a63f..b001b6a64f960 100644
--- a/pkgs/applications/window-managers/wio/default.nix
+++ b/pkgs/applications/window-managers/wio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit
+{ lib, stdenv, fetchgit
 , meson
 , ninja
 , pkg-config
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" "${stdenv.lib.makeBinPath [ alacritty cage ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "That Plan 9 feel, for Wayland";
     longDescription = ''
       Wio is a Wayland compositor for Linux and FreeBSD which has a similar look
diff --git a/pkgs/applications/window-managers/wmfs/default.nix b/pkgs/applications/window-managers/wmfs/default.nix
index a53fc560abcae..83c7d787d8824 100644
--- a/pkgs/applications/window-managers/wmfs/default.nix
+++ b/pkgs/applications/window-managers/wmfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnumake,
+{ lib, stdenv, fetchFromGitHub, gnumake,
   libX11, libXinerama, libXrandr, libXpm, libXft, imlib2 }:
 stdenv.mkDerivation {
   pname = "wmfs";
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
     "MANPREFIX=${placeholder "out"}/share/man"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Window manager from scratch";
     license = licenses.bsd2;
     maintainers = [ maintainers.balsoft ];
diff --git a/pkgs/applications/window-managers/xmonad/log-applet/default.nix b/pkgs/applications/window-managers/xmonad/log-applet/default.nix
index ffd804eaba0ed..744ae62579078 100644
--- a/pkgs/applications/window-managers/xmonad/log-applet/default.nix
+++ b/pkgs/applications/window-managers/xmonad/log-applet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, glib, dbus-glib
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, glib, dbus-glib
 , desktopSupport ? "gnomeflashback", xorg
 , gtk2
 , gtk3, gnome3, mate
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
   # --define-variable=prefix=$prefix
   PKG_CONFIG_LIBXFCE4PANEL_1_0_LIBDIR = "$(out)/lib";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kalj/xmonad-log-applet";
     license = licenses.bsd3;
     broken = desktopSupport == "gnomeflashback";
diff --git a/pkgs/applications/window-managers/yabar/build.nix b/pkgs/applications/window-managers/yabar/build.nix
index b9996e1b4666a..c4b4f5cc8c4f4 100644
--- a/pkgs/applications/window-managers/yabar/build.nix
+++ b/pkgs/applications/window-managers/yabar/build.nix
@@ -45,7 +45,7 @@ stdenv.mkDerivation {
     }
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern and lightweight status bar for X window managers";
     homepage    = "https://github.com/geommer/yabar";
     license     = licenses.mit;
diff --git a/pkgs/build-support/build-fhs-userenv/chrootenv/default.nix b/pkgs/build-support/build-fhs-userenv/chrootenv/default.nix
index 70a7a43bd3984..6ab697c3696fa 100644
--- a/pkgs/build-support/build-fhs-userenv/chrootenv/default.nix
+++ b/pkgs/build-support/build-fhs-userenv/chrootenv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, meson, ninja, pkgconfig, glib }:
+{ lib, stdenv, meson, ninja, pkgconfig, glib }:
 
 stdenv.mkDerivation {
   name = "chrootenv";
@@ -7,7 +7,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ meson ninja pkgconfig ];
   buildInputs = [ glib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Setup mount/user namespace for FHS emulation";
     license = licenses.mit;
     maintainers = with maintainers; [ yegortimoshenko ];
diff --git a/pkgs/build-support/templaterpm/default.nix b/pkgs/build-support/templaterpm/default.nix
index 30465c740e537..0f7acc13277b9 100644
--- a/pkgs/build-support/templaterpm/default.nix
+++ b/pkgs/build-support/templaterpm/default.nix
@@ -1,4 +1,4 @@
-{stdenv, makeWrapper, python, toposort, rpm}:
+{lib, stdenv, makeWrapper, python, toposort, rpm}:
 
 stdenv.mkDerivation {
   pname = "nix-template-rpm";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
       --set PYTHONPATH "${rpm}/lib/${python.libPrefix}/site-packages":"${toposort}/lib/${python.libPrefix}/site-packages"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create templates of nix expressions from RPM .spec files";
     maintainers = with maintainers; [ tstrobel ];
     platforms = with stdenv.lib.platforms; unix;
diff --git a/pkgs/data/documentation/anarchism/default.nix b/pkgs/data/documentation/anarchism/default.nix
index 3acb215db14ae..8f95a371ae227 100644
--- a/pkgs/data/documentation/anarchism/default.nix
+++ b/pkgs/data/documentation/anarchism/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, xdg_utils }:
+{ lib, stdenv, fetchFromGitLab, xdg_utils }:
 
 stdenv.mkDerivation rec {
   pname = "anarchism";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     cp debian/anarchism.desktop $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.anarchistfaq.org/";
     changelog = "http://anarchism.pageabode.com/afaq/new.html";
     description = "Exhaustive exploration of Anarchist theory and practice";
diff --git a/pkgs/data/documentation/gnome-user-docs/default.nix b/pkgs/data/documentation/gnome-user-docs/default.nix
index a344dbca2f383..30f8d736d32e2 100644
--- a/pkgs/data/documentation/gnome-user-docs/default.nix
+++ b/pkgs/data/documentation/gnome-user-docs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gettext
 , gnome3
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "User and system administration help for the GNOME desktop";
     homepage = "https://help.gnome.org/users/gnome-help/";
     license = licenses.cc-by-30;
diff --git a/pkgs/data/documentation/man-pages/default.nix b/pkgs/data/documentation/man-pages/default.nix
index d4fc2eb98eb47..a8f38b1a6c6a0 100644
--- a/pkgs/data/documentation/man-pages/default.nix
+++ b/pkgs/data/documentation/man-pages/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "man-pages";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   '';
   outputDocdev = "out";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux development manual pages";
     homepage = "https://www.kernel.org/doc/man-pages/";
     repositories.git = "http://git.kernel.org/pub/scm/docs/man-pages/man-pages";
diff --git a/pkgs/data/documentation/scheme-manpages/default.nix b/pkgs/data/documentation/scheme-manpages/default.nix
index 345fb99b7bb44..2915430d9f24e 100644
--- a/pkgs/data/documentation/scheme-manpages/default.nix
+++ b/pkgs/data/documentation/scheme-manpages/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "scheme-manpages-unstable";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp -r man3/ man7/ $out/share/man/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unix manual pages for R6RS and R7RS";
     homepage = "https://github.com/schemedoc/manpages";
     license = licenses.mit;
diff --git a/pkgs/data/documentation/stdman/default.nix b/pkgs/data/documentation/stdman/default.nix
index de50f6128616f..9308c538d3556 100644
--- a/pkgs/data/documentation/stdman/default.nix
+++ b/pkgs/data/documentation/stdman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, curl, fetchFromGitHub }:
+{ lib, stdenv, curl, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "stdman";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Formatted C++17 stdlib man pages (cppreference)";
     longDescription = "stdman is a tool that parses archived HTML
       files from cppreference and generates groff-formatted manual
diff --git a/pkgs/data/documentation/zeal/default.nix b/pkgs/data/documentation/zeal/default.nix
index 4551dc2117922..7543672f7d0d5 100644
--- a/pkgs/data/documentation/zeal/default.nix
+++ b/pkgs/data/documentation/zeal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, extra-cmake-modules, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, extra-cmake-modules, pkgconfig
 , qtbase, qtimageformats, qtwebengine, qtx11extras, mkDerivation
 , libarchive, libXdmcp, libpthreadstubs, xcbutilkeysyms  }:
 
@@ -30,7 +30,7 @@ mkDerivation rec {
     libXdmcp libpthreadstubs xcbutilkeysyms
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple offline API documentation browser";
     longDescription = ''
       Zeal is a simple offline API documentation browser inspired by Dash (macOS
diff --git a/pkgs/data/fonts/alegreya-sans/default.nix b/pkgs/data/fonts/alegreya-sans/default.nix
index 4798433416545..cc0cd6cac9b90 100644
--- a/pkgs/data/fonts/alegreya-sans/default.nix
+++ b/pkgs/data/fonts/alegreya-sans/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "alegreya-sans";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -D -m 444 fonts/webfonts/*.woff2 -t $out/share/fonts/woff2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Humanist sans serif family with a calligraphic feeling";
     longDescription = ''
 Alegreya Sans is a humanist sans serif family with a calligraphic feeling that conveys a dynamic and varied rhythm. This gives a pleasant feeling to readers of long texts.
diff --git a/pkgs/data/fonts/alegreya/default.nix b/pkgs/data/fonts/alegreya/default.nix
index 99a7131dc11ac..b2ec1de0cc898 100644
--- a/pkgs/data/fonts/alegreya/default.nix
+++ b/pkgs/data/fonts/alegreya/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "alegreya";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -D -m 444 fonts/webfonts/*.woff2 -t $out/share/fonts/woff2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An elegant and versatile font family for comfortable reading";
     longDescription = ''
 Alegreya is a typeface originally intended for literature. Among its crowning characteristics, it conveys a dynamic and varied rhythm which facilitates the reading of long texts. Also, it provides freshness to the page while referring to the calligraphic letter, not as a literal interpretation, but rather in a contemporary typographic language.
diff --git a/pkgs/data/fonts/cherry/default.nix b/pkgs/data/fonts/cherry/default.nix
index a69aa3684ab43..53d9149091e80 100644
--- a/pkgs/data/fonts/cherry/default.nix
+++ b/pkgs/data/fonts/cherry/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fonttosfnt, mkfontdir }:
+{ lib, stdenv, fetchFromGitHub, fonttosfnt, mkfontdir }:
 
 stdenv.mkDerivation rec {
   pname = "cherry";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     mkfontdir $out/share/fonts/misc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "cherry font";
     homepage = "https://github.com/turquoise-hexagon/cherry";
     license = licenses.mit;
diff --git a/pkgs/data/fonts/clearlyU/default.nix b/pkgs/data/fonts/clearlyU/default.nix
index 84cf3ebc538d3..5c97d3b713445 100644
--- a/pkgs/data/fonts/clearlyU/default.nix
+++ b/pkgs/data/fonts/clearlyU/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fonttosfnt, mkfontscale, libfaketime }:
+{ lib, stdenv, fetchurl, fonttosfnt, mkfontscale, libfaketime }:
 
 stdenv.mkDerivation rec {
   pname = "clearlyU";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     mkfontdir "$fontDir"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Unicode font";
     license = licenses.mit;
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/data/fonts/comic-neue/default.nix b/pkgs/data/fonts/comic-neue/default.nix
index 13a40b8c0a06e..df618aea81108 100644
--- a/pkgs/data/fonts/comic-neue/default.nix
+++ b/pkgs/data/fonts/comic-neue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "comic-neue";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp -v ${pname}-${version}/WebFonts/*.woff2 $out/share/fonts/WOFF2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://comicneue.com/";
     description = "A casual type face: Make your lemonade stand look like a fortune 500 company";
     longDescription = ''
diff --git a/pkgs/data/fonts/corefonts/default.nix b/pkgs/data/fonts/corefonts/default.nix
index ed28f6b5e6ce4..c37d3251a9dc6 100644
--- a/pkgs/data/fonts/corefonts/default.nix
+++ b/pkgs/data/fonts/corefonts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cabextract }:
+{ lib, stdenv, fetchurl, cabextract }:
 
 let
 
@@ -61,7 +61,7 @@ stdenv.mkDerivation {
   outputHashMode = "recursive";
   outputHash = "089d2m9bvaacj36qdq77pcazji0sbbr796shic3k52cpxkjnzbwh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://corefonts.sourceforge.net/";
     description = "Microsoft's TrueType core fonts for the Web";
     platforms = platforms.all;
diff --git a/pkgs/data/fonts/creep/default.nix b/pkgs/data/fonts/creep/default.nix
index 7c7ad4d5aa915..d4748544af555 100644
--- a/pkgs/data/fonts/creep/default.nix
+++ b/pkgs/data/fonts/creep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libfaketime
+{ lib, stdenv, fetchFromGitHub, libfaketime
 , fonttosfnt, mkfontscale
 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     mkfontdir "$out/share/fonts/misc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pretty sweet 4px wide pixel font";
     homepage = "https://github.com/romeovs/creep";
     license = licenses.mit;
diff --git a/pkgs/data/fonts/dina/default.nix b/pkgs/data/fonts/dina/default.nix
index 1a8ac344a5312..2a770222ed104 100644
--- a/pkgs/data/fonts/dina/default.nix
+++ b/pkgs/data/fonts/dina/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip
+{ lib, stdenv, fetchurl, unzip
 , bdftopcf, mkfontscale, fontforge
 }:
 
@@ -49,7 +49,7 @@ stdenv.mkDerivation {
 
   outputs = [ "out" "bdf" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A monospace bitmap font aimed at programmers";
     longDescription = ''
       Dina is a monospace bitmap font, primarily aimed at programmers. It is
diff --git a/pkgs/data/fonts/emojione/default.nix b/pkgs/data/fonts/emojione/default.nix
index d5b9b29dd85df..629e46fe79711 100644
--- a/pkgs/data/fonts/emojione/default.nix
+++ b/pkgs/data/fonts/emojione/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, inkscape, imagemagick, potrace, svgo, scfbuild }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, inkscape, imagemagick, potrace, svgo, scfbuild }:
 
 stdenv.mkDerivation rec {
   pname = "emojione";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     install -Dm755 build/EmojiOneColor-SVGinOT.ttf $out/share/fonts/truetype/EmojiOneColor-SVGinOT.ttf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source emoji set";
     homepage = "http://emojione.com/";
     license = licenses.cc-by-40;
diff --git a/pkgs/data/fonts/envypn-font/default.nix b/pkgs/data/fonts/envypn-font/default.nix
index 0d69b812c4cd2..dbfb85f881fc7 100644
--- a/pkgs/data/fonts/envypn-font/default.nix
+++ b/pkgs/data/fonts/envypn-font/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libfaketime
+{ lib, stdenv, fetchurl, libfaketime
 , fonttosfnt, mkfontscale
 }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     mkfontdir "$out/share/fonts/misc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Readable bitmap font inspired by Envy Code R
     '';
diff --git a/pkgs/data/fonts/et-book/default.nix b/pkgs/data/fonts/et-book/default.nix
index 58586ba7db658..e7d97b777076e 100644
--- a/pkgs/data/fonts/et-book/default.nix
+++ b/pkgs/data/fonts/et-book/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 fetchFromGitHub rec {
   rev = "7e8f02dadcc23ba42b491b39e5bdf16e7b383031";
@@ -13,7 +13,7 @@ fetchFromGitHub rec {
     cp -t $out/share/fonts/truetype et-book-${rev}/source/4-ttf/*.ttf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The typeface used in Edward Tufte’s books.";
     license = licenses.mit;
     platforms = platforms.all;
diff --git a/pkgs/data/fonts/fira-code/default.nix b/pkgs/data/fonts/fira-code/default.nix
index a3fac2d69d0b9..546c7d905a7ba 100644
--- a/pkgs/data/fonts/fira-code/default.nix
+++ b/pkgs/data/fonts/fira-code/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 let
   version = "5.2";
@@ -15,7 +15,7 @@ in fetchzip {
 
   sha256 = "1wbfjgvr9m5azl5w49y0hpqzgcraw6spd1wnxgxlzfx57x6gcw0k";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tonsky/FiraCode";
     description = "Monospace font with programming ligatures";
     longDescription = ''
diff --git a/pkgs/data/fonts/fira-code/symbols.nix b/pkgs/data/fonts/fira-code/symbols.nix
index 624616bdd5802..2e4cfc8f05b6c 100644
--- a/pkgs/data/fonts/fira-code/symbols.nix
+++ b/pkgs/data/fonts/fira-code/symbols.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 fetchzip {
   name = "fira-code-symbols-20160811";
@@ -12,7 +12,7 @@ fetchzip {
 
   sha256 = "19krsp22rin74ix0i19v4bh1c965g18xkmz1n55h6n6qimisnbkm";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FiraCode unicode ligature glyphs in private use area";
     longDescription = ''
       FiraCode uses ligatures, which some editors don’t support.
diff --git a/pkgs/data/fonts/fira-mono/default.nix b/pkgs/data/fonts/fira-mono/default.nix
index d29d6304cee10..37f285b55527c 100644
--- a/pkgs/data/fonts/fira-mono/default.nix
+++ b/pkgs/data/fonts/fira-mono/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 fetchzip {
   name = "fira-mono-3.206";
@@ -12,7 +12,7 @@ fetchzip {
 
   sha256 = "1ci3fxhdwabvfj4nl16pwcgqnh7s2slp8vblribk8zkpx8cbp1dj";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mozilla.github.io/Fira/";
     description = "Monospace font for Firefox OS";
     longDescription = ''
diff --git a/pkgs/data/fonts/go-font/default.nix b/pkgs/data/fonts/go-font/default.nix
index e887f0ffef127..b2225f5b49bf7 100644
--- a/pkgs/data/fonts/go-font/default.nix
+++ b/pkgs/data/fonts/go-font/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit }:
+{ lib, stdenv, fetchgit }:
 
 let
   version = "2017-03-30";
@@ -17,7 +17,7 @@ in (fetchgit {
 
   sha256 = "1488426ya2nzmwjas947fx9h5wzxrp9wasn8nkjqf0y0mpd4f1xz";
 }) // {
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://blog.golang.org/go-fonts";
     description = "The Go font family";
     license = licenses.bsd3;
diff --git a/pkgs/data/fonts/gohufont/default.nix b/pkgs/data/fonts/gohufont/default.nix
index ac82c82ae3dfd..f28e3d5ba6196 100644
--- a/pkgs/data/fonts/gohufont/default.nix
+++ b/pkgs/data/fonts/gohufont/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub
+{ lib, stdenv, fetchurl, fetchFromGitHub
 , mkfontscale, bdf2psf, bdftopcf
 , fonttosfnt, libfaketime
 }:
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     mkfontdir "$fontDir"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A monospace bitmap font well suited for programming and terminal use
     '';
diff --git a/pkgs/data/fonts/google-fonts/default.nix b/pkgs/data/fonts/google-fonts/default.nix
index 153f37c88e0ac..0fac2a67bb8a8 100644
--- a/pkgs/data/fonts/google-fonts/default.nix
+++ b/pkgs/data/fonts/google-fonts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "google-fonts";
@@ -48,7 +48,7 @@ stdenv.mkDerivation {
     find . -name '*.ttf' -exec install -m 444 -Dt $dest '{}' +
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fonts.google.com";
     description = "Font files available from Google Fonts";
     license = with licenses; [ asl20 ofl ufl ];
diff --git a/pkgs/data/fonts/gubbi/default.nix b/pkgs/data/fonts/gubbi/default.nix
index 2d1c520e61031..9ae46d0899254 100644
--- a/pkgs/data/fonts/gubbi/default.nix
+++ b/pkgs/data/fonts/gubbi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fontforge }:
+{ lib, stdenv, fetchFromGitHub, fontforge }:
 
 stdenv.mkDerivation rec {
   pname = "gubbi-font";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "install -Dm444 -t $out/share/fonts/truetype/ Gubbi.ttf";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "A Kannada font";
     license = licenses.gpl3Plus;
diff --git a/pkgs/data/fonts/inconsolata/default.nix b/pkgs/data/fonts/inconsolata/default.nix
index 10568073e4b29..f064b4f619231 100644
--- a/pkgs/data/fonts/inconsolata/default.nix
+++ b/pkgs/data/fonts/inconsolata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, google-fonts }:
+{ lib, stdenv, google-fonts }:
 
 stdenv.mkDerivation {
   pname = "inconsolata";
@@ -9,7 +9,7 @@ stdenv.mkDerivation {
     install -m644 --target $out/share/fonts/truetype/inconsolata -D $src/ofl/inconsolata/*.ttf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.levien.com/type/myfonts/inconsolata.html";
     description = "A monospace font for both screen and print";
     maintainers = with maintainers; [ mikoim raskin rycee ];
diff --git a/pkgs/data/fonts/inconsolata/lgc.nix b/pkgs/data/fonts/inconsolata/lgc.nix
index e69e6e02a22f1..945fafcfcc52a 100644
--- a/pkgs/data/fonts/inconsolata/lgc.nix
+++ b/pkgs/data/fonts/inconsolata/lgc.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, fontforge}:
+{lib, stdenv, fetchFromGitHub, fontforge}:
 
 stdenv.mkDerivation rec {
   pname = "inconsolata-lgc";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -m444 -Dt $out/share/doc/${pname}-${version} LICENSE README
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fork of Inconsolata font, with proper support of Cyrillic and Greek";
     longDescription = ''
       Inconsolata is one of the most suitable font for programmers created by Raph
diff --git a/pkgs/data/fonts/input-fonts/default.nix b/pkgs/data/fonts/input-fonts/default.nix
index 2db7e259a3523..9956325e15bc4 100644
--- a/pkgs/data/fonts/input-fonts/default.nix
+++ b/pkgs/data/fonts/input-fonts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, requireFile, unzip }:
+{ lib, stdenv, requireFile, unzip }:
 
 stdenv.mkDerivation {
   pname = "input-fonts";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
   outputHashMode = "recursive";
   outputHash = "15sdhqqqd4jgk80fw7ncx49avi9cxbdgyrvnrfya0066x4q4r6lv";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fonts for Code, from Font Bureau";
     longDescription = ''
       Input is a font family designed for computer programming, data,
diff --git a/pkgs/data/fonts/iosevka/default.nix b/pkgs/data/fonts/iosevka/default.nix
index 989c2d39c19ee..0d998a4863ab8 100644
--- a/pkgs/data/fonts/iosevka/default.nix
+++ b/pkgs/data/fonts/iosevka/default.nix
@@ -92,7 +92,7 @@ stdenv.mkDerivation rec {
     updateScript = ./update-default.sh;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://be5invis.github.io/Iosevka";
     downloadPage = "https://github.com/be5invis/Iosevka/releases";
     description = ''
diff --git a/pkgs/data/fonts/jost/default.nix b/pkgs/data/fonts/jost/default.nix
index fc06a7e98438b..a8df441d9990e 100644
--- a/pkgs/data/fonts/jost/default.nix
+++ b/pkgs/data/fonts/jost/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchzip}:
+{lib, stdenv, fetchzip}:
 
 let
   version = "3.5";
@@ -13,7 +13,7 @@ in fetchzip {
 
   sha256="0l78vhmbsyfmrva5wc76pskhxqryyg8q5xddpj9g5wqsddy525dq";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/indestructible-type/Jost";
     description = "A sans serif font by Indestructible Type";
     license = licenses.ofl;
diff --git a/pkgs/data/fonts/joypixels/default.nix b/pkgs/data/fonts/joypixels/default.nix
index c19a55400fcb6..d7442b3452171 100644
--- a/pkgs/data/fonts/joypixels/default.nix
+++ b/pkgs/data/fonts/joypixels/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , config
 , acceptLicense ? config.joypixels.acceptLicense or false
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The finest emoji you can use legally (formerly EmojiOne)";
     longDescription = ''
       New for 2020! JoyPixels 6.0 includes 3,342 originally crafted icon
diff --git a/pkgs/data/fonts/kanji-stroke-order-font/default.nix b/pkgs/data/fonts/kanji-stroke-order-font/default.nix
index 7b8444c3cde78..80c97024ac366 100644
--- a/pkgs/data/fonts/kanji-stroke-order-font/default.nix
+++ b/pkgs/data/fonts/kanji-stroke-order-font/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   version = "4.003";
@@ -17,7 +17,7 @@ in stdenv.mkDerivation {
     cp *.txt $out/share/doc/kanji-stroke-order
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Font containing stroke order diagrams for over 6500 kanji, 180 kana and other characters";
     homepage = "https://sites.google.com/site/nihilistorguk/";
 
diff --git a/pkgs/data/fonts/liberation-fonts/default.nix b/pkgs/data/fonts/liberation-fonts/default.nix
index edc39ff0a40e0..04ee3781b6bb6 100644
--- a/pkgs/data/fonts/liberation-fonts/default.nix
+++ b/pkgs/data/fonts/liberation-fonts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fontforge, python3 }:
+{ lib, stdenv, fetchFromGitHub, fontforge, python3 }:
 let
   inherit (python3.pkgs) fonttools;
 
@@ -27,7 +27,7 @@ let
           install -m444 -Dt $out/share/doc/${pname}-${version} README      || true
         '';
 
-        meta = with stdenv.lib; {
+        meta = with lib; {
           description = "Liberation Fonts, replacements for Times New Roman, Arial, and Courier New";
           longDescription = ''
             The Liberation Fonts are intended to be replacements for the three most
diff --git a/pkgs/data/fonts/liberation-sans-narrow/default.nix b/pkgs/data/fonts/liberation-sans-narrow/default.nix
index 373704f25f539..281bfa4c42b0f 100644
--- a/pkgs/data/fonts/liberation-sans-narrow/default.nix
+++ b/pkgs/data/fonts/liberation-sans-narrow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fontforge, python3Packages, python3 }:
+{ lib, stdenv, fetchFromGitHub, fontforge, python3Packages, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "liberation-sans-narrow";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -m444 -Dt $out/doc/${pname}-${version} AUTHORS ChangeLog COPYING License.txt README.rst
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Liberation Sans Narrow Font Family is a replacement for Arial Narrow";
     longDescription = ''
       Liberation Sans Narrow is a font originally created by Ascender
diff --git a/pkgs/data/fonts/libertine/default.nix b/pkgs/data/fonts/libertine/default.nix
index bd47998b924f1..2120c5965e2f5 100644
--- a/pkgs/data/fonts/libertine/default.nix
+++ b/pkgs/data/fonts/libertine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fontforge }:
+{ lib, stdenv, fetchurl, fontforge }:
 
 stdenv.mkDerivation {
   name = "linux-libertine-5.3.0";
@@ -38,7 +38,7 @@ stdenv.mkDerivation {
     install -m444 -Dt $out/share/texmf/fonts/map       *.map
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux Libertine Fonts";
     homepage = "http://linuxlibertine.sf.net";
     maintainers = [ maintainers.volth ];
diff --git a/pkgs/data/fonts/libre-caslon/default.nix b/pkgs/data/fonts/libre-caslon/default.nix
index 1b5e5b1be690b..d89d4c41c0f3b 100644
--- a/pkgs/data/fonts/libre-caslon/default.nix
+++ b/pkgs/data/fonts/libre-caslon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "libre-caslon";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
   outputHashMode = "recursive";
   outputHash = "05aajwny99yqzn1nnq1blx6h7rl54x056y12hyawfbigkzxhscns";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Caslon fonts based on hand-lettered American Caslons of 1960s";
     homepage = "http://www.impallari.com/librecaslon";
     license = licenses.ofl;
diff --git a/pkgs/data/fonts/lobster-two/default.nix b/pkgs/data/fonts/lobster-two/default.nix
index d5a46b43fb493..fb1595fe2fc77 100644
--- a/pkgs/data/fonts/lobster-two/default.nix
+++ b/pkgs/data/fonts/lobster-two/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 let
 
@@ -69,7 +69,7 @@ in
     outputHashMode = "recursive";
     outputHash = "0if9l8pzwgfnbdjg5yblcy08dwn9yj3wzz29l0fycia46xlzd4ym";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/librefonts/lobstertwo";
       description = "Script font with many ligatures";
       license = licenses.ofl;
diff --git a/pkgs/data/fonts/meslo-lgs-nf/default.nix b/pkgs/data/fonts/meslo-lgs-nf/default.nix
index 36ce33cd7d2d6..305bd69f2daec 100644
--- a/pkgs/data/fonts/meslo-lgs-nf/default.nix
+++ b/pkgs/data/fonts/meslo-lgs-nf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "meslo-lgs-nf";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp $src/*.ttf $out/share/fonts/truetype
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Meslo Nerd Font patched for Powerlevel10k";
     homepage = "https://github.com/romkatv/powerlevel10k-media";
     license = licenses.asl20;
diff --git a/pkgs/data/fonts/migmix/default.nix b/pkgs/data/fonts/migmix/default.nix
index 1b3313d4e026e..bcc0666f035d1 100644
--- a/pkgs/data/fonts/migmix/default.nix
+++ b/pkgs/data/fonts/migmix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "migmix";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   outputHashMode = "recursive";
   outputHash = "1fhh8wg6lxwrnsg9rl4ihffl0bsp1wqa5gps9fx60kr6j9wpvmbg";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-quality Japanese font based on M+ fonts and IPA fonts";
     homepage = "http://mix-mplus-ipa.osdn.jp/migmix";
     license = licenses.ipa;
diff --git a/pkgs/data/fonts/migu/default.nix b/pkgs/data/fonts/migu/default.nix
index 530fd4f543f2a..09992ef5ec8c5 100644
--- a/pkgs/data/fonts/migu/default.nix
+++ b/pkgs/data/fonts/migu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "migu";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   outputHashMode = "recursive";
   outputHash = "0nbpn21cxdd6gsgr3fadzjsnz84f2swpf81wmscmjgvd56ngndzh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-quality Japanese font based on modified M+ fonts and IPA fonts";
     homepage = "http://mix-mplus-ipa.osdn.jp/migu/";
     license = licenses.ipa;
diff --git a/pkgs/data/fonts/monoid/default.nix b/pkgs/data/fonts/monoid/default.nix
index 48dc121af459c..77ef87152acf3 100644
--- a/pkgs/data/fonts/monoid/default.nix
+++ b/pkgs/data/fonts/monoid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, python3 }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, python3 }:
 
 stdenv.mkDerivation {
   pname = "monoid";
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
     install -m444 -Dt $out/share/doc            Readme.md
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://larsenwork.com/monoid";
     description = "Customisable coding font with alternates, ligatures and contextual positioning";
     license = [ licenses.ofl licenses.mit ];
diff --git a/pkgs/data/fonts/nerdfonts/default.nix b/pkgs/data/fonts/nerdfonts/default.nix
index bf98effb1508e..ceb0cb8b03afc 100644
--- a/pkgs/data/fonts/nerdfonts/default.nix
+++ b/pkgs/data/fonts/nerdfonts/default.nix
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
     ''}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Iconic font aggregator, collection, & patcher. 3,600+ icons, 50+ patched fonts";
     longDescription = ''
       Nerd Fonts is a project that attempts to patch as many developer targeted
diff --git a/pkgs/data/fonts/noto-fonts/default.nix b/pkgs/data/fonts/noto-fonts/default.nix
index 1c1d773038e76..59d1ed353f3a7 100644
--- a/pkgs/data/fonts/noto-fonts/default.nix
+++ b/pkgs/data/fonts/noto-fonts/default.nix
@@ -179,7 +179,7 @@ in
       install -D $src $out/share/fonts/blobmoji/Blobmoji.ttf
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Noto Emoji with extended Blob support";
       homepage = "https://github.com/C1710/blobmoji";
       license = with licenses; [ ofl asl20 ];
diff --git a/pkgs/data/fonts/paratype-pt/mono.nix b/pkgs/data/fonts/paratype-pt/mono.nix
index 54dbe3abf4eaf..eecab47c08790 100644
--- a/pkgs/data/fonts/paratype-pt/mono.nix
+++ b/pkgs/data/fonts/paratype-pt/mono.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 fetchzip {
   name = "paratype-pt-mono";
@@ -16,7 +16,7 @@ fetchzip {
 
   sha256 = "07kl82ngby55khvzsvn831ddpc0q8djgz2y6gsjixkyjfdk2xjjm";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.paratype.ru/public/";
     description = "An open Paratype font";
 
diff --git a/pkgs/data/fonts/paratype-pt/sans.nix b/pkgs/data/fonts/paratype-pt/sans.nix
index afaba6804f8b9..826b8887365ef 100644
--- a/pkgs/data/fonts/paratype-pt/sans.nix
+++ b/pkgs/data/fonts/paratype-pt/sans.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 fetchzip {
   name = "paratype-pt-sans";
@@ -16,7 +16,7 @@ fetchzip {
 
   sha256 = "01fkd417gv98jf3a6zyfi9w2dkqsbddy1vacga2672yf0kh1z1r0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.paratype.ru/public/";
     description = "An open Paratype font";
 
diff --git a/pkgs/data/fonts/paratype-pt/serif.nix b/pkgs/data/fonts/paratype-pt/serif.nix
index a6f21e425f8d2..bbff974e10712 100644
--- a/pkgs/data/fonts/paratype-pt/serif.nix
+++ b/pkgs/data/fonts/paratype-pt/serif.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 fetchzip {
   name = "paratype-pt-serif";
@@ -16,7 +16,7 @@ fetchzip {
 
   sha256 = "1iw5qi4ag3yp1lwmi91lb18gr768bqwl46xskaqnkhr9i9qp0v6d";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.paratype.ru/public/";
     description = "An open Paratype font";
 
diff --git a/pkgs/data/fonts/profont/default.nix b/pkgs/data/fonts/profont/default.nix
index 6297a8fbb204e..3570bf7bf91ad 100644
--- a/pkgs/data/fonts/profont/default.nix
+++ b/pkgs/data/fonts/profont/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, mkfontscale }:
+{ lib, stdenv, fetchzip, mkfontscale }:
 
 stdenv.mkDerivation {
   pname = "profont";
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
     mkfontdir "$out/share/fonts/misc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tobiasjung.name/profont/";
     description = "A monospaced font created to be a most readable font for programming";
     maintainers = with maintainers; [ myrl ];
diff --git a/pkgs/data/fonts/proggyfonts/default.nix b/pkgs/data/fonts/proggyfonts/default.nix
index 7ddfd69aeeb4c..81ecb73540957 100644
--- a/pkgs/data/fonts/proggyfonts/default.nix
+++ b/pkgs/data/fonts/proggyfonts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mkfontscale }:
+{ lib, stdenv, fetchurl, mkfontscale }:
 
 stdenv.mkDerivation {
   name = "proggyfonts-0.1";
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
   outputHashMode = "recursive";
   outputHash = "1x196rp3wqjd7m57bgp5kfy5jmj97qncxi1vwibs925ji7dqzfgf";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://upperbounds.net";
     description = "A set of fixed-width screen fonts that are designed for code listings";
     license = licenses.mit;
diff --git a/pkgs/data/fonts/ricty/default.nix b/pkgs/data/fonts/ricty/default.nix
index 13cb056dc454a..435cdb7d163b2 100644
--- a/pkgs/data/fonts/ricty/default.nix
+++ b/pkgs/data/fonts/ricty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, google-fonts, migu, fontforge, which }:
+{ lib, stdenv, fetchurl, google-fonts, migu, fontforge, which }:
 
 stdenv.mkDerivation rec {
   pname = "ricty";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     install -m644 --target $out/share/fonts/truetype/ricty -D Ricty-*.ttf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-quality Japanese font based on Inconsolata and Migu 1M";
     homepage = "http://www.yusa.lab.uec.ac.jp/~yusa/ricty.html";
     license = licenses.unfree;
diff --git a/pkgs/data/fonts/rictydiminished-with-firacode/default.nix b/pkgs/data/fonts/rictydiminished-with-firacode/default.nix
index 0f90c13d11ebf..ceed830700406 100644
--- a/pkgs/data/fonts/rictydiminished-with-firacode/default.nix
+++ b/pkgs/data/fonts/rictydiminished-with-firacode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fontforge, python3 }:
+{ lib, stdenv, fetchgit, fontforge, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "rictydiminished-with-firacode";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     ]))
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hakatashi/RictyDiminished-with-FiraCode";
     description = "The best Japanese programming font meets the awesome ligatures of Firacode";
     license = licenses.ofl;
diff --git a/pkgs/data/fonts/roboto-mono/default.nix b/pkgs/data/fonts/roboto-mono/default.nix
index 9bb6552680141..fd3372123c608 100644
--- a/pkgs/data/fonts/roboto-mono/default.nix
+++ b/pkgs/data/fonts/roboto-mono/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   # Latest commit touching the robotomono tree
@@ -67,7 +67,7 @@ stdenv.mkDerivation {
   outputHashMode = "recursive";
   outputHash = "0fkx2z97k29n1392bf76iwdyz44yp86hmqah7ai6bikzlia38qa0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.google.com/fonts/specimen/Roboto+Mono";
     description = "Google Roboto Mono fonts";
     longDescription = ''
diff --git a/pkgs/data/fonts/roboto-slab/default.nix b/pkgs/data/fonts/roboto-slab/default.nix
index 1fec03b46fe45..dc37c8258564c 100644
--- a/pkgs/data/fonts/roboto-slab/default.nix
+++ b/pkgs/data/fonts/roboto-slab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "roboto-slab";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
   outputHashMode = "recursive";
   outputHash = "0g663npi5lkvwcqafd4cjrm90ph0nv1lig7d19xzfymnj47qpj8x";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.google.com/fonts/specimen/Roboto+Slab";
     description = "Roboto Slab Typeface by Google";
     longDescription = ''
diff --git a/pkgs/data/fonts/siji/default.nix b/pkgs/data/fonts/siji/default.nix
index fb13f82263dd7..ea2d2b687d53b 100644
--- a/pkgs/data/fonts/siji/default.nix
+++ b/pkgs/data/fonts/siji/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, libfaketime, fonttosfnt, mkfontscale }:
+{ lib, stdenv, fetchzip, libfaketime, fonttosfnt, mkfontscale }:
 
 stdenv.mkDerivation rec {
   name = "siji-${version}";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "bdf" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/stark/siji";
     description = "An iconic bitmap font based on Stlarch with additional glyphs";
     license = licenses.gpl2;
diff --git a/pkgs/data/fonts/tamsyn/default.nix b/pkgs/data/fonts/tamsyn/default.nix
index 4d1e58a6bb34b..6f0886e1d971f 100644
--- a/pkgs/data/fonts/tamsyn/default.nix
+++ b/pkgs/data/fonts/tamsyn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fontforge, mkfontscale }:
+{ lib, stdenv, fetchurl, fontforge, mkfontscale }:
 
 let
   version = "1.11";
@@ -34,7 +34,7 @@ in stdenv.mkDerivation {
     mkfontdir "$out/share/fonts/misc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A monospace bitmap font aimed at programmers";
     longDescription = ''Tamsyn is a monospace bitmap font, primarily aimed at
     programmers. It was derived from Gilles Boccon-Gibod's MonteCarlo. Tamsyn
diff --git a/pkgs/data/fonts/tamzen/default.nix b/pkgs/data/fonts/tamzen/default.nix
index 026ec63d670e3..80212a14aebfb 100644
--- a/pkgs/data/fonts/tamzen/default.nix
+++ b/pkgs/data/fonts/tamzen/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, mkfontscale, stdenv }:
+{ fetchFromGitHub, mkfontscale, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   pname = "tamzen-font";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     mkfontdir "$out/share/fonts/misc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bitmapped programming font based on Tamsyn";
     longDescription = ''
     Tamzen is a monospace bitmap font. It is programatically forked
diff --git a/pkgs/data/fonts/terminus-font/default.nix b/pkgs/data/fonts/terminus-font/default.nix
index bbde1dd252c39..fca357706a603 100644
--- a/pkgs/data/fonts/terminus-font/default.nix
+++ b/pkgs/data/fonts/terminus-font/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3
+{ lib, stdenv, fetchurl, python3
 , libfaketime, fonttosfnt
 , bdftopcf, mkfontscale
 }:
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   installTargets = [ "install" "fontdir" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A clean fixed width font";
     longDescription = ''
       Terminus Font is designed for long (8 and more hours per day) work
diff --git a/pkgs/data/fonts/tewi/default.nix b/pkgs/data/fonts/tewi/default.nix
index 7821cc6604120..1cf31b5affe76 100644
--- a/pkgs/data/fonts/tewi/default.nix
+++ b/pkgs/data/fonts/tewi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3
+{ lib, stdenv, fetchFromGitHub, python3
 , bdftopcf, mkfontscale
 , libfaketime, fonttosfnt
 }:
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     mkfontdir "$fontDir"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A nice bitmap font, readable even at small sizes";
     longDescription = ''
       Tewi is a bitmap font, readable even at very small font sizes. This is
diff --git a/pkgs/data/fonts/tex-gyre-math/default.nix b/pkgs/data/fonts/tex-gyre-math/default.nix
index cd3c3ab00b180..92898be0f3ff2 100644
--- a/pkgs/data/fonts/tex-gyre-math/default.nix
+++ b/pkgs/data/fonts/tex-gyre-math/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 let
   variants = {
@@ -48,7 +48,7 @@ let
       outputHashMode = "recursive";
       inherit outputHash;
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         longDescription = ''
           TeX Gyre ${displayName} Math is a math companion for the TeX Gyre
           ${displayName} family of fonts (see
diff --git a/pkgs/data/fonts/tex-gyre/default.nix b/pkgs/data/fonts/tex-gyre/default.nix
index 197d14c3f03e1..333da24e95f33 100644
--- a/pkgs/data/fonts/tex-gyre/default.nix
+++ b/pkgs/data/fonts/tex-gyre/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 let
   mkVariant = variant: { version, abbreviation, sha256, outputHash }: stdenv.mkDerivation {
@@ -22,7 +22,7 @@ let
     outputHashMode = "recursive";
     inherit outputHash;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://www.gust.org.pl/projects/e-foundry/tex-gyre";
       # "The TeX Gyre fonts are licensed under the GUST Font License (GFL),
       # which is a free license, legally equivalent to the LaTeX Project Public
diff --git a/pkgs/data/fonts/tlwg/default.nix b/pkgs/data/fonts/tlwg/default.nix
index 2e3a0a95c0552..9c03bbb162f52 100644
--- a/pkgs/data/fonts/tlwg/default.nix
+++ b/pkgs/data/fonts/tlwg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, fontforge }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, fontforge }:
 
 stdenv.mkDerivation rec {
   pname = "tlwg";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   preAutoreconf = "echo ${version} > VERSION";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of Thai scalable fonts available under free licenses";
     homepage = "https://linux.thai.net/projects/fonts-tlwg";
     license = with licenses; [ gpl2 publicDomain lppl13c free ];
diff --git a/pkgs/data/fonts/ttf-tw-moe/default.nix b/pkgs/data/fonts/ttf-tw-moe/default.nix
index 1115b48b70954..6957928944269 100644
--- a/pkgs/data/fonts/ttf-tw-moe/default.nix
+++ b/pkgs/data/fonts/ttf-tw-moe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 let
   version = "2020-11-14";
 in
@@ -14,7 +14,7 @@ fetchzip {
 
   sha256 = "1jd3gjjfa4vadp6d499n0irz5b22z611kd7q5qgqf6s2fwbxfhiz";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.moe.gov.tw/";
     description = "Set of KAI and SONG fonts from the Ministry of Education of Taiwan";
     version = version;
diff --git a/pkgs/data/fonts/twemoji-color-font/default.nix b/pkgs/data/fonts/twemoji-color-font/default.nix
index 23ae8e76b1d5b..5e690e7fd6f26 100644
--- a/pkgs/data/fonts/twemoji-color-font/default.nix
+++ b/pkgs/data/fonts/twemoji-color-font/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, inkscape, imagemagick, potrace, svgo, scfbuild }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, inkscape, imagemagick, potrace, svgo, scfbuild }:
 
 stdenv.mkDerivation rec {
   pname = "twemoji-color-font";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     install -Dm644 linux/fontconfig/56-twemoji-color.conf $out/etc/fonts/conf.d/56-twemoji-color.conf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Color emoji SVGinOT font using Twitter Unicode 10 emoji with diversity and country flags";
     longDescription = ''
       A color and B&W emoji SVGinOT font built from the Twitter Emoji for
diff --git a/pkgs/data/fonts/twitter-color-emoji/default.nix b/pkgs/data/fonts/twitter-color-emoji/default.nix
index 8435957fe2011..de70a0b6c6a0f 100644
--- a/pkgs/data/fonts/twitter-color-emoji/default.nix
+++ b/pkgs/data/fonts/twitter-color-emoji/default.nix
@@ -1,7 +1,7 @@
 # Based upon https://src.fedoraproject.org/rpms/twitter-twemoji-fonts
 # The main difference is that we use “Twitter Color Emoji” name (which is recognized by upstream fontconfig)
 
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cairo
 , imagemagick
@@ -91,7 +91,7 @@ stdenv.mkDerivation rec {
     install -Dm644 TwitterColorEmoji.ttf $out/share/fonts/truetype/TwitterColorEmoji.ttf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Color emoji font with a flat visual style, designed and used by Twitter";
     longDescription = ''
       A bitmap color emoji font built from the Twitter Emoji for
diff --git a/pkgs/data/fonts/ucs-fonts/default.nix b/pkgs/data/fonts/ucs-fonts/default.nix
index 71c42c46b5d49..7bb9930ccfca9 100644
--- a/pkgs/data/fonts/ucs-fonts/default.nix
+++ b/pkgs/data/fonts/ucs-fonts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bdftopcf
+{ lib, stdenv, fetchurl, bdftopcf
 , libfaketime, fonttosfnt, mkfontscale
 }:
 
@@ -51,7 +51,7 @@ stdenv.mkDerivation {
 
   outputs = [ "out" "bdf" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.cl.cam.ac.uk/~mgk25/ucs-fonts.html";
     description = "Unicode bitmap fonts";
     license = licenses.publicDomain;
diff --git a/pkgs/data/fonts/unifont/default.nix b/pkgs/data/fonts/unifont/default.nix
index 3a9f107c4c7ed..507faae53e356 100644
--- a/pkgs/data/fonts/unifont/default.nix
+++ b/pkgs/data/fonts/unifont/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mkfontscale
+{ lib, stdenv, fetchurl, mkfontscale
 , libfaketime, fonttosfnt
 }:
 
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
       mkfontscale
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unicode font for Base Multilingual Plane";
     homepage = "http://unifoundry.com/unifont.html";
 
diff --git a/pkgs/data/fonts/uw-ttyp0/default.nix b/pkgs/data/fonts/uw-ttyp0/default.nix
index b0e58faed6027..a3c3f7b68aa74 100644
--- a/pkgs/data/fonts/uw-ttyp0/default.nix
+++ b/pkgs/data/fonts/uw-ttyp0/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl
+{ lib, stdenv, fetchurl, perl
 , bdftopcf, bdf2psf, mkfontdir
 , fonttosfnt
 , targetsDat  ? null
@@ -80,7 +80,7 @@ stdenv.mkDerivation rec {
     runHook postConfigure
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Monospace bitmap screen fonts for X11";
     homepage = "https://people.mpi-inf.mpg.de/~uwe/misc/uw-ttyp0/";
     license = with licenses; [ free mit ];
diff --git a/pkgs/data/fonts/xits-math/default.nix b/pkgs/data/fonts/xits-math/default.nix
index dfb38973edd92..9e3c013f44ded 100644
--- a/pkgs/data/fonts/xits-math/default.nix
+++ b/pkgs/data/fonts/xits-math/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages}:
+{ lib, stdenv, fetchFromGitHub, python3Packages}:
 
 stdenv.mkDerivation rec {
   pname = "xits-math";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -m444 -Dt $out/share/fonts/opentype *.otf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/alif-type/xits";
     description = "OpenType implementation of STIX fonts with math support";
     license = licenses.ofl;
diff --git a/pkgs/data/icons/arc-icon-theme/default.nix b/pkgs/data/icons/arc-icon-theme/default.nix
index ab80305d52850..6b7de57a4ff12 100644
--- a/pkgs/data/icons/arc-icon-theme/default.nix
+++ b/pkgs/data/icons/arc-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, gtk3, gnome3, moka-icon-theme, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, gtk3, gnome3, moka-icon-theme, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "arc-icon-theme";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   postFixup = "gtk-update-icon-cache $out/share/icons/Arc";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Arc icon theme";
     homepage = "https://github.com/horst3180/arc-icon-theme";
     license = licenses.gpl3;
diff --git a/pkgs/data/icons/capitaine-cursors/default.nix b/pkgs/data/icons/capitaine-cursors/default.nix
index e57482b191b7f..075dbc922bd48 100644
--- a/pkgs/data/icons/capitaine-cursors/default.nix
+++ b/pkgs/data/icons/capitaine-cursors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, makeFontsConf
+{ lib, stdenv, fetchFromGitHub, fetchpatch, makeFontsConf
 , inkscape, xcursorgen, bc }:
 
 stdenv.mkDerivation rec {
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     cp -pr dist/light $out/share/icons/capitaine-cursors-white
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An x-cursor theme inspired by macOS and based on KDE Breeze";
     homepage = "https://github.com/keeferrourke/capitaine-cursors";
     license = licenses.lgpl3;
diff --git a/pkgs/data/icons/elementary-xfce-icon-theme/default.nix b/pkgs/data/icons/elementary-xfce-icon-theme/default.nix
index 52f9c8c821fe8..adf2139d0cefd 100644
--- a/pkgs/data/icons/elementary-xfce-icon-theme/default.nix
+++ b/pkgs/data/icons/elementary-xfce-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, gdk-pixbuf, optipng, librsvg, gtk3, pantheon, gnome3, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, gdk-pixbuf, optipng, librsvg, gtk3, pantheon, gnome3, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "elementary-xfce-icon-theme";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     make icon-caches
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Elementary icons for Xfce and other GTK desktops like GNOME";
     homepage = "https://github.com/shimmerproject/elementary-xfce";
     license = licenses.gpl2;
diff --git a/pkgs/data/icons/faba-icon-theme/default.nix b/pkgs/data/icons/faba-icon-theme/default.nix
index 9df47f8faa7c2..6ccd4c4622fa7 100644
--- a/pkgs/data/icons/faba-icon-theme/default.nix
+++ b/pkgs/data/icons/faba-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, python3, gtk3, pantheon, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, python3, gtk3, pantheon, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   name = "${package-name}-${version}";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A sexy and modern icon theme with Tango influences";
     homepage = "https://snwh.org/moka";
     license = with licenses; [ cc-by-sa-40 gpl3 ];
diff --git a/pkgs/data/icons/faba-mono-icons/default.nix b/pkgs/data/icons/faba-mono-icons/default.nix
index e403ba753ecc6..0627c87bfc5ee 100644
--- a/pkgs/data/icons/faba-mono-icons/default.nix
+++ b/pkgs/data/icons/faba-mono-icons/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, gtk3, moka-icon-theme, faba-icon-theme, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, gtk3, moka-icon-theme, faba-icon-theme, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "faba-mono-icons";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The full set of Faba monochrome panel icons";
     homepage = "https://snwh.org/moka";
     license = licenses.gpl3;
diff --git a/pkgs/data/icons/flat-remix-icon-theme/default.nix b/pkgs/data/icons/flat-remix-icon-theme/default.nix
index aea76738d82fa..743bcba54de21 100644
--- a/pkgs/data/icons/flat-remix-icon-theme/default.nix
+++ b/pkgs/data/icons/flat-remix-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , gtk3, breeze-icons, pantheon, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub , gtk3, breeze-icons, pantheon, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec  {
   pname = "flat-remix-icon-theme";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec  {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat remix is a pretty simple icon theme inspired on material design";
     homepage = "https://drasite.com/flat-remix";
     license = with licenses; [ gpl3 ];
diff --git a/pkgs/data/icons/gnome-icon-theme/default.nix b/pkgs/data/icons/gnome-icon-theme/default.nix
index 30dacbae740db..9879f8da342d7 100644
--- a/pkgs/data/icons/gnome-icon-theme/default.nix
+++ b/pkgs/data/icons/gnome-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, iconnamingutils, gtk2 }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, iconnamingutils, gtk2 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-icon-theme";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     rm -r "$out/share/locale"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of icons for the GNOME 2 desktop";
     homepage = "https://download.gnome.org/sources/gnome-icon-theme/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/data/icons/hicolor-icon-theme/default.nix b/pkgs/data/icons/hicolor-icon-theme/default.nix
index 5eefce81a1293..3a8839844f118 100644
--- a/pkgs/data/icons/hicolor-icon-theme/default.nix
+++ b/pkgs/data/icons/hicolor-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "hicolor-icon-theme-0.17";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Default fallback theme used by implementations of the icon theme specification";
     homepage = "https://icon-theme.freedesktop.org/releases/";
     platforms = platforms.unix;
diff --git a/pkgs/data/icons/humanity-icon-theme/default.nix b/pkgs/data/icons/humanity-icon-theme/default.nix
index 62085110f5134..13ee96d049985 100644
--- a/pkgs/data/icons/humanity-icon-theme/default.nix
+++ b/pkgs/data/icons/humanity-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk3, gnome3, hicolor-icon-theme }:
+{ lib, stdenv, fetchurl, gtk3, gnome3, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "humanity-icon-theme";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Humanity icons from Ubuntu";
     homepage = "https://launchpad.net/humanity/";
     license = licenses.gpl2;
diff --git a/pkgs/data/icons/iconpack-jade/default.nix b/pkgs/data/icons/iconpack-jade/default.nix
index 4c6b84479a7ab..7d13476d73ecb 100644
--- a/pkgs/data/icons/iconpack-jade/default.nix
+++ b/pkgs/data/icons/iconpack-jade/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "iconpack-jade";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Icon pack based upon Faenza and Mint-X";
     homepage = "https://github.com/madmaxms/iconpack-jade";
     license = licenses.lgpl3;
diff --git a/pkgs/data/icons/iconpack-obsidian/default.nix b/pkgs/data/icons/iconpack-obsidian/default.nix
index 165801f52eb82..ae3bf79d79aae 100644
--- a/pkgs/data/icons/iconpack-obsidian/default.nix
+++ b/pkgs/data/icons/iconpack-obsidian/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, gnome-icon-theme, mint-x-icons, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, gnome-icon-theme, mint-x-icons, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "iconpack-obsidian";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnome icon pack based upon Faenza";
     homepage = "https://github.com/madmaxms/iconpack-obsidian";
     license = licenses.lgpl3;
diff --git a/pkgs/data/icons/iso-flags/default.nix b/pkgs/data/icons/iso-flags/default.nix
index b329a151c7282..4252853b898ca 100644
--- a/pkgs/data/icons/iso-flags/default.nix
+++ b/pkgs/data/icons/iso-flags/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , perl
 , perlPackages
@@ -37,7 +37,7 @@ stdenv.mkDerivation {
     mv build $out/share/iso-flags
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/joielechong/iso-country-flags-svg-collection";
     description = "248 country flag SVG & PNG icons with different icon styles";
     license = [ licenses.publicDomain ];
diff --git a/pkgs/data/icons/kora-icon-theme/default.nix b/pkgs/data/icons/kora-icon-theme/default.nix
index cd5f9f758792a..9c64ed4b49724 100644
--- a/pkgs/data/icons/kora-icon-theme/default.nix
+++ b/pkgs/data/icons/kora-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , gtk3, breeze-icons, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub , gtk3, breeze-icons, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec  {
   pname = "kora-icon-theme";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec  {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An SVG icon theme in four variants";
     homepage = "https://github.com/bikass/kora";
     license = with licenses; [ gpl3Only ];
diff --git a/pkgs/data/icons/luna-icons/default.nix b/pkgs/data/icons/luna-icons/default.nix
index b0de2ac3b1320..702d4293f2a0f 100644
--- a/pkgs/data/icons/luna-icons/default.nix
+++ b/pkgs/data/icons/luna-icons/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gtk3
 , breeze-icons
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Icon pack based on marwaita and papirus icons";
     homepage = "https://github.com/darkomarko42/Luna-Icons";
     license = [ licenses.gpl3Only ];
diff --git a/pkgs/data/icons/maia-icon-theme/default.nix b/pkgs/data/icons/maia-icon-theme/default.nix
index 2a6dbc512acca..75c7cd58007a0 100644
--- a/pkgs/data/icons/maia-icon-theme/default.nix
+++ b/pkgs/data/icons/maia-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , cmake
 , extra-cmake-modules
@@ -41,7 +41,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Icons based on Breeze and Super Flat Remix";
     homepage = "https://gitlab.manjaro.org/artwork/themes/maia";
     license = licenses.lgpl3;
diff --git a/pkgs/data/icons/moka-icon-theme/default.nix b/pkgs/data/icons/moka-icon-theme/default.nix
index d481f2df8d6ef..5e67fdc9cc934 100644
--- a/pkgs/data/icons/moka-icon-theme/default.nix
+++ b/pkgs/data/icons/moka-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, gtk3, python3, faba-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, gtk3, python3, faba-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "moka-icon-theme";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An icon theme designed with a minimal flat style using simple geometry and bright colours";
     homepage = "https://snwh.org/moka";
     license = with licenses; [ cc-by-sa-40 gpl3 ];
diff --git a/pkgs/data/icons/numix-cursor-theme/default.nix b/pkgs/data/icons/numix-cursor-theme/default.nix
index 7ff3c4ca23c4f..377cf05ac179f 100644
--- a/pkgs/data/icons/numix-cursor-theme/default.nix
+++ b/pkgs/data/icons/numix-cursor-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, inkscape, xcursorgen }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, inkscape, xcursorgen }:
 
 stdenv.mkDerivation rec {
   version = "1.1";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     cp -dr --no-preserve='ownership' Numix-Cursor{,-Light} $out/share/icons/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Numix cursor theme";
     homepage = "https://numixproject.github.io";
     license = licenses.gpl3;
diff --git a/pkgs/data/icons/numix-icon-theme-circle/default.nix b/pkgs/data/icons/numix-icon-theme-circle/default.nix
index ef06c2e2532ad..e46c7a4289bb6 100644
--- a/pkgs/data/icons/numix-icon-theme-circle/default.nix
+++ b/pkgs/data/icons/numix-icon-theme-circle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, numix-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, numix-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "numix-icon-theme-circle";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Numix icon theme (circle version)";
     homepage = "https://numixproject.github.io";
     license = licenses.gpl3;
diff --git a/pkgs/data/icons/numix-icon-theme-square/default.nix b/pkgs/data/icons/numix-icon-theme-square/default.nix
index b0b4e20073a45..bc243b95afc84 100644
--- a/pkgs/data/icons/numix-icon-theme-square/default.nix
+++ b/pkgs/data/icons/numix-icon-theme-square/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, numix-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, numix-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "numix-icon-theme-square";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Numix icon theme (square version)";
     homepage = "https://numixproject.github.io";
     license = licenses.gpl3;
diff --git a/pkgs/data/icons/numix-icon-theme/default.nix b/pkgs/data/icons/numix-icon-theme/default.nix
index 30e212629e864..d8e583b4bbb80 100644
--- a/pkgs/data/icons/numix-icon-theme/default.nix
+++ b/pkgs/data/icons/numix-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "numix-icon-theme";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Numix icon theme";
     homepage = "https://numixproject.github.io";
     license = licenses.gpl3;
diff --git a/pkgs/data/icons/paper-icon-theme/default.nix b/pkgs/data/icons/paper-icon-theme/default.nix
index 585190a7b382c..c84369a8a4a94 100644
--- a/pkgs/data/icons/paper-icon-theme/default.nix
+++ b/pkgs/data/icons/paper-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, gtk3, python3, gnome3, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, gtk3, python3, gnome3, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "paper-icon-theme";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     gtk-update-icon-cache "$out"/share/icons/Paper-Mono-Dark;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern icon theme designed around bold colours and simple geometric shapes";
     homepage = "https://snwh.org/paper";
     license = with licenses; [ cc-by-sa-40 lgpl3 ];
diff --git a/pkgs/data/icons/papirus-icon-theme/default.nix b/pkgs/data/icons/papirus-icon-theme/default.nix
index 0f4d0d1d90c74..b790134618214 100644
--- a/pkgs/data/icons/papirus-icon-theme/default.nix
+++ b/pkgs/data/icons/papirus-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, pantheon, breeze-icons, gnome-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, pantheon, breeze-icons, gnome-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "papirus-icon-theme";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Papirus icon theme";
     homepage = "https://github.com/PapirusDevelopmentTeam/papirus-icon-theme";
     license = licenses.lgpl3;
diff --git a/pkgs/data/icons/papirus-maia-icon-theme/default.nix b/pkgs/data/icons/papirus-maia-icon-theme/default.nix
index 4cfe50d7836bc..814d9ced017bc 100644
--- a/pkgs/data/icons/papirus-maia-icon-theme/default.nix
+++ b/pkgs/data/icons/papirus-maia-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, gtk3, breeze-icons, gnome-icon-theme, papirus-icon-theme, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, cmake, gtk3, breeze-icons, gnome-icon-theme, papirus-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "papirus-maia-icon-theme";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manjaro variation of Papirus icon theme";
     homepage = "https://github.com/Ste74/papirus-maia-icon-theme";
     license = licenses.lgpl3;
diff --git a/pkgs/data/icons/pop-icon-theme/default.nix b/pkgs/data/icons/pop-icon-theme/default.nix
index 76b393dcf791f..cb7db20d67cac 100644
--- a/pkgs/data/icons/pop-icon-theme/default.nix
+++ b/pkgs/data/icons/pop-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
 
   dontDropIconThemeCache = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Icon theme for Pop!_OS with a semi-flat design and raised 3D motifs";
     homepage = "https://github.com/pop-os/icon-theme";
     license = with licenses; [ cc-by-sa-40 gpl3 ];
diff --git a/pkgs/data/icons/qogir-icon-theme/default.nix b/pkgs/data/icons/qogir-icon-theme/default.nix
index 1d677f1457dfb..e647b02f0109d 100644
--- a/pkgs/data/icons/qogir-icon-theme/default.nix
+++ b/pkgs/data/icons/qogir-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "qogir-icon-theme";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     name= ./install.sh -d $out/share/icons
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat colorful design icon theme";
     homepage = "https://github.com/vinceliuice/Qogir-icon-theme";
     license = with licenses; [ gpl3 ];
diff --git a/pkgs/data/icons/zafiro-icons/default.nix b/pkgs/data/icons/zafiro-icons/default.nix
index d406ae50e1c34..f6c56aa3c0fcf 100644
--- a/pkgs/data/icons/zafiro-icons/default.nix
+++ b/pkgs/data/icons/zafiro-icons/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, breeze-icons, gnome-icon-theme, numix-icon-theme, numix-icon-theme-circle, hicolor-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, gtk3, breeze-icons, gnome-icon-theme, numix-icon-theme, numix-icon-theme-circle, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "zafiro-icons";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     gtk-update-icon-cache "$out"/share/icons/Zafiro-icons
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Icon pack flat with light colors";
     homepage = "https://github.com/zayronxio/Zafiro-icons";
     license = with licenses; [ gpl3 ];
diff --git a/pkgs/data/misc/adapta-backgrounds/default.nix b/pkgs/data/misc/adapta-backgrounds/default.nix
index 1c35d3deef910..029961f6c52b3 100644
--- a/pkgs/data/misc/adapta-backgrounds/default.nix
+++ b/pkgs/data/misc/adapta-backgrounds/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, glib }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, glib }:
 
 stdenv.mkDerivation rec {
   pname = "adapta-backgrounds";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ meson ninja pkgconfig glib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wallpaper collection for adapta-project";
     homepage = "https://github.com/adapta-project/adapta-backgrounds";
     license = with licenses; [ gpl2 cc-by-sa-40 ];
diff --git a/pkgs/data/misc/brise/default.nix b/pkgs/data/misc/brise/default.nix
index 4f5b2e972e13f..f4e1a6d2905f5 100644
--- a/pkgs/data/misc/brise/default.nix
+++ b/pkgs/data/misc/brise/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, librime }:
+{ lib, stdenv, fetchFromGitHub, librime }:
 
 stdenv.mkDerivation {
   name = "brise-unstable-2017-09-16";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rime Schema Repository";
     longDescription = ''
       This software is a collection of data packages used by Rime
diff --git a/pkgs/data/misc/cldr-emoji-annotation/default.nix b/pkgs/data/misc/cldr-emoji-annotation/default.nix
index 8164012b69aef..e51f5639cbc64 100644
--- a/pkgs/data/misc/cldr-emoji-annotation/default.nix
+++ b/pkgs/data/misc/cldr-emoji-annotation/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 }:
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     autoreconfHook
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Emoji annotation files in CLDR";
     homepage = "https://www.unicode.org/";
     license = licenses.unicode-dfs-2016;
diff --git a/pkgs/data/misc/combinatorial_designs/default.nix b/pkgs/data/misc/combinatorial_designs/default.nix
index a14e13749589f..5457b4e54d4bf 100644
--- a/pkgs/data/misc/combinatorial_designs/default.nix
+++ b/pkgs/data/misc/combinatorial_designs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     mv * "$out/share/combinatorial_designs"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Data for Combinatorial Designs";
     longDescription = ''
       Current content:
diff --git a/pkgs/data/misc/conway_polynomials/default.nix b/pkgs/data/misc/conway_polynomials/default.nix
index d6413439dede6..f7da9381e6107 100644
--- a/pkgs/data/misc/conway_polynomials/default.nix
+++ b/pkgs/data/misc/conway_polynomials/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python
 }:
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     ${pythonEnv.interpreter} ${spkg-install}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Contains a small database of Conway polynomials";
     license = licenses.gpl2;
     platforms = platforms.all;
diff --git a/pkgs/data/misc/ddccontrol-db/default.nix b/pkgs/data/misc/ddccontrol-db/default.nix
index d0d18d473358a..6cb0c46e5f55c 100644
--- a/pkgs/data/misc/ddccontrol-db/default.nix
+++ b/pkgs/data/misc/ddccontrol-db/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoconf
 , automake
 , libtool
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
       intltool
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Monitor database for DDCcontrol";
     homepage = "https://github.com/ddccontrol/ddccontrol-db";
     license = licenses.gpl2;
diff --git a/pkgs/data/misc/elliptic_curves/default.nix b/pkgs/data/misc/elliptic_curves/default.nix
index 9b296487670db..988716f5429eb 100644
--- a/pkgs/data/misc/elliptic_curves/default.nix
+++ b/pkgs/data/misc/elliptic_curves/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python
 }:
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     ${python.interpreter} ${spkg-install}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Databases of elliptic curves";
     longDescription = ''
       Includes two databases:
diff --git a/pkgs/data/misc/freepats/default.nix b/pkgs/data/misc/freepats/default.nix
index a1fa49bae27dc..3ba5e1b61de15 100644
--- a/pkgs/data/misc/freepats/default.nix
+++ b/pkgs/data/misc/freepats/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "freepats-20060219";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   installPhase = ''mkdir "$out"; cp -r . "$out"'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Instrument patches, for MIDI synthesizers";
     longDescription = ''
       Freepats is a project to create a free and open set of instrument
diff --git a/pkgs/data/misc/geolite-legacy/default.nix b/pkgs/data/misc/geolite-legacy/default.nix
index 4fcbe8d02832f..735a660894926 100644
--- a/pkgs/data/misc/geolite-legacy/default.nix
+++ b/pkgs/data/misc/geolite-legacy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   fetchDB = src: sha256: fetchurl {
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     "asnum/GeoIPASNumv6.dat.gz"
     "1qyq4h8cja62giv6q1qqc502vsq53wzz1kx80mgvwngmycrxa21k";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GeoLite Legacy IP geolocation databases";
     homepage = "https://geolite.maxmind.com/download/geoip";
     license = licenses.cc-by-sa-30;
diff --git a/pkgs/data/misc/graphs/default.nix b/pkgs/data/misc/graphs/default.nix
index bf7f8d4fd0e83..54b6c16613e8a 100644
--- a/pkgs/data/misc/graphs/default.nix
+++ b/pkgs/data/misc/graphs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp * "$out/share/graphs/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database of graphs";
     license = licenses.gpl2;
     platforms = platforms.all;
diff --git a/pkgs/data/misc/iana-etc/default.nix b/pkgs/data/misc/iana-etc/default.nix
index 4f9a98dccffb5..1936bd6627a7a 100644
--- a/pkgs/data/misc/iana-etc/default.nix
+++ b/pkgs/data/misc/iana-etc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 let
   version = "20200729";
@@ -12,7 +12,7 @@ in fetchzip {
     install -D -m0644 -t $out/etc services protocols
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Mic92/iana-etc";
     description = "IANA protocol and port number assignments (/etc/protocols and /etc/services)";
     platforms = platforms.unix;
diff --git a/pkgs/data/misc/libkkc-data/default.nix b/pkgs/data/misc/libkkc-data/default.nix
index aeb15057abf32..96130b2de5e11 100644
--- a/pkgs/data/misc/libkkc-data/default.nix
+++ b/pkgs/data/misc/libkkc-data/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, marisa, libkkc }:
+{ lib, stdenv, fetchurl, marisa, libkkc }:
 
 stdenv.mkDerivation rec {
   pname = "libkkc-data";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ marisa ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Language model data package for libkkc";
     homepage    = "https://github.com/ueno/libkkc";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/data/misc/media-player-info/default.nix b/pkgs/data/misc/media-player-info/default.nix
index 0307bf8d0ed2d..867822af39e66 100644
--- a/pkgs/data/misc/media-player-info/default.nix
+++ b/pkgs/data/misc/media-player-info/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, python3, udev, systemd }:
+{ lib, stdenv, fetchurl, pkgconfig, python3, udev, systemd }:
 
 let
   name = "media-player-info-24";
@@ -21,7 +21,7 @@ in
 
     configureFlags = [ "--with-udevdir=${placeholder "out"}/lib/udev" ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A repository of data files describing media player capabilities";
       homepage = "https://www.freedesktop.org/wiki/Software/media-player-info/";
       license = licenses.bsd3;
diff --git a/pkgs/data/misc/mime-types/default.nix b/pkgs/data/misc/mime-types/default.nix
index b18b66a227e64..dc942868250d9 100644
--- a/pkgs/data/misc/mime-types/default.nix
+++ b/pkgs/data/misc/mime-types/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 let
   version = "9";
@@ -11,7 +11,7 @@ in fetchzip rec {
   '';
   sha256 = "0gyla4wfiaccs0qh0hw7n08kdpnkkssglcg0z2jblb2lsdr4qna0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database of common mappings of file extensions to MIME types";
     homepage = "https://packages.gentoo.org/packages/app-misc/mime-types";
     license = licenses.gpl2;
diff --git a/pkgs/data/misc/miscfiles/default.nix b/pkgs/data/misc/miscfiles/default.nix
index 3d1caf9ae5173..783dc29ecb2d5 100644
--- a/pkgs/data/misc/miscfiles/default.nix
+++ b/pkgs/data/misc/miscfiles/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   name = "miscfiles-1.5";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "005588vfrwx8ghsdv9p7zczj9lbc9a3r4m5aphcaqv8gif4siaka";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/miscfiles/";
     license = licenses.gpl2Plus;
     description = "Collection of files not of crucial importance for sysadmins";
diff --git a/pkgs/data/misc/mobile-broadband-provider-info/default.nix b/pkgs/data/misc/mobile-broadband-provider-info/default.nix
index c9f24c9e85ef8..f487edba98156 100644
--- a/pkgs/data/misc/mobile-broadband-provider-info/default.nix
+++ b/pkgs/data/misc/mobile-broadband-provider-info/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnome3 }:
+{ lib, stdenv, fetchurl, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "mobile-broadband-provider-info";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mobile broadband service provider database";
     homepage = "https://wiki.gnome.org/Projects/NetworkManager/MobileBroadband/ServiceProviders";
     license = licenses.publicDomain;
diff --git a/pkgs/data/misc/nixos-artwork/wallpapers.nix b/pkgs/data/misc/nixos-artwork/wallpapers.nix
index 36242db4621fb..f8d22637cf3da 100644
--- a/pkgs/data/misc/nixos-artwork/wallpapers.nix
+++ b/pkgs/data/misc/nixos-artwork/wallpapers.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   mkNixBackground = { name, src, description }:
@@ -33,7 +33,7 @@ _EOF
         kdeFilePath = "${pkg}/share/wallpapers/${name}/contents/images/${src.name}";
       };
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         inherit description;
         homepage = "https://github.com/NixOS/nixos-artwork";
         license = licenses.free;
diff --git a/pkgs/data/misc/osinfo-db/default.nix b/pkgs/data/misc/osinfo-db/default.nix
index 9721d08347587..36fc664a83bb5 100644
--- a/pkgs/data/misc/osinfo-db/default.nix
+++ b/pkgs/data/misc/osinfo-db/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, osinfo-db-tools, gettext, libxml2 }:
+{ lib, stdenv, fetchurl, osinfo-db-tools, gettext, libxml2 }:
 
 stdenv.mkDerivation rec {
   pname = "osinfo-db";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     osinfo-db-import --dir "$out/share/osinfo" "${src}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Osinfo database of information about operating systems for virtualization provisioning tools";
     homepage = "https://gitlab.com/libosinfo/osinfo-db/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/data/misc/pari-galdata/default.nix b/pkgs/data/misc/pari-galdata/default.nix
index 644a50a8ddeb9..c767346280506 100644
--- a/pkgs/data/misc/pari-galdata/default.nix
+++ b/pkgs/data/misc/pari-galdata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     cp -R * "$out/share/pari/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PARI database needed to compute Galois group in degrees 8 through 11";
     homepage = "http://pari.math.u-bordeaux.fr/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/data/misc/pari-seadata-small/default.nix b/pkgs/data/misc/pari-seadata-small/default.nix
index a9c9a62839ce9..86516fe1ddba2 100644
--- a/pkgs/data/misc/pari-seadata-small/default.nix
+++ b/pkgs/data/misc/pari-seadata-small/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     cp -R * "$out/share/pari/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PARI database needed by ellap for large primes";
     homepage = "http://pari.math.u-bordeaux.fr/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/data/misc/polytopes_db/default.nix b/pkgs/data/misc/polytopes_db/default.nix
index 95ca8af82a7b7..8e9e7b44a4aac 100644
--- a/pkgs/data/misc/polytopes_db/default.nix
+++ b/pkgs/data/misc/polytopes_db/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp -R * "$out/share/reflexive_polytopes/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reflexive polytopes database";
     license = licenses.gpl2;
     platforms = platforms.all;
diff --git a/pkgs/data/misc/poppler-data/default.nix b/pkgs/data/misc/poppler-data/default.nix
index 717c948f7437c..5d6e7b8e80dc2 100644
--- a/pkgs/data/misc/poppler-data/default.nix
+++ b/pkgs/data/misc/poppler-data/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, cmake, ninja }:
+{ fetchurl, lib, stdenv, cmake, ninja }:
 
 stdenv.mkDerivation rec {
   name = "poppler-data-0.4.10";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ninja ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://poppler.freedesktop.org/";
     description = "Encoding files for Poppler, a PDF rendering library";
     platforms = platforms.all;
diff --git a/pkgs/data/misc/shared-desktop-ontologies/default.nix b/pkgs/data/misc/shared-desktop-ontologies/default.nix
index d3dfadeb5b361..88f9eec8fcada 100644
--- a/pkgs/data/misc/shared-desktop-ontologies/default.nix
+++ b/pkgs/data/misc/shared-desktop-ontologies/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake }:
+{ lib, stdenv, fetchurl, cmake }:
 
 stdenv.mkDerivation rec {
   name = "shared-desktop-ontologies-0.11.0";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://oscaf.sourceforge.net/";
     description = "Ontologies necessary for the Nepomuk semantic desktop";
     longDescription = ''
diff --git a/pkgs/data/misc/shared-mime-info/default.nix b/pkgs/data/misc/shared-mime-info/default.nix
index 4d286ad0f0a8f..69e1e697a4738 100644
--- a/pkgs/data/misc/shared-mime-info/default.nix
+++ b/pkgs/data/misc/shared-mime-info/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , gettext
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     glib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database of common MIME types";
     homepage = "http://freedesktop.org/wiki/Software/shared-mime-info";
     license = licenses.gpl2Plus;
diff --git a/pkgs/data/misc/sound-theme-freedesktop/default.nix b/pkgs/data/misc/sound-theme-freedesktop/default.nix
index 9082900619482..2b750a7e9e10f 100644
--- a/pkgs/data/misc/sound-theme-freedesktop/default.nix
+++ b/pkgs/data/misc/sound-theme-freedesktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool }:
+{ lib, stdenv, fetchurl, intltool }:
 
 stdenv.mkDerivation rec {
   pname = "sound-theme-freedesktop";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ intltool ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Freedesktop reference sound theme";
     homepage = "http://freedesktop.org/wiki/Specifications/sound-theme-spec";
     # See http://cgit.freedesktop.org/sound-theme-freedesktop/tree/CREDITS:
diff --git a/pkgs/data/misc/tzdata/default.nix b/pkgs/data/misc/tzdata/default.nix
index fa7100501adf7..98a6b9877d15f 100644
--- a/pkgs/data/misc/tzdata/default.nix
+++ b/pkgs/data/misc/tzdata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPackages }:
+{ lib, stdenv, fetchurl, buildPackages }:
 
 stdenv.mkDerivation rec {
   pname = "tzdata";
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./tzdata-setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.iana.org/time-zones";
     description = "Database of current and historical time zones";
     changelog = "https://github.com/eggert/tz/blob/${version}/NEWS";
diff --git a/pkgs/data/misc/unicode-character-database/default.nix b/pkgs/data/misc/unicode-character-database/default.nix
index e52f21713ed82..0f0a4d5fa15cd 100644
--- a/pkgs/data/misc/unicode-character-database/default.nix
+++ b/pkgs/data/misc/unicode-character-database/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , unzip
 }:
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unicode Character Database";
     homepage = "https://www.unicode.org/";
     license = licenses.unicode-dfs-2016;
diff --git a/pkgs/data/misc/unicode-emoji/default.nix b/pkgs/data/misc/unicode-emoji/default.nix
index b7705d7ee5b48..60ff492330dcc 100644
--- a/pkgs/data/misc/unicode-emoji/default.nix
+++ b/pkgs/data/misc/unicode-emoji/default.nix
@@ -50,7 +50,7 @@ symlinkJoin rec {
 
   passthru = srcs;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unicode Emoji Data Files";
     homepage = "https://home.unicode.org/emoji/";
     license = licenses.unicode-dfs-2016;
diff --git a/pkgs/data/misc/unihan-database/default.nix b/pkgs/data/misc/unihan-database/default.nix
index d5d62403cc3d9..02632b9264486 100644
--- a/pkgs/data/misc/unihan-database/default.nix
+++ b/pkgs/data/misc/unihan-database/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , unzip
 }:
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unicode Han Database";
     homepage = "https://www.unicode.org/";
     license = licenses.unicode-dfs-2016;
diff --git a/pkgs/data/misc/wireless-regdb/default.nix b/pkgs/data/misc/wireless-regdb/default.nix
index cc22606c0d69c..fc238fbe149b6 100644
--- a/pkgs/data/misc/wireless-regdb/default.nix
+++ b/pkgs/data/misc/wireless-regdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "wireless-regdb";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     "PREFIX="
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wireless regulatory database for CRDA";
     homepage = "http://wireless.kernel.org/en/developers/Regulatory/";
     license = licenses.isc;
diff --git a/pkgs/data/soundfonts/fluid/default.nix b/pkgs/data/soundfonts/fluid/default.nix
index c1c318383a096..1f84a6fd1eef2 100644
--- a/pkgs/data/soundfonts/fluid/default.nix
+++ b/pkgs/data/soundfonts/fluid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "Fluid-3";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     install -Dm644 "FluidR3 GM2-2.SF2" $out/share/soundfonts/FluidR3_GM2-2.sf2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Frank Wen's pro-quality GM/GS soundfont";
     homepage = "http://www.hammersound.net/";
     license = licenses.mit;
diff --git a/pkgs/data/themes/adapta/default.nix b/pkgs/data/themes/adapta/default.nix
index ca8e908009f90..7bbb8b6acc9e5 100644
--- a/pkgs/data/themes/adapta/default.nix
+++ b/pkgs/data/themes/adapta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, parallel, sassc, inkscape, libxml2, glib, gdk-pixbuf, librsvg, gtk-engine-murrine, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, parallel, sassc, inkscape, libxml2, glib, gdk-pixbuf, librsvg, gtk-engine-murrine, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "adapta-gtk-theme";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     "--disable-unity"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An adaptive GTK theme based on Material Design Guidelines";
     homepage = "https://github.com/adapta-project/adapta-gtk-theme";
     license = with licenses; [ gpl2 cc-by-sa-30 ];
diff --git a/pkgs/data/themes/adementary/default.nix b/pkgs/data/themes/adementary/default.nix
index 4c8362b346b3f..8b03132bfcb78 100644
--- a/pkgs/data/themes/adementary/default.nix
+++ b/pkgs/data/themes/adementary/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, sassc }:
+{ lib, stdenv, fetchFromGitHub, gtk3, sassc }:
 
 stdenv.mkDerivation rec {
   pname = "adementary-theme";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     ./install.sh -d $out/share/themes
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adwaita-based GTK theme with design influence from elementary OS and Vertex GTK theme";
     homepage    = "https://github.com/hrdwrrsk/adementary-theme";
     license     = licenses.gpl3;
diff --git a/pkgs/data/themes/amber/default.nix b/pkgs/data/themes/amber/default.nix
index 84eaee90fdbc4..258dcff326654 100644
--- a/pkgs/data/themes/amber/default.nix
+++ b/pkgs/data/themes/amber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, sassc, gdk-pixbuf, librsvg, gtk_engines, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, sassc, gdk-pixbuf, librsvg, gtk_engines, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "amber-theme";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   propagatedUserEnvPkgs = [ gtk-engine-murrine ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK, gnome-shell and Xfce theme based on Ubuntu Ambiance";
     homepage = "https://github.com/lassekongo83/amber-theme";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/ant-theme/ant-bloody.nix b/pkgs/data/themes/ant-theme/ant-bloody.nix
index 3c540889c13ac..66cd3e247a729 100644
--- a/pkgs/data/themes/ant-theme/ant-bloody.nix
+++ b/pkgs/data/themes/ant-theme/ant-bloody.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk-engine-murrine }:
+{ lib, stdenv, fetchurl, gtk-engine-murrine }:
 
 let
   themeName = "Ant-Bloody";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bloody variant of the Ant theme";
     homepage = "https://github.com/EliverLara/${themeName}";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/ant-theme/ant-nebula.nix b/pkgs/data/themes/ant-theme/ant-nebula.nix
index 03ee3b5d2d428..a62791572352b 100644
--- a/pkgs/data/themes/ant-theme/ant-nebula.nix
+++ b/pkgs/data/themes/ant-theme/ant-nebula.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk-engine-murrine }:
+{ lib, stdenv, fetchurl, gtk-engine-murrine }:
 
 let
   themeName = "Ant-Nebula";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Nebula variant of the Ant theme";
     homepage = "https://github.com/EliverLara/${themeName}";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/ant-theme/ant.nix b/pkgs/data/themes/ant-theme/ant.nix
index 736c8a1aa6acf..250b77a66e8f8 100644
--- a/pkgs/data/themes/ant-theme/ant.nix
+++ b/pkgs/data/themes/ant-theme/ant.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk-engine-murrine }:
+{ lib, stdenv, fetchurl, gtk-engine-murrine }:
 
 let
   themeName = "Ant";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A flat and light theme with a modern look";
     homepage = "https://github.com/EliverLara/${themeName}";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/arc/default.nix b/pkgs/data/themes/arc/default.nix
index bbbfbe7fe5c64..919c04913f03c 100644
--- a/pkgs/data/themes/arc/default.nix
+++ b/pkgs/data/themes/arc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , sassc
 , autoreconfHook
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     install -Dm644 -t $out/share/doc/${pname} AUTHORS *.md
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat theme with transparent elements for GTK 3, GTK 2 and Gnome Shell";
     homepage = "https://github.com/jnsh/arc-theme";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/canta/default.nix b/pkgs/data/themes/canta/default.nix
index c6a6678b98c7e..cf1223152088c 100644
--- a/pkgs/data/themes/canta/default.nix
+++ b/pkgs/data/themes/canta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , librsvg
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     gtk-update-icon-cache $out/share/icons/Canta
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat Design theme for GTK based desktop environments";
     homepage = "https://github.com/vinceliuice/Canta-theme";
     license = licenses.gpl2;
diff --git a/pkgs/data/themes/cdetheme/default.nix b/pkgs/data/themes/cdetheme/default.nix
index ae7386047517d..466f7d0daf1ea 100644
--- a/pkgs/data/themes/cdetheme/default.nix
+++ b/pkgs/data/themes/cdetheme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages }:
+{ lib, stdenv, fetchFromGitHub, python2Packages }:
 
 stdenv.mkDerivation rec {
   pname = "cdetheme";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     wrapPythonProgramsIn "$out/share/themes/cdetheme/scripts" "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gtk2 / Gtk3 theme mimicking CDE / Motif";
     homepage = "https://www.gnome-look.org/p/1231025";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/clearlooks-phenix/default.nix b/pkgs/data/themes/clearlooks-phenix/default.nix
index 4de923da9cf46..0157914d8fcc4 100644
--- a/pkgs/data/themes/clearlooks-phenix/default.nix
+++ b/pkgs/data/themes/clearlooks-phenix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   version = "7.0.1";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK3 port of the Clearlooks theme";
     longDescription = ''
       The Clearlooks-Phénix project aims at creating a GTK3 port of Clearlooks,
diff --git a/pkgs/data/themes/dracula-theme/default.nix b/pkgs/data/themes/dracula-theme/default.nix
index 87afbedf8fb66..e36f567b5f802 100644
--- a/pkgs/data/themes/dracula-theme/default.nix
+++ b/pkgs/data/themes/dracula-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, gtk-engine-murrine }:
 
 let
   themeName = "Dracula";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dracula variant of the Ant theme";
     homepage = "https://github.com/dracula/gtk";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/equilux-theme/default.nix b/pkgs/data/themes/equilux-theme/default.nix
index f24524eb6b972..ddc57c552a126 100644
--- a/pkgs/data/themes/equilux-theme/default.nix
+++ b/pkgs/data/themes/equilux-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnome3, glib, libxml2, gtk-engine-murrine, gdk-pixbuf, librsvg, bc }:
+{ lib, stdenv, fetchFromGitHub, gnome3, glib, libxml2, gtk-engine-murrine, gdk-pixbuf, librsvg, bc }:
 
 stdenv.mkDerivation rec {
   pname = "equilux-theme";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/COPYING
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "A Material Design theme for GNOME/GTK based desktop environments";
     license = licenses.gpl2;
diff --git a/pkgs/data/themes/greybird/default.nix b/pkgs/data/themes/greybird/default.nix
index 2f14988e1b251..1af0230d5695c 100644
--- a/pkgs/data/themes/greybird/default.nix
+++ b/pkgs/data/themes/greybird/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, sassc, gdk-pixbuf, librsvg, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, sassc, gdk-pixbuf, librsvg, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "greybird";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     gtk-engine-murrine
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Grey and blue theme from the Shimmer Project for GTK-based environments";
     homepage = "https://github.com/shimmerproject/Greybird";
     license = [ licenses.gpl2Plus ]; # or alternatively: cc-by-nc-sa-30 or later
diff --git a/pkgs/data/themes/jade1/default.nix b/pkgs/data/themes/jade1/default.nix
index 03dd7a49cda8a..7b850c9049e22 100644
--- a/pkgs/data/themes/jade1/default.nix
+++ b/pkgs/data/themes/jade1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk-engine-murrine }:
+{ lib, stdenv, fetchurl, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "theme-jade1";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Based on Linux Mint theme with dark menus and more intensive green";
     homepage = "https://github.com/madmaxms/theme-jade-1";
     license = with licenses; [ gpl3Only ];
diff --git a/pkgs/data/themes/lounge/default.nix b/pkgs/data/themes/lounge/default.nix
index a62ff72db6f67..af355c168e426 100644
--- a/pkgs/data/themes/lounge/default.nix
+++ b/pkgs/data/themes/lounge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, sassc, gtk3, gnome3, gdk-pixbuf, librsvg, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, sassc, gtk3, gnome3, gdk-pixbuf, librsvg, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "lounge-gtk-theme";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     gtk-update-icon-cache "$out"/share/icons/Lounge-aux;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple and clean GTK theme with vintage scrollbars, inspired by Absolute, based on Adwaita";
     homepage = "https://github.com/monday15/lounge-gtk-theme";
     license = licenses.gpl3Plus;
diff --git a/pkgs/data/themes/marwaita-manjaro/default.nix b/pkgs/data/themes/marwaita-manjaro/default.nix
index 27b503b842df9..4189f0ed48d6a 100644
--- a/pkgs/data/themes/marwaita-manjaro/default.nix
+++ b/pkgs/data/themes/marwaita-manjaro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , gtk-engine-murrine
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manjaro Style (green version) of Marwaita GTK theme";
     homepage = "https://www.pling.com/p/1351213/";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/marwaita-peppermint/default.nix b/pkgs/data/themes/marwaita-peppermint/default.nix
index c7c4efa777bb1..ede6b12cf55ca 100644
--- a/pkgs/data/themes/marwaita-peppermint/default.nix
+++ b/pkgs/data/themes/marwaita-peppermint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , gtk-engine-murrine
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Marwaita GTK theme with Peppermint Os Linux style";
     homepage = "https://www.pling.com/p/1399569/";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/marwaita-pop_os/default.nix b/pkgs/data/themes/marwaita-pop_os/default.nix
index 487b54a53e718..d16a84d5709b2 100644
--- a/pkgs/data/themes/marwaita-pop_os/default.nix
+++ b/pkgs/data/themes/marwaita-pop_os/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , gtk-engine-murrine
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Marwaita GTK theme with Pop_os Linux style";
     homepage = "https://www.pling.com/p/1377894/";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/marwaita-ubuntu/default.nix b/pkgs/data/themes/marwaita-ubuntu/default.nix
index 0241748bc432c..8d32f0a3bd97d 100644
--- a/pkgs/data/themes/marwaita-ubuntu/default.nix
+++ b/pkgs/data/themes/marwaita-ubuntu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , gtk-engine-murrine
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ubuntu Style of Marwaita GTK theme";
     homepage = "https://www.pling.com/p/1352833/";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/marwaita/default.nix b/pkgs/data/themes/marwaita/default.nix
index c3ff0bb433a61..bcf6d69a65c4f 100644
--- a/pkgs/data/themes/marwaita/default.nix
+++ b/pkgs/data/themes/marwaita/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , gtk-engine-murrine
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK theme supporting Budgie, Pantheon, Mate, Xfce4 and GNOME desktops";
     homepage = "https://www.pling.com/p/1239855/";
     license = licenses.cc0;
diff --git a/pkgs/data/themes/matcha/default.nix b/pkgs/data/themes/matcha/default.nix
index 75b9d0f65ed89..e0d706d2b0bd4 100644
--- a/pkgs/data/themes/matcha/default.nix
+++ b/pkgs/data/themes/matcha/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gdk-pixbuf, librsvg, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, gdk-pixbuf, librsvg, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "matcha-gtk-theme";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp -a src/extra/firefox $out/share/doc/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A stylish flat Design theme for GTK based desktop environments";
     homepage = "https://vinceliuice.github.io/theme-matcha";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/materia-theme/default.nix b/pkgs/data/themes/materia-theme/default.nix
index b5c13960be270..a7351a30ba823 100644
--- a/pkgs/data/themes/materia-theme/default.nix
+++ b/pkgs/data/themes/materia-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/COPYING
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Material Design theme for GNOME/GTK based desktop environments";
     homepage = "https://github.com/nana-4/materia-theme";
     license = licenses.gpl2Only;
diff --git a/pkgs/data/themes/mojave/default.nix b/pkgs/data/themes/mojave/default.nix
index 3d14f782c694b..7959753f05e0b 100644
--- a/pkgs/data/themes/mojave/default.nix
+++ b/pkgs/data/themes/mojave/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, glib, gtk-engine-murrine, gtk_engines, inkscape, optipng, sassc, which }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, glib, gtk-engine-murrine, gtk_engines, inkscape, optipng, sassc, which }:
 
 stdenv.mkDerivation rec {
   pname = "mojave-gtk-theme";
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/share/wallpapers ../"macOS Mojave Wallpapers"/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mac OSX Mojave like theme for GTK based desktop environments";
     homepage = "https://github.com/vinceliuice/Mojave-gtk-theme";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/nordic-polar/default.nix b/pkgs/data/themes/nordic-polar/default.nix
index 9d74ae2225001..8af17dd98afe6 100644
--- a/pkgs/data/themes/nordic-polar/default.nix
+++ b/pkgs/data/themes/nordic-polar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk-engine-murrine }:
+{ lib, stdenv, fetchurl, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "nordic-polar";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/{LICENSE,README.md}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gtk theme created using the awesome Nord color pallete";
     homepage = "https://github.com/EliverLara/Nordic-Polar";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/nordic/default.nix b/pkgs/data/themes/nordic/default.nix
index aca72c2fb4895..1d8ceec3d1ba8 100644
--- a/pkgs/data/themes/nordic/default.nix
+++ b/pkgs/data/themes/nordic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk-engine-murrine }:
+{ lib, stdenv, fetchurl, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "nordic";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/{LICENSE,README.md}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dark Gtk theme created using the awesome Nord color pallete";
     homepage = "https://github.com/EliverLara/Nordic";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/numix-solarized/default.nix b/pkgs/data/themes/numix-solarized/default.nix
index 356f7d33b2605..0d965e8030a65 100644
--- a/pkgs/data/themes/numix-solarized/default.nix
+++ b/pkgs/data/themes/numix-solarized/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, sassc, glib, gdk-pixbuf, inkscape, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, python3, sassc, glib, gdk-pixbuf, inkscape, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   version = "20200910";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Solarized versions of Numix GTK2 and GTK3 theme";
     longDescription = ''
       This is a fork of the Numix GTK theme that replaces the colors of the theme
diff --git a/pkgs/data/themes/obsidian2/default.nix b/pkgs/data/themes/obsidian2/default.nix
index 79c8e221894bc..3eb056e183e6c 100644
--- a/pkgs/data/themes/obsidian2/default.nix
+++ b/pkgs/data/themes/obsidian2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk-engine-murrine }:
+{ lib, stdenv, fetchurl, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "theme-obsidian2";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnome theme, based upon Adwaita-Maia dark skin";
     homepage = "https://github.com/madmaxms/theme-obsidian-2";
     license = with licenses; [ gpl3Only ];
diff --git a/pkgs/data/themes/onestepback/default.nix b/pkgs/data/themes/onestepback/default.nix
index 0385ca90f61e6..9547e35438908 100644
--- a/pkgs/data/themes/onestepback/default.nix
+++ b/pkgs/data/themes/onestepback/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "onestepback";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/{LICENSE,README*}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gtk theme inspired by the NextStep look";
     homepage = "http://www.vide.memoire.free.fr/perso/OneStepBack";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/paper-gtk/default.nix b/pkgs/data/themes/paper-gtk/default.nix
index 6f6c8b7851fba..e7c9179678f02 100644
--- a/pkgs/data/themes/paper-gtk/default.nix
+++ b/pkgs/data/themes/paper-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, gtk_engines }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, gtk_engines }:
 
 stdenv.mkDerivation {
   version = "2016-08-16";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern desktop theme suite featuring a mostly flat with a minimal use of shadows for depth";
     homepage = "https://snwh.org/paper";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/plano/default.nix b/pkgs/data/themes/plano/default.nix
index 534831e007ee3..5728dff6f9a5f 100644
--- a/pkgs/data/themes/plano/default.nix
+++ b/pkgs/data/themes/plano/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     gtk-engine-murrine
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat theme for GNOME and Xfce";
     homepage = "https://github.com/lassekongo83/plano-theme";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/plata/default.nix b/pkgs/data/themes/plata/default.nix
index 6437bb1543d3c..6153c3607c92b 100644
--- a/pkgs/data/themes/plata/default.nix
+++ b/pkgs/data/themes/plata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, autoreconfHook, pkgconfig, parallel
+{ lib, stdenv, fetchFromGitLab, autoreconfHook, pkgconfig, parallel
 , sassc, inkscape, libxml2, glib, gdk-pixbuf, librsvg, gtk-engine-murrine
 , cinnamonSupport ? true
 , gnomeFlashbackSupport ? true
@@ -81,7 +81,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GTK theme based on Material Design Refresh";
     homepage = "https://gitlab.com/tista500/plata-theme";
     license = with licenses; [ gpl2 cc-by-sa-40 ];
diff --git a/pkgs/data/themes/pop-gtk/default.nix b/pkgs/data/themes/pop-gtk/default.nix
index 317d0ba860194..ec17be3261d8a 100644
--- a/pkgs/data/themes/pop-gtk/default.nix
+++ b/pkgs/data/themes/pop-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System76 Pop GTK+ Theme";
     homepage = "https://github.com/pop-os/gtk-theme";
     license = with licenses; [ gpl3 lgpl21 cc-by-sa-40 ];
diff --git a/pkgs/data/themes/qogir/default.nix b/pkgs/data/themes/qogir/default.nix
index 44bb220d404d4..d4ffdca3ae331 100644
--- a/pkgs/data/themes/qogir/default.nix
+++ b/pkgs/data/themes/qogir/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gdk-pixbuf, librsvg, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, gdk-pixbuf, librsvg, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "qogir-theme";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/{AUTHORS,COPYING}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat Design theme for GTK based desktop environments";
     homepage = "https://vinceliuice.github.io/Qogir-theme";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/shades-of-gray/default.nix b/pkgs/data/themes/shades-of-gray/default.nix
index 718fb2b5d4ca6..e4c4cfb3ba51e 100644
--- a/pkgs/data/themes/shades-of-gray/default.nix
+++ b/pkgs/data/themes/shades-of-gray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk_engines, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, gtk_engines, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "shades-of-gray-theme";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp -a Shades-of-gray* $out/share/themes/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat dark GTK theme with ergonomic contrasts";
     homepage = "https://github.com/WernerFP/Shades-of-gray-theme";
     license = licenses.gpl3Plus;
diff --git a/pkgs/data/themes/sierra/default.nix b/pkgs/data/themes/sierra/default.nix
index 470010eb54a20..d3fbb5fe78851 100644
--- a/pkgs/data/themes/sierra/default.nix
+++ b/pkgs/data/themes/sierra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libxml2, gdk-pixbuf, librsvg, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, libxml2, gdk-pixbuf, librsvg, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "sierra-gtk-theme";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     name= ./install.sh --dest $out/share/themes
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Mac OSX like theme for GTK based desktop environments";
     homepage = "https://github.com/vinceliuice/Sierra-gtk-theme";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/skeu/default.nix b/pkgs/data/themes/skeu/default.nix
index 1f2f869364ec0..d8b0c1896572d 100644
--- a/pkgs/data/themes/skeu/default.nix
+++ b/pkgs/data/themes/skeu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , gtk-engine-murrine
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK theme with skeuomorphism design";
     homepage = "https://www.pling.com/p/1363834/";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/snowblind/default.nix b/pkgs/data/themes/snowblind/default.nix
index 3517f4de2638d..d36fe23244216 100644
--- a/pkgs/data/themes/snowblind/default.nix
+++ b/pkgs/data/themes/snowblind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitLab, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "snowblind";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/{COPYING,CREDITS}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Smooth blue theme based on Materia Design";
     homepage = "https://www.opencode.net/ju1464/Snowblind";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/solarc/default.nix b/pkgs/data/themes/solarc/default.nix
index b8e937564a55d..62a9b1076cf0b 100644
--- a/pkgs/data/themes/solarc/default.nix
+++ b/pkgs/data/themes/solarc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, pkgconfig,
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, pkgconfig,
   gtk-engine-murrine, gtk3
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     ./autogen.sh --prefix=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Solarized version of the Arc theme";
     homepage = "https://github.com/schemar/solarc-theme";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/stilo/default.nix b/pkgs/data/themes/stilo/default.nix
index 066d122d4414d..54d6f2a6e3c8d 100644
--- a/pkgs/data/themes/stilo/default.nix
+++ b/pkgs/data/themes/stilo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, sassc, gdk-pixbuf, librsvg, gtk_engines, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, sassc, gdk-pixbuf, librsvg, gtk_engines, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "stilo-themes";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   propagatedUserEnvPkgs = [ gtk-engine-murrine ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minimalistic GTK, gnome shell and Xfce themes";
     homepage = "https://github.com/lassekongo83/stilo-themes";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/sweet/default.nix b/pkgs/data/themes/sweet/default.nix
index 6ba7ae40c6828..8a62735d2e529 100644
--- a/pkgs/data/themes/sweet/default.nix
+++ b/pkgs/data/themes/sweet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "sweet";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Light and dark colorful Gtk3.20+ theme";
     homepage = "https://github.com/EliverLara/Sweet";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/ubuntu-themes/default.nix b/pkgs/data/themes/ubuntu-themes/default.nix
index 14779e8d7a389..732c9a74573b9 100644
--- a/pkgs/data/themes/ubuntu-themes/default.nix
+++ b/pkgs/data/themes/ubuntu-themes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , gnome-icon-theme
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ubuntu monochrome and Suru icon themes, Ambiance and Radiance themes, and Ubuntu artwork";
     homepage = "https://launchpad.net/ubuntu-themes";
     license = with licenses; [ cc-by-sa-40 gpl3 ];
diff --git a/pkgs/data/themes/venta/default.nix b/pkgs/data/themes/venta/default.nix
index 1086aaeb70958..cd67915216096 100644
--- a/pkgs/data/themes/venta/default.nix
+++ b/pkgs/data/themes/venta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gdk-pixbuf
 , gtk-engine-murrine
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gtk theme based on windows 10 style";
     homepage = "https://www.pling.com/p/1386774/";
     license = licenses.gpl3Only;
diff --git a/pkgs/data/themes/vertex/default.nix b/pkgs/data/themes/vertex/default.nix
index 81c681f537157..7e0b5d7e9cb29 100644
--- a/pkgs/data/themes/vertex/default.nix
+++ b/pkgs/data/themes/vertex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "theme-vertex";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     cp AUTHORS README.md $out/share/doc/$pname/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Theme for GTK 3, GTK 2, Gnome-Shell, and Cinnamon";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/vimix/default.nix b/pkgs/data/themes/vimix/default.nix
index 43636b584d3c6..5a56128937087 100644
--- a/pkgs/data/themes/vimix/default.nix
+++ b/pkgs/data/themes/vimix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk_engines, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, gtk_engines, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "vimix-gtk-themes";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     rm $out/share/themes/*/{AUTHORS,LICENSE}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flat Material Design theme for GTK based desktop environments";
     homepage = "https://github.com/vinceliuice/vimix-gtk-themes";
     license = licenses.gpl3;
diff --git a/pkgs/data/themes/yaru/default.nix b/pkgs/data/themes/yaru/default.nix
index 8e8a56d09da45..7121aed9b1e48 100644
--- a/pkgs/data/themes/yaru/default.nix
+++ b/pkgs/data/themes/yaru/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, sassc, pkg-config, glib, ninja,
+{ lib, stdenv, fetchFromGitHub, meson, sassc, pkg-config, glib, ninja,
   python3, gtk3, gnome3, gtk-engine-murrine, humanity-icon-theme, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   postPatch = "patchShebangs .";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ubuntu community theme 'yaru' - default Ubuntu theme since 18.10";
     homepage = "https://github.com/ubuntu/yaru";
     license = with licenses; [ cc-by-sa-40 gpl3 ];
diff --git a/pkgs/data/themes/zuki/default.nix b/pkgs/data/themes/zuki/default.nix
index 40046c6c5b309..217ca6c59cb6a 100644
--- a/pkgs/data/themes/zuki/default.nix
+++ b/pkgs/data/themes/zuki/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, sassc, gdk-pixbuf, librsvg, gtk_engines, gtk-engine-murrine }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, sassc, gdk-pixbuf, librsvg, gtk_engines, gtk-engine-murrine }:
 
 stdenv.mkDerivation rec {
   pname = "zuki-themes";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   propagatedUserEnvPkgs = [ gtk-engine-murrine ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Themes for GTK, gnome-shell and Xfce";
     homepage = "https://github.com/lassekongo83/zuki-themes";
     license = licenses.gpl3Only;
diff --git a/pkgs/desktops/cdesktopenv/default.nix b/pkgs/desktops/cdesktopenv/default.nix
index 7454603e7acdd..2a0769c92e99a 100644
--- a/pkgs/desktops/cdesktopenv/default.nix
+++ b/pkgs/desktops/cdesktopenv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xorgproto, libX11, bison, ksh, perl, gnum4
+{ lib, stdenv, fetchurl, xorgproto, libX11, bison, ksh, perl, gnum4
 , libXinerama, libXt, libXext, libtirpc, motif, libXft, xbitmaps
 , libjpeg, libXmu, libXdmcp, libXScrnSaver, symlinkJoin, bdftopcf
 , ncompress, mkfontdir, tcl, libXaw, gcc, glibcLocales, gawk
@@ -71,7 +71,7 @@ EOF
     mv $out/opt/dt/bin/dtmail $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Common Desktop Environment";
     homepage = "https://sourceforge.net/projects/cdesktopenv/";
     license = licenses.lgpl2;
diff --git a/pkgs/desktops/cinnamon/cinnamon-common/default.nix b/pkgs/desktops/cinnamon/cinnamon-common/default.nix
index 496f0bb3d3f60..5886804392b95 100644
--- a/pkgs/desktops/cinnamon/cinnamon-common/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-common/default.nix
@@ -24,7 +24,7 @@
 , networkmanager
 , pkgconfig
 , polkit
-, stdenv
+, lib, stdenv
 , wrapGAppsHook
 , libxml2
 , gtk-doc
@@ -160,7 +160,7 @@ stdenv.mkDerivation rec {
     providedSessions = ["cinnamon" "cinnamon2d"];
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon";
     description = "The Cinnamon desktop environment";
     license = [ licenses.gpl2 ];
diff --git a/pkgs/desktops/cinnamon/cinnamon-common/libcroco.nix b/pkgs/desktops/cinnamon/cinnamon-common/libcroco.nix
index c6f6e350c9f6d..10f5e61a175ca 100644
--- a/pkgs/desktops/cinnamon/cinnamon-common/libcroco.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-common/libcroco.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxml2, glib, gnome3 }:
+{ lib, stdenv, fetchurl, pkgconfig, libxml2, glib, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "libcroco";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME CSS2 parsing and manipulation toolkit";
     homepage = https://gitlab.gnome.org/GNOME/libcroco;
     license = licenses.lgpl2;
diff --git a/pkgs/desktops/cinnamon/cinnamon-control-center/default.nix b/pkgs/desktops/cinnamon/cinnamon-control-center/default.nix
index 50eeb23b68192..6a495ccc516bb 100644
--- a/pkgs/desktops/cinnamon/cinnamon-control-center/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-control-center/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , autoreconfHook
@@ -110,7 +110,7 @@ stdenv.mkDerivation rec {
     libtool
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon-control-center";
     description = "A collection of configuration plugins used in cinnamon-settings";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/cinnamon/cinnamon-desktop/default.nix b/pkgs/desktops/cinnamon/cinnamon-desktop/default.nix
index 71eb54ea20236..f9b204d61143c 100644
--- a/pkgs/desktops/cinnamon/cinnamon-desktop/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-desktop/default.nix
@@ -8,7 +8,7 @@
 , pkgconfig
 , pulseaudio
 , python3
-, stdenv
+, lib, stdenv
 , xkeyboard_config
 , xorg
 , wrapGAppsHook
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     sed "s|/usr/share|/run/current-system/sw/share|g" -i ./schemas/* # NOTE: unless this causes a circular dependency, we could link it to cinnamon-common/share/cinnamon
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon-desktop";
     description = "Library and data for various Cinnamon modules";
 
diff --git a/pkgs/desktops/cinnamon/cinnamon-menus/default.nix b/pkgs/desktops/cinnamon/cinnamon-menus/default.nix
index 9edc136870798..cdcbe6ec80544 100644
--- a/pkgs/desktops/cinnamon/cinnamon-menus/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-menus/default.nix
@@ -4,7 +4,7 @@
 , meson
 , ninja
 , pkgconfig
-, stdenv
+, lib, stdenv
 , wrapGAppsHook
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     pkgconfig
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon-menus";
     description = "A menu system for the Cinnamon project";
     license = [ licenses.gpl2 licenses.lgpl2 ];
diff --git a/pkgs/desktops/cinnamon/cinnamon-screensaver/default.nix b/pkgs/desktops/cinnamon/cinnamon-screensaver/default.nix
index 7074e6c329a4b..029dea37de123 100644
--- a/pkgs/desktops/cinnamon/cinnamon-screensaver/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-screensaver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , meson
@@ -106,7 +106,7 @@ stdenv.mkDerivation rec {
     sed "s|/usr/share/locale|/run/current-system/sw/share/locale|g" -i ./src/cinnamon-screensaver-main.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon-screensaver";
     description = "The Cinnamon screen locker and screensaver program";
     license = [ licenses.gpl2 licenses.lgpl2 ];
diff --git a/pkgs/desktops/cinnamon/cinnamon-session/default.nix b/pkgs/desktops/cinnamon/cinnamon-session/default.nix
index 4e9c09f4d7350..303523420c7fc 100644
--- a/pkgs/desktops/cinnamon/cinnamon-session/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-session/default.nix
@@ -14,7 +14,7 @@
 , ninja
 , pkgconfig
 , python3
-, stdenv
+, lib, stdenv
 , systemd
 , wrapGAppsHook
 , xapps
@@ -95,7 +95,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon-session";
     description = "The Cinnamon session manager";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/cinnamon/cinnamon-settings-daemon/default.nix b/pkgs/desktops/cinnamon/cinnamon-settings-daemon/default.nix
index 4788af897312e..4e930741b992c 100644
--- a/pkgs/desktops/cinnamon/cinnamon-settings-daemon/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-settings-daemon/default.nix
@@ -15,7 +15,7 @@
 , wrapGAppsHook
 , pkgconfig
 , pulseaudio
-, stdenv
+, lib, stdenv
 , systemd
 , upower
 , dconf
@@ -107,7 +107,7 @@ stdenv.mkDerivation rec {
     ln -s $out/libexec/csd-backlight-helper $out/bin/cinnamon-settings-daemon/csd-backlight-helper
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon-settings-daemon";
     description = "The settings daemon for the Cinnamon desktop";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/cinnamon/cinnamon-translations/default.nix b/pkgs/desktops/cinnamon/cinnamon-translations/default.nix
index 142c586d8d64c..24bb382286887 100644
--- a/pkgs/desktops/cinnamon/cinnamon-translations/default.nix
+++ b/pkgs/desktops/cinnamon/cinnamon-translations/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gettext
 }:
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     mv usr $out # files get installed like so: msgfmt -o usr/share/locale/$lang/LC_MESSAGES/$dir.mo $file
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cinnamon-translations";
     description = "Translations files for the Cinnamon desktop";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/cinnamon/cjs/default.nix b/pkgs/desktops/cinnamon/cjs/default.nix
index 6471d06cd5176..90989d45e426d 100644
--- a/pkgs/desktops/cinnamon/cjs/default.nix
+++ b/pkgs/desktops/cinnamon/cjs/default.nix
@@ -2,7 +2,7 @@
 , fetchFromGitHub
 , gobject-introspection
 , pkgconfig
-, stdenv
+, lib, stdenv
 , wrapGAppsHook
 , python3
 , cairo
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
     "-Dprofiler=disabled"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/cjs";
     description = "JavaScript bindings for Cinnamon";
 
diff --git a/pkgs/desktops/cinnamon/mint-themes/default.nix b/pkgs/desktops/cinnamon/mint-themes/default.nix
index a4bc81ec8ec95..67020ce0b36a4 100644
--- a/pkgs/desktops/cinnamon/mint-themes/default.nix
+++ b/pkgs/desktops/cinnamon/mint-themes/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 , python3
 , sassc
 , sass
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     mv usr/share $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/mint-themes";
     description = "Mint-X and Mint-Y themes for the cinnamon desktop";
     license = licenses.gpl3; # from debian/copyright
diff --git a/pkgs/desktops/cinnamon/mint-x-icons/default.nix b/pkgs/desktops/cinnamon/mint-x-icons/default.nix
index 2fbb3cc67bc3b..f52b0556d564d 100644
--- a/pkgs/desktops/cinnamon/mint-x-icons/default.nix
+++ b/pkgs/desktops/cinnamon/mint-x-icons/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 , gnome3
 , gnome-icon-theme
 , hicolor-icon-theme
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/mint-x-icons";
     description = "Mint/metal theme based on mintified versions of Clearlooks Revamp, Elementary and Faenza";
     license = licenses.gpl3Plus; # from debian/copyright
diff --git a/pkgs/desktops/cinnamon/mint-y-icons/default.nix b/pkgs/desktops/cinnamon/mint-y-icons/default.nix
index d5f2271625c80..8d55e81c58c21 100644
--- a/pkgs/desktops/cinnamon/mint-y-icons/default.nix
+++ b/pkgs/desktops/cinnamon/mint-y-icons/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 , gnome3
 , gnome-icon-theme
 , hicolor-icon-theme
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/mint-y-icons";
     description = "The Mint-Y icon theme";
     license = licenses.gpl3; # from debian/copyright
diff --git a/pkgs/desktops/cinnamon/muffin/default.nix b/pkgs/desktops/cinnamon/muffin/default.nix
index e16ab1eb67692..be6f69359cca4 100644
--- a/pkgs/desktops/cinnamon/muffin/default.nix
+++ b/pkgs/desktops/cinnamon/muffin/default.nix
@@ -14,7 +14,7 @@
 , libXtst
 , libxkbcommon
 , pkgconfig
-, stdenv
+, lib, stdenv
 , udev
 , xorg
 , wrapGAppsHook
@@ -90,7 +90,7 @@ stdenv.mkDerivation rec {
     NOCONFIGURE=1 ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/muffin";
     description = "The window management library for the Cinnamon desktop (libmuffin) and its sample WM binary (muffin)";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/cinnamon/nemo/default.nix b/pkgs/desktops/cinnamon/nemo/default.nix
index 5037f23512083..aa876a305c643 100644
--- a/pkgs/desktops/cinnamon/nemo/default.nix
+++ b/pkgs/desktops/cinnamon/nemo/default.nix
@@ -5,7 +5,7 @@
 , meson
 , ninja
 , pkgconfig
-, stdenv
+, lib, stdenv
 , wrapGAppsHook
 , libxml2
 , gtk3
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
     "-Dc_args=-I${glib.dev}/include/gio-unix-2.0"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/nemo";
     description = "File browser for Cinnamon";
     license = [ licenses.gpl2 licenses.lgpl2 ];
diff --git a/pkgs/desktops/cinnamon/warpinator/default.nix b/pkgs/desktops/cinnamon/warpinator/default.nix
index 5e37cff3d0a87..2338c834d1f85 100644
--- a/pkgs/desktops/cinnamon/warpinator/default.nix
+++ b/pkgs/desktops/cinnamon/warpinator/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 , gobject-introspection
 , meson
 , ninja
@@ -69,7 +69,7 @@ python3.pkgs.buildPythonApplication rec  {
     chmod -x+X $out/libexec/warpinator/*.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/warpinator";
     description = "Share files across the LAN";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/cinnamon/xapps/default.nix b/pkgs/desktops/cinnamon/xapps/default.nix
index d82cb05142379..0e8c7defa72a9 100644
--- a/pkgs/desktops/cinnamon/xapps/default.nix
+++ b/pkgs/desktops/cinnamon/xapps/default.nix
@@ -11,7 +11,7 @@
 , ninja
 , pkgconfig
 , python3
-, stdenv
+, lib, stdenv
 , vala
 , wrapGAppsHook
 , inxi
@@ -93,7 +93,7 @@ stdenv.mkDerivation rec {
     sed "s|'inxi'|'${inxi}/bin/inxi'|" -i scripts/upload-system-info
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/xapps";
     description = "Cross-desktop libraries and common resources";
     license = licenses.lgpl3;
diff --git a/pkgs/desktops/enlightenment/efl/default.nix b/pkgs/desktops/enlightenment/efl/default.nix
index 00ea83cb85c3e..a68886d414bcd 100644
--- a/pkgs/desktops/enlightenment/efl/default.nix
+++ b/pkgs/desktops/enlightenment/efl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -203,7 +203,7 @@ stdenv.mkDerivation rec {
     patchelf --add-needed ${libsndfile.out}/lib/libsndfile.so $out/lib/libecore_audio.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enlightenment foundation libraries";
     homepage = "https://enlightenment.org/";
     license = with licenses; [ bsd2 lgpl2Only licenses.zlib ];
diff --git a/pkgs/desktops/enlightenment/enlightenment/default.nix b/pkgs/desktops/enlightenment/enlightenment/default.nix
index 90a15a1d52351..0c6ae68529d4e 100644
--- a/pkgs/desktops/enlightenment/enlightenment/default.nix
+++ b/pkgs/desktops/enlightenment/enlightenment/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -66,7 +66,7 @@ stdenv.mkDerivation rec {
 
   passthru.providedSessions = [ "enlightenment" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Compositing Window Manager and Desktop Shell";
     homepage = "https://www.enlightenment.org";
     license = licenses.bsd2;
diff --git a/pkgs/desktops/enlightenment/evisum/default.nix b/pkgs/desktops/enlightenment/evisum/default.nix
index f89ff2cee3059..e4b2a7ac205aa 100644
--- a/pkgs/desktops/enlightenment/evisum/default.nix
+++ b/pkgs/desktops/enlightenment/evisum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkg-config, efl }:
+{ lib, stdenv, fetchurl, meson, ninja, pkg-config, efl }:
 
 stdenv.mkDerivation rec {
   pname = "evisum";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     efl
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System and process monitor written with EFL";
     homepage = "https://www.enlightenment.org";
     license = with licenses; [ isc ];
diff --git a/pkgs/desktops/gnome-2/bindings/gnome-python-desktop/default.nix b/pkgs/desktops/gnome-2/bindings/gnome-python-desktop/default.nix
index bf811961226db..ef4c2ba0d91ac 100644
--- a/pkgs/desktops/gnome-2/bindings/gnome-python-desktop/default.nix
+++ b/pkgs/desktops/gnome-2/bindings/gnome-python-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnome_python, librsvg, libwnck, libgtop, pkgconfig, python2, gtk2 }:
+{ lib, stdenv, fetchurl, gnome_python, librsvg, libwnck, libgtop, pkgconfig, python2, gtk2 }:
 
 let
   inherit (python2.pkgs) python pygtk;
@@ -23,7 +23,7 @@ in stdenv.mkDerivation rec {
     echo "gtk-2.0" > $out/${python2.sitePackages}/${pname}-${version}.pth
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.pygtk.org";
     description = "Python bindings for GNOME desktop packages";
     license = licenses.lgpl21;
diff --git a/pkgs/desktops/gnome-2/bindings/gnome-python/default.nix b/pkgs/desktops/gnome-2/bindings/gnome-python/default.nix
index 455e3fe267324..bdcd9d661c36b 100644
--- a/pkgs/desktops/gnome-2/bindings/gnome-python/default.nix
+++ b/pkgs/desktops/gnome-2/bindings/gnome-python/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python2, pkgconfig, libgnome, GConf, glib, gtk2, gnome_vfs }:
+{ lib, stdenv, fetchurl, python2, pkgconfig, libgnome, GConf, glib, gtk2, gnome_vfs }:
 
 with stdenv.lib;
 
@@ -23,7 +23,7 @@ in stdenv.mkDerivation rec {
     echo "gtk-2.0" > $out/${python2.sitePackages}/${name}.pth
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pygtk.org/";
     description = "Python wrapper for GNOME libraries";
     platforms = platforms.linux;
diff --git a/pkgs/desktops/gnome-2/desktop/mail-notification/default.nix b/pkgs/desktops/gnome-2/desktop/mail-notification/default.nix
index 99175e25120ce..6cfc2891ee4b0 100644
--- a/pkgs/desktops/gnome-2/desktop/mail-notification/default.nix
+++ b/pkgs/desktops/gnome-2/desktop/mail-notification/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, glib, gnome2, dbus-glib, gmime, gnome-icon-theme, libnotify, libgnome-keyring, openssl, cyrus_sasl, sylpheed, gob2, gettext, intltool, libxml2, hicolor-icon-theme, tango-icon-theme }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, glib, gnome2, dbus-glib, gmime, gnome-icon-theme, libnotify, libgnome-keyring, openssl, cyrus_sasl, sylpheed, gob2, gettext, intltool, libxml2, hicolor-icon-theme, tango-icon-theme }:
 
 stdenv.mkDerivation rec {
   rev = "9ae8768";
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tray status icon, which notifies us when new email arrives";
     homepage = "https://www.nongnu.org/mailnotify/";
     license = with licenses; [ gpl3 ];
diff --git a/pkgs/desktops/gnome-2/platform/GConf/default.nix b/pkgs/desktops/gnome-2/platform/GConf/default.nix
index 9d3e3a9be2095..0e622a38e5259 100644
--- a/pkgs/desktops/gnome-2/platform/GConf/default.nix
+++ b/pkgs/desktops/gnome-2/platform/GConf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, dbus-glib, glib, ORBit2, libxml2, polkit, python3, intltool }:
+{ lib, stdenv, fetchurl, pkgconfig, dbus-glib, glib, ORBit2, libxml2, polkit, python3, intltool }:
 
 stdenv.mkDerivation rec {
   pname = "gconf";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     2to3 --write --nobackup gsettings/gsettings-schema-convert
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://projects.gnome.org/gconf/";
     description = "Deprecated system for storing application preferences";
     platforms = platforms.unix;
diff --git a/pkgs/desktops/gnome-2/platform/ORBit2/default.nix b/pkgs/desktops/gnome-2/platform/ORBit2/default.nix
index f30c48b08e966..48198bbdc9d8e 100644
--- a/pkgs/desktops/gnome-2/platform/ORBit2/default.nix
+++ b/pkgs/desktops/gnome-2/platform/ORBit2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, glib, libIDL, libintl }:
+{ lib, stdenv, fetchurl, pkgconfig, glib, libIDL, libintl }:
 
 stdenv.mkDerivation rec {
   name = "ORBit2-${minVer}.19";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     moveToOutput "bin/orbit2-config" "$dev"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://projects.gnome.org/ORBit2/";
     description = "A CORBA 2.4-compliant Object Request Broker";
     platforms   = platforms.unix;
diff --git a/pkgs/desktops/gnome-2/platform/gtkglext/default.nix b/pkgs/desktops/gnome-2/platform/gtkglext/default.nix
index 193ae1f3c226a..780acebbb37da 100644
--- a/pkgs/desktops/gnome-2/platform/gtkglext/default.nix
+++ b/pkgs/desktops/gnome-2/platform/gtkglext/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , pkgconfig
 , gtk-doc
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     NOCONFIGURE=1 ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://projects.gnome.org/gtkglext/";
     description = "GtkGLExt, an OpenGL extension to GTK";
     longDescription = ''
diff --git a/pkgs/desktops/gnome-2/platform/libgnomeprint/default.nix b/pkgs/desktops/gnome-2/platform/libgnomeprint/default.nix
index 44c4469c5656d..dd1975ac20f94 100644
--- a/pkgs/desktops/gnome-2/platform/libgnomeprint/default.nix
+++ b/pkgs/desktops/gnome-2/platform/libgnomeprint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, gtk2, gettext, libxml2, intltool, libart_lgpl
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, gtk2, gettext, libxml2, intltool, libart_lgpl
 , libgnomecups, bison, flex }:
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = [ libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
   };
 }
diff --git a/pkgs/desktops/gnome-3/apps/accerciser/default.nix b/pkgs/desktops/gnome-3/apps/accerciser/default.nix
index f05eb41d35e28..c482a3a45eeaa 100644
--- a/pkgs/desktops/gnome-3/apps/accerciser/default.nix
+++ b/pkgs/desktops/gnome-3/apps/accerciser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , gnome3
@@ -63,7 +63,7 @@ python3.pkgs.buildPythonApplication rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Accerciser";
     description = "Interactive Python accessibility explorer";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/cheese/default.nix b/pkgs/desktops/gnome-3/apps/cheese/default.nix
index c4998cc451fe3..d6d181df96445 100644
--- a/pkgs/desktops/gnome-3/apps/cheese/default.nix
+++ b/pkgs/desktops/gnome-3/apps/cheese/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , gettext
 , fetchurl
 , wrapGAppsHook
@@ -107,7 +107,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Cheese";
     description = "Take photos and videos with your webcam, with fun graphical effects";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/evolution/default.nix b/pkgs/desktops/gnome-3/apps/evolution/default.nix
index 6bb2e139cba0f..9bf1567611532 100644
--- a/pkgs/desktops/gnome-3/apps/evolution/default.nix
+++ b/pkgs/desktops/gnome-3/apps/evolution/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , cmake
 , ninja
 , intltool
@@ -124,7 +124,7 @@ stdenv.mkDerivation rec {
 
   PKG_CONFIG_LIBEDATASERVERUI_1_2_UIMODULEDIR = "${placeholder "out"}/lib/evolution-data-server/ui-modules";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Evolution";
     description = "Personal information management application that provides integrated mail, calendaring and address book functionality";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/file-roller/default.nix b/pkgs/desktops/gnome-3/apps/file-roller/default.nix
index 29e482135a2bc..aa0e2c3b1f37c 100644
--- a/pkgs/desktops/gnome-3/apps/file-roller/default.nix
+++ b/pkgs/desktops/gnome-3/apps/file-roller/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glib, gtk3, meson, ninja, pkgconfig, gnome3, gettext, itstool, libxml2, libarchive
+{ lib, stdenv, fetchurl, glib, gtk3, meson, ninja, pkgconfig, gnome3, gettext, itstool, libxml2, libarchive
 , file, json-glib, python3, wrapGAppsHook, desktop-file-utils, libnotify, nautilus, glibcLocales }:
 
 stdenv.mkDerivation rec {
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/FileRoller";
     description = "Archive manager for the GNOME desktop environment";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/apps/gedit/default.nix b/pkgs/desktops/gnome-3/apps/gedit/default.nix
index f3219e74bcae3..c59ff77d29d42 100644
--- a/pkgs/desktops/gnome-3/apps/gedit/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gedit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , fetchurl
 , python3
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Gedit";
     description = "Official text editor of the GNOME desktop environment";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/ghex/default.nix b/pkgs/desktops/gnome-3/apps/ghex/default.nix
index 7de5ffc1add05..44e714382a372 100644
--- a/pkgs/desktops/gnome-3/apps/ghex/default.nix
+++ b/pkgs/desktops/gnome-3/apps/ghex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , pkgconfig
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Ghex";
     description = "Hex editor for GNOME desktop environment";
     platforms = platforms.unix;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-books/default.nix b/pkgs/desktops/gnome-3/apps/gnome-books/default.nix
index e7ea02a27495b..a3456a0ed48e8 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-books/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-books/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , ninja
 , gettext
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true; # Tracker 3 not supported and it cannot start Tracker 2.
     homepage = "https://wiki.gnome.org/Apps/Books";
     description = "An e-book manager application for GNOME";
diff --git a/pkgs/desktops/gnome-3/apps/gnome-boxes/default.nix b/pkgs/desktops/gnome-3/apps/gnome-boxes/default.nix
index bf19768ad22a7..8020813c4fe0f 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-boxes/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-boxes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -135,7 +135,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple GNOME 3 application to access remote or virtual systems";
     homepage = "https://wiki.gnome.org/Apps/Boxes";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-calendar/default.nix b/pkgs/desktops/gnome-3/apps/gnome-calendar/default.nix
index 67d433a8209f3..6c539c9a970dd 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-calendar/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-calendar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , meson
@@ -83,7 +83,7 @@ stdenv.mkDerivation rec {
     patchShebangs build-aux/meson/meson_post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Calendar";
     description = "Simple and beautiful calendar application for GNOME";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-characters/default.nix b/pkgs/desktops/gnome-3/apps/gnome-characters/default.nix
index 987fa594ae527..9e4d8d8005ffc 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-characters/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-characters/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -75,7 +75,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Design/Apps/CharacterMap";
     description = "Simple utility application to find and insert unusual characters";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-clocks/default.nix b/pkgs/desktops/gnome-3/apps/gnome-clocks/default.nix
index 1ffd15cfc14fc..39071542a9727 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-clocks/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-clocks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Clocks";
     description = "Clock application designed for GNOME 3";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-connections/default.nix b/pkgs/desktops/gnome-3/apps/gnome-connections/default.nix
index 02c2a4f3da840..f672a7c4f997c 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-connections/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-connections/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gnome3
 , meson
@@ -65,7 +65,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/GNOME/connections";
     description = "A remote desktop client for the GNOME desktop environment";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-documents/default.nix b/pkgs/desktops/gnome-3/apps/gnome-documents/default.nix
index ec1268f077019..6ab8fa8414595 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-documents/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-documents/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , ninja
 , gettext
@@ -116,7 +116,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true; # Tracker 3 not supported and it cannot start Tracker 2.
     homepage = "https://wiki.gnome.org/Apps/Documents";
     description = "Document manager application designed to work with GNOME 3";
diff --git a/pkgs/desktops/gnome-3/apps/gnome-getting-started-docs/default.nix b/pkgs/desktops/gnome-3/apps/gnome-getting-started-docs/default.nix
index 79b3be3ae3db1..0ec65b51c6845 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-getting-started-docs/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-getting-started-docs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnome3, intltool, itstool, libxml2 }:
+{ lib, stdenv, fetchurl, gnome3, intltool, itstool, libxml2 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-getting-started-docs";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ intltool itstool libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://live.gnome.org/DocumentationProject";
     description = "Help a new user get started in GNOME";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-logs/default.nix b/pkgs/desktops/gnome-3/apps/gnome-logs/default.nix
index 45675b791cd85..ee023b3d43493 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-logs/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-logs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , meson
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Logs";
     description = "A log viewer for the systemd journal";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-maps/default.nix b/pkgs/desktops/gnome-3/apps/gnome-maps/default.nix
index 47e03c0b0707e..8ea538eb30bb4 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-maps/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-maps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -89,7 +89,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Maps";
     description = "A map application for GNOME 3";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-music/default.nix b/pkgs/desktops/gnome-3/apps/gnome-music/default.nix
index a682e3b4935a3..241120db7a98f 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-music/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-music/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , ninja
 , gettext
@@ -103,7 +103,7 @@ python3.pkgs.buildPythonApplication rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Music";
     description = "Music player and management application for the GNOME desktop environment";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-nettool/default.nix b/pkgs/desktops/gnome-3/apps/gnome-nettool/default.nix
index 88072912b6630..60b039c0df67c 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-nettool/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-nettool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , libgtop, intltool, itstool, libxml2, nmap, inetutils }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/GNOME/gnome-nettool";
     description = "A collection of networking tools";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-notes/default.nix b/pkgs/desktops/gnome-3/apps/gnome-notes/default.nix
index fab4c491a6b5b..38505f9a83df8 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-notes/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-notes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , ninja
 , gettext
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Note editor designed to remain simple to use";
     homepage = "https://wiki.gnome.org/Apps/Notes";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-power-manager/default.nix b/pkgs/desktops/gnome-3/apps/gnome-power-manager/default.nix
index 4a92052763efa..9bccff4a8a7ac 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-power-manager/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-power-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , gettext
 , fetchurl
 , pkgconfig
@@ -50,7 +50,7 @@ in stdenv.mkDerivation rec {
     gnome3.adwaita-icon-theme
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://projects-old.gnome.org/gnome-power-manager/";
     description = "View battery and power statistics provided by UPower";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-sound-recorder/default.nix b/pkgs/desktops/gnome-3/apps/gnome-sound-recorder/default.nix
index 6875b2ec814a6..79fef5bdab140 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-sound-recorder/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-sound-recorder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , gettext
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple and modern sound recorder";
     homepage = "https://wiki.gnome.org/Apps/SoundRecorder";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-todo/default.nix b/pkgs/desktops/gnome-3/apps/gnome-todo/default.nix
index d837ce3968e49..d1e43e0a13eeb 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-todo/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-todo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , meson
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Personal task manager for GNOME";
     homepage = "https://wiki.gnome.org/Apps/Todo";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/gnome-3/apps/gnome-weather/default.nix b/pkgs/desktops/gnome-3/apps/gnome-weather/default.nix
index 84be3f5274345..3080db3f100ff 100644
--- a/pkgs/desktops/gnome-3/apps/gnome-weather/default.nix
+++ b/pkgs/desktops/gnome-3/apps/gnome-weather/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook, gjs, gobject-introspection
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook, gjs, gobject-introspection
 , libgweather, meson, ninja, geoclue2, gnome-desktop, python3, gsettings-desktop-schemas }:
 
 stdenv.mkDerivation rec {
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Weather";
     description = "Access current weather conditions and forecasts";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/polari/default.nix b/pkgs/desktops/gnome-3/apps/polari/default.nix
index c16b1f2ab1246..6551d653e296a 100644
--- a/pkgs/desktops/gnome-3/apps/polari/default.nix
+++ b/pkgs/desktops/gnome-3/apps/polari/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, itstool, fetchurl, gdk-pixbuf, adwaita-icon-theme
+{ lib, stdenv, itstool, fetchurl, gdk-pixbuf, adwaita-icon-theme
 , telepathy-glib, gjs, meson, ninja, gettext, telepathy-idle, libxml2, desktop-file-utils
 , pkgconfig, gtk3, glib, libsecret, libsoup, webkitgtk, gobject-introspection, appstream-glib
 , gnome3, wrapGAppsHook, telepathy-logger, gspell, gsettings-desktop-schemas }:
@@ -44,7 +44,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Polari";
     description = "IRC chat client designed to integrate with the GNOME desktop";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/seahorse/default.nix b/pkgs/desktops/gnome-3/apps/seahorse/default.nix
index 3cbd7a509fe44..355fd645b30bc 100644
--- a/pkgs/desktops/gnome-3/apps/seahorse/default.nix
+++ b/pkgs/desktops/gnome-3/apps/seahorse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , vala
@@ -75,7 +75,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Seahorse";
     description = "Application for managing encryption keys and passwords in the GnomeKeyring";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/apps/vinagre/default.nix b/pkgs/desktops/gnome-3/apps/vinagre/default.nix
index e04238b4b16fb..7c02715df5e0f 100644
--- a/pkgs/desktops/gnome-3/apps/vinagre/default.nix
+++ b/pkgs/desktops/gnome-3/apps/vinagre/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk3, gnome3, vte, libxml2, gtk-vnc, intltool
+{ lib, stdenv, fetchurl, pkgconfig, gtk3, gnome3, vte, libxml2, gtk-vnc, intltool
 , libsecret, itstool, wrapGAppsHook, librsvg }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Remote desktop viewer for GNOME";
     homepage = "https://wiki.gnome.org/Apps/Vinagre";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/core/adwaita-icon-theme/default.nix b/pkgs/desktops/gnome-3/core/adwaita-icon-theme/default.nix
index fa489e7695c13..d7d1bad54c10c 100644
--- a/pkgs/desktops/gnome-3/core/adwaita-icon-theme/default.nix
+++ b/pkgs/desktops/gnome-3/core/adwaita-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, gnome3
+{ lib, stdenv, fetchurl, pkgconfig, intltool, gnome3
 , iconnamingutils, gtk3, gdk-pixbuf, librsvg, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = with platforms; linux ++ darwin;
     maintainers = teams.gnome.members;
   };
diff --git a/pkgs/desktops/gnome-3/core/baobab/default.nix b/pkgs/desktops/gnome-3/core/baobab/default.nix
index 274989bf3b861..68c96209623d2 100644
--- a/pkgs/desktops/gnome-3/core/baobab/default.nix
+++ b/pkgs/desktops/gnome-3/core/baobab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gettext, fetchurl, vala, desktop-file-utils
+{ lib, stdenv, gettext, fetchurl, vala, desktop-file-utils
 , meson, ninja, pkgconfig, python3, gtk3, glib, libxml2
 , wrapGAppsHook, itstool, gnome3 }:
 
@@ -24,7 +24,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical application to analyse disk usage in any GNOME environment";
     homepage = "https://wiki.gnome.org/Apps/DiskUsageAnalyzer";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/core/caribou/default.nix b/pkgs/desktops/gnome-3/core/caribou/default.nix
index b9da1ab1c163a..f61490da1e0ec 100644
--- a/pkgs/desktops/gnome-3/core/caribou/default.nix
+++ b/pkgs/desktops/gnome-3/core/caribou/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, pkgconfig, gnome3, glib, gtk3, clutter, dbus, python3, libxml2
+{ fetchurl, lib, stdenv, pkgconfig, gnome3, glib, gtk3, clutter, dbus, python3, libxml2
 , libxklavier, libXtst, gtk2, intltool, libxslt, at-spi2-core, autoreconfHook
 , wrapGAppsHook, libgee }:
 
@@ -44,7 +44,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An input assistive technology intended for switch and pointer users";
     homepage = "https://wiki.gnome.org/Projects/Caribou";
     license = licenses.lgpl21;
diff --git a/pkgs/desktops/gnome-3/core/dconf-editor/default.nix b/pkgs/desktops/gnome-3/core/dconf-editor/default.nix
index 00c9d3a4c9057..3f128e7378bd1 100644
--- a/pkgs/desktops/gnome-3/core/dconf-editor/default.nix
+++ b/pkgs/desktops/gnome-3/core/dconf-editor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, vala, libxslt, pkgconfig, glib, gtk3, gnome3, python3, dconf
+{ lib, stdenv, fetchurl, meson, ninja, vala, libxslt, pkgconfig, glib, gtk3, gnome3, python3, dconf
 , libxml2, gettext, docbook_xsl, wrapGAppsHook, gobject-introspection }:
 
 let
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     maintainers = teams.gnome.members;
   };
diff --git a/pkgs/desktops/gnome-3/core/empathy/default.nix b/pkgs/desktops/gnome-3/core/empathy/default.nix
index ce5ca16eb7452..bc4d67f3a73b9 100644
--- a/pkgs/desktops/gnome-3/core/empathy/default.nix
+++ b/pkgs/desktops/gnome-3/core/empathy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , intltool
 , fetchurl
 , webkitgtk
@@ -137,7 +137,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Empathy";
     description = "Messaging program which supports text, voice, video chat, and file transfers over many different protocols";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/eog/default.nix b/pkgs/desktops/gnome-3/core/eog/default.nix
index fb1b5f50c0e79..20c126a6284c4 100644
--- a/pkgs/desktops/gnome-3/core/eog/default.nix
+++ b/pkgs/desktops/gnome-3/core/eog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -85,7 +85,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME image viewer";
     homepage = "https://wiki.gnome.org/Apps/EyeOfGnome";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/core/epiphany/default.nix b/pkgs/desktops/gnome-3/core/epiphany/default.nix
index 4bbed000e4335..7e47ec24af714 100644
--- a/pkgs/desktops/gnome-3/core/epiphany/default.nix
+++ b/pkgs/desktops/gnome-3/core/epiphany/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , ninja
 , gettext
@@ -103,7 +103,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Epiphany";
     description = "WebKit based web browser for GNOME";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/evince/default.nix b/pkgs/desktops/gnome-3/core/evince/default.nix
index a2c7c52a1ccd7..51778f5e8a975 100644
--- a/pkgs/desktops/gnome-3/core/evince/default.nix
+++ b/pkgs/desktops/gnome-3/core/evince/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -115,7 +115,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Evince";
     description = "GNOME's document viewer";
 
diff --git a/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix b/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix
index e52d466b0e4b5..3415203dccc8f 100644
--- a/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix
+++ b/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, substituteAll, pkgconfig, gnome3, python3, gobject-introspection
+{ fetchurl, lib, stdenv, substituteAll, pkgconfig, gnome3, python3, gobject-introspection
 , intltool, libsoup, libxml2, libsecret, icu, sqlite, tzdata, libcanberra-gtk3, gcr
 , p11-kit, db, nspr, nss, libical, gperf, wrapGAppsHook, glib-networking, pcre
 , vala, cmake, ninja, kerberos, openldap, webkitgtk, libaccounts-glib, json-glib
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unified backend for programs that work with contacts, tasks, and calendar information";
     homepage = "https://wiki.gnome.org/Apps/Evolution";
     license = licenses.lgpl2;
diff --git a/pkgs/desktops/gnome-3/core/gdm/default.nix b/pkgs/desktops/gnome-3/core/gdm/default.nix
index 10130be57da09..cda062378f725 100644
--- a/pkgs/desktops/gnome-3/core/gdm/default.nix
+++ b/pkgs/desktops/gnome-3/core/gdm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , substituteAll
@@ -172,7 +172,7 @@ stdenv.mkDerivation rec {
     initialVT = "7";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program that manages graphical display servers and handles graphical user logins";
     homepage = "https://wiki.gnome.org/Projects/GDM";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/core/gnome-backgrounds/default.nix b/pkgs/desktops/gnome-3/core/gnome-backgrounds/default.nix
index 8df32a1486ebe..ed8e513f8d3e8 100644
--- a/pkgs/desktops/gnome-3/core/gnome-backgrounds/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-backgrounds/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, gnome3, gettext }:
+{ lib, stdenv, fetchurl, meson, ninja, pkgconfig, gnome3, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-backgrounds";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ meson ninja pkgconfig gettext ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.unix;
     maintainers = teams.gnome.members;
   };
diff --git a/pkgs/desktops/gnome-3/core/gnome-bluetooth/default.nix b/pkgs/desktops/gnome-3/core/gnome-bluetooth/default.nix
index fa5b5abf0ffd0..9a1c7289810ae 100644
--- a/pkgs/desktops/gnome-3/core/gnome-bluetooth/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-bluetooth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnome3, meson, ninja, pkgconfig, gtk3, intltool, glib
+{ lib, stdenv, fetchurl, gnome3, meson, ninja, pkgconfig, gtk3, intltool, glib
 , udev, itstool, libxml2, wrapGAppsHook, libnotify, libcanberra-gtk3, gobject-introspection
 , gtk-doc, docbook_xsl, docbook_xml_dtd_43, python3, gsettings-desktop-schemas }:
 
@@ -42,7 +42,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://help.gnome.org/users/gnome-bluetooth/stable/index.html.en";
     description = "Application that let you manage Bluetooth in the GNOME destkop";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-calculator/default.nix b/pkgs/desktops/gnome-3/core/gnome-calculator/default.nix
index 2f22fd86a6f65..8af32c9208a4f 100644
--- a/pkgs/desktops/gnome-3/core/gnome-calculator/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-calculator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, meson, ninja, vala, gettext, itstool, fetchurl, pkgconfig, libxml2
+{ lib, stdenv, meson, ninja, vala, gettext, itstool, fetchurl, pkgconfig, libxml2
 , gtk3, glib, gtksourceview4, wrapGAppsHook, gobject-introspection, python3
 , gnome3, mpfr, gmp, libsoup, libmpc, gsettings-desktop-schemas, libgee }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Calculator";
     description = "Application that solves mathematical equations and is suitable as a default application in a Desktop environment";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-color-manager/default.nix b/pkgs/desktops/gnome-3/core/gnome-color-manager/default.nix
index 69655e2364d30..305163179aaef 100644
--- a/pkgs/desktops/gnome-3/core/gnome-color-manager/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-color-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of graphical utilities for color management to be used in the GNOME desktop";
     license = licenses.gpl2Plus;
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-common/default.nix b/pkgs/desktops/gnome-3/core/gnome-common/default.nix
index fb0b0f875440f..ba2fcb39979bc 100644
--- a/pkgs/desktops/gnome-3/core/gnome-common/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-common/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, gnome3, autoconf, automake }:
+{ lib, stdenv, fetchurl, which, gnome3, autoconf, automake }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-common";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = [ which autoconf automake ]; # autogen.sh which is using gnome-common tends to require which
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = teams.gnome.members;
   };
 }
diff --git a/pkgs/desktops/gnome-3/core/gnome-contacts/default.nix b/pkgs/desktops/gnome-3/core/gnome-contacts/default.nix
index 7e7730d9f6b22..a6cb63de23c41 100644
--- a/pkgs/desktops/gnome-3/core/gnome-contacts/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-contacts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , gettext
 , fetchurl
 , evolution-data-server
@@ -84,7 +84,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Contacts";
     description = "GNOME’s integrated address book";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-control-center/default.nix b/pkgs/desktops/gnome-3/core/gnome-control-center/default.nix
index 1300f7a750357..18bcc8e2e8915 100644
--- a/pkgs/desktops/gnome-3/core/gnome-control-center/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-control-center/default.nix
@@ -1,7 +1,7 @@
 { fetchurl
 , fetchFromGitLab
 , fetchpatch
-, stdenv
+, lib, stdenv
 , substituteAll
 , accountsservice
 , adwaita-icon-theme
@@ -188,7 +188,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities to configure the GNOME desktop";
     license = licenses.gpl2Plus;
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-desktop/default.nix b/pkgs/desktops/gnome-3/core/gnome-desktop/default.nix
index d7ce6c370c38f..a818f23d086a3 100644
--- a/pkgs/desktops/gnome-3/core/gnome-desktop/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll, pkgconfig, libxslt, ninja, gnome3, gtk3, glib
+{ lib, stdenv, fetchurl, substituteAll, pkgconfig, libxslt, ninja, gnome3, gtk3, glib
 , gettext, libxml2, xkeyboard_config, isocodes, meson, wayland
 , libseccomp, systemd, bubblewrap, gobject-introspection, gtk-doc, docbook_xsl, gsettings-desktop-schemas }:
 
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library with common API for various GNOME modules";
     license = with licenses; [ gpl2 lgpl2 ];
     platforms = platforms.linux;
diff --git a/pkgs/desktops/gnome-3/core/gnome-dictionary/default.nix b/pkgs/desktops/gnome-3/core/gnome-dictionary/default.nix
index 02941743f556e..51382ad4caea7 100644
--- a/pkgs/desktops/gnome-3/core/gnome-dictionary/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-dictionary/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, meson, ninja, pkgconfig, desktop-file-utils, appstream-glib, libxslt
+{ lib, stdenv, fetchurl, fetchpatch, meson, ninja, pkgconfig, desktop-file-utils, appstream-glib, libxslt
 , libxml2, gettext, itstool, wrapGAppsHook, docbook_xsl, docbook_xml_dtd_43
 , gnome3, gtk3, glib, gsettings-desktop-schemas }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Dictionary";
     description = "Dictionary is the GNOME application to look up definitions";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-disk-utility/default.nix b/pkgs/desktops/gnome-3/core/gnome-disk-utility/default.nix
index d4972fb0a2917..db7e60bbafb5b 100644
--- a/pkgs/desktops/gnome-3/core/gnome-disk-utility/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-disk-utility/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gettext, fetchurl, pkgconfig, udisks2, libsecret, libdvdread
+{ lib, stdenv, gettext, fetchurl, pkgconfig, udisks2, libsecret, libdvdread
 , meson, ninja, gtk3, glib, wrapGAppsHook, python3, libnotify
 , itstool, gnome3, libxml2, gsettings-desktop-schemas
 , libcanberra-gtk3, libxslt, docbook_xsl, libpwquality, systemd }:
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://en.wikipedia.org/wiki/GNOME_Disks";
     description = "A udisks graphical front-end";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-font-viewer/default.nix b/pkgs/desktops/gnome-3/core/gnome-font-viewer/default.nix
index d0ceef61c25a2..2bae66d7d45ac 100644
--- a/pkgs/desktops/gnome-3/core/gnome-font-viewer/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-font-viewer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, meson, ninja, gettext, fetchurl
+{ lib, stdenv, meson, ninja, gettext, fetchurl
 , pkgconfig, gtk3, glib, libxml2, gnome-desktop, adwaita-icon-theme
 , wrapGAppsHook, gnome3, harfbuzz }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Program that can preview fonts and create thumbnails for fonts";
     maintainers = teams.gnome.members;
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/core/gnome-initial-setup/default.nix b/pkgs/desktops/gnome-3/core/gnome-initial-setup/default.nix
index eba9ed1334f1a..4f20910e20d3b 100644
--- a/pkgs/desktops/gnome-3/core/gnome-initial-setup/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-initial-setup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , substituteAll
 , gettext
@@ -101,7 +101,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple, easy, and safe way to prepare a new system";
     homepage = "https://gitlab.gnome.org/GNOME/gnome-initial-setup";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/core/gnome-keyring/default.nix b/pkgs/desktops/gnome-3/core/gnome-keyring/default.nix
index 9ffd32e85f704..eeb03125a26f9 100644
--- a/pkgs/desktops/gnome-3/core/gnome-keyring/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-keyring/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, dbus, libgcrypt, pam, python2, glib, libxslt
+{ lib, stdenv, fetchurl, pkgconfig, dbus, libgcrypt, pam, python2, glib, libxslt
 , gettext, gcr, libcap_ng, libselinux, p11-kit, openssh, wrapGAppsHook
 , docbook_xsl, docbook_xml_dtd_43, gnome3 }:
 
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of components in GNOME that store secrets, passwords, keys, certificates and make them available to applications";
     homepage = "https://wiki.gnome.org/Projects/GnomeKeyring";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/core/gnome-online-miners/default.nix b/pkgs/desktops/gnome-3/core/gnome-online-miners/default.nix
index 9a940458679fb..abc791acb090c 100644
--- a/pkgs/desktops/gnome-3/core/gnome-online-miners/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-online-miners/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , autoconf-archive
@@ -106,7 +106,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Projects/GnomeOnlineMiners";
     description = "A set of crawlers that go through your online content and index them locally in Tracker";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-remote-desktop/default.nix b/pkgs/desktops/gnome-3/core/gnome-remote-desktop/default.nix
index 87c0d1efc84c1..7e428688b9251 100644
--- a/pkgs/desktops/gnome-3/core/gnome-remote-desktop/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-remote-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cairo
 , meson
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     "-Dsystemd_user_unit_dir=${placeholder "out"}/lib/systemd/user"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Projects/Mutter/RemoteDesktop";
     description = "GNOME Remote Desktop server";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-screenshot/default.nix b/pkgs/desktops/gnome-3/core/gnome-screenshot/default.nix
index 05bb189c0e294..f6aac0faf4a9f 100644
--- a/pkgs/desktops/gnome-3/core/gnome-screenshot/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-screenshot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gettext, libxml2, libhandy, fetchurl, pkgconfig, libcanberra-gtk3
+{ lib, stdenv, gettext, libxml2, libhandy, fetchurl, pkgconfig, libcanberra-gtk3
 , gtk3, glib, meson, ninja, python3, wrapGAppsHook, appstream-glib, desktop-file-utils
 , gnome3, gsettings-desktop-schemas }:
 
@@ -33,7 +33,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://en.wikipedia.org/wiki/GNOME_Screenshot";
     description = "Utility used in the GNOME desktop environment for taking screenshots";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-session/ctl.nix b/pkgs/desktops/gnome-3/core/gnome-session/ctl.nix
index 6bc18d5379f41..05d28de768a8e 100644
--- a/pkgs/desktops/gnome-3/core/gnome-session/ctl.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-session/ctl.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     systemd
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "gnome-session-ctl extracted from gnome-session for nixpkgs";
     homepage = "https://github.com/nix-community/gnome-session-ctl";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/core/gnome-session/default.nix b/pkgs/desktops/gnome-3/core/gnome-session/default.nix
index 4684f3ebee0b7..ade6ef2bb3497 100644
--- a/pkgs/desktops/gnome-3/core/gnome-session/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-session/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, substituteAll, meson, ninja, pkgconfig, gnome3, glib, gtk3, gsettings-desktop-schemas
+{ fetchurl, lib, stdenv, substituteAll, meson, ninja, pkgconfig, gnome3, glib, gtk3, gsettings-desktop-schemas
 , gnome-desktop, dbus, json-glib, libICE, xmlto, docbook_xsl, docbook_xml_dtd_412, python3
 , libxslt, gettext, makeWrapper, systemd, xorg, epoxy, gnugrep, bash, gnome-session-ctl }:
 
@@ -80,7 +80,7 @@ stdenv.mkDerivation rec {
     providedSessions = [ "gnome" "gnome-xorg" ];
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME session manager";
     homepage = "https://wiki.gnome.org/Projects/SessionManagement";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/core/gnome-settings-daemon/default.nix b/pkgs/desktops/gnome-3/core/gnome-settings-daemon/default.nix
index 3c039bc631080..45250086f1d03 100644
--- a/pkgs/desktops/gnome-3/core/gnome-settings-daemon/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-settings-daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchpatch
 , substituteAll
 , fetchurl
@@ -125,7 +125,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl2Plus;
     maintainers = teams.gnome.members;
     platforms = platforms.linux;
diff --git a/pkgs/desktops/gnome-3/core/gnome-shell-extensions/default.nix b/pkgs/desktops/gnome-3/core/gnome-shell-extensions/default.nix
index 2d07f90a16c88..b5d2300904519 100644
--- a/pkgs/desktops/gnome-3/core/gnome-shell-extensions/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-shell-extensions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, gettext, pkgconfig, spidermonkey_68, glib
+{ lib, stdenv, fetchurl, meson, ninja, gettext, pkgconfig, spidermonkey_68, glib
 , gnome3, gnome-menus, substituteAll }:
 
 stdenv.mkDerivation rec {
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Projects/GnomeShell/Extensions";
     description = "Modify and extend GNOME Shell functionality and behavior";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-shell/default.nix b/pkgs/desktops/gnome-3/core/gnome-shell/default.nix
index 53b9bc5d73825..b7dfb90841f9b 100644
--- a/pkgs/desktops/gnome-3/core/gnome-shell/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-shell/default.nix
@@ -1,7 +1,7 @@
 { fetchurl
 , fetchpatch
 , substituteAll
-, stdenv
+, lib, stdenv
 , meson
 , ninja
 , pkg-config
@@ -200,7 +200,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Core user interface for the GNOME 3 desktop";
     homepage = "https://wiki.gnome.org/Projects/GnomeShell";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/core/gnome-software/default.nix b/pkgs/desktops/gnome-3/core/gnome-software/default.nix
index 71744ab84a3c8..b3a8b2c7d3a79 100644
--- a/pkgs/desktops/gnome-3/core/gnome-software/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-software/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll, pkgconfig, meson, ninja, gettext, gnome3, wrapGAppsHook, packagekit, ostree
+{ lib, stdenv, fetchurl, substituteAll, pkgconfig, meson, ninja, gettext, gnome3, wrapGAppsHook, packagekit, ostree
 , glib, appstream-glib, libsoup, polkit, isocodes, gspell, libxslt, gobject-introspection, flatpak, fwupd
 , gtk3, gsettings-desktop-schemas, gnome-desktop, libxmlb, gnome-online-accounts
 , json-glib, libsecret, valgrind-light, docbook_xsl, docbook_xml_dtd_42, docbook_xml_dtd_43, gtk-doc, desktop-file-utils
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Software store that lets you install and update applications and system extensions";
     homepage = "https://wiki.gnome.org/Apps/Software";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/core/gnome-system-monitor/default.nix b/pkgs/desktops/gnome-3/core/gnome-system-monitor/default.nix
index d9e652de5f6d0..7675e1be864d9 100644
--- a/pkgs/desktops/gnome-3/core/gnome-system-monitor/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-system-monitor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gettext, fetchurl, pkgconfig, gtkmm3, libxml2
+{ lib, stdenv, gettext, fetchurl, pkgconfig, gtkmm3, libxml2
 , bash, gtk3, glib, wrapGAppsHook, meson, ninja, python3
 , gsettings-desktop-schemas, itstool, gnome3, librsvg, gdk-pixbuf, libgtop, systemd }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/SystemMonitor";
     description = "System Monitor shows you what programs are running and how much processor time, memory, and disk space are being used";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-terminal/default.nix b/pkgs/desktops/gnome-3/core/gnome-terminal/default.nix
index 8c8cc88301d86..e88d6f8fa40d8 100644
--- a/pkgs/desktops/gnome-3/core/gnome-terminal/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-terminal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxml2, gnome3, dconf, nautilus
+{ lib, stdenv, fetchurl, pkgconfig, libxml2, gnome3, dconf, nautilus
 , gtk3, gsettings-desktop-schemas, vte, gettext, which, libuuid, vala
 , desktop-file-utils, itstool, wrapGAppsHook, glib, pcre2
 , libxslt, docbook-xsl-nons }:
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The GNOME Terminal Emulator";
     homepage = "https://wiki.gnome.org/Apps/Terminal";
     platforms = platforms.linux;
diff --git a/pkgs/desktops/gnome-3/core/gnome-themes-extra/default.nix b/pkgs/desktops/gnome-3/core/gnome-themes-extra/default.nix
index fa2f4921fd91b..8207c8322ff4d 100644
--- a/pkgs/desktops/gnome-3/core/gnome-themes-extra/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-themes-extra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, gtk3, gnome3, librsvg, pkgconfig, pango, atk, gtk2
+{ lib, stdenv, fetchurl, intltool, gtk3, gnome3, librsvg, pkgconfig, pango, atk, gtk2
 , gdk-pixbuf, hicolor-icon-theme }:
 
 let
@@ -28,7 +28,7 @@ in stdenv.mkDerivation rec {
     gtk-update-icon-cache "$out"/share/icons/HighContrast
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     maintainers = teams.gnome.members;
   };
diff --git a/pkgs/desktops/gnome-3/core/gnome-tour/default.nix b/pkgs/desktops/gnome-3/core/gnome-tour/default.nix
index ec2007e0ee4af..606dda723bb34 100644
--- a/pkgs/desktops/gnome-3/core/gnome-tour/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-tour/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , gettext
 , meson
@@ -65,7 +65,7 @@ rustPlatform.buildRustPackage rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/GNOME/gnome-tour";
     description = "GNOME Greeter & Tour";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gnome-user-share/default.nix b/pkgs/desktops/gnome-3/core/gnome-user-share/default.nix
index 90acee076a342..d2f2a6242bfbb 100644
--- a/pkgs/desktops/gnome-3/core/gnome-user-share/default.nix
+++ b/pkgs/desktops/gnome-3/core/gnome-user-share/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , gettext
 , meson
 , ninja
@@ -86,7 +86,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://help.gnome.org/users/gnome-user-share/3.8";
     description = "Service that exports the contents of the Public folder in your home directory on the local network";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/gucharmap/default.nix b/pkgs/desktops/gnome-3/core/gucharmap/default.nix
index fe24ac8708a0c..bbb271004ac43 100644
--- a/pkgs/desktops/gnome-3/core/gucharmap/default.nix
+++ b/pkgs/desktops/gnome-3/core/gucharmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , intltool
 , fetchFromGitLab
 , meson
@@ -98,7 +98,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME Character Map, based on the Unicode Character Database";
     homepage = "https://wiki.gnome.org/Apps/Gucharmap";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/gnome-3/core/mutter/3.34/default.nix b/pkgs/desktops/gnome-3/core/mutter/3.34/default.nix
index 6afded7667167..4e81ae03f85d3 100644
--- a/pkgs/desktops/gnome-3/core/mutter/3.34/default.nix
+++ b/pkgs/desktops/gnome-3/core/mutter/3.34/default.nix
@@ -1,7 +1,7 @@
 { fetchurl
 , fetchpatch
 , substituteAll
-, stdenv
+, lib, stdenv
 , pkgconfig
 , gnome3
 , pantheon
@@ -124,7 +124,7 @@ stdenv.mkDerivation rec {
     ${glib.dev}/bin/glib-compile-schemas "$out/share/glib-2.0/schemas"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A window manager for GNOME";
     homepage = "https://gitlab.gnome.org/GNOME/mutter";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/core/mutter/default.nix b/pkgs/desktops/gnome-3/core/mutter/default.nix
index 7f26e615a1cf0..673966e720dc2 100644
--- a/pkgs/desktops/gnome-3/core/mutter/default.nix
+++ b/pkgs/desktops/gnome-3/core/mutter/default.nix
@@ -2,7 +2,7 @@
 , fetchpatch
 , substituteAll
 , runCommand
-, stdenv
+, lib, stdenv
 , pkgconfig
 , gnome3
 , gettext
@@ -146,7 +146,7 @@ let self = stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A window manager for GNOME";
     homepage = "https://gitlab.gnome.org/GNOME/mutter";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/core/nautilus/default.nix b/pkgs/desktops/gnome-3/core/nautilus/default.nix
index 79334e5b19499..682740b22bc05 100644
--- a/pkgs/desktops/gnome-3/core/nautilus/default.nix
+++ b/pkgs/desktops/gnome-3/core/nautilus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -104,7 +104,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The file manager for GNOME";
     homepage = "https://wiki.gnome.org/Apps/Files";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/gnome-3/core/rygel/default.nix b/pkgs/desktops/gnome-3/core/rygel/default.nix
index f7ce3387fc074..bf821f31f903f 100644
--- a/pkgs/desktops/gnome-3/core/rygel/default.nix
+++ b/pkgs/desktops/gnome-3/core/rygel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -99,7 +99,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A home media solution (UPnP AV MediaServer) that allows you to easily share audio, video and pictures to other devices";
     homepage = "https://wiki.gnome.org/Projects/Rygel";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/gnome-3/core/simple-scan/default.nix b/pkgs/desktops/gnome-3/core/simple-scan/default.nix
index 66846876faef8..d2d31ada0f8f8 100644
--- a/pkgs/desktops/gnome-3/core/simple-scan/default.nix
+++ b/pkgs/desktops/gnome-3/core/simple-scan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple scanning utility";
     longDescription = ''
       A really easy way to scan both documents and photos. You can crop out the
diff --git a/pkgs/desktops/gnome-3/core/sushi/default.nix b/pkgs/desktops/gnome-3/core/sushi/default.nix
index f0ddaef081b30..2363b921cd7f9 100644
--- a/pkgs/desktops/gnome-3/core/sushi/default.nix
+++ b/pkgs/desktops/gnome-3/core/sushi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , meson
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://en.wikipedia.org/wiki/Sushi_(software)";
     description = "A quick previewer for Nautilus";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/totem/default.nix b/pkgs/desktops/gnome-3/core/totem/default.nix
index 58ee706b1cfcc..03da54a1353c1 100644
--- a/pkgs/desktops/gnome-3/core/totem/default.nix
+++ b/pkgs/desktops/gnome-3/core/totem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -113,7 +113,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Videos";
     description = "Movie player for the GNOME desktop based on GStreamer";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/yelp-xsl/default.nix b/pkgs/desktops/gnome-3/core/yelp-xsl/default.nix
index a29a292b3d74e..912914488830b 100644
--- a/pkgs/desktops/gnome-3/core/yelp-xsl/default.nix
+++ b/pkgs/desktops/gnome-3/core/yelp-xsl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , gettext
 , fetchurl
 , pkgconfig
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Yelp";
     description = "Yelp's universal stylesheets for Mallard and DocBook";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/yelp/default.nix b/pkgs/desktops/gnome-3/core/yelp/default.nix
index 147809de9ef62..3b382a7142477 100644
--- a/pkgs/desktops/gnome-3/core/yelp/default.nix
+++ b/pkgs/desktops/gnome-3/core/yelp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gettext, fetchurl, webkitgtk, pkgconfig, gtk3, glib
+{ lib, stdenv, gettext, fetchurl, webkitgtk, pkgconfig, gtk3, glib
 , gnome3, sqlite
 , itstool, libxml2, libxslt, gst_all_1
 , wrapGAppsHook }:
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Yelp";
     description = "The help viewer in Gnome";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/core/zenity/default.nix b/pkgs/desktops/gnome-3/core/zenity/default.nix
index 5750fa0d001c4..6c6493a42e82e 100644
--- a/pkgs/desktops/gnome-3/core/zenity/default.nix
+++ b/pkgs/desktops/gnome-3/core/zenity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , libxml2
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to display dialogs from the commandline and shell scripts";
     homepage = "https://wiki.gnome.org/Projects/Zenity";
     platforms = platforms.linux;
diff --git a/pkgs/desktops/gnome-3/devtools/anjuta/default.nix b/pkgs/desktops/gnome-3/devtools/anjuta/default.nix
index efd36d4d4affe..0a7975c03ca2f 100644
--- a/pkgs/desktops/gnome-3/devtools/anjuta/default.nix
+++ b/pkgs/desktops/gnome-3/devtools/anjuta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, gjs, flex, bison, libxml2, intltool,
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, gjs, flex, bison, libxml2, intltool,
   gdl, libgda, gtksourceview, gsettings-desktop-schemas,
   itstool, python3, ncurses, makeWrapper }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
         "$GSETTINGS_SCHEMAS_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Software development studio";
     homepage = "http://anjuta.org/";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/devtools/devhelp/default.nix b/pkgs/desktops/gnome-3/devtools/devhelp/default.nix
index 7de22f693d6c3..5f714827e0b1f 100644
--- a/pkgs/desktops/gnome-3/devtools/devhelp/default.nix
+++ b/pkgs/desktops/gnome-3/devtools/devhelp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "API documentation browser for GNOME";
     homepage = "https://wiki.gnome.org/Apps/Devhelp";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/gnome-3/devtools/gnome-devel-docs/default.nix b/pkgs/desktops/gnome-3/devtools/gnome-devel-docs/default.nix
index a3a69eb4e3494..115d9f289cfab 100644
--- a/pkgs/desktops/gnome-3/devtools/gnome-devel-docs/default.nix
+++ b/pkgs/desktops/gnome-3/devtools/gnome-devel-docs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnome3, intltool, itstool, libxml2 }:
+{ lib, stdenv, fetchurl, gnome3, intltool, itstool, libxml2 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-devel-docs";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ intltool itstool libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/GNOME/gnome-devel-docs";
     description = "Developer documentation for GNOME";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/extensions/EasyScreenCast/default.nix b/pkgs/desktops/gnome-3/extensions/EasyScreenCast/default.nix
index 523dbc622f081..fa1d89173fdd6 100644
--- a/pkgs/desktops/gnome-3/extensions/EasyScreenCast/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/EasyScreenCast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll, glib, gnome3, gettext }:
+{ lib, stdenv, fetchFromGitHub, substituteAll, glib, gnome3, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-EasyScreenCast";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   uuid = "EasyScreenCast@iacopodeenosee.gmail.com";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simplifies the use of the video recording function integrated in gnome shell";
     homepage = "https://github.com/EasyScreenCast/EasyScreenCast";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/gnome-3/extensions/appindicator/default.nix b/pkgs/desktops/gnome-3/extensions/appindicator/default.nix
index 0638241df53b8..f5dae739ea477 100644
--- a/pkgs/desktops/gnome-3/extensions/appindicator/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/appindicator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-appindicator";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AppIndicator/KStatusNotifierItem support for GNOME Shell";
     license = licenses.gpl2Plus;
     maintainers = with maintainers; [ jonafato ];
diff --git a/pkgs/desktops/gnome-3/extensions/arc-menu/default.nix b/pkgs/desktops/gnome-3/extensions/arc-menu/default.nix
index 336820b7938eb..58f1836a132a6 100644
--- a/pkgs/desktops/gnome-3/extensions/arc-menu/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/arc-menu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, glib, gettext, substituteAll, gnome-menus }:
+{ lib, stdenv, fetchFromGitLab, glib, gettext, substituteAll, gnome-menus }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-arc-menu";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   uuid = "arc-menu@linxgem33.com";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnome shell extension designed to replace the standard menu found in Gnome 3";
     license = licenses.gpl2Plus;
     maintainers = with maintainers; [ dkabot ];
diff --git a/pkgs/desktops/gnome-3/extensions/caffeine/default.nix b/pkgs/desktops/gnome-3/extensions/caffeine/default.nix
index 1dbb52e856a87..41155391f89c5 100644
--- a/pkgs/desktops/gnome-3/extensions/caffeine/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/caffeine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib, gettext, bash, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, glib, gettext, bash, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-caffeine";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fill the cup to inhibit auto suspend and screensaver";
     license = licenses.gpl2;
     maintainers = with maintainers; [ eperuffo ];
diff --git a/pkgs/desktops/gnome-3/extensions/chrome-gnome-shell/default.nix b/pkgs/desktops/gnome-3/extensions/chrome-gnome-shell/default.nix
index 5308d4bee5acb..f6adf85de4d00 100644
--- a/pkgs/desktops/gnome-3/extensions/chrome-gnome-shell/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/chrome-gnome-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cmake
 , ninja
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME Shell integration for Chrome";
     homepage = "https://wiki.gnome.org/Projects/GnomeShellIntegrationForChrome";
     longDescription = ''
diff --git a/pkgs/desktops/gnome-3/extensions/clipboard-indicator/default.nix b/pkgs/desktops/gnome-3/extensions/clipboard-indicator/default.nix
index dbeb08af224ef..ee64fc5113d05 100644
--- a/pkgs/desktops/gnome-3/extensions/clipboard-indicator/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/clipboard-indicator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-clipboard-indicator";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adds a clipboard indicator to the top panel and saves clipboard history";
     license = licenses.mit;
     maintainers = with maintainers; [ jonafato ];
diff --git a/pkgs/desktops/gnome-3/extensions/dash-to-dock/default.nix b/pkgs/desktops/gnome-3/extensions/dash-to-dock/default.nix
index 59d9319eb54af..45233e52f8932 100644
--- a/pkgs/desktops/gnome-3/extensions/dash-to-dock/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/dash-to-dock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , glib
 , gettext
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   uuid = "dash-to-dock@micxgx.gmail.com";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A dock for the Gnome Shell";
     homepage = "https://micheleg.github.io/dash-to-dock/";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/extensions/dash-to-panel/default.nix b/pkgs/desktops/gnome-3/extensions/dash-to-panel/default.nix
index 923faa00a1499..7a9dc066cc77e 100644
--- a/pkgs/desktops/gnome-3/extensions/dash-to-panel/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/dash-to-panel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib, gettext }:
+{ lib, stdenv, fetchFromGitHub, glib, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-dash-to-panel";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   uuid = "dash-to-panel@jderose9.github.com";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An icon taskbar for Gnome Shell";
     license = licenses.gpl2;
     maintainers = with maintainers; [ mounium ];
diff --git a/pkgs/desktops/gnome-3/extensions/draw-on-your-screen/default.nix b/pkgs/desktops/gnome-3/extensions/draw-on-your-screen/default.nix
index 5e6f7b89e1d95..e5a2ccd89cd9c 100644
--- a/pkgs/desktops/gnome-3/extensions/draw-on-your-screen/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/draw-on-your-screen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, gettext, gnome3 }:
+{ lib, stdenv, fetchgit, gettext, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-draw-on-your-screen";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A drawing extension for GNOME Shell";
     license = licenses.gpl2Plus;
     maintainers = with maintainers; [ ericdallo ];
diff --git a/pkgs/desktops/gnome-3/extensions/drop-down-terminal/default.nix b/pkgs/desktops/gnome-3/extensions/drop-down-terminal/default.nix
index 3c6d181178b44..8cd567a590dbd 100644
--- a/pkgs/desktops/gnome-3/extensions/drop-down-terminal/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/drop-down-terminal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll, gjs, vte, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, substituteAll, gjs, vte, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-drop-down-terminal";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configurable drop down terminal shell";
     license = licenses.gpl3;
     maintainers = with maintainers; [ ericdallo ];
diff --git a/pkgs/desktops/gnome-3/extensions/emoji-selector/default.nix b/pkgs/desktops/gnome-3/extensions/emoji-selector/default.nix
index c4db4702193a6..5470dc996be01 100644
--- a/pkgs/desktops/gnome-3/extensions/emoji-selector/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/emoji-selector/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib, gettext }:
+{ lib, stdenv, fetchFromGitHub, glib, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-emoji-selector";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "GNOME Shell extension providing a searchable popup menu displaying most emojis";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/gnome-3/extensions/freon/default.nix b/pkgs/desktops/gnome-3/extensions/freon/default.nix
index 5224e4863ae2e..f30e2f6f8a250 100644
--- a/pkgs/desktops/gnome-3/extensions/freon/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/freon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib }:
+{ lib, stdenv, fetchFromGitHub, glib }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-freon";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME Shell extension for displaying CPU, GPU, disk temperatures, voltage and fan RPM in the top panel";
     license = licenses.gpl2;
     maintainers = with maintainers; [ justinas ];
diff --git a/pkgs/desktops/gnome-3/extensions/gsconnect/default.nix b/pkgs/desktops/gnome-3/extensions/gsconnect/default.nix
index d85efd0a4da40..abb9d9d1bb3b1 100644
--- a/pkgs/desktops/gnome-3/extensions/gsconnect/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/gsconnect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , substituteAll
 , openssl
@@ -107,7 +107,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "KDE Connect implementation for Gnome Shell";
     homepage = "https://github.com/andyholmes/gnome-shell-extension-gsconnect/wiki";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/extensions/icon-hider/default.nix b/pkgs/desktops/gnome-3/extensions/icon-hider/default.nix
index 844c8ad84d79e..00c67421e54a5 100644
--- a/pkgs/desktops/gnome-3/extensions/icon-hider/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/icon-hider/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-icon-hider";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Icon Hider is a GNOME Shell extension for managing status area items";
     license = licenses.bsd3;
     maintainers = with maintainers; [ jonafato ];
diff --git a/pkgs/desktops/gnome-3/extensions/impatience/default.nix b/pkgs/desktops/gnome-3/extensions/impatience/default.nix
index 073a4301cc5ed..82551efef3c78 100644
--- a/pkgs/desktops/gnome-3/extensions/impatience/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/impatience/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib }:
+{ lib, stdenv, fetchFromGitHub, glib }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-impatience";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   uuid = "impatience@gfxmonk.net";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Speed up builtin gnome-shell animations";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ timbertson tiramiseb ];
diff --git a/pkgs/desktops/gnome-3/extensions/material-shell/default.nix b/pkgs/desktops/gnome-3/extensions/material-shell/default.nix
index e7931fc4fc064..87b9a3c1507c4 100644
--- a/pkgs/desktops/gnome-3/extensions/material-shell/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/material-shell/default.nix
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   uuid = "material-shell@papyelgringo";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern desktop interface for Linux";
     license = licenses.mit;
     maintainers = with maintainers; [ benley ];
diff --git a/pkgs/desktops/gnome-3/extensions/mpris-indicator-button/default.nix b/pkgs/desktops/gnome-3/extensions/mpris-indicator-button/default.nix
index 4bf4b7508176a..9ab2168d2dcac 100644
--- a/pkgs/desktops/gnome-3/extensions/mpris-indicator-button/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/mpris-indicator-button/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , gnome3
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple MPRIS indicator button for GNOME Shell";
     license = licenses.gpl3;
     maintainers = with maintainers; [ worldofpeace ];
diff --git a/pkgs/desktops/gnome-3/extensions/night-theme-switcher/default.nix b/pkgs/desktops/gnome-3/extensions/night-theme-switcher/default.nix
index f170a2fb19071..6c1d6512adc67 100644
--- a/pkgs/desktops/gnome-3/extensions/night-theme-switcher/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/night-theme-switcher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, glib, gnome3, unzip }:
+{ lib, stdenv, fetchFromGitLab, glib, gnome3, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-night-theme-switcher";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically change the GTK theme to dark variant when Night Light activates";
     license = licenses.gpl3;
     maintainers = with maintainers; [ jonafato ];
diff --git a/pkgs/desktops/gnome-3/extensions/no-title-bar/default.nix b/pkgs/desktops/gnome-3/extensions/no-title-bar/default.nix
index 25ef7ddf82790..7d143a061f68c 100644
--- a/pkgs/desktops/gnome-3/extensions/no-title-bar/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/no-title-bar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll, glib, gettext, xorg }:
+{ lib, stdenv, fetchFromGitHub, substituteAll, glib, gettext, xorg }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-no-title-bar";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   uuid = "no-title-bar@franglais125.gmail.com";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integrates maximized windows with the top panel";
     homepage = "https://github.com/franglais125/no-title-bar";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/extensions/paperwm/default.nix b/pkgs/desktops/gnome-3/extensions/paperwm/default.nix
index 382f8aa732b90..201628b4b424e 100644
--- a/pkgs/desktops/gnome-3/extensions/paperwm/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/paperwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-paperwm";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiled scrollable window management for Gnome Shell";
     homepage = "https://github.com/paperwm/PaperWM";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/gnome-3/extensions/pidgin-im-integration/default.nix b/pkgs/desktops/gnome-3/extensions/pidgin-im-integration/default.nix
index dfcfd63b59dbe..d16477403474b 100644
--- a/pkgs/desktops/gnome-3/extensions/pidgin-im-integration/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/pidgin-im-integration/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, glib, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-pidgin-im-integration";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   uuid = "pidgin@muffinmad";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/muffinmad/pidgin-im-gnome-shell-extension";
     description = "Make Pidgin IM conversations appear in the Gnome Shell message tray";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/extensions/remove-dropdown-arrows/default.nix b/pkgs/desktops/gnome-3/extensions/remove-dropdown-arrows/default.nix
index 6d6a04a386cc0..e310f5dcf10c5 100644
--- a/pkgs/desktops/gnome-3/extensions/remove-dropdown-arrows/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/remove-dropdown-arrows/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-remove-dropdown-arrows";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Remove dropdown arrows from GNOME Shell Menus";
     license = licenses.gpl3;
     maintainers = with maintainers; [ jonafato ];
diff --git a/pkgs/desktops/gnome-3/extensions/sound-output-device-chooser/default.nix b/pkgs/desktops/gnome-3/extensions/sound-output-device-chooser/default.nix
index 9f80fbe28cd7d..a6444025ebbc7 100644
--- a/pkgs/desktops/gnome-3/extensions/sound-output-device-chooser/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/sound-output-device-chooser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , substituteAll
 , fetchFromGitHub
 , libpulseaudio
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME Shell extension adding audio device chooser to panel";
     license = licenses.gpl3;
     maintainers = with maintainers; [ jtojnar ];
diff --git a/pkgs/desktops/gnome-3/extensions/system-monitor/default.nix b/pkgs/desktops/gnome-3/extensions/system-monitor/default.nix
index 1b1da50b7fa78..77e3f48850d2e 100644
--- a/pkgs/desktops/gnome-3/extensions/system-monitor/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/system-monitor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll, fetchpatch, fetchFromGitHub, glib, glib-networking, libgtop, gnome3 }:
+{ lib, stdenv, substituteAll, fetchpatch, fetchFromGitHub, glib, glib-networking, libgtop, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-system-monitor";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   uuid = "system-monitor@paradoxxx.zero.gmail.com";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display system informations in gnome shell status bar";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ tiramiseb ];
diff --git a/pkgs/desktops/gnome-3/extensions/taskwhisperer/default.nix b/pkgs/desktops/gnome-3/extensions/taskwhisperer/default.nix
index a6f45e3b574cf..0935bf521a4a2 100644
--- a/pkgs/desktops/gnome-3/extensions/taskwhisperer/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/taskwhisperer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll, fetchFromGitHub, taskwarrior, gettext, runtimeShell, gnome3 }:
+{ lib, stdenv, substituteAll, fetchFromGitHub, taskwarrior, gettext, runtimeShell, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-taskwhisperer";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME Shell TaskWarrior GUI";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ jonafato ];
diff --git a/pkgs/desktops/gnome-3/extensions/tilingnome/default.nix b/pkgs/desktops/gnome-3/extensions/tilingnome/default.nix
index 57f5a9377baa9..dcea4c69ff82e 100644
--- a/pkgs/desktops/gnome-3/extensions/tilingnome/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/tilingnome/default.nix
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   uuid = "tilingnome@rliang.github.com";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiling window management for GNOME Shell";
     license = licenses.gpl2;
     maintainers = with maintainers; [ benley ];
diff --git a/pkgs/desktops/gnome-3/extensions/timepp/default.nix b/pkgs/desktops/gnome-3/extensions/timepp/default.nix
index f1c53eda6bdf1..94b8540c1bf32 100644
--- a/pkgs/desktops/gnome-3/extensions/timepp/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/timepp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-timepp";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A todo.txt manager, time tracker, timer, stopwatch, pomodoro, and alarms gnome-shell extension.";
     homepage = "https://github.com/zagortenay333/timepp__gnome";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/gnome-3/extensions/topicons-plus/default.nix b/pkgs/desktops/gnome-3/extensions/topicons-plus/default.nix
index 860a77d2856b1..7b98e20ed29b1 100644
--- a/pkgs/desktops/gnome-3/extensions/topicons-plus/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/topicons-plus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, glib, gnome3, gettext }:
+{ lib, stdenv, fetchFromGitHub, glib, gnome3, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-topicons-plus";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   uuid = "TopIcons@phocean.net";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Brings all icons back to the top panel, so that it's easier to keep track of apps running in the backround";
     license = licenses.gpl2;
     maintainers = with maintainers; [ eperuffo ];
diff --git a/pkgs/desktops/gnome-3/extensions/window-corner-preview/default.nix b/pkgs/desktops/gnome-3/extensions/window-corner-preview/default.nix
index 9c5d5266ce274..e7659b6b31496 100644
--- a/pkgs/desktops/gnome-3/extensions/window-corner-preview/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/window-corner-preview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-window-corner-preview";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME Shell extension showing a video preview on the corner of the screen";
     license = licenses.mit;
     maintainers = with maintainers; [ jtojnar ];
diff --git a/pkgs/desktops/gnome-3/extensions/window-is-ready-remover/default.nix b/pkgs/desktops/gnome-3/extensions/window-is-ready-remover/default.nix
index 45ac75baf8bf7..3f0e9e71b571b 100644
--- a/pkgs/desktops/gnome-3/extensions/window-is-ready-remover/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/window-is-ready-remover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-window-is-ready-remover";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME Shell extension removing window is ready notification";
     homepage = "https://github.com/nunofarruca/WindowIsReady_Remover";
     license = licenses.asl20;
diff --git a/pkgs/desktops/gnome-3/extensions/workspace-matrix/default.nix b/pkgs/desktops/gnome-3/extensions/workspace-matrix/default.nix
index 6c466a8eca4bf..eb1d6e7e319c6 100644
--- a/pkgs/desktops/gnome-3/extensions/workspace-matrix/default.nix
+++ b/pkgs/desktops/gnome-3/extensions/workspace-matrix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, findutils, glib }:
+{ lib, stdenv, fetchFromGitHub, findutils, glib }:
 
 stdenv.mkDerivation rec {
   pname = "gnome-shell-extension-workspace-matrix";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Arrange workspaces in a two dimensional grid with workspace thumbnails";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ chkno ];
diff --git a/pkgs/desktops/gnome-3/games/aisleriot/default.nix b/pkgs/desktops/gnome-3/games/aisleriot/default.nix
index e441462921b59..bb513df4c7a90 100644
--- a/pkgs/desktops/gnome-3/games/aisleriot/default.nix
+++ b/pkgs/desktops/gnome-3/games/aisleriot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , pkg-config
 , gnome3
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Aisleriot";
     description = "A collection of patience games written in guile scheme";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/atomix/default.nix b/pkgs/desktops/gnome-3/games/atomix/default.nix
index 28cc020b2d805..6f8b9ad9bde35 100644
--- a/pkgs/desktops/gnome-3/games/atomix/default.nix
+++ b/pkgs/desktops/gnome-3/games/atomix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, wrapGAppsHook, python3
+{ lib, stdenv, fetchurl, meson, ninja, pkgconfig, wrapGAppsHook, python3
 , gettext, gnome3, glib, gtk3, libgnome-games-support, gdk-pixbuf }:
 
 let
@@ -27,7 +27,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Puzzle game where you move atoms to build a molecule";
     homepage = "https://wiki.gnome.org/Apps/Atomix";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/games/five-or-more/default.nix b/pkgs/desktops/gnome-3/games/five-or-more/default.nix
index ca69395eb2359..291581661f779 100644
--- a/pkgs/desktops/gnome-3/games/five-or-more/default.nix
+++ b/pkgs/desktops/gnome-3/games/five-or-more/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, meson, ninja, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , librsvg, libgnome-games-support, gettext, itstool, libxml2, python3, vala }:
 
 stdenv.mkDerivation rec {
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Five_or_more";
     description = "Remove colored balls from the board by forming lines";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/four-in-a-row/default.nix b/pkgs/desktops/gnome-3/games/four-in-a-row/default.nix
index 7ed3a0d478cab..edd6a2ecd81ea 100644
--- a/pkgs/desktops/gnome-3/games/four-in-a-row/default.nix
+++ b/pkgs/desktops/gnome-3/games/four-in-a-row/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , gettext, meson, gsound, librsvg, itstool, vala
 , python3, ninja, desktop-file-utils }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Four-in-a-row";
     description = "Make lines of the same color to win";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-chess/default.nix b/pkgs/desktops/gnome-3/games/gnome-chess/default.nix
index 17ac13ebbce1d..f1f7cbcaeb81d 100644
--- a/pkgs/desktops/gnome-3/games/gnome-chess/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-chess/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, vala, pkgconfig, wrapGAppsHook, gobject-introspection
+{ lib, stdenv, fetchurl, meson, ninja, vala, pkgconfig, wrapGAppsHook, gobject-introspection
 , gettext, itstool, libxml2, python3, gnome3, glib, gtk3, librsvg }:
 
 stdenv.mkDerivation rec {
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Chess";
     description = "Play the classic two-player boardgame of chess";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-klotski/default.nix b/pkgs/desktops/gnome-3/games/gnome-klotski/default.nix
index a51b79e0f883c..c6a3a24a50b7a 100644
--- a/pkgs/desktops/gnome-3/games/gnome-klotski/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-klotski/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, vala, gnome3, gtk3, wrapGAppsHook, appstream-glib, desktop-file-utils
+{ lib, stdenv, fetchurl, pkgconfig, vala, gnome3, gtk3, wrapGAppsHook, appstream-glib, desktop-file-utils
 , glib, librsvg, libxml2, gettext, itstool, libgee, libgnome-games-support
 , meson, ninja, python3
 }:
@@ -33,7 +33,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Klotski";
     description = "Slide blocks to solve the puzzle";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-mahjongg/default.nix b/pkgs/desktops/gnome-3/games/gnome-mahjongg/default.nix
index 9bb0db10da580..51908d3236c23 100644
--- a/pkgs/desktops/gnome-3/games/gnome-mahjongg/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-mahjongg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , librsvg, gettext, itstool, libxml2
 , meson, ninja, glib, vala, desktop-file-utils
 }:
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Mahjongg";
     description = "Disassemble a pile of tiles by removing matching pairs";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-mines/default.nix b/pkgs/desktops/gnome-3/games/gnome-mines/default.nix
index 011b9569fd849..93529b0b3f88c 100644
--- a/pkgs/desktops/gnome-3/games/gnome-mines/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-mines/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, vala, gobject-introspection, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, meson, ninja, vala, gobject-introspection, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , librsvg, gettext, itstool, python3, libxml2, libgnome-games-support, libgee, desktop-file-utils }:
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Mines";
     description = "Clear hidden mines from a minefield";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-nibbles/default.nix b/pkgs/desktops/gnome-3/games/gnome-nibbles/default.nix
index b4f778c3ff1e8..410d397bb588e 100644
--- a/pkgs/desktops/gnome-3/games/gnome-nibbles/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-nibbles/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , librsvg, gsound, clutter-gtk, gettext, itstool, vala, python3
 , libxml2, libgee, libgnome-games-support, meson, ninja
 , desktop-file-utils, hicolor-icon-theme}:
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Guide a worm around a maze";
     homepage = "https://wiki.gnome.org/Apps/Nibbles";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/games/gnome-robots/default.nix b/pkgs/desktops/gnome-3/games/gnome-robots/default.nix
index 1d9beca366708..39eb27228be03 100644
--- a/pkgs/desktops/gnome-3/games/gnome-robots/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-robots/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , librsvg, gsound, gettext, itstool, libxml2, libgnome-games-support
 , libgee, meson, ninja, python3, desktop-file-utils, adwaita-icon-theme }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     patchShebangs build-aux/meson_post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Robots";
     description = "Avoid the robots and make them crash into each other";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-sudoku/default.nix b/pkgs/desktops/gnome-3/games/gnome-sudoku/default.nix
index a46cfeee50601..49bafcf9603a7 100644
--- a/pkgs/desktops/gnome-3/games/gnome-sudoku/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-sudoku/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, vala, pkgconfig, gobject-introspection, gettext, gtk3, gnome3, wrapGAppsHook
+{ lib, stdenv, fetchurl, meson, ninja, vala, pkgconfig, gobject-introspection, gettext, gtk3, gnome3, wrapGAppsHook
 , libgee, json-glib, qqwing, itstool, libxml2, python3, desktop-file-utils }:
 
 stdenv.mkDerivation rec {
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Sudoku";
     description = "Test your logic skills in this number grid puzzle";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-taquin/default.nix b/pkgs/desktops/gnome-3/games/gnome-taquin/default.nix
index fc73ef1397ef2..9c8b06a7dd4f1 100644
--- a/pkgs/desktops/gnome-3/games/gnome-taquin/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-taquin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , librsvg, gsound, gettext, itstool, libxml2
 , meson, ninja, vala, python3, desktop-file-utils
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     gnome3.adwaita-icon-theme
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Taquin";
     description = "Move tiles so that they reach their places";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/gnome-tetravex/default.nix b/pkgs/desktops/gnome-3/games/gnome-tetravex/default.nix
index 420943580c0d0..42137e9caa537 100644
--- a/pkgs/desktops/gnome-3/games/gnome-tetravex/default.nix
+++ b/pkgs/desktops/gnome-3/games/gnome-tetravex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
+{ lib, stdenv, fetchurl, pkgconfig, gnome3, gtk3, wrapGAppsHook
 , libxml2, gettext, itstool, meson, ninja, python3
 , vala, desktop-file-utils
 }:
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     patchShebangs build-aux/meson_post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Tetravex";
     description = "Complete the puzzle by matching numbered tiles";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/hitori/default.nix b/pkgs/desktops/gnome-3/games/hitori/default.nix
index 7dac364dcb296..3e5d0e0097995 100644
--- a/pkgs/desktops/gnome-3/games/hitori/default.nix
+++ b/pkgs/desktops/gnome-3/games/hitori/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Hitori";
     description = "GTK application to generate and let you play games of Hitori";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/iagno/default.nix b/pkgs/desktops/gnome-3/games/iagno/default.nix
index 9443fc2bb8ca0..15be308e4e9e2 100644
--- a/pkgs/desktops/gnome-3/games/iagno/default.nix
+++ b/pkgs/desktops/gnome-3/games/iagno/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , pkg-config
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Iagno";
     description = "Computer version of the game Reversi, more popularly called Othello";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/lightsoff/default.nix b/pkgs/desktops/gnome-3/games/lightsoff/default.nix
index f5425205db604..828a9ac24fb58 100644
--- a/pkgs/desktops/gnome-3/games/lightsoff/default.nix
+++ b/pkgs/desktops/gnome-3/games/lightsoff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, vala, pkgconfig, gtk3, gnome3, gdk-pixbuf, librsvg, wrapGAppsHook
+{ lib, stdenv, fetchurl, vala, pkgconfig, gtk3, gnome3, gdk-pixbuf, librsvg, wrapGAppsHook
 , gettext, itstool, clutter, clutter-gtk, libxml2, appstream-glib
 , meson, ninja, python3 }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Lightsoff";
     description = "Puzzle game, where the objective is to turn off all of the tiles on the board";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/quadrapassel/default.nix b/pkgs/desktops/gnome-3/games/quadrapassel/default.nix
index 9bc1c5ee73ab1..c47b2776563e4 100644
--- a/pkgs/desktops/gnome-3/games/quadrapassel/default.nix
+++ b/pkgs/desktops/gnome-3/games/quadrapassel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk3, gnome3, gdk-pixbuf
+{ lib, stdenv, fetchurl, pkgconfig, gtk3, gnome3, gdk-pixbuf
 , librsvg, gsound, libmanette
 , gettext, itstool, libxml2, clutter, clutter-gtk, wrapGAppsHook
 , meson, ninja, python3, vala, desktop-file-utils
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Classic falling-block game, Tetris";
     homepage = "https://wiki.gnome.org/Apps/Quadrapassel";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/games/swell-foop/default.nix b/pkgs/desktops/gnome-3/games/swell-foop/default.nix
index 4b12609d3f3d9..a96ccd5c9b6c9 100644
--- a/pkgs/desktops/gnome-3/games/swell-foop/default.nix
+++ b/pkgs/desktops/gnome-3/games/swell-foop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, vala, glib, gtk3, gnome3, desktop-file-utils
+{ lib, stdenv, fetchurl, meson, ninja, pkgconfig, vala, glib, gtk3, gnome3, desktop-file-utils
 , clutter, clutter-gtk, gettext, itstool, libxml2, wrapGAppsHook, python3 }:
 
 let
@@ -27,7 +27,7 @@ in stdenv.mkDerivation rec {
     patchShebangs meson_post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Swell%20Foop";
     description = "Puzzle game, previously known as Same GNOME";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/games/tali/default.nix b/pkgs/desktops/gnome-3/games/tali/default.nix
index fea6ce571e0b3..c6d28cd3bc160 100644
--- a/pkgs/desktops/gnome-3/games/tali/default.nix
+++ b/pkgs/desktops/gnome-3/games/tali/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk3, gnome3, gdk-pixbuf
+{ lib, stdenv, fetchurl, pkgconfig, gtk3, gnome3, gdk-pixbuf
 , librsvg, libgnome-games-support, gettext, itstool, libxml2, wrapGAppsHook
 , meson, ninja, python3, desktop-file-utils
 }:
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     patchShebangs build-aux/meson_post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Tali";
     description = "Sort of poker with dice and less money";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/misc/geary/default.nix b/pkgs/desktops/gnome-3/misc/geary/default.nix
index 6390b03efa31a..db9fb395d7d81 100644
--- a/pkgs/desktops/gnome-3/misc/geary/default.nix
+++ b/pkgs/desktops/gnome-3/misc/geary/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , pkgconfig
@@ -144,7 +144,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Geary";
     description = "Mail client for GNOME 3";
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/misc/gitg/default.nix b/pkgs/desktops/gnome-3/misc/gitg/default.nix
index c4849f00d3b94..0ba1d1130bd5a 100644
--- a/pkgs/desktops/gnome-3/misc/gitg/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gitg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , vala
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Gitg";
     description = "GNOME GUI client to view git repositories";
     maintainers = with maintainers; [ domenkozar ];
diff --git a/pkgs/desktops/gnome-3/misc/gnome-applets/default.nix b/pkgs/desktops/gnome-3/misc/gnome-applets/default.nix
index cc9e0a29d8fdd..601dded48953b 100644
--- a/pkgs/desktops/gnome-3/misc/gnome-applets/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gnome-applets/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gettext
 , itstool
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Applets for use with the GNOME panel";
     homepage = "https://wiki.gnome.org/Projects/GnomeApplets";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/misc/gnome-autoar/default.nix b/pkgs/desktops/gnome-3/misc/gnome-autoar/default.nix
index baa43bdedb3e5..5495bdb4c3da8 100644
--- a/pkgs/desktops/gnome-3/misc/gnome-autoar/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gnome-autoar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , gnome3
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     glib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     maintainers = teams.gnome.members;
     license = licenses.lgpl21;
diff --git a/pkgs/desktops/gnome-3/misc/gnome-flashback/default.nix b/pkgs/desktops/gnome-3/misc/gnome-flashback/default.nix
index 93b8fc2251b3b..84666a833086a 100644
--- a/pkgs/desktops/gnome-3/misc/gnome-flashback/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gnome-flashback/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoreconfHook
 , fetchurl
 , gettext
@@ -188,7 +188,7 @@ let
         '';
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "GNOME 2.x-like session for GNOME 3";
       homepage = "https://wiki.gnome.org/Projects/GnomeFlashback";
       license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/misc/gnome-packagekit/default.nix b/pkgs/desktops/gnome-3/misc/gnome-packagekit/default.nix
index 63a6512588232..c69966406e052 100644
--- a/pkgs/desktops/gnome-3/misc/gnome-packagekit/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gnome-packagekit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, meson, ninja, gettext, gnome3, packagekit, polkit
+{ lib, stdenv, fetchurl, pkgconfig, meson, ninja, gettext, gnome3, packagekit, polkit
 , gtk3, systemd, wrapGAppsHook, desktop-file-utils }:
 
 stdenv.mkDerivation rec {
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.freedesktop.org/software/PackageKit/";
     platforms = platforms.linux;
     maintainers = teams.gnome.members;
diff --git a/pkgs/desktops/gnome-3/misc/gnome-panel/default.nix b/pkgs/desktops/gnome-3/misc/gnome-panel/default.nix
index 518d8e198343c..d4ea880d1afcb 100644
--- a/pkgs/desktops/gnome-3/misc/gnome-panel/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gnome-panel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , autoreconfHook
 , dconf
@@ -88,7 +88,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Component of Gnome Flashback that provides panels and default applets for the desktop";
     homepage = "https://wiki.gnome.org/Projects/GnomePanel";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/misc/gpaste/default.nix b/pkgs/desktops/gnome-3/misc/gpaste/default.nix
index 0071d2415c14a..504846e8d4b33 100644
--- a/pkgs/desktops/gnome-3/misc/gpaste/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gpaste/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , appstream-glib
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     ${glib.dev}/bin/glib-compile-schemas "$out/share/glib-2.0/schemas"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Keruspe/GPaste";
     description = "Clipboard management system with GNOME 3 integration";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/gnome-3/misc/gtkhtml/default.nix b/pkgs/desktops/gnome-3/misc/gtkhtml/default.nix
index 9550de32fbeaa..0f99592743710 100644
--- a/pkgs/desktops/gnome-3/misc/gtkhtml/default.nix
+++ b/pkgs/desktops/gnome-3/misc/gtkhtml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk3, intltool
+{ lib, stdenv, fetchurl, pkgconfig, gtk3, intltool
 , gnome3, enchant, isocodes, gsettings-desktop-schemas }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = [ enchant isocodes ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     maintainers = teams.gnome.members;
   };
diff --git a/pkgs/desktops/gnome-3/misc/libgnome-games-support/default.nix b/pkgs/desktops/gnome-3/misc/libgnome-games-support/default.nix
index fb472ffff1db9..f5dd04cdb91e4 100644
--- a/pkgs/desktops/gnome-3/misc/libgnome-games-support/default.nix
+++ b/pkgs/desktops/gnome-3/misc/libgnome-games-support/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , glib
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small library intended for internal use by GNOME Games, but it may be used by others";
     homepage = "https://wiki.gnome.org/Apps/Games";
     license = licenses.lgpl3;
diff --git a/pkgs/desktops/gnome-3/misc/metacity/default.nix b/pkgs/desktops/gnome-3/misc/metacity/default.nix
index 04008f4c84bb5..ef16cf49a1567 100644
--- a/pkgs/desktops/gnome-3/misc/metacity/default.nix
+++ b/pkgs/desktops/gnome-3/misc/metacity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gettext
 , glib
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Window manager used in Gnome Flashback";
     homepage = "https://wiki.gnome.org/Projects/Metacity";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/gnome-3/misc/nautilus-python/default.nix b/pkgs/desktops/gnome-3/misc/nautilus-python/default.nix
index e8c523277e182..a942fded0877f 100644
--- a/pkgs/desktops/gnome-3/misc/nautilus-python/default.nix
+++ b/pkgs/desktops/gnome-3/misc/nautilus-python/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , which
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for the Nautilus Extension API";
     homepage = "https://wiki.gnome.org/Projects/NautilusPython";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/gnome-3/misc/pomodoro/default.nix b/pkgs/desktops/gnome-3/misc/pomodoro/default.nix
index 4676155c3c1c0..dfaa7f844aa71 100644
--- a/pkgs/desktops/gnome-3/misc/pomodoro/default.nix
+++ b/pkgs/desktops/gnome-3/misc/pomodoro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoconf-archive
 , appstream-glib
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
     sqlite
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gnomepomodoro.org/";
     description = "Time management utility for GNOME based on the pomodoro technique";
     longDescription = ''
diff --git a/pkgs/desktops/lumina/lumina-calculator/default.nix b/pkgs/desktops/lumina/lumina-calculator/default.nix
index 7451fa3facf5f..0b5690d94429b 100644
--- a/pkgs/desktops/lumina/lumina-calculator/default.nix
+++ b/pkgs/desktops/lumina/lumina-calculator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, qtbase, qttools }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, qtbase, qttools }:
 
 mkDerivation rec {
   pname = "lumina-calculator";
@@ -22,7 +22,7 @@ mkDerivation rec {
     "LRELEASE=${stdenv.lib.getDev qttools}/bin/lrelease"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scientific calculator for the Lumina Desktop";
     homepage = "https://github.com/lumina-desktop/lumina-calculator";
     license = licenses.bsd3;
diff --git a/pkgs/desktops/lumina/lumina-pdf/default.nix b/pkgs/desktops/lumina/lumina-pdf/default.nix
index b4e5039af1fe8..1e16913160451 100644
--- a/pkgs/desktops/lumina/lumina-pdf/default.nix
+++ b/pkgs/desktops/lumina/lumina-pdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, qtbase, qttools, poppler }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, qtbase, qttools, poppler }:
 
 mkDerivation rec {
   pname = "lumina-pdf";
@@ -28,7 +28,7 @@ mkDerivation rec {
 
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PDF viewer for the Lumina Desktop";
     homepage = "https://github.com/lumina-desktop/lumina-pdf";
     license = licenses.bsd3;
diff --git a/pkgs/desktops/lumina/lumina/default.nix b/pkgs/desktops/lumina/lumina/default.nix
index ff1810db6e6ee..ec2cbc3b2971c 100644
--- a/pkgs/desktops/lumina/lumina/default.nix
+++ b/pkgs/desktops/lumina/lumina/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchFromGitHub
 , fluxbox
@@ -86,7 +86,7 @@ mkDerivation rec {
 
   passthru.providedSessions = [ "Lumina-DE" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight, portable desktop environment";
     longDescription = ''
       The Lumina Desktop Environment is a lightweight system interface
diff --git a/pkgs/desktops/lxde/core/lxappearance/default.nix b/pkgs/desktops/lxde/core/lxappearance/default.nix
index b838c19afc8ee..4119f4c41341a 100644
--- a/pkgs/desktops/lxde/core/lxappearance/default.nix
+++ b/pkgs/desktops/lxde/core/lxappearance/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , intltool
 , pkg-config
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = stdenv.lib.optional withGtk3 "--enable-gtk3";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight program for configuring the theme and fonts of gtk applications";
     homepage = "https://lxde.org/";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/lxde/core/lxrandr/default.nix b/pkgs/desktops/lxde/core/lxrandr/default.nix
index ab109f3c6d459..6ac021397de33 100644
--- a/pkgs/desktops/lxde/core/lxrandr/default.nix
+++ b/pkgs/desktops/lxde/core/lxrandr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, gtk2, libX11, xrandr, withGtk3 ? false, gtk3 }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, gtk2, libX11, xrandr, withGtk3 ? false, gtk3 }:
 
 stdenv.mkDerivation rec {
   name = "lxrandr-0.3.2";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig intltool ];
   buildInputs = [ libX11 (if withGtk3 then gtk3 else gtk2) xrandr ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Standard screen manager of LXDE";
     homepage = "https://lxde.org/";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/desktops/mate/atril/default.nix b/pkgs/desktops/mate/atril/default.nix
index 12c89ee1b111a..50254fbd29cfd 100644
--- a/pkgs/desktops/mate/atril/default.nix
+++ b/pkgs/desktops/mate/atril/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , gettext
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple multi-page document viewer for the MATE desktop";
     homepage = "https://mate-desktop.org";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/caja-dropbox/default.nix b/pkgs/desktops/mate/caja-dropbox/default.nix
index 7b2387721dca5..85179214b08fe 100644
--- a/pkgs/desktops/mate/caja-dropbox/default.nix
+++ b/pkgs/desktops/mate/caja-dropbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll
+{ lib, stdenv, fetchurl, substituteAll
 , pkgconfig, gobject-introspection, gdk-pixbuf
 , gtk3, mate, python3, dropbox }:
 
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dropbox extension for Caja file manager";
     homepage = "https://github.com/mate-desktop/caja-dropbox";
     license = with licenses; [ gpl3 cc-by-nd-30 ];
diff --git a/pkgs/desktops/mate/caja-extensions/default.nix b/pkgs/desktops/mate/caja-extensions/default.nix
index d71d72ce1886e..a9cd7abf85746 100644
--- a/pkgs/desktops/mate/caja-extensions/default.nix
+++ b/pkgs/desktops/mate/caja-extensions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, gupnp, mate, imagemagick, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, gupnp, mate, imagemagick, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "caja-extensions";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of extensions for Caja file manager";
     homepage = "https://mate-desktop.org";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/libmatekbd/default.nix b/pkgs/desktops/mate/libmatekbd/default.nix
index f0e178ea9e8e4..4b652d06d29e3 100644
--- a/pkgs/desktops/mate/libmatekbd/default.nix
+++ b/pkgs/desktops/mate/libmatekbd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, libxklavier }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, libxklavier }:
 
 stdenv.mkDerivation rec {
   pname = "libmatekbd";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Keyboard management library for MATE";
     homepage = "https://github.com/mate-desktop/libmatekbd";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/libmatemixer/default.nix b/pkgs/desktops/mate/libmatemixer/default.nix
index 8b1e68e8b35cc..97a55b5e45eb5 100644
--- a/pkgs/desktops/mate/libmatemixer/default.nix
+++ b/pkgs/desktops/mate/libmatemixer/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv, fetchurl, pkgconfig, gettext, glib
+{ config, lib, stdenv, fetchurl, pkgconfig, gettext, glib
 , alsaSupport ? stdenv.isLinux, alsaLib
 , pulseaudioSupport ? config.pulseaudio or true, libpulseaudio
 , ossSupport ? false
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mixer library for MATE";
     homepage = "https://github.com/mate-desktop/libmatemixer";
     license = with licenses; [ gpl2 lgpl2 ];
diff --git a/pkgs/desktops/mate/libmateweather/default.nix b/pkgs/desktops/mate/libmateweather/default.nix
index 3bfdfea06f170..4ecdfcdf157f3 100644
--- a/pkgs/desktops/mate/libmateweather/default.nix
+++ b/pkgs/desktops/mate/libmateweather/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, libsoup, tzdata }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, libsoup, tzdata }:
 
 stdenv.mkDerivation rec {
   pname = "libmateweather";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library to access weather information from online services for MATE";
     homepage = "https://github.com/mate-desktop/libmateweather";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/marco/default.nix b/pkgs/desktops/mate/marco/default.nix
index 69beaa3cee7ae..fc098428fcb5f 100644
--- a/pkgs/desktops/mate/marco/default.nix
+++ b/pkgs/desktops/mate/marco/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, libxml2, libcanberra-gtk3, libgtop, libstartup_notification, gnome3, gtk3, mate-settings-daemon, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, libxml2, libcanberra-gtk3, libgtop, libstartup_notification, gnome3, gtk3, mate-settings-daemon, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "marco";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MATE default window manager";
     homepage = "https://github.com/mate-desktop/marco";
     license = [ licenses.gpl2 ];
diff --git a/pkgs/desktops/mate/mate-applets/default.nix b/pkgs/desktops/mate/mate-applets/default.nix
index 2a97bc851da08..533070c2698a4 100644
--- a/pkgs/desktops/mate/mate-applets/default.nix
+++ b/pkgs/desktops/mate/mate-applets/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, gnome3, glib, gtk3, gtksourceview3, libwnck3, libgtop, libxml2, libnotify, polkit, upower, wirelesstools, mate, hicolor-icon-theme, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, gnome3, glib, gtk3, gtksourceview3, libwnck3, libgtop, libxml2, libnotify, polkit, upower, wirelesstools, mate, hicolor-icon-theme, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-applets";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Applets for use with the MATE panel";
     homepage = "https://mate-desktop.org";
     license = with licenses; [ gpl2Plus lgpl2Plus ];
diff --git a/pkgs/desktops/mate/mate-backgrounds/default.nix b/pkgs/desktops/mate/mate-backgrounds/default.nix
index 8e2aa6933ffe6..f49529c4a6633 100644
--- a/pkgs/desktops/mate/mate-backgrounds/default.nix
+++ b/pkgs/desktops/mate/mate-backgrounds/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, gettext }:
+{ lib, stdenv, fetchurl, meson, ninja, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "mate-backgrounds";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     ninja
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Background images and data for MATE";
     homepage = "https://mate-desktop.org";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/mate-calc/default.nix b/pkgs/desktops/mate/mate-calc/default.nix
index 48c9f37c03af2..a9ed85e650b59 100644
--- a/pkgs/desktops/mate/mate-calc/default.nix
+++ b/pkgs/desktops/mate/mate-calc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, gtk3, libxml2, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, gtk3, libxml2, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-calc";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calculator for the MATE desktop";
     homepage = "https://mate-desktop.org";
     license = [ licenses.gpl2Plus ];
diff --git a/pkgs/desktops/mate/mate-control-center/default.nix b/pkgs/desktops/mate/mate-control-center/default.nix
index 4c26961ba1564..397f4969b6ec8 100644
--- a/pkgs/desktops/mate/mate-control-center/default.nix
+++ b/pkgs/desktops/mate/mate-control-center/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, libxml2, dbus-glib,
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, libxml2, dbus-glib,
   libxklavier, libcanberra-gtk3, librsvg, libappindicator-gtk3,
   desktop-file-utils, dconf, gtk3, polkit, mate, hicolor-icon-theme, wrapGAppsHook
 }:
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities to configure the MATE desktop";
     homepage = "https://github.com/mate-desktop/mate-control-center";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/mate-desktop/default.nix b/pkgs/desktops/mate/mate-desktop/default.nix
index 2e298d14168eb..1f9db9a95202b 100644
--- a/pkgs/desktops/mate/mate-desktop/default.nix
+++ b/pkgs/desktops/mate/mate-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, isocodes, gnome3, gtk3, dconf, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, isocodes, gnome3, gtk3, dconf, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-desktop";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library with common API for various MATE modules";
     homepage = "https://mate-desktop.org";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/mate-indicator-applet/default.nix b/pkgs/desktops/mate/mate-indicator-applet/default.nix
index 235929dce0c71..981a5a04f02cd 100644
--- a/pkgs/desktops/mate/mate-indicator-applet/default.nix
+++ b/pkgs/desktops/mate/mate-indicator-applet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, libindicator-gtk3, mate, hicolor-icon-theme, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, libindicator-gtk3, mate, hicolor-icon-theme, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-indicator-applet";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mate-desktop/mate-indicator-applet";
     description = "MATE panel indicator applet";
     longDescription = ''
diff --git a/pkgs/desktops/mate/mate-media/default.nix b/pkgs/desktops/mate/mate-media/default.nix
index 458e4638ada87..77e98495b0990 100644
--- a/pkgs/desktops/mate/mate-media/default.nix
+++ b/pkgs/desktops/mate/mate-media/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, libtool, libxml2, libcanberra-gtk3, gtk3, mate, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, libtool, libxml2, libcanberra-gtk3, gtk3, mate, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-media";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Media tools for MATE";
     homepage = "https://mate-desktop.org";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/mate/mate-menus/default.nix b/pkgs/desktops/mate/mate-menus/default.nix
index 73f8be24cc380..ae145061e1fb7 100644
--- a/pkgs/desktops/mate/mate-menus/default.nix
+++ b/pkgs/desktops/mate/mate-menus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, glib, gobject-introspection, python3 }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, glib, gobject-introspection, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "mate-menus";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Menu system for MATE";
     homepage = "https://github.com/mate-desktop/mate-menus";
     license = with licenses; [ gpl2 lgpl2 ];
diff --git a/pkgs/desktops/mate/mate-netbook/default.nix b/pkgs/desktops/mate/mate-netbook/default.nix
index 4c3338ef907df..7103464f23ac2 100644
--- a/pkgs/desktops/mate/mate-netbook/default.nix
+++ b/pkgs/desktops/mate/mate-netbook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, libwnck3, libfakekey, libXtst, mate, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, libwnck3, libfakekey, libXtst, mate, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-netbook";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MATE utilities for netbooks";
     longDescription = ''
       MATE utilities for netbooks are an applet and a daemon to maximize
diff --git a/pkgs/desktops/mate/mate-notification-daemon/default.nix b/pkgs/desktops/mate/mate-notification-daemon/default.nix
index 0a797f4defa0b..6c95f445ace71 100644
--- a/pkgs/desktops/mate/mate-notification-daemon/default.nix
+++ b/pkgs/desktops/mate/mate-notification-daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, glib, libcanberra-gtk3,
+{ lib, stdenv, fetchurl, pkgconfig, gettext, glib, libcanberra-gtk3,
   libnotify, libwnck3, gtk3, libxml2, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Notification daemon for MATE Desktop";
     homepage = "https://github.com/mate-desktop/mate-notification-daemon";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/mate/mate-panel/default.nix b/pkgs/desktops/mate/mate-panel/default.nix
index 4b021bcc0991b..9a09b5e949f4c 100644
--- a/pkgs/desktops/mate/mate-panel/default.nix
+++ b/pkgs/desktops/mate/mate-panel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, glib, libwnck3, librsvg, libxml2, dconf, gtk3, mate, hicolor-icon-theme, gobject-introspection, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, glib, libwnck3, librsvg, libxml2, dconf, gtk3, mate, hicolor-icon-theme, gobject-introspection, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-panel";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The MATE panel";
     homepage = "https://github.com/mate-desktop/mate-panel";
     license = with licenses; [ gpl2 lgpl2 ];
diff --git a/pkgs/desktops/mate/mate-polkit/default.nix b/pkgs/desktops/mate/mate-polkit/default.nix
index 2ab526240418d..556bfa02d3d30 100644
--- a/pkgs/desktops/mate/mate-polkit/default.nix
+++ b/pkgs/desktops/mate/mate-polkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, gobject-introspection, libappindicator-gtk3, libindicator-gtk3, polkit }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, gobject-introspection, libappindicator-gtk3, libindicator-gtk3, polkit }:
 
 stdenv.mkDerivation rec {
   pname = "mate-polkit";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integrates polkit authentication for MATE desktop";
     homepage = "https://mate-desktop.org";
     license = [ licenses.gpl2Plus ];
diff --git a/pkgs/desktops/mate/mate-power-manager/default.nix b/pkgs/desktops/mate/mate-power-manager/default.nix
index c6872cc5beb9a..995041be6bd47 100644
--- a/pkgs/desktops/mate/mate-power-manager/default.nix
+++ b/pkgs/desktops/mate/mate-power-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, glib, itstool, libxml2, mate-panel, libnotify, libcanberra-gtk3, dbus-glib, upower, gnome3, gtk3, libtool, polkit, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, glib, itstool, libxml2, mate-panel, libnotify, libcanberra-gtk3, dbus-glib, upower, gnome3, gtk3, libtool, polkit, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-power-manager";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The MATE Power Manager";
     homepage = "https://mate-desktop.org";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/mate/mate-screensaver/default.nix b/pkgs/desktops/mate/mate-screensaver/default.nix
index f05d8a736d5d8..18f8f57133205 100644
--- a/pkgs/desktops/mate/mate-screensaver/default.nix
+++ b/pkgs/desktops/mate/mate-screensaver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, dbus-glib, libXScrnSaver, libnotify, libxml2, pam, systemd, mate, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, dbus-glib, libXScrnSaver, libnotify, libxml2, pam, systemd, mate, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-screensaver";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Screen saver and locker for the MATE desktop";
     homepage = "https://mate-desktop.org";
     license = with licenses; [ gpl2Plus lgpl2Plus ];
diff --git a/pkgs/desktops/mate/mate-sensors-applet/default.nix b/pkgs/desktops/mate/mate-sensors-applet/default.nix
index babdbcb4da0e1..21b5a58a1439c 100644
--- a/pkgs/desktops/mate/mate-sensors-applet/default.nix
+++ b/pkgs/desktops/mate/mate-sensors-applet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, gtk3, libxml2, libxslt, libatasmart, libnotify, lm_sensors, mate, hicolor-icon-theme, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, gtk3, libxml2, libxslt, libatasmart, libnotify, lm_sensors, mate, hicolor-icon-theme, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-sensors-applet";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mate-desktop/mate-sensors-applet";
     description = "MATE panel applet for hardware sensors";
     license = with licenses; [ gpl2Plus ];
diff --git a/pkgs/desktops/mate/mate-session-manager/default.nix b/pkgs/desktops/mate/mate-session-manager/default.nix
index b8b61324574b9..64dfd65b20d81 100644
--- a/pkgs/desktops/mate/mate-session-manager/default.nix
+++ b/pkgs/desktops/mate/mate-session-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, xtrans, dbus-glib, systemd,
+{ lib, stdenv, fetchurl, pkgconfig, gettext, xtrans, dbus-glib, systemd,
   libSM, libXtst, gtk3, epoxy, polkit, hicolor-icon-theme, mate,
   wrapGAppsHook, fetchpatch
 }:
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
 
   passthru.providedSessions = [ "mate" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MATE Desktop session manager";
     homepage = "https://github.com/mate-desktop/mate-session-manager";
     license = with licenses; [ gpl2 lgpl2 ];
diff --git a/pkgs/desktops/mate/mate-settings-daemon/default.nix b/pkgs/desktops/mate/mate-settings-daemon/default.nix
index e02323858625c..467b8c7c9b0fc 100644
--- a/pkgs/desktops/mate/mate-settings-daemon/default.nix
+++ b/pkgs/desktops/mate/mate-settings-daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, glib, dbus-glib, libxklavier,
+{ lib, stdenv, fetchurl, pkgconfig, gettext, glib, dbus-glib, libxklavier,
   libcanberra-gtk3, libnotify, nss, polkit, dconf, gtk3, mate,
   pulseaudioSupport ? stdenv.config.pulseaudio or true, libpulseaudio,
   wrapGAppsHook }:
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MATE settings daemon";
     homepage = "https://github.com/mate-desktop/mate-settings-daemon";
     license = with licenses; [ gpl2 lgpl21 ];
diff --git a/pkgs/desktops/mate/mate-system-monitor/default.nix b/pkgs/desktops/mate/mate-system-monitor/default.nix
index 38c6a041e4336..f6e767e94abc2 100644
--- a/pkgs/desktops/mate/mate-system-monitor/default.nix
+++ b/pkgs/desktops/mate/mate-system-monitor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, gtkmm3, libxml2, libgtop, libwnck3, librsvg, polkit, systemd, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, gtkmm3, libxml2, libgtop, libwnck3, librsvg, polkit, systemd, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-system-monitor";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System monitor for the MATE desktop";
     homepage = "https://mate-desktop.org";
     license = [ licenses.gpl2Plus ];
diff --git a/pkgs/desktops/mate/mate-terminal/default.nix b/pkgs/desktops/mate/mate-terminal/default.nix
index c187aba897752..1772eacbd04c5 100644
--- a/pkgs/desktops/mate/mate-terminal/default.nix
+++ b/pkgs/desktops/mate/mate-terminal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, glib, itstool, libxml2, mate, dconf, gtk3, vte, pcre2, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, glib, itstool, libxml2, mate, dconf, gtk3, vte, pcre2, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-terminal";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The MATE Terminal Emulator";
     homepage = "https://mate-desktop.org";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/mate/mate-tweak/default.nix b/pkgs/desktops/mate/mate-tweak/default.nix
index 9609d832f6b11..316a72a09c7f2 100644
--- a/pkgs/desktops/mate/mate-tweak/default.nix
+++ b/pkgs/desktops/mate/mate-tweak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3Packages
 , intltool
@@ -72,7 +72,7 @@ python3Packages.buildPythonApplication rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tweak tool for the MATE Desktop";
     homepage = "https://github.com/ubuntu-mate/mate-tweak";
     changelog = "https://github.com/ubuntu-mate/mate-tweak/releases/tag/${version}";
diff --git a/pkgs/desktops/mate/mate-user-guide/default.nix b/pkgs/desktops/mate/mate-user-guide/default.nix
index 20ab8a9a361f2..7a95620f31e6b 100644
--- a/pkgs/desktops/mate/mate-user-guide/default.nix
+++ b/pkgs/desktops/mate/mate-user-guide/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gettext, itstool, libxml2, yelp }:
+{ lib, stdenv, fetchurl, gettext, itstool, libxml2, yelp }:
 
 stdenv.mkDerivation rec {
   pname = "mate-user-guide";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MATE User Guide";
     homepage = "https://mate-desktop.org";
     license = with licenses; [ gpl2Plus fdl12 ];
diff --git a/pkgs/desktops/mate/mate-user-share/default.nix b/pkgs/desktops/mate/mate-user-share/default.nix
index ba27ae6ce1028..29f169f447d71 100644
--- a/pkgs/desktops/mate/mate-user-share/default.nix
+++ b/pkgs/desktops/mate/mate-user-share/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, gtk3, dbus-glib, libnotify, libxml2, libcanberra-gtk3, mod_dnssd, apacheHttpd, hicolor-icon-theme, mate, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, gtk3, dbus-glib, libnotify, libxml2, libcanberra-gtk3, mod_dnssd, apacheHttpd, hicolor-icon-theme, mate, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-user-share";
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "User level public file sharing for the MATE desktop";
     homepage = "https://github.com/mate-desktop/mate-user-share";
     license = with licenses; [ gpl2Plus ];
diff --git a/pkgs/desktops/mate/mate-utils/default.nix b/pkgs/desktops/mate/mate-utils/default.nix
index e36ff69a6fa7f..2faa99f9a8b60 100644
--- a/pkgs/desktops/mate/mate-utils/default.nix
+++ b/pkgs/desktops/mate/mate-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, itstool, glib, gtk3, libxml2, libgtop, libcanberra-gtk3, inkscape, udisks2, mate, hicolor-icon-theme, wrapGAppsHook }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, itstool, glib, gtk3, libxml2, libgtop, libcanberra-gtk3, inkscape, udisks2, mate, hicolor-icon-theme, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "mate-utils";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for the MATE desktop";
     homepage = "https://mate-desktop.org";
     license = with licenses; [ gpl2Plus lgpl2Plus ];
diff --git a/pkgs/desktops/mate/mozo/default.nix b/pkgs/desktops/mate/mozo/default.nix
index 7bad399623a79..669d5400881e4 100644
--- a/pkgs/desktops/mate/mozo/default.nix
+++ b/pkgs/desktops/mate/mozo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchurl, pkgconfig, gettext, mate, gtk3, glib, wrapGAppsHook, gobject-introspection }:
+{ lib, stdenv, python3, fetchurl, pkgconfig, gettext, mate, gtk3, glib, wrapGAppsHook, gobject-introspection }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "mozo";
@@ -20,7 +20,7 @@ python3.pkgs.buildPythonApplication rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MATE Desktop menu editor";
     homepage = "https://github.com/mate-desktop/mozo";
     license = with licenses; [ lgpl2Plus ];
diff --git a/pkgs/desktops/mate/python-caja/default.nix b/pkgs/desktops/mate/python-caja/default.nix
index 570eaefb5990c..fef39d11f9d38 100644
--- a/pkgs/desktops/mate/python-caja/default.nix
+++ b/pkgs/desktops/mate/python-caja/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, gtk3, mate, python3Packages }:
+{ lib, stdenv, fetchurl, pkgconfig, gettext, gtk3, mate, python3Packages }:
 
 stdenv.mkDerivation rec {
   pname = "python-caja";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python binding for Caja components";
     homepage = "https://github.com/mate-desktop/python-caja";
     license = [ licenses.gpl2Plus ];
diff --git a/pkgs/desktops/pantheon/apps/appcenter/default.nix b/pkgs/desktops/pantheon/apps/appcenter/default.nix
index ca7ace8e79dff..11ba1182f2523 100644
--- a/pkgs/desktops/pantheon/apps/appcenter/default.nix
+++ b/pkgs/desktops/pantheon/apps/appcenter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , nix-update-script
 , appstream
 , appstream-glib
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/elementary/appcenter";
     description = "An open, pay-what-you-want app store for indie developers, designed for elementary OS";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-calculator/default.nix b/pkgs/desktops/pantheon/apps/elementary-calculator/default.nix
index 0695b6e4006ee..c75ffa8acf3de 100644
--- a/pkgs/desktops/pantheon/apps/elementary-calculator/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-calculator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/elementary/calculator";
     description = "Calculator app designed for elementary OS";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-calendar/default.nix b/pkgs/desktops/pantheon/apps/elementary-calendar/default.nix
index 66bba6dfe793e..48c660aeccb70 100644
--- a/pkgs/desktops/pantheon/apps/elementary-calendar/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-calendar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop calendar app designed for elementary OS";
     homepage = "https://github.com/elementary/calendar";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-camera/default.nix b/pkgs/desktops/pantheon/apps/elementary-camera/default.nix
index e7bb60a062d8f..0640265e6db7f 100644
--- a/pkgs/desktops/pantheon/apps/elementary-camera/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-camera/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -73,7 +73,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Camera app designed for elementary OS";
     homepage = "https://github.com/elementary/camera";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-code/default.nix b/pkgs/desktops/pantheon/apps/elementary-code/default.nix
index 3454ff086c9a8..538194edd4582 100644
--- a/pkgs/desktops/pantheon/apps/elementary-code/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-code/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -88,7 +88,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Code editor designed for elementary OS";
     homepage = "https://github.com/elementary/code";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-dock/default.nix b/pkgs/desktops/pantheon/apps/elementary-dock/default.nix
index 7cc34f8c82c98..c28ee297e3356 100644
--- a/pkgs/desktops/pantheon/apps/elementary-dock/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-dock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , vala
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
     pango
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Elegant, simple, clean dock";
     homepage = "https://github.com/elementary/dock";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-feedback/default.nix b/pkgs/desktops/pantheon/apps/elementary-feedback/default.nix
index 29b897012e7d6..abad7f42eb8d6 100644
--- a/pkgs/desktops/pantheon/apps/elementary-feedback/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-feedback/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GitHub Issue Reporter designed for elementary OS";
     homepage = "https://github.com/elementary/feedback";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-files/default.nix b/pkgs/desktops/pantheon/apps/elementary-files/default.nix
index 9433edc9ce5f4..635f77e09ed81 100644
--- a/pkgs/desktops/pantheon/apps/elementary-files/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-files/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -92,7 +92,7 @@ stdenv.mkDerivation rec {
       --subst-var-by ELEMENTARY_FILES_GSETTINGS_PATH ${glib.makeSchemaPath "$out" "${pname}-${version}"}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "File browser designed for elementary OS";
     homepage = "https://github.com/elementary/files";
     license = licenses.lgpl3;
diff --git a/pkgs/desktops/pantheon/apps/elementary-music/default.nix b/pkgs/desktops/pantheon/apps/elementary-music/default.nix
index 0e34b29f1de0f..b8306394f107a 100644
--- a/pkgs/desktops/pantheon/apps/elementary-music/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-music/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -90,7 +90,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Music player and library designed for elementary OS";
     homepage = "https://github.com/elementary/music";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/elementary-screenshot-tool/default.nix b/pkgs/desktops/pantheon/apps/elementary-screenshot-tool/default.nix
index da67ac0aed841..1224b9b31202b 100644
--- a/pkgs/desktops/pantheon/apps/elementary-screenshot-tool/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-screenshot-tool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Screenshot tool designed for elementary OS";
     homepage = "https://github.com/elementary/screenshot";
     license = licenses.lgpl3;
diff --git a/pkgs/desktops/pantheon/apps/elementary-terminal/default.nix b/pkgs/desktops/pantheon/apps/elementary-terminal/default.nix
index ddd5c0a0eac3b..456fee4472b3a 100644
--- a/pkgs/desktops/pantheon/apps/elementary-terminal/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-terminal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal emulator designed for elementary OS";
     longDescription = ''
       A super lightweight, beautiful, and simple terminal. Comes with sane defaults, browser-class tabs, sudo paste protection,
diff --git a/pkgs/desktops/pantheon/apps/elementary-videos/default.nix b/pkgs/desktops/pantheon/apps/elementary-videos/default.nix
index f51c6c0090d3e..95a61a5649d88 100644
--- a/pkgs/desktops/pantheon/apps/elementary-videos/default.nix
+++ b/pkgs/desktops/pantheon/apps/elementary-videos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Video player and library app designed for elementary OS";
     homepage = "https://github.com/elementary/videos";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/sideload/default.nix b/pkgs/desktops/pantheon/apps/sideload/default.nix
index 2fc5d560da0f6..df483b9a79602 100644
--- a/pkgs/desktops/pantheon/apps/sideload/default.nix
+++ b/pkgs/desktops/pantheon/apps/sideload/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , desktop-file-utils
 , nix-update-script
 , elementary-gtk-theme
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/elementary/sideload";
     description = "Flatpak installer, designed for elementary OS";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/a11y/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/a11y/default.nix
index 9937edc22b5ba..699aa56f4a7a2 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/a11y/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/a11y/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , substituteAll
 , fetchFromGitHub
 , nix-update-script
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Universal Access Plug";
     homepage = "https://github.com/elementary/switchboard-plug-a11y";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/about/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/about/default.nix
index f174c41abc7b3..fad80f1319619 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/about/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/about/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , nix-update-script
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard About Plug";
     homepage = "https://github.com/elementary/switchboard-plug-about";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/applications/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/applications/default.nix
index b5a8cc7665161..3c76dc9053ca2 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/applications/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/applications/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Applications Plug";
     homepage = "https://github.com/elementary/switchboard-plug-applications";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/bluetooth/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/bluetooth/default.nix
index ab1e0b5280a81..3f35c6a46b925 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/bluetooth/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/bluetooth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Bluetooth Plug";
     homepage = "https://github.com/elementary/switchboard-plug-bluetooth";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/datetime/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/datetime/default.nix
index 95a454b36f435..036b21a08fcbd 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/datetime/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/datetime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Date & Time Plug";
     homepage = "https://github.com/elementary/switchboard-plug-datetime";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/display/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/display/default.nix
index 490c8c57a67c9..4471ebaef23fe 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/display/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/display/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Displays Plug";
     homepage = "https://github.com/elementary/switchboard-plug-display";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/keyboard/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/keyboard/default.nix
index d1180f37ed066..8cb401e48de94 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/keyboard/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/keyboard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Keyboard Plug";
     homepage = "https://github.com/elementary/switchboard-plug-keyboard";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/mouse-touchpad/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/mouse-touchpad/default.nix
index 78a74c59e9ed9..c1177c54b24c9 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/mouse-touchpad/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/mouse-touchpad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Mouse & Touchpad Plug";
     homepage = "https://github.com/elementary/switchboard-plug-mouse-touchpad";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/network/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/network/default.nix
index 2ce9aad5666e0..5672c442269c0 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/network/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/network/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
   ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Networking Plug";
     homepage = "https://github.com/elementary/switchboard-plug-network";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/notifications/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/notifications/default.nix
index 37f69a3cc1410..a1ed6b1085c98 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/notifications/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/notifications/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Notifications Plug";
     homepage = "https://github.com/elementary/switchboard-plug-notifications";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/onlineaccounts/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/onlineaccounts/default.nix
index 913fa58e28711..43a411a4d2520 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/onlineaccounts/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/onlineaccounts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -75,7 +75,7 @@ stdenv.mkDerivation rec {
   PKG_CONFIG_SWITCHBOARD_2_0_PLUGSDIR = "${placeholder "out"}/lib/switchboard";
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Online Accounts Plug";
     homepage = "https://github.com/elementary/switchboard-plug-onlineaccounts";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/pantheon-shell/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/pantheon-shell/default.nix
index d877d43d1378d..6a9b1f6494d57 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/pantheon-shell/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/pantheon-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nix-update-script, pantheon, meson, ninja, pkgconfig, vala, glib
+{ lib, stdenv, fetchFromGitHub, nix-update-script, pantheon, meson, ninja, pkgconfig, vala, glib
 , libgee, granite, gexiv2, elementary-settings-daemon, gtk3, gnome-desktop
 , gala, wingpanel, elementary-dock, switchboard, gettext, bamf, fetchpatch }:
 
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     wingpanel
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Desktop Plug";
     homepage = "https://github.com/elementary/switchboard-plug-pantheon-shell";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/power/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/power/default.nix
index 0549a797dbcb1..71ce891043ba2 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/power/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/power/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Power Plug";
     homepage = "https://github.com/elementary/switchboard-plug-power";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/printers/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/printers/default.nix
index 2e8f05d8416d4..6a9ade11736e9 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/printers/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/printers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Printers Plug";
     homepage = "https://github.com/elementary/switchboard-plug-printers";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/security-privacy/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/security-privacy/default.nix
index fd2a24db3e8a1..c90d88161a9a8 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/security-privacy/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/security-privacy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Security & Privacy Plug";
     homepage = "https://github.com/elementary/switchboard-plug-security-privacy";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/sharing/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/sharing/default.nix
index 47c4928c08b56..ff8fd5909bae1 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/sharing/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/sharing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Sharing Plug";
     homepage = "https://github.com/elementary/switchboard-plug-sharing";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard-plugs/sound/default.nix b/pkgs/desktops/pantheon/apps/switchboard-plugs/sound/default.nix
index cab47c94cb997..ead5305651b9e 100644
--- a/pkgs/desktops/pantheon/apps/switchboard-plugs/sound/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard-plugs/sound/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     switchboard
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switchboard Sound Plug";
     homepage = "https://github.com/elementary/switchboard-plug-sound";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/desktops/pantheon/apps/switchboard/default.nix b/pkgs/desktops/pantheon/apps/switchboard/default.nix
index 1327c4739eb79..d842b4f361bc7 100644
--- a/pkgs/desktops/pantheon/apps/switchboard/default.nix
+++ b/pkgs/desktops/pantheon/apps/switchboard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extensible System Settings app for Pantheon";
     homepage = "https://github.com/elementary/switchboard";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/pantheon/artwork/elementary-gtk-theme/default.nix b/pkgs/desktops/pantheon/artwork/elementary-gtk-theme/default.nix
index 05f1f10a5a7e4..437f379412208 100644
--- a/pkgs/desktops/pantheon/artwork/elementary-gtk-theme/default.nix
+++ b/pkgs/desktops/pantheon/artwork/elementary-gtk-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     ninja
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK theme designed to be smooth, attractive, fast, and usable";
     homepage = "https://github.com/elementary/stylesheet";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/pantheon/artwork/elementary-icon-theme/default.nix b/pkgs/desktops/pantheon/artwork/elementary-icon-theme/default.nix
index a12101c04d006..55935b2ee0e08 100644
--- a/pkgs/desktops/pantheon/artwork/elementary-icon-theme/default.nix
+++ b/pkgs/desktops/pantheon/artwork/elementary-icon-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
 
   postFixup = "gtk-update-icon-cache $out/share/icons/elementary";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Named, vector icons for elementary OS";
     longDescription = ''
       An original set of vector icons designed specifically for elementary OS and its desktop environment: Pantheon.
diff --git a/pkgs/desktops/pantheon/artwork/elementary-redacted-script/default.nix b/pkgs/desktops/pantheon/artwork/elementary-redacted-script/default.nix
index 50a455885162f..6a9d1b0aca365 100644
--- a/pkgs/desktops/pantheon/artwork/elementary-redacted-script/default.nix
+++ b/pkgs/desktops/pantheon/artwork/elementary-redacted-script/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pantheon
 }:
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     cp -a truetype/*.ttf $out/share/fonts/truetype/redacted-elementary
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Font for concealing text";
     homepage = "https://github.com/png2378/redacted-elementary";
     license = licenses.ofl;
diff --git a/pkgs/desktops/pantheon/artwork/elementary-sound-theme/default.nix b/pkgs/desktops/pantheon/artwork/elementary-sound-theme/default.nix
index e18cac7d4ab60..b4d7ce5b247d0 100644
--- a/pkgs/desktops/pantheon/artwork/elementary-sound-theme/default.nix
+++ b/pkgs/desktops/pantheon/artwork/elementary-sound-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of system sounds for elementary";
     homepage = "https://github.com/elementary/sound-theme";
     license = licenses.unlicense;
diff --git a/pkgs/desktops/pantheon/artwork/elementary-wallpapers/default.nix b/pkgs/desktops/pantheon/artwork/elementary-wallpapers/default.nix
index 975497cb9e4b5..3e4e64d730126 100644
--- a/pkgs/desktops/pantheon/artwork/elementary-wallpapers/default.nix
+++ b/pkgs/desktops/pantheon/artwork/elementary-wallpapers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of wallpapers for elementary";
     homepage = "https://github.com/elementary/wallpapers";
     license = licenses.publicDomain;
diff --git a/pkgs/desktops/pantheon/desktop/elementary-default-settings/default.nix b/pkgs/desktops/pantheon/desktop/elementary-default-settings/default.nix
index a8cf30e9732e8..278880657155e 100644
--- a/pkgs/desktops/pantheon/desktop/elementary-default-settings/default.nix
+++ b/pkgs/desktops/pantheon/desktop/elementary-default-settings/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -98,7 +98,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Default settings and configuration files for elementary";
     homepage = "https://github.com/elementary/default-settings";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/desktop/elementary-greeter/default.nix b/pkgs/desktops/pantheon/desktop/elementary-greeter/default.nix
index de93b0d36834a..27d82c345a9f5 100644
--- a/pkgs/desktops/pantheon/desktop/elementary-greeter/default.nix
+++ b/pkgs/desktops/pantheon/desktop/elementary-greeter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , linkFarm
@@ -120,7 +120,7 @@ stdenv.mkDerivation rec {
       --replace "Exec=io.elementary.greeter" "Exec=$out/bin/io.elementary.greeter"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LightDM Greeter for Pantheon";
     homepage = "https://github.com/elementary/greeter";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/desktop/elementary-onboarding/default.nix b/pkgs/desktops/pantheon/desktop/elementary-onboarding/default.nix
index 73de43594bdd5..6d900b2e03f41 100644
--- a/pkgs/desktops/pantheon/desktop/elementary-onboarding/default.nix
+++ b/pkgs/desktops/pantheon/desktop/elementary-onboarding/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Onboarding app for new users designed for elementary OS";
     homepage = "https://github.com/elementary/onboarding";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/desktop/elementary-print-shim/default.nix b/pkgs/desktops/pantheon/desktop/elementary-print-shim/default.nix
index 7610551fb9c1c..e80dc3644fbaa 100644
--- a/pkgs/desktops/pantheon/desktop/elementary-print-shim/default.nix
+++ b/pkgs/desktops/pantheon/desktop/elementary-print-shim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ gtk3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple shim for printing support via Contractor";
     homepage = "https://github.com/elementary/print";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/desktop/elementary-session-settings/default.nix b/pkgs/desktops/pantheon/desktop/elementary-session-settings/default.nix
index 63e9fe3f6fa8d..27a379f4738d1 100644
--- a/pkgs/desktops/pantheon/desktop/elementary-session-settings/default.nix
+++ b/pkgs/desktops/pantheon/desktop/elementary-session-settings/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , substituteAll
@@ -153,7 +153,7 @@ stdenv.mkDerivation rec {
     ];
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Session settings for elementary";
     homepage = "https://github.com/elementary/session-settings";
     license = licenses.lgpl3;
diff --git a/pkgs/desktops/pantheon/desktop/elementary-shortcut-overlay/default.nix b/pkgs/desktops/pantheon/desktop/elementary-shortcut-overlay/default.nix
index 4e6afb9ff89de..d3f3725ad8329 100644
--- a/pkgs/desktops/pantheon/desktop/elementary-shortcut-overlay/default.nix
+++ b/pkgs/desktops/pantheon/desktop/elementary-shortcut-overlay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     libgee
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A native OS-wide shortcut overlay to be launched by Gala";
     homepage = "https://github.com/elementary/shortcut-overlay";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/desktop/extra-elementary-contracts/default.nix b/pkgs/desktops/pantheon/desktop/extra-elementary-contracts/default.nix
index bfeda383ea4ea..2db483cb5c7ef 100644
--- a/pkgs/desktops/pantheon/desktop/extra-elementary-contracts/default.nix
+++ b/pkgs/desktops/pantheon/desktop/extra-elementary-contracts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , substituteAll
 , fetchFromGitHub
 , file-roller
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     cp *.contract $out/share/contractor/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extra contractor files for elementary";
     homepage = "https://github.com/worldofpeace/extra-elementary-contracts";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/applications-menu/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/applications-menu/default.nix
index 27e6215b78735..19c565ac9f925 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/applications-menu/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/applications-menu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , nix-update-script
@@ -100,7 +100,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight and stylish app launcher for Pantheon";
     homepage = "https://github.com/elementary/applications-menu";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/bluetooth/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/bluetooth/default.nix
index 995577b80d068..4e6fd0e4f6cb4 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/bluetooth/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/bluetooth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bluetooth Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-bluetooth";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/datetime/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/datetime/default.nix
index 09583877fb132..2b5898db932d6 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/datetime/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/datetime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Date & Time Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-datetime";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/keyboard/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/keyboard/default.nix
index 712b25d22f453..01c3ee9e275bf 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/keyboard/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/keyboard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Keyboard Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-keyboard";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/network/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/network/default.nix
index 7f1ee7fbfbac8..eb69d6410eb00 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/network/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/network/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     wingpanel
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-network";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/nightlight/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/nightlight/default.nix
index 05d0b0a0beb18..04047180f305a 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/nightlight/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/nightlight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
 
   PKG_CONFIG_WINGPANEL_2_0_INDICATORSDIR = "${placeholder "out"}/lib/wingpanel";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Night Light Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-nightlight";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/notifications/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/notifications/default.nix
index 99ba52212a296..3028fa21da3d5 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/notifications/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/notifications/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     wingpanel
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Notifications Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-notifications";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/power/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/power/default.nix
index 3ad4ab4d662d2..e1156f693e470 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/power/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/power/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Power Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-power";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/session/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/session/default.nix
index 914db6cc8a94f..84b204a17f714 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/session/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/session/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     wingpanel
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Session Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-session";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/sound/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/sound/default.nix
index 02f7984eee98d..ab51071bd7540 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel-indicators/sound/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel-indicators/sound/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sound Indicator for Wingpanel";
     homepage = "https://github.com/elementary/wingpanel-indicator-sound";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel/default.nix b/pkgs/desktops/pantheon/desktop/wingpanel/default.nix
index 08eda9aa3685b..752b7daac20f2 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel/default.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -73,7 +73,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The extensible top panel for Pantheon";
     longDescription = ''
       Wingpanel is an empty container that accepts indicators as extensions,
diff --git a/pkgs/desktops/pantheon/granite/default.nix b/pkgs/desktops/pantheon/granite/default.nix
index 8b5ad8d5e6b54..8d06464ef1ce0 100644
--- a/pkgs/desktops/pantheon/granite/default.nix
+++ b/pkgs/desktops/pantheon/granite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , python3
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extension to GTK used by elementary OS";
     longDescription = ''
       Granite is a companion library for GTK and GLib. Among other things, it provides complex widgets and convenience functions
diff --git a/pkgs/desktops/pantheon/services/contractor/default.nix b/pkgs/desktops/pantheon/services/contractor/default.nix
index 76874878ff7d5..650c7a9fe878a 100644
--- a/pkgs/desktops/pantheon/services/contractor/default.nix
+++ b/pkgs/desktops/pantheon/services/contractor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
 
   PKG_CONFIG_DBUS_1_SESSION_BUS_SERVICES_DIR = "${placeholder "out"}/share/dbus-1/services";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A desktop-wide extension service used by elementary OS";
     homepage = "https://github.com/elementary/contractor";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/services/elementary-capnet-assist/default.nix b/pkgs/desktops/pantheon/services/elementary-capnet-assist/default.nix
index 2213bcb4e3771..97320ce0496b6 100644
--- a/pkgs/desktops/pantheon/services/elementary-capnet-assist/default.nix
+++ b/pkgs/desktops/pantheon/services/elementary-capnet-assist/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small WebKit app that assists a user with login when a captive portal is detected";
     homepage = "https://github.com/elementary/capnet-assist";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/pantheon/services/elementary-dpms-helper/default.nix b/pkgs/desktops/pantheon/services/elementary-dpms-helper/default.nix
index 3bb68475096f7..0251e857a1807 100644
--- a/pkgs/desktops/pantheon/services/elementary-dpms-helper/default.nix
+++ b/pkgs/desktops/pantheon/services/elementary-dpms-helper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     ${glib.dev}/bin/glib-compile-schemas $out/share/glib-2.0/schemas
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sets DPMS settings found in org.pantheon.dpms";
     homepage = "https://github.com/elementary/dpms-helper";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/pantheon/services/elementary-notifications/default.nix b/pkgs/desktops/pantheon/services/elementary-notifications/default.nix
index b90f8c86bf1aa..73cace23cca97 100644
--- a/pkgs/desktops/pantheon/services/elementary-notifications/default.nix
+++ b/pkgs/desktops/pantheon/services/elementary-notifications/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , meson
 , ninja
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson/post_install.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK notification server for Pantheon";
     homepage = "https://github.com/elementary/notifications";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/services/elementary-settings-daemon/default.nix b/pkgs/desktops/pantheon/services/elementary-settings-daemon/default.nix
index 724a07d25bfe0..268f6c4aaef07 100644
--- a/pkgs/desktops/pantheon/services/elementary-settings-daemon/default.nix
+++ b/pkgs/desktops/pantheon/services/elementary-settings-daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , substituteAll
 , fetchurl
 , fetchgit
@@ -143,7 +143,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl2Plus;
     maintainers = pantheon.maintainers;
     platforms = platforms.linux;
diff --git a/pkgs/desktops/pantheon/services/pantheon-agent-geoclue2/default.nix b/pkgs/desktops/pantheon/services/pantheon-agent-geoclue2/default.nix
index 11e0aaee3ad96..29b24981c4735 100644
--- a/pkgs/desktops/pantheon/services/pantheon-agent-geoclue2/default.nix
+++ b/pkgs/desktops/pantheon/services/pantheon-agent-geoclue2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     ${glib.dev}/bin/glib-compile-schemas $out/share/glib-2.0/schemas
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pantheon Geoclue2 Agent";
     homepage = "https://github.com/elementary/pantheon-agent-geoclue2";
     license = licenses.gpl3Plus;
diff --git a/pkgs/desktops/pantheon/services/pantheon-agent-polkit/default.nix b/pkgs/desktops/pantheon/services/pantheon-agent-polkit/default.nix
index ad8cf7e82e935..f3a496549381a 100644
--- a/pkgs/desktops/pantheon/services/pantheon-agent-polkit/default.nix
+++ b/pkgs/desktops/pantheon/services/pantheon-agent-polkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     polkit
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Polkit Agent for the Pantheon Desktop";
     homepage = "https://github.com/elementary/pantheon-agent-polkit";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/desktops/rox/rox-filer/default.nix b/pkgs/desktops/rox/rox-filer/default.nix
index cc7de2168e481..e8ffe0f9d92b6 100644
--- a/pkgs/desktops/rox/rox-filer/default.nix
+++ b/pkgs/desktops/rox/rox-filer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxml2, gtk, libSM, shared-mime-info }:
+{ lib, stdenv, fetchurl, pkgconfig, libxml2, gtk, libSM, shared-mime-info }:
 
 let
   version = "2.11";
@@ -69,7 +69,7 @@ in stdenv.mkDerivation {
     ln -sv application-{msword,rtf}.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, lightweight, gtk2 file manager";
     homepage = "http://rox.sourceforge.net/desktop";
     license = with licenses; [ gpl2 lgpl2 ];
diff --git a/pkgs/desktops/surf-display/default.nix b/pkgs/desktops/surf-display/default.nix
index dd06448664784..6746229a6bd2a 100644
--- a/pkgs/desktops/surf-display/default.nix
+++ b/pkgs/desktops/surf-display/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, makeWrapper
+{ lib, stdenv, fetchgit, makeWrapper
 , surf, wmctrl, matchbox, xdotool, unclutter
 , xorg, pulseaudio, xprintidle-ng }:
 
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     providedSessions = [ "surf-display" ];
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kiosk browser session manager based on the surf browser";
     homepage = "https://code.it-zukunft-schule.de/cgit/surf-display/";
     maintainers = with maintainers; [ etu ];
diff --git a/pkgs/desktops/xfce/applications/catfish/default.nix b/pkgs/desktops/xfce/applications/catfish/default.nix
index 7b9587b988b9e..6eff57f46ed42 100644
--- a/pkgs/desktops/xfce/applications/catfish/default.nix
+++ b/pkgs/desktops/xfce/applications/catfish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, file, which, intltool, gobject-introspection,
+{ lib, stdenv, fetchurl, file, which, intltool, gobject-introspection,
   findutils, xdg_utils, dconf, gtk3, python3Packages,
   wrapGAppsHook
 }:
@@ -50,7 +50,7 @@ python3Packages.buildPythonApplication rec {
   # Disable check because there is no test in the source distribution
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/apps/catfish/start";
     description = "Handy file search tool";
     longDescription = ''
diff --git a/pkgs/desktops/xfce/applications/orage/default.nix b/pkgs/desktops/xfce/applications/orage/default.nix
index 3af6c0a6bbabc..a18002928dc4a 100644
--- a/pkgs/desktops/xfce/applications/orage/default.nix
+++ b/pkgs/desktops/xfce/applications/orage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkg-config, intltool, dbus-glib, gtk2, libical, libnotify, tzdata
+{ lib, stdenv, fetchurl, fetchpatch, pkg-config, intltool, dbus-glib, gtk2, libical, libnotify, tzdata
 , popt, libxfce4ui, xfce4-panel, withPanelPlugin ? true, wrapGAppsHook, xfce }:
 
 assert withPanelPlugin -> libxfce4ui != null && xfce4-panel != null;
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister "apps" pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple calendar application with reminders";
     homepage = "https://git.xfce.org/archive/orage/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/art/xfce4-icon-theme.nix b/pkgs/desktops/xfce/art/xfce4-icon-theme.nix
index 526b703059177..ea4a4e0c7ee83 100644
--- a/pkgs/desktops/xfce/art/xfce4-icon-theme.nix
+++ b/pkgs/desktops/xfce/art/xfce4-icon-theme.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, gtk3, gnome-icon-theme, tango-icon-theme, hicolor-icon-theme, xfce }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, gtk3, gnome-icon-theme, tango-icon-theme, hicolor-icon-theme, xfce }:
 
 let
   category = "art";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.xfce.org/";
     description = "Icons for Xfce";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/art/xfwm4-themes.nix b/pkgs/desktops/xfce/art/xfwm4-themes.nix
index db0a1779a41b9..b93fa776ca4e2 100644
--- a/pkgs/desktops/xfce/art/xfwm4-themes.nix
+++ b/pkgs/desktops/xfce/art/xfwm4-themes.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xfce }:
+{ lib, stdenv, fetchurl, xfce }:
 
 let
   category = "art";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.xfce.org/";
     description = "Themes for Xfce";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/xfce/mkXfceDerivation.nix b/pkgs/desktops/xfce/mkXfceDerivation.nix
index 8709b84820c40..ddfc553057088 100644
--- a/pkgs/desktops/xfce/mkXfceDerivation.nix
+++ b/pkgs/desktops/xfce/mkXfceDerivation.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, pkgconfig, xfce4-dev-tools, hicolor-icon-theme, xfce, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitLab, pkgconfig, xfce4-dev-tools, hicolor-icon-theme, xfce, wrapGAppsHook }:
 
 { category
 , pname
@@ -46,7 +46,7 @@ let
       versionLister = xfce.gitLister src.meta.homepage;
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://gitlab.xfce.org/${category}/${pname}/about";
       license = licenses.gpl2; # some libraries are under LGPLv2+
       platforms = platforms.linux;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix
index 38ad759e700cc..e8945b3e55b29 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-cpugraph-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, glib, exo, libXtst, xorgproto, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk3, hicolor-icon-theme, xfce }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, glib, exo, libXtst, xorgproto, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk3, hicolor-icon-theme, xfce }:
 
 let
   category = "panel-plugins";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-cpugraph-plugin";
     description = "CPU graph show for Xfce panel";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix
index 15f528fd5fc79..aa14c878b12af 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-datetime-plugin/default.nix
@@ -1,5 +1,5 @@
 { mkXfceDerivation
-, stdenv
+, lib, stdenv
 , intltool
 , libxfce4ui
 , xfce4-panel
@@ -26,7 +26,7 @@ mkXfceDerivation {
     xfce4-panel
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shows the date and time in the panel, and a calendar appears when you left-click on it";
     maintainers = [ maintainers.AndersonTorres ];
   };
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix
index 673b0a24fb61f..6c75b44d77ac0 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-dockbarx-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, fetchFromGitHub, python2, bash, vala_0_46
+{ lib, stdenv, pkgconfig, fetchFromGitHub, python2, bash, vala_0_46
 , dockbarx, gtk2, xfce, pythonPackages, wafHook }:
 
 stdenv.mkDerivation rec {
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     wrapPythonProgramsIn "$out/share/xfce4/panel/plugins" "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/TiZ-EX1/xfce4-dockbarx-plugin";
     description = "A plugins to embed DockbarX into xfce4-panel";
     license = licenses.mit;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix
index d8f612d1a81b0..edd317918d88e 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-eyes-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk3, xfce }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk3, xfce }:
 
 let
   category = "panel-plugins";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-eyes-plugin";
     description = "Rolling eyes (following mouse pointer) plugin for the Xfce panel";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix
index b67e63f5c6449..31bb89198f652 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-fsguard-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk3, xfce }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk3, xfce }:
 
 let
   category = "panel-plugins";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-fsguard-plugin";
     description = "Filesystem usage monitor plugin for the Xfce panel";
     license = licenses.bsd2;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix
index 417001fed53be..4566a140dd36b 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-genmon-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk3, xfce }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk3, xfce }:
 
 let
   category = "panel-plugins";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-genmon-plugin";
     description = "Generic monitor plugin for the Xfce panel";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix
index d8775c4b7045a..bc8d9ff32768a 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-hardware-monitor-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, autoreconfHook, gnome2, gtkmm2,
+{ lib, stdenv, fetchurl, pkgconfig, intltool, autoreconfHook, gnome2, gtkmm2,
   libgtop, libxfce4ui, libxfce4util, xfce4-panel, lm_sensors, xfce
 }:
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://goodies.xfce.org/projects/panel-plugins/xfce4-hardware-monitor-plugin";
     description = "Hardware monitor plugin for the XFCE4 panel";
     license = licenses.gpl3;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix
index 3d60d8b18f9a4..b3d1f6e71591d 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-mailwatch-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui,
+{ lib, stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui,
   gtk2, exo, gnutls, libgcrypt, xfce }:
 
 let
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-mailwatch-plugin";
     description = "Mail watcher plugin for Xfce panel";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix
index bb56e875c865a..dddbf79522e71 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-mpc-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel,
+{ lib, stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel,
   libxfce4ui, gtk3, exo, xfce }:
 
 let
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-mpc-plugin";
     description = "MPD plugin for Xfce panel";
     platforms = platforms.linux;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-namebar-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-namebar-plugin.nix
index 5575bf585fced..92d39fc8fbbcb 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-namebar-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-namebar-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, fetchFromGitHub, python3, vala_0_46
+{ lib, stdenv, pkgconfig, fetchFromGitHub, python3, vala_0_46
 , gtk3, libwnck3, libxfce4util, xfce4-panel, wafHook, xfce }:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     rev-prefix = "v";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/HugLifeTiZ/xfce4-namebar-plugin";
     description = "Plugin which integrates titlebar and window controls into the xfce4-panel";
     license = licenses.mit;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix
index d6910d367a632..70586d1bc3456 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-notes-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, libunique, xfce }:
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, xfconf, gtk2, libunique, xfce }:
 
 let
   category = "panel-plugins";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-notes-plugin";
     description = "Sticky notes plugin for Xfce panel";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix
index 8b8dbf3e022cb..61237856d5d32 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-sensors-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, gtk3, libxfce4ui,
+{ lib, stdenv, fetchurl, pkgconfig, intltool, gtk3, libxfce4ui,
   libxfce4util, xfce4-panel, libnotify, lm_sensors, hddtemp, netcat-gnu, xfce
 }:
 
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-sensors-plugin";
     description = "A panel plug-in for different sensors using acpi, lm_sensors and hddtemp";
     license = licenses.gpl2;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix
index 52da6a29ea42f..c1a5dfecbba6b 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-systemload-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk3, xfce }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk3, xfce }:
 
 let
   category = "panel-plugins";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-systemload-plugin";
     description = "System load plugin for Xfce panel";
     license = licenses.bsd2;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix
index e9cfbd50f9120..27e9c098974cc 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-timer-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk3, hicolor-icon-theme, xfce }:
+{ lib, stdenv, fetchurl, pkgconfig, intltool, libxfce4util, xfce4-panel, libxfce4ui, gtk3, hicolor-icon-theme, xfce }:
 
 let
   category = "panel-plugins";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-timer-plugin";
     description = "Simple countdown and alarm plugin for the Xfce panel";
     platforms = platforms.linux;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/appmenu-gtk-module.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/appmenu-gtk-module.nix
index 39393dd39e9f5..e35dc5922d930 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/appmenu-gtk-module.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/appmenu-gtk-module.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, vala, glib, gtk2, gtk3 }:
+{ lib, stdenv, fetchFromGitHub, cmake, vala, glib, gtk2, gtk3 }:
 stdenv.mkDerivation rec {
   pname = "vala-panel-appmenu-xfce";
   version = "0.6.94";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp -r output/var/empty/* "$out"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Port of the Unity GTK Module";
     license = licenses.lgpl3;
     maintainers = with maintainers; [ jD91mZM2 ];
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix
index 525bd6e5fd7d6..ce90dd6809df3 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-vala-panel-appmenu-plugin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll, callPackage, pkgconfig, cmake, vala, libxml2,
+{ lib, stdenv, fetchFromGitHub, substituteAll, callPackage, pkgconfig, cmake, vala, libxml2,
   glib, pcre, gtk2, gtk3, xorg, libxkbcommon, epoxy, at-spi2-core, dbus-glib, bamf,
   xfce, libwnck3, libdbusmenu, gobject-introspection }:
 
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.gitLister src.meta.homepage;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Global Menu applet for XFCE4";
     license = licenses.lgpl3;
     maintainers = with maintainers; [ jD91mZM2 ];
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix
index cff2ef251ad4b..fae85cb64697a 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-weather-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, gtk3, libxml2, libsoup, upower,
+{ lib, stdenv, fetchurl, pkgconfig, intltool, gtk3, libxml2, libsoup, upower,
   libxfce4ui, libxfce4util, xfce4-panel, hicolor-icon-theme, xfce }:
 
 let
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.archiveLister category pname;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.xfce.org/panel-plugins/xfce4-weather-plugin";
     description = "Weather plugin for the Xfce desktop environment";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix b/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix
index e629a08c5537e..f5cf3899b0230 100644
--- a/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix
+++ b/pkgs/desktops/xfce/panel-plugins/xfce4-windowck-plugin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, intltool, python3, imagemagick, libwnck, gtk2
+{ lib, stdenv, fetchFromGitHub, pkgconfig, intltool, python3, imagemagick, libwnck, gtk2
 , exo, libxfce4ui, libxfce4util, xfce4-panel, xfconf, xfce4-dev-tools, xfce }:
 
 stdenv.mkDerivation rec {
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     rev-prefix = "v";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://goodies.xfce.org/projects/panel-plugins/xfce4-windowck-plugin";
     description = "Xfce plugins which allows to put the maximized window title and buttons on the panel";
     license = licenses.gpl2Plus;
diff --git a/pkgs/desktops/xfce/thunar-plugins/archive/default.nix b/pkgs/desktops/xfce/thunar-plugins/archive/default.nix
index 6b255dc720124..985b067a02fb2 100644
--- a/pkgs/desktops/xfce/thunar-plugins/archive/default.nix
+++ b/pkgs/desktops/xfce/thunar-plugins/archive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkXfceDerivation
 , gtk3
 , thunar
@@ -31,7 +31,7 @@ mkXfceDerivation {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Thunar plugin providing file context menus for archives";
   };
 }
diff --git a/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix b/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix
index 83891fe48dd6b..85a8b95dc0023 100644
--- a/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix
+++ b/pkgs/desktops/xfce/thunar-plugins/dropbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , gtk3
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     versionLister = xfce.gitLister src.meta.homepage;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Jeinzi/thunar-dropbox";
     description = "A plugin that adds context-menu items for Dropbox to Thunar";
     license = licenses.gpl3;
diff --git a/pkgs/development/arduino/arduino-ci/default.nix b/pkgs/development/arduino/arduino-ci/default.nix
index b6b1fc9c89d14..2f5d4bedc7fee 100644
--- a/pkgs/development/arduino/arduino-ci/default.nix
+++ b/pkgs/development/arduino/arduino-ci/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub,  makeWrapper, arduino-cli, ruby, python3 }:
+{ lib, stdenv, fetchFromGitHub,  makeWrapper, arduino-cli, ruby, python3 }:
 
 let
 
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/arduino-ci --prefix PATH ":" "${runtimePath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CI for Arduino Libraries";
     homepage = src.meta.homepage;
     license = licenses.mit;
diff --git a/pkgs/development/arduino/arduino-cli/default.nix b/pkgs/development/arduino/arduino-cli/default.nix
index 1b1116a74b5df..f3cc83417776a 100644
--- a/pkgs/development/arduino/arduino-cli/default.nix
+++ b/pkgs/development/arduino/arduino-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, buildFHSUserEnv }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, buildFHSUserEnv }:
 
 let
 
@@ -23,7 +23,7 @@ let
       "-ldflags=-s -w -X github.com/arduino/arduino-cli/version.versionString=${version} -X github.com/arduino/arduino-cli/version.commit=unknown"
     ] ++ stdenv.lib.optionals stdenv.isLinux [ "-extldflags '-static'" ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       inherit (src.meta) homepage;
       description = "Arduino from the command line";
       license = licenses.gpl3Only;
diff --git a/pkgs/development/arduino/arduino-core/default.nix b/pkgs/development/arduino/arduino-core/default.nix
index 456a8d8b81c52..081c7c7c6385e 100644
--- a/pkgs/development/arduino/arduino-core/default.nix
+++ b/pkgs/development/arduino/arduino-core/default.nix
@@ -244,7 +244,7 @@ stdenv.mkDerivation rec {
     ''}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open-source electronics prototyping platform";
     homepage = "http://arduino.cc/";
     license = if withTeensyduino then licenses.unfreeRedistributable else licenses.gpl2;
diff --git a/pkgs/development/arduino/platformio/core.nix b/pkgs/development/arduino/platformio/core.nix
index a039314d753df..733e7e0b1462f 100644
--- a/pkgs/development/arduino/platformio/core.nix
+++ b/pkgs/development/arduino/platformio/core.nix
@@ -107,7 +107,7 @@ in buildPythonApplication rec {
       --subst-var-by SPDX_LICENSE_LIST_DATA '${spdx-license-list-data}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = stdenv.isAarch64;
     description = "An open source ecosystem for IoT development";
     homepage = "http://platformio.org";
diff --git a/pkgs/development/dotnet-modules/python-language-server/default.nix b/pkgs/development/dotnet-modules/python-language-server/default.nix
index 286037b2cce2a..526e93f84c42c 100644
--- a/pkgs/development/dotnet-modules/python-language-server/default.nix
+++ b/pkgs/development/dotnet-modules/python-language-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchurl
 , makeWrapper
@@ -94,7 +94,7 @@ stdenv.mkDerivation {
   # to find some of the packaged DLLs.
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Microsoft Language Server for Python";
     homepage = "https://github.com/microsoft/python-language-server";
     license = licenses.asl20;
diff --git a/pkgs/development/guile-modules/guile-cairo/default.nix b/pkgs/development/guile-modules/guile-cairo/default.nix
index 8864e014c6dee..31867d16b4cff 100644
--- a/pkgs/development/guile-modules/guile-cairo/default.nix
+++ b/pkgs/development/guile-modules/guile-cairo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, guile, guile-lib, cairo, expat }:
+{ lib, stdenv, fetchurl, pkgconfig, guile, guile-lib, cairo, expat }:
 
 stdenv.mkDerivation rec {
   pname = "guile-cairo";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   doCheck = false; # Cannot find unit-test module from guile-lib
   checkInputs = [ guile-lib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cairo bindings for GNU Guile";
     longDescription = ''
       Guile-Cairo wraps the Cairo graphics library for Guile Scheme.
diff --git a/pkgs/development/guile-modules/guile-fibers/default.nix b/pkgs/development/guile-modules/guile-fibers/default.nix
index 88ba443b6b8ac..db16c91c4ef60 100644
--- a/pkgs/development/guile-modules/guile-fibers/default.nix
+++ b/pkgs/development/guile-modules/guile-fibers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, guile, texinfo }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, guile, texinfo }:
 
 let
   version = "1.0.0";
@@ -18,7 +18,7 @@ in stdenv.mkDerivation {
 
   autoreconfPhase = "./autogen.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Concurrent ML-like concurrency for Guile";
     homepage = "https://github.com/wingo/fibers";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/guile-modules/guile-gnome/default.nix b/pkgs/development/guile-modules/guile-gnome/default.nix
index 17f03f67cef5f..a02da829c7f60 100644
--- a/pkgs/development/guile-modules/guile-gnome/default.nix
+++ b/pkgs/development/guile-modules/guile-gnome/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, guile, guile-lib, gwrap
+{ fetchurl, lib, stdenv, guile, guile-lib, gwrap
 , pkgconfig, gconf, glib, gnome_vfs, gtk2
 , libglade, libgnome, libgnomecanvas, libgnomeui
 , pango, guile-cairo, texinfo
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   GUILE_AUTO_COMPILE = 0;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME bindings for GNU Guile";
     longDescription = ''
       GNU guile-gnome brings the power of Scheme to your graphical application.
diff --git a/pkgs/development/guile-modules/guile-lib/default.nix b/pkgs/development/guile-modules/guile-lib/default.nix
index 97f501f41db75..6b860bd28da56 100644
--- a/pkgs/development/guile-modules/guile-lib/default.nix
+++ b/pkgs/development/guile-modules/guile-lib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, guile, texinfo, pkgconfig }:
+{ lib, stdenv, fetchurl, guile, texinfo, pkgconfig }:
 
 assert stdenv ? cc && stdenv.cc.isGNU;
 
@@ -24,7 +24,7 @@ in stdenv.mkDerivation {
     "$(dirname $(echo ${stdenv.cc.cc.lib}/lib*/libgcc_s.so))''${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of useful Guile Scheme modules";
     longDescription = ''
       guile-lib is intended as an accumulation place for pure-scheme Guile
diff --git a/pkgs/development/guile-modules/guile-ncurses/default.nix b/pkgs/development/guile-modules/guile-ncurses/default.nix
index 8f60185826701..eb10c0f1e5913 100644
--- a/pkgs/development/guile-modules/guile-ncurses/default.nix
+++ b/pkgs/development/guile-modules/guile-ncurses/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, guile, ncurses, libffi }:
+{ lib, stdenv, fetchurl, pkgconfig, guile, ncurses, libffi }:
 
 let
   name = "guile-ncurses-${version}";
@@ -28,7 +28,7 @@ in stdenv.mkDerivation {
   # XXX: 1 of 65 tests failed.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scheme interface to the NCurses libraries";
     longDescription = ''
       GNU Guile-Ncurses is a library for the Guile Scheme interpreter that
diff --git a/pkgs/development/guile-modules/guile-opengl/default.nix b/pkgs/development/guile-modules/guile-opengl/default.nix
index e1e04ecfe6993..f05804776533a 100644
--- a/pkgs/development/guile-modules/guile-opengl/default.nix
+++ b/pkgs/development/guile-modules/guile-opengl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, guile }:
+{ lib, stdenv, fetchurl, pkgconfig, guile }:
 
 let
   name = "guile-opengl-${version}";
@@ -13,7 +13,7 @@ in stdenv.mkDerivation {
 
   nativeBuildInputs = [ pkgconfig guile ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Guile bindings for the OpenGL graphics API";
     homepage = "https://www.gnu.org/software/guile-opengl/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/guile-modules/guile-reader/default.nix b/pkgs/development/guile-modules/guile-reader/default.nix
index 392babc096a4c..47ef15ef4e206 100644
--- a/pkgs/development/guile-modules/guile-reader/default.nix
+++ b/pkgs/development/guile-modules/guile-reader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig
 , gperf, guile, guile-lib, libffi }:
 
 with stdenv.lib;
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--with-guilemoduledir=$(out)/share/guile/site" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple framework for building readers for GNU Guile";
     longDescription = ''
        Guile-Reader is a simple framework for building readers for GNU
diff --git a/pkgs/development/guile-modules/guile-sdl/default.nix b/pkgs/development/guile-modules/guile-sdl/default.nix
index eff4c699625a5..a676f65215d21 100644
--- a/pkgs/development/guile-modules/guile-sdl/default.nix
+++ b/pkgs/development/guile-modules/guile-sdl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, guile, buildEnv
+{ lib, stdenv, fetchurl, pkgconfig, guile, buildEnv
 , SDL, SDL_image, SDL_ttf, SDL_mixer
 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     };
   in [ "SDLMINUSI=-I${sdl}/include/SDL" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Guile bindings for SDL";
     homepage = "https://www.gnu.org/software/guile-sdl/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/guile-modules/guile-sdl2/default.nix b/pkgs/development/guile-modules/guile-sdl2/default.nix
index 061d3c4a1dba7..fe1567272ceac 100644
--- a/pkgs/development/guile-modules/guile-sdl2/default.nix
+++ b/pkgs/development/guile-modules/guile-sdl2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, guile, libtool, pkgconfig
+{ lib, stdenv, fetchurl, guile, libtool, pkgconfig
 , SDL2, SDL2_image, SDL2_ttf, SDL2_mixer
 }:
 
@@ -28,7 +28,7 @@ in stdenv.mkDerivation {
 
   makeFlags = [ "GUILE_AUTO_COMPILE=0" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bindings to SDL2 for GNU Guile";
     homepage = "https://dthompson.us/projects/guile-sdl2.html";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/guile-modules/guile-xcb/default.nix b/pkgs/development/guile-modules/guile-xcb/default.nix
index b08d8313930bc..d0cc719b62573 100644
--- a/pkgs/development/guile-modules/guile-xcb/default.nix
+++ b/pkgs/development/guile-modules/guile-xcb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, guile, texinfo }:
+{ lib, stdenv, fetchurl, pkgconfig, guile, texinfo }:
 
 let
   name = "guile-xcb-${version}";
@@ -21,7 +21,7 @@ in stdenv.mkDerivation {
     ";
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XCB bindings for Guile";
     homepage = "http://www.markwitmer.com/guile-xcb/guile-xcb.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/java-modules/jogl/default.nix b/pkgs/development/java-modules/jogl/default.nix
index d4e5f1b62bf7c..5f20adada23ef 100644
--- a/pkgs/development/java-modules/jogl/default.nix
+++ b/pkgs/development/java-modules/jogl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, ant, jdk8, git, xorg, udev, libGL, libGLU }:
+{ lib, stdenv, fetchgit, ant, jdk8, git, xorg, udev, libGL, libGLU }:
 
 {
   jogl_2_3_2 =
@@ -55,7 +55,7 @@
         cp $NIX_BUILD_TOP/jogl/build/jar/jogl-all{,-natives-linux-amd64}.jar  $out/share/java/
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "Java libraries for 3D Graphics, Multimedia and Processing";
         homepage = "https://jogamp.org/";
         license = licenses.bsd3;
diff --git a/pkgs/development/java-modules/postgresql_jdbc/default.nix b/pkgs/development/java-modules/postgresql_jdbc/default.nix
index 01041d7753981..e7968cf80c0a1 100644
--- a/pkgs/development/java-modules/postgresql_jdbc/default.nix
+++ b/pkgs/development/java-modules/postgresql_jdbc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchMavenArtifact }:
+{ lib, stdenv, fetchMavenArtifact }:
 
 stdenv.mkDerivation rec {
   pname = "postgresql-jdbc";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -m444 -D $src/share/java/*postgresql-${version}.jar $out/share/java/postgresql-jdbc.jar
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://jdbc.postgresql.org/";
     description = "JDBC driver for PostgreSQL allowing Java programs to connect to a PostgreSQL database";
     license = licenses.bsd2;
diff --git a/pkgs/development/lua-modules/generated-packages.nix b/pkgs/development/lua-modules/generated-packages.nix
index 500766585632b..fddb028b80ae8 100644
--- a/pkgs/development/lua-modules/generated-packages.nix
+++ b/pkgs/development/lua-modules/generated-packages.nix
@@ -5,7 +5,7 @@ nixpkgs$ maintainers/scripts/update-luarocks-packages pkgs/development/lua-modul
 
 These packages are manually refined in lua-overrides.nix
 */
-{ self, stdenv, fetchurl, fetchgit, pkgs, ... } @ args:
+{ self, lib, stdenv, fetchurl, fetchgit, pkgs, ... } @ args:
 self: super:
 with self;
 {
@@ -21,7 +21,7 @@ alt-getopt = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cheusov/lua-alt-getopt";
     description = "Process application arguments the same way as getopt_long";
     maintainers = with maintainers; [ arobyn ];
@@ -39,7 +39,7 @@ ansicolors = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kikito/ansicolors.lua";
     description = "Library for color Manipulation.";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -56,7 +56,7 @@ argparse = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/luarocks/argparse";
     description = "A feature-rich command-line argument parser";
     license.fullName = "MIT";
@@ -79,7 +79,7 @@ basexx = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/aiq/basexx";
     description = "A base2, base16, base32, base64 and base85 library for Lua";
     license.fullName = "MIT";
@@ -96,7 +96,7 @@ binaryheap = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Tieske/binaryheap.lua";
     description = "Binary heap implementation in pure Lua";
     maintainers = with maintainers; [ vcunat ];
@@ -114,7 +114,7 @@ bit32 = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.lua.org/manual/5.2/manual.html#6.7";
     description = "Lua 5.2 bit manipulation library";
     maintainers = with maintainers; [ lblasc ];
@@ -138,7 +138,7 @@ busted = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua lua_cliargs luafilesystem luasystem dkjson say luassert lua-term penlight mediator_lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://olivinelabs.com/busted/";
     description = "Elegant Lua unit testing.";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -154,7 +154,7 @@ cassowary = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ lua penlight ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sile-typesetter/cassowary.lua";
     description = "The cassowary constraint solver";
     maintainers = with maintainers; [ marsam alerque ];
@@ -172,7 +172,7 @@ cjson = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.kyne.com.au/~mark/software/lua-cjson.php";
     description = "A fast JSON encoding/parsing module";
     license.fullName = "MIT";
@@ -189,7 +189,7 @@ compat53 = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/keplerproject/lua-compat-5.3";
     description = "Compatibility module providing Lua-5.3-style APIs for Lua 5.2 and 5.1";
     maintainers = with maintainers; [ vcunat ];
@@ -206,7 +206,7 @@ cosmo = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ lpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cosmo.luaforge.net";
     description = "Safe templates for Lua";
     maintainers = with maintainers; [ marsam ];
@@ -222,7 +222,7 @@ coxpcall = buildLuarocksPackage {
     sha256 = "0n1jmda4g7x06458596bamhzhcsly6x0p31yp6q3jz4j11zv1zhi";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://keplerproject.github.io/coxpcall";
     description = "Coroutine safe xpcall and pcall";
     license.fullName = "MIT/X11";
@@ -239,7 +239,7 @@ cqueues = buildLuarocksPackage {
   disabled = (lua.luaversion != "5.2");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://25thandclement.com/~william/projects/cqueues.html";
     description = "Continuation Queues: Embeddable asynchronous networking, threading, and notification framework for Lua on Unix.";
     maintainers = with maintainers; [ vcunat ];
@@ -267,7 +267,7 @@ cyrussasl = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/JorjBauer/lua-cyrussasl";
     description = "Cyrus SASL library for Lua 5.1+";
     maintainers = with maintainers; [ vcunat ];
@@ -285,7 +285,7 @@ digestif = buildLuarocksPackage {
   disabled = (luaOlder "5.3");
   propagatedBuildInputs = [ lua lpeg dkjson ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/astoff/digestif/";
     description = "A code analyzer for TeX";
     license.fullName = "MIT";
@@ -302,7 +302,7 @@ dkjson = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://dkolf.de/src/dkjson-lua.fsl/";
     description = "David Kolf's JSON module for Lua";
     license.fullName = "MIT/X11";
@@ -318,7 +318,7 @@ fifo = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/daurnimator/fifo.lua";
     description = "A lua library/'class' that implements a FIFO";
     license.fullName = "MIT/X11";
@@ -335,7 +335,7 @@ http = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua compat53 bit32 cqueues luaossl basexx lpeg lpeg_patterns binaryheap fifo ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/daurnimator/lua-http";
     description = "HTTP library for Lua";
     maintainers = with maintainers; [ vcunat ];
@@ -353,7 +353,7 @@ inspect = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kikito/inspect.lua";
     description = "Lua table visualizer, ideal for debugging";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -380,7 +380,7 @@ ldbus = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/daurnimator/ldbus";
     description = "A Lua library to access dbus.";
     license.fullName = "MIT/X11";
@@ -402,7 +402,7 @@ ldoc = buildLuarocksPackage {
 
   propagatedBuildInputs = [ penlight markdown ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://stevedonovan.github.com/ldoc";
     description = "A Lua Documentation Tool";
     license.fullName = "MIT/X11";
@@ -419,7 +419,7 @@ lgi = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pavouk/lgi";
     description = "Lua bindings to GObject libraries";
     license.fullName = "MIT/X11";
@@ -442,7 +442,7 @@ linenoise = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hoelzro/lua-linenoise";
     description = "A binding for the linenoise command line library";
     license.fullName = "MIT/X11";
@@ -459,7 +459,7 @@ ljsyscall = buildLuarocksPackage {
   disabled = (lua.luaversion != "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.myriabit.com/ljsyscall/";
     description = "LuaJIT Linux syscall FFI";
     maintainers = with maintainers; [ lblasc ];
@@ -477,7 +477,7 @@ lpeg = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.inf.puc-rio.br/~roberto/lpeg.html";
     description = "Parsing Expression Grammars For Lua";
     maintainers = with maintainers; [ vyp ];
@@ -494,7 +494,7 @@ lpeg_patterns = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ lua lpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/daurnimator/lpeg_patterns/archive/v0.5.zip";
     description = "a collection of LPEG patterns";
     license.fullName = "MIT";
@@ -511,7 +511,7 @@ lpeglabel = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sqmedeiros/lpeglabel/";
     description = "Parsing Expression Grammars For Lua with Labeled Failures";
     license.fullName = "MIT/X11";
@@ -528,7 +528,7 @@ lpty = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.tset.de/lpty/";
     description = "A simple facility for lua to control other programs via PTYs.";
     license.fullName = "MIT";
@@ -545,7 +545,7 @@ lrexlib-gnu = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rrthomas/lrexlib";
     description = "Regular expression library binding (GNU flavour).";
     license.fullName = "MIT/X11";
@@ -562,7 +562,7 @@ lrexlib-pcre = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rrthomas/lrexlib";
     description = "Regular expression library binding (PCRE flavour).";
     maintainers = with maintainers; [ vyp ];
@@ -580,7 +580,7 @@ lrexlib-posix = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rrthomas/lrexlib";
     description = "Regular expression library binding (POSIX flavour).";
     license.fullName = "MIT/X11";
@@ -597,7 +597,7 @@ ltermbox = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://code.google.com/p/termbox";
     description = "A termbox library package";
     license.fullName = "New BSD License";
@@ -624,7 +624,7 @@ lua-cmsgpack = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/antirez/lua-cmsgpack";
     description = "MessagePack C implementation and bindings for Lua 5.1/5.2/5.3";
     license.fullName = "Two-clause BSD";
@@ -641,7 +641,7 @@ lua-iconv = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ittner.github.com/lua-iconv/";
     description = "Lua binding to the iconv";
     license.fullName = "MIT/X11";
@@ -668,7 +668,7 @@ lua-lsp = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua dkjson lpeglabel inspect ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Alloyed/lua-lsp";
     description = "No summary";
     license.fullName = "MIT";
@@ -685,7 +685,7 @@ lua-messagepack = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fperrad.frama.io/lua-MessagePack/";
     description = "a pure Lua implementation of the MessagePack serialization format";
     license.fullName = "MIT/X11";
@@ -702,7 +702,7 @@ lua-resty-http = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ledgetech/lua-resty-http";
     description = "Lua HTTP client cosocket driver for OpenResty / ngx_lua.";
     license.fullName = "2-clause BSD";
@@ -719,7 +719,7 @@ lua-resty-jwt = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cdbattags/lua-resty-jwt";
     description = "JWT for ngx_lua and LuaJIT.";
     license.fullName = "Apache License Version 2";
@@ -736,7 +736,7 @@ lua-resty-openidc = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua lua-resty-http lua-resty-session lua-resty-jwt ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zmartzone/lua-resty-openidc";
     description = "A library for NGINX implementing the OpenID Connect Relying Party (RP) and the OAuth 2.0 Resource Server (RS) functionality";
     license.fullName = "Apache 2.0";
@@ -753,7 +753,7 @@ lua-resty-session = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bungle/lua-resty-session";
     description = "Session Library for OpenResty – Flexible and Secure";
     license.fullName = "BSD";
@@ -774,7 +774,7 @@ lua-term = buildLuarocksPackage {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hoelzro/lua-term";
     description = "Terminal functions for Lua";
     license.fullName = "MIT/X11";
@@ -791,7 +791,7 @@ lua-toml = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jonstoler/lua-toml";
     description = "toml decoder/encoder for Lua";
     license.fullName = "MIT";
@@ -808,7 +808,7 @@ lua-zlib = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brimworks/lua-zlib";
     description = "Simple streaming interface to zlib for Lua.";
     maintainers = with maintainers; [ koral ];
@@ -826,7 +826,7 @@ lua_cliargs = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/amireh/lua_cliargs";
     description = "A command-line argument parser.";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -853,7 +853,7 @@ luabitop = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.3");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://bitop.luajit.org/";
     description = "Lua Bit Operations Module";
     license.fullName = "MIT/X license";
@@ -870,7 +870,7 @@ luacheck = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua argparse luafilesystem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mpeterv/luacheck";
     description = "A static analyzer and a linter for Lua";
     license.fullName = "MIT";
@@ -887,7 +887,7 @@ luacov = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://keplerproject.github.io/luacov/";
     description = "Coverage analysis tool for Lua scripts";
     license.fullName = "MIT";
@@ -904,7 +904,7 @@ luadbi = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mwild1/luadbi";
     description = "Database abstraction layer";
     license.fullName = "MIT/X11";
@@ -921,7 +921,7 @@ luadbi-mysql = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua luadbi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mwild1/luadbi";
     description = "Database abstraction layer";
     license.fullName = "MIT/X11";
@@ -938,7 +938,7 @@ luadbi-postgresql = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua luadbi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mwild1/luadbi";
     description = "Database abstraction layer";
     license.fullName = "MIT/X11";
@@ -955,7 +955,7 @@ luadbi-sqlite3 = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua luadbi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mwild1/luadbi";
     description = "Database abstraction layer";
     license.fullName = "MIT/X11";
@@ -971,7 +971,7 @@ luadoc = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ lualogging luafilesystem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://luadoc.luaforge.net/";
     description = "LuaDoc is a documentation tool for Lua source code";
     license.fullName = "MIT/X11";
@@ -988,7 +988,7 @@ luaepnf = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua lpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://siffiejoe.github.io/lua-luaepnf/";
     description = "Extended PEG Notation Format (easy grammars for LPeg)";
     license.fullName = "MIT";
@@ -1005,7 +1005,7 @@ luaevent = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/harningt/luaevent";
     description = "libevent binding for Lua";
     license.fullName = "MIT";
@@ -1022,7 +1022,7 @@ luaexpat = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.keplerproject.org/luaexpat/";
     description = "XML Expat parsing";
     maintainers = with maintainers; [ arobyn flosse ];
@@ -1040,7 +1040,7 @@ luaffi = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/facebook/luaffifb";
     description = "FFI library for calling C functions from lua";
     license.fullName = "BSD";
@@ -1057,7 +1057,7 @@ luafilesystem = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "git://github.com/keplerproject/luafilesystem";
     description = "File System Library for the Lua Programming Language";
     maintainers = with maintainers; [ flosse vcunat ];
@@ -1074,7 +1074,7 @@ lualogging = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ luasocket ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Neopallium/lualogging";
     description = "A simple API to use logging features";
     license.fullName = "MIT/X11";
@@ -1090,7 +1090,7 @@ luaossl = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://25thandclement.com/~william/projects/luaossl.html";
     description = "Most comprehensive OpenSSL module in the Lua universe.";
     maintainers = with maintainers; [ vcunat ];
@@ -1108,7 +1108,7 @@ luaposix = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ bit32 lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/luaposix/luaposix/";
     description = "Lua bindings for POSIX";
     maintainers = with maintainers; [ vyp lblasc ];
@@ -1132,7 +1132,7 @@ luarepl = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hoelzro/lua-repl";
     description = "A reusable REPL component for Lua, written in Lua";
     license.fullName = "MIT/X11";
@@ -1149,7 +1149,7 @@ luasec = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua luasocket ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brunoos/luasec/wiki";
     description = "A binding for OpenSSL library to provide TLS/SSL communication over LuaSocket.";
     maintainers = with maintainers; [ flosse ];
@@ -1167,7 +1167,7 @@ luasocket = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://luaforge.net/projects/luasocket/";
     description = "Network support for the Lua language";
     license.fullName = "MIT";
@@ -1194,7 +1194,7 @@ luasql-sqlite3 = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.keplerproject.org/luasql/";
     description = "Database connectivity for Lua (SQLite3 driver)";
     maintainers = with maintainers; [ vyp ];
@@ -1218,7 +1218,7 @@ luassert = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua say ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://olivinelabs.com/busted/";
     description = "Lua Assertions Extension";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -1235,7 +1235,7 @@ luasystem = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://olivinelabs.com/luasystem/";
     description = "Platform independent system calls for Lua.";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -1252,7 +1252,7 @@ luautf8 = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/starwing/luautf8";
     description = "A UTF-8 support module for Lua";
     maintainers = with maintainers; [ pstn ];
@@ -1270,7 +1270,7 @@ luazip = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mpeterv/luazip";
     description = "Library for reading files inside zip files";
     license.fullName = "MIT";
@@ -1287,7 +1287,7 @@ lua-yajl = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brimworks/lua-yajl";
     description = "Integrate the yajl JSON library with Lua.";
     maintainers = with maintainers; [ pstn ];
@@ -1305,7 +1305,7 @@ luuid = buildLuarocksPackage {
   disabled = (luaOlder "5.2") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.tecgraf.puc-rio.br/~lhf/ftp/lua/#luuid";
     description = "A library for UUID generation";
     license.fullName = "Public domain";
@@ -1322,7 +1322,7 @@ luv = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/luvit/luv";
     description = "Bare libuv bindings for lua";
     license.fullName = "Apache 2.0";
@@ -1339,7 +1339,7 @@ lyaml = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.5");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gvvaughan/lyaml";
     description = "libYAML binding for Lua";
     maintainers = with maintainers; [ lblasc ];
@@ -1357,7 +1357,7 @@ markdown = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mpeterv/markdown";
     description = "Markdown text-to-html markup system.";
     license.fullName = "MIT/X11";
@@ -1380,7 +1380,7 @@ mediator_lua = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://olivinelabs.com/mediator_lua/";
     description = "Event handling through channels";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -1401,7 +1401,7 @@ mpack = buildLuarocksPackage {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/libmpack/libmpack-lua/releases/download/1.0.8/libmpack-lua-1.0.8.tar.gz";
     description = "Lua binding to libmpack";
     license.fullName = "MIT";
@@ -1418,7 +1418,7 @@ moonscript = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua lpeg alt-getopt luafilesystem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://moonscript.org";
     description = "A programmer friendly language that compiles to Lua";
     maintainers = with maintainers; [ arobyn ];
@@ -1436,7 +1436,7 @@ nvim-client = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua mpack luv coxpcall ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/neovim/lua-client";
     description = "Lua client to Nvim";
     license.fullName = "Apache";
@@ -1452,7 +1452,7 @@ penlight = buildLuarocksPackage {
   };
   propagatedBuildInputs = [ luafilesystem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://tieske.github.io/Penlight";
     description = "Lua utility libraries loosely based on the Python standard libraries";
     maintainers = with maintainers; [ alerque ];
@@ -1470,7 +1470,7 @@ rapidjson = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/xpol/lua-rapidjson";
     description = "Json module based on the very fast RapidJSON.";
     license.fullName = "MIT";
@@ -1487,7 +1487,7 @@ readline = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.4");
   propagatedBuildInputs = [ lua luaposix ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.pjb.com.au/comp/lua/readline.html";
     description = "Interface to the readline library";
     license.fullName = "MIT/X11";
@@ -1510,7 +1510,7 @@ say = buildLuarocksPackage {
   disabled = (luaOlder "5.1");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://olivinelabs.com/busted/";
     description = "Lua String Hashing/Indexing Library";
     license.fullName = "MIT <http://opensource.org/licenses/MIT>";
@@ -1527,7 +1527,7 @@ std__debug = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.5");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://lua-stdlib.github.io/_debug";
     description = "Debug Hints Library";
     license.fullName = "MIT/X11";
@@ -1544,7 +1544,7 @@ std_normalize = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.5");
   propagatedBuildInputs = [ lua std__debug ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://lua-stdlib.github.io/normalize";
     description = "Normalized Lua Functions";
     license.fullName = "MIT/X11";
@@ -1561,7 +1561,7 @@ stdlib = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.5");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://lua-stdlib.github.io/lua-stdlib";
     description = "General Lua Libraries";
     maintainers = with maintainers; [ vyp ];
@@ -1579,7 +1579,7 @@ vstruct = buildLuarocksPackage {
   disabled = (luaOlder "5.1") || (luaAtLeast "5.3");
   propagatedBuildInputs = [ lua ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ToxicFrog/vstruct";
     description = "Lua library to manipulate binary data";
   };
diff --git a/pkgs/development/misc/avr/libc/default.nix b/pkgs/development/misc/avr/libc/default.nix
index 6682f72c62de6..83054b46a94c8 100644
--- a/pkgs/development/misc/avr/libc/default.nix
+++ b/pkgs/development/misc/avr/libc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, automake, autoconf }:
+{ lib, stdenv, fetchurl, automake, autoconf }:
 
 let
   version = "2.0.0";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     incdir = "/avr/include";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a C runtime library for AVR microcontrollers";
     homepage = "https://savannah.nongnu.org/projects/avr-libc/";
     license = licenses.bsd3;
diff --git a/pkgs/development/misc/avr8-burn-omat/default.nix b/pkgs/development/misc/avr8-burn-omat/default.nix
index 1a92f8fdd9da0..1f504ac280e88 100644
--- a/pkgs/development/misc/avr8-burn-omat/default.nix
+++ b/pkgs/development/misc/avr8-burn-omat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, runtimeShell }:
+{ lib, stdenv, fetchurl, unzip, runtimeShell }:
 
 stdenv.mkDerivation {
   name = "avr8-burn-omat-2.1.2";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/avr8-burn-omat
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI tool for avrdude";
     homepage = "http://avr8-burn-o-mat.aaabbb.de/avr8_burn_o_mat_avrdude_gui_en.html";
     license = stdenv.lib.licenses.gpl3;
diff --git a/pkgs/development/misc/h3/default.nix b/pkgs/development/misc/h3/default.nix
index 8b8515261a1c7..1d12e0f2b01f6 100644
--- a/pkgs/development/misc/h3/default.nix
+++ b/pkgs/development/misc/h3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , cmake
 , fetchFromGitHub
 }:
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "-DENABLE_LINTING=OFF"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/uber/h3";
     description = "Hexagonal hierarchical geospatial indexing system";
     license = licenses.asl20;
diff --git a/pkgs/development/misc/loc/default.nix b/pkgs/development/misc/loc/default.nix
index d8b65a7c1473c..33de722baa242 100644
--- a/pkgs/development/misc/loc/default.nix
+++ b/pkgs/development/misc/loc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 with rustPlatform;
 
@@ -15,7 +15,7 @@ buildRustPackage rec {
 
   cargoSha256 = "1fgv1kxiif48q9mm60ygn88r5nkxfyiacmvbgwp0jxiacv8r7779";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cgag/loc";
     description = "Count lines of code quickly";
     license = stdenv.lib.licenses.mit;
diff --git a/pkgs/development/misc/msp430/mspdebug.nix b/pkgs/development/misc/msp430/mspdebug.nix
index 471dd5b312292..f8616ff0bc4f1 100644
--- a/pkgs/development/misc/msp430/mspdebug.nix
+++ b/pkgs/development/misc/msp430/mspdebug.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoPatchelfHook
 , libusb-compat-0_1
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     stdenv.lib.optional (!enableReadline) "WITHOUT_READLINE=1";
   unameS = stdenv.lib.optionalString stdenv.isDarwin "Darwin";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free programmer, debugger, and gdb proxy for MSP430 MCUs";
     homepage = "https://dlbeer.co.nz/mspdebug/";
     license = licenses.gpl2;
diff --git a/pkgs/development/misc/rappel/default.nix b/pkgs/development/misc/rappel/default.nix
index 761d2ea98ba02..67e202a005fc9 100644
--- a/pkgs/development/misc/rappel/default.nix
+++ b/pkgs/development/misc/rappel/default.nix
@@ -2,7 +2,7 @@
 , libedit
 , makeWrapper
 , nasm
-, stdenv
+, lib, stdenv
 }:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/yrp604/rappel";
     description = "A pretty janky assembly REPL";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/misc/resholve/resholve.nix b/pkgs/development/misc/resholve/resholve.nix
index 2d1880f704cfd..06561e05dd900 100644
--- a/pkgs/development/misc/resholve/resholve.nix
+++ b/pkgs/development/misc/resholve/resholve.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , callPackage
 , python27Packages
 , installShellFiles
@@ -64,7 +64,7 @@ python27Packages.buildPythonApplication {
     ./test.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Resolve external shell-script dependencies";
     homepage = "https://github.com/abathur/resholve";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/misc/rpiboot/unstable.nix b/pkgs/development/misc/rpiboot/unstable.nix
index f12f5a845f171..d0cb663fb74ba 100644
--- a/pkgs/development/misc/rpiboot/unstable.nix
+++ b/pkgs/development/misc/rpiboot/unstable.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libusb1 }:
+{ lib, stdenv, fetchFromGitHub, libusb1 }:
 
 stdenv.mkDerivation {
   pname = "rpiboot";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     cp -r msd $out/share/rpiboot
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/raspberrypi/usbboot";
     description = "Utility to boot a Raspberry Pi CM/CM3/Zero over USB";
     license = licenses.asl20;
diff --git a/pkgs/development/misc/stm32/betaflight/default.nix b/pkgs/development/misc/stm32/betaflight/default.nix
index dee5f51b290df..486ca04d36a56 100644
--- a/pkgs/development/misc/stm32/betaflight/default.nix
+++ b/pkgs/development/misc/stm32/betaflight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , gcc-arm-embedded, binutils-arm-embedded, python2
 , skipTargets ? [
   # These targets do not build, for the reasons listed, along with the last version checked.
@@ -57,7 +57,7 @@ in stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flight controller software (firmware) used to fly multi-rotor craft and fixed wing craft";
     homepage = "https://github.com/betaflight/betaflight";
     license = licenses.gpl3;
diff --git a/pkgs/development/misc/stm32/inav/default.nix b/pkgs/development/misc/stm32/inav/default.nix
index 8ff8b45f06d4a..c7e59a5d27ea9 100644
--- a/pkgs/development/misc/stm32/inav/default.nix
+++ b/pkgs/development/misc/stm32/inav/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , gcc-arm-embedded, binutils-arm-embedded, ruby
 }:
 
@@ -49,7 +49,7 @@ in stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Navigation-enabled flight control software";
     homepage = "https://inavflight.github.io";
     license = licenses.gpl3;
diff --git a/pkgs/development/misc/yelp-tools/default.nix b/pkgs/development/misc/yelp-tools/default.nix
index 19e345b3c2fdd..9e2d406303c87 100644
--- a/pkgs/development/misc/yelp-tools/default.nix
+++ b/pkgs/development/misc/yelp-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxml2, libxslt, itstool, gnome3, pkgconfig }:
+{ lib, stdenv, fetchurl, libxml2, libxslt, itstool, gnome3, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "yelp-tools";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Yelp/Tools";
     description = "Small programs that help you create, edit, manage, and publish your Mallard or DocBook documentation";
     maintainers = with maintainers; [ domenkozar ];
diff --git a/pkgs/development/mobile/abootimg/default.nix b/pkgs/development/mobile/abootimg/default.nix
index 21d24004645ce..d2e43d1060810 100644
--- a/pkgs/development/mobile/abootimg/default.nix
+++ b/pkgs/development/mobile/abootimg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, coreutils, cpio, findutils, gzip, makeWrapper, util-linux }:
+{ lib, stdenv, fetchFromGitHub, coreutils, cpio, findutils, gzip, makeWrapper, util-linux }:
 
 let
   version = "0.6";
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
     wrapProgram $out/bin/abootimg-unpack-initrd --prefix PATH : ${stdenv.lib.makeBinPath [ cpio gzip ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ggrandou/abootimg";
     description = "Manipulate Android Boot Images";
     license = licenses.gpl2;
diff --git a/pkgs/development/mobile/adb-sync/default.nix b/pkgs/development/mobile/adb-sync/default.nix
index 98f69ed88b169..fc37eefc21212 100644
--- a/pkgs/development/mobile/adb-sync/default.nix
+++ b/pkgs/development/mobile/adb-sync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, platform-tools, makeWrapper
+{ lib, stdenv, fetchFromGitHub, python3, platform-tools, makeWrapper
 , socat, go-mtpfs, adbfs-rootless
 }:
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to synchronise files between a PC and an Android devices using ADB (Android Debug Bridge)";
     homepage = "https://github.com/google/adb-sync";
     license = licenses.asl20;
diff --git a/pkgs/development/mobile/adbfs-rootless/default.nix b/pkgs/development/mobile/adbfs-rootless/default.nix
index 2033fa78ae58b..f562adb1dd054 100644
--- a/pkgs/development/mobile/adbfs-rootless/default.nix
+++ b/pkgs/development/mobile/adbfs-rootless/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig, fuse, adb }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, pkgconfig, fuse, adb }:
 
 stdenv.mkDerivation rec {
   pname = "adbfs-rootless";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     install -D adbfs $out/bin/adbfs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mount Android phones on Linux with adb, no root required";
     inherit (src.meta) homepage;
     license = licenses.bsd3;
diff --git a/pkgs/development/mobile/imgpatchtools/default.nix b/pkgs/development/mobile/imgpatchtools/default.nix
index fd14a73e2ce71..c45e4973f564f 100644
--- a/pkgs/development/mobile/imgpatchtools/default.nix
+++ b/pkgs/development/mobile/imgpatchtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, bzip2, openssl, zlib }:
+{ lib, stdenv, fetchzip, bzip2, openssl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "imgpatchtools";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "install -Dt $out/bin bin/*";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools to manipulate Android OTA archives";
     longDescription = ''
       This package is useful for Android development. In particular, it can be
diff --git a/pkgs/development/mobile/webos/cmake-modules.nix b/pkgs/development/mobile/webos/cmake-modules.nix
index cd58ea4e20cfb..0f73646c76913 100644
--- a/pkgs/development/mobile/webos/cmake-modules.nix
+++ b/pkgs/development/mobile/webos/cmake-modules.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "cmake-modules-webos";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./cmake-setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CMake modules needed to build Open WebOS components";
     license = licenses.asl20;
     maintainers = with maintainers; [ dtzWill ];
diff --git a/pkgs/development/mobile/webos/novacom.nix b/pkgs/development/mobile/webos/novacom.nix
index e7afdb32137b2..08f25a53bf689 100644
--- a/pkgs/development/mobile/webos/novacom.nix
+++ b/pkgs/development/mobile/webos/novacom.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, webos, cmake, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, webos, cmake, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "novacom";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/bin/novaterm --replace "exec novacom" "exec $out/bin/novacom"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for communicating with WebOS devices";
     license = licenses.asl20;
     maintainers = with maintainers; [ dtzWill ];
diff --git a/pkgs/development/mobile/webos/novacomd.nix b/pkgs/development/mobile/webos/novacomd.nix
index 932ec0e59d64a..c39f36b93f688 100644
--- a/pkgs/development/mobile/webos/novacomd.nix
+++ b/pkgs/development/mobile/webos/novacomd.nix
@@ -1,4 +1,4 @@
-{ stdenv,
+{ lib, stdenv,
 fetchFromGitHub, fetchpatch,
 webos, cmake, pkgconfig,
 libusb-compat-0_1 }:
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DWEBOS_TARGET_MACHINE_IMPL=host" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon for communicating with WebOS devices";
     license = licenses.asl20;
     maintainers = with maintainers; [ dtzWill ];
diff --git a/pkgs/development/mobile/xpwn/default.nix b/pkgs/development/mobile/xpwn/default.nix
index 0c49a29b32227..075a247f12c91 100644
--- a/pkgs/development/mobile/xpwn/default.nix
+++ b/pkgs/development/mobile/xpwn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, zlib, libpng, bzip2, libusb-compat-0_1, openssl }:
+{ lib, stdenv, fetchFromGitHub, cmake, zlib, libpng, bzip2, libusb-compat-0_1, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "xpwn";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ zlib libpng bzip2 libusb-compat-0_1 openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://planetbeing.lighthouseapp.com/projects/15246-xpwn";
     description = "Custom NOR firmware loader/IPSW generator for the iPhone";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/development/ocaml-modules/afl-persistent/default.nix b/pkgs/development/ocaml-modules/afl-persistent/default.nix
index 5ac352e0762c1..5625cd95764f4 100644
--- a/pkgs/development/ocaml-modules/afl-persistent/default.nix
+++ b/pkgs/development/ocaml-modules/afl-persistent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, findlib, opaline }:
+{ lib, stdenv, fetchFromGitHub, ocaml, findlib, opaline }:
 
 stdenv.mkDerivation rec {
   pname = "afl-persistent";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
   doCheck = true;
   checkPhase = "./_build/test && ./_build/test2";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/stedolan/ocaml-afl-persistent";
     description = "persistent-mode afl-fuzz for ocaml";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/ansiterminal/default.nix b/pkgs/development/ocaml-modules/ansiterminal/default.nix
index 7b9f017515173..53b02a453a0e4 100644
--- a/pkgs/development/ocaml-modules/ansiterminal/default.nix
+++ b/pkgs/development/ocaml-modules/ansiterminal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild }:
 
 stdenv.mkDerivation rec {
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Chris00/ANSITerminal";
     description = "A module allowing to use the colors and cursor movements on ANSI terminals";
     longDescription = ''
diff --git a/pkgs/development/ocaml-modules/atd/default.nix b/pkgs/development/ocaml-modules/atd/default.nix
index 84b137ada7c36..41992575a9969 100644
--- a/pkgs/development/ocaml-modules/atd/default.nix
+++ b/pkgs/development/ocaml-modules/atd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, menhir, easy-format, fetchFromGitHub, buildDunePackage, which, biniou, yojson }:
+{ lib, stdenv, menhir, easy-format, fetchFromGitHub, buildDunePackage, which, biniou, yojson }:
 
 buildDunePackage rec {
   pname = "atd";
@@ -18,7 +18,7 @@ buildDunePackage rec {
   buildInputs = [ which menhir ];
   propagatedBuildInputs = [ easy-format biniou yojson ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mjambon/atd";
     description = "Syntax for cross-language type definitions";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/bap/default.nix b/pkgs/development/ocaml-modules/bap/default.nix
index 9cb0859cedc81..f24896ba2e995 100644
--- a/pkgs/development/ocaml-modules/bap/default.nix
+++ b/pkgs/development/ocaml-modules/bap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl
+{ lib, stdenv, fetchFromGitHub, fetchurl
 , ocaml, findlib, ocamlbuild, ocaml_oasis
 , bitstring, camlzip, cmdliner, core_kernel, ezjsonm, fileutils, ocaml_lwt, ocamlgraph, ocurl, re, uri, zarith, piqi, piqi-ocaml, uuidm, llvm, frontc, ounit, ppx_jane, parsexp
 , utop, libxml2, ncurses
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--enable-everything ${disableIda}" "--with-llvm-config=${llvm}/bin/llvm-config" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Platform for binary analysis. It is written in OCaml, but can be used from other languages.";
     homepage = "https://github.com/BinaryAnalysisPlatform/bap/";
     maintainers = [ maintainers.maurer ];
diff --git a/pkgs/development/ocaml-modules/bin_prot/default.nix b/pkgs/development/ocaml-modules/bin_prot/default.nix
index 0dddb653e09e1..1da1df752e89d 100644
--- a/pkgs/development/ocaml-modules/bin_prot/default.nix
+++ b/pkgs/development/ocaml-modules/bin_prot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildOcaml, fetchurl, ocaml, type_conv }:
+{ lib, stdenv, buildOcaml, fetchurl, ocaml, type_conv }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "bin_prot-112.24.00 is not available for OCaml ${ocaml.version}"
@@ -19,7 +19,7 @@ buildOcaml rec {
 
   hasSharedObjects = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/bin_prot";
     description = "Binary protocol generator ";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/biniou/1.0.nix b/pkgs/development/ocaml-modules/biniou/1.0.nix
index ed216d8236aae..e98c9a40eea6a 100644
--- a/pkgs/development/ocaml-modules/biniou/1.0.nix
+++ b/pkgs/development/ocaml-modules/biniou/1.0.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ocaml, findlib, easy-format}:
+{lib, stdenv, fetchurl, ocaml, findlib, easy-format}:
 let
   pname = "biniou";
   version = "1.0.9";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     mkdir $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A binary data format designed for speed, safety, ease of use and backward compatibility as protocols evolve";
     homepage = webpage;
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/biocaml/default.nix b/pkgs/development/ocaml-modules/biocaml/default.nix
index c85886c73de43..216978412e0af 100644
--- a/pkgs/development/ocaml-modules/biocaml/default.nix
+++ b/pkgs/development/ocaml-modules/biocaml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchFromGitHub, fetchpatch
+{ lib, stdenv, buildDunePackage, fetchFromGitHub, fetchpatch
 , ounit, async, base64, camlzip, cfstream
 , core, ppx_jane, ppx_sexp_conv, rresult, uri, xmlm }:
 
@@ -21,7 +21,7 @@ buildDunePackage rec {
   checkInputs = [ ounit ];
   propagatedBuildInputs = [ async base64 camlzip cfstream core rresult uri xmlm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bioinformatics library for Ocaml";
     homepage = "http://${pname}.org";
     maintainers = [ maintainers.bcdarwin ];
diff --git a/pkgs/development/ocaml-modules/bolt/default.nix b/pkgs/development/ocaml-modules/bolt/default.nix
index f5dc099b1403f..d14deedcb6579 100644
--- a/pkgs/development/ocaml-modules/bolt/default.nix
+++ b/pkgs/development/ocaml-modules/bolt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, ocaml, findlib, ocamlbuild, which, camlp4 }:
+{ lib, stdenv, fetchurl, fetchpatch, ocaml, findlib, ocamlbuild, which, camlp4 }:
 
 let inherit (stdenv.lib) getVersion versionAtLeast; in
 
@@ -50,7 +50,7 @@ EOF
   doCheck = true;
   checkTarget = "tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://bolt.x9c.fr";
     description = "A logging tool for the OCaml language";
     longDescription = ''
diff --git a/pkgs/development/ocaml-modules/camlimages/4.0.nix b/pkgs/development/ocaml-modules/camlimages/4.0.nix
index e62acc3cd63f0..26735b1c5d7f7 100644
--- a/pkgs/development/ocaml-modules/camlimages/4.0.nix
+++ b/pkgs/development/ocaml-modules/camlimages/4.0.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, omake, ocaml, libtiff, libjpeg, libpng, giflib, findlib, libXpm, freetype, graphicsmagick, ghostscript }:
+{ lib, stdenv, fetchurl, omake, ocaml, libtiff, libjpeg, libpng, giflib, findlib, libXpm, freetype, graphicsmagick, ghostscript }:
 
 let
   pname = "camlimages";
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     omake install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     branch = "4.0";
     homepage = "https://bitbucket.org/camlspotter/camlimages";
     description = "OCaml image processing library";
diff --git a/pkgs/development/ocaml-modules/camlpdf/default.nix b/pkgs/development/ocaml-modules/camlpdf/default.nix
index 7e231001f24f3..ca9432a72b3d3 100644
--- a/pkgs/development/ocaml-modules/camlpdf/default.nix
+++ b/pkgs/development/ocaml-modules/camlpdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which, ocaml, findlib }:
+{ lib, stdenv, fetchFromGitHub, which, ocaml, findlib }:
 
 if !stdenv.lib.versionAtLeast ocaml.version "4.02"
 then throw "camlpdf is not available for OCaml ${ocaml.version}"
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/lib/ocaml/${ocaml.version}/site-lib/stublibs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml library for reading, writing and modifying PDF files";
     homepage = "https://github.com/johnwhitington/camlpdf";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/ocaml-modules/camlzip/default.nix b/pkgs/development/ocaml-modules/camlzip/default.nix
index 1e6e0e8f8faa6..d8bbfafa98de2 100644
--- a/pkgs/development/ocaml-modules/camlzip/default.nix
+++ b/pkgs/development/ocaml-modules/camlzip/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, zlib, ocaml, findlib}:
+{lib, stdenv, fetchurl, zlib, ocaml, findlib}:
 
 let
   param =
@@ -53,7 +53,7 @@ stdenv.mkDerivation {
     ln -s $out/lib/ocaml/${ocaml.version}/site-lib/{,caml}zip
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cristal.inria.fr/~xleroy/software.html#camlzip";
     description = "A library for handling ZIP and GZIP files in OCaml";
     longDescription = ''
diff --git a/pkgs/development/ocaml-modules/cfstream/default.nix b/pkgs/development/ocaml-modules/cfstream/default.nix
index d0fcf5be83ccc..a947eadbf11d9 100644
--- a/pkgs/development/ocaml-modules/cfstream/default.nix
+++ b/pkgs/development/ocaml-modules/cfstream/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchFromGitHub, m4, core_kernel, ounit }:
+{ lib, stdenv, buildDunePackage, fetchFromGitHub, m4, core_kernel, ounit }:
 
 buildDunePackage rec {
   pname = "cfstream";
@@ -23,7 +23,7 @@ buildDunePackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Simple Core-inspired wrapper for standard library Stream module";
     maintainers = [ maintainers.bcdarwin ];
diff --git a/pkgs/development/ocaml-modules/cil/default.nix b/pkgs/development/ocaml-modules/cil/default.nix
index 9903c237e6323..75e0224491074 100644
--- a/pkgs/development/ocaml-modules/cil/default.nix
+++ b/pkgs/development/ocaml-modules/cil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, ocaml, findlib, ocamlbuild }:
+{ lib, stdenv, fetchurl, perl, ocaml, findlib, ocamlbuild }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "cil is not available for OCaml ${ocaml.version}"
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
   '';
   prefixKey = "-prefix=";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://kerneis.github.io/cil/";
     description = "A front-end for the C programming language that facilitates program analysis and transformation";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/cmdliner/default.nix b/pkgs/development/ocaml-modules/cmdliner/default.nix
index 7c94dcf54356c..b998047104302 100644
--- a/pkgs/development/ocaml-modules/cmdliner/default.nix
+++ b/pkgs/development/ocaml-modules/cmdliner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, result }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, result }:
 
 let
   pname = "cmdliner";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://erratique.ch/software/cmdliner";
     description = "An OCaml module for the declarative definition of command line interfaces";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/comparelib/default.nix b/pkgs/development/ocaml-modules/comparelib/default.nix
index 55787e123923f..d5133064652d6 100644
--- a/pkgs/development/ocaml-modules/comparelib/default.nix
+++ b/pkgs/development/ocaml-modules/comparelib/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcaml, fetchurl, type_conv}:
+{lib, stdenv, buildOcaml, fetchurl, type_conv}:
 
 buildOcaml rec {
   name = "comparelib";
@@ -13,7 +13,7 @@ buildOcaml rec {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/comparelib";
     description = "Syntax extension for deriving \"compare\" functions automatically";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/cpdf/default.nix b/pkgs/development/ocaml-modules/cpdf/default.nix
index e40f6531e1fd1..cc2aad52d3d66 100644
--- a/pkgs/development/ocaml-modules/cpdf/default.nix
+++ b/pkgs/development/ocaml-modules/cpdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, findlib, camlpdf, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ocaml, findlib, camlpdf, ncurses }:
 
 let version = "2.3.1"; in
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     cp cpdfmanual.pdf $out/share/doc/cpdf/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.coherentpdf.com/";
     platforms = ocaml.meta.platforms or [];
     description = "PDF Command Line Tools";
diff --git a/pkgs/development/ocaml-modules/cpu/default.nix b/pkgs/development/ocaml-modules/cpu/default.nix
index 716e40e16e9f6..2544723a902b3 100644
--- a/pkgs/development/ocaml-modules/cpu/default.nix
+++ b/pkgs/development/ocaml-modules/cpu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchFromGitHub, autoconf }:
+{ lib, stdenv, buildDunePackage, fetchFromGitHub, autoconf }:
 
 buildDunePackage rec {
   pname = "cpu";
@@ -20,7 +20,7 @@ buildDunePackage rec {
 
   hardeningDisable = stdenv.lib.optional stdenv.isDarwin "strictoverflow";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Core pinning library";
     maintainers = [ maintainers.bcdarwin ];
diff --git a/pkgs/development/ocaml-modules/crowbar/default.nix b/pkgs/development/ocaml-modules/crowbar/default.nix
index 0189026e346b3..d05d15286bf79 100644
--- a/pkgs/development/ocaml-modules/crowbar/default.nix
+++ b/pkgs/development/ocaml-modules/crowbar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchFromGitHub, ocplib-endian, cmdliner, afl-persistent
+{ lib, stdenv, buildDunePackage, fetchFromGitHub, ocplib-endian, cmdliner, afl-persistent
 , calendar, fpath, pprint, uutf, uunf, uucp }:
 
 buildDunePackage rec {
@@ -22,7 +22,7 @@ buildDunePackage rec {
   # uunf is broken on aarch64
   doCheck = !stdenv.isAarch64;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Property fuzzing for OCaml";
     homepage = "https://github.com/stedolan/crowbar";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/cstruct/1.9.0.nix b/pkgs/development/ocaml-modules/cstruct/1.9.0.nix
index 1cea58abee20c..33c1aa6b7ae83 100644
--- a/pkgs/development/ocaml-modules/cstruct/1.9.0.nix
+++ b/pkgs/development/ocaml-modules/cstruct/1.9.0.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, ocamlbuild, ocplib-endian, sexplib, findlib, ppx_tools
+{ lib, stdenv, fetchFromGitHub, ocaml, ocamlbuild, ocplib-endian, sexplib, findlib, ppx_tools
 , async ? null, lwt ? null
 }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
   createFindlibDestdir = true;
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mirage/ocaml-cstruct";
     description = "Map OCaml arrays onto C-like structs";
     license = stdenv.lib.licenses.isc;
diff --git a/pkgs/development/ocaml-modules/csv/1.5.nix b/pkgs/development/ocaml-modules/csv/1.5.nix
index 9b61526926317..6fdf20308611c 100644
--- a/pkgs/development/ocaml-modules/csv/1.5.nix
+++ b/pkgs/development/ocaml-modules/csv/1.5.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, ocaml, findlib, ocamlbuild }:
+{ lib, stdenv, fetchzip, ocaml, findlib, ocamlbuild }:
 
 stdenv.mkDerivation {
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
 
   installPhase = "ocaml setup.ml -install";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure OCaml library to read and write CSV files";
     homepage = "https://github.com/Chris00/ocaml-csv";
     license = licenses.lgpl21;
diff --git a/pkgs/development/ocaml-modules/ctypes/default.nix b/pkgs/development/ocaml-modules/ctypes/default.nix
index 8a16dcec343bf..1805f587cad66 100644
--- a/pkgs/development/ocaml-modules/ctypes/default.nix
+++ b/pkgs/development/ocaml-modules/ctypes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, ocaml, findlib, libffi, pkgconfig, ncurses, integers }:
+{ lib, stdenv, fetchzip, ocaml, findlib, libffi, pkgconfig, ncurses, integers }:
 
 if !stdenv.lib.versionAtLeast ocaml.version "4.02"
 then throw "ctypes is not available for OCaml ${ocaml.version}"
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     make install XEN=false
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ocamllabs/ocaml-ctypes";
     description = "Library for binding to C libraries using pure OCaml";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/curses/default.nix b/pkgs/development/ocaml-modules/curses/default.nix
index 2c989caa3e8d1..f1211ad9cdc63 100644
--- a/pkgs/development/ocaml-modules/curses/default.nix
+++ b/pkgs/development/ocaml-modules/curses/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ncurses }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "ocaml-curses";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   buildPhase = "make all opt";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OCaml Bindings to curses/ncurses";
     homepage = "https://opam.ocaml.org/packages/curses/curses.1.0.4/";
     license = licenses.gpl2;
diff --git a/pkgs/development/ocaml-modules/dtoa/default.nix b/pkgs/development/ocaml-modules/dtoa/default.nix
index b26cbec25edb3..92f75fb3c3348 100644
--- a/pkgs/development/ocaml-modules/dtoa/default.nix
+++ b/pkgs/development/ocaml-modules/dtoa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildDunePackage }:
+{ lib, stdenv, fetchurl, buildDunePackage }:
 
 buildDunePackage rec {
   pname = "dtoa";
@@ -13,7 +13,7 @@ buildDunePackage rec {
 
   hardeningDisable = stdenv.lib.optional stdenv.isDarwin "strictoverflow";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/flowtype/ocaml-dtoa";
     description = "Converts OCaml floats into strings (doubles to ascii, \"d to a\"), using the efficient Grisu3 algorithm.";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/dum/default.nix b/pkgs/development/ocaml-modules/dum/default.nix
index 844d06e30389a..d8aa1f371f3b5 100644
--- a/pkgs/development/ocaml-modules/dum/default.nix
+++ b/pkgs/development/ocaml-modules/dum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, findlib
+{ lib, stdenv, fetchFromGitHub, ocaml, findlib
 , easy-format
 }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mjambon/dum";
     description = "Inspect the runtime representation of arbitrary OCaml values";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/ocaml-modules/easy-format/default.nix b/pkgs/development/ocaml-modules/easy-format/default.nix
index 5c1155a723bde..6a3566fda2b61 100644
--- a/pkgs/development/ocaml-modules/easy-format/default.nix
+++ b/pkgs/development/ocaml-modules/easy-format/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, ocaml, findlib }:
+{ lib, stdenv, fetchzip, ocaml, findlib }:
 let
   pname = "easy-format";
   version = "1.2.0";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
   doCheck = true;
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-level and functional interface to the Format module of the OCaml standard library";
     homepage = "https://github.com/ocaml-community/${pname}";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/eigen/default.nix b/pkgs/development/ocaml-modules/eigen/default.nix
index dacd3a758623b..e86d21da016a7 100644
--- a/pkgs/development/ocaml-modules/eigen/default.nix
+++ b/pkgs/development/ocaml-modules/eigen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchFromGitHub, ctypes, libcxx }:
+{ lib, stdenv, buildDunePackage, fetchFromGitHub, ctypes, libcxx }:
 
 buildDunePackage rec {
   pname = "eigen";
@@ -19,7 +19,7 @@ buildDunePackage rec {
 
   propagatedBuildInputs = [ ctypes ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Minimal/incomplete Ocaml interface to Eigen3, mostly for Owl";
     platforms = platforms.x86_64;
diff --git a/pkgs/development/ocaml-modules/estring/default.nix b/pkgs/development/ocaml-modules/estring/default.nix
index 4cd27f272b3c8..782ebce9cb864 100644
--- a/pkgs/development/ocaml-modules/estring/default.nix
+++ b/pkgs/development/ocaml-modules/estring/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildOcaml, ocaml, fetchurl }:
+{ lib, stdenv, buildOcaml, ocaml, fetchurl }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "estring is not available for OCaml ${ocaml.version}"
@@ -13,7 +13,7 @@ buildOcaml rec {
     sha256 = "0b6znz5igm8pp28w4b7sgy82rpd9m5aw6ss933rfbw1mrh05gvcg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://estring.forge.ocamlcore.org/";
     description = "Extension for string literals";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/ezxmlm/default.nix b/pkgs/development/ocaml-modules/ezxmlm/default.nix
index 1740bd77fdb2d..68b128283cc4f 100644
--- a/pkgs/development/ocaml-modules/ezxmlm/default.nix
+++ b/pkgs/development/ocaml-modules/ezxmlm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildDunePackage, xmlm }:
+{ lib, stdenv, fetchFromGitHub, buildDunePackage, xmlm }:
 
 buildDunePackage rec {
   pname = "ezxmlm";
@@ -13,7 +13,7 @@ buildDunePackage rec {
 
   propagatedBuildInputs = [ xmlm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Combinators to use with xmlm for parsing and selection";
     longDescription = ''
       An "easy" interface on top of the xmlm library. This version provides
diff --git a/pkgs/development/ocaml-modules/faillib/default.nix b/pkgs/development/ocaml-modules/faillib/default.nix
index 2a4d03e87aea1..64993c4912d4d 100644
--- a/pkgs/development/ocaml-modules/faillib/default.nix
+++ b/pkgs/development/ocaml-modules/faillib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildOcaml, fetchurl, ocaml, herelib, camlp4 }:
+{ lib, stdenv, buildOcaml, fetchurl, ocaml, herelib, camlp4 }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "faillib-111.17.00 is not available for OCaml ${ocaml.version}"
@@ -19,7 +19,7 @@ buildOcaml rec {
   doCheck = true;
   checkPhase = "make test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ocaml.janestreet.com/";
     description = "Library for dealing with failure in OCaml";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/fieldslib/default.nix b/pkgs/development/ocaml-modules/fieldslib/default.nix
index 90b75faa54c2b..9a90c7e5d0d25 100644
--- a/pkgs/development/ocaml-modules/fieldslib/default.nix
+++ b/pkgs/development/ocaml-modules/fieldslib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, type_conv, camlp4 }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, type_conv, camlp4 }:
 
 assert stdenv.lib.versionOlder "4.00" (stdenv.lib.getVersion ocaml);
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ocaml.janestreet.com/";
     description = "OCaml syntax extension to define first class values representing record fields, to get and set record fields, iterate and fold over all fields of a record and create new record values";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/fix/default.nix b/pkgs/development/ocaml-modules/fix/default.nix
index d1a2b93cee160..cdf585683d767 100644
--- a/pkgs/development/ocaml-modules/fix/default.nix
+++ b/pkgs/development/ocaml-modules/fix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild }:
 
 assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gallium.inria.fr/~fpottier/fix/";
     description = "A simple OCaml module for computing the least solution of a system of monotone equations";
     license = licenses.cecill-c;
diff --git a/pkgs/development/ocaml-modules/fmt/default.nix b/pkgs/development/ocaml-modules/fmt/default.nix
index 6b457a9d6dc25..adac4c199c03d 100644
--- a/pkgs/development/ocaml-modules/fmt/default.nix
+++ b/pkgs/development/ocaml-modules/fmt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, cmdliner, seq, stdlib-shims }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, cmdliner, seq, stdlib-shims }:
 
 if !stdenv.lib.versionAtLeast ocaml.version "4.05"
 then throw "fmt is not available for OCaml ${ocaml.version}"
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://erratique.ch/software/fmt";
     license = licenses.isc;
     description = "OCaml Format pretty-printer combinators";
diff --git a/pkgs/development/ocaml-modules/functory/default.nix b/pkgs/development/ocaml-modules/functory/default.nix
index 934a88254e27f..e1078f420ba24 100644
--- a/pkgs/development/ocaml-modules/functory/default.nix
+++ b/pkgs/development/ocaml-modules/functory/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib }:
+{ lib, stdenv, fetchurl, ocaml, findlib }:
 
 assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.11";
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.lri.fr/~filliatr/functory/";
     description = "A distributed computing library for Objective Caml which facilitates distributed execution of parallelizable computations in a seamless fashion";
     license = licenses.lgpl21;
diff --git a/pkgs/development/ocaml-modules/gg/default.nix b/pkgs/development/ocaml-modules/gg/default.nix
index d4c28be2f7982..c772b9a8b5476 100644
--- a/pkgs/development/ocaml-modules/gg/default.nix
+++ b/pkgs/development/ocaml-modules/gg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, opaline }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, opaline }:
 
 let
   inherit (stdenv.lib) getVersion versionAtLeast;
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
 
   installPhase = "opaline -libdir $OCAMLFIND_DESTDIR";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Basic types for computer graphics in OCaml";
     longDescription = ''
       Gg is an OCaml module providing basic types for computer graphics. It
diff --git a/pkgs/development/ocaml-modules/gsl/default.nix b/pkgs/development/ocaml-modules/gsl/default.nix
index aebdf4adb27f7..4780b7917ce59 100644
--- a/pkgs/development/ocaml-modules/gsl/default.nix
+++ b/pkgs/development/ocaml-modules/gsl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildDunePackage, pkg-config, gsl, darwin, dune-configurator }:
+{ lib, stdenv, fetchurl, buildDunePackage, pkg-config, gsl, darwin, dune-configurator }:
 
 buildDunePackage rec {
   pname = "gsl";
@@ -14,7 +14,7 @@ buildDunePackage rec {
   buildInputs = [ dune-configurator gsl pkg-config ];
   propagatedBuildInputs = stdenv.lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.Accelerate ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mmottl.github.io/gsl-ocaml/";
     description = "OCaml bindings to the GNU Scientific Library";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/ocaml-modules/herelib/default.nix b/pkgs/development/ocaml-modules/herelib/default.nix
index a99b6cb711e47..16bf0443d7ed7 100644
--- a/pkgs/development/ocaml-modules/herelib/default.nix
+++ b/pkgs/development/ocaml-modules/herelib/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcaml, fetchurl}:
+{lib, stdenv, buildOcaml, fetchurl}:
 
 buildOcaml rec {
   version = "112.35.00";
@@ -11,7 +11,7 @@ buildOcaml rec {
     sha256 = "03rrlpjmnd8d1rzzmd112355m7a5bwn3vf90xkbc6gkxlad9cxbs";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/herelib";
     description = "Syntax extension for inserting the current location";
     license = stdenv.lib.licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/higlo/default.nix b/pkgs/development/ocaml-modules/higlo/default.nix
index ecda6338beed1..3c4b7a37f99ef 100644
--- a/pkgs/development/ocaml-modules/higlo/default.nix
+++ b/pkgs/development/ocaml-modules/higlo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, findlib, xtmpl, ulex }:
+{ lib, stdenv, fetchFromGitHub, ocaml, findlib, xtmpl, ulex }:
 
 stdenv.mkDerivation rec {
   pname = "higlo";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   patches = ./install.patch;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OCaml library for syntax highlighting";
     homepage = "https://zoggy.github.io/higlo/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/ocaml-modules/http/default.nix b/pkgs/development/ocaml-modules/http/default.nix
index 3936eb13c2fb0..b1cae90a6184e 100644
--- a/pkgs/development/ocaml-modules/http/default.nix
+++ b/pkgs/development/ocaml-modules/http/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ocaml_pcre, ocamlnet, ocaml, findlib, camlp4}:
+{lib, stdenv, fetchurl, ocaml_pcre, ocamlnet, ocaml, findlib, camlp4}:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "ocaml-http is not available for OCaml ${ocaml.version}"
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     make all opt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ocaml-http.forge.ocamlcore.org/";
     platforms = ocaml.meta.platforms or [];
     description = "Do it yourself (OCaml) HTTP daemon";
diff --git a/pkgs/development/ocaml-modules/janestreet/async-rpc-kernel.nix b/pkgs/development/ocaml-modules/janestreet/async-rpc-kernel.nix
index 70780ee385fa6..513c0a17c01d1 100644
--- a/pkgs/development/ocaml-modules/janestreet/async-rpc-kernel.nix
+++ b/pkgs/development/ocaml-modules/janestreet/async-rpc-kernel.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane, async_kernel, bin_prot, core_kernel,
+{lib, stdenv, buildOcamlJane, async_kernel, bin_prot, core_kernel,
  fieldslib, ppx_assert, ppx_bench, ppx_driver, ppx_expect, ppx_inline_test,
  ppx_jane, sexplib, typerep, variantslib}:
 
@@ -9,7 +9,7 @@ buildOcamlJane {
     ppx_assert ppx_bench ppx_driver ppx_expect ppx_inline_test ppx_jane
     sexplib typerep variantslib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/async_rpc_kernel";
     description = "Platform-independent core of Async RPC library";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/bin_prot.nix b/pkgs/development/ocaml-modules/janestreet/bin_prot.nix
index 1eb6b6a95f86f..871fade158aaf 100644
--- a/pkgs/development/ocaml-modules/janestreet/bin_prot.nix
+++ b/pkgs/development/ocaml-modules/janestreet/bin_prot.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane, type_conv}:
+{lib, stdenv, buildOcamlJane, type_conv}:
 
 buildOcamlJane {
   name = "bin_prot";
@@ -8,7 +8,7 @@ buildOcamlJane {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/bin_prot";
     description = "Binary protocol generator ";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/core_bench.nix b/pkgs/development/ocaml-modules/janestreet/core_bench.nix
index 1956a7f3b7057..160fb30ee23ef 100644
--- a/pkgs/development/ocaml-modules/janestreet/core_bench.nix
+++ b/pkgs/development/ocaml-modules/janestreet/core_bench.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildOcamlJane
 , core
 , core_extended
@@ -11,7 +11,7 @@ buildOcamlJane {
   propagatedBuildInputs =
     [ core core_extended textutils ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/core_bench";
     description = "Micro-benchmarking library for OCaml";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/fieldslib.nix b/pkgs/development/ocaml-modules/janestreet/fieldslib.nix
index 39aeb7047177e..75b894a8c14f5 100644
--- a/pkgs/development/ocaml-modules/janestreet/fieldslib.nix
+++ b/pkgs/development/ocaml-modules/janestreet/fieldslib.nix
@@ -1,4 +1,4 @@
-{ stdenv, type_conv, buildOcamlJane }:
+{ lib, stdenv, type_conv, buildOcamlJane }:
 
 buildOcamlJane {
   name = "fieldslib";
@@ -10,7 +10,7 @@ buildOcamlJane {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ocaml.janestreet.com/";
     description = "OCaml syntax extension to define first class values representing record fields, to get and set record fields, iterate and fold over all fields of a record and create new record values";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/js-build-tools.nix b/pkgs/development/ocaml-modules/janestreet/js-build-tools.nix
index f77b793bcaabc..eba4e8f94a7fb 100644
--- a/pkgs/development/ocaml-modules/janestreet/js-build-tools.nix
+++ b/pkgs/development/ocaml-modules/janestreet/js-build-tools.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildOcaml, fetchurl, ocaml_oasis, opaline }:
+{ lib, stdenv, buildOcaml, fetchurl, ocaml_oasis, opaline }:
 
 buildOcaml rec {
   name = "js-build-tools";
@@ -21,7 +21,7 @@ buildOcaml rec {
 
   patches = [ ./js-build-tools-darwin.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jane Street Build Tools";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-assert.nix b/pkgs/development/ocaml-modules/janestreet/ppx-assert.nix
index 3ed7106e7b652..bd38d963034e3 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-assert.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-assert.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_compare, ppx_core, ppx_driver, ppx_here, ppx_sexp_conv, ppx_tools, ppx_type_conv, sexplib}:
 
 buildOcamlJane {
@@ -8,7 +8,7 @@ buildOcamlJane {
     [ ppx_compare ppx_core ppx_driver ppx_here ppx_sexp_conv ppx_tools
       ppx_type_conv sexplib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Assert-like extension nodes that raise useful errors on failure";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-bench.nix b/pkgs/development/ocaml-modules/janestreet/ppx-bench.nix
index 9e5df431e04c2..131af5367db61 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-bench.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-bench.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver, ppx_inline_test, ppx_tools}:
 
 buildOcamlJane {
@@ -10,7 +10,7 @@ buildOcamlJane {
 
   propagatedBuildInputs = [ ppx_core ppx_driver ppx_inline_test ppx_tools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Syntax extension for writing in-line benchmarks in ocaml code";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-bin-prot.nix b/pkgs/development/ocaml-modules/janestreet/ppx-bin-prot.nix
index d7f333d4cf4c5..c742d6fbe8080 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-bin-prot.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-bin-prot.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_tools, ppx_type_conv, bin_prot}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0kwmrrrybdkmphqczsr3lg3imsxcjb8iy41syvn44s3kcjfyyzbz";
   propagatedBuildInputs = [ ppx_core ppx_tools ppx_type_conv bin_prot ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generation of bin_prot readers and writers from types";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-compare.nix b/pkgs/development/ocaml-modules/janestreet/ppx-compare.nix
index 0bfdd7bd540ce..51b18de65e6ab 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-compare.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-compare.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver, ppx_tools, ppx_type_conv}:
 
 buildOcamlJane {
@@ -7,7 +7,7 @@ buildOcamlJane {
   propagatedBuildInputs =
     [ppx_core ppx_driver ppx_tools ppx_type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generation of fast comparison functions from type expressions and definitions";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-custom-printf.nix b/pkgs/development/ocaml-modules/janestreet/ppx-custom-printf.nix
index c652afa5fbfc9..f3a20425b73c7 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-custom-printf.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-custom-printf.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver, ppx_sexp_conv, ppx_tools}:
 
 buildOcamlJane {
@@ -7,7 +7,7 @@ buildOcamlJane {
 
   propagatedBuildInputs = [ ppx_core ppx_driver ppx_sexp_conv ppx_tools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extensions to printf-style format-strings for user-defined string conversion";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-enumerate.nix b/pkgs/development/ocaml-modules/janestreet/ppx-enumerate.nix
index 2fdfede0f23df..d4c7c61a3992a 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-enumerate.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-enumerate.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_tools, ppx_type_conv}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0m11921q2pjzkwckf21fynd2qfy83n9jjsgks23yagdai8a7ym16";
   propagatedBuildInputs = [ ppx_core ppx_tools ppx_type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate a list containing all values of a finite type";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-expect.nix b/pkgs/development/ocaml-modules/janestreet/ppx-expect.nix
index f78f93ee1202b..b3dfcb68ed192 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-expect.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-expect.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_assert, ppx_compare, ppx_core, ppx_custom_printf, ppx_driver,
  ppx_fields_conv, ppx_here, ppx_inline_test, ppx_sexp_conv, ppx_tools,
  ppx_variants_conv, re, sexplib, variantslib, fieldslib}:
@@ -11,7 +11,7 @@ buildOcamlJane {
       ppx_fields_conv ppx_here ppx_inline_test ppx_sexp_conv ppx_tools
       ppx_variants_conv re sexplib variantslib fieldslib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cram-like framework for OCaml";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-fields-conv.nix b/pkgs/development/ocaml-modules/janestreet/ppx-fields-conv.nix
index 551738573b369..7fdcdc4461283 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-fields-conv.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-fields-conv.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_tools, ppx_type_conv}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "11w9wfjgkv7yxv3rwlwi6m193zan6rhmi45q7n3ddi2s8ls3gra7";
   propagatedBuildInputs = [ ppx_core ppx_tools ppx_type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generation of accessor and iteration functions for ocaml records";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-here.nix b/pkgs/development/ocaml-modules/janestreet/ppx-here.nix
index ea3ac5e8e5aef..95ebb59faf9f5 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-here.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-here.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "1mzdgn8k171zkwmbizf1a48l525ny0w3363c7gknpnifcinxniiw";
   propagatedBuildInputs = [ ppx_core ppx_driver ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A ppx rewriter that defines an extension node whose value is its source position";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-inline-test.nix b/pkgs/development/ocaml-modules/janestreet/ppx-inline-test.nix
index d0e4c84158c7d..811e529851b88 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-inline-test.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-inline-test.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver, ppx_tools}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0ygapa54i0wwcj3jcqwiimrc6z0b7aafgjhbk37h6vvclnm5n7f6";
   propagatedBuildInputs = [ ppx_core ppx_driver ppx_tools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Syntax extension for writing in-line tests in ocaml code";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-jane.nix b/pkgs/development/ocaml-modules/janestreet/ppx-jane.nix
index 1086059b19f3e..07577dbf1f7a8 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-jane.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-jane.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_assert,
  ppx_bench, ppx_bin_prot, ppx_compare, ppx_custom_printf, ppx_driver,
  ppx_enumerate, ppx_expect, ppx_fail, ppx_fields_conv, ppx_here,
@@ -14,7 +14,7 @@ buildOcamlJane {
       ppx_here ppx_inline_test ppx_let ppx_pipebang ppx_sexp_conv
       ppx_sexp_message ppx_sexp_value ppx_typerep_conv ppx_variants_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A ppx_driver including all standard ppx rewriters";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-let.nix b/pkgs/development/ocaml-modules/janestreet/ppx-let.nix
index 8c8b87d7112e8..370221c1d4813 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-let.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-let.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0whnfq4rgkq4apfqnvc100wlk25pmqdyvy6s21dsn3fcm9hff467";
   propagatedBuildInputs = [ ppx_core ppx_driver ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A ppx rewriter for monadic and applicative let bindings and match statements";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-optcomp.nix b/pkgs/development/ocaml-modules/janestreet/ppx-optcomp.nix
index 61fa66b77cc52..fe4f1753fa78c 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-optcomp.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-optcomp.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_tools}:
 
 buildOcamlJane {
@@ -7,7 +7,7 @@ buildOcamlJane {
   propagatedBuildInputs =
     [ ppx_core ppx_tools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ppx_optcomp stands for Optional Compilation. It is a tool used to handle optional compilations of pieces of code depending of the word size, the version of the compiler, etc.";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-pipebang.nix b/pkgs/development/ocaml-modules/janestreet/ppx-pipebang.nix
index 209638f97b741..b1d8007936b6a 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-pipebang.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-pipebang.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver, ppx_tools}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0k25bhj9ziiw89xvs4svz7cgazbbmprba9wbic2llffg55fp7acc";
   propagatedBuildInputs = [ ppx_core ppx_driver ppx_tools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A ppx rewriter that inlines reverse application operators |> and |!";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-sexp-conv.nix b/pkgs/development/ocaml-modules/janestreet/ppx-sexp-conv.nix
index 00361ee81ebed..c820464d10961 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-sexp-conv.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-sexp-conv.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_tools, ppx_type_conv, sexplib}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "1kgbmlc11w5jhbhmy5n0f734l44zwyry48342dm5qydi9sfzcgq2";
   propagatedBuildInputs = [ ppx_core ppx_tools ppx_type_conv sexplib];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PPX syntax extension that generates code for converting OCaml types to and from s-expressions, as defined in the sexplib library";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-sexp-message.nix b/pkgs/development/ocaml-modules/janestreet/ppx-sexp-message.nix
index 2a8bf44bfab20..a710436000ecb 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-sexp-message.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-sexp-message.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver, ppx_here, ppx_sexp_conv, ppx_tools}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0inbff25qii868p141jb1y8n3vjfyz66jpnsl9nma6nkkyjkp05j";
   propagatedBuildInputs = [ ppx_core ppx_driver ppx_here ppx_sexp_conv ppx_tools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easy construction of S-Expressions";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-sexp-value.nix b/pkgs/development/ocaml-modules/janestreet/ppx-sexp-value.nix
index 64fbe4bd9bb9c..e51a27ffaeefd 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-sexp-value.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-sexp-value.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_driver, ppx_here, ppx_sexp_conv, ppx_tools}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "04602ppqfwx33ghjywam00hlqqzsz4d99r60k9q0v1mynk9pjhj0";
   propagatedBuildInputs = [ ppx_core ppx_driver ppx_here ppx_sexp_conv ppx_tools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A ppx rewriter that simplifies building S-Expression from OCaml Values";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-typerep-conv.nix b/pkgs/development/ocaml-modules/janestreet/ppx-typerep-conv.nix
index 472ec19b55884..b4d6288a179ca 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-typerep-conv.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-typerep-conv.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_tools, ppx_type_conv, typerep}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0dldlx73r07j6w0i7h4hxly0v678naa79na5rafsk2974gs5ih9g";
   propagatedBuildInputs = [ ppx_core ppx_tools ppx_type_conv typerep ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic generation of runtime types from type definitions";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/ppx-variants-conv.nix b/pkgs/development/ocaml-modules/janestreet/ppx-variants-conv.nix
index 1d01b0bc321d1..7989ecaecea70 100644
--- a/pkgs/development/ocaml-modules/janestreet/ppx-variants-conv.nix
+++ b/pkgs/development/ocaml-modules/janestreet/ppx-variants-conv.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane,
+{lib, stdenv, buildOcamlJane,
  ppx_core, ppx_tools, ppx_type_conv, sexplib, variantslib}:
 
 buildOcamlJane {
@@ -6,7 +6,7 @@ buildOcamlJane {
   hash = "0kgal8b9yh7wrd75hllb9fyl6zbksfnr9k7pykpzdm3js98dirhn";
   propagatedBuildInputs = [ ppx_core ppx_tools ppx_type_conv sexplib variantslib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generation of accessor and iteration functions for ocaml variant types";
     maintainers = [ maintainers.maurer ];
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/sexplib.nix b/pkgs/development/ocaml-modules/janestreet/sexplib.nix
index 1bb9d489b1484..df8f6591bdac6 100644
--- a/pkgs/development/ocaml-modules/janestreet/sexplib.nix
+++ b/pkgs/development/ocaml-modules/janestreet/sexplib.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane, type_conv}:
+{lib, stdenv, buildOcamlJane, type_conv}:
 
 buildOcamlJane {
   minimumSupportedOcamlVersion = "4.02";
@@ -9,7 +9,7 @@ buildOcamlJane {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ocaml.janestreet.com/";
     description = "Library for serializing OCaml values to and from S-expressions";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/typerep.nix b/pkgs/development/ocaml-modules/janestreet/typerep.nix
index 9ed037e52110e..ee751eb3cfc48 100644
--- a/pkgs/development/ocaml-modules/janestreet/typerep.nix
+++ b/pkgs/development/ocaml-modules/janestreet/typerep.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane, type_conv}:
+{lib, stdenv, buildOcamlJane, type_conv}:
 
 buildOcamlJane {
   name = "typerep";
@@ -10,7 +10,7 @@ buildOcamlJane {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/typerep";
     description = "Runtime types for OCaml (beta version)";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/janestreet/variantslib.nix b/pkgs/development/ocaml-modules/janestreet/variantslib.nix
index 02e63291add29..3fd7877d2bb41 100644
--- a/pkgs/development/ocaml-modules/janestreet/variantslib.nix
+++ b/pkgs/development/ocaml-modules/janestreet/variantslib.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcamlJane, type_conv}:
+{lib, stdenv, buildOcamlJane, type_conv}:
 
 buildOcamlJane {
   name = "variantslib";
@@ -10,7 +10,7 @@ buildOcamlJane {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/variantslib";
     description = "OCaml variants as first class values";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/javalib/default.nix b/pkgs/development/ocaml-modules/javalib/default.nix
index f7978cf4805e4..13cff62afbf89 100644
--- a/pkgs/development/ocaml-modules/javalib/default.nix
+++ b/pkgs/development/ocaml-modules/javalib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, which, ocaml, findlib
+{ lib, stdenv, fetchzip, which, ocaml, findlib
 , camlzip, extlib
 }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = [ camlzip extlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library that parses Java .class files into OCaml data structures";
     homepage = "https://javalib-team.github.io/javalib/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/ocaml-modules/kafka/default.nix b/pkgs/development/ocaml-modules/kafka/default.nix
index 0176daeaf6c56..d1ebe95be89d6 100644
--- a/pkgs/development/ocaml-modules/kafka/default.nix
+++ b/pkgs/development/ocaml-modules/kafka/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildDunePackage, base, cmdliner, ocaml_lwt,
+{ lib, stdenv, fetchFromGitHub, buildDunePackage, base, cmdliner, ocaml_lwt,
   rdkafka, zlib }:
 
 buildDunePackage rec {
@@ -16,7 +16,7 @@ buildDunePackage rec {
 
   propagatedBuildInputs = [ rdkafka zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/didier-wenzek/ocaml-kafka";
     description = "OCaml bindings for Kafka";
     license     = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/lablgl/default.nix b/pkgs/development/ocaml-modules/lablgl/default.nix
index 2172135e8d4c7..a7b145c2d4efb 100644
--- a/pkgs/development/ocaml-modules/lablgl/default.nix
+++ b/pkgs/development/ocaml-modules/lablgl/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ocaml, lablgtk, findlib, libGLU, libGL, freeglut, camlp4 } :
+{lib, stdenv, fetchurl, ocaml, lablgtk, findlib, libGLU, libGL, freeglut, camlp4 } :
 
 let
   pname = "lablgl";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     cp ./META $out/lib/ocaml/${ocaml.version}/site-lib/lablgl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://wwwfun.kurims.kyoto-u.ac.jp/soft/lsl/lablgl.html";
     description = "OpenGL bindings for ocaml";
     license = licenses.gpl2;
diff --git a/pkgs/development/ocaml-modules/lablgtk/default.nix b/pkgs/development/ocaml-modules/lablgtk/default.nix
index 2b6c3028fd6c3..0bc24b539acc9 100644
--- a/pkgs/development/ocaml-modules/lablgtk/default.nix
+++ b/pkgs/development/ocaml-modules/lablgtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, ocaml, findlib, pkgconfig, gtk2, libgnomecanvas, libglade, gtksourceview }:
+{ lib, stdenv, fetchurl, fetchFromGitHub, ocaml, findlib, pkgconfig, gtk2, libgnomecanvas, libglade, gtksourceview }:
 
 let param =
   let check = stdenv.lib.versionAtLeast ocaml.version; in
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = ocaml.meta.platforms or [];
     maintainers = with maintainers; [
       maggesi roconnor vbgl
diff --git a/pkgs/development/ocaml-modules/lacaml/default.nix b/pkgs/development/ocaml-modules/lacaml/default.nix
index b7f5cb44818b0..ab45c9ab8db81 100644
--- a/pkgs/development/ocaml-modules/lacaml/default.nix
+++ b/pkgs/development/ocaml-modules/lacaml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, darwin, buildDunePackage, dune-configurator
+{ lib, stdenv, fetchurl, darwin, buildDunePackage, dune-configurator
 , lapack, blas
 }:
 
@@ -22,7 +22,7 @@ buildDunePackage rec {
     stdenv.lib.optionals stdenv.isDarwin
       [ darwin.apple_sdk.frameworks.Accelerate ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mmottl.github.io/lacaml";
     description = "OCaml bindings for BLAS and LAPACK";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/ocaml-modules/logs/default.nix b/pkgs/development/ocaml-modules/logs/default.nix
index 50d68520fab09..4a88a26d30d84 100644
--- a/pkgs/development/ocaml-modules/logs/default.nix
+++ b/pkgs/development/ocaml-modules/logs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild
 , topkg, result, lwt, cmdliner, fmt }:
 let
   pname = "logs";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   inherit (topkg) installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Logging infrastructure for OCaml";
     homepage = webpage;
     inherit (ocaml.meta) platforms;
diff --git a/pkgs/development/ocaml-modules/macaque/default.nix b/pkgs/development/ocaml-modules/macaque/default.nix
index 32acccd54f280..61ee7ebfe9c54 100644
--- a/pkgs/development/ocaml-modules/macaque/default.nix
+++ b/pkgs/development/ocaml-modules/macaque/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, ocaml, findlib, ocamlbuild, pgocaml, camlp4 }:
+{ lib, stdenv, fetchzip, ocaml, findlib, ocamlbuild, pgocaml, camlp4 }:
 
 stdenv.mkDerivation {
   name = "ocaml-macaque-0.7.2";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Macros for Caml Queries";
     homepage = "https://github.com/ocsigen/macaque";
     license = licenses.lgpl2;
diff --git a/pkgs/development/ocaml-modules/menhir/default.nix b/pkgs/development/ocaml-modules/menhir/default.nix
index 23e31e75779dd..684fd1271aec8 100644
--- a/pkgs/development/ocaml-modules/menhir/default.nix
+++ b/pkgs/development/ocaml-modules/menhir/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild
 , version ? if stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "4.02" then "20190626" else "20140422"
 }@args:
 
diff --git a/pkgs/development/ocaml-modules/menhir/generic.nix b/pkgs/development/ocaml-modules/menhir/generic.nix
index 71561e96cd472..a917d634a19cb 100644
--- a/pkgs/development/ocaml-modules/menhir/generic.nix
+++ b/pkgs/development/ocaml-modules/menhir/generic.nix
@@ -1,4 +1,4 @@
-{ version, src, stdenv, ocaml, findlib, ocamlbuild, ... }:
+{ version, src, lib, stdenv, ocaml, findlib, ocamlbuild, ... }:
 
 stdenv.mkDerivation {
   pname = "menhir";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     export PREFIX=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pauillac.inria.fr/~fpottier/menhir/";
     description = "A LR(1) parser generator for OCaml";
     longDescription = ''
diff --git a/pkgs/development/ocaml-modules/ocaml-libvirt/default.nix b/pkgs/development/ocaml-modules/ocaml-libvirt/default.nix
index dc6cef0bbba1e..63056481199f8 100644
--- a/pkgs/development/ocaml-modules/ocaml-libvirt/default.nix
+++ b/pkgs/development/ocaml-modules/ocaml-libvirt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, libvirt, autoreconfHook, pkg-config, ocaml, findlib, perl }:
+{ lib, stdenv, fetchFromGitLab, libvirt, autoreconfHook, pkg-config, ocaml, findlib, perl }:
 
 stdenv.mkDerivation rec {
   pname = "ocaml-libvirt";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "make install-opt";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OCaml bindings for libvirt";
     homepage = "https://libvirt.org/ocaml/";
     license = licenses.gpl2;
diff --git a/pkgs/development/ocaml-modules/ocaml-syntax-shims/default.nix b/pkgs/development/ocaml-modules/ocaml-syntax-shims/default.nix
index 706dc913e1e65..6f9c8f01e9044 100644
--- a/pkgs/development/ocaml-modules/ocaml-syntax-shims/default.nix
+++ b/pkgs/development/ocaml-modules/ocaml-syntax-shims/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchurl }:
+{ lib, stdenv, buildDunePackage, fetchurl }:
 
 buildDunePackage rec {
   minimumOCamlVersion = "4.02.3";
@@ -15,7 +15,7 @@ buildDunePackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ocaml-ppx/ocaml-syntax-shims";
     description = "Backport new syntax to older OCaml versions";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/ocf/default.nix b/pkgs/development/ocaml-modules/ocf/default.nix
index 7cff7b625b581..c19c9b567a34c 100644
--- a/pkgs/development/ocaml-modules/ocf/default.nix
+++ b/pkgs/development/ocaml-modules/ocf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, ocaml, findlib, ppx_tools, yojson }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, ocaml, findlib, ppx_tools, yojson }:
 
 if stdenv.lib.versionOlder ocaml.version "4.03"
 || stdenv.lib.versionAtLeast ocaml.version "4.08"
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
   })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OCaml library to read and write configuration options in JSON syntax";
     homepage = "https://zoggy.github.io/ocf/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/ocaml-modules/odn/default.nix b/pkgs/development/ocaml-modules/odn/default.nix
index c9e5308f8af4e..645955f27a9ee 100644
--- a/pkgs/development/ocaml-modules/odn/default.nix
+++ b/pkgs/development/ocaml-modules/odn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, type_conv, ounit, camlp4 }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, type_conv, ounit, camlp4 }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "ocaml-data-notation is not available for OCaml ${ocaml.version}"
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
   buildPhase     = "ocaml setup.ml -build";
   installPhase   = "ocaml setup.ml -install";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Store data using OCaml notation";
     homepage = "https://forge.ocamlcore.org/projects/odn/";
     license = licenses.lgpl21;
diff --git a/pkgs/development/ocaml-modules/opti/default.nix b/pkgs/development/ocaml-modules/opti/default.nix
index 82e2378869f64..d229f6284e3dc 100644
--- a/pkgs/development/ocaml-modules/opti/default.nix
+++ b/pkgs/development/ocaml-modules/opti/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildDunePackage }:
+{ lib, stdenv, fetchurl, buildDunePackage }:
 
 buildDunePackage rec {
   pname = "opti";
@@ -11,7 +11,7 @@ buildDunePackage rec {
     sha256 = "ed9ba56dc06e9d2b1bf097964cc65ea37db787d4f239c13d0dd74693f5b50a1e";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DSL to generate fast incremental C code from declarative specifications";
     license = licenses.bsd3;
     maintainers = [ maintainers.jmagnusj ];
diff --git a/pkgs/development/ocaml-modules/otfm/default.nix b/pkgs/development/ocaml-modules/otfm/default.nix
index 8d5bf290c6e09..7f68555da089c 100644
--- a/pkgs/development/ocaml-modules/otfm/default.nix
+++ b/pkgs/development/ocaml-modules/otfm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, uutf, result }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, uutf, result }:
 
 let
   pname = "otfm";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenType font decoder for OCaml";
     longDescription = ''
       Otfm is an in-memory decoder for the OpenType font data format. It
diff --git a/pkgs/development/ocaml-modules/pa_bench/default.nix b/pkgs/development/ocaml-modules/pa_bench/default.nix
index 1027d0fc21abd..c0b859c57a306 100644
--- a/pkgs/development/ocaml-modules/pa_bench/default.nix
+++ b/pkgs/development/ocaml-modules/pa_bench/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcaml, fetchurl, type_conv, pa_ounit}:
+{lib, stdenv, buildOcaml, fetchurl, type_conv, pa_ounit}:
 
 buildOcaml rec {
   name = "pa_bench";
@@ -14,7 +14,7 @@ buildOcaml rec {
   buildInputs = [ pa_ounit ];
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/pa_bench";
     description = "Syntax extension for inline benchmarks";
     license = stdenv.lib.licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/pa_ounit/default.nix b/pkgs/development/ocaml-modules/pa_ounit/default.nix
index 3bd8baac4b764..9d2fa5bac1a86 100644
--- a/pkgs/development/ocaml-modules/pa_ounit/default.nix
+++ b/pkgs/development/ocaml-modules/pa_ounit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildOcaml, ocaml, fetchurl, ounit }:
+{ lib, stdenv, buildOcaml, ocaml, fetchurl, ounit }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "pa_ounit is not available for OCaml ${ocaml.version}"
@@ -15,7 +15,7 @@ buildOcaml rec {
 
   propagatedBuildInputs = [ ounit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/pa_ounit";
     description = "OCaml inline testing";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/parany/default.nix b/pkgs/development/ocaml-modules/parany/default.nix
index 0a4fc9ecea45b..34e14959e327b 100644
--- a/pkgs/development/ocaml-modules/parany/default.nix
+++ b/pkgs/development/ocaml-modules/parany/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchFromGitHub, ocamlnet, cpu }:
+{ lib, stdenv, buildDunePackage, fetchFromGitHub, ocamlnet, cpu }:
 
 buildDunePackage rec {
   pname = "parany";
@@ -13,7 +13,7 @@ buildDunePackage rec {
 
   propagatedBuildInputs = [ ocamlnet cpu ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Generalized map/reduce for multicore computing";
     maintainers = [ maintainers.bcdarwin ];
diff --git a/pkgs/development/ocaml-modules/pcre/default.nix b/pkgs/development/ocaml-modules/pcre/default.nix
index 94af6fce26027..210b7d58857c7 100644
--- a/pkgs/development/ocaml-modules/pcre/default.nix
+++ b/pkgs/development/ocaml-modules/pcre/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pcre, ocaml, findlib, ocamlbuild }:
+{ lib, stdenv, fetchurl, pcre, ocaml, findlib, ocamlbuild }:
 
 stdenv.mkDerivation rec {
   name = "ocaml${ocaml.version}-pcre-${version}";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   dontConfigure = true;	# Skip configure phase
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/mmottl/pcre-ocaml";
     description = "An efficient C-library for pattern matching with Perl-style regular expressions in OCaml";
     license = licenses.lgpl21;
diff --git a/pkgs/development/ocaml-modules/phylogenetics/default.nix b/pkgs/development/ocaml-modules/phylogenetics/default.nix
index 27b6ed3f986bb..d3d6097b4462d 100644
--- a/pkgs/development/ocaml-modules/phylogenetics/default.nix
+++ b/pkgs/development/ocaml-modules/phylogenetics/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildDunePackage, fetchFromGitHub, ppx_deriving
+{ lib, stdenv, buildDunePackage, fetchFromGitHub, ppx_deriving
 , alcotest, angstrom-unix, biocaml, gnuplot, gsl, lacaml, menhir, owl, printbox }:
 
 buildDunePackage rec {
@@ -22,7 +22,7 @@ buildDunePackage rec {
 
   doCheck = false;  # many tests require bppsuite
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Bioinformatics library for Ocaml";
     maintainers = [ maintainers.bcdarwin ];
diff --git a/pkgs/development/ocaml-modules/pipebang/default.nix b/pkgs/development/ocaml-modules/pipebang/default.nix
index f62978c0a9cd3..fdfbfe83e53d9 100644
--- a/pkgs/development/ocaml-modules/pipebang/default.nix
+++ b/pkgs/development/ocaml-modules/pipebang/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcaml, fetchurl}:
+{lib, stdenv, buildOcaml, fetchurl}:
 
 buildOcaml rec {
   name = "pipebang";
@@ -11,7 +11,7 @@ buildOcaml rec {
     sha256 = "0acm2y8wxvnapa248lkgm0vcc44hlwhrjxqkx1awjxzcmarnxhfk";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/pipebang";
     description = "Syntax extension to transform x |! f into f x";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/piqi-ocaml/default.nix b/pkgs/development/ocaml-modules/piqi-ocaml/default.nix
index 39201d0570b34..7203f3702850c 100644
--- a/pkgs/development/ocaml-modules/piqi-ocaml/default.nix
+++ b/pkgs/development/ocaml-modules/piqi-ocaml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, ocaml, findlib, piqi, stdlib-shims }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, ocaml, findlib, piqi, stdlib-shims }:
 
 stdenv.mkDerivation rec {
   version = "0.7.7";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "DESTDIR=$out make install";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://piqi.org";
     description = "Universal schema language and a collection of tools built around it. These are the ocaml bindings";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/piqi/default.nix b/pkgs/development/ocaml-modules/piqi/default.nix
index f3c489723b2f9..bbd7746d36657 100644
--- a/pkgs/development/ocaml-modules/piqi/default.nix
+++ b/pkgs/development/ocaml-modules/piqi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, findlib, which, sedlex_2, easy-format, xmlm, base64 }:
+{ lib, stdenv, fetchFromGitHub, ocaml, findlib, which, sedlex_2, easy-format, xmlm, base64 }:
 
 stdenv.mkDerivation rec {
   version = "0.6.15";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     make ocaml-install;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://piqi.org";
     description = "Universal schema language and a collection of tools built around it";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/pprint/default.nix b/pkgs/development/ocaml-modules/pprint/default.nix
index 0e4f9fea7d928..70193d5b568bd 100644
--- a/pkgs/development/ocaml-modules/pprint/default.nix
+++ b/pkgs/development/ocaml-modules/pprint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild }:
 
 assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
   dontBuild = true;
   installFlags = [ "-C" "src" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gallium.inria.fr/~fpottier/pprint/";
     description = "An OCaml adaptation of Wadler’s and Leijen’s prettier printer";
     license = licenses.cecill-c;
diff --git a/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix b/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix
index 32865bed63163..a5531813c42f6 100644
--- a/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix
+++ b/pkgs/development/ocaml-modules/ppx_gen_rec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildDunePackage, ocaml-migrate-parsetree }:
+{ lib, stdenv, fetchurl, buildDunePackage, ocaml-migrate-parsetree }:
 
 buildDunePackage rec {
   pname = "ppx_gen_rec";
@@ -13,7 +13,7 @@ buildDunePackage rec {
 
   buildInputs = [ ocaml-migrate-parsetree ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/flowtype/ocaml-ppx_gen_rec";
     description = "ocaml preprocessor that generates a recursive module";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/ppx_tools/default.nix b/pkgs/development/ocaml-modules/ppx_tools/default.nix
index 5f3f0916178ae..1427485c5ed37 100644
--- a/pkgs/development/ocaml-modules/ppx_tools/default.nix
+++ b/pkgs/development/ocaml-modules/ppx_tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildDunePackage, ocaml, findlib }:
+{ lib, stdenv, fetchFromGitHub, buildDunePackage, ocaml, findlib }:
 
 let param =
   let v6_2 = {
@@ -39,7 +39,7 @@ let src = fetchFromGitHub {
       inherit (param) sha256;
     };
     pname = "ppx_tools";
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Tools for authors of ppx rewriters";
       homepage = "https://www.lexifi.com/ppx_tools";
       license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/react/default.nix b/pkgs/development/ocaml-modules/react/default.nix
index 02bba95405d55..7ae3e8e66f337 100644
--- a/pkgs/development/ocaml-modules/react/default.nix
+++ b/pkgs/development/ocaml-modules/react/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, topkg, ocamlbuild }:
+{ lib, stdenv, fetchurl, ocaml, findlib, topkg, ocamlbuild }:
 
 stdenv.mkDerivation {
   name = "ocaml-react-1.2.1";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://erratique.ch/software/react";
     description = "Applicative events and signals for OCaml";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/reactivedata/default.nix b/pkgs/development/ocaml-modules/reactivedata/default.nix
index 667c97276045e..1a96c734d85a6 100644
--- a/pkgs/development/ocaml-modules/reactivedata/default.nix
+++ b/pkgs/development/ocaml-modules/reactivedata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, react, opaline }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, react, opaline }:
 
 if !stdenv.lib.versionAtLeast ocaml.version "4.04"
 then throw "reactiveData is not available for OCaml ${ocaml.version}"
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
 
   installPhase = "opaline -prefix $out -libdir $OCAMLFIND_DESTDIR";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml module for functional reactive programming (FRP) based on React";
     homepage = "https://github.com/ocsigen/reactiveData";
     license = licenses.lgpl21;
diff --git a/pkgs/development/ocaml-modules/sawja/default.nix b/pkgs/development/ocaml-modules/sawja/default.nix
index c6cda7d057363..61c3fc8628832 100644
--- a/pkgs/development/ocaml-modules/sawja/default.nix
+++ b/pkgs/development/ocaml-modules/sawja/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which, perl, ocaml, findlib, javalib }:
+{ lib, stdenv, fetchFromGitHub, which, perl, ocaml, findlib, javalib }:
 
 let
   pname = "sawja";
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
 
   propagatedBuildInputs = [ javalib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library written in OCaml, relying on Javalib to provide a high level representation of Java bytecode programs";
     homepage = webpage;
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/ocaml-modules/secp256k1/default.nix b/pkgs/development/ocaml-modules/secp256k1/default.nix
index aab98a9cc6b32..b066b941259ac 100644
--- a/pkgs/development/ocaml-modules/secp256k1/default.nix
+++ b/pkgs/development/ocaml-modules/secp256k1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildDunePackage, base, stdio, dune-configurator, secp256k1 }:
+{ lib, stdenv, fetchFromGitHub, buildDunePackage, base, stdio, dune-configurator, secp256k1 }:
 
 buildDunePackage rec {
   pname = "secp256k1";
@@ -15,7 +15,7 @@ buildDunePackage rec {
 
   buildInputs = [ base stdio dune-configurator secp256k1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dakk/secp256k1-ml";
     description = "Elliptic curve library secp256k1 wrapper for Ocaml";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/sodium/default.nix b/pkgs/development/ocaml-modules/sodium/default.nix
index 5d81545658062..a25145ca49fdb 100644
--- a/pkgs/development/ocaml-modules/sodium/default.nix
+++ b/pkgs/development/ocaml-modules/sodium/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, findlib, ocamlbuild, ctypes, libsodium }:
+{ lib, stdenv, fetchFromGitHub, ocaml, findlib, ocamlbuild, ctypes, libsodium }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.10"
 then throw "sodium is not available for OCaml ${ocaml.version}"
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = stdenv.lib.optional stdenv.isDarwin "strictoverflow";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dsheets/ocaml-sodium";
     description = "Binding to libsodium 1.0.9+";
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/ocaml-modules/sqlite3EZ/default.nix b/pkgs/development/ocaml-modules/sqlite3EZ/default.nix
index a3e26a31a8f92..4fc87ba3d1e42 100644
--- a/pkgs/development/ocaml-modules/sqlite3EZ/default.nix
+++ b/pkgs/development/ocaml-modules/sqlite3EZ/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, twt, ocaml_sqlite3 }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, twt, ocaml_sqlite3 }:
 
 assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12";
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mlin/ocaml-sqlite3EZ";
     description = "A thin wrapper for sqlite3-ocaml with a simplified interface";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/syslog/default.nix b/pkgs/development/ocaml-modules/syslog/default.nix
index 2fa032225e7e3..6ed4fd0b90ebf 100644
--- a/pkgs/development/ocaml-modules/syslog/default.nix
+++ b/pkgs/development/ocaml-modules/syslog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocaml, findlib }:
+{ lib, stdenv, fetchFromGitHub, ocaml, findlib }:
 
 assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "4.03.0";
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rixed/ocaml-syslog";
     description = "Simple wrapper to access the system logger from OCaml";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/ocaml-modules/tsdl/default.nix b/pkgs/development/ocaml-modules/tsdl/default.nix
index f614c476140eb..0dad4f54e0ab4 100644
--- a/pkgs/development/ocaml-modules/tsdl/default.nix
+++ b/pkgs/development/ocaml-modules/tsdl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, ctypes, result, SDL2, pkgconfig, ocb-stubblr }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, ctypes, result, SDL2, pkgconfig, ocb-stubblr }:
 
 if !stdenv.lib.versionAtLeast ocaml.version "4.03"
 then throw "tsdl is not available for OCaml ${ocaml.version}"
@@ -33,7 +33,7 @@ stdenv.mkDerivation {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = webpage;
     description = "Thin bindings to the cross-platform SDL library";
     license = licenses.isc;
diff --git a/pkgs/development/ocaml-modules/twt/default.nix b/pkgs/development/ocaml-modules/twt/default.nix
index 235d04ba99bdf..77635e8848e01 100644
--- a/pkgs/development/ocaml-modules/twt/default.nix
+++ b/pkgs/development/ocaml-modules/twt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, ocaml, findlib }:
+{ lib, stdenv, fetchzip, ocaml, findlib }:
 
 stdenv.mkDerivation {
   name = "ocaml${ocaml.version}-twt-0.94.0";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://people.csail.mit.edu/mikelin/ocaml+twt/";
     description = "“The Whitespace Thing” for OCaml";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/type_conv/108.08.00.nix b/pkgs/development/ocaml-modules/type_conv/108.08.00.nix
index 69439c1c265f0..729313144905c 100644
--- a/pkgs/development/ocaml-modules/type_conv/108.08.00.nix
+++ b/pkgs/development/ocaml-modules/type_conv/108.08.00.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ocaml, findlib, camlp4}:
+{lib, stdenv, fetchurl, ocaml, findlib, camlp4}:
 
 if !stdenv.lib.versionAtLeast ocaml.version "3.12"
 || stdenv.lib.versionAtLeast ocaml.version "4.03"
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ocaml.janestreet.com/";
     description = "Support library for OCaml preprocessor type conversions";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/typerep/default.nix b/pkgs/development/ocaml-modules/typerep/default.nix
index 859bd21b0a7cc..20fd5bcb03c6c 100644
--- a/pkgs/development/ocaml-modules/typerep/default.nix
+++ b/pkgs/development/ocaml-modules/typerep/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildOcaml, fetchurl, type_conv}:
+{lib, stdenv, buildOcaml, fetchurl, type_conv}:
 
 buildOcaml rec {
   name = "typerep";
@@ -13,7 +13,7 @@ buildOcaml rec {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/typerep";
     description = "Runtime types for OCaml (beta version)";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/uucd/default.nix b/pkgs/development/ocaml-modules/uucd/default.nix
index 355b177b204f6..f5d9323361502 100644
--- a/pkgs/development/ocaml-modules/uucd/default.nix
+++ b/pkgs/development/ocaml-modules/uucd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, xmlm, topkg }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, xmlm, topkg }:
 
 let
   pname = "uucd";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = [ xmlm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml module to decode the data of the Unicode character database from its XML representation";
     homepage = webpage;
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/ocaml-modules/uucp/default.nix b/pkgs/development/ocaml-modules/uucp/default.nix
index d657a6f020535..3a0d9f124b1f3 100644
--- a/pkgs/development/ocaml-modules/uucp/default.nix
+++ b/pkgs/development/ocaml-modules/uucp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, uchar, uutf, uunf }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, uchar, uutf, uunf }:
 
 let
   pname = "uucp";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
 
   inherit (topkg) installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml library providing efficient access to a selection of character properties of the Unicode character database";
     homepage = webpage;
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/ocaml-modules/uuidm/default.nix b/pkgs/development/ocaml-modules/uuidm/default.nix
index 399f147bd0d1a..b260a05505bce 100644
--- a/pkgs/development/ocaml-modules/uuidm/default.nix
+++ b/pkgs/development/ocaml-modules/uuidm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, cmdliner }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, cmdliner }:
 
 stdenv.mkDerivation rec {
   version = "0.9.7";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml module implementing 128 bits universally unique identifiers version 3, 5 (name based with MD5, SHA-1 hashing) and 4 (random based) according to RFC 4122";
     homepage = "https://erratique.ch/software/uuidm";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/uunf/default.nix b/pkgs/development/ocaml-modules/uunf/default.nix
index 1d0e5b2bcd948..da4b2a175d7c1 100644
--- a/pkgs/development/ocaml-modules/uunf/default.nix
+++ b/pkgs/development/ocaml-modules/uunf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, ocaml, findlib, ocamlbuild, topkg, uchar, uutf, cmdliner, uucd }:
+{ lib, stdenv, fetchurl, unzip, ocaml, findlib, ocamlbuild, topkg, uchar, uutf, cmdliner, uucd }:
 let
   pname = "uunf";
   webpage = "https://erratique.ch/software/${pname}";
@@ -50,7 +50,7 @@ stdenv.mkDerivation {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml module for normalizing Unicode text";
     homepage = webpage;
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/ocaml-modules/uuseg/default.nix b/pkgs/development/ocaml-modules/uuseg/default.nix
index 8fb9d207576d9..c083f5b68f65e 100644
--- a/pkgs/development/ocaml-modules/uuseg/default.nix
+++ b/pkgs/development/ocaml-modules/uuseg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, uchar, uucp, uutf, cmdliner }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg, uchar, uucp, uutf, cmdliner }:
 
 let
   pname = "uuseg";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml library for segmenting Unicode text";
     homepage = webpage;
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/ocaml-modules/uutf/default.nix b/pkgs/development/ocaml-modules/uutf/default.nix
index f289781b422c9..e8179e369afa0 100644
--- a/pkgs/development/ocaml-modules/uutf/default.nix
+++ b/pkgs/development/ocaml-modules/uutf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, cmdliner , topkg, uchar }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, cmdliner , topkg, uchar }:
 let
   pname = "uutf";
   webpage = "https://erratique.ch/software/${pname}";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Non-blocking streaming Unicode codec for OCaml";
     homepage = webpage;
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/ocaml-modules/variantslib/default.nix b/pkgs/development/ocaml-modules/variantslib/default.nix
index ebb0857e9186d..f26ccdb39a9a6 100644
--- a/pkgs/development/ocaml-modules/variantslib/default.nix
+++ b/pkgs/development/ocaml-modules/variantslib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildOcaml, ocaml, fetchurl, type_conv }:
+{ lib, stdenv, buildOcaml, ocaml, fetchurl, type_conv }:
 
 if stdenv.lib.versionAtLeast ocaml.version "4.06"
 then throw "variantslib-109.15.03 is not available for OCaml ${ocaml.version}"
@@ -17,7 +17,7 @@ buildOcaml rec {
 
   propagatedBuildInputs = [ type_conv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/janestreet/variantslib";
     description = "OCaml variants as first class values";
     license = licenses.asl20;
diff --git a/pkgs/development/ocaml-modules/wtf8/default.nix b/pkgs/development/ocaml-modules/wtf8/default.nix
index ea09b326d3933..b46386b1666f2 100644
--- a/pkgs/development/ocaml-modules/wtf8/default.nix
+++ b/pkgs/development/ocaml-modules/wtf8/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildDunePackage }:
+{ lib, stdenv, fetchurl, buildDunePackage }:
 
 buildDunePackage rec {
   pname = "wtf8";
@@ -11,7 +11,7 @@ buildDunePackage rec {
     sha256 = "09ygcxxd5warkdzz17rgpidrd0pg14cy2svvnvy1hna080lzg7vp";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/flowtype/ocaml-wtf8";
     description = "WTF-8 is a superset of UTF-8 that allows unpaired surrogates.";
     license = licenses.mit;
diff --git a/pkgs/development/ocaml-modules/xmlm/default.nix b/pkgs/development/ocaml-modules/xmlm/default.nix
index bb05b89d7befe..d1945ea7859a9 100644
--- a/pkgs/development/ocaml-modules/xmlm/default.nix
+++ b/pkgs/development/ocaml-modules/xmlm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg }:
+{ lib, stdenv, fetchurl, ocaml, findlib, ocamlbuild, topkg }:
 let
   pname = "xmlm";
   webpage = "https://erratique.ch/software/${pname}";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   inherit (topkg) buildPhase installPhase;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OCaml streaming codec to decode and encode the XML data format";
     homepage = webpage;
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/ocaml-modules/xtmpl/default.nix b/pkgs/development/ocaml-modules/xtmpl/default.nix
index 31c671538a58a..50a3eeadec876 100644
--- a/pkgs/development/ocaml-modules/xtmpl/default.nix
+++ b/pkgs/development/ocaml-modules/xtmpl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, ocaml, findlib, iri, ppx_tools, js_of_ocaml
+{ lib, stdenv, fetchFromGitLab, ocaml, findlib, iri, ppx_tools, js_of_ocaml
 , js_of_ocaml-ppx, re }:
 
 if stdenv.lib.versionOlder ocaml.version "4.03"
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XML templating library for OCaml";
     homepage = "https://www.good-eris.net/xtmpl/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/ocaml-modules/yojson/default.nix b/pkgs/development/ocaml-modules/yojson/default.nix
index dca97a53cbfb6..21c9a6d19ce86 100644
--- a/pkgs/development/ocaml-modules/yojson/default.nix
+++ b/pkgs/development/ocaml-modules/yojson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, ocaml, findlib, dune, cppo, easy-format, biniou }:
+{ lib, stdenv, fetchzip, ocaml, findlib, dune, cppo, easy-format, biniou }:
 let
   pname = "yojson";
   param =
@@ -34,7 +34,7 @@ stdenv.mkDerivation ({
   propagatedBuildInputs = [ easy-format biniou ];
   configurePlatforms = [];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An optimized parsing and printing library for the JSON format";
     homepage = "https://github.com/ocaml-community/${pname}";
     license = licenses.bsd3;
diff --git a/pkgs/development/ocaml-modules/zarith/default.nix b/pkgs/development/ocaml-modules/zarith/default.nix
index 175004c71bba0..364d76f40fae0 100644
--- a/pkgs/development/ocaml-modules/zarith/default.nix
+++ b/pkgs/development/ocaml-modules/zarith/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , ocaml, findlib, pkgconfig, perl
 , gmp
 }:
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   preInstall = "mkdir -p $out/lib/ocaml/${ocaml.version}/site-lib/stublibs";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, arbitrary precision OCaml integers";
     homepage    = "http://forge.ocamlcore.org/projects/zarith";
     license     = licenses.lgpl2;
diff --git a/pkgs/development/perl-modules/MNI/default.nix b/pkgs/development/perl-modules/MNI/default.nix
index 7057883e6373a..c0fc8f2810856 100644
--- a/pkgs/development/perl-modules/MNI/default.nix
+++ b/pkgs/development/perl-modules/MNI/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, buildPerlPackage, stdenv }:
+{ fetchFromGitHub, buildPerlPackage, lib, stdenv }:
 
 buildPerlPackage {
   pname = "MNI-Perllib";
@@ -15,7 +15,7 @@ buildPerlPackage {
 
   doCheck = false;  # TODO: almost all tests fail ... is this a real problem?
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BIC-MNI/mni-perllib";
     license = with licenses; [ artistic1 gpl1Plus ];
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/development/perl-modules/Percona-Toolkit/default.nix b/pkgs/development/perl-modules/Percona-Toolkit/default.nix
index b2c5437e38054..85a11aaed46b6 100644
--- a/pkgs/development/perl-modules/Percona-Toolkit/default.nix
+++ b/pkgs/development/perl-modules/Percona-Toolkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPerlPackage, shortenPerlShebang
+{ lib, stdenv, fetchFromGitHub, buildPerlPackage, shortenPerlShebang
 , DBDmysql, DBI, IOSocketSSL, TermReadKey
 }:
 
@@ -23,7 +23,7 @@ buildPerlPackage rec {
     shortenPerlShebang $(grep -l "/bin/env perl" $out/bin/*)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''Collection of advanced command-line tools to perform a variety of MySQL and system tasks.'';
     homepage = "https://www.percona.com/software/database-tools/percona-toolkit";
     license = with licenses; [ gpl2 ];
diff --git a/pkgs/development/perl-modules/strip-nondeterminism/default.nix b/pkgs/development/perl-modules/strip-nondeterminism/default.nix
index 3557ed68cec6f..80e81cad74d16 100644
--- a/pkgs/development/perl-modules/strip-nondeterminism/default.nix
+++ b/pkgs/development/perl-modules/strip-nondeterminism/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, file, fetchFromGitLab, buildPerlPackage, ArchiveZip, ArchiveCpio, shortenPerlShebang }:
+{ lib, stdenv, file, fetchFromGitLab, buildPerlPackage, ArchiveZip, ArchiveCpio, shortenPerlShebang }:
 
 buildPerlPackage rec {
   pname = "strip-nondeterminism";
@@ -30,7 +30,7 @@ buildPerlPackage rec {
     shortenPerlShebang $out/bin/strip-nondeterminism
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Perl module for stripping bits of non-deterministic information";
     homepage = "https://reproducible-builds.org/";
     license = licenses.gpl3;
diff --git a/pkgs/development/pharo/launcher/default.nix b/pkgs/development/pharo/launcher/default.nix
index 1737fb90c7ac6..45531b551761c 100644
--- a/pkgs/development/pharo/launcher/default.nix
+++ b/pkgs/development/pharo/launcher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bash, pharo, unzip, makeDesktopItem }:
+{ lib, stdenv, fetchurl, bash, pharo, unzip, makeDesktopItem }:
 
 stdenv.mkDerivation rec {
   version = "2017.02.28";
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
      test "$?" == 124 && echo "ok")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Launcher for Pharo distributions";
     homepage = "https://pharo.org";
     longDescription = ''
diff --git a/pkgs/development/pharo/vm/build-vm-legacy.nix b/pkgs/development/pharo/vm/build-vm-legacy.nix
index 13db30eae9098..d85dab861e7da 100644
--- a/pkgs/development/pharo/vm/build-vm-legacy.nix
+++ b/pkgs/development/pharo/vm/build-vm-legacy.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cmake
 , bash
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
     ln -s "${pharo-share}/lib/"*.sources $prefix/lib/$name
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clean and innovative Smalltalk-inspired environment";
     homepage = "https://pharo.org";
     longDescription = ''
diff --git a/pkgs/development/pharo/vm/build-vm.nix b/pkgs/development/pharo/vm/build-vm.nix
index d5469233f387f..28525ac475e6a 100644
--- a/pkgs/development/pharo/vm/build-vm.nix
+++ b/pkgs/development/pharo/vm/build-vm.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , bash
 , unzip
@@ -150,7 +150,7 @@ stdenv.mkDerivation rec {
     ln -s ${libgit2}/lib/libgit2.so* "$out/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clean and innovative Smalltalk-inspired environment";
     homepage = "https://pharo.org";
     longDescription = ''
diff --git a/pkgs/development/pharo/vm/vms.nix b/pkgs/development/pharo/vm/vms.nix
index 7b96b5a913985..77bc5b0682fba 100644
--- a/pkgs/development/pharo/vm/vms.nix
+++ b/pkgs/development/pharo/vm/vms.nix
@@ -1,4 +1,5 @@
 { cmake
+, lib
 , stdenv
 , fetchurl
 , bash
diff --git a/pkgs/development/python-modules/FormEncode/default.nix b/pkgs/development/python-modules/FormEncode/default.nix
index d91bef07d2aea..2b06fcdce7d26 100644
--- a/pkgs/development/python-modules/FormEncode/default.nix
+++ b/pkgs/development/python-modules/FormEncode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, dnspython, pycountry, nose, setuptools_scm, six, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, dnspython, pycountry, nose, setuptools_scm, six, isPy27 }:
 
 buildPythonPackage rec {
   pname = "FormEncode";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     sed -i 's/test_unicode_ascii_subgroup/noop/' formencode/tests/test_email.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FormEncode validates and converts nested structures";
     homepage = "http://formencode.org";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/HTSeq/default.nix b/pkgs/development/python-modules/HTSeq/default.nix
index 83263f734bd45..178b6a7b85cd4 100644
--- a/pkgs/development/python-modules/HTSeq/default.nix
+++ b/pkgs/development/python-modules/HTSeq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, cython, numpy, pysam, matplotlib, python, isPy27, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, cython, numpy, pysam, matplotlib, python, isPy27, isPy3k }:
 buildPythonPackage rec {
   version = "0.12.4";
   pname = "HTSeq";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     ${python.interpreter} python3/test/test_general.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://htseq.readthedocs.io/";
     description = "A framework to work with high-throughput sequencing data";
     maintainers = with maintainers; [ unode ];
diff --git a/pkgs/development/python-modules/IPy/default.nix b/pkgs/development/python-modules/IPy/default.nix
index 332ee0fc0c133..f142c24592237 100644
--- a/pkgs/development/python-modules/IPy/default.nix
+++ b/pkgs/development/python-modules/IPy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, nose }:
 
 buildPythonPackage rec {
   pname = "IPy";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     nosetests -e fuzz
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Class and tools for handling of IPv4 and IPv6 addresses and networks";
     homepage = "https://github.com/autocracy/python-ipy";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/PyLD/default.nix b/pkgs/development/python-modules/PyLD/default.nix
index 1c7bc2ff93fb6..247b7f0332f5a 100644
--- a/pkgs/development/python-modules/PyLD/default.nix
+++ b/pkgs/development/python-modules/PyLD/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python, requests, gnugrep }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python, requests, gnugrep }:
 
 let
 
@@ -48,7 +48,7 @@ buildPythonPackage rec {
     ${python.interpreter} tests/runtests.py -d ${normalization}/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python implementation of the JSON-LD API";
     homepage = "https://github.com/digitalbazaar/pyld";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/ROPGadget/default.nix b/pkgs/development/python-modules/ROPGadget/default.nix
index c3c67194ebb74..19280bf03c2bb 100644
--- a/pkgs/development/python-modules/ROPGadget/default.nix
+++ b/pkgs/development/python-modules/ROPGadget/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , capstone}:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ capstone ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to search for gadgets in binaries to facilitate ROP exploitation";
     homepage = "http://shell-storm.org/project/ROPgadget/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/Rtree/default.nix b/pkgs/development/python-modules/Rtree/default.nix
index 9adfbb67e62dc..82c8ced9704b2 100644
--- a/pkgs/development/python-modules/Rtree/default.nix
+++ b/pkgs/development/python-modules/Rtree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, libspatialindex, numpy }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, libspatialindex, numpy }:
 
 buildPythonPackage rec {
   pname = "Rtree";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   doCheck = false;
   checkInputs = [ numpy ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "R-Tree spatial index for Python GIS";
     homepage = "https://toblerity.org/rtree/";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/Theano/default.nix b/pkgs/development/python-modules/Theano/default.nix
index ce32e42e4716f..c2dd7460b133a 100644
--- a/pkgs/development/python-modules/Theano/default.nix
+++ b/pkgs/development/python-modules/Theano/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , runCommandCC
 , fetchPypi
 , buildPythonPackage
@@ -85,7 +85,7 @@ in buildPythonPackage rec {
 
   pythonImportsCheck = [ "theano" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://deeplearning.net/software/theano/";
     description = "A Python library for large-scale array computation";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/Wand/default.nix b/pkgs/development/python-modules/Wand/default.nix
index c897b04e880c8..d7ad28c013361 100644
--- a/pkgs/development/python-modules/Wand/default.nix
+++ b/pkgs/development/python-modules/Wand/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , imagemagick7Big
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   passthru.imagemagick = imagemagick7Big;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ctypes-based simple MagickWand API binding for Python";
     homepage = "http://wand-py.org/";
     license = [ licenses.mit ];
diff --git a/pkgs/development/python-modules/WazeRouteCalculator/default.nix b/pkgs/development/python-modules/WazeRouteCalculator/default.nix
index 02519e9dc66b4..28515e6f6028c 100644
--- a/pkgs/development/python-modules/WazeRouteCalculator/default.nix
+++ b/pkgs/development/python-modules/WazeRouteCalculator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , requests }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # there are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calculate actual route time and distance with Waze API";
     homepage = "https://github.com/kovacsbalu/WazeRouteCalculator";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/aadict/default.nix b/pkgs/development/python-modules/aadict/default.nix
index 2587260748f0e..cf6976fa6c1ed 100644
--- a/pkgs/development/python-modules/aadict/default.nix
+++ b/pkgs/development/python-modules/aadict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ six ];
   checkInputs = [ nose coverage ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/metagriffin/aadict";
     description = "An auto-attribute dict (and a couple of other useful dict functions).";
     maintainers = with maintainers; [ glittershark ];
diff --git a/pkgs/development/python-modules/aafigure/default.nix b/pkgs/development/python-modules/aafigure/default.nix
index ed07a60e0a892..5350443eeaabd 100644
--- a/pkgs/development/python-modules/aafigure/default.nix
+++ b/pkgs/development/python-modules/aafigure/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pillow }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pillow }:
 
 buildPythonPackage rec {
   pname = "aafigure";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     sed -i "s|/usr/share/fonts|/nonexisting-fonts-path|" aafigure/PILhelper.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ASCII art to image converter";
     homepage = "https://launchpad.net/aafigure/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/acebinf/default.nix b/pkgs/development/python-modules/acebinf/default.nix
index 78810de1740df..f8134aaf5b315 100644
--- a/pkgs/development/python-modules/acebinf/default.nix
+++ b/pkgs/development/python-modules/acebinf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyvcf
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "acebinf" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ACEnglish/acebinf";
     description = "Collection of simple utilities used when building bioinformatics tools";
     license = licenses.unlicense;
diff --git a/pkgs/development/python-modules/acme-tiny/default.nix b/pkgs/development/python-modules/acme-tiny/default.nix
index b9bc11a34c721..75408244e66ab 100644
--- a/pkgs/development/python-modules/acme-tiny/default.nix
+++ b/pkgs/development/python-modules/acme-tiny/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm, fusepy, fuse
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm, fusepy, fuse
 , openssl }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   doCheck = false; # seems to hang, not sure
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiny script to issue and renew TLS certs from Let's Encrypt";
     homepage = "https://github.com/diafygi/acme-tiny";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/actdiag/default.nix b/pkgs/development/python-modules/actdiag/default.nix
index 84aef2dfb03d9..ca47018f56f4d 100644
--- a/pkgs/development/python-modules/actdiag/default.nix
+++ b/pkgs/development/python-modules/actdiag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose, docutils, blockdiag, reportlab }:
 
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose reportlab ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate activity-diagram image from spec-text file (similar to Graphviz)";
     homepage = "http://blockdiag.com/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/adal/default.nix b/pkgs/development/python-modules/adal/default.nix
index 0df7247986d01..f7e973c8f6932 100644
--- a/pkgs/development/python-modules/adal/default.nix
+++ b/pkgs/development/python-modules/adal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , requests, pyjwt, dateutil }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs =  [ requests pyjwt dateutil ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library to make it easy for python application to authenticate to Azure Active Directory (AAD) in order to access AAD protected web resources";
     homepage = "https://github.com/AzureAD/azure-activedirectory-library-for-python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/afdko/default.nix b/pkgs/development/python-modules/afdko/default.nix
index 6371fa804bb0c..4df6c5f6c4931 100644
--- a/pkgs/development/python-modules/afdko/default.nix
+++ b/pkgs/development/python-modules/afdko/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, pythonOlder, python
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, pythonOlder, python
 , fonttools, defcon, lxml, fs, unicodedata2, zopfli, brotlipy, fontpens
 , brotli, fontmath, mutatormath, booleanoperations
 , ufoprocessor, ufonormalizer, psautohint, tqdm
@@ -65,7 +65,7 @@ buildPythonPackage rec {
     "test_options"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adobe Font Development Kit for OpenType";
     homepage = "https://adobe-type-tools.github.io/afdko/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/agate-dbf/default.nix b/pkgs/development/python-modules/agate-dbf/default.nix
index 09556ea891b32..099fb1701cb4c 100644
--- a/pkgs/development/python-modules/agate-dbf/default.nix
+++ b/pkgs/development/python-modules/agate-dbf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, agate, dbf, dbfread }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, agate, dbf, dbfread }:
 
 buildPythonPackage rec {
     pname = "agate-dbf";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
       sha256 = "589682b78c5c03f2dc8511e6e3edb659fb7336cd118e248896bb0b44c2f1917b";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Adds read support for dbf files to agate";
       homepage    = "https://github.com/wireservice/agate-dbf";
       license     = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/agate-sql/default.nix b/pkgs/development/python-modules/agate-sql/default.nix
index 08516d05f002d..566951ea71d14 100644
--- a/pkgs/development/python-modules/agate-sql/default.nix
+++ b/pkgs/development/python-modules/agate-sql/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, agate, sqlalchemy, crate }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, agate, sqlalchemy, crate }:
 
 buildPythonPackage rec {
     pname = "agate-sql";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
     propagatedBuildInputs = [ agate sqlalchemy crate ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Adds SQL read/write support to agate.";
       homepage    = "https://github.com/wireservice/agate-sql";
       license     = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/aiodns/default.nix b/pkgs/development/python-modules/aiodns/default.nix
index 694f92577cbb4..e1130331365cd 100644
--- a/pkgs/development/python-modules/aiodns/default.nix
+++ b/pkgs/development/python-modules/aiodns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , isPy27, isPyPy, python, pycares, typing, trollius }:
 
 buildPythonPackage rec {
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # 'Could not contact DNS servers'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/saghul/aiodns";
     license = licenses.mit;
     description = "Simple DNS resolver for asyncio";
diff --git a/pkgs/development/python-modules/aioeventlet/default.nix b/pkgs/development/python-modules/aioeventlet/default.nix
index 0582a59eae877..4bdd2b1327cd7 100644
--- a/pkgs/development/python-modules/aioeventlet/default.nix
+++ b/pkgs/development/python-modules/aioeventlet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , eventlet
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ${python.interpreter} runtests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "aioeventlet implements the asyncio API (PEP 3156) on top of eventlet. It makes";
     homepage = "https://pypi.org/project/aioeventlet/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/aioredis/default.nix b/pkgs/development/python-modules/aioredis/default.nix
index a199878fc216c..2e59168157beb 100644
--- a/pkgs/development/python-modules/aioredis/default.nix
+++ b/pkgs/development/python-modules/aioredis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pkgs, async-timeout, hiredis, isPyPy, isPy27
 }:
 
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Wants to run redis-server, hardcoded FHS paths, too much trouble.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Asyncio (PEP 3156) Redis client library";
     homepage = "https://github.com/aio-libs/aioredis";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/aiozeroconf/default.nix b/pkgs/development/python-modules/aiozeroconf/default.nix
index b89ba73b0d645..d73ae2b35dfbc 100644
--- a/pkgs/development/python-modules/aiozeroconf/default.nix
+++ b/pkgs/development/python-modules/aiozeroconf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , netifaces
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ netifaces ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure python implementation of multicast DNS service discovery";
     homepage = "https://github.com/jstasiak/python-zeroconf";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/ajpy/default.nix b/pkgs/development/python-modules/ajpy/default.nix
index 5f42646dd9982..0dd135e139fd1 100644
--- a/pkgs/development/python-modules/ajpy/default.nix
+++ b/pkgs/development/python-modules/ajpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "ajpy";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # ajpy doesn't have tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AJP package crafting library";
     homepage = "https://github.com/hypn0s/AJPy/";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/alabaster/default.nix b/pkgs/development/python-modules/alabaster/default.nix
index d54741b63ea2c..b4cc69e555bcc 100644
--- a/pkgs/development/python-modules/alabaster/default.nix
+++ b/pkgs/development/python-modules/alabaster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pygments }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bitprophet/alabaster";
     description = "A Sphinx theme";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/alarmdecoder/default.nix b/pkgs/development/python-modules/alarmdecoder/default.nix
index ef8b74bb9d71a..b563a80447f25 100644
--- a/pkgs/development/python-modules/alarmdecoder/default.nix
+++ b/pkgs/development/python-modules/alarmdecoder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pyserial, pyftdi, pyusb
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pyserial, pyftdi, pyusb
 , pyopenssl, nose, isPy3k, pythonOlder, mock }:
 
 buildPythonPackage rec {
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   checkInputs = [ nose mock ];
   pythonImportsCheck = [ "alarmdecoder" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nutechsoftware/alarmdecoder";
     description =
       "Python interface for the Alarm Decoder (AD2) family of alarm devices. (AD2USB, AD2SERIAL and AD2PI)";
diff --git a/pkgs/development/python-modules/alembic/default.nix b/pkgs/development/python-modules/alembic/default.nix
index 4061dca8aa28a..142c6d1c416c7 100644
--- a/pkgs/development/python-modules/alembic/default.nix
+++ b/pkgs/development/python-modules/alembic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, pytestcov, mock, coverage, setuptools
 , Mako, sqlalchemy, python-editor, dateutil
 }:
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # no traditional test suite
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/zzzeek/alembic";
     description = "A database migration tool for SQLAlchemy";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/alerta-server/default.nix b/pkgs/development/python-modules/alerta-server/default.nix
index f8a3b96848051..ce1e702a7bacc 100644
--- a/pkgs/development/python-modules/alerta-server/default.nix
+++ b/pkgs/development/python-modules/alerta-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , bcrypt, blinker, flask, flask-compress, flask-cors, mohawk, psycopg2, pyjwt, pymongo, python-dateutil, pytz, pyyaml, requests, requests-hawk, sentry-sdk
 }:
 
@@ -37,7 +37,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.5";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://alerta.io";
     description = "Alerta Monitoring System server";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/alerta/default.nix b/pkgs/development/python-modules/alerta/default.nix
index c8007566328a9..19dd17ee3f023 100644
--- a/pkgs/development/python-modules/alerta/default.nix
+++ b/pkgs/development/python-modules/alerta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , six, click, requests, requests-hawk, pytz, tabulate, pythonOlder
 }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.5";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://alerta.io";
     description = "Alerta Monitoring System command-line interface";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/alot/default.nix b/pkgs/development/python-modules/alot/default.nix
index c3b624a7bceda..21c6aaff2fbc4 100644
--- a/pkgs/development/python-modules/alot/default.nix
+++ b/pkgs/development/python-modules/alot/default.nix
@@ -60,7 +60,7 @@ buildPythonPackage rec {
     sed "s,/usr/bin,$out/bin,g" extra/alot.desktop > $out/share/applications/alot.desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pazz/alot";
     description = "Terminal MUA using notmuch mail";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/altair/default.nix b/pkgs/development/python-modules/altair/default.nix
index f5076953bf200..018ac7ddf501d 100644
--- a/pkgs/development/python-modules/altair/default.nix
+++ b/pkgs/development/python-modules/altair/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27
 , entrypoints
 , glibcLocales
 , ipython
@@ -52,7 +52,7 @@ buildPythonPackage rec {
     pytest --doctest-modules altair
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A declarative statistical visualization library for Python.";
     homepage = "https://github.com/altair-viz/altair";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/amazon_kclpy/default.nix b/pkgs/development/python-modules/amazon_kclpy/default.nix
index bfce45ae206c6..ed266c0db7887 100644
--- a/pkgs/development/python-modules/amazon_kclpy/default.nix
+++ b/pkgs/development/python-modules/amazon_kclpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python, mock, boto, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python, mock, boto, pytest }:
 
 buildPythonPackage rec {
   pname = "amazon_kclpy";
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Amazon Kinesis Client Library for Python";
     homepage = "https://github.com/awslabs/amazon-kinesis-client-python";
     license = licenses.amazonsl;
diff --git a/pkgs/development/python-modules/amply/default.nix b/pkgs/development/python-modules/amply/default.nix
index 1962d004f41bd..32bcbb4589ab9 100644
--- a/pkgs/development/python-modules/amply/default.nix
+++ b/pkgs/development/python-modules/amply/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , setuptools_scm
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "amply" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/willu47/amply";
     description = ''
       Allows you to load and manipulate AMPL/GLPK data as Python data structures
diff --git a/pkgs/development/python-modules/amqp/default.nix b/pkgs/development/python-modules/amqp/default.nix
index 12dc1eca2a31a..75a4f8d6e120c 100644
--- a/pkgs/development/python-modules/amqp/default.nix
+++ b/pkgs/development/python-modules/amqp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytestCheckHook, case, vine }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytestCheckHook, case, vine }:
 
 buildPythonPackage rec {
   pname = "amqp";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     "test_rmq.py" # requires network access
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/celery/py-amqp";
     description = "Python client for the Advanced Message Queuing Procotol (AMQP). This is a fork of amqplib which is maintained by the Celery project";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/amqplib/default.nix b/pkgs/development/python-modules/amqplib/default.nix
index a3e11271ade25..c7b4dc865bb8a 100644
--- a/pkgs/development/python-modules/amqplib/default.nix
+++ b/pkgs/development/python-modules/amqplib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, python }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, python }:
 
 buildPythonPackage rec {
   pname = "amqplib";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     ${python.interpreter} tests/client_0_8/run_all.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/barryp/py-amqplib";
     description = "Python client for the Advanced Message Queuing Procotol (AMQP)";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/aniso8601/default.nix b/pkgs/development/python-modules/aniso8601/default.nix
index 97e79e4e8eb7c..c6c05283f280c 100644
--- a/pkgs/development/python-modules/aniso8601/default.nix
+++ b/pkgs/development/python-modules/aniso8601/default.nix
@@ -1,11 +1,11 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , dateutil, mock, isPy3k }:
 
 buildPythonPackage rec {
   pname = "aniso8601";
   version = "8.1.0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parses ISO 8601 strings.";
     homepage    = "https://bitbucket.org/nielsenb/aniso8601";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/annoy/default.nix b/pkgs/development/python-modules/annoy/default.nix
index 138c70a384837..0bd060843809a 100644
--- a/pkgs/development/python-modules/annoy/default.nix
+++ b/pkgs/development/python-modules/annoy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , h5py
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     nose
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Approximate Nearest Neighbors in C++/Python optimized for memory usage and loading/saving to disk";
     homepage = "https://github.com/spotify/annoy";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/anonip/default.nix b/pkgs/development/python-modules/anonip/default.nix
index de9048bde343f..9c1b3abf9800f 100644
--- a/pkgs/development/python-modules/anonip/default.nix
+++ b/pkgs/development/python-modules/anonip/default.nix
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   checkPhase = "python tests.py";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/DigitaleGesellschaft/Anonip";
     description = "A tool to anonymize IP-addresses in log-files";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/ansicolor/default.nix b/pkgs/development/python-modules/ansicolor/default.nix
index f9d589e43696f..3d96061362e9f 100644
--- a/pkgs/development/python-modules/ansicolor/default.nix
+++ b/pkgs/development/python-modules/ansicolor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "ansicolor";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "d17e1b07b9dd7ded31699fbca53ae6cd373584f9b6dcbc124d1f321ebad31f1d";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/numerodix/ansicolor/";
     description = "A library to produce ansi color output and colored highlighting and diffing";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ansicolors/default.nix b/pkgs/development/python-modules/ansicolors/default.nix
index 3ea77384c7970..7d6dd2127e675 100644
--- a/pkgs/development/python-modules/ansicolors/default.nix
+++ b/pkgs/development/python-modules/ansicolors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "ansicolors";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/verigak/colors/";
     description = "ANSI colors for Python";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/ansiconv/default.nix b/pkgs/development/python-modules/ansiconv/default.nix
index d2de4837e07a1..6a3571960d03b 100644
--- a/pkgs/development/python-modules/ansiconv/default.nix
+++ b/pkgs/development/python-modules/ansiconv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pytest }:
 
 buildPythonPackage rec {
   pname = "ansiconv";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A module for converting ANSI coded text and converts it to either plain text or HTML";
     homepage = "https://github.com/ansible/ansiconv";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/apipkg/default.nix b/pkgs/development/python-modules/apipkg/default.nix
index 22bddb252c8e3..88535bb7cf1e0 100644
--- a/pkgs/development/python-modules/apipkg/default.nix
+++ b/pkgs/development/python-modules/apipkg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, setuptools_scm, isPy3k }:
 
 buildPythonPackage rec {
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     py.test ${testExpression}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Namespace control and lazy-import mechanism";
     homepage = "https://github.com/pytest-dev/apipkg";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/approvaltests/default.nix b/pkgs/development/python-modules/approvaltests/default.nix
index a7b0b51d8f1ce..bc47de371288f 100644
--- a/pkgs/development/python-modules/approvaltests/default.nix
+++ b/pkgs/development/python-modules/approvaltests/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy37, pyperclip }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy37, pyperclip }:
 
 buildPythonPackage rec {
   version = "0.2.6";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
       --replace "pyperclip==1.5.27" "pyperclip>=1.5.27"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Assertion/verification library to aid testing";
     homepage = "https://github.com/approvals/ApprovalTests.Python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/apsw/default.nix b/pkgs/development/python-modules/apsw/default.nix
index 1f314dc7408aa..de74480765a0e 100644
--- a/pkgs/development/python-modules/apsw/default.nix
+++ b/pkgs/development/python-modules/apsw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch
 , sqlite, isPyPy }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   buildInputs = [ sqlite ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python wrapper for the SQLite embedded relational database engine";
     homepage = "https://github.com/rogerbinns/apsw";
     license = licenses.zlib;
diff --git a/pkgs/development/python-modules/argh/default.nix b/pkgs/development/python-modules/argh/default.nix
index 544a66c058214..0e2beb6a31eb9 100644
--- a/pkgs/development/python-modules/argh/default.nix
+++ b/pkgs/development/python-modules/argh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/neithere/argh/";
     description = "An unobtrusive argparse wrapper with natural syntax";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/args/default.nix b/pkgs/development/python-modules/args/default.nix
index ae66713361c2b..cb349484f2769 100644
--- a/pkgs/development/python-modules/args/default.nix
+++ b/pkgs/development/python-modules/args/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "args";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "a785b8d837625e9b61c39108532d95b85274acd679693b71ebb5156848fcf814";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command Arguments for Humans";
     homepage = "https://github.com/kennethreitz/args";
   };
diff --git a/pkgs/development/python-modules/aria2p/default.nix b/pkgs/development/python-modules/aria2p/default.nix
index a7d8221d78ef6..076fec8c56baf 100644
--- a/pkgs/development/python-modules/aria2p/default.nix
+++ b/pkgs/development/python-modules/aria2p/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
 , aria2, poetry, pytest, pytestcov, pytest_xdist, responses
 , asciimatics, loguru, requests, setuptools, websocket_client
 }:
@@ -34,7 +34,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ asciimatics loguru requests setuptools websocket_client ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pawamoy/aria2p";
     description = "Command-line tool and library to interact with an aria2c daemon process with JSON-RPC";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/asana/default.nix b/pkgs/development/python-modules/asana/default.nix
index 71c003ef9b0a9..ed5e441df9706 100644
--- a/pkgs/development/python-modules/asana/default.nix
+++ b/pkgs/development/python-modules/asana/default.nix
@@ -1,5 +1,5 @@
 { buildPythonPackage, pythonAtLeast, pytest, requests, requests_oauthlib, six
-, fetchFromGitHub, responses, stdenv
+, fetchFromGitHub, responses, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client library for Asana";
     homepage = "https://github.com/asana/python-asana";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/asgi-csrf/default.nix b/pkgs/development/python-modules/asgi-csrf/default.nix
index e838ec787c319..eabb3d525cae9 100644
--- a/pkgs/development/python-modules/asgi-csrf/default.nix
+++ b/pkgs/development/python-modules/asgi-csrf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy27, fetchFromGitHub, itsdangerous, python-multipart
+{ lib, stdenv, buildPythonPackage, isPy27, fetchFromGitHub, itsdangerous, python-multipart
 , pytestCheckHook, starlette, httpx, pytest-asyncio }:
 
 buildPythonPackage rec {
@@ -33,7 +33,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "asgi_csrf" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ASGI middleware for protecting against CSRF attacks";
     license = licenses.asl20;
     homepage = "https://github.com/simonw/asgi-csrf";
diff --git a/pkgs/development/python-modules/asgiref/default.nix b/pkgs/development/python-modules/asgiref/default.nix
index a14c294bf6822..ec630c40d0347 100644
--- a/pkgs/development/python-modules/asgiref/default.nix
+++ b/pkgs/development/python-modules/asgiref/default.nix
@@ -32,7 +32,7 @@ buildPythonPackage rec {
     "test_multiprocessing"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reference ASGI adapters and channel layers";
     license = licenses.bsd3;
     homepage = "https://github.com/django/asgiref";
diff --git a/pkgs/development/python-modules/asn1ate/default.nix b/pkgs/development/python-modules/asn1ate/default.nix
index 6af5b3da88089..2735bbf2f70f5 100644
--- a/pkgs/development/python-modules/asn1ate/default.nix
+++ b/pkgs/development/python-modules/asn1ate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pyparsing }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pyparsing }:
 
 buildPythonPackage rec {
   pname = "asn1ate";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyparsing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for translating ASN.1 into other forms";
     license = licenses.bsd3;
     platforms = platforms.unix;
diff --git a/pkgs/development/python-modules/astral/default.nix b/pkgs/development/python-modules/astral/default.nix
index 6c4afec6352ec..4ea53e17eb0e4 100644
--- a/pkgs/development/python-modules/astral/default.nix
+++ b/pkgs/development/python-modules/astral/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, pytz, requests, pytest, freezegun }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, pytz, requests, pytest, freezegun }:
 
 buildPythonPackage rec {
   pname = "astral";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     py.test -m "not webtest"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calculations for the position of the sun and the moon";
     homepage = "https://github.com/sffjunkie/astral/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/astunparse/default.nix b/pkgs/development/python-modules/astunparse/default.nix
index 0947b3877b5ed..c9001da5c70f7 100644
--- a/pkgs/development/python-modules/astunparse/default.nix
+++ b/pkgs/development/python-modules/astunparse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , six
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # tests not included with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This is a factored out version of unparse found in the Python source distribution";
     homepage = "https://github.com/simonpercivall/astunparse";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/asyncssh/default.nix b/pkgs/development/python-modules/asyncssh/default.nix
index dc990325bfe69..d3684ea57200c 100644
--- a/pkgs/development/python-modules/asyncssh/default.nix
+++ b/pkgs/development/python-modules/asyncssh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , cryptography
 , bcrypt, gssapi, libnacl, libsodium, nettle, pyopenssl
 , openssl, openssh, pytestCheckHook }:
@@ -46,7 +46,7 @@ buildPythonPackage rec {
 
   disabledTests = [ "test_expired_root" "test_confirm" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides an asynchronous client and server implementation of the SSHv2 protocol on top of the Python asyncio framework";
     homepage = "https://asyncssh.readthedocs.io/en/latest";
     license = licenses.epl20;
diff --git a/pkgs/development/python-modules/atomiclong/default.nix b/pkgs/development/python-modules/atomiclong/default.nix
index 670361b9a9efb..7bcb36d548d8d 100644
--- a/pkgs/development/python-modules/atomiclong/default.nix
+++ b/pkgs/development/python-modules/atomiclong/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, cffi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, cffi }:
 
 buildPythonPackage rec {
   pname = "atomiclong";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   buildInputs = [ pytest ];
   propagatedBuildInputs = [ cffi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Long data type with atomic operations using CFFI";
     homepage = "https://github.com/dreid/atomiclong";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/atomicwrites/default.nix b/pkgs/development/python-modules/atomicwrites/default.nix
index 03401f226a2ef..e958b0f16d620 100644
--- a/pkgs/development/python-modules/atomicwrites/default.nix
+++ b/pkgs/development/python-modules/atomicwrites/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "atomicwrites";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   doCheck = false;
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Atomic file writes on POSIX";
     homepage = "https://pypi.python.org/pypi/atomicwrites";
     maintainers = with maintainers; [ matthiasbeyer ];
diff --git a/pkgs/development/python-modules/atomman/default.nix b/pkgs/development/python-modules/atomman/default.nix
index 9e5eb34da3b1f..147d2e77debc4 100644
--- a/pkgs/development/python-modules/atomman/default.nix
+++ b/pkgs/development/python-modules/atomman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy27
 , cython
 , datamodeldict
 , matplotlib
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     py.test tests -k 'not test_atomic'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/usnistgov/atomman/";
     description = "Atomistic Manipulation Toolkit";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/atsim_potentials/default.nix b/pkgs/development/python-modules/atsim_potentials/default.nix
index 8369a49b7db8d..6b8b8dccef817 100644
--- a/pkgs/development/python-modules/atsim_potentials/default.nix
+++ b/pkgs/development/python-modules/atsim_potentials/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , configparser
@@ -39,7 +39,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mjdrushton/atsim-potentials";
     description = "Provides tools for working with pair and embedded atom method potential models including tabulation routines for DL_POLY and LAMMPS";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/attrdict/default.nix b/pkgs/development/python-modules/attrdict/default.nix
index 1dfbf32c995b2..5c7514f9da639 100644
--- a/pkgs/development/python-modules/attrdict/default.nix
+++ b/pkgs/development/python-modules/attrdict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, coverage, nose, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, coverage, nose, six }:
 
 buildPythonPackage rec {
   pname = "attrdict";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ coverage nose six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A dict with attribute-style access";
     homepage = "https://github.com/bcj/AttrDict";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/authlib/default.nix b/pkgs/development/python-modules/authlib/default.nix
index e3d8c99e0ea19..82014b9be9933 100644
--- a/pkgs/development/python-modules/authlib/default.nix
+++ b/pkgs/development/python-modules/authlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pytest
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     PYTHONPATH=$PWD:$PYTHONPATH pytest tests/{core,files}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/lepture/authlib";
     description = "The ultimate Python library in building OAuth and OpenID Connect servers. JWS,JWE,JWK,JWA,JWT included.";
     maintainers = with maintainers; [ flokli ];
diff --git a/pkgs/development/python-modules/authres/default.nix b/pkgs/development/python-modules/authres/default.nix
index 372fb03a9472e..c3d0402d48d19 100644
--- a/pkgs/development/python-modules/authres/default.nix
+++ b/pkgs/development/python-modules/authres/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, python }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, python }:
 
 buildPythonPackage rec {
   pname = "authres";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m authres
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Email Authentication-Results Headers generation and parsing for Python/Python3";
     longDescription = ''
       Python module that implements various internet RFC's: 5451/7001/7601
diff --git a/pkgs/development/python-modules/autograd/default.nix b/pkgs/development/python-modules/autograd/default.nix
index 6d56775d90c39..fef97a7a6f48d 100644
--- a/pkgs/development/python-modules/autograd/default.nix
+++ b/pkgs/development/python-modules/autograd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, numpy, future }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, numpy, future }:
 
 buildPythonPackage rec {
   pname = "autograd";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # fixed, enable testing. See: https://github.com/HIPS/autograd/issues/404
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/HIPS/autograd";
     description = "Compute derivatives of NumPy code efficiently";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/autologging/default.nix b/pkgs/development/python-modules/autologging/default.nix
index 7a3b36c351417..7cd66dc2c3fea 100644
--- a/pkgs/development/python-modules/autologging/default.nix
+++ b/pkgs/development/python-modules/autologging/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "Autologging";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
     extension = "zip";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ninthtest.info/python-autologging/";
     description = "Easier logging and tracing for Python classes";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/automat/default.nix b/pkgs/development/python-modules/automat/default.nix
index 78a3259a28784..fa395f119ee57 100644
--- a/pkgs/development/python-modules/automat/default.nix
+++ b/pkgs/development/python-modules/automat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   m2r, setuptools_scm, six, attrs }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # this creates a circular dependency.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/glyph/Automat";
     description = "Self-service finite-state machines for the programmer on the go";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/autopep8/default.nix b/pkgs/development/python-modules/autopep8/default.nix
index 1b40aa9c1408b..afeaef4066119 100644
--- a/pkgs/development/python-modules/autopep8/default.nix
+++ b/pkgs/development/python-modules/autopep8/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pycodestyle, glibcLocales
+{ lib, stdenv, fetchPypi, buildPythonPackage, pycodestyle, glibcLocales
 , toml
 }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   LC_ALL = "en_US.UTF-8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool that automatically formats Python code to conform to the PEP 8 style guide";
     homepage = "https://pypi.python.org/pypi/autopep8/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/avro/default.nix b/pkgs/development/python-modules/avro/default.nix
index d9f57686845d7..9e08cd8ae1dac 100644
--- a/pkgs/development/python-modules/avro/default.nix
+++ b/pkgs/development/python-modules/avro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi, pycodestyle, isort }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi, pycodestyle, isort }:
 
 buildPythonPackage rec {
   pname = "avro";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   nativeBuildInputs = [ pycodestyle ];
   propagatedBuildInputs = [ isort ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A serialization and RPC framework";
     homepage = "https://pypi.python.org/pypi/avro/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/avro3k/default.nix b/pkgs/development/python-modules/avro3k/default.nix
index 59d09b3f25f0d..b600bc75c7a31 100644
--- a/pkgs/development/python-modules/avro3k/default.nix
+++ b/pkgs/development/python-modules/avro3k/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k }:
 
 buildPythonPackage rec {
   pname = "avro3k";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   doCheck = false;        # No such file or directory: './run_tests.py
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A serialization and RPC framework";
     homepage = "https://pypi.python.org/pypi/avro3k/";
   };
diff --git a/pkgs/development/python-modules/awesome-slugify/default.nix b/pkgs/development/python-modules/awesome-slugify/default.nix
index 945c941dec4ea..00882cb082796 100644
--- a/pkgs/development/python-modules/awesome-slugify/default.nix
+++ b/pkgs/development/python-modules/awesome-slugify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, unidecode, regex, python }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, unidecode, regex, python }:
 
 buildPythonPackage rec {
   pname = "awesome-slugify";
@@ -24,7 +24,7 @@ buildPythonPackage rec {
       ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dimka665/awesome-slugify";
     description = "Python flexible slugify function";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/b2sdk/default.nix b/pkgs/development/python-modules/b2sdk/default.nix
index f807c03539908..da43f6e5690e2 100644
--- a/pkgs/development/python-modules/b2sdk/default.nix
+++ b/pkgs/development/python-modules/b2sdk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm, isPy27, pytestCheckHook
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm, isPy27, pytestCheckHook
 , requests, arrow, logfury, tqdm }:
 
 buildPythonPackage rec {
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # requires unpackaged dependencies like liccheck
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client library and utilities for access to B2 Cloud Storage (backblaze).";
     homepage = "https://github.com/Backblaze/b2-sdk-python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/babelfish/default.nix b/pkgs/development/python-modules/babelfish/default.nix
index 87769aa3ea913..5ac0442921567 100644
--- a/pkgs/development/python-modules/babelfish/default.nix
+++ b/pkgs/development/python-modules/babelfish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools }:
 
 buildPythonPackage rec {
   pname = "babelfish";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/babelfish";
     description = "A module to work with countries and languages";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/backports-shutil-which/default.nix b/pkgs/development/python-modules/backports-shutil-which/default.nix
index 656842f4434d2..5fe922b90462e 100644
--- a/pkgs/development/python-modules/backports-shutil-which/default.nix
+++ b/pkgs/development/python-modules/backports-shutil-which/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pytest }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pytest }:
 
 buildPythonPackage rec {
   pname = "backports.shutil_which";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     py.test test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Backport of shutil.which from Python 3.3";
     homepage = "https://github.com/minrk/backports.shutil_which";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/backports_csv/default.nix b/pkgs/development/python-modules/backports_csv/default.nix
index e2fae4897f62d..5216149ddc2c4 100644
--- a/pkgs/development/python-modules/backports_csv/default.nix
+++ b/pkgs/development/python-modules/backports_csv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, future }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, future }:
 
 buildPythonPackage rec {
 
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ future ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Backport of Python 3 csv module";
     homepage = "https://github.com/ryanhiebert";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/backports_os/default.nix b/pkgs/development/python-modules/backports_os/default.nix
index dc969cbb4b943..b3e231bcd05d4 100644
--- a/pkgs/development/python-modules/backports_os/default.nix
+++ b/pkgs/development/python-modules/backports_os/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools_scm
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pjdelport/backports.os";
     description = "Backport of new features in Python's os module";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/backports_unittest-mock/default.nix b/pkgs/development/python-modules/backports_unittest-mock/default.nix
index b85c642787e62..08f98de79f270 100644
--- a/pkgs/development/python-modules/backports_unittest-mock/default.nix
+++ b/pkgs/development/python-modules/backports_unittest-mock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm, mock }:
 
 buildPythonPackage rec {
   pname = "backports.unittest_mock";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "backports.unittest_mock" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a function install() which makes the mock module";
     homepage = "https://github.com/jaraco/backports.unittest_mock";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/backports_weakref/default.nix b/pkgs/development/python-modules/backports_weakref/default.nix
index 8b818398ec9eb..9770fb45981dd 100644
--- a/pkgs/development/python-modules/backports_weakref/default.nix
+++ b/pkgs/development/python-modules/backports_weakref/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools_scm
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Backports of new features in Python’s weakref module";
     license = licenses.psfl;
     maintainers = with maintainers; [ jyp ];
diff --git a/pkgs/development/python-modules/bacpypes/default.nix b/pkgs/development/python-modules/bacpypes/default.nix
index 3999efd12b676..59542e61c56bb 100644
--- a/pkgs/development/python-modules/bacpypes/default.nix
+++ b/pkgs/development/python-modules/bacpypes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchFromGitHub
 , wheel, pytestCheckHook, pytestrunner }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     "test_recurring_task_5"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/JoelBender/bacpypes";
     description = "BACpypes provides a BACnet application layer and network layer written in Python for daemons, scripting, and graphical interfaces.";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bap/default.nix b/pkgs/development/python-modules/bap/default.nix
index fd63294302c3c..d2575afb77d2f 100644
--- a/pkgs/development/python-modules/bap/default.nix
+++ b/pkgs/development/python-modules/bap/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildPythonPackage, fetchFromGitHub, bap, requests}:
+{lib, stdenv, buildPythonPackage, fetchFromGitHub, bap, requests}:
 
 buildPythonPackage rec {
   pname = "bap";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Platform for binary analysis. It is written in OCaml, but can be used from other languages.";
     homepage = "https://github.com/BinaryAnalysisPlatform/bap/";
     maintainers = [ maintainers.maurer ];
diff --git a/pkgs/development/python-modules/base58/default.nix b/pkgs/development/python-modules/base58/default.nix
index 42f848aa846bb..a36727429ca7d 100644
--- a/pkgs/development/python-modules/base58/default.nix
+++ b/pkgs/development/python-modules/base58/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy27, pytest, pyhamcrest }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy27, pytest, pyhamcrest }:
 
 buildPythonPackage rec {
   pname = "base58";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Base58 and Base58Check implementation";
     homepage = "https://github.com/keis/base58";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/basemap/default.nix b/pkgs/development/python-modules/basemap/default.nix
index a06bcebc8e6c8..c97548bdee888 100644
--- a/pkgs/development/python-modules/basemap/default.nix
+++ b/pkgs/development/python-modules/basemap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , numpy
@@ -34,7 +34,7 @@ buildPythonPackage rec {
   # TODO : do the post install checks (`cd examples && ${python.interpreter} run_all.py`)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://matplotlib.org/basemap/";
     description = "Plot data on map projections with matplotlib";
     longDescription = ''
diff --git a/pkgs/development/python-modules/batinfo/default.nix b/pkgs/development/python-modules/batinfo/default.nix
index e8516aecdc65b..0ed3486272d35 100644
--- a/pkgs/development/python-modules/batinfo/default.nix
+++ b/pkgs/development/python-modules/batinfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "batinfo";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nicolargo/batinfo";
     description = "A simple Python lib to retrieve battery information";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/bayespy/default.nix b/pkgs/development/python-modules/bayespy/default.nix
index ef3dfa095184f..b470d21b1bea1 100644
--- a/pkgs/development/python-modules/bayespy/default.nix
+++ b/pkgs/development/python-modules/bayespy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , pytest, nose, glibcLocales
 , numpy, scipy, matplotlib, h5py }:
 
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     LC_ALL=en_US.utf-8 pytest -k 'not test_message_to_parents'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.bayespy.org";
     description = "Variational Bayesian inference tools for Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bcdoc/default.nix b/pkgs/development/python-modules/bcdoc/default.nix
index b8cbf8537dc60..185fcb86b0b7a 100644
--- a/pkgs/development/python-modules/bcdoc/default.nix
+++ b/pkgs/development/python-modules/bcdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, docutils, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, docutils, six }:
 
 buildPythonPackage rec {
   pname = "bcdoc";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # Tests fail due to nix file timestamp normalization.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/boto/bcdoc";
     license = licenses.asl20;
     description = "ReST document generation tools for botocore";
diff --git a/pkgs/development/python-modules/beautifulsoup4/default.nix b/pkgs/development/python-modules/beautifulsoup4/default.nix
index a0afd0c4f4c41..555669da243ee 100644
--- a/pkgs/development/python-modules/beautifulsoup4/default.nix
+++ b/pkgs/development/python-modules/beautifulsoup4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, soupsieve, pytest, python }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, soupsieve, pytest, python }:
 
 buildPythonPackage rec {
   pname = "beautifulsoup4";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ soupsieve ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://crummy.com/software/BeautifulSoup/bs4/";
     description = "HTML and XML parser";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bedup/default.nix b/pkgs/development/python-modules/bedup/default.nix
index 6c0c3c44d2d4e..0e339dca09739 100644
--- a/pkgs/development/python-modules/bedup/default.nix
+++ b/pkgs/development/python-modules/bedup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , btrfs-progs
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ contextlib2 pyxdg pycparser alembic ]
     ++ stdenv.lib.optionals (!isPyPy) [ cffi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Deduplication for Btrfs";
     longDescription = ''
       Deduplication for Btrfs. bedup looks for new and changed files,
diff --git a/pkgs/development/python-modules/behave/default.nix b/pkgs/development/python-modules/behave/default.nix
index 26cd6441ba5a0..56217dca617db 100644
--- a/pkgs/development/python-modules/behave/default.nix
+++ b/pkgs/development/python-modules/behave/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , buildPythonApplication, python
 , pytestCheckHook, mock, pathpy, pyhamcrest, pytest-html
 , glibcLocales
@@ -37,7 +37,7 @@ buildPythonApplication rec {
     ${python.interpreter} bin/behave -f progress3 --stop --tags='~@xfail' issue.features/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/behave/behave";
     description = "behaviour-driven development, Python style";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/bellows/default.nix b/pkgs/development/python-modules/bellows/default.nix
index ab50a1acd8ef8..614a1ad98a91e 100644
--- a/pkgs/development/python-modules/bellows/default.nix
+++ b/pkgs/development/python-modules/bellows/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , click, click-log, pure-pcapy3
 , pyserial, pyserial-asyncio, voluptuous, zigpy
 , asynctest, pytest, pytest-asyncio }:
@@ -28,7 +28,7 @@ in buildPythonPackage rec {
       --replace "click-log==0.2.0" "click-log>=0.2.0"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python 3 project to implement EZSP for EmberZNet devices";
     homepage = "https://github.com/zigpy/bellows";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/bespon/default.nix b/pkgs/development/python-modules/bespon/default.nix
index 51e29e55d07f1..555a0a4875811 100644
--- a/pkgs/development/python-modules/bespon/default.nix
+++ b/pkgs/development/python-modules/bespon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   doCheck = false;
 
   pythonImportsCheck = [ "bespon" ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Encodes and decodes data in the BespON format.";
     homepage = "https://github.com/gpoore/bespon_py";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/betamax-matchers/default.nix b/pkgs/development/python-modules/betamax-matchers/default.nix
index e95a34d154242..424b8ef4ef365 100644
--- a/pkgs/development/python-modules/betamax-matchers/default.nix
+++ b/pkgs/development/python-modules/betamax-matchers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , betamax, requests_toolbelt }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   buildInputs = [ betamax requests_toolbelt ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sigmavirus24/betamax_matchers";
     description = "A group of experimental matchers for Betamax";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/betamax-serializers/default.nix b/pkgs/development/python-modules/betamax-serializers/default.nix
index 60a79a51d4999..3d3cad4d95b5c 100644
--- a/pkgs/development/python-modules/betamax-serializers/default.nix
+++ b/pkgs/development/python-modules/betamax-serializers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , betamax, pyyaml }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   buildInputs = [ betamax pyyaml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/betamax/serializers";
     description = "A set of third-party serializers for Betamax";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/betamax/default.nix b/pkgs/development/python-modules/betamax/default.nix
index 7339fcbf6485b..5e1469bfc52df 100644
--- a/pkgs/development/python-modules/betamax/default.nix
+++ b/pkgs/development/python-modules/betamax/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests }:
 
 buildPythonPackage rec {
   pname = "betamax";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://betamax.readthedocs.org/en/latest/";
     description = "A VCR imitation for requests";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/billiard/default.nix b/pkgs/development/python-modules/billiard/default.nix
index ff87ba2e66916..4f8aa3565da26 100644
--- a/pkgs/development/python-modules/billiard/default.nix
+++ b/pkgs/development/python-modules/billiard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPyPy, pytestCheckHook, case, psutil, fetchpatch }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPyPy, pytestCheckHook, case, psutil, fetchpatch }:
 
 buildPythonPackage rec {
   pname = "billiard";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook case psutil ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/celery/billiard";
     description = "Python multiprocessing fork with improvements and bugfixes";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/binwalk/default.nix b/pkgs/development/python-modules/binwalk/default.nix
index c6fbbc13c43d3..3d1b9c0a90c41 100644
--- a/pkgs/development/python-modules/binwalk/default.nix
+++ b/pkgs/development/python-modules/binwalk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , zlib
@@ -49,7 +49,7 @@ buildPythonPackage {
 
   checkInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ReFirmLabs/binwalk";
     description = "A tool for searching a given binary image for embedded files";
     maintainers = [ maintainers.koral ];
diff --git a/pkgs/development/python-modules/bitbucket-api/default.nix b/pkgs/development/python-modules/bitbucket-api/default.nix
index 82b49a2675740..559661bbb4f33 100644
--- a/pkgs/development/python-modules/bitbucket-api/default.nix
+++ b/pkgs/development/python-modules/bitbucket-api/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , requests_oauthlib, nose, sh }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Sheeprider/BitBucket-api";
     description = "Python library to interact with BitBucket REST API";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bitbucket-cli/default.nix b/pkgs/development/python-modules/bitbucket-cli/default.nix
index 5e5d5662ba320..50075fe70fce5 100644
--- a/pkgs/development/python-modules/bitbucket-cli/default.nix
+++ b/pkgs/development/python-modules/bitbucket-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, requests }:
 
 buildPythonPackage rec {
   pname = "bitbucket-cli";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bitbucket command line interface";
     homepage = "https://bitbucket.org/zhemao/bitbucket-cli";
     maintainers = with maintainers; [ refnil ];
diff --git a/pkgs/development/python-modules/bitmath/default.nix b/pkgs/development/python-modules/bitmath/default.nix
index 55194b02db3a0..49992c561f734 100644
--- a/pkgs/development/python-modules/bitmath/default.nix
+++ b/pkgs/development/python-modules/bitmath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, progressbar231, progressbar33, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, progressbar231, progressbar33, mock }:
 
 buildPythonPackage rec {
   pname = "bitmath";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   checkInputs = [ (if isPy3k then progressbar33 else progressbar231) mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Module for representing and manipulating file sizes with different prefix";
     homepage = "https://github.com/tbielawa/bitmath";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bitstring/default.nix b/pkgs/development/python-modules/bitstring/default.nix
index a2ba5b10268c5..d6eaf31056ff5 100644
--- a/pkgs/development/python-modules/bitstring/default.nix
+++ b/pkgs/development/python-modules/bitstring/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "bitstring";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "0jl6192dwrlm5ybkbh7ywmyaymrc3cmz9y07nm7qdli9n9rfpwzx";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Module for binary data manipulation";
     homepage = "https://github.com/scott-griffiths/bitstring";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bjoern/default.nix b/pkgs/development/python-modules/bjoern/default.nix
index c2f60fce9dc5f..2949ecbf6f929 100644
--- a/pkgs/development/python-modules/bjoern/default.nix
+++ b/pkgs/development/python-modules/bjoern/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, libev, python }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, libev, python }:
 
 buildPythonPackage rec {
   pname = "bjoern";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     ${python.interpreter} tests/test_wsgi_compliance.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jonashaag/bjoern";
     description = "A screamingly fast Python 2/3 WSGI server written in C";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/black-macchiato/default.nix b/pkgs/development/python-modules/black-macchiato/default.nix
index 130d07d61ff46..536ad1f14b666 100644
--- a/pkgs/development/python-modules/black-macchiato/default.nix
+++ b/pkgs/development/python-modules/black-macchiato/default.nix
@@ -1,4 +1,4 @@
-{ stdenv,
+{ lib, stdenv,
   buildPythonPackage,
   fetchFromGitHub,
   pythonOlder,
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "black" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This is a small utility built on top of the black Python code formatter to enable formatting of partial files";
     homepage    = "https://github.com/wbolster/black-macchiato";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/bleak/default.nix b/pkgs/development/python-modules/bleak/default.nix
index 91d94fcd72d9f..06dc3217dc87d 100644
--- a/pkgs/development/python-modules/bleak/default.nix
+++ b/pkgs/development/python-modules/bleak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi, bluez, txdbus, pytest, pytestcov }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi, bluez, txdbus, pytest, pytestcov }:
 
 buildPythonPackage rec {
   pname = "bleak";
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   checkPhase = "AGENT_OS=linux py.test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bluetooth Low Energy platform Agnostic Klient for Python";
     homepage = "https://github.com/hbldh/bleak";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/blessed/default.nix b/pkgs/development/python-modules/blessed/default.nix
index 7f1a24b485085..7adacecc647a4 100644
--- a/pkgs/development/python-modules/blessed/default.nix
+++ b/pkgs/development/python-modules/blessed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, six
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, six
 , wcwidth, pytest, mock, glibcLocales
 }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ wcwidth six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jquast/blessed";
     description = "A thin, practical wrapper around terminal capabilities in Python.";
     maintainers = with maintainers; [ eqyiel ];
diff --git a/pkgs/development/python-modules/blessings/default.nix b/pkgs/development/python-modules/blessings/default.nix
index c285b3a7d0038..5263a92ec3d9f 100644
--- a/pkgs/development/python-modules/blessings/default.nix
+++ b/pkgs/development/python-modules/blessings/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/erikrose/blessings";
     description = "A thin, practical wrapper around terminal coloring, styling, and positioning";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/blinker/default.nix b/pkgs/development/python-modules/blinker/default.nix
index 5c76efb029fd0..e33ad1626318a 100644
--- a/pkgs/development/python-modules/blinker/default.nix
+++ b/pkgs/development/python-modules/blinker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "blinker";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "1dpq0vb01p36jjwbhhd08ylvrnyvcc82yxx3mwjx6awrycjyw6j7";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pythonhosted.org/blinker/";
     description = "Fast, simple object-to-object and broadcast signaling";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/blis/default.nix b/pkgs/development/python-modules/blis/default.nix
index 0042bcaf92933..eeb62e8fed321 100644
--- a/pkgs/development/python-modules/blis/default.nix
+++ b/pkgs/development/python-modules/blis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cython
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     pytest
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BLAS-like linear algebra library";
     homepage = "https://github.com/explosion/cython-blis";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/blist/default.nix b/pkgs/development/python-modules/blist/default.nix
index 52687bf2506de..505f01af5fe4a 100644
--- a/pkgs/development/python-modules/blist/default.nix
+++ b/pkgs/development/python-modules/blist/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchpatch
 , fetchPypi
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://stutzbachenterprises.com/blist/";
     description = "A list-like type with better asymptotic performance and similar performance on small lists";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/blivet/default.nix b/pkgs/development/python-modules/blivet/default.nix
index d224f2bc22e12..94abc39fd2854 100644
--- a/pkgs/development/python-modules/blivet/default.nix
+++ b/pkgs/development/python-modules/blivet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, pykickstart, pyparted, pyblock
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, pykickstart, pyparted, pyblock
 , pyudev, six, libselinux, multipath-tools, lsof, util-linux
 }:
 
@@ -33,7 +33,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fedoraproject.org/wiki/Blivet";
     description = "Module for management of a system's storage configuration";
     license = with licenses; [ gpl2Plus lgpl21Plus ];
diff --git a/pkgs/development/python-modules/block-io/default.nix b/pkgs/development/python-modules/block-io/default.nix
index 24ddd429cd93c..3a9704d71bc55 100644
--- a/pkgs/development/python-modules/block-io/default.nix
+++ b/pkgs/development/python-modules/block-io/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, base58, ecdsa, pycryptodome, requests, six, setuptools }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, base58, ecdsa, pycryptodome, requests, six, setuptools }:
 
 buildPythonPackage rec {
   pname = "block-io";
@@ -30,7 +30,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "block_io" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integrate Bitcoin, Dogecoin and Litecoin in your Python applications using block.io";
     homepage = "https://github.com/BlockIo/block_io-python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/blockdiag/default.nix b/pkgs/development/python-modules/blockdiag/default.nix
index ff53884ef376b..5adc854d02632 100644
--- a/pkgs/development/python-modules/blockdiag/default.nix
+++ b/pkgs/development/python-modules/blockdiag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , setuptools, funcparserlib, pillow, webcolors, reportlab, docutils
 }:
 
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # require network and fail
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate block-diagram image from spec-text file (similar to Graphviz)";
     homepage = "http://blockdiag.com/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/bluepy/default.nix b/pkgs/development/python-modules/bluepy/default.nix
index a26cdb9dd3562..d833d20934d6d 100644
--- a/pkgs/development/python-modules/bluepy/default.nix
+++ b/pkgs/development/python-modules/bluepy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkg-config
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   '';
   pythonImportsCheck = [ "bluepy" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python interface to Bluetooth LE on Linux";
     homepage = "https://github.com/IanHarvey/bluepy";
     maintainers = with maintainers; [ georgewhewell ];
diff --git a/pkgs/development/python-modules/boltons/default.nix b/pkgs/development/python-modules/boltons/default.nix
index 080165f707124..13e264340da12 100644
--- a/pkgs/development/python-modules/boltons/default.nix
+++ b/pkgs/development/python-modules/boltons/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pytest }:
 
 buildPythonPackage rec {
   pname = "boltons";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest ];
   checkPhase = "pytest tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mahmoud/boltons";
     description = "220+ constructs, recipes, and snippets extending (and relying on nothing but) the Python standard library";
     longDescription = ''
diff --git a/pkgs/development/python-modules/boltztrap2/default.nix b/pkgs/development/python-modules/boltztrap2/default.nix
index 48fc3bf69983a..48bc53bbeeda9 100644
--- a/pkgs/development/python-modules/boltztrap2/default.nix
+++ b/pkgs/development/python-modules/boltztrap2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , spglib
@@ -36,7 +36,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.boltztrap.org/";
     description = "Band-structure interpolator and transport coefficient calculator";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/bottle/default.nix b/pkgs/development/python-modules/bottle/default.nix
index 52d97582ef31e..213d69dd98902 100644
--- a/pkgs/development/python-modules/bottle/default.nix
+++ b/pkgs/development/python-modules/bottle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools }:
 
 buildPythonPackage rec {
   pname = "bottle";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://bottlepy.org";
     description = "A fast and simple micro-framework for small web-applications";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/box2d/default.nix b/pkgs/development/python-modules/box2d/default.nix
index 1b372f90a90f2..92ac90ab6d4d6 100644
--- a/pkgs/development/python-modules/box2d/default.nix
+++ b/pkgs/development/python-modules/box2d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , swig2
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # tests not included with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pybox2d/pybox2d";
     description = ''
       A 2D game physics library for Python under
diff --git a/pkgs/development/python-modules/bpython/default.nix b/pkgs/development/python-modules/bpython/default.nix
index 7dfe8053ca247..108d8ec0c66bf 100644
--- a/pkgs/development/python-modules/bpython/default.nix
+++ b/pkgs/development/python-modules/bpython/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , curtsies
@@ -36,7 +36,7 @@ buildPythonPackage rec {
   # tests fail: https://github.com/bpython/bpython/issues/712
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fancy curses interface to the Python interactive interpreter";
     homepage = "https://bpython-interpreter.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bsddb3/default.nix b/pkgs/development/python-modules/bsddb3/default.nix
index 0989b61b6cfae..9877a03a087e2 100644
--- a/pkgs/development/python-modules/bsddb3/default.nix
+++ b/pkgs/development/python-modules/bsddb3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     export BERKELEYDB_DIR=${pkgs.db.dev};
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for Oracle Berkeley DB";
     homepage = "https://www.jcea.es/programacion/pybsddb.htm";
     license = with licenses; [ agpl3 ]; # License changed from bsd3 to agpl3 since 6.x
diff --git a/pkgs/development/python-modules/bsdiff4/default.nix b/pkgs/development/python-modules/bsdiff4/default.nix
index aabcd4de93433..f70f71c1a6990 100644
--- a/pkgs/development/python-modules/bsdiff4/default.nix
+++ b/pkgs/development/python-modules/bsdiff4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , aflplusplus
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     python -c 'import bsdiff4; bsdiff4.test()'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "binary diff and patch using the BSDIFF4-format";
     homepage = "https://github.com/ilanschnell/bsdiff4";
     license = licenses.bsdProtection;
diff --git a/pkgs/development/python-modules/bt-proximity/default.nix b/pkgs/development/python-modules/bt-proximity/default.nix
index 17f384062482e..209565fa21b7c 100644
--- a/pkgs/development/python-modules/bt-proximity/default.nix
+++ b/pkgs/development/python-modules/bt-proximity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , pybluez }:
 
 buildPythonPackage {
@@ -18,7 +18,7 @@ buildPythonPackage {
   # there are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bluetooth Proximity Detection using Python";
     homepage = "https://github.com/FrederikBolding/bluetooth-proximity";
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/development/python-modules/btchip/default.nix b/pkgs/development/python-modules/btchip/default.nix
index c84ee0f0be7f9..ebb14a77b5644 100644
--- a/pkgs/development/python-modules/btchip/default.nix
+++ b/pkgs/development/python-modules/btchip/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, hidapi, pyscard, ecdsa }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, hidapi, pyscard, ecdsa }:
 
 buildPythonPackage rec {
   pname = "btchip-python";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # tests requires hardware
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python communication library for Ledger Hardware Wallet products";
     homepage = "https://github.com/LedgerHQ/btchip-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/btrees/default.nix b/pkgs/development/python-modules/btrees/default.nix
index 08f2c1eeb2ffe..471ba54215def 100644
--- a/pkgs/development/python-modules/btrees/default.nix
+++ b/pkgs/development/python-modules/btrees/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , persistent
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     sha256 = "7ce4a5eb5c135bcb5c06b5bd1ca6fd7fd39d8631306182307ed8bc30d3033846";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scalable persistent components";
     homepage = "http://packages.python.org/BTrees";
     license = licenses.zpl21;
diff --git a/pkgs/development/python-modules/btrfs/default.nix b/pkgs/development/python-modules/btrfs/default.nix
index 225b26b4d650a..8ea93fe005e7d 100644
--- a/pkgs/development/python-modules/btrfs/default.nix
+++ b/pkgs/development/python-modules/btrfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1w92sj47wy53ygz725xr613k32pk5khi0g9lrpp6img871241hrx";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Inspect btrfs filesystems";
     homepage = "https://github.com/knorrie/python-btrfs";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/bugsnag/default.nix b/pkgs/development/python-modules/bugsnag/default.nix
index 603e6f42e4504..5e3b0b4e89f7b 100644
--- a/pkgs/development/python-modules/bugsnag/default.nix
+++ b/pkgs/development/python-modules/bugsnag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic error monitoring for django, flask, etc.";
     homepage = "https://www.bugsnag.com";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/bugwarrior/default.nix b/pkgs/development/python-modules/bugwarrior/default.nix
index 25de097f1a964..3d27384efe18b 100644
--- a/pkgs/development/python-modules/bugwarrior/default.nix
+++ b/pkgs/development/python-modules/bugwarrior/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder, setuptools
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder, setuptools
 , twiggy, requests, offtrac, bugzilla, taskw, dateutil, pytz, keyring, six
 , jinja2, pycurl, dogpile_cache, lockfile, click, pyxdg, future, jira }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # for the moment oauth2client <4.0.0 and megaplan>=1.4 are missing for running the test suite.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ralphbean/bugwarrior";
     description = "Sync github, bitbucket, bugzilla, and trac issues with taskwarrior";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/bugz/default.nix b/pkgs/development/python-modules/bugz/default.nix
index abfde52ef5f77..5324a43e1b0c1 100644
--- a/pkgs/development/python-modules/bugz/default.nix
+++ b/pkgs/development/python-modules/bugz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -16,7 +16,7 @@ buildPythonPackage {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/williamh/pybugz";
     description = "Command line interface for Bugzilla";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/bugzilla/default.nix b/pkgs/development/python-modules/bugzilla/default.nix
index f40488511093d..fc122ecd233c6 100644
--- a/pkgs/development/python-modules/bugzilla/default.nix
+++ b/pkgs/development/python-modules/bugzilla/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pep8, coverage, logilab_common, requests }:
 
 buildPythonPackage rec {
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     export HOME=$(pwd)/check-phase
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/python-bugzilla/python-bugzilla";
     description = "Bugzilla XMLRPC access module";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/buildout/default.nix b/pkgs/development/python-modules/buildout/default.nix
index 20731e76c814f..0751b284a7869 100644
--- a/pkgs/development/python-modules/buildout/default.nix
+++ b/pkgs/development/python-modules/buildout/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "zc.buildout";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "1dyc5g3yv7wm3hf3fcsh6y1wivzjj1bspafr5qqb653z9a31lsfn";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.buildout.org";
     description = "A software build and configuration system";
     license = licenses.zpl21;
diff --git a/pkgs/development/python-modules/bumps/default.nix b/pkgs/development/python-modules/bumps/default.nix
index e2938e0f32e26..05f082c747bd7 100644
--- a/pkgs/development/python-modules/bumps/default.nix
+++ b/pkgs/development/python-modules/bumps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six}:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six}:
 
 buildPythonPackage rec {
   pname = "bumps";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "9f92c05effd8175763799d19ca55592e89b053318f611148a6725159aea41d67";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.reflectometry.org/danse/software.html";
     description = "Data fitting with bayesian uncertainty analysis";
     maintainers = with maintainers; [ rprospero ];
diff --git a/pkgs/development/python-modules/bunch/default.nix b/pkgs/development/python-modules/bunch/default.nix
index 42918f0233984..ce77085e4f7f9 100644
--- a/pkgs/development/python-modules/bunch/default.nix
+++ b/pkgs/development/python-modules/bunch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "bunch";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ ];
   };
 }
diff --git a/pkgs/development/python-modules/bwapy/default.nix b/pkgs/development/python-modules/bwapy/default.nix
index 31884074defd8..c736eb577d444 100644
--- a/pkgs/development/python-modules/bwapy/default.nix
+++ b/pkgs/development/python-modules/bwapy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pythonOlder
 , fetchPypi
@@ -33,7 +33,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "bwapy" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ACEnglish/acebinf";
     description = "Python bindings to bwa mem aligner";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/cachecontrol/default.nix b/pkgs/development/python-modules/cachecontrol/default.nix
index e5a7584234caa..53b13ddb56858 100644
--- a/pkgs/development/python-modules/cachecontrol/default.nix
+++ b/pkgs/development/python-modules/cachecontrol/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ionrock/cachecontrol";
     description = "Httplib2 caching for requests";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/cachelib/default.nix b/pkgs/development/python-modules/cachelib/default.nix
index e73bbaa28a695..503b546116ef2 100644
--- a/pkgs/development/python-modules/cachelib/default.nix
+++ b/pkgs/development/python-modules/cachelib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "cachelib";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "47e95a67d68c729cbad63285a790a06f0e0d27d71624c6e44c1ec3456bb4476f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pallets/cachelib";
     description = "Collection of cache libraries in the same API interface";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cachetools/default.nix b/pkgs/development/python-modules/cachetools/default.nix
index 6cc6c45137f5d..6fd3f637875d6 100644
--- a/pkgs/development/python-modules/cachetools/default.nix
+++ b/pkgs/development/python-modules/cachetools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27 }:
 
 buildPythonPackage rec {
   pname = "cachetools";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "bbaa39c3dede00175df2dc2b03d0cf18dd2d32a7de7beb68072d13043c9edb20";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extensible memoizing collections and decorators";
     homepage = "https://github.com/tkem/cachetools";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/cairosvg/1_x.nix b/pkgs/development/python-modules/cairosvg/1_x.nix
index b98fbbf91e860..bb5629cf4e513 100644
--- a/pkgs/development/python-modules/cairosvg/1_x.nix
+++ b/pkgs/development/python-modules/cairosvg/1_x.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, cairocffi, nose, fontconfig
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, cairocffi, nose, fontconfig
 , cssselect2, defusedxml, pillow, tinycss2 }:
 
 # CairoSVG 2.x dropped support for Python 2 so offer CairoSVG 1.x as an
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   #   FONTCONFIG_FILE=${fontconfig.out}/etc/fonts/fonts.conf nosetests .
   # '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://cairosvg.org";
     license = licenses.lgpl3;
     description = "SVG converter based on Cairo";
diff --git a/pkgs/development/python-modules/cairosvg/default.nix b/pkgs/development/python-modules/cairosvg/default.nix
index da3e84b725dd5..9d1c54651c204 100644
--- a/pkgs/development/python-modules/cairosvg/default.nix
+++ b/pkgs/development/python-modules/cairosvg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, fetchpatch
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, fetchpatch
 , cairocffi, cssselect2, defusedxml, pillow, tinycss2
 , pytest, pytestrunner, pytestcov, pytest-flake8, pytest-isort }:
 
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest pytestrunner pytestcov pytest-flake8 pytest-isort ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://cairosvg.org";
     license = licenses.lgpl3;
     description = "SVG converter based on Cairo";
diff --git a/pkgs/development/python-modules/canonicaljson/default.nix b/pkgs/development/python-modules/canonicaljson/default.nix
index 31daad18bdc8e..96af6f4bf78fc 100644
--- a/pkgs/development/python-modules/canonicaljson/default.nix
+++ b/pkgs/development/python-modules/canonicaljson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , frozendict, simplejson, six, isPy27
 }:
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     frozendict simplejson six
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/matrix-org/python-canonicaljson";
     description = "Encodes objects and arrays as RFC 7159 JSON.";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/capstone/default.nix b/pkgs/development/python-modules/capstone/default.nix
index 7fc0b16522ed5..7d5e416a9c5d4 100644
--- a/pkgs/development/python-modules/capstone/default.nix
+++ b/pkgs/development/python-modules/capstone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     make check
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.capstone-engine.org/";
     license = licenses.bsdOriginal;
     description = "Python bindings for Capstone disassembly engine";
diff --git a/pkgs/development/python-modules/carbon/default.nix b/pkgs/development/python-modules/carbon/default.nix
index 71a7174fb23f6..e0a31829b05fa 100644
--- a/pkgs/development/python-modules/carbon/default.nix
+++ b/pkgs/development/python-modules/carbon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , twisted, whisper, txamqp, cachetools, urllib3
 }:
 
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ twisted whisper txamqp cachetools urllib3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://graphiteapp.org/";
     description = "Backend data caching and persistence daemon for Graphite";
     maintainers = with maintainers; [ offline basvandijk ];
diff --git a/pkgs/development/python-modules/carrot/default.nix b/pkgs/development/python-modules/carrot/default.nix
index 9a5ffe578565f..c2262decd314f 100644
--- a/pkgs/development/python-modules/carrot/default.nix
+++ b/pkgs/development/python-modules/carrot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose, amqplib, anyjson }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   doCheck = false; # depends on the network
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/carrot";
     description = "AMQP Messaging Framework for Python";
   };
diff --git a/pkgs/development/python-modules/case/default.nix b/pkgs/development/python-modules/case/default.nix
index 771a349be1f77..5d1a7696516a4 100644
--- a/pkgs/development/python-modules/case/default.nix
+++ b/pkgs/development/python-modules/case/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , six, nose, unittest2, mock }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six nose unittest2 mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/celery/case";
     description = "unittests utilities";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/casttube/default.nix b/pkgs/development/python-modules/casttube/default.nix
index ff8e5614ceb66..85b1147c13a55 100644
--- a/pkgs/development/python-modules/casttube/default.nix
+++ b/pkgs/development/python-modules/casttube/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests }:
 
 buildPythonPackage rec {
   pname = "casttube";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interact with the Youtube Chromecast api";
     homepage = "https://github.com/ur1katz/casttube";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/catalogue/default.nix b/pkgs/development/python-modules/catalogue/default.nix
index 1624cbcf36ce2..c4cd89cab68a3 100644
--- a/pkgs/development/python-modules/catalogue/default.nix
+++ b/pkgs/development/python-modules/catalogue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiny library for adding function or object registries";
     homepage = "https://github.com/explosion/catalogue";
     changelog = "https://github.com/explosion/catalogue/releases/tag/v${version}";
diff --git a/pkgs/development/python-modules/cbor/default.nix b/pkgs/development/python-modules/cbor/default.nix
index 3ebf5f26b8212..f081511265fd3 100644
--- a/pkgs/development/python-modules/cbor/default.nix
+++ b/pkgs/development/python-modules/cbor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "cbor";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # https://github.com/brianolson/cbor_py/issues/6
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/bodhisnarkva/cbor";
     description = "Concise Binary Object Representation (CBOR) library";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/cccolutils/default.nix b/pkgs/development/python-modules/cccolutils/default.nix
index 5f5e396a02e2b..96e75405ee3c5 100644
--- a/pkgs/development/python-modules/cccolutils/default.nix
+++ b/pkgs/development/python-modules/cccolutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, krb5Full, nose, GitPython, mock, git }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, krb5Full, nose, GitPython, mock, git }:
 
 buildPythonPackage rec {
   pname = "CCColUtils";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = isPy3k; # needs unpackaged module to run tests on python2
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Kerberos 5 Credential Cache Collection Utilities";
     homepage = "https://pagure.io/cccolutils";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/cddb/default.nix b/pkgs/development/python-modules/cddb/default.nix
index 5c27b48d62f34..0956a971ebd8c 100644
--- a/pkgs/development/python-modules/cddb/default.nix
+++ b/pkgs/development/python-modules/cddb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pkgs
 , isPy3k
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     sha256 = "098xhd575ibvdx7i3dny3lwi851yxhjg2hn5jbbgrwj833rg5l5w";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cddb-py.sourceforge.net/";
     description = "CDDB and FreeDB audio CD track info access";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/cdecimal/default.nix b/pkgs/development/python-modules/cdecimal/default.nix
index 3508b392203d4..f788d32520e16 100644
--- a/pkgs/development/python-modules/cdecimal/default.nix
+++ b/pkgs/development/python-modules/cdecimal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonPackage, isPy3k }:
+{ lib, stdenv, fetchurl, buildPythonPackage, isPy3k }:
 
 with stdenv.lib;
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # Upstream tests are not included s. a. http://www.bytereef.org/mpdecimal/testing.html
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast drop-in replacement for decimal.py";
     homepage    = "http://www.bytereef.org/mpdecimal/";
     license     = licenses.bsd2;
diff --git a/pkgs/development/python-modules/cement/default.nix b/pkgs/development/python-modules/cement/default.nix
index 9117908f399ab..9133389f0ce92 100644
--- a/pkgs/development/python-modules/cement/default.nix
+++ b/pkgs/development/python-modules/cement/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k }:
 
 buildPythonPackage rec {
   pname = "cement";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   disabled = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://builtoncement.com/";
     description = "A CLI Application Framework for Python.";
     maintainers = with maintainers; [ eqyiel ];
diff --git a/pkgs/development/python-modules/cerberus/default.nix b/pkgs/development/python-modules/cerberus/default.nix
index b0c35204d6e76..08b7527c54c1f 100644
--- a/pkgs/development/python-modules/cerberus/default.nix
+++ b/pkgs/development/python-modules/cerberus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytestrunner, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytestrunner, pytest }:
 
 buildPythonPackage rec {
   pname = "Cerberus";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     pytest -k 'not nested_oneofs'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://python-cerberus.org/";
     description = "Lightweight, extensible schema and data validation tool for Python dictionaries";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/certipy/default.nix b/pkgs/development/python-modules/certipy/default.nix
index 5d34eede3110d..049e3ffdb5d92 100644
--- a/pkgs/development/python-modules/certipy/default.nix
+++ b/pkgs/development/python-modules/certipy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyopenssl
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = false; #no tests were included
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/LLNL/certipy";
     description = "wrapper for pyOpenSSL";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cffi/default.nix b/pkgs/development/python-modules/cffi/default.nix
index 07492240ffe9e..55390ea5ff946 100644
--- a/pkgs/development/python-modules/cffi/default.nix
+++ b/pkgs/development/python-modules/cffi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPyPy, fetchPypi, libffi, pycparser, pytest }:
+{ lib, stdenv, buildPythonPackage, isPyPy, fetchPypi, libffi, pycparser, pytest }:
 
 if isPyPy then null else buildPythonPackage rec {
   pname = "cffi";
@@ -37,7 +37,7 @@ if isPyPy then null else buildPythonPackage rec {
     py.test -k "not test_char_pointer_conversion"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ domenkozar lnl7 ];
     homepage = "https://cffi.readthedocs.org/";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/cgroup-utils/default.nix b/pkgs/development/python-modules/cgroup-utils/default.nix
index a94b4439250ea..2000a4e0a3bc8 100644
--- a/pkgs/development/python-modules/cgroup-utils/default.nix
+++ b/pkgs/development/python-modules/cgroup-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pep8, nose }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pep8, nose }:
 
 buildPythonPackage rec {
   version = "0.8";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     sha256 = "0qnbn8cnq8m14s8s1hcv25xjd55dyb6yy54l5vc7sby5xzzp11fq";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility tools for control groups of Linux";
     maintainers = with maintainers; [ layus ];
     platforms = platforms.linux;
diff --git a/pkgs/development/python-modules/chai/default.nix b/pkgs/development/python-modules/chai/default.nix
index 16166d2db80ee..3400b33635a8f 100644
--- a/pkgs/development/python-modules/chai/default.nix
+++ b/pkgs/development/python-modules/chai/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "chai";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "ff8d2b6855f660cd23cd5ec79bd10264d39f24f6235773331b48e7fcd637d6cc";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mocking, stubbing and spying framework for python";
   };
 }
diff --git a/pkgs/development/python-modules/chainmap/default.nix b/pkgs/development/python-modules/chainmap/default.nix
index 17a51f17763aa..3858fc44f234b 100644
--- a/pkgs/development/python-modules/chainmap/default.nix
+++ b/pkgs/development/python-modules/chainmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "chainmap";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # Requires tox
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Backport/clone of ChainMap";
     homepage = "https://bitbucket.org/jeunice/chainmap";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/chameleon/default.nix b/pkgs/development/python-modules/chameleon/default.nix
index 0af3d18824afa..a2ffcb9a0236a 100644
--- a/pkgs/development/python-modules/chameleon/default.nix
+++ b/pkgs/development/python-modules/chameleon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "chameleon" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://chameleon.readthedocs.io/";
     description = "Fast HTML/XML Template Compiler";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/channels-redis/default.nix b/pkgs/development/python-modules/channels-redis/default.nix
index a43a8ce7d0a8a..3f341f5527ae6 100644
--- a/pkgs/development/python-modules/channels-redis/default.nix
+++ b/pkgs/development/python-modules/channels-redis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , aioredis
 , asgiref
 , buildPythonPackage
@@ -37,7 +37,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "channels_redis" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/django/channels_redis/";
     description = "Redis-backed ASGI channel layer implementation";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/channels/default.nix b/pkgs/development/python-modules/channels/default.nix
index 20e470d8c7032..c2836ef4faa01 100644
--- a/pkgs/development/python-modules/channels/default.nix
+++ b/pkgs/development/python-modules/channels/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   asgiref, django, daphne
 }:
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ asgiref django daphne ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Brings event-driven capabilities to Django with a channel system";
     license = licenses.bsd3;
     homepage = "https://github.com/django/channels";
diff --git a/pkgs/development/python-modules/chardet/default.nix b/pkgs/development/python-modules/chardet/default.nix
index 1a8b1f36e998c..bbc41df0cd827 100644
--- a/pkgs/development/python-modules/chardet/default.nix
+++ b/pkgs/development/python-modules/chardet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch
 , pytest, pytestrunner, hypothesis }:
 
 buildPythonPackage rec {
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest pytestrunner hypothesis ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/chardet/chardet";
     description = "Universal encoding detector";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/check-manifest/default.nix b/pkgs/development/python-modules/check-manifest/default.nix
index 6368ebf4b737d..18ce078269a99 100644
--- a/pkgs/development/python-modules/check-manifest/default.nix
+++ b/pkgs/development/python-modules/check-manifest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pep517, toml, mock, breezy, git }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pep517, toml, mock, breezy, git }:
 
 buildPythonPackage rec {
   pname = "check-manifest";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   checkInputs = [ mock breezy git ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mgedmin/check-manifest";
     description = "Check MANIFEST.in in a Python source package for completeness";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/cherrypy/17.nix b/pkgs/development/python-modules/cherrypy/17.nix
index 5e5541b26e277..9982db19f3815 100644
--- a/pkgs/development/python-modules/cherrypy/17.nix
+++ b/pkgs/development/python-modules/cherrypy/17.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , setuptools_scm
 , cheroot, contextlib2, portend, routes, six, zc_lockfile
 , backports_unittest-mock, objgraph, pathpy, pytest, pytestcov, backports_functools_lru_cache, requests_toolbelt
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     pytest ${stdenv.lib.optionalString stdenv.isDarwin "--ignore=cherrypy/test/test_wsgi_unix_socket.py"}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.cherrypy.org";
     description = "A pythonic, object-oriented HTTP framework";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cherrypy/default.nix b/pkgs/development/python-modules/cherrypy/default.nix
index 3e9f75795e497..76fd780e52312 100644
--- a/pkgs/development/python-modules/cherrypy/default.nix
+++ b/pkgs/development/python-modules/cherrypy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , setuptools_scm
 , cheroot, portend, more-itertools, zc_lockfile, routes
 , jaraco_collections
@@ -47,7 +47,7 @@ buildPythonPackage rec {
 
   __darwinAllowLocalNetworking = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.cherrypy.org";
     description = "A pythonic, object-oriented HTTP framework";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cjson/default.nix b/pkgs/development/python-modules/cjson/default.nix
index 1ecd43fccdeeb..ce70a2f459dac 100644
--- a/pkgs/development/python-modules/cjson/default.nix
+++ b/pkgs/development/python-modules/cjson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, isPyPy }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, isPyPy }:
 
 buildPythonPackage rec {
   pname = "python-cjson";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
     sha256 = "3006c2c218297be3448dc793218e0b15d20fe9839775521bfc294fc6aa24972b";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A very fast JSON encoder/decoder for Python";
     homepage = "https://ag-projects.com/";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/ckcc-protocol/default.nix b/pkgs/development/python-modules/ckcc-protocol/default.nix
index 7f5311f45b005..dd72f5705e70b 100644
--- a/pkgs/development/python-modules/ckcc-protocol/default.nix
+++ b/pkgs/development/python-modules/ckcc-protocol/default.nix
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ click ecdsa hidapi pyaes ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Communicate with your Coldcard using Python";
     homepage = "https://github.com/Coldcard/ckcc-protocol";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/cld2-cffi/default.nix b/pkgs/development/python-modules/cld2-cffi/default.nix
index 7775fee5ba0d9..df28bcdf3aa77 100644
--- a/pkgs/development/python-modules/cld2-cffi/default.nix
+++ b/pkgs/development/python-modules/cld2-cffi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six, cffi, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six, cffi, nose }:
 
 buildPythonPackage rec {
   pname = "cld2-cffi";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   checkPhase = "nosetests -v";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CFFI bindings around Google Chromium's embedded compact language detection library (CLD2)";
     homepage = "https://github.com/GregBowyer/cld2-cffi";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/clf/default.nix b/pkgs/development/python-modules/clf/default.nix
index d3741ef38a936..f4168d689d446 100644
--- a/pkgs/development/python-modules/clf/default.nix
+++ b/pkgs/development/python-modules/clf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , docopt, requests, pygments }:
 
 buildPythonPackage rec {
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # No local packages or download links found for requests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ncrocfer/clf";
     description = "Command line tool to search snippets on Commandlinefu.com";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/cliapp/default.nix b/pkgs/development/python-modules/cliapp/default.nix
index 497306c293a4a..4b7611c092e24 100644
--- a/pkgs/development/python-modules/cliapp/default.nix
+++ b/pkgs/development/python-modules/cliapp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , sphinx
@@ -21,7 +21,7 @@ buildPythonPackage {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://liw.fi/cliapp/";
     description = "Python framework for Unix command line programs";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/click-completion/default.nix b/pkgs/development/python-modules/click-completion/default.nix
index 3fd41f54f66ce..61a154286325b 100644
--- a/pkgs/development/python-modules/click-completion/default.nix
+++ b/pkgs/development/python-modules/click-completion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k,
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k,
   click, jinja2, shellingham, six
 }:
 
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ click jinja2 shellingham six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Add or enhance bash, fish, zsh and powershell completion in Click";
     homepage = "https://github.com/click-contrib/click-completion";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/click-didyoumean/default.nix b/pkgs/development/python-modules/click-didyoumean/default.nix
index 58d7da4fd391d..8d3c3ba3e240e 100644
--- a/pkgs/development/python-modules/click-didyoumean/default.nix
+++ b/pkgs/development/python-modules/click-didyoumean/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   click
 }:
 
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ click ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enable git-like did-you-mean feature in click";
     homepage = "https://github.com/click-contrib/click-didyoumean";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/click-help-colors/default.nix b/pkgs/development/python-modules/click-help-colors/default.nix
index e66f23d09b21b..dbe4e33ca84c0 100644
--- a/pkgs/development/python-modules/click-help-colors/default.nix
+++ b/pkgs/development/python-modules/click-help-colors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , click, pytest
 }:
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "click_help_colors" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Colorization of help messages in Click";
     homepage    = "https://github.com/r-m-n/click-help-colors";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/click-log/default.nix b/pkgs/development/python-modules/click-log/default.nix
index dd2b4b158ed5f..4aa63dd453780 100644
--- a/pkgs/development/python-modules/click-log/default.nix
+++ b/pkgs/development/python-modules/click-log/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, click }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, click }:
 
 buildPythonPackage rec {
   pname = "click-log";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ click ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/click-contrib/click-log/";
     description = "Logging integration for Click";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/click-plugins/default.nix b/pkgs/development/python-modules/click-plugins/default.nix
index a8c1d7a489ff0..c2b25341e17cd 100644
--- a/pkgs/development/python-modules/click-plugins/default.nix
+++ b/pkgs/development/python-modules/click-plugins/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   click, pytest
 }:
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     pytest
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extension module for click to enable registering CLI commands";
     homepage = "https://github.com/click-contrib/click-plugins";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/click-repl/default.nix b/pkgs/development/python-modules/click-repl/default.nix
index 03c9520014c41..23adb12da6582 100644
--- a/pkgs/development/python-modules/click-repl/default.nix
+++ b/pkgs/development/python-modules/click-repl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, click, prompt_toolkit }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, click, prompt_toolkit }:
 
 buildPythonPackage rec {
   pname = "click-repl";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ click prompt_toolkit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/click-contrib/click-repl";
     description = "Subcommand REPL for click apps";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/clickclick/default.nix b/pkgs/development/python-modules/clickclick/default.nix
index b2e23dc55bdb4..e211b955ac849 100644
--- a/pkgs/development/python-modules/clickclick/default.nix
+++ b/pkgs/development/python-modules/clickclick/default.nix
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     "test_choice_default"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Click command line utilities";
     homepage = "https://github.com/hjacobs/python-clickclick/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/cligj/default.nix b/pkgs/development/python-modules/cligj/default.nix
index 91124cd21f4b9..f9d953d8536e1 100644
--- a/pkgs/development/python-modules/cligj/default.nix
+++ b/pkgs/development/python-modules/cligj/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , click, pytest, glibcLocales
 }:
 
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     LC_ALL=en_US.utf-8 pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Click params for commmand line interfaces to GeoJSON";
     homepage = "https://github.com/mapbox/cligj";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/clint/default.nix b/pkgs/development/python-modules/clint/default.nix
index 329cf4f07ccf6..133fc0de55c62 100644
--- a/pkgs/development/python-modules/clint/default.nix
+++ b/pkgs/development/python-modules/clint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -29,7 +29,7 @@ buildPythonPackage rec {
   buildInputs = [ mock nose nose_progressive pkgs.glibcLocales ];
   propagatedBuildInputs = [ pillow blessings args ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kennethreitz/clint";
     description = "Python Command Line Interface Tools";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/clize/default.nix b/pkgs/development/python-modules/clize/default.nix
index e2ef3ea5bb1c5..c9c3f5c905cea 100644
--- a/pkgs/development/python-modules/clize/default.nix
+++ b/pkgs/development/python-modules/clize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , dateutil
@@ -45,7 +45,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "clize" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line argument parsing for Python";
     homepage = "https://github.com/epsy/clize";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/closure-linter/default.nix b/pkgs/development/python-modules/closure-linter/default.nix
index b814455da3ff6..75f5ba0b449ec 100644
--- a/pkgs/development/python-modules/closure-linter/default.nix
+++ b/pkgs/development/python-modules/closure-linter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , isPy3k
@@ -24,7 +24,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ gflags ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Checks JavaScript files against Google's style guide.";
     homepage = "https://developers.google.com/closure/utilities/";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/development/python-modules/cloudpickle/default.nix b/pkgs/development/python-modules/cloudpickle/default.nix
index cd21e125ccef3..e5b4a63a564ea 100644
--- a/pkgs/development/python-modules/cloudpickle/default.nix
+++ b/pkgs/development/python-modules/cloudpickle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, pytest, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, pytest, mock }:
 
 buildPythonPackage rec {
   pname = "cloudpickle";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # TypeError: cannot serialize '_io.FileIO' object
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extended pickling support for Python objects";
     homepage = "https://github.com/cloudpipe/cloudpickle";
     license = with licenses; [ bsd3 ];
diff --git a/pkgs/development/python-modules/clustershell/default.nix b/pkgs/development/python-modules/clustershell/default.nix
index 86d44aed532cb..a0e744f9919dc 100644
--- a/pkgs/development/python-modules/clustershell/default.nix
+++ b/pkgs/development/python-modules/clustershell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pyyaml, openssh
+{ lib, stdenv, buildPythonPackage, fetchPypi, pyyaml, openssh
 , nose, bc, hostname, coreutils, bash, gnused
 }:
 
@@ -80,7 +80,7 @@ buildPythonPackage rec {
     tests/*.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scalable Python framework for cluster administration";
     homepage = "https://cea-hpc.github.io/clustershell";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/cmd2/default.nix b/pkgs/development/python-modules/cmd2/default.nix
index 889ef3fba15ce..be4e64f760eef 100644
--- a/pkgs/development/python-modules/cmd2/default.nix
+++ b/pkgs/development/python-modules/cmd2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pythonOlder, isPy3k
+{ lib, stdenv, fetchPypi, buildPythonPackage, pythonOlder, isPy3k
 , pyperclip, six, pyparsing, vim, wcwidth, colorama, attrs
 , contextlib2 ? null, typing ? null, setuptools_scm
 , pytest, mock ? null, pytest-mock
@@ -52,7 +52,7 @@ buildPythonPackage rec {
     py.test -k 'not test_path_completion_user_expansion'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enhancements for standard library's cmd module";
     homepage = "https://github.com/python-cmd2/cmd2";
     maintainers = with maintainers; [ teto ];
diff --git a/pkgs/development/python-modules/cmdline/default.nix b/pkgs/development/python-modules/cmdline/default.nix
index 39f1f9de0c675..4249ed7164b9d 100644
--- a/pkgs/development/python-modules/cmdline/default.nix
+++ b/pkgs/development/python-modules/cmdline/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pyyaml }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pyyaml }:
 
 buildPythonPackage rec {
   pname = "cmdline";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   doCheck = false;
   propagatedBuildInputs = [ pyyaml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for consistent command line tools";
     homepage = "https://github.com/rca/cmdline";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/cmdtest/default.nix b/pkgs/development/python-modules/cmdtest/default.nix
index 5c53cafdb4e14..5bb4ef79a20c9 100644
--- a/pkgs/development/python-modules/cmdtest/default.nix
+++ b/pkgs/development/python-modules/cmdtest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , cliapp
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # TODO: cmdtest tests must be run before the buildPhase
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://liw.fi/cmdtest/";
     description = "Black box tests Unix command line tools";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/cocotb/default.nix b/pkgs/development/python-modules/cocotb/default.nix
index 9e6ebbe260e4f..e95900d17b527 100644
--- a/pkgs/development/python-modules/cocotb/default.nix
+++ b/pkgs/development/python-modules/cocotb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, setuptools, swig, verilog }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, setuptools, swig, verilog }:
 
 buildPythonPackage rec {
   pname = "cocotb";
@@ -43,7 +43,7 @@ buildPythonPackage rec {
     make test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Coroutine based cosimulation library for writing VHDL and Verilog testbenches in Python";
     homepage = "https://github.com/cocotb/cocotb";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cogapp/default.nix b/pkgs/development/python-modules/cogapp/default.nix
index 2962e65a7fb69..019faeaebc305 100644
--- a/pkgs/development/python-modules/cogapp/default.nix
+++ b/pkgs/development/python-modules/cogapp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "cogapp";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # there are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A code generator for executing Python snippets in source files";
     homepage = "http://nedbatchelder.com/code/cog";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/coilmq/default.nix b/pkgs/development/python-modules/coilmq/default.nix
index 8b103b55171d4..bc0b6af146af8 100644
--- a/pkgs/development/python-modules/coilmq/default.nix
+++ b/pkgs/development/python-modules/coilmq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , stompclient, python-daemon, redis, pid, pytest, six, click, coverage
 , sqlalchemy }:
 
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # The teste data is not included in the distribution
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple, lightweight, and easily extensible STOMP message broker";
     homepage = "https://github.com/hozn/coilmq/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/colanderalchemy/default.nix b/pkgs/development/python-modules/colanderalchemy/default.nix
index aba5ebf609b88..a5b29af1c31a3 100644
--- a/pkgs/development/python-modules/colanderalchemy/default.nix
+++ b/pkgs/development/python-modules/colanderalchemy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , unittest2
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Tests are not included in Pypi
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Autogenerate Colander schemas based on SQLAlchemy models";
     homepage = "https://github.com/stefanofontanelli/ColanderAlchemy";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/colorama/default.nix b/pkgs/development/python-modules/colorama/default.nix
index 0634918458272..6778c6acadb8d 100644
--- a/pkgs/development/python-modules/colorama/default.nix
+++ b/pkgs/development/python-modules/colorama/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
   pname = "colorama";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tartley/colorama";
     license = licenses.bsd3;
     description = "Cross-platform colored terminal text";
diff --git a/pkgs/development/python-modules/colorcet/default.nix b/pkgs/development/python-modules/colorcet/default.nix
index a80895de3d154..05304175b71d3 100644
--- a/pkgs/development/python-modules/colorcet/default.nix
+++ b/pkgs/development/python-modules/colorcet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , param
@@ -40,7 +40,7 @@ buildPythonPackage rec {
     pytest colorcet -k 'not matplotlib_default_colormap_plot'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of perceptually uniform colormaps";
     homepage = "https://colorcet.pyviz.org";
     license = licenses.cc-by-40;
diff --git a/pkgs/development/python-modules/colorclass/default.nix b/pkgs/development/python-modules/colorclass/default.nix
index 4a627cab5451a..08da356e222ea 100644
--- a/pkgs/development/python-modules/colorclass/default.nix
+++ b/pkgs/development/python-modules/colorclass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "colorclass";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Robpol86/colorclass";
     license = licenses.mit;
     description = "Automatic support for console colors";
diff --git a/pkgs/development/python-modules/colored/default.nix b/pkgs/development/python-modules/colored/default.nix
index 2d2cac3da1b93..5caa0cad2f6fa 100644
--- a/pkgs/development/python-modules/colored/default.nix
+++ b/pkgs/development/python-modules/colored/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No proper test suite
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/dslackw/colored";
     description = "Simple library for color and formatting to terminal";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/colorlog/default.nix b/pkgs/development/python-modules/colorlog/default.nix
index 0b40284fd5eb0..829f157fced02 100644
--- a/pkgs/development/python-modules/colorlog/default.nix
+++ b/pkgs/development/python-modules/colorlog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "colorlog";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck =  [ "colorlog" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Log formatting with colors";
     homepage = "https://github.com/borntyping/python-colorlog";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/colour/default.nix b/pkgs/development/python-modules/colour/default.nix
index d0f802072a38f..6a6ad9d4946a3 100644
--- a/pkgs/development/python-modules/colour/default.nix
+++ b/pkgs/development/python-modules/colour/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, d2to1 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, d2to1 }:
 
 buildPythonPackage rec {
   pname = "colour";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   buildInputs = [ d2to1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts and manipulates common color representation (RGB, HSV, web, ...)";
     homepage = "https://github.com/vaab/colour";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/configobj/default.nix b/pkgs/development/python-modules/configobj/default.nix
index 82ca70c46795e..d0988689275e4 100644
--- a/pkgs/development/python-modules/configobj/default.nix
+++ b/pkgs/development/python-modules/configobj/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage
+{ lib, stdenv, buildPythonPackage
 , fetchFromGitHub
 , six
 , mock, pytest
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   checkInputs = [ mock pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Config file reading, writing and validation";
     homepage = "https://pypi.python.org/pypi/configobj";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/configparser/4.nix b/pkgs/development/python-modules/configparser/4.nix
index 9c6c631d9c277..cbef6fd2ce7fe 100644
--- a/pkgs/development/python-modules/configparser/4.nix
+++ b/pkgs/development/python-modules/configparser/4.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm }:
 
 buildPythonPackage rec {
   pname = "configparser";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     export LC_ALL=${if stdenv.isDarwin then "en_US" else "C"}.UTF-8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Updated configparser from Python 3.7 for Python 2.6+.";
     license = licenses.mit;
     homepage = "https://github.com/jaraco/configparser";
diff --git a/pkgs/development/python-modules/configparser/default.nix b/pkgs/development/python-modules/configparser/default.nix
index ad9a13c28bf0c..e8610f053da61 100644
--- a/pkgs/development/python-modules/configparser/default.nix
+++ b/pkgs/development/python-modules/configparser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm
 , toml
 }:
 
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     export LC_ALL=${if stdenv.isDarwin then "en_US" else "C"}.UTF-8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Updated configparser from Python 3.7 for Python 2.6+.";
     license = licenses.mit;
     homepage = "https://github.com/jaraco/configparser";
diff --git a/pkgs/development/python-modules/configshell/default.nix b/pkgs/development/python-modules/configshell/default.nix
index 6a21c1074ea7f..ba3700962bf64 100644
--- a/pkgs/development/python-modules/configshell/default.nix
+++ b/pkgs/development/python-modules/configshell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, pyparsing, six, urwid }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, pyparsing, six, urwid }:
 
 buildPythonPackage rec {
   pname = "configshell";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyparsing six urwid ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python library for building configuration shells";
     homepage = "https://github.com/open-iscsi/configshell-fb";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/confluent-kafka/default.nix b/pkgs/development/python-modules/confluent-kafka/default.nix
index 8048d6f78a276..f3e8b1c943b1a 100644
--- a/pkgs/development/python-modules/confluent-kafka/default.nix
+++ b/pkgs/development/python-modules/confluent-kafka/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, rdkafka, requests, avro3k, avro, futures, enum34 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, rdkafka, requests, avro3k, avro, futures, enum34 }:
 
 buildPythonPackage rec {
   version = "1.5.0";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # No tests in PyPi Tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Confluent's Apache Kafka client for Python";
     homepage = "https://github.com/confluentinc/confluent-kafka-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/constantly/default.nix b/pkgs/development/python-modules/constantly/default.nix
index 9b7222b7bbc61..189573699b915 100644
--- a/pkgs/development/python-modules/constantly/default.nix
+++ b/pkgs/development/python-modules/constantly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 }:
 buildPythonPackage rec {
   pname = "constantly";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "0dgwdla5kfpqz83hfril716inm41hgn9skxskvi77605jbmp4qsq";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/twisted/constantly";
     description = "symbolic constant support";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/construct/default.nix b/pkgs/development/python-modules/construct/default.nix
index cf9ab42f3259b..bb334f11c756a 100644
--- a/pkgs/development/python-modules/construct/default.nix
+++ b/pkgs/development/python-modules/construct/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
 , six, pytestCheckHook, pytest-benchmark, numpy, arrow, ruamel_yaml
 }:
 
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   pytestFlagsArray = [ "--benchmark-disable" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful declarative parser (and builder) for binary data";
     homepage = "https://construct.readthedocs.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/consul/default.nix b/pkgs/development/python-modules/consul/default.nix
index 589076481c902..3978b14484ac8 100644
--- a/pkgs/development/python-modules/consul/default.nix
+++ b/pkgs/development/python-modules/consul/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , requests, six, pytest }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests distributed. https://github.com/cablehead/python-consul/issues/133
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client for Consul (https://www.consul.io/)";
     homepage = "https://github.com/cablehead/python-consul";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/contexter/default.nix b/pkgs/development/python-modules/contexter/default.nix
index 0fa72dfa687de..d8b74d4fedba1 100644
--- a/pkgs/development/python-modules/contexter/default.nix
+++ b/pkgs/development/python-modules/contexter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "contexter";
@@ -9,6 +9,6 @@ buildPythonPackage rec {
     sha256 = "c730890b1a915051414a6350d8ea1cddca7d01d8f756badedb30b9bf305ea0a8";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
   };
 }
diff --git a/pkgs/development/python-modules/convertdate/default.nix b/pkgs/development/python-modules/convertdate/default.nix
index c60d4778012cb..f28923002f70d 100644
--- a/pkgs/development/python-modules/convertdate/default.nix
+++ b/pkgs/development/python-modules/convertdate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pymeeus, pytz }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pymeeus, pytz }:
 
 buildPythonPackage rec {
   pname = "convertdate";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pymeeus pytz ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/fitnr/convertdate";
     description = "Utils for converting between date formats and calculating holidays";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/cookiecutter/default.nix b/pkgs/development/python-modules/cookiecutter/default.nix
index 23bc8bcec524e..f9a4fe9820828 100644
--- a/pkgs/development/python-modules/cookiecutter/default.nix
+++ b/pkgs/development/python-modules/cookiecutter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPyPy
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPyPy
 , pytest, pytestcov, pytest-mock, freezegun
 , jinja2, future, binaryornot, click, whichcraft, poyo, jinja2_time, requests
 , python-slugify }:
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/audreyr/cookiecutter";
     description = "A command-line utility that creates projects from project templates";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cookies/default.nix b/pkgs/development/python-modules/cookies/default.nix
index 7ae110fef3c2c..59d2214f758e6 100644
--- a/pkgs/development/python-modules/cookies/default.nix
+++ b/pkgs/development/python-modules/cookies/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "cookies";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Friendlier RFC 6265-compliant cookie parser/renderer";
     homepage = "https://github.com/sashahart/cookies";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/coreapi/default.nix b/pkgs/development/python-modules/coreapi/default.nix
index 521b06755cec8..8ac69a457396e 100644
--- a/pkgs/development/python-modules/coreapi/default.nix
+++ b/pkgs/development/python-modules/coreapi/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   fetchFromGitHub,
   buildPythonPackage,
   django,
@@ -35,7 +35,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client library for Core API";
     homepage = "https://github.com/core-api/python-client";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/coreschema/default.nix b/pkgs/development/python-modules/coreschema/default.nix
index 5b5ca3f5044eb..73167dea8a7dd 100644
--- a/pkgs/development/python-modules/coreschema/default.nix
+++ b/pkgs/development/python-modules/coreschema/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   fetchFromGitHub,
   buildPythonPackage,
   jinja2,
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client library for Core Schema";
     homepage = "https://github.com/ivegotasthma/python-coreschema";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cornice/default.nix b/pkgs/development/python-modules/cornice/default.nix
index d09cffb31d64a..10c559201931c 100644
--- a/pkgs/development/python-modules/cornice/default.nix
+++ b/pkgs/development/python-modules/cornice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyramid
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # tests not packaged with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mozilla-services/cornice";
     description = "Build Web Services with Pyramid";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/cot/default.nix b/pkgs/development/python-modules/cot/default.nix
index 8952d79634d7a..89e26545d7950 100644
--- a/pkgs/development/python-modules/cot/default.nix
+++ b/pkgs/development/python-modules/cot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder, isPy3k
 , argcomplete, colorlog, pyvmomi, requests, verboselogs
 , psutil, pyopenssl, setuptools
 , mock, pytest, pytest-mock, pytestCheckHook, qemu
@@ -43,7 +43,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace "'argparse'," ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Common OVF Tool";
     longDescription = ''
       COT (the Common OVF Tool) is a tool for editing Open Virtualization Format (.ovf, .ova) virtual appliances,
diff --git a/pkgs/development/python-modules/cov-core/default.nix b/pkgs/development/python-modules/cov-core/default.nix
index ad85218709e86..44461a8ca9fb0 100644
--- a/pkgs/development/python-modules/cov-core/default.nix
+++ b/pkgs/development/python-modules/cov-core/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, coverage }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, coverage }:
 
 buildPythonPackage rec {
   pname = "cov-core";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ coverage ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin core for use by pytest-cov, nose-cov and nose2-cov";
   };
 }
diff --git a/pkgs/development/python-modules/cppheaderparser/default.nix b/pkgs/development/python-modules/cppheaderparser/default.nix
index 688d394198f4a..b51499de449c9 100644
--- a/pkgs/development/python-modules/cppheaderparser/default.nix
+++ b/pkgs/development/python-modules/cppheaderparser/default.nix
@@ -1,7 +1,7 @@
 { buildPythonPackage
 , fetchPypi
 , ply
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "CppHeaderParser" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parse C++ header files using ply.lex to generate navigable class tree representing the class structure";
     homepage = "https://sourceforge.net/projects/cppheaderparser/";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/crate/default.nix b/pkgs/development/python-modules/crate/default.nix
index 1cae57c6faf76..37e49210009ae 100644
--- a/pkgs/development/python-modules/crate/default.nix
+++ b/pkgs/development/python-modules/crate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , urllib3
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     pytestCheckHook
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/crate/crate-python";
     description = "A Python client library for CrateDB";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/crayons/default.nix b/pkgs/development/python-modules/crayons/default.nix
index f262d289af71f..c93bf71687fb2 100644
--- a/pkgs/development/python-modules/crayons/default.nix
+++ b/pkgs/development/python-modules/crayons/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, colorama }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, colorama }:
 
 buildPythonPackage rec {
   pname = "crayons";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ colorama ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TextUI colors for Python";
     homepage = "https://github.com/kennethreitz/crayons";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/crc16/default.nix b/pkgs/development/python-modules/crc16/default.nix
index 01f5bb8a7e537..1e3c9cbbf4ff9 100644
--- a/pkgs/development/python-modules/crc16/default.nix
+++ b/pkgs/development/python-modules/crc16/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "crc16";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "15nkx0pa4lskwin84flpk8fsw3jqg6wic6v3s83syjqg76h6my61";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://code.google.com/archive/p/pycrc16/";
     description = "Python library for calculating CRC16";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/crccheck/default.nix b/pkgs/development/python-modules/crccheck/default.nix
index 92a4cc8a84150..1ddf2a2ba6843 100644
--- a/pkgs/development/python-modules/crccheck/default.nix
+++ b/pkgs/development/python-modules/crccheck/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     extension = "zip";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for CRCs and checksums";
     homepage = "https://bitbucket.org/martin_scharrer/crccheck";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/crcmod/default.nix b/pkgs/development/python-modules/crcmod/default.nix
index 47e1b4097d3d0..488b723d89fd4 100644
--- a/pkgs/development/python-modules/crcmod/default.nix
+++ b/pkgs/development/python-modules/crcmod/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "crcmod";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "07k0hgr42vw2j92cln3klxka81f33knd7459cn3d8aszvfh52w6w";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python module for generating objects that compute the Cyclic Redundancy Check (CRC)";
     homepage = "http://crcmod.sourceforge.net/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/credstash/default.nix b/pkgs/development/python-modules/credstash/default.nix
index 1f9b4b28f2949..ca5e1fe334a03 100644
--- a/pkgs/development/python-modules/credstash/default.nix
+++ b/pkgs/development/python-modules/credstash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, cryptography, boto3, pyyaml, docutils, pytest, fetchpatch }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, cryptography, boto3, pyyaml, docutils, pytest, fetchpatch }:
 
 buildPythonPackage rec {
   pname = "credstash";
@@ -30,7 +30,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility for managing secrets in the cloud using AWS KMS and DynamoDB";
     homepage = "https://github.com/LuminalOSS/credstash";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/cryptacular/default.nix b/pkgs/development/python-modules/cryptacular/default.nix
index 5ec1ccacae99b..dc97e96e4f5d9 100644
--- a/pkgs/development/python-modules/cryptacular/default.nix
+++ b/pkgs/development/python-modules/cryptacular/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, pythonAtLeast
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, pythonAtLeast
 , coverage, nose, pbkdf2 }:
 
 buildPythonPackage rec {
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # https://bitbucket.org/dholth/cryptacular/issues/11
   disabled = isPy27 || pythonAtLeast "3.6";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ domenkozar ];
   };
 }
diff --git a/pkgs/development/python-modules/cryptography/3.3.nix b/pkgs/development/python-modules/cryptography/3.3.nix
index a76e62dd4ddbb..a95318241584a 100644
--- a/pkgs/development/python-modules/cryptography/3.3.nix
+++ b/pkgs/development/python-modules/cryptography/3.3.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -65,7 +65,7 @@ buildPythonPackage rec {
   # can do until nix 1.11's release
   __impureHostDeps = [ "/usr/lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A package which provides cryptographic recipes and primitives";
     longDescription = ''
       Cryptography includes both high level recipes and low level interfaces to
diff --git a/pkgs/development/python-modules/cryptography/default.nix b/pkgs/development/python-modules/cryptography/default.nix
index 0bee19c3f4f3c..bae494989c7d4 100644
--- a/pkgs/development/python-modules/cryptography/default.nix
+++ b/pkgs/development/python-modules/cryptography/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -63,7 +63,7 @@ buildPythonPackage rec {
   # can do until nix 1.11's release
   __impureHostDeps = [ "/usr/lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A package which provides cryptographic recipes and primitives";
     longDescription = ''
       Cryptography includes both high level recipes and low level interfaces to
diff --git a/pkgs/development/python-modules/cssmin/default.nix b/pkgs/development/python-modules/cssmin/default.nix
index deace3233b247..a6f6f3c956ae8 100644
--- a/pkgs/development/python-modules/cssmin/default.nix
+++ b/pkgs/development/python-modules/cssmin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "cssmin";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python port of the YUI CSS compression algorithm";
     homepage = "https://github.com/zacharyvoase/cssmin";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cssselect/default.nix b/pkgs/development/python-modules/cssselect/default.nix
index 00e6c0f7a627b..fe13fa9582ea1 100644
--- a/pkgs/development/python-modules/cssselect/default.nix
+++ b/pkgs/development/python-modules/cssselect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "cssselect";
@@ -12,6 +12,6 @@ buildPythonPackage rec {
   # AttributeError: 'module' object has no attribute 'tests'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
   };
 }
diff --git a/pkgs/development/python-modules/cssutils/default.nix b/pkgs/development/python-modules/cssutils/default.nix
index 1db154ac1b8c5..ea3ac6236e90e 100644
--- a/pkgs/development/python-modules/cssutils/default.nix
+++ b/pkgs/development/python-modules/cssutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, mock }:
 
 buildPythonPackage rec {
   pname = "cssutils";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # couple of failing tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python package to parse and build CSS";
     homepage = "http://cthedot.de/cssutils/";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/cupy/default.nix b/pkgs/development/python-modules/cupy/default.nix
index 2d2a2be485587..09685d392d6a4 100644
--- a/pkgs/development/python-modules/cupy/default.nix
+++ b/pkgs/development/python-modules/cupy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage
+{ lib, stdenv, buildPythonPackage
 , fetchPypi, isPy3k, linuxPackages
 , fastrlock, numpy, six, wheel, pytest, mock, setuptools
 , cudatoolkit, cudnn, nccl
@@ -40,7 +40,7 @@ buildPythonPackage rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A NumPy-compatible matrix library accelerated by CUDA";
     homepage = "https://cupy.chainer.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/curtsies/default.nix b/pkgs/development/python-modules/curtsies/default.nix
index 9f45c2fd2ba61..f860f2ae5ebc1 100644
--- a/pkgs/development/python-modules/curtsies/default.nix
+++ b/pkgs/development/python-modules/curtsies/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, pythonOlder, blessings, mock, nose, pyte, wcwidth, typing }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, pythonOlder, blessings, mock, nose, pyte, wcwidth, typing }:
 
 buildPythonPackage rec {
   pname = "curtsies";
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     nosetests tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Curses-like terminal wrapper, with colored strings!";
     homepage = "https://github.com/bpython/curtsies";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/curve25519-donna/default.nix b/pkgs/development/python-modules/curve25519-donna/default.nix
index 1672557f1b95c..e42f4021a6f2b 100644
--- a/pkgs/development/python-modules/curve25519-donna/default.nix
+++ b/pkgs/development/python-modules/curve25519-donna/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "curve25519-donna";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "1w0vkjyh4ki9n98lr2hg09f1lr1g3pz48kshrlic01ba6pasj60q";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper for the portable curve25519-donna implementation";
     homepage = "http://code.google.com/p/curve25519-donna/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cx_freeze/default.nix b/pkgs/development/python-modules/cx_freeze/default.nix
index e4350bada3317..14a585617c642 100644
--- a/pkgs/development/python-modules/cx_freeze/default.nix
+++ b/pkgs/development/python-modules/cx_freeze/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchPypi, ncurses, importlib-metadata }:
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchPypi, ncurses, importlib-metadata }:
 
 buildPythonPackage rec {
   pname = "cx_Freeze";
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # fails to find Console even though it exists on python 3.x
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of scripts and modules for freezing Python scripts into executables";
     homepage = "http://cx-freeze.sourceforge.net/";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/cx_oracle/default.nix b/pkgs/development/python-modules/cx_oracle/default.nix
index 440e43cf81c81..ceacad12059d7 100644
--- a/pkgs/development/python-modules/cx_oracle/default.nix
+++ b/pkgs/development/python-modules/cx_oracle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, odpic }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, odpic }:
 
 buildPythonPackage rec {
   pname = "cx_Oracle";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # Check need an Oracle database to run
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python interface to Oracle";
     homepage = "https://oracle.github.io/python-cx_Oracle";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/cymem/default.nix b/pkgs/development/python-modules/cymem/default.nix
index e563e6615fe81..d805ba5de1f94 100644
--- a/pkgs/development/python-modules/cymem/default.nix
+++ b/pkgs/development/python-modules/cymem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , cython
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover -p "*test*"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cython memory pool for RAII-style memory management";
     homepage = "https://github.com/explosion/cymem";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/cypari2/default.nix b/pkgs/development/python-modules/cypari2/default.nix
index ee2c9ded18df0..8a0adb3d6c964 100644
--- a/pkgs/development/python-modules/cypari2/default.nix
+++ b/pkgs/development/python-modules/cypari2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , python
 , fetchPypi
@@ -46,7 +46,7 @@ buildPythonPackage rec {
     make check
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cython bindings for PARI";
     license = licenses.gpl2;
     maintainers = teams.sage.members;
diff --git a/pkgs/development/python-modules/daemonize/default.nix b/pkgs/development/python-modules/daemonize/default.nix
index 9db823806843d..30d4f1bd71468 100644
--- a/pkgs/development/python-modules/daemonize/default.nix
+++ b/pkgs/development/python-modules/daemonize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1hwbl3gf9fdds9sc14zgjyjisjvxidrvqc11xlbb0b6jz17nw0nx";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library to enable your code run as a daemon process on Unix-like systems";
     homepage = "https://github.com/thesharp/daemonize";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/daphne/default.nix b/pkgs/development/python-modules/daphne/default.nix
index cbd80333b2f08..fc48f91501245 100644
--- a/pkgs/development/python-modules/daphne/default.nix
+++ b/pkgs/development/python-modules/daphne/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchFromGitHub
 , asgiref, autobahn, twisted, pytestrunner
 , hypothesis, pytest, pytest-asyncio, service-identity, pyopenssl
 }:
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django ASGI (HTTP/WebSocket) server";
     license = licenses.bsd3;
     homepage = "https://github.com/django/daphne";
diff --git a/pkgs/development/python-modules/darcsver/default.nix b/pkgs/development/python-modules/darcsver/default.nix
index 33c7eb2d11687..6484d84253b57 100644
--- a/pkgs/development/python-modules/darcsver/default.nix
+++ b/pkgs/development/python-modules/darcsver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, mock }:
 
 buildPythonPackage rec {
   pname = "darcsver";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # AttributeError: 'module' object has no attribute 'test_darcsver'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Darcsver, generate a version number from Darcs history";
     homepage = "https://pypi.python.org/pypi/darcsver";
     license = "BSD-style";
diff --git a/pkgs/development/python-modules/dask-glm/default.nix b/pkgs/development/python-modules/dask-glm/default.nix
index 0a88323fafd8c..1db03b66ffb01 100644
--- a/pkgs/development/python-modules/dask-glm/default.nix
+++ b/pkgs/development/python-modules/dask-glm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cloudpickle
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     py.test dask_glm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dask/dask-glm/";
     description = "Generalized Linear Models with Dask";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dask-image/default.nix b/pkgs/development/python-modules/dask-image/default.nix
index 453cb715b12b7..eac503c2f8556 100644
--- a/pkgs/development/python-modules/dask-image/default.nix
+++ b/pkgs/development/python-modules/dask-image/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -39,7 +39,7 @@ buildPythonPackage rec {
     pytest --ignore=tests/test_dask_image/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dask/dask-image";
     description = "Distributed image processing";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/dask-jobqueue/default.nix b/pkgs/development/python-modules/dask-jobqueue/default.nix
index 52e22a093311b..be27399b71f63 100644
--- a/pkgs/development/python-modules/dask-jobqueue/default.nix
+++ b/pkgs/development/python-modules/dask-jobqueue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , dask
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     py.test dask_jobqueue/tests/test_jobqueue_core.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dask/dask-jobqueue";
     description = "Deploy Dask on job schedulers like PBS, SLURM, and SGE";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dask-ml/default.nix b/pkgs/development/python-modules/dask-ml/default.nix
index 441c698c2ad09..4d3aa8e79a058 100644
--- a/pkgs/development/python-modules/dask-ml/default.nix
+++ b/pkgs/development/python-modules/dask-ml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -55,7 +55,7 @@ buildPythonPackage rec {
     "dask_ml.utils"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dask/dask-ml";
     description = "Scalable Machine Learn with Dask";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dask-mpi/default.nix b/pkgs/development/python-modules/dask-mpi/default.nix
index 2794bcba7aed5..f2d8737b38e98 100644
--- a/pkgs/development/python-modules/dask-mpi/default.nix
+++ b/pkgs/development/python-modules/dask-mpi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , dask
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   # hardcoded mpirun path in tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dask/dask-mpi";
     description = "Deploy Dask using mpi4py";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dask-xgboost/default.nix b/pkgs/development/python-modules/dask-xgboost/default.nix
index 9730ca8a2feb2..c60f628d72eb8 100644
--- a/pkgs/development/python-modules/dask-xgboost/default.nix
+++ b/pkgs/development/python-modules/dask-xgboost/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , xgboost
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dask/dask-xgboost";
     description = "Interactions between Dask and XGBoost";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/databricks-cli/default.nix b/pkgs/development/python-modules/databricks-cli/default.nix
index 2184a7e419401..30001b781d283 100644
--- a/pkgs/development/python-modules/databricks-cli/default.nix
+++ b/pkgs/development/python-modules/databricks-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , click
 , requests
 , tabulate
@@ -32,7 +32,7 @@ buildPythonPackage rec {
     configparser
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/databricks/databricks-cli";
     description = "A command line interface for Databricks";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/dataclasses/default.nix b/pkgs/development/python-modules/dataclasses/default.nix
index 5cfaf237059d5..a88995937d838 100644
--- a/pkgs/development/python-modules/dataclasses/default.nix
+++ b/pkgs/development/python-modules/dataclasses/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy36 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy36 }:
 
 buildPythonPackage rec {
   pname = "dataclasses";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "8479067f342acf957dc82ec415d355ab5edb7e7646b90dc6e2fd1d96ad084c97";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of PEP 557: Data Classes";
     homepage = "https://github.com/ericvsmith/dataclasses";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/datadiff/default.nix b/pkgs/development/python-modules/datadiff/default.nix
index 0c30f2f84689f..6804623522758 100644
--- a/pkgs/development/python-modules/datadiff/default.nix
+++ b/pkgs/development/python-modules/datadiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   buildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DataDiff";
     homepage = "https://sourceforge.net/projects/datadiff/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/datamodeldict/default.nix b/pkgs/development/python-modules/datamodeldict/default.nix
index e4c10d8c22c76..f3eab1d1d4e2b 100644
--- a/pkgs/development/python-modules/datamodeldict/default.nix
+++ b/pkgs/development/python-modules/datamodeldict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , xmltodict
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/usnistgov/DataModelDict/";
     description = "Class allowing for data models equivalently represented as Python dictionaries, JSON, and XML";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/dateutil/default.nix b/pkgs/development/python-modules/dateutil/default.nix
index 88024265d9482..a6aca68ef2938 100644
--- a/pkgs/development/python-modules/dateutil/default.nix
+++ b/pkgs/development/python-modules/dateutil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six, setuptools_scm, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six, setuptools_scm, pytest }:
 buildPythonPackage rec {
   pname = "python-dateutil";
   version = "2.8.1";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Requires fixing
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful extensions to the standard datetime module";
     homepage = "https://pypi.python.org/pypi/python-dateutil";
     license = "BSD-style";
diff --git a/pkgs/development/python-modules/datrie/default.nix b/pkgs/development/python-modules/datrie/default.nix
index 7cb30937e0dbf..c7f74730c1619 100644
--- a/pkgs/development/python-modules/datrie/default.nix
+++ b/pkgs/development/python-modules/datrie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch
 , cython, pytest, pytestrunner, hypothesis }:
 
 buildPythonPackage rec {
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     ./update_c.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Super-fast, efficiently stored Trie for Python";
     homepage = "https://github.com/kmike/datrie";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/dbf/default.nix b/pkgs/development/python-modules/dbf/default.nix
index 9eb6e4f89a269..348f91ea68311 100644
--- a/pkgs/development/python-modules/dbf/default.nix
+++ b/pkgs/development/python-modules/dbf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, aenum, isPy3k, pythonOlder, enum34, python }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, aenum, isPy3k, pythonOlder, enum34, python }:
 
 buildPythonPackage rec {
     pname = "dbf";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
       ${python.interpreter} dbf/test.py
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Pure python package for reading/writing dBase, FoxPro, and Visual FoxPro .dbf files";
       homepage    = "https://pypi.python.org/pypi/dbf";
       license     = licenses.bsd2;
diff --git a/pkgs/development/python-modules/dbfread/default.nix b/pkgs/development/python-modules/dbfread/default.nix
index 9dda98e03acf4..9f78f3fdde1b4 100644
--- a/pkgs/development/python-modules/dbfread/default.nix
+++ b/pkgs/development/python-modules/dbfread/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
     pname = "dbfread";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
       sha256 = "07c8a9af06ffad3f6f03e8fe91ad7d2733e31a26d2b72c4dd4cfbae07ee3b73d";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Read DBF Files with Python";
       homepage    = "https://dbfread.readthedocs.org/";
       license     = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/dbus-next/default.nix b/pkgs/development/python-modules/dbus-next/default.nix
index bbca0df8d8e90..76385ac8023a5 100644
--- a/pkgs/development/python-modules/dbus-next/default.nix
+++ b/pkgs/development/python-modules/dbus-next/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , python
@@ -32,7 +32,7 @@ buildPythonPackage rec {
       -k "not test_peer_interface"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/altdesktop/python-dbus-next";
     description = "A zero-dependency DBus library for Python with asyncio support";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/dbutils/default.nix b/pkgs/development/python-modules/dbutils/default.nix
index ec57e8ada051d..42ae779e0d21a 100644
--- a/pkgs/development/python-modules/dbutils/default.nix
+++ b/pkgs/development/python-modules/dbutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytestCheckHook }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytestCheckHook }:
 
 buildPythonPackage rec {
   version = "2.0";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Database connections for multi-threaded environments";
     homepage = "https://webwareforpython.github.io/DBUtils/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/dcmstack/default.nix b/pkgs/development/python-modules/dcmstack/default.nix
index f06e361dc7169..a6669d0e30dfe 100644
--- a/pkgs/development/python-modules/dcmstack/default.nix
+++ b/pkgs/development/python-modules/dcmstack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pythonAtLeast
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/moloney/dcmstack";
     description = "DICOM to Nifti conversion preserving metadata";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/deap/default.nix b/pkgs/development/python-modules/deap/default.nix
index 5a09c42a9bbf7..21dc9d3832c81 100644
--- a/pkgs/development/python-modules/deap/default.nix
+++ b/pkgs/development/python-modules/deap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, python, numpy, matplotlib, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, python, numpy, matplotlib, nose }:
 
 buildPythonPackage rec {
   pname = "deap";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     ${python.interpreter} setup.py nosetests --verbosity=3
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DEAP is a novel evolutionary computation framework for rapid prototyping and testing of ideas.";
     homepage = "https://github.com/DEAP/deap";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/deluge-client/default.nix b/pkgs/development/python-modules/deluge-client/default.nix
index 8a2bdee1d922e..a271371e22fc7 100644
--- a/pkgs/development/python-modules/deluge-client/default.nix
+++ b/pkgs/development/python-modules/deluge-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "deluge-client";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # it will try to connect to a running instance
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight pure-python rpc client for deluge";
     homepage = "https://github.com/JohnDoee/deluge-client";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/demjson/default.nix b/pkgs/development/python-modules/demjson/default.nix
index aee130f789e5e..988c2815da8c8 100644
--- a/pkgs/development/python-modules/demjson/default.nix
+++ b/pkgs/development/python-modules/demjson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python, buildPythonPackage, fetchPypi, isPy3k }:
+{ lib, stdenv, python, buildPythonPackage, fetchPypi, isPy3k }:
 
 buildPythonPackage rec {
   pname = "demjson";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     ${python.interpreter} test/test_demjson.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Encoder/decoder and lint/validator for JSON (JavaScript Object Notation)";
     homepage = "https://github.com/dmeranda/demjson";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/dependency-injector/default.nix b/pkgs/development/python-modules/dependency-injector/default.nix
index a9c0b517a1344..0c2e2055ff9f3 100644
--- a/pkgs/development/python-modules/dependency-injector/default.nix
+++ b/pkgs/development/python-modules/dependency-injector/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, six, unittest2, pyyaml, flask }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, six, unittest2, pyyaml, flask }:
 
 let
   testPath =
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     unit2 discover -s tests/unit -p "${testPath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dependency injection microframework for Python";
     homepage = "https://github.com/ets-labs/python-dependency-injector";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/deprecated/default.nix b/pkgs/development/python-modules/deprecated/default.nix
index d6e5acdeaf8cb..bca1de711f24f 100644
--- a/pkgs/development/python-modules/deprecated/default.nix
+++ b/pkgs/development/python-modules/deprecated/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage,
+{ lib, stdenv, fetchPypi, buildPythonPackage,
 	wrapt, pytest, tox }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ wrapt ];
   checkInputs = [ pytest ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tantale/deprecated";
     description = "Python @deprecated decorator to deprecate old python classes, functions or methods";
     platforms = platforms.all;
diff --git a/pkgs/development/python-modules/derpconf/default.nix b/pkgs/development/python-modules/derpconf/default.nix
index 9138ef28530a7..f9b8f5dec7c0c 100644
--- a/pkgs/development/python-modules/derpconf/default.nix
+++ b/pkgs/development/python-modules/derpconf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six }:
 
 buildPythonPackage rec {
   pname = "derpconf";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "derpconf abstracts loading configuration files for your app";
     homepage = "https://github.com/globocom/derpconf";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/descartes/default.nix b/pkgs/development/python-modules/descartes/default.nix
index c726492f69d4d..5280ff2417aae 100644
--- a/pkgs/development/python-modules/descartes/default.nix
+++ b/pkgs/development/python-modules/descartes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   matplotlib, shapely
 }:
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     shapely
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library to use Shapely or GeoJSON objects as matplotlib paths";
     homepage = "https://bitbucket.org/sgillies/descartes/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/deskcon/default.nix b/pkgs/development/python-modules/deskcon/default.nix
index 7beaa838a8254..01918445b3421 100644
--- a/pkgs/development/python-modules/deskcon/default.nix
+++ b/pkgs/development/python-modules/deskcon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pyopenssl
 , pkgs
@@ -33,7 +33,7 @@ buildPythonPackage {
     wrapPythonProgramsIn $out/bin "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integrates an Android device into a desktop";
     homepage = "https://github.com/screenfreeze/deskcon-desktop";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/diff_cover/default.nix b/pkgs/development/python-modules/diff_cover/default.nix
index ab9d9493fd604..9672cca46b05d 100644
--- a/pkgs/development/python-modules/diff_cover/default.nix
+++ b/pkgs/development/python-modules/diff_cover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , inflect
 , jinja2
 , jinja2_pluralize
@@ -37,7 +37,7 @@ buildPythonPackage rec {
     pytest -k 'not added_file_pylint_console and not file_does_not_exist'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically find diff lines that need test coverage";
     homepage = "https://github.com/Bachmann1234/diff-cover";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/digi-xbee/default.nix b/pkgs/development/python-modules/digi-xbee/default.nix
index 32d8c47a98011..ad653c6313c64 100644
--- a/pkgs/development/python-modules/digi-xbee/default.nix
+++ b/pkgs/development/python-modules/digi-xbee/default.nix
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Upstream doesn't contain unit tests, only functional tests which require specific hardware
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library to interact with Digi International's XBee radio frequency modules";
     homepage = "https://github.com/digidotcom/xbee-python";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/digitalocean/default.nix b/pkgs/development/python-modules/digitalocean/default.nix
index 404331a495773..f052d8f978e58 100644
--- a/pkgs/development/python-modules/digitalocean/default.nix
+++ b/pkgs/development/python-modules/digitalocean/default.nix
@@ -8,7 +8,7 @@
 , pytestCheckHook
 , requests
 , responses
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -41,7 +41,7 @@ buildPythonPackage rec {
     cd digitalocean
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "digitalocean.com API to manage Droplets and Images";
     homepage = "https://pypi.python.org/pypi/python-digitalocean";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/discid/default.nix b/pkgs/development/python-modules/discid/default.nix
index 2684d4a06a911..1c24402926f37 100644
--- a/pkgs/development/python-modules/discid/default.nix
+++ b/pkgs/development/python-modules/discid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libdiscid, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, libdiscid, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "discid";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
                   "_open_library('${libdiscid}/lib/libdiscid${extension}')"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python binding of libdiscid";
     homepage    = "https://python-discid.readthedocs.org/";
     license     = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/discogs_client/default.nix b/pkgs/development/python-modules/discogs_client/default.nix
index 8d8fb12d4d9be..5e3ac1e1fcde6 100644
--- a/pkgs/development/python-modules/discogs_client/default.nix
+++ b/pkgs/development/python-modules/discogs_client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests, oauthlib }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests, oauthlib }:
 
 buildPythonPackage rec {
   pname = "discogs-client";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests oauthlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official Python API client for Discogs";
     license = licenses.bsd2;
     homepage = "https://github.com/discogs/discogs_client";
diff --git a/pkgs/development/python-modules/distlib/default.nix b/pkgs/development/python-modules/distlib/default.nix
index af9b82e42dc3d..403834a3731c0 100644
--- a/pkgs/development/python-modules/distlib/default.nix
+++ b/pkgs/development/python-modules/distlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "distlib";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # Tests use pypi.org.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Low-level components of distutils2/packaging";
     homepage = "https://distlib.readthedocs.io";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/distorm3/default.nix b/pkgs/development/python-modules/distorm3/default.nix
index 29524240a8a78..e9b8e66d4c990 100644
--- a/pkgs/development/python-modules/distorm3/default.nix
+++ b/pkgs/development/python-modules/distorm3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "distorm3";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # no tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful Disassembler Library For x86/AMD64";
     homepage = "https://github.com/gdabah/distorm";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/distro/default.nix b/pkgs/development/python-modules/distro/default.nix
index baaf54dd061d4..81bcccd8bd6c6 100644
--- a/pkgs/development/python-modules/distro/default.nix
+++ b/pkgs/development/python-modules/distro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
   pname = "distro";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "distro" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nir0s/distro";
     description = "Linux Distribution - a Linux OS platform information API.";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/distutils_extra/default.nix b/pkgs/development/python-modules/distutils_extra/default.nix
index 1e66f04374be7..882a39957993c 100644
--- a/pkgs/development/python-modules/distutils_extra/default.nix
+++ b/pkgs/development/python-modules/distutils_extra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1bv3h2p9ffbzyddhi5sccsfwrm3i6yxzn0m06fdxkj2zsvs28gvj";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/python-distutils-extra";
     description = "Enhancements to Python's distutils";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/dj-email-url/default.nix b/pkgs/development/python-modules/dj-email-url/default.nix
index 711eee059caaf..f8dd9dca202c9 100644
--- a/pkgs/development/python-modules/dj-email-url/default.nix
+++ b/pkgs/development/python-modules/dj-email-url/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # tests not included with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/migonzalvar/dj-email-url";
     description = "Use an URL to configure email backend settings in your Django Application";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/dj-search-url/default.nix b/pkgs/development/python-modules/dj-search-url/default.nix
index f86f08ae60b92..321bec8149d12 100644
--- a/pkgs/development/python-modules/dj-search-url/default.nix
+++ b/pkgs/development/python-modules/dj-search-url/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "424d1a5852500b3c118abfdd0e30b3e0016fe68e7ed27b8553a67afa20d4fb40";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dstufft/dj-search-url";
     description = "Use Search URLs in your Django Haystack Application";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/django-allauth/default.nix b/pkgs/development/python-modules/django-allauth/default.nix
index a91bd6cadc3e5..fafd7ab9a63fe 100644
--- a/pkgs/development/python-modules/django-allauth/default.nix
+++ b/pkgs/development/python-modules/django-allauth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, requests, requests_oauthlib
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, requests, requests_oauthlib
 , django, python3-openid, mock, coverage }:
 
 buildPythonPackage rec {
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     coverage run manage.py test allauth
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integrated set of Django applications addressing authentication, registration, account management as well as 3rd party (social) account authentication";
     homepage = "https://www.intenct.nl/projects/django-allauth";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-anymail/default.nix b/pkgs/development/python-modules/django-anymail/default.nix
index 32fb403419414..892cf179c3704 100644
--- a/pkgs/development/python-modules/django-anymail/default.nix
+++ b/pkgs/development/python-modules/django-anymail/default.nix
@@ -1,5 +1,5 @@
 {
-    stdenv,
+    lib, stdenv,
     buildPythonPackage,
     fetchFromGitHub,
     six,
@@ -38,7 +38,7 @@ buildPythonPackage rec {
 
   # this package allows multiple email backends
   # sparkpost is missing because it's not packaged yet
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django email backends and webhooks for Mailgun";
     homepage = "https://github.com/anymail/django-anymail";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django-auth-ldap/default.nix b/pkgs/development/python-modules/django-auth-ldap/default.nix
index 84b9df28bce62..d0dacd659a15c 100644
--- a/pkgs/development/python-modules/django-auth-ldap/default.nix
+++ b/pkgs/development/python-modules/django-auth-ldap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi, isPy27
 , ldap , django
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # django.core.exceptions.ImproperlyConfigured: Requested setting INSTALLED_APPS, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django authentication backend that authenticates against an LDAP service";
     homepage = "https://github.com/django-auth-ldap/django-auth-ldap";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/django-cache-url/default.nix b/pkgs/development/python-modules/django-cache-url/default.nix
index 6abe92c43f763..103bfb29578d8 100644
--- a/pkgs/development/python-modules/django-cache-url/default.nix
+++ b/pkgs/development/python-modules/django-cache-url/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # tests not included with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ghickman/django-cache-url";
     description = "Use Cache URLs in your Django application";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-cleanup/default.nix b/pkgs/development/python-modules/django-cleanup/default.nix
index 66d202304ee78..39f65275feeda 100644
--- a/pkgs/development/python-modules/django-cleanup/default.nix
+++ b/pkgs/development/python-modules/django-cleanup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, django
+{ lib, stdenv, buildPythonPackage, fetchPypi, django
 , redis, async-timeout, hiredis
 }:
 
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   checkInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically deletes old file for FileField and ImageField. It also deletes files on models instance deletion";
     homepage = "https://github.com/un1t/django-cleanup";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-compat/default.nix b/pkgs/development/python-modules/django-compat/default.nix
index 57426181b7358..ef18bfe77ec92 100644
--- a/pkgs/development/python-modules/django-compat/default.nix
+++ b/pkgs/development/python-modules/django-compat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python,
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python,
   django, six
 }:
 
@@ -33,7 +33,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Forward and backwards compatibility layer for Django 1.4, 1.7, 1.8, 1.9, 1.10 and 1.11";
     homepage = "https://github.com/arteria/django-compat";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-configurations/default.nix b/pkgs/development/python-modules/django-configurations/default.nix
index 5b813977493e2..bf1835071f880 100644
--- a/pkgs/development/python-modules/django-configurations/default.nix
+++ b/pkgs/development/python-modules/django-configurations/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django-discover-runner
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   # django.core.exceptions.ImproperlyConfigured: django-configurations settings importer wasn't correctly installed
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://django-configurations.readthedocs.io/";
     description = "A helper for organizing Django settings";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/django-csp/default.nix b/pkgs/development/python-modules/django-csp/default.nix
index 1eed9578a8a2c..d87e39b8e3f7d 100644
--- a/pkgs/development/python-modules/django-csp/default.nix
+++ b/pkgs/development/python-modules/django-csp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, django }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, django }:
 
 buildPythonPackage rec {
   pname = "django-csp";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adds Content-Security-Policy headers to Django";
     homepage = "https://github.com/mozilla/django-csp";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django-discover-runner/default.nix b/pkgs/development/python-modules/django-discover-runner/default.nix
index 43ae9a7c83a5b..63d51d41fc935 100644
--- a/pkgs/development/python-modules/django-discover-runner/default.nix
+++ b/pkgs/development/python-modules/django-discover-runner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # tests not included with release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jezdez/django-discover-runner";
     description = "A Django test runner based on unittest2's test discovery";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/django-dynamic-preferences/default.nix b/pkgs/development/python-modules/django-dynamic-preferences/default.nix
index de3424c9fec58..7288896c4fea0 100644
--- a/pkgs/development/python-modules/django-dynamic-preferences/default.nix
+++ b/pkgs/development/python-modules/django-dynamic-preferences/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , django, persisting-theory, six
 }:
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # django.core.exceptions.ImproperlyConfigured: Requested setting DYNAMIC_PREFERENCES, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/EliotBerriot/django-dynamic-preferences";
     description = "Dynamic global and instance settings for your django project";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django-filter/default.nix b/pkgs/development/python-modules/django-filter/default.nix
index 93f3f20f3051b..e4ca546bbc28c 100644
--- a/pkgs/development/python-modules/django-filter/default.nix
+++ b/pkgs/development/python-modules/django-filter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reusable Django application for allowing users to filter querysets dynamically";
     homepage = "https://pypi.org/project/django-filter/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django-gravatar2/default.nix b/pkgs/development/python-modules/django-gravatar2/default.nix
index 4ea3b7e7ee58a..083126066039e 100644
--- a/pkgs/development/python-modules/django-gravatar2/default.nix
+++ b/pkgs/development/python-modules/django-gravatar2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "django-gravatar2";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Essential Gravatar support for Django";
     homepage = "https://github.com/twaddington/django-gravatar";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-hijack-admin/default.nix b/pkgs/development/python-modules/django-hijack-admin/default.nix
index e30fc88079caa..54056547f48ac 100644
--- a/pkgs/development/python-modules/django-hijack-admin/default.nix
+++ b/pkgs/development/python-modules/django-hijack-admin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python,
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python,
   django_hijack, django_nose }:
 buildPythonPackage rec {
   pname = "django-hijack-admin";
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Admin integration for django-hijack";
     homepage = "https://github.com/arteria/django-hijack-admin";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-hijack/default.nix b/pkgs/development/python-modules/django-hijack/default.nix
index d736e69ae6ef2..bd6f870de66e4 100644
--- a/pkgs/development/python-modules/django-hijack/default.nix
+++ b/pkgs/development/python-modules/django-hijack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python,
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python,
   django, django_compat, django_nose
 }:
 buildPythonPackage rec {
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows superusers to hijack (=login as) and work on behalf of another user";
     homepage = "https://github.com/arteria/django-hijack";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-logentry-admin/default.nix b/pkgs/development/python-modules/django-logentry-admin/default.nix
index d9734ff4a220f..59e9782f05012 100644
--- a/pkgs/development/python-modules/django-logentry-admin/default.nix
+++ b/pkgs/development/python-modules/django-logentry-admin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, django, pytest, pytest-django }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, django, pytest, pytest-django }:
 
 buildPythonPackage rec {
   pname = "django-logentry-admin";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Show all LogEntry objects in the Django admin site";
     homepage = "https://github.com/yprez/django-logentry-admin";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/django-mailman3/default.nix b/pkgs/development/python-modules/django-mailman3/default.nix
index afa504f1bc71e..40063c89e4329 100644
--- a/pkgs/development/python-modules/django-mailman3/default.nix
+++ b/pkgs/development/python-modules/django-mailman3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, django-gravatar2, django_compressor
+{ lib, stdenv, buildPythonPackage, fetchPypi, django-gravatar2, django_compressor
 , django-allauth, mailmanclient, django, mock
 }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     PYTHONPATH=.:$PYTHONPATH django-admin.py test --settings=django_mailman3.tests.settings_test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django library for Mailman UIs";
     homepage = "https://gitlab.com/mailman/django-mailman3";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/django-maintenance-mode/default.nix b/pkgs/development/python-modules/django-maintenance-mode/default.nix
index 2e433aa5d4590..c599e28d2062e 100644
--- a/pkgs/development/python-modules/django-maintenance-mode/default.nix
+++ b/pkgs/development/python-modules/django-maintenance-mode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, pytest, django }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, pytest, django }:
 
 buildPythonPackage rec {
   pname = "django-maintenance-mode";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shows a 503 error page when maintenance-mode is on";
     homepage = "https://github.com/fabiocaccamo/django-maintenance-mode";
     maintainers = with maintainers; [ mrmebelman ];
diff --git a/pkgs/development/python-modules/django-oauth-toolkit/default.nix b/pkgs/development/python-modules/django-oauth-toolkit/default.nix
index 83f1049a2e568..6e16af5bc8f9d 100644
--- a/pkgs/development/python-modules/django-oauth-toolkit/default.nix
+++ b/pkgs/development/python-modules/django-oauth-toolkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , django, requests, oauthlib
 }:
 
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # django.core.exceptions.ImproperlyConfigured: Requested setting OAUTH2_PROVIDER, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OAuth2 goodies for the Djangonauts";
     homepage = "https://github.com/jazzband/django-oauth-toolkit";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/django-paintstore/default.nix b/pkgs/development/python-modules/django-paintstore/default.nix
index b2c755907c154..4fed9bf470b26 100644
--- a/pkgs/development/python-modules/django-paintstore/default.nix
+++ b/pkgs/development/python-modules/django-paintstore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests, requests_oauthlib
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests, requests_oauthlib
 , django, python3-openid }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django app that integrates jQuery ColorPicker with the Django admin";
     homepage = "https://github.com/gsiegman/django-paintstore";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-postgresql-netfields/default.nix b/pkgs/development/python-modules/django-postgresql-netfields/default.nix
index 73c15850d33c8..f2bd574919aae 100644
--- a/pkgs/development/python-modules/django-postgresql-netfields/default.nix
+++ b/pkgs/development/python-modules/django-postgresql-netfields/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , django
 , netaddr
@@ -41,7 +41,7 @@ buildPythonPackage rec {
     six
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django PostgreSQL netfields implementation";
     homepage = "https://github.com/jimfunk/django-postgresql-netfields";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/django-q/default.nix b/pkgs/development/python-modules/django-q/default.nix
index 0755c5055a1e9..2eb3b19f554bf 100644
--- a/pkgs/development/python-modules/django-q/default.nix
+++ b/pkgs/development/python-modules/django-q/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, django-picklefield, arrow
+{ lib, stdenv, buildPythonPackage, fetchPypi, django-picklefield, arrow
 , blessed, django, future }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multiprocessing distributed task queue for Django";
     homepage = "https://django-q.readthedocs.org";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-ranged-response/default.nix b/pkgs/development/python-modules/django-ranged-response/default.nix
index 29b2baf89cdce..d517563590fb6 100644
--- a/pkgs/development/python-modules/django-ranged-response/default.nix
+++ b/pkgs/development/python-modules/django-ranged-response/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchPypi, buildPythonPackage, django }:
+{ lib, stdenv, fetchurl, fetchPypi, buildPythonPackage, django }:
 
 buildPythonPackage rec {
   pname = "django-ranged-response";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modified FileResponse that returns `Content-Range` headers with the HTTP response, so browsers (read Safari 9+) that request the file, can stream the response properly";
     homepage = "https://github.com/wearespindle/django-ranged-fileresponse";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-raster/default.nix b/pkgs/development/python-modules/django-raster/default.nix
index 056f8dffdcfca..a3aed647a33b5 100644
--- a/pkgs/development/python-modules/django-raster/default.nix
+++ b/pkgs/development/python-modules/django-raster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k,
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k,
   numpy, django_colorful, pillow, psycopg2,
   pyparsing, django, celery, boto3, importlib-metadata
 }:
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ numpy django_colorful pillow psycopg2
                             pyparsing django celery boto3 importlib-metadata ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Basic raster data integration for Django";
     homepage = "https://github.com/geodesign/django-raster";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-storages/default.nix b/pkgs/development/python-modules/django-storages/default.nix
index bdf7c21514c26..869c3bf74eef0 100644
--- a/pkgs/development/python-modules/django-storages/default.nix
+++ b/pkgs/development/python-modules/django-storages/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , django
 }:
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # django.core.exceptions.ImproperlyConfigured: Requested setting DEFAULT_INDEX_TABLESPACE, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of custom storage backends for Django";
     homepage = "https://django-storages.readthedocs.io";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django-versatileimagefield/default.nix b/pkgs/development/python-modules/django-versatileimagefield/default.nix
index de5854192d202..39912f474204d 100644
--- a/pkgs/development/python-modules/django-versatileimagefield/default.nix
+++ b/pkgs/development/python-modules/django-versatileimagefield/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # tests not included with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Replaces django's ImageField with a more flexible interface";
     homepage = "https://github.com/respondcreate/django-versatileimagefield/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django-widget-tweaks/default.nix b/pkgs/development/python-modules/django-widget-tweaks/default.nix
index 99e3abda890a6..8529df09bb76c 100644
--- a/pkgs/development/python-modules/django-widget-tweaks/default.nix
+++ b/pkgs/development/python-modules/django-widget-tweaks/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchFromGitHub, python, stdenv, django }:
+{ buildPythonPackage, fetchFromGitHub, python, lib, stdenv, django }:
 
 buildPythonPackage rec {
   pname = "django-widget-tweaks";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   checkPhase = "${python.interpreter} runtests.py";
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
       description = "Tweak the form field rendering in templates, not in python-level form definitions.";
       homepage = "https://github.com/jazzband/django-widget-tweaks";
       license = licenses.mit;
diff --git a/pkgs/development/python-modules/django/2.nix b/pkgs/development/python-modules/django/2.nix
index 64897890759ec..641ec02aae013 100644
--- a/pkgs/development/python-modules/django/2.nix
+++ b/pkgs/development/python-modules/django/2.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, substituteAll,
+{ lib, stdenv, buildPythonPackage, fetchPypi, substituteAll,
   isPy3k,
   geos, gdal, pytz, sqlparse,
   withGdal ? false
@@ -29,7 +29,7 @@ buildPythonPackage rec {
   # too complicated to setup
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-level Python Web framework";
     homepage = "https://www.djangoproject.com/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django/3.nix b/pkgs/development/python-modules/django/3.nix
index 77dcb48235a8a..2ea5b5a006c8c 100644
--- a/pkgs/development/python-modules/django/3.nix
+++ b/pkgs/development/python-modules/django/3.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , substituteAll
@@ -39,7 +39,7 @@ buildPythonPackage rec {
   # too complicated to setup
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-level Python Web framework";
     homepage = "https://www.djangoproject.com/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django_appconf/default.nix b/pkgs/development/python-modules/django_appconf/default.nix
index 45116ddd55486..c9c9913d76448 100644
--- a/pkgs/development/python-modules/django_appconf/default.nix
+++ b/pkgs/development/python-modules/django_appconf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, six, django, fetchpatch }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, six, django, fetchpatch }:
 buildPythonPackage rec {
   pname = "django-appconf";
   version = "1.0.3";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     python -m django test --settings="tests.test_settings"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A helper class for handling configuration defaults of packaged apps gracefully";
     homepage = "https://django-appconf.readthedocs.org/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/django_classytags/default.nix b/pkgs/development/python-modules/django_classytags/default.nix
index 102e2e7cf9353..e0a297e53c0cd 100644
--- a/pkgs/development/python-modules/django_classytags/default.nix
+++ b/pkgs/development/python-modules/django_classytags/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # pypi version doesn't include runtest.py, needed to run tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Class based template tags for Django";
     homepage = "https://github.com/divio/django-classy-tags";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django_colorful/default.nix b/pkgs/development/python-modules/django_colorful/default.nix
index 10068f87b0798..468327139e644 100644
--- a/pkgs/development/python-modules/django_colorful/default.nix
+++ b/pkgs/development/python-modules/django_colorful/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # Requires Django >= 1.8
   buildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django extension that provides database and form color fields";
     homepage = "https://github.com/charettes/django-colorful";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django_compressor/default.nix b/pkgs/development/python-modules/django_compressor/default.nix
index 1408032d0c275..f00804364899f 100644
--- a/pkgs/development/python-modules/django_compressor/default.nix
+++ b/pkgs/development/python-modules/django_compressor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   rcssmin, rjsmin, django_appconf }:
 buildPythonPackage rec {
     pname = "django_compressor";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
     propagatedBuildInputs = [ rcssmin rjsmin django_appconf ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Compresses linked and inline JavaScript or CSS into single cached files";
       homepage = "https://django-compressor.readthedocs.org/en/latest/";
       license = licenses.mit;
diff --git a/pkgs/development/python-modules/django_contrib_comments/default.nix b/pkgs/development/python-modules/django_contrib_comments/default.nix
index 3f5371e397afc..a8872967df4db 100644
--- a/pkgs/development/python-modules/django_contrib_comments/default.nix
+++ b/pkgs/development/python-modules/django_contrib_comments/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/django/django-contrib-comments";
     description = "The code formerly known as django.contrib.comments";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/django_environ/default.nix b/pkgs/development/python-modules/django_environ/default.nix
index e4ec7505c831a..fa2618fa1a71f 100644
--- a/pkgs/development/python-modules/django_environ/default.nix
+++ b/pkgs/development/python-modules/django_environ/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   doCheck = false;
   propagatedBuildInputs = [ django six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilize environment variables to configure your Django application";
     homepage = "https://github.com/joke2k/django-environ/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django_evolution/default.nix b/pkgs/development/python-modules/django_evolution/default.nix
index e3b7be798775a..dba92efb2d948 100644
--- a/pkgs/development/python-modules/django_evolution/default.nix
+++ b/pkgs/development/python-modules/django_evolution/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database schema evolution tool for the Django web framework";
     homepage = "https://github.com/beanbaginc/django-evolution";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/django_guardian/default.nix b/pkgs/development/python-modules/django_guardian/default.nix
index 364a5e12f52fb..60023660ea56e 100644
--- a/pkgs/development/python-modules/django_guardian/default.nix
+++ b/pkgs/development/python-modules/django_guardian/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , django_environ, mock, django
 , pytest, pytestrunner, pytest-django
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest pytestrunner pytest-django django_environ mock ];
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Per object permissions for Django";
     homepage = "https://github.com/django-guardian/django-guardian";
     license = [ licenses.mit licenses.bsd2 ];
diff --git a/pkgs/development/python-modules/django_modelcluster/default.nix b/pkgs/development/python-modules/django_modelcluster/default.nix
index e41b455cd4b5e..500fe2e2fbce0 100644
--- a/pkgs/development/python-modules/django_modelcluster/default.nix
+++ b/pkgs/development/python-modules/django_modelcluster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytz
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pytz six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Django extension to allow working with 'clusters' of models as a single unit, independently of the database";
     homepage = "https://github.com/torchbox/django-modelcluster/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/django_nose/default.nix b/pkgs/development/python-modules/django_nose/default.nix
index 66a4ad7857b98..7f2f9efcfc5b0 100644
--- a/pkgs/development/python-modules/django_nose/default.nix
+++ b/pkgs/development/python-modules/django_nose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides all the goodness of nose in your Django tests";
     homepage = "https://github.com/django-nose/django-nose";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django_redis/default.nix b/pkgs/development/python-modules/django_redis/default.nix
index 114962477fd6b..434dea7f0f217 100644
--- a/pkgs/development/python-modules/django_redis/default.nix
+++ b/pkgs/development/python-modules/django_redis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage,
+{ lib, stdenv, fetchPypi, buildPythonPackage,
   mock, django, redis, msgpack }:
 buildPythonPackage rec {
   pname = "django-redis";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     msgpack
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Full featured redis cache backend for Django";
     homepage = "https://github.com/niwibe/django-redis";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django_reversion/default.nix b/pkgs/development/python-modules/django_reversion/default.nix
index 9d307734367c0..16574770ff9eb 100644
--- a/pkgs/development/python-modules/django_reversion/default.nix
+++ b/pkgs/development/python-modules/django_reversion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extension to the Django web framework that provides comprehensive version control facilities";
     homepage = "https://github.com/etianen/django-reversion";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/django_silk/default.nix b/pkgs/development/python-modules/django_silk/default.nix
index 8efd62d7d1812..66475b35d2a3c 100644
--- a/pkgs/development/python-modules/django_silk/default.nix
+++ b/pkgs/development/python-modules/django_silk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , python
 , fetchFromGitHub
@@ -54,7 +54,7 @@ buildPythonPackage rec {
     DB=sqlite3 DB_NAME=db.sqlite3 ${python.interpreter} manage.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Silky smooth profiling for the Django Framework";
     homepage = "https://github.com/jazzband/django-silk";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/django_taggit/default.nix b/pkgs/development/python-modules/django_taggit/default.nix
index 80ee899b18322..e715dde7c41e9 100644
--- a/pkgs/development/python-modules/django_taggit/default.nix
+++ b/pkgs/development/python-modules/django_taggit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , python
 , fetchPypi
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m django test --settings=tests.settings
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "django-taggit is a reusable Django application for simple tagging";
     homepage = "https://github.com/alex/django-taggit/tree/master/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/django_treebeard/default.nix b/pkgs/development/python-modules/django_treebeard/default.nix
index 060867d837f92..fd8789d1fb87b 100644
--- a/pkgs/development/python-modules/django_treebeard/default.nix
+++ b/pkgs/development/python-modules/django_treebeard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # tests fail  "AppRegistryNotReady("Apps aren't loaded yet.")"
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Efficient tree implementations for Django 1.6+";
     homepage = "https://tabo.pe/projects/django-treebeard/";
     maintainers = with maintainers; [ desiderius ];
diff --git a/pkgs/development/python-modules/djangorestframework/default.nix b/pkgs/development/python-modules/djangorestframework/default.nix
index 20ae1d81b6afb..ce92fab3e9657 100644
--- a/pkgs/development/python-modules/djangorestframework/default.nix
+++ b/pkgs/development/python-modules/djangorestframework/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, django, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, django, isPy27 }:
 
 buildPythonPackage rec {
   version = "3.12.2";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web APIs for Django, made easy";
     homepage = "https://www.django-rest-framework.org/";
     maintainers = with maintainers; [ desiderius ];
diff --git a/pkgs/development/python-modules/dkimpy/default.nix b/pkgs/development/python-modules/dkimpy/default.nix
index aaecda77780c1..e7a80d91d24cb 100644
--- a/pkgs/development/python-modules/dkimpy/default.nix
+++ b/pkgs/development/python-modules/dkimpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, openssl, buildPythonPackage
+{ lib, stdenv, fetchPypi, openssl, buildPythonPackage
 , pytest, dnspython, pynacl, authres, python }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     ${python.interpreter} ./test.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DKIM + ARC email signing/verification tools + Python module";
     longDescription = ''
       Python module that implements DKIM (DomainKeys Identified Mail) email
diff --git a/pkgs/development/python-modules/docker-pycreds/default.nix b/pkgs/development/python-modules/docker-pycreds/default.nix
index a75278d45d433..543f4994020ca 100644
--- a/pkgs/development/python-modules/docker-pycreds/default.nix
+++ b/pkgs/development/python-modules/docker-pycreds/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six }:
 
 buildPythonPackage rec {
   pname = "docker-pycreds";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for the docker credentials store API.";
     homepage = "https://github.com/shin-/dockerpy-creds";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/dockerfile-parse/default.nix b/pkgs/development/python-modules/dockerfile-parse/default.nix
index e3a998126e9c0..74e363d18b97e 100644
--- a/pkgs/development/python-modules/dockerfile-parse/default.nix
+++ b/pkgs/development/python-modules/dockerfile-parse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six, pytestcov, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six, pytestcov, pytest }:
 
 buildPythonPackage rec {
   version = "1.1.0";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestcov pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for parsing Dockerfile files";
     homepage = "https://github.com/DBuildService/dockerfile-parse";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dockerpty/default.nix b/pkgs/development/python-modules/dockerpty/default.nix
index fd9d7b4b88da4..b6267b87c1bd1 100644
--- a/pkgs/development/python-modules/dockerpty/default.nix
+++ b/pkgs/development/python-modules/dockerpty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six }:
 
 buildPythonPackage rec {
   pname = "dockerpty";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Functionality needed to operate the pseudo-tty (PTY) allocated to a docker container";
     homepage = "https://github.com/d11wtq/dockerpty";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/docopt/default.nix b/pkgs/development/python-modules/docopt/default.nix
index 135bedfc43e84..2dc4bb38cf148 100644
--- a/pkgs/development/python-modules/docopt/default.nix
+++ b/pkgs/development/python-modules/docopt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "docopt";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "14f4hn6d1j4b99svwbaji8n2zj58qicyz19mm0x6pmhb50jsics9";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pythonic argument parser, that will make you smile";
     homepage = "http://docopt.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/doctest-ignore-unicode/default.nix b/pkgs/development/python-modules/doctest-ignore-unicode/default.nix
index 0241fd15ad48f..12d15799ecc62 100644
--- a/pkgs/development/python-modules/doctest-ignore-unicode/default.nix
+++ b/pkgs/development/python-modules/doctest-ignore-unicode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, nose }:
 
 buildPythonPackage rec {
   pname = "doctest-ignore-unicode";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Add flag to ignore unicode literal prefixes in doctests";
     license = with licenses; [ asl20 ];
     homepage = "https://github.com/gnublade/doctest-ignore-unicode";
diff --git a/pkgs/development/python-modules/dogpile.cache/default.nix b/pkgs/development/python-modules/dogpile.cache/default.nix
index f36e1347be9fb..5dba1b91bc17b 100644
--- a/pkgs/development/python-modules/dogpile.cache/default.nix
+++ b/pkgs/development/python-modules/dogpile.cache/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -37,7 +37,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ decorator stevedore ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A caching front-end based on the Dogpile lock";
     homepage = "https://bitbucket.org/zzzeek/dogpile.cache";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dogpile.core/default.nix b/pkgs/development/python-modules/dogpile.core/default.nix
index 41340cda26ee0..f6eabc378b3ba 100644
--- a/pkgs/development/python-modules/dogpile.core/default.nix
+++ b/pkgs/development/python-modules/dogpile.core/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "dogpile.core";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 'dogpile' lock, typically used as a component of a larger caching solution";
     homepage = "https://bitbucket.org/zzzeek/dogpile.core";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dot2tex/default.nix b/pkgs/development/python-modules/dot2tex/default.nix
index 03445f79117f7..2626f420676a1 100644
--- a/pkgs/development/python-modules/dot2tex/default.nix
+++ b/pkgs/development/python-modules/dot2tex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python
 , buildPythonPackage
 , fetchPypi
@@ -37,7 +37,7 @@ buildPythonPackage rec {
     ${python.interpreter} tests/test_dot2tex.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert graphs generated by Graphviz to LaTeX friendly formats";
     homepage = "https://github.com/kjellmf/dot2tex";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/dpath/default.nix b/pkgs/development/python-modules/dpath/default.nix
index 548bd51683850..505bd7bb456c3 100644
--- a/pkgs/development/python-modules/dpath/default.nix
+++ b/pkgs/development/python-modules/dpath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy27
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy27
 , mock, pytestCheckHook, nose, hypothesis
 }:
 
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # use pytest as nosetests hangs
   checkInputs = [ mock nose pytestCheckHook hypothesis ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/akesterson/dpath-python";
     license = [ licenses.mit ];
     description = "A python library for accessing and searching dictionaries via /slashed/paths ala xpath";
diff --git a/pkgs/development/python-modules/dpkt/default.nix b/pkgs/development/python-modules/dpkt/default.nix
index 4dd0de3b2d8cb..177b260e8044f 100644
--- a/pkgs/development/python-modules/dpkt/default.nix
+++ b/pkgs/development/python-modules/dpkt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
   pname = "dpkt";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "f4e579cbaf6e2285ebf3a9e84019459b4367636bac079ba169527e582fca48b4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, simple packet creation / parsing, with definitions for the basic TCP/IP protocols";
     homepage = "https://github.com/kbandla/dpkt";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/drf-yasg/default.nix b/pkgs/development/python-modules/drf-yasg/default.nix
index 1488d93822892..dd92d51d6c6b2 100644
--- a/pkgs/development/python-modules/drf-yasg/default.nix
+++ b/pkgs/development/python-modules/drf-yasg/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   buildPythonPackage,
   fetchPypi,
   inflection,
@@ -31,7 +31,7 @@ buildPythonPackage rec {
     djangorestframework
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generation of Swagger/OpenAPI schemas for Django REST Framework";
     homepage = "https://github.com/axnsan12/drf-yasg";
     maintainers = with maintainers; [ ivegotasthma ];
diff --git a/pkgs/development/python-modules/dropbox/default.nix b/pkgs/development/python-modules/dropbox/default.nix
index b58d24e3fecf5..22e66d0a4a434 100644
--- a/pkgs/development/python-modules/dropbox/default.nix
+++ b/pkgs/development/python-modules/dropbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytestrunner, requests, urllib3, mock, setuptools }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   buildInputs = [ pytestrunner ];
   propagatedBuildInputs = [ requests urllib3 mock setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python library for Dropbox's HTTP-based Core and Datastore APIs";
     homepage = "https://www.dropbox.com/developers/core/docs";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/dtopt/default.nix b/pkgs/development/python-modules/dtopt/default.nix
index 4b649cad9668d..84631c2170891 100644
--- a/pkgs/development/python-modules/dtopt/default.nix
+++ b/pkgs/development/python-modules/dtopt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "06ae07a12294a7ba708abaa63f838017d1a2faf6147a1e7a14ca4fa28f86da7f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Add options to doctest examples while they are running";
     homepage = "https://pypi.python.org/pypi/dtopt";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/dufte/default.nix b/pkgs/development/python-modules/dufte/default.nix
index 8fe2025923599..7836c8aa60a0a 100644
--- a/pkgs/development/python-modules/dufte/default.nix
+++ b/pkgs/development/python-modules/dufte/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   checkInputs = [ pytestCheckHook ];
   pythonImportsCheck = [ "dufte" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clean matplotlib plots";
     homepage = "https://github.com/nschloe/dufte";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/dulwich/0_19.nix b/pkgs/development/python-modules/dulwich/0_19.nix
index 82b9bed492cca..f0d3bad7a04f4 100644
--- a/pkgs/development/python-modules/dulwich/0_19.nix
+++ b/pkgs/development/python-modules/dulwich/0_19.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , urllib3, certifi
 , gevent, geventhttpclient, mock, fastimport
 , git, glibcLocales }:
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple Python implementation of the Git file formats and protocols";
     homepage = "https://samba.org/~jelmer/dulwich/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/dulwich/default.nix b/pkgs/development/python-modules/dulwich/default.nix
index fb29133da0ef6..dd067514ccccb 100644
--- a/pkgs/development/python-modules/dulwich/default.nix
+++ b/pkgs/development/python-modules/dulwich/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , urllib3, certifi
 , gevent, geventhttpclient, mock, fastimport
 , git, glibcLocales }:
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple Python implementation of the Git file formats and protocols";
     homepage = "https://samba.org/~jelmer/dulwich/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/dyn/default.nix b/pkgs/development/python-modules/dyn/default.nix
index cc7a330e97cf7..b5fa28f2de6b2 100644
--- a/pkgs/development/python-modules/dyn/default.nix
+++ b/pkgs/development/python-modules/dyn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, pytestcov, mock
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, pytestcov, mock
 , pytest_xdist, covCore, glibcLocales }:
 
 buildPythonPackage rec {
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   LC_ALL="en_US.UTF-8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynect dns lib";
     homepage = "https://dyn.readthedocs.org/en/latest/intro.html";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/dynd/default.nix b/pkgs/development/python-modules/dynd/default.nix
index 9150a6746a2bf..f23d19510ee79 100644
--- a/pkgs/development/python-modules/dynd/default.nix
+++ b/pkgs/development/python-modules/dynd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPyPy
 , isPy3k
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   buildInputs = [ pkgs.libdynd.dev cython ];
   propagatedBuildInputs = [ numpy pkgs.libdynd ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://libdynd.org";
     license = licenses.bsd2;
     description = "Python exposure of dynd";
diff --git a/pkgs/development/python-modules/easygui/default.nix b/pkgs/development/python-modules/easygui/default.nix
index 30c03ae6e2c55..441d839d36f69 100644
--- a/pkgs/development/python-modules/easygui/default.nix
+++ b/pkgs/development/python-modules/easygui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
   pname = "easygui";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false; # No tests available
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Very simple, very easy GUI programming in Python";
     homepage = "https://github.com/robertlugg/easygui";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/easyprocess/default.nix b/pkgs/development/python-modules/easyprocess/default.nix
index 3dda2c914556b..fc86edf5d4d01 100644
--- a/pkgs/development/python-modules/easyprocess/default.nix
+++ b/pkgs/development/python-modules/easyprocess/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "EasyProcess";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easy to use python subprocess interface";
     homepage = "https://github.com/ponty/EasyProcess";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/ecdsa/default.nix b/pkgs/development/python-modules/ecdsa/default.nix
index 1d2a780bbbbdb..2a17f84bb3b4f 100644
--- a/pkgs/development/python-modules/ecdsa/default.nix
+++ b/pkgs/development/python-modules/ecdsa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Only needed for tests
   checkInputs = [ pkgs.openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ECDSA cryptographic signature library";
     homepage = "https://github.com/warner/python-ecdsa";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ed25519/default.nix b/pkgs/development/python-modules/ed25519/default.nix
index 27ebc6a0ff27c..183d7cc3ca554 100644
--- a/pkgs/development/python-modules/ed25519/default.nix
+++ b/pkgs/development/python-modules/ed25519/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
   pname = "ed25519";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "0n1k83ww0pr4q6z0h7p8hvy21hcgb96jvgllfbwhvvyf37h3w182";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ed25519 public-key signatures";
     homepage = "https://github.com/warner/python-ed25519";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/editorconfig/default.nix b/pkgs/development/python-modules/editorconfig/default.nix
index ac3845bb66715..727c3003db5c9 100644
--- a/pkgs/development/python-modules/editorconfig/default.nix
+++ b/pkgs/development/python-modules/editorconfig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , cmake
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     ctest -E "utf_8_char" .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://editorconfig.org";
     description = "EditorConfig File Locator and Interpreter for Python";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/edward/default.nix b/pkgs/development/python-modules/edward/default.nix
index 0f42ddcc799bb..c1171043356a1 100644
--- a/pkgs/development/python-modules/edward/default.nix
+++ b/pkgs/development/python-modules/edward/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, pythonAtLeast
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, pythonAtLeast
 , Keras, numpy, scipy, six, tensorflow }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ Keras numpy scipy six tensorflow ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Probabilistic programming language using Tensorflow";
     homepage = "https://github.com/blei-lab/edward";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/eggdeps/default.nix b/pkgs/development/python-modules/eggdeps/default.nix
index 8c7d7679005e9..ae339368ff5d9 100644
--- a/pkgs/development/python-modules/eggdeps/default.nix
+++ b/pkgs/development/python-modules/eggdeps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_interface
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # tests fail, see https://hydra.nixos.org/build/4316603/log/raw
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool which computes a dependency graph between active Python eggs";
     homepage = "http://thomas-lotze.de/en/software/eggdeps/";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/elasticsearch-dsl/default.nix b/pkgs/development/python-modules/elasticsearch-dsl/default.nix
index 06c4e4045ce18..4418890259117 100644
--- a/pkgs/development/python-modules/elasticsearch-dsl/default.nix
+++ b/pkgs/development/python-modules/elasticsearch-dsl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # Tests require a local instance of elasticsearch
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High level Python client for Elasticsearch";
     longDescription = ''
       Elasticsearch DSL is a high-level library whose aim is to help with
diff --git a/pkgs/development/python-modules/elasticsearch/default.nix b/pkgs/development/python-modules/elasticsearch/default.nix
index 8f403469e193c..4929d1f51a481 100644
--- a/pkgs/development/python-modules/elasticsearch/default.nix
+++ b/pkgs/development/python-modules/elasticsearch/default.nix
@@ -2,7 +2,7 @@
 , fetchPypi
 , urllib3, requests
 , nosexcover, mock
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage (rec {
@@ -20,7 +20,7 @@ buildPythonPackage (rec {
   propagatedBuildInputs = [ urllib3 requests ];
   buildInputs = [ nosexcover mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official low-level client for Elasticsearch";
     homepage = "https://github.com/elasticsearch/elasticsearch-py";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/eliot/default.nix b/pkgs/development/python-modules/eliot/default.nix
index 815167aefb5b5..472834c5c7256 100644
--- a/pkgs/development/python-modules/eliot/default.nix
+++ b/pkgs/development/python-modules/eliot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -47,7 +47,7 @@ buildPythonPackage rec {
     pytest -k 'not test_parse_stream'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://eliot.readthedocs.io";
     description = "Logging library that tells you why it happened";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/emcee/default.nix b/pkgs/development/python-modules/emcee/default.nix
index ed513579457f9..12974a9422d6b 100644
--- a/pkgs/development/python-modules/emcee/default.nix
+++ b/pkgs/development/python-modules/emcee/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , numpy }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ numpy ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kick ass affine-invariant ensemble MCMC sampling";
     homepage = "https://emcee.readthedocs.io/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/emv/default.nix b/pkgs/development/python-modules/emv/default.nix
index 6dfe39f8b6b1d..26d40d8d20527 100644
--- a/pkgs/development/python-modules/emv/default.nix
+++ b/pkgs/development/python-modules/emv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , click, enum-compat, pyscard, pycountry, terminaltables
 , pytestCheckHook, pythonOlder
 }:
@@ -30,7 +30,7 @@ buildPythonPackage rec {
       --replace '"argparse==1.4.0",' ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/russss/python-emv";
     description = "Implementation of the EMV chip-and-pin smartcard protocol";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/enum/default.nix b/pkgs/development/python-modules/enum/default.nix
index 92d3faa598917..ad266623c78bb 100644
--- a/pkgs/development/python-modules/enum/default.nix
+++ b/pkgs/development/python-modules/enum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = !isPyPy;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/enum/";
     description = "Robust enumerated type support in Python";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/enum34/default.nix b/pkgs/development/python-modules/enum34/default.nix
index 1f0d109427669..5e26853098fb0 100644
--- a/pkgs/development/python-modules/enum34/default.nix
+++ b/pkgs/development/python-modules/enum34/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonAtLeast
@@ -18,7 +18,7 @@ if pythonAtLeast "3.4" then null else buildPythonPackage rec {
     ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/enum34";
     description = "Python 3.4 Enum backported to 3.3, 3.2, 3.1, 2.7, 2.6, 2.5, and 2.4";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/epc/default.nix b/pkgs/development/python-modules/epc/default.nix
index fe3cc4420c481..d74595431639c 100644
--- a/pkgs/development/python-modules/epc/default.nix
+++ b/pkgs/development/python-modules/epc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , sexpdata
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ sexpdata ];
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "EPC (RPC stack for Emacs Lisp) implementation in Python";
     homepage = "https://github.com/tkf/python-epc";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/ephem/default.nix b/pkgs/development/python-modules/ephem/default.nix
index 32fe91cb72d5a..4d6e594092666 100644
--- a/pkgs/development/python-modules/ephem/default.nix
+++ b/pkgs/development/python-modules/ephem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , glibcLocales, pytest }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     LC_ALL="en_US.UTF-8" py.test --pyargs ephem.tests -k "not JPLTest"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compute positions of the planets and stars";
     homepage = "https://pypi.python.org/pypi/ephem/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/et_xmlfile/default.nix b/pkgs/development/python-modules/et_xmlfile/default.nix
index 09475329c1bbf..5ba9490d945a4 100644
--- a/pkgs/development/python-modules/et_xmlfile/default.nix
+++ b/pkgs/development/python-modules/et_xmlfile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , lxml
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     py.test $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of lxml.xmlfile for the standard library";
     longDescription = ''
       et_xmlfile is a low memory library for creating large XML files.
diff --git a/pkgs/development/python-modules/etcd/default.nix b/pkgs/development/python-modules/etcd/default.nix
index 7a122f1b616e7..338992259a148 100644
--- a/pkgs/development/python-modules/etcd/default.nix
+++ b/pkgs/development/python-modules/etcd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , simplejson
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # No proper tests are available
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python etcd client that just works";
     homepage = "https://github.com/dsoprea/PythonEtcdClient";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/etebase/default.nix b/pkgs/development/python-modules/etebase/default.nix
index 366c447ed9420..c0f9125a8d795 100644
--- a/pkgs/development/python-modules/etebase/default.nix
+++ b/pkgs/development/python-modules/etebase/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , wheel
 , rustPlatform
 , pipInstallHook
@@ -52,7 +52,7 @@ rustPlatform.buildRustPackage rec {
     pipInstallPhase
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.etebase.com/";
     description = "A Python client library for Etebase";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/eve/default.nix b/pkgs/development/python-modules/eve/default.nix
index c50cc2aeb8279..b931db188e3ef 100644
--- a/pkgs/development/python-modules/eve/default.nix
+++ b/pkgs/development/python-modules/eve/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , flask
@@ -32,7 +32,7 @@ buildPythonPackage rec {
   # tests call a running mongodb instance
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://python-eve.org/";
     description = "Open source Python REST API framework designed for human beings";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/eventlib/default.nix b/pkgs/development/python-modules/eventlib/default.nix
index 4f684612f1844..1b2b44d65f705 100644
--- a/pkgs/development/python-modules/eventlib/default.nix
+++ b/pkgs/development/python-modules/eventlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchdarcs
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Eventlib bindings for python";
     homepage    = "https://ag-projects.com/";
     license     = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/evernote/default.nix b/pkgs/development/python-modules/evernote/default.nix
index b245ff117474b..70c7fad963af6 100644
--- a/pkgs/development/python-modules/evernote/default.nix
+++ b/pkgs/development/python-modules/evernote/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
    propagatedBuildInputs = [ oauth2 ];
 
-   meta = with stdenv.lib; {
+   meta = with lib; {
     description = "Evernote SDK for Python";
     homepage = "https://dev.evernote.com";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/exchangelib/default.nix b/pkgs/development/python-modules/exchangelib/default.nix
index 0635f8f027cca..e380ca613cfdb 100644
--- a/pkgs/development/python-modules/exchangelib/default.nix
+++ b/pkgs/development/python-modules/exchangelib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage,
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage,
   pythonOlder,
   lxml, tzlocal, python-dateutil, pygments, requests-kerberos,
   defusedxml, cached-property, isodate, requests_ntlm, dnspython,
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     oauthlib requests_oauthlib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client for Microsoft Exchange Web Services (EWS)";
     homepage    = "https://github.com/ecederstrand/exchangelib";
     license     = licenses.bsd2;
diff --git a/pkgs/development/python-modules/execnet/default.nix b/pkgs/development/python-modules/execnet/default.nix
index bc7b67f52d42e..0a22ab4b0516c 100644
--- a/pkgs/development/python-modules/execnet/default.nix
+++ b/pkgs/development/python-modules/execnet/default.nix
@@ -36,7 +36,7 @@ buildPythonPackage rec {
 
   __darwinAllowLocalNetworking = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rapid multi-Python deployment";
     license = licenses.gpl2;
     homepage = "https://execnet.readthedocs.io/";
diff --git a/pkgs/development/python-modules/exifread/default.nix b/pkgs/development/python-modules/exifread/default.nix
index 3c7b814a3c839..e86a681a8e391 100644
--- a/pkgs/development/python-modules/exifread/default.nix
+++ b/pkgs/development/python-modules/exifread/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "a0f74af5040168d3883bbc980efe26d06c89f026dc86ba28eb34107662d51766";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easy to use Python module to extract Exif metadata from tiff and jpeg files";
     homepage    = "https://github.com/ianare/exif-py";
     license     = licenses.bsd0;
diff --git a/pkgs/development/python-modules/eyed3/default.nix b/pkgs/development/python-modules/eyed3/default.nix
index d8ccb299fccb1..08faf5c2ba847 100644
--- a/pkgs/development/python-modules/eyed3/default.nix
+++ b/pkgs/development/python-modules/eyed3/default.nix
@@ -36,7 +36,7 @@ buildPythonPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python module and command line program for processing ID3 tags";
     homepage    = "https://eyed3.nicfit.net/";
     license     = licenses.gpl2;
diff --git a/pkgs/development/python-modules/ezdxf/default.nix b/pkgs/development/python-modules/ezdxf/default.nix
index a745566a64518..6dfefe092040e 100644
--- a/pkgs/development/python-modules/ezdxf/default.nix
+++ b/pkgs/development/python-modules/ezdxf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchFromGitHub, pyparsing, pytest }:
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchFromGitHub, pyparsing, pytest }:
 
 buildPythonPackage rec {
   version = "0.12";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyparsing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python package to read and write DXF drawings (interface to the DXF file format)";
     homepage = "https://github.com/mozman/ezdxf/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/face/default.nix b/pkgs/development/python-modules/face/default.nix
index 71fbca916104a..89e7156fa5242 100644
--- a/pkgs/development/python-modules/face/default.nix
+++ b/pkgs/development/python-modules/face/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, boltons, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, boltons, pytest }:
 
 buildPythonPackage rec {
   pname = "face";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # reporting
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mahmoud/face";
     description = "A command-line interface parser and framework";
     longDescription = ''
diff --git a/pkgs/development/python-modules/face_recognition/default.nix b/pkgs/development/python-modules/face_recognition/default.nix
index 2b26fa735e6d1..1896bdfac592b 100644
--- a/pkgs/development/python-modules/face_recognition/default.nix
+++ b/pkgs/development/python-modules/face_recognition/default.nix
@@ -1,5 +1,5 @@
 { buildPythonPackage, fetchFromGitHub, pillow, click, dlib, numpy
-, face_recognition_models, stdenv, flake8, pytest, glibcLocales
+, face_recognition_models, lib, stdenv, flake8, pytest, glibcLocales
 }:
 
 buildPythonPackage rec {
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     LC_ALL="en_US.UTF-8" py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     homepage = "https://github.com/ageitgey/face_recognition";
     maintainers = with maintainers; [ ma27 ];
diff --git a/pkgs/development/python-modules/face_recognition_models/default.nix b/pkgs/development/python-modules/face_recognition_models/default.nix
index 427ad364dde6a..d5838438b7d90 100644
--- a/pkgs/development/python-modules/face_recognition_models/default.nix
+++ b/pkgs/development/python-modules/face_recognition_models/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, stdenv, fetchPypi, setuptools }:
+{ buildPythonPackage, lib, stdenv, fetchPypi, setuptools }:
 
 buildPythonPackage rec {
   pname = "face_recognition_models";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ageitgey/face_recognition_models";
     license = licenses.cc0;
     maintainers = with maintainers; [ ma27 ];
diff --git a/pkgs/development/python-modules/fake-useragent/default.nix b/pkgs/development/python-modules/fake-useragent/default.nix
index fb85408dd3d2d..be26ab98af628 100644
--- a/pkgs/development/python-modules/fake-useragent/default.nix
+++ b/pkgs/development/python-modules/fake-useragent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, six, pytest }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, six, pytest }:
 
 buildPythonPackage rec {
   pname = "fake-useragent";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Up to date simple useragent faker with real world database";
     homepage = "https://github.com/hellysmile/fake-useragent";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/fake_factory/default.nix b/pkgs/development/python-modules/fake_factory/default.nix
index ab947756fa98a..82af8d04e077e 100644
--- a/pkgs/development/python-modules/fake_factory/default.nix
+++ b/pkgs/development/python-modules/fake_factory/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest faker.tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python package that generates fake data for you";
     homepage    = "https://pypi.python.org/pypi/fake-factory";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/falcon/default.nix b/pkgs/development/python-modules/falcon/default.nix
index 20a7677741385..8d1aa02026c1c 100644
--- a/pkgs/development/python-modules/falcon/default.nix
+++ b/pkgs/development/python-modules/falcon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , coverage
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # OSError: [Errno 98] Address already in use
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An unladen web framework for building APIs and app backends";
     homepage = "https://falconframework.org/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/fasteners/default.nix b/pkgs/development/python-modules/fasteners/default.nix
index 75719a78fb21b..b81ebb4faa030 100644
--- a/pkgs/development/python-modules/fasteners/default.nix
+++ b/pkgs/development/python-modules/fasteners/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python package that provides useful locks";
     homepage = "https://github.com/harlowja/fasteners";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/fastentrypoints/default.nix b/pkgs/development/python-modules/fastentrypoints/default.nix
index 08e2e384ff922..eb86784ddc7b8 100644
--- a/pkgs/development/python-modules/fastentrypoints/default.nix
+++ b/pkgs/development/python-modules/fastentrypoints/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "fastentrypoints";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "02s1j8i2dzbpbwgq2a3fiqwm3cnmhii2qzc0k42l0rdxd4a4ya7z";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Makes entry_points specified in setup.py load more quickly";
     homepage = "https://github.com/ninjaaron/fast-entry_points";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/fastimport/default.nix b/pkgs/development/python-modules/fastimport/default.nix
index c1fab50c06e12..55aad9d71ea5b 100644
--- a/pkgs/development/python-modules/fastimport/default.nix
+++ b/pkgs/development/python-modules/fastimport/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, python, fetchPypi}:
+{ lib, stdenv, buildPythonPackage, python, fetchPypi}:
 
 buildPythonPackage rec {
   pname = "fastimport";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/python-fastimport";
     description = "VCS fastimport/fastexport parser";
     maintainers = with maintainers; [ koral ];
diff --git a/pkgs/development/python-modules/fastpair/default.nix b/pkgs/development/python-modules/fastpair/default.nix
index edb45eb068770..82964070d03bd 100644
--- a/pkgs/development/python-modules/fastpair/default.nix
+++ b/pkgs/development/python-modules/fastpair/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pytestrunner, pytest, scipy }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pytestrunner, pytest, scipy }:
 
 buildPythonPackage {
   pname = "fastpair";
@@ -26,7 +26,7 @@ buildPythonPackage {
     pytest fastpair
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/carsonfarmer/fastpair";
     description = "Data-structure for the dynamic closest-pair problem";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/fastpbkdf2/default.nix b/pkgs/development/python-modules/fastpbkdf2/default.nix
index 568d894805fda..e033dc42d4575 100644
--- a/pkgs/development/python-modules/fastpbkdf2/default.nix
+++ b/pkgs/development/python-modules/fastpbkdf2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage
 , openssl, pytest, cffi, six }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest ];
   propagatedBuildInputs = [ cffi six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Ayrx/python-fastpbkdf2";
     description = "Python bindings for fastpbkdf2";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/fastprogress/default.nix b/pkgs/development/python-modules/fastprogress/default.nix
index a542b58056536..25cc2b8792f70 100644
--- a/pkgs/development/python-modules/fastprogress/default.nix
+++ b/pkgs/development/python-modules/fastprogress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "fastprogress" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/fastai/fastprogress";
     description = "Simple and flexible progress bar for Jupyter Notebook and console";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/fastrlock/default.nix b/pkgs/development/python-modules/fastrlock/default.nix
index e44639942a0d7..7aedbbdd8f7c6 100644
--- a/pkgs/development/python-modules/fastrlock/default.nix
+++ b/pkgs/development/python-modules/fastrlock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "fastrlock";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "9ae1a31f6e069b5f0f28ba63c594d0c952065de0a375f7b491d21ebaccc5166f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/scoder/fastrlock";
     description = "A fast RLock implementation for CPython";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/fasttext/default.nix b/pkgs/development/python-modules/fasttext/default.nix
index 42e6446e86435..bf3bd987564ab 100644
--- a/pkgs/development/python-modules/fasttext/default.nix
+++ b/pkgs/development/python-modules/fasttext/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildPythonPackage, fetchFromGitHub, numpy, pkgs, pybind11 }:
+{lib, stdenv, buildPythonPackage, fetchFromGitHub, numpy, pkgs, pybind11 }:
 
 buildPythonPackage rec {
   inherit (pkgs.fasttext) pname version src;
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     HOME=$TMPDIR
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python module for text classification and representation learning";
     homepage = "https://fasttext.cc/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/fdint/default.nix b/pkgs/development/python-modules/fdint/default.nix
index 68c3b039a47fd..4de0d18ca8b7f 100644
--- a/pkgs/development/python-modules/fdint/default.nix
+++ b/pkgs/development/python-modules/fdint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cython
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m fdint.tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/scott-maddox/fdint";
     description = "A free, open-source python package for quickly and precisely approximating Fermi-Dirac integrals";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/feedgen/default.nix b/pkgs/development/python-modules/feedgen/default.nix
index dbc303f430262..509ffaed9d71c 100644
--- a/pkgs/development/python-modules/feedgen/default.nix
+++ b/pkgs/development/python-modules/feedgen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, dateutil, lxml }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, dateutil, lxml }:
 
 buildPythonPackage rec {
   pname = "feedgen";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python module to generate ATOM feeds, RSS feeds and Podcasts.";
     downloadPage = "https://github.com/lkiesow/python-feedgen/releases";
     homepage = "https://github.com/lkiesow/python-feedgen";
diff --git a/pkgs/development/python-modules/feedgenerator/default.nix b/pkgs/development/python-modules/feedgenerator/default.nix
index c0ccb7d345a97..8508cc637f225 100644
--- a/pkgs/development/python-modules/feedgenerator/default.nix
+++ b/pkgs/development/python-modules/feedgenerator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, glibcLocales, fetchPypi, six, pytz }:
+{ lib, stdenv, buildPythonPackage, glibcLocales, fetchPypi, six, pytz }:
 
 buildPythonPackage rec {
   pname = "feedgenerator";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six pytz ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Standalone version of django.utils.feedgenerator, compatible with Py3k";
     homepage = "https://github.com/dmdm/feedgenerator-py3k.git";
     maintainers = with maintainers; [ ];
diff --git a/pkgs/development/python-modules/feedparser/5.nix b/pkgs/development/python-modules/feedparser/5.nix
index 31fc61053b927..a79048c55254f 100644
--- a/pkgs/development/python-modules/feedparser/5.nix
+++ b/pkgs/development/python-modules/feedparser/5.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # lots of networking failures
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kurtmckee/feedparser";
     description = "Universal feed parser";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/feedparser/default.nix b/pkgs/development/python-modules/feedparser/default.nix
index aeeb9b3e4960a..7b48fe6f73e5c 100644
--- a/pkgs/development/python-modules/feedparser/default.nix
+++ b/pkgs/development/python-modules/feedparser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     python -Wd tests/runtests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kurtmckee/feedparser";
     description = "Universal feed parser";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/filebrowser_safe/default.nix b/pkgs/development/python-modules/filebrowser_safe/default.nix
index 014e3b9810a99..df132211d4f9c 100644
--- a/pkgs/development/python-modules/filebrowser_safe/default.nix
+++ b/pkgs/development/python-modules/filebrowser_safe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # There is no test embedded
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A snapshot of django-filebrowser for the Mezzanine CMS";
     longDescription = ''
       filebrowser_safe was created to provide a snapshot of the
diff --git a/pkgs/development/python-modules/filebytes/default.nix b/pkgs/development/python-modules/filebytes/default.nix
index 7404620896c96..bfac6a0e6b234 100644
--- a/pkgs/development/python-modules/filebytes/default.nix
+++ b/pkgs/development/python-modules/filebytes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0h97i6h525hg401dvvaa5krxi184qpvldbdn0izmirvr9pvh4hkn";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://scoding.de/filebytes-introduction";
     license = licenses.gpl2;
     description = "Scripts to parse ELF, PE, Mach-O and OAT (Android Runtime)";
diff --git a/pkgs/development/python-modules/filelock/default.nix b/pkgs/development/python-modules/filelock/default.nix
index 9729c1543cb49..77ddec306fc29 100644
--- a/pkgs/development/python-modules/filelock/default.nix
+++ b/pkgs/development/python-modules/filelock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "filelock";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "18d82244ee114f543149c66a6e0c14e9c4f8a1044b5cdaadd0f82159d6a6ff59";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/benediktschmitt/py-filelock";
     description = "A platform independent file lock for Python";
     license = licenses.unlicense;
diff --git a/pkgs/development/python-modules/filterpy/default.nix b/pkgs/development/python-modules/filterpy/default.nix
index bae362d3a4a44..53059ce43d051 100644
--- a/pkgs/development/python-modules/filterpy/default.nix
+++ b/pkgs/development/python-modules/filterpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     pytest --ignore=filterpy/common/tests/test_discretization.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rlabbe/filterpy";
     description = "Kalman filtering and optimal estimation library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/fints/default.nix b/pkgs/development/python-modules/fints/default.nix
index 10915e766ac25..8e02dac585087 100644
--- a/pkgs/development/python-modules/fints/default.nix
+++ b/pkgs/development/python-modules/fints/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy27
 , bleach
 , mt-940
 , pytest
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     pytest . --ignore=tests/test_client.py -k 'not robust_mode'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/raphaelm/python-fints/";
     description = "Pure-python FinTS (formerly known as HBCI) implementation";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/fire/default.nix b/pkgs/development/python-modules/fire/default.nix
index 6c81a708d57d6..5a14f772546f1 100644
--- a/pkgs/development/python-modules/fire/default.nix
+++ b/pkgs/development/python-modules/fire/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, six, hypothesis, mock
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, six, hypothesis, mock
 , python-Levenshtein, pytest, termcolor, isPy27, enum34 }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     py.test -k 'not testInitRequiresFlag'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for automatically generating command line interfaces";
     longDescription = ''
       Python Fire is a library for automatically generating command line
diff --git a/pkgs/development/python-modules/first/default.nix b/pkgs/development/python-modules/first/default.nix
index 6956addb29f36..a5bdf847eff2d 100644
--- a/pkgs/development/python-modules/first/default.nix
+++ b/pkgs/development/python-modules/first/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "first";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false; # no tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The function you always missed in Python";
     homepage = "https://github.com/hynek/first/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/flake8/default.nix b/pkgs/development/python-modules/flake8/default.nix
index a369919b98fbc..33459b7c66b3f 100644
--- a/pkgs/development/python-modules/flake8/default.nix
+++ b/pkgs/development/python-modules/flake8/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , mock, pytest, pytestrunner
 , configparser, enum34, mccabe, pycodestyle, pyflakes, functools32, typing, importlib-metadata
 }:
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     py.test tests --ignore=tests/integration/test_checker.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Code checking using pep8 and pyflakes";
     homepage = "https://pypi.python.org/pypi/flake8";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/flaky/default.nix b/pkgs/development/python-modules/flaky/default.nix
index 9bf20e6cc3b55..02b0641a34e27 100644
--- a/pkgs/development/python-modules/flaky/default.nix
+++ b/pkgs/development/python-modules/flaky/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     pytest --force-flaky --max-runs 2  test/test_pytest/test_pytest_options_example.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/box/flaky";
     description = "Plugin for nose or py.test that automatically reruns flaky tests";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/flask-babel/default.nix b/pkgs/development/python-modules/flask-babel/default.nix
index 0eb9f61d697f4..da6176e6781f9 100644
--- a/pkgs/development/python-modules/flask-babel/default.nix
+++ b/pkgs/development/python-modules/flask-babel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , python
 , fetchPypi
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover -s tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adds i18n/l10n support to Flask applications";
     longDescription = ''
       Implements i18n and l10n support for Flask.
diff --git a/pkgs/development/python-modules/flask-common/default.nix b/pkgs/development/python-modules/flask-common/default.nix
index 40c7903aee3d5..7dbf507f22050 100644
--- a/pkgs/development/python-modules/flask-common/default.nix
+++ b/pkgs/development/python-modules/flask-common/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , crayons, flask, flask-caching, gunicorn, maya, meinheld, whitenoise }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ crayons flask flask-caching gunicorn maya meinheld whitenoise ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flask extension with lots of common time-savers";
     homepage = "https://github.com/kennethreitz/flask-common";
     license = licenses.asl20; # XXX: setup.py lists BSD but git repo has Apache 2.0 LICENSE
diff --git a/pkgs/development/python-modules/flask-compress/default.nix b/pkgs/development/python-modules/flask-compress/default.nix
index fe55705bb521c..9491ca8be779f 100644
--- a/pkgs/development/python-modules/flask-compress/default.nix
+++ b/pkgs/development/python-modules/flask-compress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, flask
+{ lib, stdenv, fetchPypi, buildPythonPackage, flask
 , brotli
 }:
 
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ flask brotli ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compress responses in your Flask app with gzip";
     homepage = "https://libwilliam.github.io/flask-compress/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/flask-cors/default.nix b/pkgs/development/python-modules/flask-cors/default.nix
index 1f98794f70455..731e8b106ab79 100644
--- a/pkgs/development/python-modules/flask-cors/default.nix
+++ b/pkgs/development/python-modules/flask-cors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , nose, flask, six, packaging }:
 
 buildPythonPackage rec {
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     nosetests --exclude test_acl_uncaught_exception_500
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Flask extension adding a decorator for CORS support";
     homepage = "https://github.com/corydolphin/flask-cors";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/flask-elastic/default.nix b/pkgs/development/python-modules/flask-elastic/default.nix
index 9f8e27ea20f98..6986cd75be69b 100644
--- a/pkgs/development/python-modules/flask-elastic/default.nix
+++ b/pkgs/development/python-modules/flask-elastic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , flask, elasticsearch }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ flask elasticsearch ];
   doCheck = false; # no tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integrates official client for Elasticsearch into Flask";
     license = licenses.bsd3;
     maintainers = [ maintainers.mic92 ];
diff --git a/pkgs/development/python-modules/flask-jwt-extended/default.nix b/pkgs/development/python-modules/flask-jwt-extended/default.nix
index 4d45343c26586..cf8a70b05330a 100644
--- a/pkgs/development/python-modules/flask-jwt-extended/default.nix
+++ b/pkgs/development/python-modules/flask-jwt-extended/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, dateutil, flask, pyjwt, werkzeug, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, dateutil, flask, pyjwt, werkzeug, pytest }:
 
 buildPythonPackage rec {
   pname = "Flask-JWT-Extended";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     pytest tests/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "JWT extension for Flask";
     homepage = "https://flask-jwt-extended.readthedocs.io/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/flask-ldap-login/default.nix b/pkgs/development/python-modules/flask-ldap-login/default.nix
index 2573f54974085..1673ca24e6e0f 100644
--- a/pkgs/development/python-modules/flask-ldap-login/default.nix
+++ b/pkgs/development/python-modules/flask-ldap-login/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchFromGitHub, fetchpatch
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchFromGitHub, fetchpatch
 , flask, flask_wtf, flask_testing, ldap
 , mock, nose }:
 
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   checkPhase = "nosetests -d";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ContinuumIO/flask-ldap-login";
     description = "User session management for Flask";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/flask-limiter/default.nix b/pkgs/development/python-modules/flask-limiter/default.nix
index 1f24919b73c06..38d42da1c8a72 100644
--- a/pkgs/development/python-modules/flask-limiter/default.nix
+++ b/pkgs/development/python-modules/flask-limiter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, flask, limits }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, flask, limits }:
 
 buildPythonPackage rec {
   pname = "Flask-Limiter";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ flask limits ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rate limiting for flask applications";
     homepage = "https://flask-limiter.readthedocs.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/flask-login/default.nix b/pkgs/development/python-modules/flask-login/default.nix
index a4cd86ee69d41..919e353eb8e0f 100644
--- a/pkgs/development/python-modules/flask-login/default.nix
+++ b/pkgs/development/python-modules/flask-login/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonAtLeast
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonAtLeast
 , flask, blinker, nose, mock, semantic-version }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = pythonAtLeast "3.3";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/maxcountryman/flask-login";
     description = "User session management for Flask";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/flask-reverse-proxy-fix/default.nix b/pkgs/development/python-modules/flask-reverse-proxy-fix/default.nix
index f8001bc2aff5d..550f6520e7dba 100644
--- a/pkgs/development/python-modules/flask-reverse-proxy-fix/default.nix
+++ b/pkgs/development/python-modules/flask-reverse-proxy-fix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy3k
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     werkzeug
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Flask middleware for applications running under a reverse proxy";
     maintainers = with maintainers; [ matthiasbeyer ];
     homepage = "https://github.com/antarctica/flask-reverse-proxy-fix";
diff --git a/pkgs/development/python-modules/flask-silk/default.nix b/pkgs/development/python-modules/flask-silk/default.nix
index fc8c57be99a42..92d2f90848cbe 100644
--- a/pkgs/development/python-modules/flask-silk/default.nix
+++ b/pkgs/development/python-modules/flask-silk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , flask
@@ -21,7 +21,7 @@ buildPythonPackage {
     flask
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adds silk icons to your Flask application or module, or extension";
     license = licenses.bsd3;
     maintainers = teams.sage.members;
diff --git a/pkgs/development/python-modules/flask-sqlalchemy/default.nix b/pkgs/development/python-modules/flask-sqlalchemy/default.nix
index c811ce24157ed..16b8c9c7fc79e 100644
--- a/pkgs/development/python-modules/flask-sqlalchemy/default.nix
+++ b/pkgs/development/python-modules/flask-sqlalchemy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, flask, mock, sqlalchemy, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, flask, mock, sqlalchemy, pytest }:
 
 buildPythonPackage rec {
   pname = "Flask-SQLAlchemy";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SQLAlchemy extension for Flask";
     homepage = "http://flask-sqlalchemy.pocoo.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/flask-swagger-ui/default.nix b/pkgs/development/python-modules/flask-swagger-ui/default.nix
index cc4b4e06bfcc5..79650e7c17553 100644
--- a/pkgs/development/python-modules/flask-swagger-ui/default.nix
+++ b/pkgs/development/python-modules/flask-swagger-ui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, flask }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, flask }:
 
 buildPythonPackage rec {
   pname = "flask-swagger-ui";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     flask
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sveint/flask-swagger-ui";
     license = licenses.mit;
     description = "Swagger UI blueprint for Flask";
diff --git a/pkgs/development/python-modules/flask-swagger/default.nix b/pkgs/development/python-modules/flask-swagger/default.nix
index c690e4e64ae56..20624c3186208 100644
--- a/pkgs/development/python-modules/flask-swagger/default.nix
+++ b/pkgs/development/python-modules/flask-swagger/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , flask, pyyaml }:
 
 buildPythonPackage rec {
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     pyyaml
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gangverk/flask-swagger";
     license = licenses.mit;
     description = "Extract swagger specs from your flask project";
diff --git a/pkgs/development/python-modules/flask-testing/default.nix b/pkgs/development/python-modules/flask-testing/default.nix
index 24e2e6343a20e..9f4d66335de5e 100644
--- a/pkgs/development/python-modules/flask-testing/default.nix
+++ b/pkgs/development/python-modules/flask-testing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy3k, flask, blinker, twill }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy3k, flask, blinker, twill }:
 
 buildPythonPackage rec {
   pname = "Flask-Testing";
@@ -23,7 +23,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "flask_testing" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flask unittest integration.";
     homepage = "https://pythonhosted.org/Flask-Testing/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/flask-versioned/default.nix b/pkgs/development/python-modules/flask-versioned/default.nix
index 3bd5ef98b322e..15e7b2c1875d2 100644
--- a/pkgs/development/python-modules/flask-versioned/default.nix
+++ b/pkgs/development/python-modules/flask-versioned/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, flask }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, flask }:
 
 buildPythonPackage rec {
   pname = "Flask-Versioned";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ flask ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flask plugin to rewrite file paths to add version info";
     homepage = "https://github.com/pilt/flask-versioned";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/flask-wtf/default.nix b/pkgs/development/python-modules/flask-wtf/default.nix
index 060f592b2cff6..eadc7842a013a 100644
--- a/pkgs/development/python-modules/flask-wtf/default.nix
+++ b/pkgs/development/python-modules/flask-wtf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, flask, wtforms, nose }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, flask, wtforms, nose }:
 
 buildPythonPackage rec {
   pname = "Flask-WTF";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   doCheck = false; # requires external service
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple integration of Flask and WTForms.";
     license = licenses.bsd3;
     maintainers = [ maintainers.mic92 ];
diff --git a/pkgs/development/python-modules/flask/default.nix b/pkgs/development/python-modules/flask/default.nix
index bbac89406fc3c..d121b4e32c8b5 100644
--- a/pkgs/development/python-modules/flask/default.nix
+++ b/pkgs/development/python-modules/flask/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , itsdangerous, click, werkzeug, jinja2, pytest }:
 
 buildPythonPackage rec {
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Tests require extra dependencies
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://flask.pocoo.org/";
     description = "A microframework based on Werkzeug, Jinja 2, and good intentions";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/flaskbabel/default.nix b/pkgs/development/python-modules/flaskbabel/default.nix
index 2956e2036c9d9..eef31359f504e 100644
--- a/pkgs/development/python-modules/flaskbabel/default.nix
+++ b/pkgs/development/python-modules/flaskbabel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , flask
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ flask jinja2 speaklater Babel pytz ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adds i18n/l10n support to Flask applications";
     homepage = "https://github.com/mitsuhiko/flask-babel";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/flowlogs_reader/default.nix b/pkgs/development/python-modules/flowlogs_reader/default.nix
index 717e3a3291b6f..1a6591040a2e3 100644
--- a/pkgs/development/python-modules/flowlogs_reader/default.nix
+++ b/pkgs/development/python-modules/flowlogs_reader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ botocore boto3 docutils ];
   buildInputs = [ unittest2 mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library to make retrieving Amazon VPC Flow Logs from CloudWatch Logs a bit easier";
     homepage = "https://github.com/obsrvbl/flowlogs-reader";
     maintainers = with maintainers; [ cransom ];
diff --git a/pkgs/development/python-modules/flup/default.nix b/pkgs/development/python-modules/flup/default.nix
index a6ef4d421df31..52ac5da27aa13 100644
--- a/pkgs/development/python-modules/flup/default.nix
+++ b/pkgs/development/python-modules/flup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "5eb09f26eb0751f8380d8ac43d1dfb20e1d42eca0fa45ea9289fa532a79cd159";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.saddi.com/software/flup/";
     description = "FastCGI Python module set";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/flux-led/default.nix b/pkgs/development/python-modules/flux-led/default.nix
index 1cbfca78462f4..ddec811e21ced 100644
--- a/pkgs/development/python-modules/flux-led/default.nix
+++ b/pkgs/development/python-modules/flux-led/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , aiohttp, zigpy
 , pytest, isPy27 }:
 
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "1zgajlkhclyrqhkmivna4ha2lyvfpk5929s042gy59p7mzpkvjx7";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python library to communicate with the flux_led smart bulbs";
     homepage = "https://github.com/Danielhiversen/flux_led";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/foolscap/default.nix b/pkgs/development/python-modules/foolscap/default.nix
index 0c5a0fff79d2c..396bef6d009e2 100644
--- a/pkgs/development/python-modules/foolscap/default.nix
+++ b/pkgs/development/python-modules/foolscap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     # trial foolscap
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://foolscap.lothar.com/";
     description = "Foolscap, an RPC protocol for Python that follows the distributed object-capability model";
     longDescription = ''
diff --git a/pkgs/development/python-modules/forbiddenfruit/default.nix b/pkgs/development/python-modules/forbiddenfruit/default.nix
index 75b4fdef33781..64713d96adea1 100644
--- a/pkgs/development/python-modules/forbiddenfruit/default.nix
+++ b/pkgs/development/python-modules/forbiddenfruit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Patch python built-in objects";
     homepage = "https://pypi.python.org/pypi/forbiddenfruit";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/foxdot/default.nix b/pkgs/development/python-modules/foxdot/default.nix
index cc9ad87052b02..d60c1e89900ad 100644
--- a/pkgs/development/python-modules/foxdot/default.nix
+++ b/pkgs/development/python-modules/foxdot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, tkinter, supercollider }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, tkinter, supercollider }:
 
 buildPythonPackage rec {
   pname = "FoxDot";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # Requires a running SuperCollider instance
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Live coding music with SuperCollider";
     homepage = "https://foxdot.org/";
     license = licenses.cc-by-sa-40;
diff --git a/pkgs/development/python-modules/freezegun/0.3.nix b/pkgs/development/python-modules/freezegun/0.3.nix
index 219fc180b225e..9dc88596f2676 100644
--- a/pkgs/development/python-modules/freezegun/0.3.nix
+++ b/pkgs/development/python-modules/freezegun/0.3.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # contains python3 specific code
   doCheck = !isPy27;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FreezeGun: Let your Python tests travel through time";
     homepage = "https://github.com/spulec/freezegun";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/freezegun/default.nix b/pkgs/development/python-modules/freezegun/default.nix
index 743b041775f05..f1b1d9738d725 100644
--- a/pkgs/development/python-modules/freezegun/default.nix
+++ b/pkgs/development/python-modules/freezegun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pythonOlder
 , fetchPypi
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # contains python3 specific code
   doCheck = !isPy27;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FreezeGun: Let your Python tests travel through time";
     homepage = "https://github.com/spulec/freezegun";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/fritzconnection/default.nix b/pkgs/development/python-modules/fritzconnection/default.nix
index d55941bd5b47e..05999d8da79f6 100644
--- a/pkgs/development/python-modules/fritzconnection/default.nix
+++ b/pkgs/development/python-modules/fritzconnection/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchFromGitHub, pytest, requests }:
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchFromGitHub, pytest, requests }:
 
 buildPythonPackage rec {
   pname = "fritzconnection";
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python-Tool to communicate with the AVM FritzBox using the TR-064 protocol";
     homepage = "https://bitbucket.org/kbr/fritzconnection";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/frozendict/default.nix b/pkgs/development/python-modules/frozendict/default.nix
index 583dad1b014d5..dd0c99298265b 100644
--- a/pkgs/development/python-modules/frozendict/default.nix
+++ b/pkgs/development/python-modules/frozendict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "frozendict";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # frozendict does not come with tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/slezica/python-frozendict";
     description = "An immutable dictionary";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ftfy/default.nix b/pkgs/development/python-modules/ftfy/default.nix
index a781230a9193b..63342c7045d04 100644
--- a/pkgs/development/python-modules/ftfy/default.nix
+++ b/pkgs/development/python-modules/ftfy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -34,7 +34,7 @@ buildPythonPackage rec {
     PATH=$out/bin:$PATH pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Given Unicode text, make its representation consistent and possibly less broken";
     homepage = "https://github.com/LuminosoInsight/python-ftfy";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/fudge/default.nix b/pkgs/development/python-modules/fudge/default.nix
index 16656fb19a747..3f53b66d1efa4 100644
--- a/pkgs/development/python-modules/fudge/default.nix
+++ b/pkgs/development/python-modules/fudge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     nosetests -v
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/fudge-py/fudge";
     description = "Replace real objects with fakes (mocks, stubs, etc) while testing";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/funcparserlib/default.nix b/pkgs/development/python-modules/funcparserlib/default.nix
index 3a9503419ecdd..773ed1dccd677 100644
--- a/pkgs/development/python-modules/funcparserlib/default.nix
+++ b/pkgs/development/python-modules/funcparserlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # Tests are Python 2.x only judging from SyntaxError
   doCheck = !(isPy3k);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recursive descent parsing library based on functional combinators";
     homepage = "https://github.com/vlasovskikh/funcparserlib";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/funcsigs/default.nix b/pkgs/development/python-modules/funcsigs/default.nix
index 1febf9d356eb2..aaa49254eccbe 100644
--- a/pkgs/development/python-modules/funcsigs/default.nix
+++ b/pkgs/development/python-modules/funcsigs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , isPyPy, isPy3k, unittest2
 }:
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # https://github.com/testing-cabal/funcsigs/issues/10
   patches = stdenv.lib.optional (isPyPy && isPy3k) [ ./fix-pypy3-tests.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python function signatures from PEP362 for Python 2.6, 2.7 and 3.2+";
     homepage = "https://github.com/aliles/funcsigs";
     maintainers = with maintainers; [ ];
diff --git a/pkgs/development/python-modules/functools32/default.nix b/pkgs/development/python-modules/functools32/default.nix
index fea79db3d05bc..cec9da4239584 100644
--- a/pkgs/development/python-modules/functools32/default.nix
+++ b/pkgs/development/python-modules/functools32/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -13,7 +13,7 @@ if isPy3k then null else buildPythonPackage rec {
     sha256 = "0v8ya0b58x47wp216n1zamimv4iw57cxz3xxhzix52jkw3xks9gn";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This is a backport of the functools standard library module from";
     homepage = "https://github.com/MiCHiLU/python-functools32";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/funcy/default.nix b/pkgs/development/python-modules/funcy/default.nix
index 96b12e631abf7..3db08cf22bbd6 100644
--- a/pkgs/development/python-modules/funcy/default.nix
+++ b/pkgs/development/python-modules/funcy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of fancy functional tools focused on practicality";
     homepage = "https://funcy.readthedocs.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/furl/default.nix b/pkgs/development/python-modules/furl/default.nix
index 5893e5a6b9415..b7592885007e8 100644
--- a/pkgs/development/python-modules/furl/default.nix
+++ b/pkgs/development/python-modules/furl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, flake8, six, orderedmultidict, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, flake8, six, orderedmultidict, pytest }:
 
 buildPythonPackage rec {
   pname = "furl";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     pytest -k 'not join'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "furl is a small Python library that makes parsing and manipulating URLs easy";
     homepage = "https://github.com/gruns/furl";
     license = licenses.unlicense;
diff --git a/pkgs/development/python-modules/fuse-python/default.nix b/pkgs/development/python-modules/fuse-python/default.nix
index ab87f57be3957..01ab12b1ab511 100644
--- a/pkgs/development/python-modules/fuse-python/default.nix
+++ b/pkgs/development/python-modules/fuse-python/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pkgconfig, fuse }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pkgconfig, fuse }:
 
 buildPythonPackage rec {
   pname = "fuse-python";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # no tests in the Pypi archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for FUSE";
     homepage = "https://github.com/libfuse/python-fuse";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/fusepy/default.nix b/pkgs/development/python-modules/fusepy/default.nix
index 57355126dde21..858d3e13ea0ca 100644
--- a/pkgs/development/python-modules/fusepy/default.nix
+++ b/pkgs/development/python-modules/fusepy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -23,7 +23,7 @@ buildPythonPackage rec {
       "find_library('fuse')" "'${pkgs.fuse}/lib/libfuse.so'"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple ctypes bindings for FUSE";
     longDescription = ''
       Python module that provides a simple interface to FUSE and MacFUSE.
diff --git a/pkgs/development/python-modules/fuzzywuzzy/default.nix b/pkgs/development/python-modules/fuzzywuzzy/default.nix
index 8baec8c1089a2..c2d16a559842a 100644
--- a/pkgs/development/python-modules/fuzzywuzzy/default.nix
+++ b/pkgs/development/python-modules/fuzzywuzzy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, python-Levenshtein, pycodestyle, hypothesis, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, python-Levenshtein, pycodestyle, hypothesis, pytest }:
 
 buildPythonPackage rec {
   pname = "fuzzywuzzy";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ python-Levenshtein ];
   checkInputs = [ pycodestyle hypothesis pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fuzzy string matching for Python";
     homepage = "https://github.com/seatgeek/fuzzywuzzy";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/gast/default.nix b/pkgs/development/python-modules/gast/default.nix
index 49687ebe3184a..e4dbe43ef8d75 100644
--- a/pkgs/development/python-modules/gast/default.nix
+++ b/pkgs/development/python-modules/gast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, astunparse }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, astunparse }:
 
 buildPythonPackage rec {
   pname = "gast";
@@ -8,7 +8,7 @@ buildPythonPackage rec {
     sha256 = "40feb7b8b8434785585ab224d1568b857edb18297e5a3047f1ba012bc83b42c1";
   };
   checkInputs = [ astunparse ] ;
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GAST provides a compatibility layer between the AST of various Python versions, as produced by ast.parse from the standard ast module.";
     license = licenses.bsd3;
     maintainers = with maintainers; [ jyp ];
diff --git a/pkgs/development/python-modules/gateone/default.nix b/pkgs/development/python-modules/gateone/default.nix
index 372cdae8c233c..981cbbb7e8c30 100644
--- a/pkgs/development/python-modules/gateone/default.nix
+++ b/pkgs/development/python-modules/gateone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , tornado
 , futures
@@ -25,7 +25,7 @@ buildPythonPackage {
     cp -R "$out/gateone/"* $out/lib/python2.7/site-packages/gateone
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://liftoffsoftware.com/";
     description = "GateOne is a web-based terminal emulator and SSH client";
     maintainers = with maintainers; [ tomberek ];
diff --git a/pkgs/development/python-modules/gcovr/default.nix b/pkgs/development/python-modules/gcovr/default.nix
index 774b2087d8fdf..bedb7f3a3755b 100644
--- a/pkgs/development/python-modules/gcovr/default.nix
+++ b/pkgs/development/python-modules/gcovr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , jinja2
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     "gcovr.configuration"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python script for summarizing gcov data";
     license = licenses.bsd0;
     homepage = "https://www.gcovr.com/";
diff --git a/pkgs/development/python-modules/gdata/default.nix b/pkgs/development/python-modules/gdata/default.nix
index 182fdc402a64e..bf9c01c250abd 100644
--- a/pkgs/development/python-modules/gdata/default.nix
+++ b/pkgs/development/python-modules/gdata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Fails with "error: invalid command 'test'"
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/google/gdata-python-client";
     description = "Python client library for Google data APIs";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/gdrivefs/default.nix b/pkgs/development/python-modules/gdrivefs/default.nix
index 24b788f2c6d77..aab5efea97def 100644
--- a/pkgs/development/python-modules/gdrivefs/default.nix
+++ b/pkgs/development/python-modules/gdrivefs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPy3k
@@ -29,7 +29,7 @@ buildPythonPackage rec {
       --replace "==" ">="
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mount Google Drive as a local file system";
     longDescription = ''
       GDriveFS is a FUSE wrapper for Google Drive developed. Design goals:
diff --git a/pkgs/development/python-modules/geeknote/default.nix b/pkgs/development/python-modules/geeknote/default.nix
index cacc832486e26..4eb209a8af7f6 100644
--- a/pkgs/development/python-modules/geeknote/default.nix
+++ b/pkgs/development/python-modules/geeknote/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -28,7 +28,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ thrift beautifulsoup4 markdown2 sqlalchemy html2text evernote ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Work with Evernote from command line";
     homepage = "http://www.geeknote.me";
     license = licenses.gpl1;
diff --git a/pkgs/development/python-modules/genanki/default.nix b/pkgs/development/python-modules/genanki/default.nix
index bda80fe9e7528..f43fdabf09e51 100644
--- a/pkgs/development/python-modules/genanki/default.nix
+++ b/pkgs/development/python-modules/genanki/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , cached-property, frozendict, pystache, pyyaml, pytest, pytestrunner
 }:
 
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kerrickstaley/genanki";
     description = "Generate Anki decks programmatically";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/genshi/default.nix b/pkgs/development/python-modules/genshi/default.nix
index 9e6bab6e1690f..9a6e4508e30e4 100644
--- a/pkgs/development/python-modules/genshi/default.nix
+++ b/pkgs/development/python-modules/genshi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     setuptools six
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python components for parsing HTML, XML and other textual content";
     longDescription = ''
       Python library that provides an integrated set of components for
diff --git a/pkgs/development/python-modules/genzshcomp/default.nix b/pkgs/development/python-modules/genzshcomp/default.nix
index 5917d71c4408e..8f486cc29efbe 100644
--- a/pkgs/development/python-modules/genzshcomp/default.nix
+++ b/pkgs/development/python-modules/genzshcomp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically generated zsh completion function for Python's option parser modules";
     homepage = "https://bitbucket.org/hhatto/genzshcomp/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/geoalchemy2/default.nix b/pkgs/development/python-modules/geoalchemy2/default.nix
index e96c67b044db1..56f9346668f69 100644
--- a/pkgs/development/python-modules/geoalchemy2/default.nix
+++ b/pkgs/development/python-modules/geoalchemy2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , sqlalchemy
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # https://github.com/geoalchemy/geoalchemy2/blob/e05a676350b11f0e73609379dae5625c5de2e868/TEST.rst
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage =  "http://geoalchemy.org/";
     license = licenses.mit;
     description = "Toolkit for working with spatial databases";
diff --git a/pkgs/development/python-modules/geographiclib/default.nix b/pkgs/development/python-modules/geographiclib/default.nix
index 0c275b672abd5..98c1ee417e432 100644
--- a/pkgs/development/python-modules/geographiclib/default.nix
+++ b/pkgs/development/python-modules/geographiclib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0cn6ap5fkh3mkfa57l5b44z3gvz7j6lpmc9rl4g2jny2gvp4dg8j";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://geographiclib.sourceforge.io";
     description = "Algorithms for geodesics (Karney, 2013) for solving the direct and inverse problems for an ellipsoid of revolution";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/geopandas/default.nix b/pkgs/development/python-modules/geopandas/default.nix
index bd38d2663bc28..bee22eb98bda4 100644
--- a/pkgs/development/python-modules/geopandas/default.nix
+++ b/pkgs/development/python-modules/geopandas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy27
 , pandas, shapely, fiona, descartes, pyproj
 , pytestCheckHook, Rtree, fetchpatch }:
 
@@ -41,7 +41,7 @@ buildPythonPackage rec {
     pyproj
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python geospatial data analysis framework";
     homepage = "https://geopandas.org";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/geopy/2.nix b/pkgs/development/python-modules/geopy/2.nix
index 2863d30f4684d..ae4e07e254792 100644
--- a/pkgs/development/python-modules/geopy/2.nix
+++ b/pkgs/development/python-modules/geopy/2.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     sha256 = "0jypkaqlbyr8icqypwm23lzsvq7flakp3a3nqr8ib5fmd0fzsq7q";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/geopy/geopy";
     description = "Python Geocoding Toolbox";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/geopy/default.nix b/pkgs/development/python-modules/geopy/default.nix
index 817c1e38418e4..fdf478d161030 100644
--- a/pkgs/development/python-modules/geopy/default.nix
+++ b/pkgs/development/python-modules/geopy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy3k
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     sha256 = "07l1pblzg3hb3dbvd9rq8x78ly5dv0zxbc5hwskqil0bhv5v1p39";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/geopy/geopy";
     description = "Python Geocoding Toolbox";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/gevent-socketio/default.nix b/pkgs/development/python-modules/gevent-socketio/default.nix
index 2b847275bed00..88d1089d5a311 100644
--- a/pkgs/development/python-modules/gevent-socketio/default.nix
+++ b/pkgs/development/python-modules/gevent-socketio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , versiontools
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   buildInputs = [ versiontools gevent-websocket mock pytest ];
   propagatedBuildInputs = [ gevent ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/abourget/gevent-socketio";
     description = "SocketIO server based on the Gevent pywsgi server, a Python network library";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/gevent-websocket/default.nix b/pkgs/development/python-modules/gevent-websocket/default.nix
index adc13738d5ea6..431a0c09a30c3 100644
--- a/pkgs/development/python-modules/gevent-websocket/default.nix
+++ b/pkgs/development/python-modules/gevent-websocket/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ gevent gunicorn ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gitlab.com/noppo/gevent-websocket";
     description = "Websocket handler for the gevent pywsgi server, a Python network library";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/gevent/default.nix b/pkgs/development/python-modules/gevent/default.nix
index bf066f5190656..ba80a928f255a 100644
--- a/pkgs/development/python-modules/gevent/default.nix
+++ b/pkgs/development/python-modules/gevent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPyPy, python, libev, greenlet
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPyPy, python, libev, greenlet
 , zope_interface
 }:
 
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # Bunch of failures.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Coroutine-based networking library";
     homepage = "http://www.gevent.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/geventhttpclient/default.nix b/pkgs/development/python-modules/geventhttpclient/default.nix
index 55ef8c39981a1..fafbef12bd3a6 100644
--- a/pkgs/development/python-modules/geventhttpclient/default.nix
+++ b/pkgs/development/python-modules/geventhttpclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     py.test $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gwik/geventhttpclient";
     description = "HTTP client library for gevent";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ghdiff/default.nix b/pkgs/development/python-modules/ghdiff/default.nix
index c58d63a083752..a9582648117a5 100644
--- a/pkgs/development/python-modules/ghdiff/default.nix
+++ b/pkgs/development/python-modules/ghdiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , zope_testrunner, six, chardet}:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   checkInputs = [ zope_testrunner ];
   propagatedBuildInputs = [ six chardet ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage =  "https://github.com/kilink/ghdiff";
     license = licenses.mit;
     description = "Generate Github-style HTML for unified diffs.";
diff --git a/pkgs/development/python-modules/gipc/default.nix b/pkgs/development/python-modules/gipc/default.nix
index 04dc8b0c068d5..a48547f290990 100644
--- a/pkgs/development/python-modules/gipc/default.nix
+++ b/pkgs/development/python-modules/gipc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , gevent
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ gevent ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "gevent-cooperative child processes and IPC";
     longDescription = ''
       Usage of Python's multiprocessing package in a gevent-powered
diff --git a/pkgs/development/python-modules/git-annex-adapter/default.nix b/pkgs/development/python-modules/git-annex-adapter/default.nix
index e5d9910024a5f..1c76e5622b8d5 100644
--- a/pkgs/development/python-modules/git-annex-adapter/default.nix
+++ b/pkgs/development/python-modules/git-annex-adapter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchFromGitHub, substituteAll
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchFromGitHub, substituteAll
 , python, util-linux, pygit2, gitMinimal, git-annex, cacert
 }:
 
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   '';
   pythonImportsCheck = [ "git_annex_adapter" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/alpernebbi/git-annex-adapter";
     description = "Call git-annex commands from Python";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/git-sweep/default.nix b/pkgs/development/python-modules/git-sweep/default.nix
index aa2a223c77745..adb9de4dbc0dd 100644
--- a/pkgs/development/python-modules/git-sweep/default.nix
+++ b/pkgs/development/python-modules/git-sweep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , GitPython
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ GitPython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line tool that helps you clean up Git branches";
     homepage = "https://github.com/arc90/git-sweep";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/globre/default.nix b/pkgs/development/python-modules/globre/default.nix
index ff2302f546787..21d2983ab0152 100644
--- a/pkgs/development/python-modules/globre/default.nix
+++ b/pkgs/development/python-modules/globre/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pythonAtLeast
 , buildPythonPackage
 , fetchPypi
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose coverage ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/metagriffin/globre";
     description = "A python glob-like regular expression generation library.";
     maintainers = with maintainers; [ glittershark ];
diff --git a/pkgs/development/python-modules/glom/default.nix b/pkgs/development/python-modules/glom/default.nix
index cae43e59c2887..2acc87a17ac46 100644
--- a/pkgs/development/python-modules/glom/default.nix
+++ b/pkgs/development/python-modules/glom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , boltons
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # test_cli.py checks the output of running "glom"
   checkPhase = "PATH=$out/bin:$PATH pytest glom/test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mahmoud/glom";
     description = "Restructuring data, the Python way";
     longDescription = ''
diff --git a/pkgs/development/python-modules/glymur/default.nix b/pkgs/development/python-modules/glymur/default.nix
index d2721951ad788..f8a0e4632389a 100644
--- a/pkgs/development/python-modules/glymur/default.nix
+++ b/pkgs/development/python-modules/glymur/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , numpy
@@ -42,7 +42,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for accessing JPEG2000 files";
     homepage = "https://github.com/quintusdias/glymur";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/gmpy2/default.nix b/pkgs/development/python-modules/gmpy2/default.nix
index cfc481a90afb2..808b918681bb3 100644
--- a/pkgs/development/python-modules/gmpy2/default.nix
+++ b/pkgs/development/python-modules/gmpy2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , fetchpatch
@@ -27,7 +27,7 @@ buildPythonPackage {
 
   buildInputs = [ gmp mpfr libmpc ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GMP/MPIR, MPFR, and MPC interface to Python 2.6+ and 3.x";
     homepage = "https://github.com/aleaxit/gmpy/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/gmusicapi/default.nix b/pkgs/development/python-modules/gmusicapi/default.nix
index deae0037bb2de..821e0ba0afa99 100644
--- a/pkgs/development/python-modules/gmusicapi/default.nix
+++ b/pkgs/development/python-modules/gmusicapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , validictory
@@ -29,7 +29,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ validictory decorator mutagen protobuf setuptools requests dateutil proboscis mock appdirs oauth2client pyopenssl gpsoauth MechanicalSoup future ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An unofficial API for Google Play Music";
     homepage = "https://pypi.python.org/pypi/gmusicapi/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/gnureadline/default.nix b/pkgs/development/python-modules/gnureadline/default.nix
index 3b9263258584d..71116c37041b8 100644
--- a/pkgs/development/python-modules/gnureadline/default.nix
+++ b/pkgs/development/python-modules/gnureadline/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace "/bin/bash" "${pkgs.bash}/bin/bash"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The standard Python readline extension statically linked against the GNU readline library";
     homepage = "https://github.com/ludwigschwardt/python-gnureadline";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/gnutls/default.nix b/pkgs/development/python-modules/gnutls/default.nix
index f26791fdbe968..addbee81bd3fa 100644
--- a/pkgs/development/python-modules/gnutls/default.nix
+++ b/pkgs/development/python-modules/gnutls/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     substituteInPlace gnutls/library/__init__.py --replace "/usr/local/lib" "${pkgs.gnutls.out}/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper for the GnuTLS library";
     homepage = "https://github.com/AGProjects/python-gnutls";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/goobook/default.nix b/pkgs/development/python-modules/goobook/default.nix
index a3d3272751575..c587c928e7e77 100644
--- a/pkgs/development/python-modules/goobook/default.nix
+++ b/pkgs/development/python-modules/goobook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , docutils, installShellFiles
 , google_api_python_client, simplejson, oauth2client, setuptools, xdg
 }:
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "goobook" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Access your Google contacts from the command line";
     longDescription = ''
       The purpose of GooBook is to make it possible to use your Google Contacts
diff --git a/pkgs/development/python-modules/goocalendar/default.nix b/pkgs/development/python-modules/goocalendar/default.nix
index 441fdc85bac20..46bafa43388b6 100644
--- a/pkgs/development/python-modules/goocalendar/default.nix
+++ b/pkgs/development/python-modules/goocalendar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , pkgconfig
@@ -40,7 +40,7 @@ buildPythonPackage rec {
   # No upstream tests available
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A calendar widget for GTK using PyGoocanvas.";
     homepage = "https://goocalendar.tryton.org/";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/google-apputils/default.nix b/pkgs/development/python-modules/google-apputils/default.nix
index b679be9dbf783..7cc7f4858826e 100644
--- a/pkgs/development/python-modules/google-apputils/default.nix
+++ b/pkgs/development/python-modules/google-apputils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -32,7 +32,7 @@ buildPythonPackage rec {
   # ERROR:root:Trying to access flag test_tmpdir before flags were parsed.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Application Utilities for Python";
     homepage = "https://github.com/google/google-apputils";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-auth/default.nix b/pkgs/development/python-modules/google-auth/default.nix
index abfe3754ccef5..9120f93a3bddd 100644
--- a/pkgs/development/python-modules/google-auth/default.nix
+++ b/pkgs/development/python-modules/google-auth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchpatch
 , fetchPypi
@@ -40,7 +40,7 @@ buildPythonPackage rec {
     "google.oauth2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Auth Python Library";
     longDescription = ''
       This library simplifies using Google’s various server-to-server
diff --git a/pkgs/development/python-modules/google-cloud-asset/default.nix b/pkgs/development/python-modules/google-cloud-asset/default.nix
index d9baa821fa1e8..8f04fb7451d2b 100644
--- a/pkgs/development/python-modules/google-cloud-asset/default.nix
+++ b/pkgs/development/python-modules/google-cloud-asset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpc_google_iam_v1
@@ -45,7 +45,7 @@ buildPythonPackage rec {
     "google.cloud.asset_v1p5beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Client for Google Cloud Asset API";
     homepage = "https://github.com/googleapis/python-asset";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-automl/default.nix b/pkgs/development/python-modules/google-cloud-automl/default.nix
index ce2a9e116cd89..302ce8ceaed36 100644
--- a/pkgs/development/python-modules/google-cloud-automl/default.nix
+++ b/pkgs/development/python-modules/google-cloud-automl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -50,7 +50,7 @@ buildPythonPackage rec {
     "google.cloud.automl_v1beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud AutoML API client library";
     homepage = "https://github.com/googleapis/python-automl";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-bigquery-datatransfer/default.nix b/pkgs/development/python-modules/google-cloud-bigquery-datatransfer/default.nix
index fde46ab7f12d9..4ec12a8fa2fb0 100644
--- a/pkgs/development/python-modules/google-cloud-bigquery-datatransfer/default.nix
+++ b/pkgs/development/python-modules/google-cloud-bigquery-datatransfer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     "google.cloud.bigquery_datatransfer_v1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BigQuery Data Transfer API client library";
     homepage = "https://github.com/googleapis/python-bigquery-datatransfer";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-bigquery/default.nix b/pkgs/development/python-modules/google-cloud-bigquery/default.nix
index 7206ee43af311..b8620ee8b35dd 100644
--- a/pkgs/development/python-modules/google-cloud-bigquery/default.nix
+++ b/pkgs/development/python-modules/google-cloud-bigquery/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -49,7 +49,7 @@ buildPythonPackage rec {
     "google.cloud.bigquery_v2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google BigQuery API client library";
     homepage = "https://github.com/googleapis/python-bigquery";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-bigtable/default.nix b/pkgs/development/python-modules/google-cloud-bigtable/default.nix
index 032a30bb24233..9632dc902d15c 100644
--- a/pkgs/development/python-modules/google-cloud-bigtable/default.nix
+++ b/pkgs/development/python-modules/google-cloud-bigtable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpc_google_iam_v1
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     pytest tests/unit -k 'not policy'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Bigtable API client library";
     homepage = "https://github.com/GoogleCloudPlatform/google-cloud-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-container/default.nix b/pkgs/development/python-modules/google-cloud-container/default.nix
index 011bb7b1967ee..6d91bed83ae70 100644
--- a/pkgs/development/python-modules/google-cloud-container/default.nix
+++ b/pkgs/development/python-modules/google-cloud-container/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -34,7 +34,7 @@ buildPythonPackage rec {
     "google.cloud.container_v1beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Container Engine API client library";
     homepage = "https://github.com/googleapis/python-container";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-core/default.nix b/pkgs/development/python-modules/google-cloud-core/default.nix
index c22c56a1ba490..72709c62ceca2 100644
--- a/pkgs/development/python-modules/google-cloud-core/default.nix
+++ b/pkgs/development/python-modules/google-cloud-core/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -29,7 +29,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "google.cloud" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "API Client library for Google Cloud: Core Helpers";
     homepage = "https://github.com/googleapis/python-cloud-core";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-dataproc/default.nix b/pkgs/development/python-modules/google-cloud-dataproc/default.nix
index f99b2c382fc66..1b7a570fed218 100644
--- a/pkgs/development/python-modules/google-cloud-dataproc/default.nix
+++ b/pkgs/development/python-modules/google-cloud-dataproc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     "google.cloud.dataproc_v1beta2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Dataproc API client library";
     homepage = "https://github.com/GoogleCloudPlatform/google-cloud-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-datastore/default.nix b/pkgs/development/python-modules/google-cloud-datastore/default.nix
index 5daa2cdd81ebf..84f98550b9a3a 100644
--- a/pkgs/development/python-modules/google-cloud-datastore/default.nix
+++ b/pkgs/development/python-modules/google-cloud-datastore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -37,7 +37,7 @@ buildPythonPackage rec {
     "google.cloud.datastore_v1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Datastore API client library";
     homepage = "https://github.com/googleapis/python-datastore";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-dlp/default.nix b/pkgs/development/python-modules/google-cloud-dlp/default.nix
index e02805c40762a..9076c1298040e 100644
--- a/pkgs/development/python-modules/google-cloud-dlp/default.nix
+++ b/pkgs/development/python-modules/google-cloud-dlp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     "google.cloud.dlp_v2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud Data Loss Prevention (DLP) API API client library";
     homepage = "https://github.com/googleapis/python-dlp";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-dns/default.nix b/pkgs/development/python-modules/google-cloud-dns/default.nix
index b6777fccec02a..0636da60e9af2 100644
--- a/pkgs/development/python-modules/google-cloud-dns/default.nix
+++ b/pkgs/development/python-modules/google-cloud-dns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -32,7 +32,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "google.cloud.dns" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud DNS API client library";
     homepage = "https://github.com/googleapis/python-dns";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-error-reporting/default.nix b/pkgs/development/python-modules/google-cloud-error-reporting/default.nix
index cdd54a291243d..b3181f8fcded0 100644
--- a/pkgs/development/python-modules/google-cloud-error-reporting/default.nix
+++ b/pkgs/development/python-modules/google-cloud-error-reporting/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -34,7 +34,7 @@ buildPythonPackage rec {
     rm -r google
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stackdriver Error Reporting API client library";
     homepage = "https://github.com/googleapis/python-error-reporting";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-firestore/default.nix b/pkgs/development/python-modules/google-cloud-firestore/default.nix
index 1de3ea11b37d4..f0c235ca0c98b 100644
--- a/pkgs/development/python-modules/google-cloud-firestore/default.nix
+++ b/pkgs/development/python-modules/google-cloud-firestore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , aiounittest
@@ -55,7 +55,7 @@ buildPythonPackage rec {
     "google.cloud.firestore_admin_v1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Firestore API client library";
     homepage = "https://github.com/googleapis/python-firestore";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-iot/default.nix b/pkgs/development/python-modules/google-cloud-iot/default.nix
index 7e8a224256d16..2b28f84a31589 100644
--- a/pkgs/development/python-modules/google-cloud-iot/default.nix
+++ b/pkgs/development/python-modules/google-cloud-iot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpc_google_iam_v1
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     "google.cloud.iot_v1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud IoT API API client library";
     homepage = "https://github.com/googleapis/python-iot";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-kms/default.nix b/pkgs/development/python-modules/google-cloud-kms/default.nix
index 49f088478ee05..6675767a2445d 100644
--- a/pkgs/development/python-modules/google-cloud-kms/default.nix
+++ b/pkgs/development/python-modules/google-cloud-kms/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -31,7 +31,7 @@ buildPythonPackage rec {
     "google.cloud.kms_v1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud Key Management Service (KMS) API API client library";
     homepage = "https://github.com/googleapis/python-kms";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-language/default.nix b/pkgs/development/python-modules/google-cloud-language/default.nix
index 2074b1edb1d6e..7186ecd6f3551 100644
--- a/pkgs/development/python-modules/google-cloud-language/default.nix
+++ b/pkgs/development/python-modules/google-cloud-language/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     "google.cloud.language_v1beta2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Natural Language API client library";
     homepage = "https://github.com/googleapis/python-language";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-logging/default.nix b/pkgs/development/python-modules/google-cloud-logging/default.nix
index dba00274021f4..58d03f206fc78 100644
--- a/pkgs/development/python-modules/google-cloud-logging/default.nix
+++ b/pkgs/development/python-modules/google-cloud-logging/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -50,7 +50,7 @@ buildPythonPackage rec {
     "google.cloud.logging_v2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stackdriver Logging API client library";
     homepage = "https://github.com/googleapis/python-logging";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-monitoring/default.nix b/pkgs/development/python-modules/google-cloud-monitoring/default.nix
index 10d7264c5606f..8dc665fe21039 100644
--- a/pkgs/development/python-modules/google-cloud-monitoring/default.nix
+++ b/pkgs/development/python-modules/google-cloud-monitoring/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     "google.cloud.monitoring_v3"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stackdriver Monitoring API client library";
     homepage = "https://github.com/GoogleCloudPlatform/google-cloud-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-pubsub/default.nix b/pkgs/development/python-modules/google-cloud-pubsub/default.nix
index e946f74ed3b2c..46a28b1ffd1da 100644
--- a/pkgs/development/python-modules/google-cloud-pubsub/default.nix
+++ b/pkgs/development/python-modules/google-cloud-pubsub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -33,7 +33,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "google.cloud.pubsub" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Pub/Sub API client library";
     homepage = "https://pypi.org/project/google-cloud-pubsub";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-redis/default.nix b/pkgs/development/python-modules/google-cloud-redis/default.nix
index 9408c6642d96f..4dcf7fd3d3180 100644
--- a/pkgs/development/python-modules/google-cloud-redis/default.nix
+++ b/pkgs/development/python-modules/google-cloud-redis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     "google.cloud.redis_v1beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Memorystore for Redis API client library";
     homepage = "https://github.com/googleapis/python-redis";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-resource-manager/default.nix b/pkgs/development/python-modules/google-cloud-resource-manager/default.nix
index 36e8d0bcc52ba..11baf3d73f3d0 100644
--- a/pkgs/development/python-modules/google-cloud-resource-manager/default.nix
+++ b/pkgs/development/python-modules/google-cloud-resource-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "google.cloud.resource_manager" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Resource Manager API client library";
     homepage = "https://github.com/googleapis/python-resource-manager";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-runtimeconfig/default.nix b/pkgs/development/python-modules/google-cloud-runtimeconfig/default.nix
index c4e569b88ad32..81fa97f152bb1 100644
--- a/pkgs/development/python-modules/google-cloud-runtimeconfig/default.nix
+++ b/pkgs/development/python-modules/google-cloud-runtimeconfig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -30,7 +30,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "google.cloud.runtimeconfig" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud RuntimeConfig API client library";
     homepage = "https://pypi.org/project/google-cloud-runtimeconfig";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-securitycenter/default.nix b/pkgs/development/python-modules/google-cloud-securitycenter/default.nix
index 4784dbe44739f..242198a219715 100644
--- a/pkgs/development/python-modules/google-cloud-securitycenter/default.nix
+++ b/pkgs/development/python-modules/google-cloud-securitycenter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpc_google_iam_v1
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     "google.cloud.securitycenter_v1p1beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud Security Command Center API API client library";
     homepage = "https://github.com/googleapis/python-securitycenter";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-spanner/default.nix b/pkgs/development/python-modules/google-cloud-spanner/default.nix
index 2591fd9dc6895..c78f328473072 100644
--- a/pkgs/development/python-modules/google-cloud-spanner/default.nix
+++ b/pkgs/development/python-modules/google-cloud-spanner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpc_google_iam_v1
@@ -45,7 +45,7 @@ buildPythonPackage rec {
     "google.cloud.spanner_v1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud Spanner API client library";
     homepage = "https://github.com/googleapis/python-spanner";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-speech/default.nix b/pkgs/development/python-modules/google-cloud-speech/default.nix
index a1d6762eafbf9..3359cfdd743aa 100644
--- a/pkgs/development/python-modules/google-cloud-speech/default.nix
+++ b/pkgs/development/python-modules/google-cloud-speech/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -34,7 +34,7 @@ buildPythonPackage rec {
     "google.cloud.speech_v1p1beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Speech API client library";
     homepage = "https://github.com/googleapis/python-speech";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-tasks/default.nix b/pkgs/development/python-modules/google-cloud-tasks/default.nix
index 8f86e71daedc2..e30986af6106a 100644
--- a/pkgs/development/python-modules/google-cloud-tasks/default.nix
+++ b/pkgs/development/python-modules/google-cloud-tasks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -35,7 +35,7 @@ buildPythonPackage rec {
     "google.cloud.tasks_v2beta3"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud Tasks API API client library";
     homepage = "https://github.com/googleapis/python-tasks";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-testutils/default.nix b/pkgs/development/python-modules/google-cloud-testutils/default.nix
index 7358c61f59a06..3f6792fa77b76 100644
--- a/pkgs/development/python-modules/google-cloud-testutils/default.nix
+++ b/pkgs/development/python-modules/google-cloud-testutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, google-auth, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, google-auth, six }:
 
 buildPythonPackage rec {
   pname = "google-cloud-testutils";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "test_utils" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System test utilities for google-cloud-python";
     homepage = "https://github.com/googleapis/python-test-utils";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-texttospeech/default.nix b/pkgs/development/python-modules/google-cloud-texttospeech/default.nix
index 7c8f738f57b75..a7228a42999b8 100644
--- a/pkgs/development/python-modules/google-cloud-texttospeech/default.nix
+++ b/pkgs/development/python-modules/google-cloud-texttospeech/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -34,7 +34,7 @@ buildPythonPackage rec {
     "google.cloud.texttospeech_v1beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Text-to-Speech API client library";
     homepage = "https://github.com/googleapis/python-texttospeech";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-trace/default.nix b/pkgs/development/python-modules/google-cloud-trace/default.nix
index 200f3dc1816a1..1252c99bf4862 100644
--- a/pkgs/development/python-modules/google-cloud-trace/default.nix
+++ b/pkgs/development/python-modules/google-cloud-trace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -35,7 +35,7 @@ buildPythonPackage rec {
     "google.cloud.trace_v2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud Trace API client library";
     homepage = "https://github.com/googleapis/python-trace";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-translate/default.nix b/pkgs/development/python-modules/google-cloud-translate/default.nix
index 41ec5e76fecea..32d402e1cf031 100644
--- a/pkgs/development/python-modules/google-cloud-translate/default.nix
+++ b/pkgs/development/python-modules/google-cloud-translate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -37,7 +37,7 @@ buildPythonPackage rec {
     "google.cloud.translate_v3beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Translation API client library";
     homepage = "https://github.com/googleapis/python-translate";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-videointelligence/default.nix b/pkgs/development/python-modules/google-cloud-videointelligence/default.nix
index 72a7f42e4f59b..43fed1fe27faf 100644
--- a/pkgs/development/python-modules/google-cloud-videointelligence/default.nix
+++ b/pkgs/development/python-modules/google-cloud-videointelligence/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -36,7 +36,7 @@ buildPythonPackage rec {
     "google.cloud.videointelligence_v1p3beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Video Intelligence API client library";
     homepage = "https://github.com/googleapis/python-videointelligence";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-vision/default.nix b/pkgs/development/python-modules/google-cloud-vision/default.nix
index 42e0aa61f7470..57a51f96e65ee 100644
--- a/pkgs/development/python-modules/google-cloud-vision/default.nix
+++ b/pkgs/development/python-modules/google-cloud-vision/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , google-api-core
@@ -32,7 +32,7 @@ buildPythonPackage rec {
     "google.cloud.vision_v1p4beta1"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud Vision API API client library";
     homepage = "https://github.com/googleapis/python-vision";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/google-cloud-websecurityscanner/default.nix b/pkgs/development/python-modules/google-cloud-websecurityscanner/default.nix
index c145bf9837d04..20614f5b5d863 100644
--- a/pkgs/development/python-modules/google-cloud-websecurityscanner/default.nix
+++ b/pkgs/development/python-modules/google-cloud-websecurityscanner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     "google.cloud.websecurityscanner_v1beta"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Web Security Scanner API client library";
     homepage = "https://github.com/googleapis/python-websecurityscanner";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/googleapis_common_protos/default.nix b/pkgs/development/python-modules/googleapis_common_protos/default.nix
index ea49beee30bbd..7e5b786b4fba6 100644
--- a/pkgs/development/python-modules/googleapis_common_protos/default.nix
+++ b/pkgs/development/python-modules/googleapis_common_protos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpc
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     "google.type"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Common protobufs used in Google APIs";
     homepage = "https://github.com/googleapis/python-api-common-protos";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/googlemaps/default.nix b/pkgs/development/python-modules/googlemaps/default.nix
index 39219000bfdd9..c971119833e6f 100644
--- a/pkgs/development/python-modules/googlemaps/default.nix
+++ b/pkgs/development/python-modules/googlemaps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , requests
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     "test_transit_without_time"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/googlemaps/google-maps-services-python";
     description = "Python client library for Google Maps API Web Services";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/gorilla/default.nix b/pkgs/development/python-modules/gorilla/default.nix
index d93cddee765e3..bf4212edc5109 100644
--- a/pkgs/development/python-modules/gorilla/default.nix
+++ b/pkgs/development/python-modules/gorilla/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi}:
+{ lib, stdenv, buildPythonPackage, fetchPypi}:
 
 buildPythonPackage rec {
   pname = "gorilla";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "feb2899b923935c25420b94aa8c266ccb5c0315199c685b725303a73195d802c";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/christophercrouzet/gorilla";
     description = "Convenient approach to monkey patching";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/gpapi/default.nix b/pkgs/development/python-modules/gpapi/default.nix
index 1181c59c1fc44..788473b5ab8f3 100644
--- a/pkgs/development/python-modules/gpapi/default.nix
+++ b/pkgs/development/python-modules/gpapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , requests
 , protobuf
 , pycryptodome
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests protobuf pycryptodome ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/NoMore201/googleplay-api";
     license = licenses.gpl3;
     description = "Google Play Unofficial Python API";
diff --git a/pkgs/development/python-modules/gphoto2/default.nix b/pkgs/development/python-modules/gphoto2/default.nix
index 2834fc5a735dc..a25c855149028 100644
--- a/pkgs/development/python-modules/gphoto2/default.nix
+++ b/pkgs/development/python-modules/gphoto2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , pkgconfig
 , libgphoto2 }:
 
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = false; # No tests available
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python interface to libgphoto2";
     homepage = "https://github.com/jim-easterbrook/python-gphoto2";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/gplaycli/default.nix b/pkgs/development/python-modules/gplaycli/default.nix
index 7e74032390108..ecd52ad848c95 100644
--- a/pkgs/development/python-modules/gplaycli/default.nix
+++ b/pkgs/development/python-modules/gplaycli/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, stdenv, libffi, isPy3k, pyasn1, clint, ndg-httpsclient
+{ buildPythonPackage, lib, stdenv, libffi, isPy3k, pyasn1, clint, ndg-httpsclient
 , protobuf, requests, args, gpapi, pyaxmlparser, fetchFromGitHub
 }:
 
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ libffi pyasn1 clint ndg-httpsclient protobuf requests args gpapi pyaxmlparser ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/matlink/gplaycli";
     description = "Google Play Downloader via Command line";
     license = licenses.agpl3Plus;
diff --git a/pkgs/development/python-modules/gpsoauth/default.nix b/pkgs/development/python-modules/gpsoauth/default.nix
index 57130a7aa5294..2c4dfcd813959 100644
--- a/pkgs/development/python-modules/gpsoauth/default.nix
+++ b/pkgs/development/python-modules/gpsoauth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cffi
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ cffi cryptography enum34 idna ipaddress ndg-httpsclient pyopenssl pyasn1 pycparser pycryptodomex requests six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python client library for Google Play Services OAuth";
     homepage = "https://github.com/simon-weber/gpsoauth";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/gpy/default.nix b/pkgs/development/python-modules/gpy/default.nix
index e4a20bc83d72e..9c444f465f302 100644
--- a/pkgs/development/python-modules/gpy/default.nix
+++ b/pkgs/development/python-modules/gpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -43,7 +43,7 @@ buildPythonPackage rec {
     "GPy"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gaussian process framework in Python";
     homepage = "https://sheffieldml.github.io/GPy";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/gpyopt/default.nix b/pkgs/development/python-modules/gpyopt/default.nix
index 67f934ccf053f..22e6743582c25 100644
--- a/pkgs/development/python-modules/gpyopt/default.nix
+++ b/pkgs/development/python-modules/gpyopt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, setuptools
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, setuptools
 , numpy, scipy, gpy, emcee, nose }:
 
 buildPythonPackage rec {
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ setuptools numpy scipy gpy emcee ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bayesian optimization toolbox in Python";
     homepage = "https://sheffieldml.github.io/GPyOpt";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/gradient_sdk/default.nix b/pkgs/development/python-modules/gradient_sdk/default.nix
index 3ee66a1c52428..adaafd8eadbe4 100644
--- a/pkgs/development/python-modules/gradient_sdk/default.nix
+++ b/pkgs/development/python-modules/gradient_sdk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , hyperopt
 }:
 
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "gradient_sdk" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gradient ML SDK";
     homepage    = "https://github.com/Paperspace/gradient-sdk";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/gradient_statsd/default.nix b/pkgs/development/python-modules/gradient_statsd/default.nix
index 14623ff625f54..607737d99ae02 100644
--- a/pkgs/development/python-modules/gradient_statsd/default.nix
+++ b/pkgs/development/python-modules/gradient_statsd/default.nix
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # Pypi does not contain tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wrapper around the DogStatsd client";
     homepage    = "https://paperspace.com";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/graphite-web/default.nix b/pkgs/development/python-modules/graphite-web/default.nix
index 16341e7180846..0bced13cd1124 100644
--- a/pkgs/development/python-modules/graphite-web/default.nix
+++ b/pkgs/development/python-modules/graphite-web/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , django, django_tagging, whisper, pycairo, cairocffi, ldap, memcached, pytz, urllib3, scandir
 }:
 buildPythonPackage rec {
@@ -28,7 +28,7 @@ buildPythonPackage rec {
       --replace "join(WEBAPP_DIR, 'content')" "join('$out', 'webapp', 'content')"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://graphiteapp.org/";
     description = "Enterprise scalable realtime graphing";
     maintainers = with maintainers; [ offline basvandijk ];
diff --git a/pkgs/development/python-modules/graphite_beacon/default.nix b/pkgs/development/python-modules/graphite_beacon/default.nix
index cc070f55323c2..06b66ccbc145a 100644
--- a/pkgs/development/python-modules/graphite_beacon/default.nix
+++ b/pkgs/development/python-modules/graphite_beacon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , tornado_5, pyyaml, funcparserlib
 , nixosTests
 }:
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     nixos = nixosTests.graphite;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple alerting application for Graphite metrics";
     homepage = "https://github.com/klen/graphite-beacon";
     maintainers = [ maintainers.offline ];
diff --git a/pkgs/development/python-modules/grappelli_safe/default.nix b/pkgs/development/python-modules/grappelli_safe/default.nix
index 299ce04f6fa23..7b2dd7e3fedda 100644
--- a/pkgs/development/python-modules/grappelli_safe/default.nix
+++ b/pkgs/development/python-modules/grappelli_safe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "35b7ccaf9acc54684c73aeefbeaddc63b8a16143bd981bd5b3ebef253def07df";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A snapshot of django-grappelli for the Mezzanine CMS";
     longDescription = ''
       grappelli_safe was created to provide a snapshot of the
diff --git a/pkgs/development/python-modules/grequests/default.nix b/pkgs/development/python-modules/grequests/default.nix
index 34e8c7ff16ff5..5ce5df8cdea25 100644
--- a/pkgs/development/python-modules/grequests/default.nix
+++ b/pkgs/development/python-modules/grequests/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests gevent ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Asynchronous HTTP requests";
     homepage = "https://github.com/kennethreitz/grequests";
     license = with licenses; [ bsd2 ];
diff --git a/pkgs/development/python-modules/grip/default.nix b/pkgs/development/python-modules/grip/default.nix
index cf29b11b268ee..019cd798d640f 100644
--- a/pkgs/development/python-modules/grip/default.nix
+++ b/pkgs/development/python-modules/grip/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 # Python bits:
@@ -42,7 +42,7 @@ buildPythonPackage rec {
       py.test -xm "not assumption"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Preview GitHub Markdown files like Readme locally before committing them";
     homepage = "https://github.com/joeyespo/grip";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/grpc_google_iam_v1/default.nix b/pkgs/development/python-modules/grpc_google_iam_v1/default.nix
index caa3b8cafb4cc..dd9527006dad6 100644
--- a/pkgs/development/python-modules/grpc_google_iam_v1/default.nix
+++ b/pkgs/development/python-modules/grpc_google_iam_v1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpcio
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   doCheck = false;
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GRPC library for the google-iam-v1 service";
     homepage = "https://github.com/googleapis/googleapis";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/grpcio-gcp/default.nix b/pkgs/development/python-modules/grpcio-gcp/default.nix
index 6af70be2f6cb7..1b631c0973ede 100644
--- a/pkgs/development/python-modules/grpcio-gcp/default.nix
+++ b/pkgs/development/python-modules/grpcio-gcp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , grpcio
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ grpcio ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "gRPC extensions for Google Cloud Platform";
     homepage = "https://grpc.io";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/grpcio-tools/default.nix b/pkgs/development/python-modules/grpcio-tools/default.nix
index 417b9d82e2e21..efae4b102d447 100644
--- a/pkgs/development/python-modules/grpcio-tools/default.nix
+++ b/pkgs/development/python-modules/grpcio-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, protobuf, grpcio, setuptools }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, protobuf, grpcio, setuptools }:
 
 buildPythonPackage rec {
   pname = "grpcio-tools";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # no tests in the package
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Protobuf code generator for gRPC";
     license = licenses.asl20;
     homepage = "https://grpc.io/grpc/python/";
diff --git a/pkgs/development/python-modules/grpcio/default.nix b/pkgs/development/python-modules/grpcio/default.nix
index e50f63fe37aca..6288828cd1bf3 100644
--- a/pkgs/development/python-modules/grpcio/default.nix
+++ b/pkgs/development/python-modules/grpcio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , darwin
 , grpc
@@ -39,7 +39,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "grpc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP/2-based RPC framework";
     license = licenses.asl20;
     homepage = "https://grpc.io/grpc/python/";
diff --git a/pkgs/development/python-modules/gsd/1.7.nix b/pkgs/development/python-modules/gsd/1.7.nix
index 6e6f0504aa722..0512a4906a273 100644
--- a/pkgs/development/python-modules/gsd/1.7.nix
+++ b/pkgs/development/python-modules/gsd/1.7.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # tests not packaged with gsd
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/glotzer/gsd";
     description = "General simulation data file format";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/gspread/default.nix b/pkgs/development/python-modules/gspread/default.nix
index 9ad1d0c685dcf..7cf2a8c8df113 100644
--- a/pkgs/development/python-modules/gspread/default.nix
+++ b/pkgs/development/python-modules/gspread/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests google-auth google-auth-oauthlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Spreadsheets client library";
     homepage = "https://github.com/burnash/gspread";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/gtimelog/default.nix b/pkgs/development/python-modules/gtimelog/default.nix
index c092da7358549..3af8e97ba71bd 100644
--- a/pkgs/development/python-modules/gtimelog/default.nix
+++ b/pkgs/development/python-modules/gtimelog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchFromGitHub, makeWrapper
 , glibcLocales, gobject-introspection, gtk3, libsoup, libsecret
 , buildPythonPackage, python
 , pygobject3, freezegun, mock
@@ -37,7 +37,7 @@ buildPythonPackage rec {
       --prefix LD_LIBRARY_PATH ":" "${gtk3.out}/lib" \
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A time tracking app";
     longDescription = ''
       GTimeLog is a small time tracking application for GNOME.
diff --git a/pkgs/development/python-modules/guestfs/default.nix b/pkgs/development/python-modules/guestfs/default.nix
index a446166c29176..fd12aab81b4a9 100644
--- a/pkgs/development/python-modules/guestfs/default.nix
+++ b/pkgs/development/python-modules/guestfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchurl, libguestfs, qemu }:
+{ lib, stdenv, buildPythonPackage, fetchurl, libguestfs, qemu }:
 
 buildPythonPackage rec {
   pname = "guestfs";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ libguestfs qemu ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://libguestfs.org/guestfs-python.3.html";
     description = "Use libguestfs from Python";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/development/python-modules/gunicorn/19.nix b/pkgs/development/python-modules/gunicorn/19.nix
index f9681eef97e36..c1091fa980c98 100644
--- a/pkgs/development/python-modules/gunicorn/19.nix
+++ b/pkgs/development/python-modules/gunicorn/19.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , coverage
 , mock
 , pytest
@@ -31,7 +31,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "gunicorn" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/benoitc/gunicorn";
     description = "WSGI HTTP Server for UNIX";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/gunicorn/default.nix b/pkgs/development/python-modules/gunicorn/default.nix
index 8bdc429690322..983335f4395bc 100644
--- a/pkgs/development/python-modules/gunicorn/default.nix
+++ b/pkgs/development/python-modules/gunicorn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27
 , coverage
 , mock
 , pytest
@@ -32,7 +32,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "gunicorn" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/benoitc/gunicorn";
     description = "WSGI HTTP Server for UNIX";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/guzzle_sphinx_theme/default.nix b/pkgs/development/python-modules/guzzle_sphinx_theme/default.nix
index 7b4498afb2c50..f70625b86fe26 100644
--- a/pkgs/development/python-modules/guzzle_sphinx_theme/default.nix
+++ b/pkgs/development/python-modules/guzzle_sphinx_theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, sphinx, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, sphinx, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "guzzle_sphinx_theme";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ sphinx ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sphinx theme used by Guzzle: http://guzzlephp.org";
     homepage = "https://github.com/guzzle/guzzle_sphinx_theme/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/gyp/default.nix b/pkgs/development/python-modules/gyp/default.nix
index c951c97b20f4d..b08814d4bd120 100644
--- a/pkgs/development/python-modules/gyp/default.nix
+++ b/pkgs/development/python-modules/gyp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitiles
 , isPy3k
@@ -19,7 +19,7 @@ buildPythonPackage {
     ./no-xcode.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to generate native build files";
     homepage = "https://chromium.googlesource.com/external/gyp/+/master/README.md";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/h2/default.nix b/pkgs/development/python-modules/h2/default.nix
index 7597abbe0f9e1..6dad775732c01 100644
--- a/pkgs/development/python-modules/h2/default.nix
+++ b/pkgs/development/python-modules/h2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , enum34, hpack, hyperframe, pytestCheckHook, hypothesis }:
 
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook hypothesis ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP/2 State-Machine based protocol implementation";
     homepage = "http://hyper.rtfd.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/h3/default.nix b/pkgs/development/python-modules/h3/default.nix
index e0d6ffce65316..46b774a25c1e1 100644
--- a/pkgs/development/python-modules/h3/default.nix
+++ b/pkgs/development/python-modules/h3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , cmake
 , fetchPypi
@@ -25,7 +25,7 @@ buildPythonPackage rec {
       --subst-var-by libh3_path ${h3}/lib/libh3${stdenv.hostPlatform.extensions.sharedLibrary}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/uber/h3-py";
     description = "This library provides Python bindings for the H3 Core Library.";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ha-ffmpeg/default.nix b/pkgs/development/python-modules/ha-ffmpeg/default.nix
index 01d0343b171f7..653c4483ce829 100644
--- a/pkgs/development/python-modules/ha-ffmpeg/default.nix
+++ b/pkgs/development/python-modules/ha-ffmpeg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , ffmpeg_3, async-timeout }:
 
 buildPythonPackage rec {
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # only manual tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pvizeli/ha-ffmpeg";
     description = "Library for home-assistant to handle ffmpeg";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/handout/default.nix b/pkgs/development/python-modules/handout/default.nix
index c5c111845d15f..b2b7b4b3d1427 100644
--- a/pkgs/development/python-modules/handout/default.nix
+++ b/pkgs/development/python-modules/handout/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , imageio, imageio-ffmpeg }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ imageio imageio-ffmpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Turn Python scripts into handouts with Markdown and figures";
     homepage = "https://github.com/danijar/handout";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/hawkauthlib/default.nix b/pkgs/development/python-modules/hawkauthlib/default.nix
index 1a8ddacdd6906..a0b7d50b560d6 100644
--- a/pkgs/development/python-modules/hawkauthlib/default.nix
+++ b/pkgs/development/python-modules/hawkauthlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , requests
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests webob ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mozilla-services/hawkauthlib";
     description = "Hawk Access Authentication protocol";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/hbmqtt/default.nix b/pkgs/development/python-modules/hbmqtt/default.nix
index 76ae5718024a4..053e955ad8064 100644
--- a/pkgs/development/python-modules/hbmqtt/default.nix
+++ b/pkgs/development/python-modules/hbmqtt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, setuptools
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, setuptools
 , transitions, websockets, passlib, docopt, pyyaml, nose }:
 
 buildPythonPackage rec {
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     nosetests -e test_connect_tcp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/beerfactory/hbmqtt";
     description = "MQTT client/broker using Python asynchronous I/O";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hcs_utils/default.nix b/pkgs/development/python-modules/hcs_utils/default.nix
index 445c2fe1f8273..56e9811396e61 100644
--- a/pkgs/development/python-modules/hcs_utils/default.nix
+++ b/pkgs/development/python-modules/hcs_utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonOlder, buildPythonPackage, fetchPypi, six, glibcLocales, pytest }:
+{ lib, stdenv, pythonOlder, buildPythonPackage, fetchPypi, six, glibcLocales, pytest }:
 
 buildPythonPackage rec {
   pname = "hcs_utils";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.4";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library collecting some useful snippets";
     homepage    = "https://pypi.python.org/pypi/hcs_utils/1.3";
     license     = licenses.isc;
diff --git a/pkgs/development/python-modules/hdmedians/default.nix b/pkgs/development/python-modules/hdmedians/default.nix
index 80e287d376f4b..3b65e10bfcece 100644
--- a/pkgs/development/python-modules/hdmedians/default.nix
+++ b/pkgs/development/python-modules/hdmedians/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/daleroberts/hdmedians";
     description = "High-dimensional medians";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/heapdict/default.nix b/pkgs/development/python-modules/heapdict/default.nix
index 159e0a7d74e96..4cd695925f280 100644
--- a/pkgs/development/python-modules/heapdict/default.nix
+++ b/pkgs/development/python-modules/heapdict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k }:
 
 buildPythonPackage rec {
   pname = "HeapDict";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a heap with decrease-key and increase-key operations.";
     homepage = "http://stutzbachenterprises.com";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/helper/default.nix b/pkgs/development/python-modules/helper/default.nix
index 00e4ddce8b4bd..4c7ff0c3878f3 100644
--- a/pkgs/development/python-modules/helper/default.nix
+++ b/pkgs/development/python-modules/helper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pyyaml, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pyyaml, mock }:
 
 buildPythonPackage rec {
   pname = "helper";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests in the pypi tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Development library for quickly writing configurable applications and daemons";
     homepage = "https://helper.readthedocs.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/hetzner/default.nix b/pkgs/development/python-modules/hetzner/default.nix
index 2909d2c2a6c5e..3b938dfc237c7 100644
--- a/pkgs/development/python-modules/hetzner/default.nix
+++ b/pkgs/development/python-modules/hetzner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "152fklxff08s71v0b78yp5ajwpqyszm3sd7j0qsrwa2x9ik4968h";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/RedMoonStudios/hetzner";
     description = "High-level Python API for accessing the Hetzner robot";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/heudiconv/default.nix b/pkgs/development/python-modules/heudiconv/default.nix
index 29a29a3b65228..ce29181882412 100644
--- a/pkgs/development/python-modules/heudiconv/default.nix
+++ b/pkgs/development/python-modules/heudiconv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -40,7 +40,7 @@ buildPythonPackage rec {
   # and these aren't in Nixpkgs
   checkPhase = "pytest -k 'not test_dlad and not test_monitor' heudiconv/tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://heudiconv.readthedocs.io";
     description = "Flexible DICOM converter for organizing imaging data";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/hg-evolve/default.nix b/pkgs/development/python-modules/hg-evolve/default.nix
index 434c6ffba2b9f..bcc93ba10cb24 100644
--- a/pkgs/development/python-modules/hg-evolve/default.nix
+++ b/pkgs/development/python-modules/hg-evolve/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enables the “changeset evolution” feature of Mercurial core";
     homepage = "https://www.mercurial-scm.org/doc/evolution/";
     maintainers = with maintainers; [ xavierzwirtz ];
diff --git a/pkgs/development/python-modules/hg-git/default.nix b/pkgs/development/python-modules/hg-git/default.nix
index c82352f9bfef4..fd321493b09be 100644
--- a/pkgs/development/python-modules/hg-git/default.nix
+++ b/pkgs/development/python-modules/hg-git/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , dulwich
@@ -26,7 +26,7 @@ buildPythonPackage rec {
       sha256 = "12r4qzbc5xcqwv0kvf8g4wjji7n45421zkbf6i75vyi4nl6n4j15";
     };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Push and pull from a Git server using Mercurial";
     homepage = "http://hg-git.github.com/";
     maintainers = with maintainers; [ koral ];
diff --git a/pkgs/development/python-modules/hglib/default.nix b/pkgs/development/python-modules/hglib/default.nix
index e96d7e2287084..afac7983584cc 100644
--- a/pkgs/development/python-modules/hglib/default.nix
+++ b/pkgs/development/python-modules/hglib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, substituteAll, python, nose, mercurial }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, substituteAll, python, nose, mercurial }:
 
 buildPythonPackage rec {
   pname = "python-hglib";
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     ${python.interpreter} test.py --with-hg "${mercurial}/bin/hg" -v
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mercurial Python library";
     homepage = "http://selenic.com/repo/python-hglib";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hgsvn/default.nix b/pkgs/development/python-modules/hgsvn/default.nix
index ccf8635b8b111..2ee6024cd4757 100644
--- a/pkgs/development/python-modules/hgsvn/default.nix
+++ b/pkgs/development/python-modules/hgsvn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -23,7 +23,7 @@ buildPythonPackage rec {
 
   doCheck = false;  # too many assumptions
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/hgsvn";
     description = "A set of scripts to work locally on Subversion checkouts using Mercurial";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/hidapi/default.nix b/pkgs/development/python-modules/hidapi/default.nix
index 856a36f77916a..c5ee1c2083925 100644
--- a/pkgs/development/python-modules/hidapi/default.nix
+++ b/pkgs/development/python-modules/hidapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libusb1, udev, darwin, fetchPypi, buildPythonPackage, cython }:
+{ lib, stdenv, libusb1, udev, darwin, fetchPypi, buildPythonPackage, cython }:
 
 buildPythonPackage rec {
   pname = "hidapi";
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "hid" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Cython interface to the hidapi from https://github.com/libusb/hidapi";
     homepage = "https://github.com/trezor/cython-hidapi";
     # license can actually be either bsd3 or gpl3
diff --git a/pkgs/development/python-modules/hieroglyph/default.nix b/pkgs/development/python-modules/hieroglyph/default.nix
index 0959d117de34f..418059c51658d 100644
--- a/pkgs/development/python-modules/hieroglyph/default.nix
+++ b/pkgs/development/python-modules/hieroglyph/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy27, sphinx }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy27, sphinx }:
 
 buildPythonPackage rec {
   pname = "hieroglyph";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # test_absolute_paths_made_relative (hieroglyph.tests.test_path_fixing.PostProcessImageTests) ... ERROR
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate HTML presentations from plain text sources";
     homepage = "https://github.com/nyergler/hieroglyph/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/hiredis/default.nix b/pkgs/development/python-modules/hiredis/default.nix
index 891c79f1b7b8a..e9d5677f8bebc 100644
--- a/pkgs/development/python-modules/hiredis/default.nix
+++ b/pkgs/development/python-modules/hiredis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , redis
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   '';
   pythonImportsCheck = [ "hiredis" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wraps protocol parsing code in hiredis, speeds up parsing of multi bulk replies";
     homepage = "https://github.com/redis/hiredis-py";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/hiro/default.nix b/pkgs/development/python-modules/hiro/default.nix
index f8ef8ba028d05..3ff672a22db65 100644
--- a/pkgs/development/python-modules/hiro/default.nix
+++ b/pkgs/development/python-modules/hiro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six, mock }:
 buildPythonPackage rec {
   pname = "hiro";
   version = "0.5.1";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Time manipulation utilities for Python";
     homepage = "https://hiro.readthedocs.io/en/latest/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hjson/default.nix b/pkgs/development/python-modules/hjson/default.nix
index 13dce54b9c3a8..3393ad186918c 100644
--- a/pkgs/development/python-modules/hjson/default.nix
+++ b/pkgs/development/python-modules/hjson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pythonImportsCheckHook
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     wrapProgram $out/bin/hjson --set PYTHONPATH "$PYTHONPATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A user interface for JSON";
     homepage = "https://github.com/hjson/hjson-py";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hkdf/default.nix b/pkgs/development/python-modules/hkdf/default.nix
index 347cd94c8f511..966ce7001fbb7 100644
--- a/pkgs/development/python-modules/hkdf/default.nix
+++ b/pkgs/development/python-modules/hkdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # no tests in PyPI tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HMAC-based Extract-and-Expand Key Derivation Function (HKDF)";
     homepage = "https://github.com/casebeer/python-hkdf";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/hocr-tools/default.nix b/pkgs/development/python-modules/hocr-tools/default.nix
index fdc578c76dffc..79a2e83508aad 100644
--- a/pkgs/development/python-modules/hocr-tools/default.nix
+++ b/pkgs/development/python-modules/hocr-tools/default.nix
@@ -3,7 +3,7 @@
 , lxml
 , pillow
 , reportlab
-, stdenv
+, lib, stdenv
 }:
 buildPythonPackage rec {
   pname = "hocr-tools";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pillow lxml reportlab ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "
 Tools for manipulating and evaluating the hOCR format for representing multi-lingual OCR results by embedding them into HTML";
     homepage = "https://github.com/tmbdev/hocr-tools";
diff --git a/pkgs/development/python-modules/holidays/default.nix b/pkgs/development/python-modules/holidays/default.nix
index 10ee1bbf2e760..b5e0062d115a1 100644
--- a/pkgs/development/python-modules/holidays/default.nix
+++ b/pkgs/development/python-modules/holidays/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , convertdate
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   ];
   pythonImportsCheck = [ "holidays" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dr-prodigy/python-holidays";
     description = "Generate and work with holidays in Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hoomd-blue/default.nix b/pkgs/development/python-modules/hoomd-blue/default.nix
index 455f1b4c99795..edb647a3fc606 100644
--- a/pkgs/development/python-modules/hoomd-blue/default.nix
+++ b/pkgs/development/python-modules/hoomd-blue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit
+{ lib, stdenv, fetchgit
 , cmake, pkgconfig
 , python
 , mpi ? null
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
   doCheck = false;
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://glotzerlab.engin.umich.edu/hoomd-blue/";
     description = "HOOMD-blue is a general-purpose particle simulation toolkit";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/hpack/default.nix b/pkgs/development/python-modules/hpack/default.nix
index 36578856286f1..9b6f724cd3188 100644
--- a/pkgs/development/python-modules/hpack/default.nix
+++ b/pkgs/development/python-modules/hpack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "fc41de0c63e687ebffde81187a948221294896f6bdc0ae2312708df339430095";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure-Python HPACK header compression";
     homepage = "http://hyper.rtfd.org";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hsaudiotag/default.nix b/pkgs/development/python-modules/hsaudiotag/default.nix
index 2da6e4a150c96..fba71dc3f109c 100644
--- a/pkgs/development/python-modules/hsaudiotag/default.nix
+++ b/pkgs/development/python-modules/hsaudiotag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure Python library that lets one to read metadata from media files";
     homepage = "http://hg.hardcoded.net/hsaudiotag/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/hsaudiotag3k/default.nix b/pkgs/development/python-modules/hsaudiotag3k/default.nix
index d12d3bc8c832c..52919e4898372 100644
--- a/pkgs/development/python-modules/hsaudiotag3k/default.nix
+++ b/pkgs/development/python-modules/hsaudiotag3k/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure Python library that lets one to read metadata from media files";
     homepage = "http://hg.hardcoded.net/hsaudiotag/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/html2text/2018.nix b/pkgs/development/python-modules/html2text/2018.nix
index e0a60e1ef0ac1..73540359ee1aa 100644
--- a/pkgs/development/python-modules/html2text/2018.nix
+++ b/pkgs/development/python-modules/html2text/2018.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "627514fb30e7566b37be6900df26c2c78a030cc9e6211bda604d8181233bcdd4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Turn HTML into equivalent Markdown-structured text";
     homepage = "https://github.com/Alir3z4/html2text/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/html5-parser/default.nix b/pkgs/development/python-modules/html5-parser/default.nix
index 4962e89526d82..61c23ac202222 100644
--- a/pkgs/development/python-modules/html5-parser/default.nix
+++ b/pkgs/development/python-modules/html5-parser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pkgs, pkgconfig, chardet, lxml }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pkgs, pkgconfig, chardet, lxml }:
 
 buildPythonPackage rec {
   pname = "html5-parser";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false; # No such file or directory: 'run_tests.py'
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast C based HTML 5 parsing for python";
     homepage = "https://html5-parser.readthedocs.io";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/htmllaundry/default.nix b/pkgs/development/python-modules/htmllaundry/default.nix
index 33d3691e85ad7..ef660fc0b9245 100644
--- a/pkgs/development/python-modules/htmllaundry/default.nix
+++ b/pkgs/development/python-modules/htmllaundry/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi, nose
 , six
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # not relevant for me, if releavnt for you, fix it...
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple HTML cleanup utilities";
     license = licenses.bsd3;
     homepage = "https://pypi.org/project/htmllaundry/";
diff --git a/pkgs/development/python-modules/httmock/default.nix b/pkgs/development/python-modules/httmock/default.nix
index 5913ceca777ba..117c7f5e132f1 100644
--- a/pkgs/development/python-modules/httmock/default.nix
+++ b/pkgs/development/python-modules/httmock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, requests }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, requests }:
 
 buildPythonPackage rec {
   pname   = "httmock";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   checkInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A mocking library for requests";
     homepage    = "https://github.com/patrys/httmock";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/http_signature/default.nix b/pkgs/development/python-modules/http_signature/default.nix
index d86861a92517b..145eea751b9b1 100644
--- a/pkgs/development/python-modules/http_signature/default.nix
+++ b/pkgs/development/python-modules/http_signature/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pycrypto ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/atl/py-http-signature";
     description = "Simple secure signing for HTTP requests using http-signature";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/httpauth/default.nix b/pkgs/development/python-modules/httpauth/default.nix
index bab2193f6a2d6..b7867e22f1756 100644
--- a/pkgs/development/python-modules/httpauth/default.nix
+++ b/pkgs/development/python-modules/httpauth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WSGI HTTP Digest Authentication middleware";
     homepage = "https://github.com/jonashaag/httpauth";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/httpbin/default.nix b/pkgs/development/python-modules/httpbin/default.nix
index cf5891ed0ee22..cbaf89c3ca61b 100644
--- a/pkgs/development/python-modules/httpbin/default.nix
+++ b/pkgs/development/python-modules/httpbin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -26,7 +26,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kennethreitz/httpbin";
     description = "HTTP Request & Response Service";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/httpretty/0.nix b/pkgs/development/python-modules/httpretty/0.nix
index ee0e598a9ac2f..436bbd97fd2fd 100644
--- a/pkgs/development/python-modules/httpretty/0.nix
+++ b/pkgs/development/python-modules/httpretty/0.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , tornado
@@ -44,7 +44,7 @@ buildPythonPackage rec {
     "tests.functional.test_requests.test_httpretty_should_allow_adding_and_overwritting_by_kwargs_u2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://httpretty.readthedocs.org/";
     description = "HTTP client request mocking tool";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/httpretty/default.nix b/pkgs/development/python-modules/httpretty/default.nix
index 0d061df86bf7a..93cf6a0927f1b 100644
--- a/pkgs/development/python-modules/httpretty/default.nix
+++ b/pkgs/development/python-modules/httpretty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , tornado
@@ -51,7 +51,7 @@ buildPythonPackage rec {
     "tests.functional.test_requests.test_httpretty_should_allow_adding_and_overwritting_by_kwargs_u2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://httpretty.readthedocs.org/";
     description = "HTTP client request mocking tool";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/humanize/default.nix b/pkgs/development/python-modules/humanize/default.nix
index 70ac0297b739e..09e94f6275dd3 100644
--- a/pkgs/development/python-modules/humanize/default.nix
+++ b/pkgs/development/python-modules/humanize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python humanize utilities";
     homepage = "https://github.com/jmoiron/humanize";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hyperframe/default.nix b/pkgs/development/python-modules/hyperframe/default.nix
index 2c6796ca6d0ca..a74198f383213 100644
--- a/pkgs/development/python-modules/hyperframe/default.nix
+++ b/pkgs/development/python-modules/hyperframe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytestCheckHook }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytestCheckHook }:
 
 buildPythonPackage rec {
   pname = "hyperframe";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP/2 framing layer for Python";
     homepage = "http://hyper.rtfd.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/hyperopt/default.nix b/pkgs/development/python-modules/hyperopt/default.nix
index 16599214ede77..ba4aeef402ec4 100644
--- a/pkgs/development/python-modules/hyperopt/default.nix
+++ b/pkgs/development/python-modules/hyperopt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , cloudpickle, numpy, future, networkx
 , six, tqdm, scipy, pymongo
 }:
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "hyperopt" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Distributed Asynchronous Hyperparameter Optimization";
     homepage    = "http://hyperopt.github.com/hyperopt/";
     license     = licenses.bsd2;
diff --git a/pkgs/development/python-modules/i3-py/default.nix b/pkgs/development/python-modules/i3-py/default.nix
index ea6e449947c59..4dea7526b7e7f 100644
--- a/pkgs/development/python-modules/i3-py/default.nix
+++ b/pkgs/development/python-modules/i3-py/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # no tests in tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for i3 users and developers";
     homepage =  "https://github.com/ziberna/i3-py";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/i3ipc/default.nix b/pkgs/development/python-modules/i3ipc/default.nix
index 231cb4f1d4133..c27d413541128 100644
--- a/pkgs/development/python-modules/i3ipc/default.nix
+++ b/pkgs/development/python-modules/i3ipc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , xorgserver, pytest, pytest-xvfb, i3, python, xlib, xdpyinfo
 , makeFontsConf, coreutils
 }:
@@ -32,7 +32,7 @@ buildPythonPackage rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An improved Python library to control i3wm and sway";
     homepage    = "https://github.com/acrisci/i3ipc-python";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/icalendar/default.nix b/pkgs/development/python-modules/icalendar/default.nix
index c8a3a09fd5508..4499d5d62f4f4 100644
--- a/pkgs/development/python-modules/icalendar/default.nix
+++ b/pkgs/development/python-modules/icalendar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   buildInputs = [ setuptools ];
   propagatedBuildInputs = [ dateutil pytz ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A parser/generator of iCalendar files";
     homepage = "https://icalendar.readthedocs.org/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/ics/default.nix b/pkgs/development/python-modules/ics/default.nix
index 30661c9bc91ab..c186020fee1ea 100644
--- a/pkgs/development/python-modules/ics/default.nix
+++ b/pkgs/development/python-modules/ics/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
 , tatsu, arrow
 , pytestCheckHook, pytest-flakes
 }:
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook pytest-flakes ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pythonic and easy iCalendar library (RFC 5545)";
     longDescription = ''
       Ics.py is a pythonic and easy iCalendar library. Its goals are to read and
diff --git a/pkgs/development/python-modules/ifaddr/default.nix b/pkgs/development/python-modules/ifaddr/default.nix
index b4a9b20f08d17..47997dbdc265e 100644
--- a/pkgs/development/python-modules/ifaddr/default.nix
+++ b/pkgs/development/python-modules/ifaddr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , ipaddress
@@ -20,7 +20,7 @@ buildPythonPackage rec {
    ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pydron/ifaddr";
     description = "Enumerates all IP addresses on all network adapters of the system";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ifconfig-parser/default.nix b/pkgs/development/python-modules/ifconfig-parser/default.nix
index cb3fb0fded5df..bdfd3767f8c45 100644
--- a/pkgs/development/python-modules/ifconfig-parser/default.nix
+++ b/pkgs/development/python-modules/ifconfig-parser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub }:
 
 buildPythonPackage rec {
   pname = "ifconfig-parser";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     python -m unittest -v test_ifconfig_parser.TestIfconfigParser
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unsophisticated python package for parsing raw output of ifconfig.";
     homepage = "https://github.com/KnightWhoSayNi/ifconfig-parser";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ifcopenshell/default.nix b/pkgs/development/python-modules/ifcopenshell/default.nix
index 16ee8dcbace89..75d1c4d774051 100644
--- a/pkgs/development/python-modules/ifcopenshell/default.nix
+++ b/pkgs/development/python-modules/ifcopenshell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , substituteAll
@@ -58,7 +58,7 @@ buildPythonPackage rec {
     "-DLIBXML2_LIBRARIES=${libxml2.out}/lib/${if stdenv.isDarwin then "libxml2.dylib" else "libxml2.so"}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source IFC library and geometry engine";
     homepage    = http://ifcopenshell.org/;
     license     = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/ijson/default.nix b/pkgs/development/python-modules/ijson/default.nix
index 8dc22d20e69a8..a82a20ca7c8af 100644
--- a/pkgs/development/python-modules/ijson/default.nix
+++ b/pkgs/development/python-modules/ijson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "ijson";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false; # something about yajl
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Iterative JSON parser with a standard Python iterator interface";
     homepage = "https://github.com/ICRAR/ijson";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/image-match/default.nix b/pkgs/development/python-modules/image-match/default.nix
index 6bb45f83790fa..5c1953d6ac3f4 100644
--- a/pkgs/development/python-modules/image-match/default.nix
+++ b/pkgs/development/python-modules/image-match/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pytestrunner, scikitimage }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pytestrunner, scikitimage }:
 
 buildPythonPackage {
   pname = "image-match";
@@ -25,7 +25,7 @@ buildPythonPackage {
   # tests cannot work without elasticsearch
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ascribe/image-match";
     description = "Quickly search over billions of images";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/imagecorruptions/default.nix b/pkgs/development/python-modules/imagecorruptions/default.nix
index 843537453c535..65c1cfd020a80 100644
--- a/pkgs/development/python-modules/imagecorruptions/default.nix
+++ b/pkgs/development/python-modules/imagecorruptions/default.nix
@@ -2,7 +2,7 @@
 , fetchPypi
 , numpy
 , scikitimage
-, stdenv
+, lib, stdenv
 , opencv3
 }:
 
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     opencv3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bethgelab/imagecorruptions";
     description = "This package provides a set of image corruptions";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/imageio/default.nix b/pkgs/development/python-modules/imageio/default.nix
index ce24dfb5896a2..e63678a524abe 100644
--- a/pkgs/development/python-modules/imageio/default.nix
+++ b/pkgs/development/python-modules/imageio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy27
 , pathlib
@@ -46,7 +46,7 @@ buildPythonPackage rec {
     substituteInPlace tests/test_ffmpeg.py --replace 'test_get_exe_installed' 'get_exe_installed'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for reading and writing a wide range of image, video, scientific, and volumetric data formats";
     homepage = "http://imageio.github.io/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/imagesize/default.nix b/pkgs/development/python-modules/imagesize/default.nix
index ab3ee46c1b83c..cd48f54ee8f45 100644
--- a/pkgs/development/python-modules/imagesize/default.nix
+++ b/pkgs/development/python-modules/imagesize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "b1f6b5a4eab1f73479a50fb79fcf729514a900c341d8503d62a62dbc4127a2b1";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Getting image size from png/jpeg/jpeg2000/gif file";
     homepage = "https://github.com/shibukawa/imagesize_py";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/imapclient/default.nix b/pkgs/development/python-modules/imapclient/default.nix
index ea9bc4844fad6..c091f53b8d4f4 100644
--- a/pkgs/development/python-modules/imapclient/default.nix
+++ b/pkgs/development/python-modules/imapclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , mock
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   checkInputs = [ mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://imapclient.readthedocs.io";
     description = "Easy-to-use, Pythonic and complete IMAP client library";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/imbalanced-learn/0.4.nix b/pkgs/development/python-modules/imbalanced-learn/0.4.nix
index 1ec139d5b3ad3..fe21096d635d6 100644
--- a/pkgs/development/python-modules/imbalanced-learn/0.4.nix
+++ b/pkgs/development/python-modules/imbalanced-learn/0.4.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, scikitlearn, pandas, nose, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, scikitlearn, pandas, nose, pytest }:
 
 buildPythonPackage rec {
   pname = "imbalanced-learn";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
                          and not wrong_memory'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library offering a number of re-sampling techniques commonly used in datasets showing strong between-class imbalance";
     homepage = "https://github.com/scikit-learn-contrib/imbalanced-learn";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/imbalanced-learn/default.nix b/pkgs/development/python-modules/imbalanced-learn/default.nix
index 21018518ca289..4253ed30e415c 100644
--- a/pkgs/development/python-modules/imbalanced-learn/default.nix
+++ b/pkgs/development/python-modules/imbalanced-learn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27
 , pandas
 , pytestCheckHook
 , scikitlearn
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     "test_make_imbalanced_iris"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library offering a number of re-sampling techniques commonly used in datasets showing strong between-class imbalance";
     homepage = "https://github.com/scikit-learn-contrib/imbalanced-learn";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/imgaug/default.nix b/pkgs/development/python-modules/imgaug/default.nix
index 82f10c1bb74c6..9ca8531dbbced 100644
--- a/pkgs/development/python-modules/imgaug/default.nix
+++ b/pkgs/development/python-modules/imgaug/default.nix
@@ -9,7 +9,7 @@
 , scipy
 , shapely
 , six
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -49,7 +49,7 @@ buildPythonPackage rec {
 
   checkInputs = [ opencv3 pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/aleju/imgaug";
     description = "Image augmentation for machine learning experiments";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/imgsize/default.nix b/pkgs/development/python-modules/imgsize/default.nix
index d4f066b8b0b24..d1a69c043d0fb 100644
--- a/pkgs/development/python-modules/imgsize/default.nix
+++ b/pkgs/development/python-modules/imgsize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "0k24qj4i996fz7lpjrs36il6lp51rh13b0j2wip87cy5v9109m2d";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python image size library";
     homepage = "https://github.com/ojii/imgsize";
     license = with licenses; [ bsd3 ];
diff --git a/pkgs/development/python-modules/importmagic/default.nix b/pkgs/development/python-modules/importmagic/default.nix
index 5217474ac2325..3a6a3c9ef8d73 100644
--- a/pkgs/development/python-modules/importmagic/default.nix
+++ b/pkgs/development/python-modules/importmagic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = false;  # missing json file from tarball
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Import Magic - automagically add, remove and manage imports";
     homepage = "https://github.com/alecthomas/importmagic";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/imread/default.nix b/pkgs/development/python-modules/imread/default.nix
index 1e4ccde4b3106..0caff88496786 100644
--- a/pkgs/development/python-modules/imread/default.nix
+++ b/pkgs/development/python-modules/imread/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   buildInputs = [ nose libjpeg libpng libtiff libwebp ];
   propagatedBuildInputs = [ numpy ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python package to load images as numpy arrays";
     homepage = "https://imread.readthedocs.io/en/latest/";
     maintainers = with maintainers; [ luispedro ];
diff --git a/pkgs/development/python-modules/imutils/default.nix b/pkgs/development/python-modules/imutils/default.nix
index 9a0797f095f64..33c2ae0001c27 100644
--- a/pkgs/development/python-modules/imutils/default.nix
+++ b/pkgs/development/python-modules/imutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , opencv3
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jrosebr1/imutils";
     description = "A series of convenience functions to make basic image processing functions";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/influxdb/default.nix b/pkgs/development/python-modules/influxdb/default.nix
index 650235b294019..2d0fd5a93adb1 100644
--- a/pkgs/development/python-modules/influxdb/default.nix
+++ b/pkgs/development/python-modules/influxdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -29,7 +29,7 @@ buildPythonPackage rec {
   doCheck = false;
   propagatedBuildInputs = [ requests dateutil pytz six msgpack ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client for InfluxDB";
     homepage = "https://github.com/influxdb/influxdb-python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/influxgraph/default.nix b/pkgs/development/python-modules/influxgraph/default.nix
index c4597650fe718..982b3fb8db5bf 100644
--- a/pkgs/development/python-modules/influxgraph/default.nix
+++ b/pkgs/development/python-modules/influxgraph/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , influxdb, graphite_api, memcached
 }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   passthru.moduleName = "influxgraph.InfluxDBFinder";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "InfluxDB storage plugin for Graphite-API";
     homepage = "https://github.com/InfluxGraph/influxgraph";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/infoqscraper/default.nix b/pkgs/development/python-modules/infoqscraper/default.nix
index 4a15430834327..4baa891a77906 100644
--- a/pkgs/development/python-modules/infoqscraper/default.nix
+++ b/pkgs/development/python-modules/infoqscraper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , html5lib
 , six
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   buildInputs = [ html5lib ];
   propagatedBuildInputs = [ six beautifulsoup4 pkgs.ffmpeg_3 pkgs.swftools pkgs.rtmpdump ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Discover presentations and/or create a movie consisting of slides and audio track from an infoq url";
     homepage = "https://github.com/cykl/infoqscraper/wiki";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/inifile/default.nix b/pkgs/development/python-modules/inifile/default.nix
index e64ef76356d17..9bd24a4d78894 100644
--- a/pkgs/development/python-modules/inifile/default.nix
+++ b/pkgs/development/python-modules/inifile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0zgd53czc1irwx6b5zip8xlmyfr40hz2pd498d8yv61znj6lm16h";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small INI library for Python";
     homepage    = "https://github.com/mitsuhiko/python-inifile";
     license     = licenses.bsd0;
diff --git a/pkgs/development/python-modules/iniparse/default.nix b/pkgs/development/python-modules/iniparse/default.nix
index e240b0863c233..c515b7865b155 100644
--- a/pkgs/development/python-modules/iniparse/default.nix
+++ b/pkgs/development/python-modules/iniparse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # Does not install tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Accessing and Modifying INI files";
     homepage = "https://github.com/candlepin/python-iniparse";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/inquirer/default.nix b/pkgs/development/python-modules/inquirer/default.nix
index c17c3eb4af882..c434a3f52bceb 100644
--- a/pkgs/development/python-modules/inquirer/default.nix
+++ b/pkgs/development/python-modules/inquirer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python-editor, readchar, blessed, pytest, pytestcov, pexpect, pytest-mock }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python-editor, readchar, blessed, pytest, pytestcov, pexpect, pytest-mock }:
 
 buildPythonPackage rec {
   pname = "inquirer";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     pytest --cov-report=term-missing  --cov inquirer --no-cov-on-fail tests/unit tests/integration
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/magmax/python-inquirer";
     description = "A collection of common interactive command line user interfaces, based on Inquirer.js";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/interruptingcow/default.nix b/pkgs/development/python-modules/interruptingcow/default.nix
index 279fb1c9685b9..b4e1dfaff1812 100644
--- a/pkgs/development/python-modules/interruptingcow/default.nix
+++ b/pkgs/development/python-modules/interruptingcow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 buildPythonPackage rec {
   pname = "interruptingcow";
   version = "0.8";
@@ -8,7 +8,7 @@ buildPythonPackage rec {
     sha256 = "3e8cd5058b651e625702cba53e3b1fb76d7a5ec07ab69c52a167a9f784e3306c";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A watchdog that interrupts long running code";
     homepage = "https://bitbucket.org/evzijst/interruptingcow";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/intervaltree/default.nix b/pkgs/development/python-modules/intervaltree/default.nix
index 8b0bbf2dd3957..27a5fa3650e8b 100644
--- a/pkgs/development/python-modules/intervaltree/default.nix
+++ b/pkgs/development/python-modules/intervaltree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , python, pytest, sortedcontainers }:
 
 buildPythonPackage rec {
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Editable interval tree data structure for Python 2 and 3";
     homepage =  "https://github.com/chaimleib/intervaltree";
     license = [ licenses.asl20 ];
diff --git a/pkgs/development/python-modules/ipaddr/default.nix b/pkgs/development/python-modules/ipaddr/default.nix
index e76aa6ee2a577..427681fedb86c 100644
--- a/pkgs/development/python-modules/ipaddr/default.nix
+++ b/pkgs/development/python-modules/ipaddr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "1ml8r8z3f0mnn381qs1snbffa920i9ycp6mm2am1d3aqczkdz4j0";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google's IP address manipulation library";
     homepage = "https://github.com/google/ipaddr-py";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ipaddress/default.nix b/pkgs/development/python-modules/ipaddress/default.nix
index 0074ad2420d87..f2e479aff96ec 100644
--- a/pkgs/development/python-modules/ipaddress/default.nix
+++ b/pkgs/development/python-modules/ipaddress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonAtLeast
@@ -18,7 +18,7 @@ if (pythonAtLeast "3.3") then null else buildPythonPackage rec {
     ${python.interpreter} test_ipaddress.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Port of the 3.3+ ipaddress module to 2.6, 2.7, and 3.2";
     homepage = "https://github.com/phihag/ipaddress";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/ipdb/default.nix b/pkgs/development/python-modules/ipdb/default.nix
index df2ae6b466167..b21907f75ff50 100644
--- a/pkgs/development/python-modules/ipdb/default.nix
+++ b/pkgs/development/python-modules/ipdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , ipython
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     export HOME=$(mktemp -d)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gotcha/ipdb";
     description = "IPython-enabled pdb";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/ipdbplugin/default.nix b/pkgs/development/python-modules/ipdbplugin/default.nix
index 7c9ee263b2b46..057d82cbebc3c 100644
--- a/pkgs/development/python-modules/ipdbplugin/default.nix
+++ b/pkgs/development/python-modules/ipdbplugin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ nose ipython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/flavioamieiro/nose-ipdb/tree/master";
     description = "Nose plugin to use iPdb instead of Pdb when tests fail";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/ipfsapi/default.nix b/pkgs/development/python-modules/ipfsapi/default.nix
index 1778e5a81af67..3deb0c6cb80cf 100644
--- a/pkgs/development/python-modules/ipfsapi/default.nix
+++ b/pkgs/development/python-modules/ipfsapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -20,7 +20,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ six requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python client library for the IPFS API";
     license = licenses.mit;
     maintainers = with maintainers; [ mguentner ];
diff --git a/pkgs/development/python-modules/iptools/default.nix b/pkgs/development/python-modules/iptools/default.nix
index 9498ee2762a3a..431c05bb38810 100644
--- a/pkgs/development/python-modules/iptools/default.nix
+++ b/pkgs/development/python-modules/iptools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for manipulating IP addresses including a class that can be used to include CIDR network blocks in Django's INTERNAL_IPS setting";
     homepage = "https://pypi.python.org/pypi/iptools";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/iso3166/default.nix b/pkgs/development/python-modules/iso3166/default.nix
index f6a4a00283c5c..acf6d3c9331dc 100644
--- a/pkgs/development/python-modules/iso3166/default.nix
+++ b/pkgs/development/python-modules/iso3166/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, pytest }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, pytest }:
 
 buildPythonPackage {
   pname = "iso3166";
@@ -18,7 +18,7 @@ buildPythonPackage {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/deactivated/python-iso3166";
     description = "Self-contained ISO 3166-1 country definitions";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/isodate/default.nix b/pkgs/development/python-modules/isodate/default.nix
index d46fb7ed74ca0..d2098a83c95e1 100644
--- a/pkgs/development/python-modules/isodate/default.nix
+++ b/pkgs/development/python-modules/isodate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover -s src/isodate/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ISO 8601 date/time parser";
     homepage = "http://cheeseshop.python.org/pypi/isodate";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/itsdangerous/default.nix b/pkgs/development/python-modules/itsdangerous/default.nix
index 4761a98dc3016..e89786d4e18d4 100644
--- a/pkgs/development/python-modules/itsdangerous/default.nix
+++ b/pkgs/development/python-modules/itsdangerous/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "321b033d07f2a4136d3ec762eac9f16a10ccd60f53c0c91af90217ace7ba1f19";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Helpers to pass trusted data to untrusted environments and back";
     homepage = "https://pypi.python.org/pypi/itsdangerous/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/itypes/default.nix b/pkgs/development/python-modules/itypes/default.nix
index 17ba3a2183a35..417d1a20b3bfd 100644
--- a/pkgs/development/python-modules/itypes/default.nix
+++ b/pkgs/development/python-modules/itypes/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   fetchFromGitHub,
   buildPythonPackage,
   pytest,
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     pytest tests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple immutable types for python";
     homepage = "https://github.com/tomchristie/itypes";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/j2cli/default.nix b/pkgs/development/python-modules/j2cli/default.nix
index b2b80e2766c7b..14cf18ae694fd 100644
--- a/pkgs/development/python-modules/j2cli/default.nix
+++ b/pkgs/development/python-modules/j2cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , jinja2
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   doCheck = false; # tests aren't installed thus aren't found, so skip
   propagatedBuildInputs = [ jinja2 pyyaml setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kolypto/j2cli";
     description = "Jinja2 Command-Line Tool";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/jabberbot/default.nix b/pkgs/development/python-modules/jabberbot/default.nix
index 4e550bcca20c2..4c625d944859f 100644
--- a/pkgs/development/python-modules/jabberbot/default.nix
+++ b/pkgs/development/python-modules/jabberbot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi, xmpppy }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi, xmpppy }:
 
 buildPythonPackage rec {
   pname = "jabberbot";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false; # lol, it does not even specify dependencies properly
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A framework for writing Jabber/XMPP bots and services";
     homepage = "http://thp.io/2007/python-jabberbot/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/jc/default.nix b/pkgs/development/python-modules/jc/default.nix
index 0bccd38f152bf..6f120fa6ea2e4 100644
--- a/pkgs/development/python-modules/jc/default.nix
+++ b/pkgs/development/python-modules/jc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , ruamel_yaml
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This tool serializes the output of popular command line tools and filetypes to structured JSON output";
     homepage = "https://github.com/kellyjonbrazil/jc";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/jdatetime/default.nix b/pkgs/development/python-modules/jdatetime/default.nix
index d51d54287e76e..d4aa49c3ca3cb 100644
--- a/pkgs/development/python-modules/jdatetime/default.nix
+++ b/pkgs/development/python-modules/jdatetime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six }:
 
 buildPythonPackage rec {
   pname = "jdatetime";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jalali datetime binding for python";
     homepage = "https://pypi.python.org/pypi/jdatetime";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/jedi/default.nix b/pkgs/development/python-modules/jedi/default.nix
index ab8f72ea9f188..6e833a7746048 100644
--- a/pkgs/development/python-modules/jedi/default.nix
+++ b/pkgs/development/python-modules/jedi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, fetchPypi, pytest, glibcLocales, tox, pytestcov, parso }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, fetchPypi, pytest, glibcLocales, tox, pytestcov, parso }:
 
 buildPythonPackage rec {
   pname = "jedi";
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # tox required for tests: https://github.com/davidhalter/jedi/issues/808
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/davidhalter/jedi";
     description = "An autocompletion tool for Python that can be used for text editors";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/jenkinsapi/default.nix b/pkgs/development/python-modules/jenkinsapi/default.nix
index 40bf7752a90b7..912c21cc8fb42 100644
--- a/pkgs/development/python-modules/jenkinsapi/default.nix
+++ b/pkgs/development/python-modules/jenkinsapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -30,7 +30,7 @@ buildPythonPackage rec {
       -k "not systests and not test_plugins and not test_view"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python API for accessing resources on a Jenkins continuous-integration server";
     homepage = "https://github.com/salimfadhley/jenkinsapi";
     maintainers = with maintainers; [ drets ];
diff --git a/pkgs/development/python-modules/jinja2/default.nix b/pkgs/development/python-modules/jinja2/default.nix
index 33d6003cae745..5dc3cbe105e54 100644
--- a/pkgs/development/python-modules/jinja2/default.nix
+++ b/pkgs/development/python-modules/jinja2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     pytest -v tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://jinja.pocoo.org/";
     description = "Stand-alone template engine";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/jinja2_pluralize/default.nix b/pkgs/development/python-modules/jinja2_pluralize/default.nix
index 4a62fa4c25b7a..0a6d0c365a04e 100644
--- a/pkgs/development/python-modules/jinja2_pluralize/default.nix
+++ b/pkgs/development/python-modules/jinja2_pluralize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, jinja2, inflect }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, jinja2, inflect }:
 
 buildPythonPackage rec {
   pname = "jinja2_pluralize";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     inflect
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jinja2 pluralize filters";
     homepage = "https://github.com/audreyr/jinja2_pluralize";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/jinja2_time/default.nix b/pkgs/development/python-modules/jinja2_time/default.nix
index d84c16f1abae1..7887fe96f75e5 100644
--- a/pkgs/development/python-modules/jinja2_time/default.nix
+++ b/pkgs/development/python-modules/jinja2_time/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , arrow
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ arrow jinja2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hackebrot/jinja2-time";
     description = "Jinja2 Extension for Dates and Times";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/jmespath/default.nix b/pkgs/development/python-modules/jmespath/default.nix
index 993955f2a032e..3b31700de0ebe 100644
--- a/pkgs/development/python-modules/jmespath/default.nix
+++ b/pkgs/development/python-modules/jmespath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , ply
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   buildInputs = [ nose ];
   propagatedBuildInputs = [ ply ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/boto/jmespath";
     description = "JMESPath allows you to declaratively specify how to extract elements from a JSON document";
     license = "BSD";
diff --git a/pkgs/development/python-modules/jpylyzer/default.nix b/pkgs/development/python-modules/jpylyzer/default.nix
index 0d6398a768a1f..c5c9cdf15056d 100644
--- a/pkgs/development/python-modules/jpylyzer/default.nix
+++ b/pkgs/development/python-modules/jpylyzer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , six
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # runner seems to be upset by the project layout
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "JP2 (JPEG 2000 Part 1) image validator and properties extractor";
     homepage = "https://jpylyzer.openpreservation.org/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/jsonfield/default.nix b/pkgs/development/python-modules/jsonfield/default.nix
index e9887b473793a..07ee609d65344 100644
--- a/pkgs/development/python-modules/jsonfield/default.nix
+++ b/pkgs/development/python-modules/jsonfield/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, django, pytestCheckHook, pytest-django }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, django, pytestCheckHook, pytest-django }:
 
 buildPythonPackage rec {
   pname = "jsonfield";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ django ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reusable model field that allows you to store validated JSON, automatically handling serialization to and from the database";
     homepage = "https://github.com/rpkilby/jsonfield/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/jsonpath_rw/default.nix b/pkgs/development/python-modules/jsonpath_rw/default.nix
index 4b842a02af83b..81a6eb3fb27b9 100644
--- a/pkgs/development/python-modules/jsonpath_rw/default.nix
+++ b/pkgs/development/python-modules/jsonpath_rw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # ImportError: No module named tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kennknowles/python-jsonpath-rw";
     description = "A robust and significantly extended implementation of JSONPath for Python, with a clear AST for metaprogramming";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/jsonpointer/default.nix b/pkgs/development/python-modules/jsonpointer/default.nix
index 6971393b80c92..e2f22ec863873 100644
--- a/pkgs/development/python-modules/jsonpointer/default.nix
+++ b/pkgs/development/python-modules/jsonpointer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0qjkjy1qlyc1nl3k95wd03ssxac0a717x8889ypgs1cfcj3bm4n1";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Resolve JSON Pointers in Python";
     homepage = "https://github.com/stefankoegl/python-json-pointer";
     license = stdenv.lib.licenses.bsd2; # "Modified BSD license, says pypi"
diff --git a/pkgs/development/python-modules/jsonref/default.nix b/pkgs/development/python-modules/jsonref/default.nix
index c174a011b5fa5..b901d811a2301 100644
--- a/pkgs/development/python-modules/jsonref/default.nix
+++ b/pkgs/development/python-modules/jsonref/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, mock }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     py.test tests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of JSON Reference for Python";
     homepage    = "https://github.com/gazpachoking/jsonref";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/jsonrpc-async/default.nix b/pkgs/development/python-modules/jsonrpc-async/default.nix
index c410b9407ea6e..0b77db5df4e6e 100644
--- a/pkgs/development/python-modules/jsonrpc-async/default.nix
+++ b/pkgs/development/python-modules/jsonrpc-async/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , aiohttp, jsonrpc-base }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ aiohttp jsonrpc-base ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A JSON-RPC client library for asyncio";
     homepage = "https://github.com/armills/jsonrpc-async";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/jsonrpc-base/default.nix b/pkgs/development/python-modules/jsonrpc-base/default.nix
index 9318fc09373cd..cc4bd1b2f6861 100644
--- a/pkgs/development/python-modules/jsonrpc-base/default.nix
+++ b/pkgs/development/python-modules/jsonrpc-base/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "jsonrpc-base";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A JSON-RPC client library base interface";
     homepage = "https://github.com/armills/jsonrpc-base";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/jsonrpc-websocket/default.nix b/pkgs/development/python-modules/jsonrpc-websocket/default.nix
index 4fe136f69b7b1..d14d382f013cb 100644
--- a/pkgs/development/python-modules/jsonrpc-websocket/default.nix
+++ b/pkgs/development/python-modules/jsonrpc-websocket/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , aiohttp, jsonrpc-base, pep8
 , pytestCheckHook
 , pytest-asyncio
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   checkInputs = [ pytestCheckHook pytest-asyncio ];
   pytestFlagsArray = [ "tests.py" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A JSON-RPC websocket client library for asyncio";
     homepage = "https://github.com/armills/jsonrpc-websocket";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/jsonwatch/default.nix b/pkgs/development/python-modules/jsonwatch/default.nix
index 1b859e21e9042..feced94422575 100644
--- a/pkgs/development/python-modules/jsonwatch/default.nix
+++ b/pkgs/development/python-modules/jsonwatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , six
@@ -17,7 +17,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Like watch -d but for JSON";
     longDescription = ''
       jsonwatch is a command line utility with which you can track
diff --git a/pkgs/development/python-modules/jug/default.nix b/pkgs/development/python-modules/jug/default.nix
index edfc7573d4e4b..eff6accaa0248 100644
--- a/pkgs/development/python-modules/jug/default.nix
+++ b/pkgs/development/python-modules/jug/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch
 , nose, numpy
 , bottle, pyyaml, redis, six
 , zlib
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   checkInputs = [ pytestCheckHook ];
   pythonImportsCheck = [ "jug" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Task-Based Parallelization Framework";
     license = licenses.mit;
     homepage = "https://jug.readthedocs.io/";
diff --git a/pkgs/development/python-modules/junos-eznc/default.nix b/pkgs/development/python-modules/junos-eznc/default.nix
index d47130c5f3fb9..d9234d836b0f2 100644
--- a/pkgs/development/python-modules/junos-eznc/default.nix
+++ b/pkgs/development/python-modules/junos-eznc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -35,7 +35,7 @@ buildPythonPackage rec {
     nosetests -v --with-coverage --cover-package=jnpr.junos --cover-inclusive -a unit
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.github.com/Juniper/py-junos-eznc";
     description = "Junos 'EZ' automation for non-programmers";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/jupyter-repo2docker/default.nix b/pkgs/development/python-modules/jupyter-repo2docker/default.nix
index 4dc878e26701d..f01605513cb6f 100644
--- a/pkgs/development/python-modules/jupyter-repo2docker/default.nix
+++ b/pkgs/development/python-modules/jupyter-repo2docker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonAtLeast
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonAtLeast
 , docker
 , escapism
 , jinja2
@@ -43,7 +43,7 @@ buildPythonPackage rec {
     "repo2docker.contentproviders.base"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://repo2docker.readthedocs.io/en/latest/";
     description = "Repo2docker: Turn code repositories into Jupyter enabled Docker Images";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/jupyter-telemetry/default.nix b/pkgs/development/python-modules/jupyter-telemetry/default.nix
index 4b3093cf6ce16..0f0c0d346e6a2 100644
--- a/pkgs/development/python-modules/jupyter-telemetry/default.nix
+++ b/pkgs/development/python-modules/jupyter-telemetry/default.nix
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     python-json-logger jsonschema ruamel_yaml traitlets
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Telemetry for Jupyter Applications and extensions";
     homepage = "https://jupyter-telemetry.readthedocs.io/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/jupyter/default.nix b/pkgs/development/python-modules/jupyter/default.nix
index b6d2a5e5a9013..03d28bbf55d6b 100644
--- a/pkgs/development/python-modules/jupyter/default.nix
+++ b/pkgs/development/python-modules/jupyter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , notebook
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # Meta-package, no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Installs all the Jupyter components in one go";
     homepage = "https://jupyter.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/jupyterlab-git/default.nix b/pkgs/development/python-modules/jupyterlab-git/default.nix
index 1c6c9a5b9e3c7..3219bd5730bb0 100644
--- a/pkgs/development/python-modules/jupyterlab-git/default.nix
+++ b/pkgs/development/python-modules/jupyterlab-git/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -31,7 +31,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "jupyterlab_git" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jupyter lab extension for version control with Git.";
     license = with licenses; [ bsd3 ];
     homepage = "https://github.com/jupyterlab/jupyterlab-git";
diff --git a/pkgs/development/python-modules/jupyterlab_server/default.nix b/pkgs/development/python-modules/jupyterlab_server/default.nix
index 0344a66cf6634..bfbd1cc89e089 100644
--- a/pkgs/development/python-modules/jupyterlab_server/default.nix
+++ b/pkgs/development/python-modules/jupyterlab_server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , notebook
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "JupyterLab Server";
     homepage = "https://jupyter.org";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/kaa-base/default.nix b/pkgs/development/python-modules/kaa-base/default.nix
index a0b8cd97ced6c..24a02f7f696a8 100644
--- a/pkgs/development/python-modules/kaa-base/default.nix
+++ b/pkgs/development/python-modules/kaa-base/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -41,7 +41,7 @@ buildPythonPackage rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generic application framework, providing the foundation for other modules";
     homepage = "https://github.com/freevo/kaa-base";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/kaa-metadata/default.nix b/pkgs/development/python-modules/kaa-metadata/default.nix
index 31f87965a0382..5164004e8ea58 100644
--- a/pkgs/development/python-modules/kaa-metadata/default.nix
+++ b/pkgs/development/python-modules/kaa-metadata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , kaa-base
@@ -46,7 +46,7 @@ buildPythonPackage rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for parsing media metadata, which can extract metadata (e.g., such as id3 tags) from a wide range of media files";
     homepage = "https://github.com/freevo/kaa-metadata";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/kafka-python/default.nix b/pkgs/development/python-modules/kafka-python/default.nix
index 8069632c17056..b147b30c2ce39 100644
--- a/pkgs/development/python-modules/kafka-python/default.nix
+++ b/pkgs/development/python-modules/kafka-python/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, six, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, six, mock }:
 
 buildPythonPackage rec {
   version = "2.0.2";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # E   ImportError: cannot import name 'unittest'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python client for Apache Kafka";
     homepage = "https://github.com/dpkp/kafka-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/kaitaistruct/default.nix b/pkgs/development/python-modules/kaitaistruct/default.nix
index 61892063278bc..866042b6942ce 100644
--- a/pkgs/development/python-modules/kaitaistruct/default.nix
+++ b/pkgs/development/python-modules/kaitaistruct/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "kaitaistruct";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "3d5845817ec8a4d5504379cc11bd570b038850ee49c4580bc0998c8fb1d327ad";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kaitai Struct: runtime library for Python";
     homepage = "https://github.com/kaitai-io/kaitai_struct_python_runtime";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/kajiki/default.nix b/pkgs/development/python-modules/kajiki/default.nix
index 8643e562fa07f..2a45404919c0a 100644
--- a/pkgs/development/python-modules/kajiki/default.nix
+++ b/pkgs/development/python-modules/kajiki/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , Babel
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ Babel pytz nine ];
   checkInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kajiki provides fast well-formed XML templates";
     homepage = "https://github.com/nandoflorestan/kajiki";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/kaptan/default.nix b/pkgs/development/python-modules/kaptan/default.nix
index 78a33a8e3022c..dea22059f096f 100644
--- a/pkgs/development/python-modules/kaptan/default.nix
+++ b/pkgs/development/python-modules/kaptan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyyaml
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configuration manager for python applications";
     homepage = "https://kaptan.readthedocs.io/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/kazoo/default.nix b/pkgs/development/python-modules/kazoo/default.nix
index 3c040abc7247d..d8743776578e4 100644
--- a/pkgs/development/python-modules/kazoo/default.nix
+++ b/pkgs/development/python-modules/kazoo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   doCheck = false;
   #ZOOKEEPER_PATH = "${pkgs.zookeeper}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kazoo.readthedocs.org";
     description = "Higher Level Zookeeper Client";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/keep/default.nix b/pkgs/development/python-modules/keep/default.nix
index 4e7003aef9f93..52fc90a3ca907 100644
--- a/pkgs/development/python-modules/keep/default.nix
+++ b/pkgs/development/python-modules/keep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , PyGithub
@@ -26,7 +26,7 @@ buildPythonPackage rec {
   # no tests
   pythonImportsCheck = [ "keep" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/orkohunter/keep";
     description = "A Meta CLI toolkit: Personal shell command keeper and snippets manager";
     platforms = platforms.all;
diff --git a/pkgs/development/python-modules/keepalive/default.nix b/pkgs/development/python-modules/keepalive/default.nix
index c53bc25d198d1..7a488edf895d5 100644
--- a/pkgs/development/python-modules/keepalive/default.nix
+++ b/pkgs/development/python-modules/keepalive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An HTTP handler for `urllib2` that supports HTTP 1.1 and keepalive";
     homepage = "https://github.com/wikier/keepalive";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/keepkey/default.nix b/pkgs/development/python-modules/keepkey/default.nix
index 82391d3775030..437a0193c61d0 100644
--- a/pkgs/development/python-modules/keepkey/default.nix
+++ b/pkgs/development/python-modules/keepkey/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, pytest
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, pytest
 , ecdsa , mnemonic, protobuf, hidapi, trezor }:
 
 buildPythonPackage rec {
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # Remove impossible dependency constraint
   postPatch = "sed -i -e 's|hidapi==|hidapi>=|' setup.py";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "KeepKey Python client";
     homepage = "https://github.com/keepkey/python-keepkey";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/keepkey_agent/default.nix b/pkgs/development/python-modules/keepkey_agent/default.nix
index 279cc50d174f4..b9189cf4e1679 100644
--- a/pkgs/development/python-modules/keepkey_agent/default.nix
+++ b/pkgs/development/python-modules/keepkey_agent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , keepkey
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsChecks = [ "keepkey_agent" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Using KeepKey as hardware-based SSH/PGP agent";
     homepage = "https://github.com/romanz/trezor-agent";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/keras/default.nix b/pkgs/development/python-modules/keras/default.nix
index f2243a1531f63..7274d3d17a691 100644
--- a/pkgs/development/python-modules/keras/default.nix
+++ b/pkgs/development/python-modules/keras/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, pytestcov, pytest_xdist
 , six, numpy, scipy, pyyaml, h5py
 , keras-applications, keras-preprocessing
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   # Couldn't get tests working
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Deep Learning library for Theano and TensorFlow";
     homepage = "https://keras.io";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/kerberos/default.nix b/pkgs/development/python-modules/kerberos/default.nix
index 7f5341a6a2537..df9babdc5829a 100644
--- a/pkgs/development/python-modules/kerberos/default.nix
+++ b/pkgs/development/python-modules/kerberos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , kerberos
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kerberos high-level interface";
     homepage = "https://pypi.python.org/pypi/kerberos";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/keyring/2.nix b/pkgs/development/python-modules/keyring/2.nix
index ce4aa145e8eec..1dc7eb0a8f98d 100644
--- a/pkgs/development/python-modules/keyring/2.nix
+++ b/pkgs/development/python-modules/keyring/2.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , dbus-python, setuptools_scm, entrypoints, secretstorage
 , pytest, pytest-flake8 }:
 
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Store and access your passwords safely";
     homepage    = "https://pypi.python.org/pypi/keyring";
     license     = licenses.psfl;
diff --git a/pkgs/development/python-modules/keyrings-alt/default.nix b/pkgs/development/python-modules/keyrings-alt/default.nix
index 506081659f65d..eb1f12e0aa397 100644
--- a/pkgs/development/python-modules/keyrings-alt/default.nix
+++ b/pkgs/development/python-modules/keyrings-alt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder, isPy27, six
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder, isPy27, six
 , pytest, backports_unittest-mock, keyring, setuptools_scm, toml
 }:
 
@@ -32,7 +32,7 @@ buildPythonPackage rec {
     "keyrings.alt"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     description = "Alternate keyring implementations";
     homepage = "https://github.com/jaraco/keyrings.alt";
diff --git a/pkgs/development/python-modules/kitchen/default.nix b/pkgs/development/python-modules/kitchen/default.nix
index 494a4f8fc0633..1a14b974114e5 100644
--- a/pkgs/development/python-modules/kitchen/default.nix
+++ b/pkgs/development/python-modules/kitchen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 buildPythonPackage rec {
   pname = "kitchen";
   version = "1.2.6";
@@ -8,7 +8,7 @@ buildPythonPackage rec {
     sha256 = "0g5hq2icnng9vy4www5hnr3r5srisfwp0wxw1sv5c5dxy61gak5q";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kitchen contains a cornucopia of useful code";
     license = licenses.lgpl2;
     maintainers = with maintainers; [ ];
diff --git a/pkgs/development/python-modules/korean-lunar-calendar/default.nix b/pkgs/development/python-modules/korean-lunar-calendar/default.nix
index 41569ac9dc9b5..8ad94d955aec5 100644
--- a/pkgs/development/python-modules/korean-lunar-calendar/default.nix
+++ b/pkgs/development/python-modules/korean-lunar-calendar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # no real tests
   pythonImportsCheck = [ "korean_lunar_calendar" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library to convert Korean lunar-calendar to Gregorian calendar.";
     homepage = "https://github.com/usingsky/korean_lunar_calendar_py";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/kubernetes/default.nix b/pkgs/development/python-modules/kubernetes/default.nix
index 0be1ae0353f81..1721807819687 100644
--- a/pkgs/development/python-modules/kubernetes/default.nix
+++ b/pkgs/development/python-modules/kubernetes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonAtLeast,
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonAtLeast,
   ipaddress, websocket_client, urllib3, pyyaml, requests_oauthlib, python-dateutil, google-auth, adal,
   isort, pytest, coverage, mock, sphinx, autopep8, pep8, codecov, recommonmark, nose }:
 
@@ -30,7 +30,7 @@ buildPythonPackage rec {
   checkInputs = [ isort coverage pytest mock sphinx autopep8 pep8 codecov recommonmark nose ];
   propagatedBuildInputs = [ ipaddress websocket_client urllib3 pyyaml requests_oauthlib python-dateutil google-auth adal ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kubernetes python client";
     homepage = "https://github.com/kubernetes-client/python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/larch/default.nix b/pkgs/development/python-modules/larch/default.nix
index 3be8b2404192c..7708bc0dbc029 100644
--- a/pkgs/development/python-modules/larch/default.nix
+++ b/pkgs/development/python-modules/larch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , sphinx
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://liw.fi/larch/";
     description = "Python B-tree library";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/lasagne/default.nix b/pkgs/development/python-modules/lasagne/default.nix
index febd38acc63f7..5bddf5cbe6f20 100644
--- a/pkgs/development/python-modules/lasagne/default.nix
+++ b/pkgs/development/python-modules/lasagne/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # there are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight library to build and train neural networks in Theano";
     homepage = "https://github.com/Lasagne/Lasagne";
     maintainers = with maintainers; [ NikolaMandic ];
diff --git a/pkgs/development/python-modules/lazy-object-proxy/default.nix b/pkgs/development/python-modules/lazy-object-proxy/default.nix
index dc2eecb002d48..63784b4005bb1 100644
--- a/pkgs/development/python-modules/lazy-object-proxy/default.nix
+++ b/pkgs/development/python-modules/lazy-object-proxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # Broken tests. Seem to be fixed upstream according to Travis.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast and thorough lazy object proxy";
     homepage = "https://github.com/ionelmc/python-lazy-object-proxy";
     license = with licenses; [ bsd2 ];
diff --git a/pkgs/development/python-modules/lazy_import/default.nix b/pkgs/development/python-modules/lazy_import/default.nix
index 743604d539ba7..1bc52b3a65c8f 100644
--- a/pkgs/development/python-modules/lazy_import/default.nix
+++ b/pkgs/development/python-modules/lazy_import/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest
 , pytest_xdist
 , six }:
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     pytest --boxed
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "lazy_import provides a set of functions that load modules, and related attributes, in a lazy fashion.";
     homepage = https://github.com/mnmelo/lazy_import;
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/ldap/default.nix b/pkgs/development/python-modules/ldap/default.nix
index 0e4f5597ce645..e5cd3d3828e1e 100644
--- a/pkgs/development/python-modules/ldap/default.nix
+++ b/pkgs/development/python-modules/ldap/default.nix
@@ -1,6 +1,6 @@
 { buildPythonPackage, fetchPypi
 , pyasn1, pyasn1-modules, pytest
-, openldap, cyrus_sasl, stdenv }:
+, openldap, cyrus_sasl, lib, stdenv }:
 
 buildPythonPackage rec {
   pname = "python-ldap";
@@ -29,7 +29,7 @@ buildPythonPackage rec {
 
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python modules for implementing LDAP clients";
     homepage = "https://www.python-ldap.org/";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/ldap3/default.nix b/pkgs/development/python-modules/ldap3/default.nix
index 178477dcc6b00..e1accc4d177e5 100644
--- a/pkgs/development/python-modules/ldap3/default.nix
+++ b/pkgs/development/python-modules/ldap3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pyasn1 }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pyasn1 }:
 
 buildPythonPackage rec {
   pname = "ldap3";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   doCheck = false; # requires network
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/ldap3";
     description = "A strictly RFC 4510 conforming LDAP V3 pure Python client library";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/le/default.nix b/pkgs/development/python-modules/le/default.nix
index 927b3f44bcf34..6415b255c7167 100644
--- a/pkgs/development/python-modules/le/default.nix
+++ b/pkgs/development/python-modules/le/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPy3k
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ simplejson psutil ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rapid7/le";
     description = "Logentries agent";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/leather/default.nix b/pkgs/development/python-modules/leather/default.nix
index 30a76747723aa..99c1f080a0315 100644
--- a/pkgs/development/python-modules/leather/default.nix
+++ b/pkgs/development/python-modules/leather/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, six }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, six }:
 
 buildPythonPackage rec {
   pname = "leather";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://leather.rtfd.io";
     description = "Python charting library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ledger_agent/default.nix b/pkgs/development/python-modules/ledger_agent/default.nix
index 2f3404fa921b7..4fc935799c317 100644
--- a/pkgs/development/python-modules/ledger_agent/default.nix
+++ b/pkgs/development/python-modules/ledger_agent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , ledgerblue
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Using Ledger as hardware-based SSH/PGP agent";
     homepage = "https://github.com/romanz/trezor-agent";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/ledgerblue/default.nix b/pkgs/development/python-modules/ledgerblue/default.nix
index c84d5fa471bd9..f853dfbf01f9b 100644
--- a/pkgs/development/python-modules/ledgerblue/default.nix
+++ b/pkgs/development/python-modules/ledgerblue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, hidapi
+{ lib, stdenv, fetchPypi, buildPythonPackage, hidapi
 , pycrypto, pillow, protobuf, future, ecpy, python-u2flib-host, pycryptodomex
 , websocket_client
 }:
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library to communicate with Ledger Blue/Nano S";
     homepage = "https://github.com/LedgerHQ/blue-loader-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ledgerwallet/default.nix b/pkgs/development/python-modules/ledgerwallet/default.nix
index e25e9d5d2a4f6..a95d8140e1152 100644
--- a/pkgs/development/python-modules/ledgerwallet/default.nix
+++ b/pkgs/development/python-modules/ledgerwallet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , cryptography
@@ -32,7 +32,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "ledgerwallet" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/LedgerHQ/ledgerctl";
     description = "A library to control Ledger devices";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/libagent/default.nix b/pkgs/development/python-modules/libagent/default.nix
index 4bc07e969330e..debe88f2f6cc5 100644
--- a/pkgs/development/python-modules/libagent/default.nix
+++ b/pkgs/development/python-modules/libagent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, ed25519, ecdsa , semver, mnemonic,
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, ed25519, ecdsa , semver, mnemonic,
   unidecode, mock, pytest , backports-shutil-which, ConfigArgParse,
   python-daemon, pymsgbox }:
 
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     py.test libagent/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Using hardware wallets as SSH/GPG agent";
     homepage = "https://github.com/romanz/trezor-agent";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/libais/default.nix b/pkgs/development/python-modules/libais/default.nix
index 3d7408e87126f..eb1ce861dd266 100644
--- a/pkgs/development/python-modules/libais/default.nix
+++ b/pkgs/development/python-modules/libais/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   six, pytest, pytestrunner, pytestcov, coverage
 }:
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest pytestrunner pytestcov coverage ];
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/schwehr/libais";
     description = "Library for decoding maritime Automatic Identification System messages";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/libarchive-c/default.nix b/pkgs/development/python-modules/libarchive-c/default.nix
index 6bcb7f80484c4..73d99afda6745 100644
--- a/pkgs/development/python-modules/libarchive-c/default.nix
+++ b/pkgs/development/python-modules/libarchive-c/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     py.test tests -k 'not test_check_archiveentry_with_unicode_entries_and_name_zip and not test_check_archiveentry_using_python_testtar'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Changaco/python-libarchive-c";
     description = "Python interface to libarchive";
     license = licenses.cc0;
diff --git a/pkgs/development/python-modules/libarcus/default.nix b/pkgs/development/python-modules/libarcus/default.nix
index e69e51ccf555f..5a5116de54783 100644
--- a/pkgs/development/python-modules/libarcus/default.nix
+++ b/pkgs/development/python-modules/libarcus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, python, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, python, fetchFromGitHub
 , cmake, sip, protobuf, pythonOlder }:
 
 buildPythonPackage rec {
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     sed -i 's#''${Python3_SITEARCH}#${placeholder "out"}/${python.sitePackages}#' cmake/SIPMacros.cmake
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Communication library between internal components for Ultimaker software";
     homepage = "https://github.com/Ultimaker/libArcus";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/libasyncns/default.nix b/pkgs/development/python-modules/libasyncns/default.nix
index fa7320bdf4ece..72147fb70f206 100644
--- a/pkgs/development/python-modules/libasyncns/default.nix
+++ b/pkgs/development/python-modules/libasyncns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchurl
+{ lib, stdenv, buildPythonPackage, fetchurl
 , libasyncns, pkgconfig }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   doCheck = false; # requires network access
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "libasyncns-python is a python binding for the asynchronous name service query library";
     license = licenses.lgpl21;
     maintainers = [ maintainers.mic92 ];
diff --git a/pkgs/development/python-modules/libevdev/default.nix b/pkgs/development/python-modules/libevdev/default.nix
index a17612c79cbc3..227cabe0099e3 100644
--- a/pkgs/development/python-modules/libevdev/default.nix
+++ b/pkgs/development/python-modules/libevdev/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy27
 , fetchPypi
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper around the libevdev C library";
     homepage = "https://gitlab.freedesktop.org/libevdev/python-libevdev";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/libgpuarray/default.nix b/pkgs/development/python-modules/libgpuarray/default.nix
index ab431168cee22..80e560e4cce66 100644
--- a/pkgs/development/python-modules/libgpuarray/default.nix
+++ b/pkgs/development/python-modules/libgpuarray/default.nix
@@ -70,7 +70,7 @@ buildPythonPackage rec {
     nose
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Theano/libgpuarray";
     description = "Library to manipulate tensors on GPU.";
     license = licenses.free;
diff --git a/pkgs/development/python-modules/libkeepass/default.nix b/pkgs/development/python-modules/libkeepass/default.nix
index 0969e62c79e82..cfc687e37c148 100644
--- a/pkgs/development/python-modules/libkeepass/default.nix
+++ b/pkgs/development/python-modules/libkeepass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , lxml, pycryptodome, colorama }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests on PyPI
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/libkeepass/libkeepass";
     description = "A library to access KeePass 1.x/KeePassX (v3) and KeePass 2.x (v4) files";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/liblarch/default.nix b/pkgs/development/python-modules/liblarch/default.nix
index 30b52be0b850b..b824dec172edf 100644
--- a/pkgs/development/python-modules/liblarch/default.nix
+++ b/pkgs/development/python-modules/liblarch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , python
@@ -37,7 +37,7 @@ buildPythonPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python library built to easily handle data structure such are lists, trees and acyclic graphs";
     homepage = "https://github.com/getting-things-gnome/liblarch";
     downloadPage = "https://github.com/getting-things-gnome/liblarch/releases";
diff --git a/pkgs/development/python-modules/libmr/default.nix b/pkgs/development/python-modules/libmr/default.nix
index 7b1bbf6020d24..a0ef924e56e6b 100644
--- a/pkgs/development/python-modules/libmr/default.nix
+++ b/pkgs/development/python-modules/libmr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, numpy, cython }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, numpy, cython }:
 
 buildPythonPackage rec {
   pname = "libmr";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests in the pypi tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "libMR provides core MetaRecognition and Weibull fitting functionality";
     homepage = "https://github.com/Vastlab/libMR";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/libnacl/default.nix b/pkgs/development/python-modules/libnacl/default.nix
index 9e19fe5e8e17d..2406738cf1bb7 100644
--- a/pkgs/development/python-modules/libnacl/default.nix
+++ b/pkgs/development/python-modules/libnacl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pytest, libsodium }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pytest, libsodium }:
 
 buildPythonPackage rec {
   pname = "libnacl";
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ xvapx ];
     description = "Python bindings for libsodium based on ctypes";
     homepage = "https://pypi.python.org/pypi/libnacl";
diff --git a/pkgs/development/python-modules/librosa/default.nix b/pkgs/development/python-modules/librosa/default.nix
index 0fc5d857fb84f..777eed4ddb330 100644
--- a/pkgs/development/python-modules/librosa/default.nix
+++ b/pkgs/development/python-modules/librosa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , joblib
@@ -31,7 +31,7 @@ buildPythonPackage rec {
   # check that import works, this allows to capture errors like https://github.com/librosa/librosa/issues/1160
   pythonImportsCheck = [ "librosa" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python module for audio and music processing";
     homepage = "http://librosa.github.io/";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/libsavitar/default.nix b/pkgs/development/python-modules/libsavitar/default.nix
index 9b6aa7bc3a8de..559289987e6c5 100644
--- a/pkgs/development/python-modules/libsavitar/default.nix
+++ b/pkgs/development/python-modules/libsavitar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, python, pythonOlder, fetchFromGitHub, cmake, sip }:
+{ lib, stdenv, buildPythonPackage, python, pythonOlder, fetchFromGitHub, cmake, sip }:
 
 buildPythonPackage rec {
   pname = "libsavitar";
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.4.0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C++ implementation of 3mf loading with SIP python bindings";
     homepage = "https://github.com/Ultimaker/libSavitar";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/libsoundtouch/default.nix b/pkgs/development/python-modules/libsoundtouch/default.nix
index 119cb6cbefa74..40f1b2f8e9ca3 100644
--- a/pkgs/development/python-modules/libsoundtouch/default.nix
+++ b/pkgs/development/python-modules/libsoundtouch/default.nix
@@ -26,7 +26,7 @@ buildPythonPackage {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bose Soundtouch Python library";
     homepage    = "https://github.com/CharlesBlonde/libsoundtouch";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/libthumbor/default.nix b/pkgs/development/python-modules/libthumbor/default.nix
index e8b7c45417a10..72e62514a5263 100644
--- a/pkgs/development/python-modules/libthumbor/default.nix
+++ b/pkgs/development/python-modules/libthumbor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "libthumbor is the python extension to thumbor";
     homepage = "https://github.com/heynemann/libthumbor";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/libtmux/default.nix b/pkgs/development/python-modules/libtmux/default.nix
index 9df5cffec97b4..df9728eb334b6 100644
--- a/pkgs/development/python-modules/libtmux/default.nix
+++ b/pkgs/development/python-modules/libtmux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pytest }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pytest }:
 
 buildPythonPackage rec {
   pname = "libtmux";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scripting library for tmux";
     homepage = "https://libtmux.readthedocs.io/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/libusb1/default.nix b/pkgs/development/python-modules/libusb1/default.nix
index 63a97652381ba..0446299fd1bdc 100644
--- a/pkgs/development/python-modules/libusb1/default.nix
+++ b/pkgs/development/python-modules/libusb1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, libusb1, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, libusb1, pytest }:
 
 buildPythonPackage rec {
   pname = "libusb1";
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     py.test -k 'not testUSBPollerThreadExit' usb1/testUSB1.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/vpelletier/python-libusb1";
     description = "Python ctype-based wrapper around libusb1";
     license     = licenses.lgpl2Plus;
diff --git a/pkgs/development/python-modules/libversion/default.nix b/pkgs/development/python-modules/libversion/default.nix
index ed3629ce65d54..dafaf412f07ac 100644
--- a/pkgs/development/python-modules/libversion/default.nix
+++ b/pkgs/development/python-modules/libversion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pkgconfig, libversion, pythonOlder }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pkgconfig, libversion, pythonOlder }:
 
 buildPythonPackage rec {
   pname = "libversion";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.6";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/repology/py-libversion";
     description = "Python bindings for libversion, which provides fast, powerful and correct generic version string comparison algorithm";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/libvirt/5.9.0.nix b/pkgs/development/python-modules/libvirt/5.9.0.nix
index 7b0b7c438d9a0..c751734e15337 100644
--- a/pkgs/development/python-modules/libvirt/5.9.0.nix
+++ b/pkgs/development/python-modules/libvirt/5.9.0.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchgit, pkgconfig, lxml, libvirt, nose }:
+{ lib, stdenv, buildPythonPackage, fetchgit, pkgconfig, lxml, libvirt, nose }:
 
 buildPythonPackage rec {
   pname = "libvirt";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.libvirt.org/";
     description = "libvirt Python bindings";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/libvirt/default.nix b/pkgs/development/python-modules/libvirt/default.nix
index 4c0e730f7d57f..e02b34e3816ae 100644
--- a/pkgs/development/python-modules/libvirt/default.nix
+++ b/pkgs/development/python-modules/libvirt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitLab, pkgconfig, lxml, libvirt, nose }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitLab, pkgconfig, lxml, libvirt, nose }:
 
 buildPythonPackage rec {
   pname = "libvirt";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://libvirt.org/python.html";
     description = "libvirt Python bindings";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/lightblue/default.nix b/pkgs/development/python-modules/lightblue/default.nix
index 99db9e5c2f73c..3e85a3cfaa049 100644
--- a/pkgs/development/python-modules/lightblue/default.nix
+++ b/pkgs/development/python-modules/lightblue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , pkgs
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pkgs.bluez pkgs.openobex ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://lightblue.sourceforge.net";
     description = "Cross-platform Bluetooth API for Python";
     maintainers = with maintainers; [ leenaars ];
diff --git a/pkgs/development/python-modules/lightgbm/default.nix b/pkgs/development/python-modules/lightgbm/default.nix
index eae2e4208d1de..d7157244b6a5e 100644
--- a/pkgs/development/python-modules/lightgbm/default.nix
+++ b/pkgs/development/python-modules/lightgbm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cmake
@@ -53,7 +53,7 @@ buildPythonPackage rec {
   # `make check`.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast, distributed, high performance gradient boosting (GBDT, GBRT, GBM or MART) framework";
     homepage = "https://github.com/Microsoft/LightGBM";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/lightning/default.nix b/pkgs/development/python-modules/lightning/default.nix
index 8b128e7cb8926..782bd41413eb9 100644
--- a/pkgs/development/python-modules/lightning/default.nix
+++ b/pkgs/development/python-modules/lightning/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   buildInputs = [ pytest ];
   propagatedBuildInputs = [ jinja2 matplotlib numpy requests six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python client library for the Lightning data visualization server";
     homepage = "http://lightning-viz.org";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/limits/default.nix b/pkgs/development/python-modules/limits/default.nix
index 22bd6607fb6b0..e1cd31867de4a 100644
--- a/pkgs/development/python-modules/limits/default.nix
+++ b/pkgs/development/python-modules/limits/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, six }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, six }:
 
 buildPythonPackage rec {
   pname = "limits";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   doCheck = false; # ifilter
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rate limiting utilities";
     license = licenses.mit;
     homepage = "https://limits.readthedocs.org/";
diff --git a/pkgs/development/python-modules/limnoria/default.nix b/pkgs/development/python-modules/limnoria/default.nix
index b46d1566532b2..c92e014e98989 100644
--- a/pkgs/development/python-modules/limnoria/default.nix
+++ b/pkgs/development/python-modules/limnoria/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modified version of Supybot, an IRC bot";
     homepage = "https://github.com/ProgVal/Limnoria";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/linecache2/default.nix b/pkgs/development/python-modules/linecache2/default.nix
index ba2525155d30b..3945ec5001cd8 100644
--- a/pkgs/development/python-modules/linecache2/default.nix
+++ b/pkgs/development/python-modules/linecache2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pbr
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # circular dependencies for tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A backport of linecache to older supported Pythons";
     homepage = "https://github.com/testing-cabal/linecache2";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/linode/default.nix b/pkgs/development/python-modules/linode/default.nix
index d0c8b0ff79438..611b91bb93098 100644
--- a/pkgs/development/python-modules/linode/default.nix
+++ b/pkgs/development/python-modules/linode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ghickman/linode";
     description = "A thin python wrapper around Linode's API";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/livelossplot/default.nix b/pkgs/development/python-modules/livelossplot/default.nix
index c58a18dffe8e7..bbf1b966bf1ee 100644
--- a/pkgs/development/python-modules/livelossplot/default.nix
+++ b/pkgs/development/python-modules/livelossplot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -31,7 +31,7 @@ buildPythonPackage rec {
     pytest tests tests/external_test_examples.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Live training loss plot in Jupyter for Keras, PyTorch, and others";
     homepage = "https://github.com/stared/livelossplot";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/livestreamer-curses/default.nix b/pkgs/development/python-modules/livestreamer-curses/default.nix
index 846f7633924b6..d76eb736ac739 100644
--- a/pkgs/development/python-modules/livestreamer-curses/default.nix
+++ b/pkgs/development/python-modules/livestreamer-curses/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPyPy
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ livestreamer ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gapato/livestreamer-curses";
     description = "Curses frontend for livestreamer";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/livestreamer/default.nix b/pkgs/development/python-modules/livestreamer/default.nix
index 83bd4bcfb72c3..3583d46943401 100644
--- a/pkgs/development/python-modules/livestreamer/default.nix
+++ b/pkgs/development/python-modules/livestreamer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pkgs
 , isPyPy
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     wrapProgram $out/bin/livestreamer --prefix PATH : ${pkgs.rtmpdump}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://livestreamer.tanuki.se";
     description = ''
       Livestreamer is CLI program that extracts streams from various
diff --git a/pkgs/development/python-modules/llfuse/default.nix b/pkgs/development/python-modules/llfuse/default.nix
index ac9360cb02dfe..35235aaab40b8 100644
--- a/pkgs/development/python-modules/llfuse/default.nix
+++ b/pkgs/development/python-modules/llfuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, fetchpatch, buildPythonPackage, pkgconfig, pytest, fuse, attr, which
+{ lib, stdenv, fetchPypi, fetchpatch, buildPythonPackage, pkgconfig, pytest, fuse, attr, which
 , contextlib2, osxfuse
 }:
 
@@ -36,7 +36,7 @@ buildPythonPackage rec {
     py.test -k "not test_listdir" ${optionalString stdenv.isDarwin ''-m "not uses_fuse"''}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for the low-level FUSE API";
     homepage = "https://github.com/python-llfuse/python-llfuse";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/development/python-modules/lmdb/default.nix b/pkgs/development/python-modules/lmdb/default.nix
index 3dc2fec4b744f..20020b97ef230 100644
--- a/pkgs/development/python-modules/lmdb/default.nix
+++ b/pkgs/development/python-modules/lmdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   LMDB_FORCE_SYSTEM=1;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Universal Python binding for the LMDB 'Lightning' Database";
     homepage = "https://github.com/dw/py-lmdb";
     license = licenses.openldap;
diff --git a/pkgs/development/python-modules/lmtpd/default.nix b/pkgs/development/python-modules/lmtpd/default.nix
index 336b799eee2c3..3a1beba29d400 100644
--- a/pkgs/development/python-modules/lmtpd/default.nix
+++ b/pkgs/development/python-modules/lmtpd/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchPypi, isPy3k, stdenv }:
+{ buildPythonPackage, fetchPypi, isPy3k, lib, stdenv }:
 
 buildPythonPackage rec {
   pname = "lmtpd";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
     sha256 = "2c6825d2ffa1de099440411a742f58e1b3e8deeb3345adcfd4c2c38d4baf62b3";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/moggers87/lmtpd";
     description = "LMTP counterpart to smtpd in the Python standard library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/localzone/default.nix b/pkgs/development/python-modules/localzone/default.nix
index f4ed4b98ef592..8690b1e4c91e7 100644
--- a/pkgs/development/python-modules/localzone/default.nix
+++ b/pkgs/development/python-modules/localzone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , dnspython
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple DNS library for managing zone files";
     homepage = "https://localzone.iomaestro.com";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/locket/default.nix b/pkgs/development/python-modules/locket/default.nix
index d98ab63797446..45985a17d3e9c 100644
--- a/pkgs/development/python-modules/locket/default.nix
+++ b/pkgs/development/python-modules/locket/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "locket";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # weird test requirements (spur.local>=0.3.7,<0.4)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Locket implements a lock that can be used by multiple processes provided they use the same path.";
     homepage = "https://github.com/mwilliamson/locket.py";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/logilab/common.nix b/pkgs/development/python-modules/logilab/common.nix
index 3da263757cc6c..b7ba746d79ee0 100644
--- a/pkgs/development/python-modules/logilab/common.nix
+++ b/pkgs/development/python-modules/logilab/common.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, unittest2, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, unittest2, six }:
 
 buildPythonPackage rec {
   pname = "logilab-common";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # and is not currently in nixos
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python packages and modules used by Logilab ";
     homepage = "https://www.logilab.org/project/logilab-common";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/logilab/constraint.nix b/pkgs/development/python-modules/logilab/constraint.nix
index aa26f21820b75..9a071b5cf5f98 100644
--- a/pkgs/development/python-modules/logilab/constraint.nix
+++ b/pkgs/development/python-modules/logilab/constraint.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, logilab_common, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, logilab_common, six }:
 
 buildPythonPackage rec {
   pname = "logilab-constraint";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "logilab-database provides some classes to make unified access to different";
     homepage = "https://www.logilab.org/project/logilab-database";
   };
diff --git a/pkgs/development/python-modules/logilab_astng/default.nix b/pkgs/development/python-modules/logilab_astng/default.nix
index 81879b2218de3..15cea1d7baaa3 100644
--- a/pkgs/development/python-modules/logilab_astng/default.nix
+++ b/pkgs/development/python-modules/logilab_astng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , logilab_common
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ logilab_common ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.logilab.org/project/logilab-astng";
     description = "Python Abstract Syntax Tree New Generation";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/loguru/default.nix b/pkgs/development/python-modules/loguru/default.nix
index 216fb3c5181e0..da91d9eeddd3b 100644
--- a/pkgs/development/python-modules/loguru/default.nix
+++ b/pkgs/development/python-modules/loguru/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, colorama, pytestCheckHook }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, colorama, pytestCheckHook }:
 
 buildPythonPackage rec {
   pname = "loguru";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   disabledTests = [ "test_time_rotation_reopening" "test_file_buffering" ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ "test_rotation_and_retention" "test_rotation_and_retention_timed_file" "test_renaming" "test_await_complete_inheritance" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Delgan/loguru";
     description = "Python logging made (stupidly) simple";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/logutils/default.nix b/pkgs/development/python-modules/logutils/default.nix
index 8b4cb4e69c5cb..d49667d7cc8af 100644
--- a/pkgs/development/python-modules/logutils/default.nix
+++ b/pkgs/development/python-modules/logutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "bc058a25d5c209461f134e1f03cab637d66a7a5ccc12e593db56fbb279899a82";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Logging utilities";
     homepage = "https://bitbucket.org/vinay.sajip/logutils/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/lpod/default.nix b/pkgs/development/python-modules/lpod/default.nix
index effdc3f432a67..67b48cecd62ca 100644
--- a/pkgs/development/python-modules/lpod/default.nix
+++ b/pkgs/development/python-modules/lpod/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , lxml
@@ -22,7 +22,7 @@ buildPythonPackage {
     sha256 = "1mikvzp27wxkzpr2lii4wg1hhx8h610agckqynvsrdc8v3nw9ciw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/lpod/lpod-python/";
     description = "Library implementing the ISO/IEC 26300 OpenDocument Format standard (ODF) ";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/lsi/default.nix b/pkgs/development/python-modules/lsi/default.nix
index 5f193f52e9a57..0fca2f7b372f9 100644
--- a/pkgs/development/python-modules/lsi/default.nix
+++ b/pkgs/development/python-modules/lsi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ colored boto pkgs.openssh pkgs.which ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI for querying and SSHing onto AWS EC2 instances";
     homepage = "https://github.com/NarrativeScience/lsi";
     maintainers = [maintainers.adnelson];
diff --git a/pkgs/development/python-modules/lxc/default.nix b/pkgs/development/python-modules/lxc/default.nix
index 2798cb8007577..a20db9dd5034a 100644
--- a/pkgs/development/python-modules/lxc/default.nix
+++ b/pkgs/development/python-modules/lxc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy3k
@@ -19,7 +19,7 @@ buildPythonPackage {
 
   buildInputs = [ pkgs.lxc ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Out of tree python 2.7 binding for liblxc";
     homepage = "https://github.com/lxc/python2-lxc";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/lyricwikia/default.nix b/pkgs/development/python-modules/lyricwikia/default.nix
index 4e58c6a7d6764..585c38ab33ec1 100644
--- a/pkgs/development/python-modules/lyricwikia/default.nix
+++ b/pkgs/development/python-modules/lyricwikia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pytestrunner, six, beautifulsoup4, requests, }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pytestrunner, six, beautifulsoup4, requests, }:
 buildPythonPackage rec {
   pname = "lyricwikia";
   version = "0.1.11";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # upstream has no code tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/enricobacis/lyricwikia";
     maintainers = [ maintainers.kmein ];
     description = "LyricWikia API for song lyrics";
diff --git a/pkgs/development/python-modules/m2crypto/default.nix b/pkgs/development/python-modules/m2crypto/default.nix
index f3ca43f5e9a5d..af07be47dcdce 100644
--- a/pkgs/development/python-modules/m2crypto/default.nix
+++ b/pkgs/development/python-modules/m2crypto/default.nix
@@ -38,7 +38,7 @@ buildPythonPackage rec {
 
   doCheck = false; # another test that depends on the network.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python crypto and SSL toolkit";
     homepage = "https://gitlab.com/m2crypto/m2crypto";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/m2r/default.nix b/pkgs/development/python-modules/m2r/default.nix
index 3de9ec079d49f..149e4d6ed5629 100644
--- a/pkgs/development/python-modules/m2r/default.nix
+++ b/pkgs/development/python-modules/m2r/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
   mistune, docutils } :
 buildPythonPackage rec {
   pname = "m2r";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # deleted by some tests and not properly regenerated)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/miyakogi/m2r";
     description = "converts a markdown file including reST markups to a valid reST format";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/maestral/default.nix b/pkgs/development/python-modules/maestral/default.nix
index cb7119860f592..b24ebbcc9eb14 100644
--- a/pkgs/development/python-modules/maestral/default.nix
+++ b/pkgs/development/python-modules/maestral/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pythonOlder
@@ -55,7 +55,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open-source Dropbox client for macOS and Linux";
     license = licenses.mit;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix b/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix
index 571a92900c905..14ae268c03a0c 100644
--- a/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix
+++ b/pkgs/development/python-modules/magic-wormhole-mailbox-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, six, attrs, twisted, pyopenssl, service-identity, autobahn, treq, mock, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, six, attrs, twisted, pyopenssl, service-identity, autobahn, treq, mock, pytest }:
 
 buildPythonPackage rec {
   version = "0.4.1";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Securely transfer data between computers";
     homepage = "https://github.com/warner/magic-wormhole-mailbox-server";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/magic-wormhole/default.nix b/pkgs/development/python-modules/magic-wormhole/default.nix
index 9e73001a14990..c85c7e2307fa7 100644
--- a/pkgs/development/python-modules/magic-wormhole/default.nix
+++ b/pkgs/development/python-modules/magic-wormhole/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -54,7 +54,7 @@ buildPythonPackage rec {
       --replace 'locale_env = dict(LC_ALL=locale, LANG=locale)' 'locale_env = dict(LC_ALL=locale, LANG=locale, LOCALE_ARCHIVE=os.getenv("LOCALE_ARCHIVE"))'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Securely transfer data between computers";
     homepage = "https://github.com/warner/magic-wormhole";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/magic/default.nix b/pkgs/development/python-modules/magic/default.nix
index 98e6731a1b86e..45fd740e2e89d 100644
--- a/pkgs/development/python-modules/magic/default.nix
+++ b/pkgs/development/python-modules/magic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pkgs
 }:
@@ -19,7 +19,7 @@ buildPythonPackage {
   # No test suite
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python wrapper around libmagic";
     homepage = "http://www.darwinsys.com/file/";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/mahotas/default.nix b/pkgs/development/python-modules/mahotas/default.nix
index b7d17d943f7b1..818ff459985cd 100644
--- a/pkgs/development/python-modules/mahotas/default.nix
+++ b/pkgs/development/python-modules/mahotas/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchFromGitHub, nose, pillow, scipy, numpy, imread, stdenv }:
+{ buildPythonPackage, fetchFromGitHub, nose, pillow, scipy, numpy, imread, lib, stdenv }:
 
 buildPythonPackage rec {
   pname = "mahotas";
@@ -23,7 +23,7 @@ buildPythonPackage rec {
 
   disabled = stdenv.isi686; # Failing tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Computer vision package based on numpy";
     homepage = "https://mahotas.readthedocs.io/";
     maintainers = with maintainers; [ luispedro ];
diff --git a/pkgs/development/python-modules/mailcap-fix/default.nix b/pkgs/development/python-modules/mailcap-fix/default.nix
index 886a3ed66b37c..08991edce4aaf 100644
--- a/pkgs/development/python-modules/mailcap-fix/default.nix
+++ b/pkgs/development/python-modules/mailcap-fix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy36
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "02lijkq6v379r8zkqg9q2srin3i80m4wvwik3hcbih0s14v0ng0i";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A patched mailcap module that conforms to RFC 1524";
     homepage = "https://github.com/michael-lazar/mailcap_fix";
     license = licenses.unlicense;
diff --git a/pkgs/development/python-modules/mailchimp/default.nix b/pkgs/development/python-modules/mailchimp/default.nix
index b9640a4ab5d50..0032caa7a0a52 100644
--- a/pkgs/development/python-modules/mailchimp/default.nix
+++ b/pkgs/development/python-modules/mailchimp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , docopt
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     sed -i 's/==/>=/' setup.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CLI client and Python API library for the MailChimp email platform";
     homepage = "http://apidocs.mailchimp.com/api/2.0/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mailman-hyperkitty/default.nix b/pkgs/development/python-modules/mailman-hyperkitty/default.nix
index 6abe5f5c6bc4b..8ab80e3371797 100644
--- a/pkgs/development/python-modules/mailman-hyperkitty/default.nix
+++ b/pkgs/development/python-modules/mailman-hyperkitty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, mailman, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, mailman, mock }:
 
 buildPythonPackage rec {
   pname = "mailman-hyperkitty";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   '';
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mailman archiver plugin for HyperKitty";
     homepage = "https://gitlab.com/mailman/mailman-hyperkitty";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/mailman-rss/default.nix b/pkgs/development/python-modules/mailman-rss/default.nix
index d0d103bfbec56..c47d300d8507d 100644
--- a/pkgs/development/python-modules/mailman-rss/default.nix
+++ b/pkgs/development/python-modules/mailman-rss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, withTwitter ? false}:
+{ lib, stdenv, python3Packages, withTwitter ? false}:
 
 python3Packages.buildPythonApplication rec {
   pname = "mailman-rss";
@@ -16,7 +16,7 @@ python3Packages.buildPythonApplication rec {
   # No tests in Pypi Tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mailman archive -> rss converter";
     homepage = "https://github.com/kyamagu/mailman-rss";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mailmanclient/default.nix b/pkgs/development/python-modules/mailmanclient/default.nix
index 45dfc55ae9a80..280ee95b83016 100644
--- a/pkgs/development/python-modules/mailmanclient/default.nix
+++ b/pkgs/development/python-modules/mailmanclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, six, httplib2, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, six, httplib2, requests }:
 
 buildPythonPackage rec {
   pname = "mailmanclient";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six httplib2 requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/mailman/";
     description = "REST client for driving Mailman 3";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/manhole/default.nix b/pkgs/development/python-modules/manhole/default.nix
index 13b887f6ee4d2..b9d57a7c0899f 100644
--- a/pkgs/development/python-modules/manhole/default.nix
+++ b/pkgs/development/python-modules/manhole/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -38,7 +38,7 @@ buildPythonPackage rec {
     py.test -vv -k "not test_uwsgi"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ionelmc/python-manhole";
     description = "Debugging manhole for Python applications";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/manuel/default.nix b/pkgs/development/python-modules/manuel/default.nix
index 1f2c09d43709d..59243783ecf9e 100644
--- a/pkgs/development/python-modules/manuel/default.nix
+++ b/pkgs/development/python-modules/manuel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ six ];
   checkInputs = [ zope_testing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A documentation builder";
     homepage = "https://pypi.python.org/pypi/manuel";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/mapsplotlib/default.nix b/pkgs/development/python-modules/mapsplotlib/default.nix
index d21d09571ad15..54d0ade40f352 100644
--- a/pkgs/development/python-modules/mapsplotlib/default.nix
+++ b/pkgs/development/python-modules/mapsplotlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ matplotlib scipy pandas requests pillow ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Custom Python plots on a Google Maps background";
     homepage = "https://github.com/tcassou/mapsplotlib";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/marionette-harness/mozinfo.nix b/pkgs/development/python-modules/marionette-harness/mozinfo.nix
index 1aca4cb58468e..b7d91cc16f52a 100644
--- a/pkgs/development/python-modules/marionette-harness/mozinfo.nix
+++ b/pkgs/development/python-modules/marionette-harness/mozinfo.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ mozfile ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System information utilities for Mozilla testing";
     homepage = "https://wiki.mozilla.org/Auto-tools/Projects/Mozbase";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/marisa/default.nix b/pkgs/development/python-modules/marisa/default.nix
index 0fa5a98f7522e..a30f7062df0a7 100644
--- a/pkgs/development/python-modules/marisa/default.nix
+++ b/pkgs/development/python-modules/marisa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, marisa, swig
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, marisa, swig
 , isPy3k
 }:
 
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   sourceRoot = "${src.name}/bindings/python";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python binding for marisa package (do not confuse with marisa-trie python bindings)";
     homepage    = "https://github.com/s-yata/marisa-trie";
     license     = with licenses; [ bsd2 lgpl2 ];
diff --git a/pkgs/development/python-modules/markdown-macros/default.nix b/pkgs/development/python-modules/markdown-macros/default.nix
index 41a634f4b9a50..e248bfe60cc44 100644
--- a/pkgs/development/python-modules/markdown-macros/default.nix
+++ b/pkgs/development/python-modules/markdown-macros/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -30,7 +30,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extension for python-markdown that makes writing trac-like macros easy";
     homepage = "https://github.com/wnielson/markdown-macros";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/markdown2/default.nix b/pkgs/development/python-modules/markdown2/default.nix
index 8add8f15298f8..2f929012df89f 100644
--- a/pkgs/development/python-modules/markdown2/default.nix
+++ b/pkgs/development/python-modules/markdown2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "markdown2";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
     sha256 = "08a124043aa0ad36ba2136239547d5011a2b770278abb11a5609611e0040ea05";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast and complete Python implementation of Markdown";
     homepage =  "https://github.com/trentm/python-markdown2";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/markerlib/default.nix b/pkgs/development/python-modules/markerlib/default.nix
index 256f395a8f8f3..d039198b3938f 100644
--- a/pkgs/development/python-modules/markerlib/default.nix
+++ b/pkgs/development/python-modules/markerlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/dholth/markerlib/";
     description = "A compiler for PEP 345 environment markers";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/markupsafe/default.nix b/pkgs/development/python-modules/markupsafe/default.nix
index 864e30214efa9..6a6e06cd3177b 100644
--- a/pkgs/development/python-modules/markupsafe/default.nix
+++ b/pkgs/development/python-modules/markupsafe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "29872e92839765e546828bb7754a68c418d927cd064fd4708fab9fe9c8bb116b";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Implements a XML/HTML/XHTML Markup safe string";
     homepage = "http://dev.pocoo.org";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/matplotlib/2.nix b/pkgs/development/python-modules/matplotlib/2.nix
index dd25860795baf..17a9fb246bd71 100644
--- a/pkgs/development/python-modules/matplotlib/2.nix
+++ b/pkgs/development/python-modules/matplotlib/2.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, python, buildPythonPackage, pycairo, backports_functools_lru_cache
+{ lib, stdenv, fetchPypi, python, buildPythonPackage, pycairo, backports_functools_lru_cache
 , which, cycler, dateutil, nose, numpy, pyparsing, sphinx, tornado, kiwisolver
 , freetype, libpng, pkgconfig, mock, pytz, pygobject3, gobject-introspection, functools32, subprocess32
 , fetchpatch
@@ -77,7 +77,7 @@ buildPythonPackage rec {
   # order for all of the tests to pass.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python plotting library, making publication quality plots";
     homepage    = "https://matplotlib.org/";
     maintainers = with maintainers; [ lovek323 veprbl ];
diff --git a/pkgs/development/python-modules/matplotlib/default.nix b/pkgs/development/python-modules/matplotlib/default.nix
index 5ad3c92393d83..f075ba47ce8a0 100644
--- a/pkgs/development/python-modules/matplotlib/default.nix
+++ b/pkgs/development/python-modules/matplotlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, python, buildPythonPackage, isPy3k, pycairo, backports_functools_lru_cache
+{ lib, stdenv, fetchPypi, python, buildPythonPackage, isPy3k, pycairo, backports_functools_lru_cache
 , which, cycler, dateutil, nose, numpy, pyparsing, sphinx, tornado, kiwisolver
 , freetype, libpng, pkgconfig, mock, pytz, pygobject3, gobject-introspection
 , certifi, pillow
@@ -68,7 +68,7 @@ buildPythonPackage rec {
   # order for all of the tests to pass.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python plotting library, making publication quality plots";
     homepage    = "https://matplotlib.org/";
     maintainers = with maintainers; [ lovek323 veprbl ];
diff --git a/pkgs/development/python-modules/matrix-client/default.nix b/pkgs/development/python-modules/matrix-client/default.nix
index 71092583d7fd4..34c99a1ebe1c2 100644
--- a/pkgs/development/python-modules/matrix-client/default.nix
+++ b/pkgs/development/python-modules/matrix-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Matrix Client-Server SDK";
     homepage = "https://github.com/matrix-org/matrix-python-sdk";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/maya/default.nix b/pkgs/development/python-modules/maya/default.nix
index 6df4091664b3e..9cd1019a03014 100644
--- a/pkgs/development/python-modules/maya/default.nix
+++ b/pkgs/development/python-modules/maya/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, fetchpatch, buildPythonPackage
+{ lib, stdenv, fetchPypi, fetchpatch, buildPythonPackage
 , dateparser, humanize, pendulum, ruamel_yaml, tzlocal }:
 
 buildPythonPackage rec {
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Datetimes for Humans";
     homepage = "https://github.com/kennethreitz/maya";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mccabe/default.nix b/pkgs/development/python-modules/mccabe/default.nix
index 7a4605e68cede..2886a436a00da 100644
--- a/pkgs/development/python-modules/mccabe/default.nix
+++ b/pkgs/development/python-modules/mccabe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, pytestrunner }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, pytestrunner }:
 
 buildPythonPackage rec {
   pname = "mccabe";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pytest pytestrunner ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "McCabe checker, plugin for flake8";
     homepage = "https://github.com/flintwork/mccabe";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mdp/default.nix b/pkgs/development/python-modules/mdp/default.nix
index a93b00a0f91ea..5313cd8e89aa8 100644
--- a/pkgs/development/python-modules/mdp/default.nix
+++ b/pkgs/development/python-modules/mdp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, future, numpy }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, future, numpy }:
 
 buildPythonPackage rec {
   pname = "MDP";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Tests disabled because of missing dependencies not in nix
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for building complex data processing software by combining widely used machine learning algorithms";
     homepage = "http://mdp-toolkit.sourceforge.net";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/mechanize/default.nix b/pkgs/development/python-modules/mechanize/default.nix
index 1d63a6e2b6a1a..e2d2269a43c0c 100644
--- a/pkgs/development/python-modules/mechanize/default.nix
+++ b/pkgs/development/python-modules/mechanize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , html5lib
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stateful programmatic web browsing in Python";
     homepage = "https://github.com/python-mechanize/mechanize";
     license = "BSD-style";
diff --git a/pkgs/development/python-modules/meinheld/default.nix b/pkgs/development/python-modules/meinheld/default.nix
index 2941505184de1..ce7f231680073 100644
--- a/pkgs/development/python-modules/meinheld/default.nix
+++ b/pkgs/development/python-modules/meinheld/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, greenlet }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, greenlet }:
 
 buildPythonPackage rec {
   pname = "meinheld";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High performance asynchronous Python WSGI Web Server";
     homepage = "https://meinheld.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/meld3/default.nix b/pkgs/development/python-modules/meld3/default.nix
index b2f514623315d..8871bfdda4638 100644
--- a/pkgs/development/python-modules/meld3/default.nix
+++ b/pkgs/development/python-modules/meld3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An HTML/XML templating engine used by supervisor";
     homepage = "https://github.com/supervisor/meld3";
     license = licenses.free;
diff --git a/pkgs/development/python-modules/meliae/default.nix b/pkgs/development/python-modules/meliae/default.nix
index e02e72c1add5b..d602e3d94fdc8 100644
--- a/pkgs/development/python-modules/meliae/default.nix
+++ b/pkgs/development/python-modules/meliae/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cython
@@ -32,7 +32,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ cython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Memory Usage Analyzer";
     homepage = "https://launchpad.net/meliae";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/memcached/default.nix b/pkgs/development/python-modules/memcached/default.nix
index 0e1ec2a2765c7..b75bd31361de0 100644
--- a/pkgs/development/python-modules/memcached/default.nix
+++ b/pkgs/development/python-modules/memcached/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , fetchPypi
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     sha256 = "124s98m6hvxj6x90d7aynsjfz878zli771q96ns767r2mbqn7192";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python API for communicating with the memcached distributed memory object cache daemon";
     homepage = "http://www.tummy.com/Community/software/python-memcached/";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/memory_profiler/default.nix b/pkgs/development/python-modules/memory_profiler/default.nix
index 0dafde83c4046..28ff6b7c5e313 100644
--- a/pkgs/development/python-modules/memory_profiler/default.nix
+++ b/pkgs/development/python-modules/memory_profiler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python
 }:
 
@@ -16,7 +16,7 @@ python.pkgs.buildPythonPackage rec {
     matplotlib # needed for plotting memory usage
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A module for monitoring memory usage of a process";
     longDescription = ''
       This is a python module for monitoring memory consumption of a process as
diff --git a/pkgs/development/python-modules/mergedeep/default.nix b/pkgs/development/python-modules/mergedeep/default.nix
index 3b5536ed6fbcf..13aadbc9952ff 100644
--- a/pkgs/development/python-modules/mergedeep/default.nix
+++ b/pkgs/development/python-modules/mergedeep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy27, fetchFromGitHub, pytest }:
+{ lib, stdenv, buildPythonPackage, isPy27, fetchFromGitHub, pytest }:
 
 buildPythonPackage rec {
   pname = "mergedeep";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   checkPhase = "pytest";
   pythonImportsCheck = [ "mergedeep" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/clarketm/mergedeep";
     description = "A deep merge function for python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mesa/default.nix b/pkgs/development/python-modules/mesa/default.nix
index 78c0f1656a3ce..5b97f972dad1a 100644
--- a/pkgs/development/python-modules/mesa/default.nix
+++ b/pkgs/development/python-modules/mesa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy27
 , cookiecutter, networkx , pandas, tornado, tqdm
 , pytest }:
 
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ cookiecutter networkx pandas tornado tqdm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/projectmesa/mesa";
     description = "An agent-based modeling (or ABM) framework in Python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/metaphone/default.nix b/pkgs/development/python-modules/metaphone/default.nix
index a9a4409c0de62..1c8557f15c415 100644
--- a/pkgs/development/python-modules/metaphone/default.nix
+++ b/pkgs/development/python-modules/metaphone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi, nose }:
 
 buildPythonPackage rec {
   pname = "metaphone";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   buildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/oubiwann/metaphone";
     description = "A Python implementation of the metaphone and double metaphone algorithms";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/micawber/default.nix b/pkgs/development/python-modules/micawber/default.nix
index 0240a21aca33f..9d31dd378ac43 100644
--- a/pkgs/development/python-modules/micawber/default.nix
+++ b/pkgs/development/python-modules/micawber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, beautifulsoup4 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, beautifulsoup4 }:
 
 buildPythonPackage rec {
   pname = "micawber";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ beautifulsoup4 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://micawber.readthedocs.io/en/latest/";
     description = "A small library for extracting rich content from urls";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/midiutil/default.nix b/pkgs/development/python-modules/midiutil/default.nix
index 0b9945f97d3dd..5ac8d917d75db 100644
--- a/pkgs/development/python-modules/midiutil/default.nix
+++ b/pkgs/development/python-modules/midiutil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "MIDIUtil";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "02m9sqv36zrzgz5zg2w9qmz8snzlm27yg3ways2hgipgs4xriykr";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/MarkCWirt/MIDIUtil";
     description = "A pure python library for creating multi-track MIDI files";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/milc/default.nix b/pkgs/development/python-modules/milc/default.nix
index adee40650bce6..dc824d565474c 100644
--- a/pkgs/development/python-modules/milc/default.nix
+++ b/pkgs/development/python-modules/milc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , appdirs
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     ./hello | grep "Hello, World"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Opinionated Batteries-Included Python 3 CLI Framework";
     homepage = "https://milc.clueboard.co";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/minimock/default.nix b/pkgs/development/python-modules/minimock/default.nix
index 6275d92b05593..f154eabb744c9 100644
--- a/pkgs/development/python-modules/minimock/default.nix
+++ b/pkgs/development/python-modules/minimock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , nose
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     ./test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimalistic mocking library for python";
     homepage = "https://pypi.python.org/pypi/MiniMock";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/miniupnpc/default.nix b/pkgs/development/python-modules/miniupnpc/default.nix
index b3c559c846225..7178405ab74c5 100644
--- a/pkgs/development/python-modules/miniupnpc/default.nix
+++ b/pkgs/development/python-modules/miniupnpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "miniupnpc";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "0ca94zz7sr2x57j218aypxqcwkr23n8js30f3yrvvqbg929nr93y";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "miniUPnP client";
     homepage = "http://miniupnp.free.fr/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mitmproxy/default.nix b/pkgs/development/python-modules/mitmproxy/default.nix
index d22ce7df128ae..dd351931e0629 100644
--- a/pkgs/development/python-modules/mitmproxy/default.nix
+++ b/pkgs/development/python-modules/mitmproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , isPy27
@@ -107,7 +107,7 @@ buildPythonPackage rec {
     requests
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Man-in-the-middle proxy";
     homepage    = "https://mitmproxy.org/";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/mlflow/default.nix b/pkgs/development/python-modules/mlflow/default.nix
index e86a27e1657f2..89cc8f9914663 100644
--- a/pkgs/development/python-modules/mlflow/default.nix
+++ b/pkgs/development/python-modules/mlflow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27
 , alembic
 , click
 , cloudpickle
@@ -61,7 +61,7 @@ buildPythonPackage rec {
     gunicorn
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mlflow/mlflow";
     description = "Open source platform for the machine learning lifecycle";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/mlrose/default.nix b/pkgs/development/python-modules/mlrose/default.nix
index 5fd39d9b347af..c3c7c55f292d9 100644
--- a/pkgs/development/python-modules/mlrose/default.nix
+++ b/pkgs/development/python-modules/mlrose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, isPy27, buildPythonPackage, fetchPypi, scikitlearn }:
+{ lib, stdenv, isPy27, buildPythonPackage, fetchPypi, scikitlearn }:
 
 buildPythonPackage rec {
   pname = "mlrose";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     sed -i 's,sklearn,scikit-learn,g' setup.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Machine Learning, Randomized Optimization and SEarch";
     homepage    = "https://github.com/gkhayes/mlrose";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/mlxtend/default.nix b/pkgs/development/python-modules/mlxtend/default.nix
index 2bfd122491010..94af156d9afbc 100644
--- a/pkgs/development/python-modules/mlxtend/default.nix
+++ b/pkgs/development/python-modules/mlxtend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -39,7 +39,7 @@ buildPythonPackage rec {
     joblib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library of Python tools and extensions for data science";
     homepage = "https://github.com/rasbt/mlxtend";
     license= licenses.bsd3;
diff --git a/pkgs/development/python-modules/mmpython/default.nix b/pkgs/development/python-modules/mmpython/default.nix
index dbb6590eee6d5..e40fc197a5bf9 100644
--- a/pkgs/development/python-modules/mmpython/default.nix
+++ b/pkgs/development/python-modules/mmpython/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPyPy
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   disabled = isPyPy || isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Media Meta Data retrieval framework";
     homepage = "https://sourceforge.net/projects/mmpython/";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/mockito/default.nix b/pkgs/development/python-modules/mockito/default.nix
index 1238388a91c0d..534d6674a8d98 100644
--- a/pkgs/development/python-modules/mockito/default.nix
+++ b/pkgs/development/python-modules/mockito/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, funcsigs, pytest, numpy }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, funcsigs, pytest, numpy }:
 
 buildPythonPackage rec {
   version = "1.2.2";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Spying framework";
     homepage = "https://github.com/kaste/mockito-python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/modestmaps/default.nix b/pkgs/development/python-modules/modestmaps/default.nix
index c7b1071954d2c..19316c26802d3 100644
--- a/pkgs/development/python-modules/modestmaps/default.nix
+++ b/pkgs/development/python-modules/modestmaps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pillow
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pillow ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for building interactive maps";
     homepage = "http://modestmaps.com";
     license = stdenv.lib.licenses.bsd3;
diff --git a/pkgs/development/python-modules/mongodict/default.nix b/pkgs/development/python-modules/mongodict/default.nix
index 932160bb9fad6..467093e84cebf 100644
--- a/pkgs/development/python-modules/mongodict/default.nix
+++ b/pkgs/development/python-modules/mongodict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pymongo
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pymongo ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MongoDB-backed Python dict-like interface";
     homepage = "https://github.com/turicas/mongodict/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/monotonic/default.nix b/pkgs/development/python-modules/monotonic/default.nix
index 38a25841c7b6c..7dffd32844273 100644
--- a/pkgs/development/python-modules/monotonic/default.nix
+++ b/pkgs/development/python-modules/monotonic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -19,7 +19,7 @@ buildPythonPackage rec {
       "ctypes.util.find_library('c')" "'${stdenv.glibc.out}/lib/libc.so.6'"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of time.monotonic() for Python 2 & < 3.3";
     homepage = "https://github.com/atdt/monotonic";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/moretools/default.nix b/pkgs/development/python-modules/moretools/default.nix
index c9fd953f350e4..d39f67a73113d 100644
--- a/pkgs/development/python-modules/moretools/default.nix
+++ b/pkgs/development/python-modules/moretools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , six, pathpy, zetup, pytest
 , decorator }:
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   checkInputs = [ six pathpy pytest ];
   propagatedBuildInputs = [ decorator ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Many more basic tools for python 2/3 extending itertools, functools, operator and collections
     '';
diff --git a/pkgs/development/python-modules/moviepy/default.nix b/pkgs/development/python-modules/moviepy/default.nix
index 1e08d5dc3af2c..13f8d5884cf61 100644
--- a/pkgs/development/python-modules/moviepy/default.nix
+++ b/pkgs/development/python-modules/moviepy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonAtLeast
@@ -43,7 +43,7 @@ buildPythonPackage rec {
     opencv3 scikitimage scikitlearn scipy matplotlib youtube-dl
   ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Video editing with Python";
     homepage = "https://zulko.github.io/moviepy/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mox/default.nix b/pkgs/development/python-modules/mox/default.nix
index 3537d936bb619..94d4791224df2 100644
--- a/pkgs/development/python-modules/mox/default.nix
+++ b/pkgs/development/python-modules/mox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pymox.readthedocs.io/";
     description = "A mock object framework for Python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/mox3/default.nix b/pkgs/development/python-modules/mox3/default.nix
index 70b982ef4b86e..77a02ae8a733f 100644
--- a/pkgs/development/python-modules/mox3/default.nix
+++ b/pkgs/development/python-modules/mox3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -29,7 +29,7 @@ buildPythonPackage rec {
   # https://opendev.org/openstack/mox3/src/branch/master/test-requirements.txt
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mock object framework for Python";
     homepage = "https://docs.openstack.org/mox3/latest/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/mozsvc/default.nix b/pkgs/development/python-modules/mozsvc/default.nix
index 780a162a916e5..55afb1773fe33 100644
--- a/pkgs/development/python-modules/mozsvc/default.nix
+++ b/pkgs/development/python-modules/mozsvc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pyramid
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   doCheck = false; # too many dependencies and conflicting versions; I (nadrieril) gave up
   propagatedBuildInputs = [ pyramid simplejson konfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mozilla-services/mozservices";
     description = "Various utilities for Mozilla apps";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/mpd/default.nix b/pkgs/development/python-modules/mpd/default.nix
index 5ae3e2b41ec70..212e6b5f13c40 100644
--- a/pkgs/development/python-modules/mpd/default.nix
+++ b/pkgs/development/python-modules/mpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "02812eba1d2e0f46e37457f5a6fa23ba203622e4bcab0a19b265e66b08cd21b4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An MPD (Music Player Daemon) client library written in pure Python";
     homepage = "http://jatreuman.indefero.net/p/python-mpd/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/mpd2/default.nix b/pkgs/development/python-modules/mpd2/default.nix
index 5503ec2e139d3..f842826d20bd6 100644
--- a/pkgs/development/python-modules/mpd2/default.nix
+++ b/pkgs/development/python-modules/mpd2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest mpd.tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python client module for the Music Player Daemon";
     homepage = "https://github.com/Mic92/python-mpd2";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/mpmath/default.nix b/pkgs/development/python-modules/mpmath/default.nix
index 1cbb8b04130b6..86d55b34f0443 100644
--- a/pkgs/development/python-modules/mpmath/default.nix
+++ b/pkgs/development/python-modules/mpmath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://mpmath.org/";
     description = "A pure-Python library for multiprecision floating arithmetic";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/mpv/default.nix b/pkgs/development/python-modules/mpv/default.nix
index 6dab88e0286c4..0ff66fa8132ee 100644
--- a/pkgs/development/python-modules/mpv/default.nix
+++ b/pkgs/development/python-modules/mpv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python, isPy27
 , mpv
 }:
 
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # tests impure, will error if it can't load libmpv.so
   checkPhase = "${python.interpreter} -c 'import mpv'";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python interface to the mpv media player";
     homepage = "https://github.com/jaseg/python-mpv";
     license = licenses.agpl3;
diff --git a/pkgs/development/python-modules/mrbob/default.nix b/pkgs/development/python-modules/mrbob/default.nix
index 7074dab739be8..64d0ce13a86d0 100644
--- a/pkgs/development/python-modules/mrbob/default.nix
+++ b/pkgs/development/python-modules/mrbob/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, stdenv, glibcLocales, mock, nose, isPy3k, jinja2, six
+{ buildPythonPackage, lib, stdenv, glibcLocales, mock, nose, isPy3k, jinja2, six
 , fetchPypi
 }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ jinja2 six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/domenkozar/mr.bob";
     description = "A tool to generate code skeletons from templates";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/msgpack-numpy/default.nix b/pkgs/development/python-modules/msgpack-numpy/default.nix
index ad612550d7e8f..56bfa06a628a7 100644
--- a/pkgs/development/python-modules/msgpack-numpy/default.nix
+++ b/pkgs/development/python-modules/msgpack-numpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cython
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     ${python.interpreter} msgpack_numpy.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Numpy data type serialization using msgpack";
     homepage = "https://github.com/lebedov/msgpack-numpy";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/msrplib/default.nix b/pkgs/development/python-modules/msrplib/default.nix
index ffb87ff48ee0d..16c4cc0f43ae7 100644
--- a/pkgs/development/python-modules/msrplib/default.nix
+++ b/pkgs/development/python-modules/msrplib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchdarcs
 , eventlib
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ eventlib application gnutls ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AGProjects/python-msrplib";
     description = "Client library for MSRP protocol and its relay extension (RFC 4975 and RFC4976)";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/multi_key_dict/default.nix b/pkgs/development/python-modules/multi_key_dict/default.nix
index a094b373f8f3f..f76cde9bec537 100644
--- a/pkgs/development/python-modules/multi_key_dict/default.nix
+++ b/pkgs/development/python-modules/multi_key_dict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "17lkx4rf4waglwbhc31aak0f28c63zl3gx5k5i1iq2m3gb0xxsyy";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "multi_key_dict";
     homepage = "https://github.com/formiaczek/multi_key_dict";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/munch/default.nix b/pkgs/development/python-modules/munch/default.nix
index 0d7d6f7c633af..2ff2ce4cefb97 100644
--- a/pkgs/development/python-modules/munch/default.nix
+++ b/pkgs/development/python-modules/munch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A dot-accessible dictionary (a la JavaScript objects)";
     license = licenses.mit;
     homepage = "https://github.com/Infinidat/munch";
diff --git a/pkgs/development/python-modules/munkres/default.nix b/pkgs/development/python-modules/munkres/default.nix
index 3df0e2b01f3b8..cb88b666cfa04 100644
--- a/pkgs/development/python-modules/munkres/default.nix
+++ b/pkgs/development/python-modules/munkres/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -28,7 +28,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://bmc.github.com/munkres/";
     description = "Munkres algorithm for the Assignment Problem";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/murmurhash/default.nix b/pkgs/development/python-modules/murmurhash/default.nix
index 2bd156bd63fd7..68aa29a6edeb5 100644
--- a/pkgs/development/python-modules/murmurhash/default.nix
+++ b/pkgs/development/python-modules/murmurhash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cython
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     pytest murmurhash
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cython bindings for MurmurHash2";
     homepage = "https://github.com/explosion/murmurhash";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/musicbrainzngs/default.nix b/pkgs/development/python-modules/musicbrainzngs/default.nix
index 7ae3445377e6a..02ec381571174 100644
--- a/pkgs/development/python-modules/musicbrainzngs/default.nix
+++ b/pkgs/development/python-modules/musicbrainzngs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     rm test/test_submit.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://python-musicbrainzngs.readthedocs.org/";
     description = "Python bindings for musicbrainz NGS webservice";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/mutag/default.nix b/pkgs/development/python-modules/mutag/default.nix
index 273a009a1f414..45725c0fabb71 100644
--- a/pkgs/development/python-modules/mutag/default.nix
+++ b/pkgs/development/python-modules/mutag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ pyparsing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/aroig/mutag";
     description = "A script to change email tags in a mu indexed maildir";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/muttils/default.nix b/pkgs/development/python-modules/muttils/default.nix
index 01e789fb75941..1d6b5ce8df442 100644
--- a/pkgs/development/python-modules/muttils/default.nix
+++ b/pkgs/development/python-modules/muttils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage {
   # Tests don't work
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for use with console mail clients, like mutt";
     homepage = "https://www.blacktrash.org/hg/muttils";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/mwclient/default.nix b/pkgs/development/python-modules/mwclient/default.nix
index 644f01fdb1f20..ac9373b574ac0 100644
--- a/pkgs/development/python-modules/mwclient/default.nix
+++ b/pkgs/development/python-modules/mwclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , requests, requests_oauthlib, six
 , pytest, pytestcache, pytestcov, responses, mock
 }:
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client library to the MediaWiki API";
     license = licenses.mit;
     homepage = "https://github.com/mwclient/mwclient";
diff --git a/pkgs/development/python-modules/mwlib-ext/default.nix b/pkgs/development/python-modules/mwlib-ext/default.nix
index cfcbdc2d0ac34..0a81fd58d7ee8 100644
--- a/pkgs/development/python-modules/mwlib-ext/default.nix
+++ b/pkgs/development/python-modules/mwlib-ext/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "9229193ee719568d482192d9d913b3c4bb96af7c589d6c31ed4a62caf5054278";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dependencies for mwlib markup";
     homepage = "http://pediapress.com/code/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/mwlib-rl/default.nix b/pkgs/development/python-modules/mwlib-rl/default.nix
index 21820d95c7fa2..d27de2ed45cc6 100644
--- a/pkgs/development/python-modules/mwlib-rl/default.nix
+++ b/pkgs/development/python-modules/mwlib-rl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mwlib
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   buildInputs = [ mwlib mwlib-ext pygments ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate pdfs from mediawiki markup";
     homepage = "http://pediapress.com/code/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/mwlib/default.nix b/pkgs/development/python-modules/mwlib/default.nix
index 55a19e1a6da31..e9defe3ee1488 100644
--- a/pkgs/development/python-modules/mwlib/default.nix
+++ b/pkgs/development/python-modules/mwlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -45,7 +45,7 @@ buildPythonPackage rec {
   # Tests are in build directory but we need extension modules that are in $out
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for parsing MediaWiki articles and converting them to different output formats";
     homepage = "http://pediapress.com/code/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/mwparserfromhell/default.nix b/pkgs/development/python-modules/mwparserfromhell/default.nix
index 791ffe0b1ea33..0546688b867ef 100644
--- a/pkgs/development/python-modules/mwparserfromhell/default.nix
+++ b/pkgs/development/python-modules/mwparserfromhell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "75787b6ab140ab267b313d37d045f3276f5dc6a9741074eddfbabc1635cb2efc";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MWParserFromHell is a parser for MediaWiki wikicode";
     homepage = "https://mwparserfromhell.readthedocs.io/en/latest/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/mygpoclient/default.nix b/pkgs/development/python-modules/mygpoclient/default.nix
index 2af73f2d8974c..c6956b828dbc7 100644
--- a/pkgs/development/python-modules/mygpoclient/default.nix
+++ b/pkgs/development/python-modules/mygpoclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, nose, minimock }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, nose, minimock }:
 
 buildPythonPackage rec {
   pname = "mypgoclient";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   doCheck = (!stdenv.isDarwin);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A gpodder.net client library";
     longDescription = ''
         The mygpoclient library allows developers to utilize a Pythonic interface
diff --git a/pkgs/development/python-modules/mypy-protobuf/default.nix b/pkgs/development/python-modules/mypy-protobuf/default.nix
index 3e0ab2cf1820b..f444ba039c207 100644
--- a/pkgs/development/python-modules/mypy-protobuf/default.nix
+++ b/pkgs/development/python-modules/mypy-protobuf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonApplication, protobuf }:
+{ lib, stdenv, fetchPypi, buildPythonApplication, protobuf }:
 
 buildPythonApplication rec {
   pname = "mypy-protobuf";
@@ -11,7 +11,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ protobuf ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate mypy stub files from protobuf specs";
     homepage = "https://github.com/dropbox/mypy-protobuf";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/mypy/default.nix b/pkgs/development/python-modules/mypy/default.nix
index 1b8d763eb6fe9..4bea992f6ba8e 100644
--- a/pkgs/development/python-modules/mypy/default.nix
+++ b/pkgs/development/python-modules/mypy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, typed-ast, psutil, isPy3k
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, typed-ast, psutil, isPy3k
 , mypy-extensions
 , typing-extensions
 , fetchpatch
@@ -56,7 +56,7 @@ buildPythonPackage rec {
   # is64bit: unfortunately the build would exhaust all possible memory on i686-linux.
   MYPY_USE_MYPYC = stdenv.buildPlatform.is64bit;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optional static typing for Python";
     homepage    = "http://www.mypy-lang.org";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/mypy/extensions.nix b/pkgs/development/python-modules/mypy/extensions.nix
index b3bb68a53b727..21a3ee21dbd92 100644
--- a/pkgs/development/python-modules/mypy/extensions.nix
+++ b/pkgs/development/python-modules/mypy/extensions.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, typing, pythonOlder }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, typing, pythonOlder }:
 
 buildPythonPackage rec {
   pname = "mypy-extensions";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = if pythonOlder "3.5" then [ typing ] else [ ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Experimental type system extensions for programs checked with the mypy typechecker";
     homepage    = "http://www.mypy-lang.org";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/mysqlclient/default.nix b/pkgs/development/python-modules/mysqlclient/default.nix
index b844d9e2c0259..9d91543b7ff3c 100644
--- a/pkgs/development/python-modules/mysqlclient/default.nix
+++ b/pkgs/development/python-modules/mysqlclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, libmysqlclient }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, libmysqlclient }:
 
 buildPythonPackage rec {
   pname = "mysqlclient";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     sha256 = "f6ebea7c008f155baeefe16c56cd3ee6239f7a5a9ae42396c2f1860f08a7c432";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python interface to MySQL";
     homepage = "https://github.com/PyMySQL/mysqlclient-python";
     license = licenses.gpl1;
diff --git a/pkgs/development/python-modules/namebench/default.nix b/pkgs/development/python-modules/namebench/default.nix
index 44b590bae2cf8..eefdcce799019 100644
--- a/pkgs/development/python-modules/namebench/default.nix
+++ b/pkgs/development/python-modules/namebench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , isPyPy
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     sed -i "s|import os|import os; os.chdir(\"$out/namebench\")|" "$out/bin/namebench.py"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/google/namebench"; # Formerly https://code.google.com/archive/p/namebench/
     description = "Find fastest DNS servers available";
     license = with licenses; [
diff --git a/pkgs/development/python-modules/nameparser/default.nix b/pkgs/development/python-modules/nameparser/default.nix
index 3384ed67c1efc..0c8e442affcf7 100644
--- a/pkgs/development/python-modules/nameparser/default.nix
+++ b/pkgs/development/python-modules/nameparser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , glibcLocales
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   LC_ALL="en_US.UTF-8";
   buildInputs = [ glibcLocales ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple Python module for parsing human names into their individual components";
     homepage = "https://github.com/derek73/python-nameparser";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/python-modules/nanoleaf/default.nix b/pkgs/development/python-modules/nanoleaf/default.nix
index ea15da78bfb5b..f6131cd53095b 100644
--- a/pkgs/development/python-modules/nanoleaf/default.nix
+++ b/pkgs/development/python-modules/nanoleaf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests }:
 
 buildPythonPackage rec {
   pname = "nanoleaf";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python interface for Nanoleaf Aurora lighting";
     homepage = "https://github.com/software-2/nanoleaf";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nanomsg-python/default.nix b/pkgs/development/python-modules/nanomsg-python/default.nix
index 29d71d0243f90..4cf33fb2074cf 100644
--- a/pkgs/development/python-modules/nanomsg-python/default.nix
+++ b/pkgs/development/python-modules/nanomsg-python/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, nanomsg }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, nanomsg }:
 
 buildPythonPackage {
   pname = "nanomsg-python";
@@ -16,7 +16,7 @@ buildPythonPackage {
   # Tests requires network connections
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bindings for nanomsg";
     homepage = "https://github.com/tonysimpson/nanomsg-python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nbclient/default.nix b/pkgs/development/python-modules/nbclient/default.nix
index f37cb3bc58f90..d846511eb3f41 100644
--- a/pkgs/development/python-modules/nbclient/default.nix
+++ b/pkgs/development/python-modules/nbclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder,
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder,
   async_generator, traitlets, nbformat, nest-asyncio, jupyter_client,
   pytest, xmltodict, nbconvert, ipywidgets
 , doCheck ? true
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest xmltodict nbconvert ipywidgets ];
   propagatedBuildInputs = [ async_generator traitlets nbformat nest-asyncio jupyter_client ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jupyter/nbclient";
     description = "A client library for executing notebooks";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/nbxmpp/default.nix b/pkgs/development/python-modules/nbxmpp/default.nix
index fb1945ddf427c..28946bd1a6e79 100644
--- a/pkgs/development/python-modules/nbxmpp/default.nix
+++ b/pkgs/development/python-modules/nbxmpp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchzip, gobject-introspection, idna, libsoup, precis-i18n, pygobject3, pyopenssl }:
+{ lib, stdenv, buildPythonPackage, fetchzip, gobject-introspection, idna, libsoup, precis-i18n, pygobject3, pyopenssl }:
 
 let
   pname = "nbxmpp";
@@ -18,7 +18,7 @@ in buildPythonPackage {
   checkInputs = [ gobject-introspection libsoup pygobject3 ];
   propagatedBuildInputs = [ idna pyopenssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://dev.gajim.org/gajim/python-nbxmpp";
     description = "Non-blocking Jabber/XMPP module";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/ncclient/default.nix b/pkgs/development/python-modules/ncclient/default.nix
index 203ffc656806d..f933587dcad14 100644
--- a/pkgs/development/python-modules/ncclient/default.nix
+++ b/pkgs/development/python-modules/ncclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , paramiko
@@ -30,7 +30,7 @@ buildPythonPackage rec {
   #Unfortunately the test hangs at te end
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ncclient/ncclient";
     description = "Python library for NETCONF clients";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ndg-httpsclient/default.nix b/pkgs/development/python-modules/ndg-httpsclient/default.nix
index 687f589fe1afb..7768614a5d12a 100644
--- a/pkgs/development/python-modules/ndg-httpsclient/default.nix
+++ b/pkgs/development/python-modules/ndg-httpsclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pyopenssl
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # uses networking
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cedadev/ndg_httpsclient/";
     description = "Provide enhanced HTTPS support for httplib and urllib2 using PyOpenSSL";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/netaddr/default.nix b/pkgs/development/python-modules/netaddr/default.nix
index 95f567a6c0c66..d92673104a9f7 100644
--- a/pkgs/development/python-modules/netaddr/default.nix
+++ b/pkgs/development/python-modules/netaddr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   checkInputs = [ glibcLocales pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://netaddr.readthedocs.io/en/latest/";
     downloadPage = "https://github.com/netaddr/netaddr/releases";
     changelog = "https://netaddr.readthedocs.io/en/latest/changes.html";
diff --git a/pkgs/development/python-modules/netcdf4/default.nix b/pkgs/development/python-modules/netcdf4/default.nix
index 33c7d307b0371..456124b19bd37 100644
--- a/pkgs/development/python-modules/netcdf4/default.nix
+++ b/pkgs/development/python-modules/netcdf4/default.nix
@@ -42,7 +42,7 @@ buildPythonPackage rec {
   CURL_DIR=curl.dev;
   JPEG_DIR=libjpeg.dev;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interface to netCDF library (versions 3 and 4)";
     homepage = "https://pypi.python.org/pypi/netCDF4";
     license = licenses.free;  # Mix of license (all MIT* like)
diff --git a/pkgs/development/python-modules/netdisco/default.nix b/pkgs/development/python-modules/netdisco/default.nix
index a26a212d8f7ec..e546ac6cd579c 100644
--- a/pkgs/development/python-modules/netdisco/default.nix
+++ b/pkgs/development/python-modules/netdisco/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi, requests, zeroconf, netifaces, pytest }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi, requests, zeroconf, netifaces, pytest }:
 
 buildPythonPackage rec {
   pname = "netdisco";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library to scan local network for services and devices";
     homepage = "https://github.com/home-assistant/netdisco";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/netifaces/default.nix b/pkgs/development/python-modules/netifaces/default.nix
index 94cdb8290133a..07dc63c2181fe 100644
--- a/pkgs/development/python-modules/netifaces/default.nix
+++ b/pkgs/development/python-modules/netifaces/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "2dee9ffdd16292878336a58d04a20f0ffe95555465fee7c9bd23b3490ef2abf3";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://alastairs-place.net/projects/netifaces/";
     description = "Portable access to network interfaces from Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/neuronpy/default.nix b/pkgs/development/python-modules/neuronpy/default.nix
index 1d258effda7df..b81398f918cda 100644
--- a/pkgs/development/python-modules/neuronpy/default.nix
+++ b/pkgs/development/python-modules/neuronpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   #No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interfaces and utilities for the NEURON simulator and analysis of neural data";
     maintainers = [ maintainers.nico202 ];
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nevow/default.nix b/pkgs/development/python-modules/nevow/default.nix
index 301d2c7a39471..356754fdeac8e 100644
--- a/pkgs/development/python-modules/nevow/default.nix
+++ b/pkgs/development/python-modules/nevow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchpatch, fetchPypi, isPy3k, twisted }:
+{ lib, stdenv, buildPythonPackage, fetchpatch, fetchPypi, isPy3k, twisted }:
 
 buildPythonPackage rec {
   pname = "Nevow";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     trial formless nevow
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Nevow, a web application construction kit for Python";
     longDescription = ''
       Nevow - Pronounced as the French "nouveau", or "noo-voh", Nevow
diff --git a/pkgs/development/python-modules/nimfa/default.nix b/pkgs/development/python-modules/nimfa/default.nix
index bd3e92e90dbcd..dc889440aa41e 100644
--- a/pkgs/development/python-modules/nimfa/default.nix
+++ b/pkgs/development/python-modules/nimfa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   checkInputs = [ matplotlib pytest ];
   doCheck = !isPy3k;  # https://github.com/marinkaz/nimfa/issues/42
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Nonnegative matrix factorization library";
     homepage = "http://nimfa.biolab.si";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/nine/default.nix b/pkgs/development/python-modules/nine/default.nix
index e0d1cb173ea76..1747332ed5a25 100644
--- a/pkgs/development/python-modules/nine/default.nix
+++ b/pkgs/development/python-modules/nine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "e8a96b6326341637d25ca9c257c1d2af4033c957946438d9d37bf6eb798d3bbe";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Let's write Python 3 right now!";
     homepage = "https://github.com/nandoflorestan/nine";
     license = licenses.free;
diff --git a/pkgs/development/python-modules/nipy/default.nix b/pkgs/development/python-modules/nipy/default.nix
index fef24e837d1b0..719e07b617bfe 100644
--- a/pkgs/development/python-modules/nipy/default.nix
+++ b/pkgs/development/python-modules/nipy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -40,7 +40,7 @@ buildPythonPackage rec {
   # nipy.tests.test_scripts.test_nipy_3_4d         # ditto re.: `nipy_3_4d` script
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://nipy.org/nipy";
     description = "Software for structural and functional neuroimaging analysis";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/nipype/default.nix b/pkgs/development/python-modules/nipype/default.nix
index f152287d25dc1..5f847007bdc58 100644
--- a/pkgs/development/python-modules/nipype/default.nix
+++ b/pkgs/development/python-modules/nipype/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -106,7 +106,7 @@ buildPythonPackage rec {
   '';
   pythonImportsCheck = [ "nipype" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://nipy.org/nipype/";
     description = "Neuroimaging in Python: Pipelines and Interfaces";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/nixpkgs/default.nix b/pkgs/development/python-modules/nixpkgs/default.nix
index b43c5ab192cb1..4edd31d6a25f6 100644
--- a/pkgs/development/python-modules/nixpkgs/default.nix
+++ b/pkgs/development/python-modules/nixpkgs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pbr
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "nixpkgs" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows to `from nixpkgs import` stuff in interactive Python sessions";
     homepage = "https://github.com/t184256/nixpkgs-python-importer";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/node-semver/default.nix b/pkgs/development/python-modules/node-semver/default.nix
index 9c787147407ae..5ba62fb9210ec 100644
--- a/pkgs/development/python-modules/node-semver/default.nix
+++ b/pkgs/development/python-modules/node-semver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pytest }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pytest }:
 
 buildPythonPackage rec {
   version = "0.7.0";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
     sha256 = "1p7ink1wajkc31r05k1yn37gk377033a9vhin8v4j757d4ha1f91";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/podhmo/python-semver";
     description = "A port of node-semver";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/noise/default.nix b/pkgs/development/python-modules/noise/default.nix
index 736444ec6e19a..98f336c49866c 100644
--- a/pkgs/development/python-modules/noise/default.nix
+++ b/pkgs/development/python-modules/noise/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "noise";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "0rcv40dcshqpchwkdlhsv3n68h9swm9fh4d1cgzr2hsp6rs7k8jp";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/caseman/noise";
     description = "Native-code and shader implementations of Perlin noise";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nose-cover3/default.nix b/pkgs/development/python-modules/nose-cover3/default.nix
index 7f954f7ebca35..185270176acbc 100644
--- a/pkgs/development/python-modules/nose-cover3/default.nix
+++ b/pkgs/development/python-modules/nose-cover3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Coverage 3.x support for Nose";
     homepage = "https://github.com/ask/nosecover3";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/nose-cprof/default.nix b/pkgs/development/python-modules/nose-cprof/default.nix
index aa3f0d37f092b..4f90ee4be8b4e 100644
--- a/pkgs/development/python-modules/nose-cprof/default.nix
+++ b/pkgs/development/python-modules/nose-cprof/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   buildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python nose plugin to profile using cProfile rather than the default Hotshot profiler";
     homepage = "https://github.com/msherry/nose-cprof";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/nose-focus/default.nix b/pkgs/development/python-modules/nose-focus/default.nix
index d7b13eb1059b4..8e31867d85c0b 100644
--- a/pkgs/development/python-modules/nose-focus/default.nix
+++ b/pkgs/development/python-modules/nose-focus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, six, nose, nose-of-yeti
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, six, nose, nose-of-yeti
 , nose-pattern-exclude, which }:
 
 buildPythonPackage rec {
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ./test.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Decorator and plugin to make nose focus on specific tests";
     homepage = "https://nose-focus.readthedocs.io/en/latest/";
     license = licenses.wtfpl;
diff --git a/pkgs/development/python-modules/nose-of-yeti/default.nix b/pkgs/development/python-modules/nose-of-yeti/default.nix
index b7fd1e241aaa7..2bd63f3295d42 100644
--- a/pkgs/development/python-modules/nose-of-yeti/default.nix
+++ b/pkgs/development/python-modules/nose-of-yeti/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, six, nose, fudge, should-dsl }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, six, nose, fudge, should-dsl }:
 
 buildPythonPackage rec {
   pname = "nose-of-yeti";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     ./test.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Nose plugin providing BDD dsl for python";
     homepage = "https://github.com/delfick/nose-of-yeti";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nose-pattern-exclude/default.nix b/pkgs/development/python-modules/nose-pattern-exclude/default.nix
index 2170ac224d950..05a7102f1ae7f 100644
--- a/pkgs/development/python-modules/nose-pattern-exclude/default.nix
+++ b/pkgs/development/python-modules/nose-pattern-exclude/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, nose }:
 
 buildPythonPackage rec {
   pname = "nose-pattern-exclude";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # There are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Exclude specific files and directories from nosetests runs";
     homepage = "https://github.com/jakubroztocil/nose-pattern-exclude";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/nose/default.nix b/pkgs/development/python-modules/nose/default.nix
index a5ed49a29d73a..2805b7c2ea19f 100644
--- a/pkgs/development/python-modules/nose/default.nix
+++ b/pkgs/development/python-modules/nose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     ${python}/bin/${python.executable} selftest.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A unittest-based testing framework for python that makes writing and running tests easier";
     homepage = "http://readthedocs.org/docs/nose/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/nose2/default.nix b/pkgs/development/python-modules/nose2/default.nix
index 300ed80ca4081..b815e223d82d1 100644
--- a/pkgs/development/python-modules/nose2/default.nix
+++ b/pkgs/development/python-modules/nose2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # AttributeError: 'module' object has no attribute 'collector'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "nose2 is the next generation of nicer testing for Python";
     homepage = "https://github.com/nose-devs/nose2";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/nose_progressive/default.nix b/pkgs/development/python-modules/nose_progressive/default.nix
index b4683ef12cbf6..b920bb40736c3 100644
--- a/pkgs/development/python-modules/nose_progressive/default.nix
+++ b/pkgs/development/python-modules/nose_progressive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # fails with obscure error
   doCheck = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/erikrose/nose-progressive";
     description = "A testrunner with a progress bar and smarter tracebacks";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nosejs/default.nix b/pkgs/development/python-modules/nosejs/default.nix
index 9d30855c68e12..c165e87ff2eeb 100644
--- a/pkgs/development/python-modules/nosejs/default.nix
+++ b/pkgs/development/python-modules/nosejs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     nosetests -v
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.org/project/NoseJS/";
     description = "A Nose plugin for integrating JavaScript tests into a Python test suite";
     license = licenses.free;
diff --git a/pkgs/development/python-modules/nosexcover/default.nix b/pkgs/development/python-modules/nosexcover/default.nix
index 84cc4994b08ac..36747a50aae7d 100644
--- a/pkgs/development/python-modules/nosexcover/default.nix
+++ b/pkgs/development/python-modules/nosexcover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , coverage
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ coverage nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extends nose.plugins.cover to add Cobertura-style XML reports";
     homepage = "https://github.com/cmheisel/nose-xcover/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/notify/default.nix b/pkgs/development/python-modules/notify/default.nix
index 7e71eb8b30213..5621f0b24affb 100644
--- a/pkgs/development/python-modules/notify/default.nix
+++ b/pkgs/development/python-modules/notify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python
 , pygobject2
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
 
   postInstall = "cd $out/lib/python*/site-packages && ln -s gtk-*/pynotify .";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for libnotify";
     homepage = "http://www.galago-project.org/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/notmuch/2.nix b/pkgs/development/python-modules/notmuch/2.nix
index 593eed6c25141..171b881087086 100644
--- a/pkgs/development/python-modules/notmuch/2.nix
+++ b/pkgs/development/python-modules/notmuch/2.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , notmuch
 , python
@@ -13,7 +13,7 @@ buildPythonPackage {
 
   buildInputs = [ python notmuch cffi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pythonic bindings for the notmuch mail database using CFFI";
     homepage = "https://notmuchmail.org/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/notmuch/default.nix b/pkgs/development/python-modules/notmuch/default.nix
index 4ae42b3390b5a..173f332b3146c 100644
--- a/pkgs/development/python-modules/notmuch/default.nix
+++ b/pkgs/development/python-modules/notmuch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , notmuch
 , python
@@ -16,7 +16,7 @@ buildPythonPackage {
       notmuch/globals.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python wrapper around notmuch";
     homepage = "https://notmuchmail.org/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/ntplib/default.nix b/pkgs/development/python-modules/ntplib/default.nix
index e87fc6292e741..266482a8ff28b 100644
--- a/pkgs/development/python-modules/ntplib/default.nix
+++ b/pkgs/development/python-modules/ntplib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Require networking
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python NTP library";
     homepage = "http://code.google.com/p/ntplib/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nuitka/default.nix b/pkgs/development/python-modules/nuitka/default.nix
index 890180d0dec97..4056c8a440e7d 100644
--- a/pkgs/development/python-modules/nuitka/default.nix
+++ b/pkgs/development/python-modules/nuitka/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , vmprof
@@ -43,7 +43,7 @@ in buildPythonPackage rec {
   # Requires CPython
   disabled = isPyPy;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python compiler with full language support and CPython compatibility";
     license = licenses.asl20;
     homepage = "https://nuitka.net/";
diff --git a/pkgs/development/python-modules/numericalunits/default.nix b/pkgs/development/python-modules/numericalunits/default.nix
index f628daf833b4d..0c71b065a32d3 100644
--- a/pkgs/development/python-modules/numericalunits/default.nix
+++ b/pkgs/development/python-modules/numericalunits/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   disabled = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pypi.python.org/pypi/numericalunits";
     description = "A package that lets you define quantities with unit";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nvchecker/default.nix b/pkgs/development/python-modules/nvchecker/default.nix
index b675fa6f06be3..832e281a9a1e2 100644
--- a/pkgs/development/python-modules/nvchecker/default.nix
+++ b/pkgs/development/python-modules/nvchecker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pythonOlder
@@ -46,7 +46,7 @@ buildPythonPackage rec {
 
   pytestFlagsArray = [ "-m 'not needs_net'" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/lilydjwg/nvchecker";
     description = "New version checker for software";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/nwdiag/default.nix b/pkgs/development/python-modules/nwdiag/default.nix
index 9e7d4958e3be5..4676fdef0cdca 100644
--- a/pkgs/development/python-modules/nwdiag/default.nix
+++ b/pkgs/development/python-modules/nwdiag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonPackage, pep8, nose, unittest2, docutils
+{ lib, stdenv, fetchurl, buildPythonPackage, pep8, nose, unittest2, docutils
 , blockdiag, setuptools
 }:
 
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # tests fail
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate network-diagram image from spec-text file (similar to Graphviz)";
     homepage = "http://blockdiag.com/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/nxt-python/default.nix b/pkgs/development/python-modules/nxt-python/default.nix
index aae9b5f743702..4057ba1de8adb 100644
--- a/pkgs/development/python-modules/nxt-python/default.nix
+++ b/pkgs/development/python-modules/nxt-python/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , isPy3k
@@ -25,7 +25,7 @@ buildPythonPackage {
   # Tests fail on Mac dependency
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python driver/interface for Lego Mindstorms NXT robot";
     homepage = "https://github.com/Eelviny/nxt-python";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/oath/default.nix b/pkgs/development/python-modules/oath/default.nix
index a64eeb8e1036e..158cf03684065 100644
--- a/pkgs/development/python-modules/oath/default.nix
+++ b/pkgs/development/python-modules/oath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1xqgcqgx6aa0j21hwsdb3aqpqhviwj756bcqjjjcm1h1aij11p6m";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python implementation of the three main OATH specifications: HOTP, TOTP and OCRA";
     homepage = "https://github.com/bdauvergne/python-oath";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/oauth/default.nix b/pkgs/development/python-modules/oauth/default.nix
index 133640f662028..0e53eaec7c0e3 100644
--- a/pkgs/development/python-modules/oauth/default.nix
+++ b/pkgs/development/python-modules/oauth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests included in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://code.google.com/archive/p/oauth/";
     description = "Library for OAuth version 1.0a";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/oauth2/default.nix b/pkgs/development/python-modules/oauth2/default.nix
index 8233b132344f6..70b2e94e37ca1 100644
--- a/pkgs/development/python-modules/oauth2/default.nix
+++ b/pkgs/development/python-modules/oauth2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , httplib2
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # ServerNotFoundError: Unable to find the server at oauth-sandbox.sevengoslings.net
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/simplegeo/python-oauth2";
     description = "Library for OAuth version 1.0";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/oauthlib/3.1.nix b/pkgs/development/python-modules/oauthlib/3.1.nix
index 185ef97486374..40501733e4c73 100644
--- a/pkgs/development/python-modules/oauthlib/3.1.nix
+++ b/pkgs/development/python-modules/oauthlib/3.1.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     py.test tests/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/idan/oauthlib";
     description = "A generic, spec-compliant, thorough implementation of the OAuth request-signing logic";
     maintainers = with maintainers; [ prikhi ];
diff --git a/pkgs/development/python-modules/oauthlib/default.nix b/pkgs/development/python-modules/oauthlib/default.nix
index bc2c8c1094c08..df65547a256d2 100644
--- a/pkgs/development/python-modules/oauthlib/default.nix
+++ b/pkgs/development/python-modules/oauthlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , mock
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     py.test tests/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/idan/oauthlib";
     description = "A generic, spec-compliant, thorough implementation of the OAuth request-signing logic";
     maintainers = with maintainers; [ prikhi ];
diff --git a/pkgs/development/python-modules/obfsproxy/default.nix b/pkgs/development/python-modules/obfsproxy/default.nix
index c320f299ddb1e..1dec57cafb44b 100644
--- a/pkgs/development/python-modules/obfsproxy/default.nix
+++ b/pkgs/development/python-modules/obfsproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , pyptlib
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pluggable transport proxy";
     homepage = "https://www.torproject.org/projects/obfsproxy";
     repositories.git = "https://git.torproject.org/pluggable-transports/obfsproxy.git";
diff --git a/pkgs/development/python-modules/objgraph/default.nix b/pkgs/development/python-modules/objgraph/default.nix
index 79c448b5cced4..8bb119bcb4bfa 100644
--- a/pkgs/development/python-modules/objgraph/default.nix
+++ b/pkgs/development/python-modules/objgraph/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -31,7 +31,7 @@ buildPythonPackage rec {
 
   checkInputs = [ mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Draws Python object reference graphs with graphviz";
     homepage = "https://mg.pov.lt/objgraph/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/offtrac/default.nix b/pkgs/development/python-modules/offtrac/default.nix
index be796b5c37dfb..edec161a133b8 100644
--- a/pkgs/development/python-modules/offtrac/default.nix
+++ b/pkgs/development/python-modules/offtrac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fedorahosted.org/offtrac";
     description = "Trac xmlrpc library";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/ofxclient/default.nix b/pkgs/development/python-modules/ofxclient/default.nix
index 7eb4bef73504f..5ef7060b7f66d 100644
--- a/pkgs/development/python-modules/ofxclient/default.nix
+++ b/pkgs/development/python-modules/ofxclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi,
+{ lib, stdenv, buildPythonPackage, fetchPypi,
  ofxhome, ofxparse, beautifulsoup4, lxml, keyring
 }:
 
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ ofxhome ofxparse beautifulsoup4 lxml keyring ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/captin411/ofxclient";
     description = "OFX client for dowloading transactions from banks";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ofxhome/default.nix b/pkgs/development/python-modules/ofxhome/default.nix
index 518c34951fce8..d9a28da180603 100644
--- a/pkgs/development/python-modules/ofxhome/default.nix
+++ b/pkgs/development/python-modules/ofxhome/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, nose }:
 
 buildPythonPackage rec {
   version = "0.3.3";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # ImportError: No module named tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/captin411/ofxhome";
     description = "ofxhome.com financial institution lookup REST client";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ofxparse/default.nix b/pkgs/development/python-modules/ofxparse/default.nix
index fbdafc291dc5e..235875eec7ce2 100644
--- a/pkgs/development/python-modules/ofxparse/default.nix
+++ b/pkgs/development/python-modules/ofxparse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six beautifulsoup4 lxml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://sites.google.com/site/ofxparse";
     description = "Tools for working with the OFX (Open Financial Exchange) file format";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ofxtools/default.nix b/pkgs/development/python-modules/ofxtools/default.nix
index da087e8b520f6..8f280d1cfd45f 100644
--- a/pkgs/development/python-modules/ofxtools/default.nix
+++ b/pkgs/development/python-modules/ofxtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , nose
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     HOME=$TMPDIR nosetests tests/*.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/csingley/ofxtools";
     description = "Library for working with Open Financial Exchange (OFX) formatted data used by financial institutions";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/olefile/default.nix b/pkgs/development/python-modules/olefile/default.nix
index 5667da7fbc6d4..96c0a0b51bef2 100644
--- a/pkgs/development/python-modules/olefile/default.nix
+++ b/pkgs/development/python-modules/olefile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 buildPythonPackage rec {
   pname = "olefile";
   version = "0.46";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "133b031eaf8fd2c9399b78b8bc5b8fcbe4c31e85295749bb17a87cba8f3c3964";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python package to parse, read and write Microsoft OLE2 files";
     homepage = "https://www.decalage.info/python/olefileio";
     # BSD like + reference to Pillow
diff --git a/pkgs/development/python-modules/omegaconf/default.nix b/pkgs/development/python-modules/omegaconf/default.nix
index 4219aad3865f1..930a036782433 100644
--- a/pkgs/development/python-modules/omegaconf/default.nix
+++ b/pkgs/development/python-modules/omegaconf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
 , pytest, pytestrunner, pyyaml, six, pathlib2, isPy27 }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   buildInputs = [ pytestrunner ];
   propagatedBuildInputs = [ pyyaml six ] ++ stdenv.lib.optional isPy27 pathlib2;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A framework for configuring complex applications";
     homepage = "https://github.com/omry/omegaconf";
     license = licenses.free;  # prior bsd license (1988)
diff --git a/pkgs/development/python-modules/onkyo-eiscp/default.nix b/pkgs/development/python-modules/onkyo-eiscp/default.nix
index 117b8228d2e54..067db3a69fef6 100644
--- a/pkgs/development/python-modules/onkyo-eiscp/default.nix
+++ b/pkgs/development/python-modules/onkyo-eiscp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , docopt, netifaces }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ docopt netifaces ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Control Onkyo receivers over ethernet";
     homepage = "https://github.com/miracle2k/onkyo-eiscp";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/openant/default.nix b/pkgs/development/python-modules/openant/default.nix
index a9598825dd00e..374b7cb059d1e 100644
--- a/pkgs/development/python-modules/openant/default.nix
+++ b/pkgs/development/python-modules/openant/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pyusb
@@ -28,7 +28,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ pyusb ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Tigge/openant";
     description = "ANT and ANT-FS Python Library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/openidc-client/default.nix b/pkgs/development/python-modules/openidc-client/default.nix
index 9cfe714ef6f2b..7d373c13a8a59 100644
--- a/pkgs/development/python-modules/openidc-client/default.nix
+++ b/pkgs/development/python-modules/openidc-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests }:
 
 buildPythonPackage rec {
   pname = "openidc-client";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CLI python OpenID Connect client with token caching and management";
     homepage = "https://github.com/puiterwijk";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/openrazer/common.nix b/pkgs/development/python-modules/openrazer/common.nix
index 67896c362f569..843380ebf21d7 100644
--- a/pkgs/development/python-modules/openrazer/common.nix
+++ b/pkgs/development/python-modules/openrazer/common.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }: rec {
   version = "2.9.0";
@@ -8,7 +8,7 @@
     rev = "v${version}";
     sha256 = "1js7hq7zx5kj99brffrfaaah283ydkffmmrzsxv4mkd3nnd6rykk";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://openrazer.github.io/";
     license = licenses.gpl2;
     maintainers = with maintainers; [ roelvandijk evanjs ];
diff --git a/pkgs/development/python-modules/openrazer/daemon.nix b/pkgs/development/python-modules/openrazer/daemon.nix
index fb7b48e2266fd..6c22d3bae5d08 100644
--- a/pkgs/development/python-modules/openrazer/daemon.nix
+++ b/pkgs/development/python-modules/openrazer/daemon.nix
@@ -1,4 +1,5 @@
-{ buildPythonApplication
+{ lib
+, buildPythonApplication
 , isPy3k
 , daemonize
 , dbus-python
@@ -15,7 +16,7 @@
 }:
 
 let
-  common = import ./common.nix { inherit stdenv fetchFromGitHub; };
+  common = import ./common.nix { inherit stdenv lib fetchFromGitHub; };
 in
 buildPythonApplication (common // rec {
   pname = "openrazer_daemon";
diff --git a/pkgs/development/python-modules/openrazer/pylib.nix b/pkgs/development/python-modules/openrazer/pylib.nix
index 2f9ff467b2d9c..52fe63318a3e9 100644
--- a/pkgs/development/python-modules/openrazer/pylib.nix
+++ b/pkgs/development/python-modules/openrazer/pylib.nix
@@ -1,4 +1,5 @@
-{ buildPythonPackage
+{ lib
+, buildPythonPackage
 , dbus-python
 , fetchFromGitHub
 , numpy
@@ -7,7 +8,7 @@
 }:
 
 let
-  common = import ./common.nix { inherit stdenv fetchFromGitHub; };
+  common = import ./common.nix { inherit stdenv lib fetchFromGitHub; };
 in
 buildPythonPackage (common // rec {
   pname = "openrazer";
diff --git a/pkgs/development/python-modules/opuslib/default.nix b/pkgs/development/python-modules/opuslib/default.nix
index aa7fc4add4935..7db467f26d50a 100644
--- a/pkgs/development/python-modules/opuslib/default.nix
+++ b/pkgs/development/python-modules/opuslib/default.nix
@@ -3,7 +3,7 @@
   isPy27,
   libopus,
   nose,
-  stdenv,
+  lib, stdenv,
   substituteAll,
 }:
 
@@ -29,7 +29,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings to the libopus, IETF low-delay audio codec";
     homepage = "https://github.com/orion-labs/opuslib";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/ordereddict/default.nix b/pkgs/development/python-modules/ordereddict/default.nix
index 9c028777fc9fa..e2931840a66a3 100644
--- a/pkgs/development/python-modules/ordereddict/default.nix
+++ b/pkgs/development/python-modules/ordereddict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "07qvy11nvgxpzarrni3wrww3vpc9yafgi2bch4j2vvvc42nb8d8w";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A drop-in substitute for Py2.7's new collections.OrderedDict that works in Python 2.4-2.6";
     license = licenses.bsd3;
     maintainers = with maintainers; [ ];
diff --git a/pkgs/development/python-modules/orderedmultidict/default.nix b/pkgs/development/python-modules/orderedmultidict/default.nix
index 1a3ab347945aa..7cb4871031b38 100644
--- a/pkgs/development/python-modules/orderedmultidict/default.nix
+++ b/pkgs/development/python-modules/orderedmultidict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, flake8, six, pythonOlder, importlib-metadata }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, flake8, six, pythonOlder, importlib-metadata }:
 
 buildPythonPackage rec {
   pname = "orderedmultidict";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
       importlib-metadata
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ordered Multivalue Dictionary.";
     homepage = "https://github.com/gruns/orderedmultidict";
     license = licenses.publicDomain;
diff --git a/pkgs/development/python-modules/orderedset/default.nix b/pkgs/development/python-modules/orderedset/default.nix
index ac7b21361c97f..aced6cf08536b 100644
--- a/pkgs/development/python-modules/orderedset/default.nix
+++ b/pkgs/development/python-modules/orderedset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "orderedset";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "0abf19w37kxypsj6v7dz79jj92y1kivjk2zivnrv7rw6bbxwrxdj";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Ordered Set implementation in Cython";
     homepage = "https://pypi.python.org/pypi/orderedset";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/osc/default.nix b/pkgs/development/python-modules/osc/default.nix
index cae6a468c7766..dad78727f2d1a 100644
--- a/pkgs/development/python-modules/osc/default.nix
+++ b/pkgs/development/python-modules/osc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, bashInteractive, urlgrabber
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, bashInteractive, urlgrabber
 , m2crypto, rpm, chardet
 }:
 
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     EOF
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/openSUSE/osc";
     description = "opensuse-commander with svn like handling";
     maintainers = [ maintainers.peti ];
diff --git a/pkgs/development/python-modules/osmnx/default.nix b/pkgs/development/python-modules/osmnx/default.nix
index 856c2bb45dbc9..c624e262cf96f 100755
--- a/pkgs/development/python-modules/osmnx/default.nix
+++ b/pkgs/development/python-modules/osmnx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, geopandas, descartes, matplotlib, networkx, numpy
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, geopandas, descartes, matplotlib, networkx, numpy
 , pandas, requests, Rtree, shapely, pytest, coverage, coveralls, folium, scikitlearn, scipy}:
 
 buildPythonPackage rec {
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   #  coverage run --source osmnx -m pytest --verbose
   #'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A package to easily download, construct, project, visualize, and analyze complex street networks from OpenStreetMap with NetworkX.";
     homepage = "https://github.com/gboeing/osmnx";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ovito/default.nix b/pkgs/development/python-modules/ovito/default.nix
index d813d2ac47f37..a33e5d19b44e6 100644
--- a/pkgs/development/python-modules/ovito/default.nix
+++ b/pkgs/development/python-modules/ovito/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , cmake
 , ffmpeg
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = with python.pkgs; [ sphinx numpy sip pyqt5 matplotlib ase ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scientific visualization and analysis software for atomistic simulation data";
     homepage = "https://www.ovito.org";
     license = with licenses; [ gpl3Only mit ];
diff --git a/pkgs/development/python-modules/packaging/2.nix b/pkgs/development/python-modules/packaging/2.nix
index 36764e64b860b..5d841eb4fb137 100644
--- a/pkgs/development/python-modules/packaging/2.nix
+++ b/pkgs/development/python-modules/packaging/2.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyparsing
@@ -31,7 +31,7 @@ buildPythonPackage rec {
   # Prevent circular dependency
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Core utilities for Python packages";
     homepage = "https://github.com/pypa/packaging";
     license = [ licenses.bsd2 licenses.asl20 ];
diff --git a/pkgs/development/python-modules/packaging/default.nix b/pkgs/development/python-modules/packaging/default.nix
index 061e8edaac6fc..973e516f5a90a 100644
--- a/pkgs/development/python-modules/packaging/default.nix
+++ b/pkgs/development/python-modules/packaging/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyparsing
@@ -36,7 +36,7 @@ buildPythonPackage rec {
   # Prevent circular dependency
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Core utilities for Python packages";
     homepage = "https://github.com/pypa/packaging";
     license = [ licenses.bsd2 licenses.asl20 ];
diff --git a/pkgs/development/python-modules/pagelabels/default.nix b/pkgs/development/python-modules/pagelabels/default.nix
index d7adc9b17c043..5daa60f475d3b 100644
--- a/pkgs/development/python-modules/pagelabels/default.nix
+++ b/pkgs/development/python-modules/pagelabels/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pdfrw }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pdfrw }:
 
 buildPythonPackage rec {
   pname = "pagelabels";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # upstream doesn't contain tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library to manipulate PDF page labels.";
     homepage = "https://github.com/lovasoa/pagelabels-py";
     maintainers = with maintainers; [ teto ];
diff --git a/pkgs/development/python-modules/pagerduty/default.nix b/pkgs/development/python-modules/pagerduty/default.nix
index 00236f3c23451..ebe2c8b5854d5 100644
--- a/pkgs/development/python-modules/pagerduty/default.nix
+++ b/pkgs/development/python-modules/pagerduty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "e8c237239d3ffb061069aa04fc5b3d8ae4fb0af16a9713fe0977f02261d323e9";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/samuel/python-pagerduty";
     description = "Library for the PagerDuty service API";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/palettable/default.nix b/pkgs/development/python-modules/palettable/default.nix
index f96e05950b80b..d61973aa3bfa8 100644
--- a/pkgs/development/python-modules/palettable/default.nix
+++ b/pkgs/development/python-modules/palettable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "palettable";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library of color palettes";
     homepage = "https://jiffyclub.github.io/palettable/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pamela/default.nix b/pkgs/development/python-modules/pamela/default.nix
index 9a55719d77f38..40597c36b5890 100644
--- a/pkgs/development/python-modules/pamela/default.nix
+++ b/pkgs/development/python-modules/pamela/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PAM interface using ctypes";
     homepage = "https://github.com/minrk/pamela";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pamqp/default.nix b/pkgs/development/python-modules/pamqp/default.nix
index 8353e8d7895f6..2e8e4500f2476 100644
--- a/pkgs/development/python-modules/pamqp/default.nix
+++ b/pkgs/development/python-modules/pamqp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   buildInputs = [ mock nose pep8 pylint mccabe ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RabbitMQ Focused AMQP low-level library";
     homepage = "https://pypi.python.org/pypi/pamqp";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pandas-datareader/default.nix b/pkgs/development/python-modules/pandas-datareader/default.nix
index 92adfb9d3f16a..c4bf9c140df3b 100644
--- a/pkgs/development/python-modules/pandas-datareader/default.nix
+++ b/pkgs/development/python-modules/pandas-datareader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pandas lxml requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Up to date remote data access for pandas, works for multiple versions of pandas";
     homepage = "https://github.com/pydata/pandas-datareader";
     license= licenses.bsd3;
diff --git a/pkgs/development/python-modules/pandas/default.nix b/pkgs/development/python-modules/pandas/default.nix
index 46348deca8d6d..3db271ee9986a 100644
--- a/pkgs/development/python-modules/pandas/default.nix
+++ b/pkgs/development/python-modules/pandas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -134,7 +134,7 @@ in buildPythonPackage rec {
     export PATH=$(pwd):$PATH
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     # https://github.com/pandas-dev/pandas/issues/14866
     # pandas devs are no longer testing i686 so safer to assume it's broken
     broken = stdenv.isi686;
diff --git a/pkgs/development/python-modules/pandocfilters/default.nix b/pkgs/development/python-modules/pandocfilters/default.nix
index 848e59313af96..d31bc2657c934 100644
--- a/pkgs/development/python-modules/pandocfilters/default.nix
+++ b/pkgs/development/python-modules/pandocfilters/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests available
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python module for writing pandoc filters, with a collection of examples";
     homepage = "https://github.com/jgm/pandocfilters";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/paperspace/default.nix b/pkgs/development/python-modules/paperspace/default.nix
index fad394a5339bc..4553b253819f1 100644
--- a/pkgs/development/python-modules/paperspace/default.nix
+++ b/pkgs/development/python-modules/paperspace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , boto3, requests, gradient_statsd, terminaltables
 , click-completion , click-didyoumean, click-help-colors
 , colorama, requests_toolbelt, gradient_sdk, progressbar2
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # tries to use /homeless-shelter to mimic container usage, etc
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python API for Paperspace Cloud";
     homepage    = "https://paperspace.com";
     license     = licenses.isc;
diff --git a/pkgs/development/python-modules/parameterized/default.nix b/pkgs/development/python-modules/parameterized/default.nix
index 77529c059afde..16925bd1286b8 100644
--- a/pkgs/development/python-modules/parameterized/default.nix
+++ b/pkgs/development/python-modules/parameterized/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, nose, mock, glibcLocales, isPy3k, isPy38 }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, nose, mock, glibcLocales, isPy3k, isPy38 }:
 
 buildPythonPackage rec {
   pname = "parameterized";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     LC_ALL="en_US.UTF-8" nosetests -v
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parameterized testing with any Python test framework";
     homepage = "https://pypi.python.org/pypi/parameterized";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/paramz/default.nix b/pkgs/development/python-modules/paramz/default.nix
index 63014647880de..65cc79745caa3 100644
--- a/pkgs/development/python-modules/paramz/default.nix
+++ b/pkgs/development/python-modules/paramz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, numpy, scipy, six, decorator, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, numpy, scipy, six, decorator, nose }:
 
 buildPythonPackage rec {
   pname = "paramz";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
       nosetests -v paramz/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parameterization framework for parameterized model creation and handling";
     homepage = "https://github.com/sods/paramz";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/parse-type/default.nix b/pkgs/development/python-modules/parse-type/default.nix
index cbf4ee0836e48..e787c65fc1180 100644
--- a/pkgs/development/python-modules/parse-type/default.nix
+++ b/pkgs/development/python-modules/parse-type/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi
+{ lib, stdenv, fetchPypi
 , buildPythonPackage, pythonOlder
 , pytest, pytestrunner
 , parse, six, enum34
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jenisys/parse_type";
     description = "Simplifies to build parse types based on the parse module";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/parse/default.nix b/pkgs/development/python-modules/parse/default.nix
index 7b160237d5ebf..d72e607bc4108 100644
--- a/pkgs/development/python-modules/parse/default.nix
+++ b/pkgs/development/python-modules/parse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi
+{ lib, stdenv, fetchPypi
 , buildPythonPackage, python
 }:
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     ${python.interpreter} test_parse.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/r1chardj0n3s/parse";
     description = "parse() is the opposite of format()";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/parsedatetime/default.nix b/pkgs/development/python-modules/parsedatetime/default.nix
index 0b7d5cd6fb4c2..1f98940fff065 100644
--- a/pkgs/development/python-modules/parsedatetime/default.nix
+++ b/pkgs/development/python-modules/parsedatetime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   buildInputs = [ pytest pytestrunner ];
   propagatedBuildInputs = [ future ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parse human-readable date/time text";
     homepage = "https://github.com/bear/parsedatetime";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/parsimonious/default.nix b/pkgs/development/python-modules/parsimonious/default.nix
index 25d87a7f2f1fd..d41953246db95 100644
--- a/pkgs/development/python-modules/parsimonious/default.nix
+++ b/pkgs/development/python-modules/parsimonious/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # performance tests tend to fail sometimes
   NOSE_EXCLUDE = "test_benchmarks";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/erikrose/parsimonious";
     description = "Fast arbitrary-lookahead parser written in pure Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/paste/default.nix b/pkgs/development/python-modules/paste/default.nix
index 6bed8144a21eb..a29deed503ed7 100644
--- a/pkgs/development/python-modules/paste/default.nix
+++ b/pkgs/development/python-modules/paste/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     py.test -k "not test_cgiapp and not test_proxy"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for using a Web Server Gateway Interface stack";
     homepage = "http://pythonpaste.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pastedeploy/default.nix b/pkgs/development/python-modules/pastedeploy/default.nix
index 21149da917f18..950b232fa7e45 100644
--- a/pkgs/development/python-modules/pastedeploy/default.nix
+++ b/pkgs/development/python-modules/pastedeploy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestrunner
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # should be included with versions > 2.0.1
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Load, configure, and compose WSGI applications and servers";
     homepage = "http://pythonpaste.org/deploy/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pastescript/default.nix b/pkgs/development/python-modules/pastescript/default.nix
index ce012c3d102aa..57dbb7b9352e1 100644
--- a/pkgs/development/python-modules/pastescript/default.nix
+++ b/pkgs/development/python-modules/pastescript/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pluggable command-line frontend, including commands to setup package file layouts";
     homepage = "https://github.com/cdent/pastescript/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/patator/default.nix b/pkgs/development/python-modules/patator/default.nix
index b876e913e3cf0..96ed85d7bcee4 100644
--- a/pkgs/development/python-modules/patator/default.nix
+++ b/pkgs/development/python-modules/patator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy27, fetchPypi
+{ lib, stdenv, buildPythonPackage, isPy27, fetchPypi
 , paramiko, pycurl, ajpy, impacket, pyopenssl, cx_oracle, mysqlclient
 , psycopg2, pycrypto, dnspython, ipy, pysnmp, pyasn1, pysqlcipher3 }:
 
@@ -38,7 +38,7 @@ buildPythonPackage rec {
   # tests require docker-compose and vagrant
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "multi-purpose brute-forcer";
     homepage = "https://github.com/lanjelot/patator";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/patch-ng/default.nix b/pkgs/development/python-modules/patch-ng/default.nix
index 7cab25707984c..981dc067fe7e6 100644
--- a/pkgs/development/python-modules/patch-ng/default.nix
+++ b/pkgs/development/python-modules/patch-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1kja1nn08w0k8k6j4kad48k581hh9drvjjb8x60v9j13sxdvqyk2";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library to parse and apply unified diffs.";
     homepage = "https://github.com/conan-io/python-patch";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/patch/default.nix b/pkgs/development/python-modules/patch/default.nix
index a4af8319f622e..8d7e78c6c27ca 100644
--- a/pkgs/development/python-modules/patch/default.nix
+++ b/pkgs/development/python-modules/patch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchzip
 }:
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # No tests included in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library to parse and apply unified diffs";
     homepage = "https://github.com/techtonik/python-patch/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/path-and-address/default.nix b/pkgs/development/python-modules/path-and-address/default.nix
index f30a6ddd40833..9512b0eb0b88a 100644
--- a/pkgs/development/python-modules/path-and-address/default.nix
+++ b/pkgs/development/python-modules/path-and-address/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pytest
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Functions for server CLI applications used by humans";
     homepage = "https://github.com/joeyespo/path-and-address";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pathos/default.nix b/pkgs/development/python-modules/pathos/default.nix
index 2b9134750fe2f..7780709060225 100644
--- a/pkgs/development/python-modules/pathos/default.nix
+++ b/pkgs/development/python-modules/pathos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , dill
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # Require network
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parallel graph management and execution in heterogeneous computing";
     homepage = "https://github.com/uqfoundation/pathos/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pathtools/default.nix b/pkgs/development/python-modules/pathtools/default.nix
index 75901743c7e46..57fff82a81d77 100644
--- a/pkgs/development/python-modules/pathtools/default.nix
+++ b/pkgs/development/python-modules/pathtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1h7iam33vwxk8bvslfj4qlsdprdnwf8bvzhqh3jq5frr391cadbw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pattern matching and various utilities for file systems paths";
     homepage = "https://github.com/gorakhargosh/pathtools";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/paver/default.nix b/pkgs/development/python-modules/paver/default.nix
index ec4a40fec1b4e..5d01df22b6d5a 100644
--- a/pkgs/development/python-modules/paver/default.nix
+++ b/pkgs/development/python-modules/paver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # the tests do not pass
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python-based build/distribution/deployment scripting tool";
     homepage    = "https://github.com/paver/paver";
     maintainers = with maintainers; [ lovek323 ];
diff --git a/pkgs/development/python-modules/pbkdf2/default.nix b/pkgs/development/python-modules/pbkdf2/default.nix
index c83cada08f2ea..18a2b9b95a3a1 100644
--- a/pkgs/development/python-modules/pbkdf2/default.nix
+++ b/pkgs/development/python-modules/pbkdf2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pbkdf2";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # ImportError: No module named test
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ domenkozar ];
   };
 }
diff --git a/pkgs/development/python-modules/pc-ble-driver-py/default.nix b/pkgs/development/python-modules/pc-ble-driver-py/default.nix
index e85df06b50021..6a12eea1b00c6 100644
--- a/pkgs/development/python-modules/pc-ble-driver-py/default.nix
+++ b/pkgs/development/python-modules/pc-ble-driver-py/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, git, swig, boost, udev, pc-ble-driver, pythonOlder
+{ lib, stdenv, fetchFromGitHub, cmake, git, swig, boost, udev, pc-ble-driver, pythonOlder
 , buildPythonPackage, enum34, wrapt, future, setuptools, scikit-build, pythonAtLeast }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   dontUseCmakeConfigure = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bluetooth Low Energy nRF5 SoftDevice serialization";
     homepage = "https://github.com/NordicSemiconductor/pc-ble-driver-py";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/development/python-modules/pcpp/default.nix b/pkgs/development/python-modules/pcpp/default.nix
index f57798c40a84e..aea7ff0fcdaf2 100644
--- a/pkgs/development/python-modules/pcpp/default.nix
+++ b/pkgs/development/python-modules/pcpp/default.nix
@@ -1,6 +1,6 @@
 { buildPythonPackage
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     fetchSubmodules = true;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ned14/pcpp";
     description = "A C99 preprocessor written in pure Python";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pdf2image/default.nix b/pkgs/development/python-modules/pdf2image/default.nix
index b9342821b209c..adc43ef4c2edc 100644
--- a/pkgs/development/python-modules/pdf2image/default.nix
+++ b/pkgs/development/python-modules/pdf2image/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pillow, poppler_utils }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pillow, poppler_utils }:
 
 buildPythonPackage rec {
   pname = "pdf2image";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
     sha256 = "066527e1bf954762fb4369c677ae3bc15f2ce8707eee830cccef8471fde736d7";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python module that wraps the pdftoppm utility to convert PDF to PIL Image object";
     homepage = "https://github.com/Belval/pdf2image";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pdfkit/default.nix b/pkgs/development/python-modules/pdfkit/default.nix
index dc9d33ddf0df6..10bc09e8ca92b 100644
--- a/pkgs/development/python-modules/pdfkit/default.nix
+++ b/pkgs/development/python-modules/pdfkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # tests are not distributed
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/pdfkit";
     description = "Wkhtmltopdf python wrapper to convert html to pdf using the webkit rendering engine and qt";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pdfminer_six/default.nix b/pkgs/development/python-modules/pdfminer_six/default.nix
index 9bc8f89157017..9a659eebe3301 100644
--- a/pkgs/development/python-modules/pdfminer_six/default.nix
+++ b/pkgs/development/python-modules/pdfminer_six/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy3k, cryptography, chardet, nose, sortedcontainers }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy3k, cryptography, chardet, nose, sortedcontainers }:
 
 buildPythonPackage rec {
   pname = "pdfminer_six";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PDF parser and analyzer";
     homepage = "https://github.com/pdfminer/pdfminer.six";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pdfposter/default.nix b/pkgs/development/python-modules/pdfposter/default.nix
index 43e2f1f57f752..0a21ed1e4999b 100644
--- a/pkgs/development/python-modules/pdfposter/default.nix
+++ b/pkgs/development/python-modules/pdfposter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pypdf2 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pypdf2 }:
 
 buildPythonPackage rec {
   pname = "pdftools.pdfposter";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
     sha256 = "0c1avpbr9q53yzq5ar2x485rmp9d0l3z27aham32bg7gplzd7w0j";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Split large pages of a PDF into smaller ones for poster printing";
     homepage = "https://pdfposter.readthedocs.io";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/pdfrw/default.nix b/pkgs/development/python-modules/pdfrw/default.nix
index 15b8a8dc8d6b4..49abb3751c910 100644
--- a/pkgs/development/python-modules/pdfrw/default.nix
+++ b/pkgs/development/python-modules/pdfrw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pdfrw";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # tests require the extra download of github.com/pmaupin/static_pdfs
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "pdfrw is a pure Python library that reads and writes PDFs.";
     homepage = "https://github.com/pmaupin/pdfrw";
     maintainers = with maintainers; [ teto ];
diff --git a/pkgs/development/python-modules/pdfx/default.nix b/pkgs/development/python-modules/pdfx/default.nix
index d2397fb5c82bd..97dee7e75705d 100644
--- a/pkgs/development/python-modules/pdfx/default.nix
+++ b/pkgs/development/python-modules/pdfx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pdfminer, chardet, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pdfminer, chardet, pytest }:
 
 buildPythonPackage rec {
   pname = "pdfx";
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Extract references (pdf, url, doi, arxiv) and metadata from a PDF";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pecan/default.nix b/pkgs/development/python-modules/pecan/default.nix
index 332f5153a9811..7303a9b15045d 100644
--- a/pkgs/development/python-modules/pecan/default.nix
+++ b/pkgs/development/python-modules/pecan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , isPy27
@@ -51,7 +51,7 @@ buildPythonPackage rec {
     "--pyargs pecan "
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pecan";
     homepage = "http://www.pecanpy.org/";
     changelog = "https://pecan.readthedocs.io/en/latest/changes.html";
diff --git a/pkgs/development/python-modules/pelican/default.nix b/pkgs/development/python-modules/pelican/default.nix
index 30d6546d5705b..0b103b780c085 100644
--- a/pkgs/development/python-modules/pelican/default.nix
+++ b/pkgs/development/python-modules/pelican/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy27
 , glibcLocales, git
 , mock, nose, markdown, lxml, typogrify
 , jinja2, pygments, docutils, pytz, unidecode, six, dateutil, feedgenerator
@@ -67,7 +67,7 @@ buildPythonPackage rec {
     patchShebangs $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to generate a static blog from reStructuredText or Markdown input files";
     homepage = "http://getpelican.com/";
     license = licenses.agpl3;
diff --git a/pkgs/development/python-modules/pep257/default.nix b/pkgs/development/python-modules/pep257/default.nix
index 8f3a1e0ea8bd6..296b55eec125f 100644
--- a/pkgs/development/python-modules/pep257/default.nix
+++ b/pkgs/development/python-modules/pep257/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchurl, pytest, mock }:
+{ lib, stdenv, buildPythonPackage, fetchurl, pytest, mock }:
 buildPythonPackage rec {
   pname = "pep257";
   version = "0.7.0";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/GreenSteam/pep257/";
     description = "Python docstring style checker";
     longDescription = "Static analysis tool for checking compliance with Python PEP 257.";
diff --git a/pkgs/development/python-modules/pep8/default.nix b/pkgs/development/python-modules/pep8/default.nix
index 12176b97380dd..8ef3bfea0f5df 100644
--- a/pkgs/development/python-modules/pep8/default.nix
+++ b/pkgs/development/python-modules/pep8/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # FAIL: test_checkers_testsuite (testsuite.test_all.Pep8TestCase)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pep8.readthedocs.org/";
     description = "Python style guide checker";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/peppercorn/default.nix b/pkgs/development/python-modules/peppercorn/default.nix
index 51114a591a57c..6caf61b0cd0d8 100644
--- a/pkgs/development/python-modules/peppercorn/default.nix
+++ b/pkgs/development/python-modules/peppercorn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1ip4bfwcpwkq9hz2dai14k2cyabvwrnvcvrcmzxmqm04g8fnimwn";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for converting a token stream into a data structure for use in web form posts";
     homepage = "https://docs.pylonsproject.org/projects/peppercorn/en/latest/";
     maintainers = with maintainers; [ domenkozar ];
diff --git a/pkgs/development/python-modules/persisting-theory/default.nix b/pkgs/development/python-modules/persisting-theory/default.nix
index ca14f80868c8c..86bae927d9ff7 100644
--- a/pkgs/development/python-modules/persisting-theory/default.nix
+++ b/pkgs/development/python-modules/persisting-theory/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose
 }:
 
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   checkPhase = "nosetests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://code.eliotberriot.com/eliotberriot/persisting-theory";
     description = "Automate data discovering and access inside a list of packages";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pex/default.nix b/pkgs/development/python-modules/pex/default.nix
index 0bbbf551f2804..1d7de0088a844 100644
--- a/pkgs/development/python-modules/pex/default.nix
+++ b/pkgs/development/python-modules/pex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # A few more dependencies I don't want to handle right now...
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library and tool for generating .pex (Python EXecutable) files";
     homepage = "https://github.com/pantsbuild/pex";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pexif/default.nix b/pkgs/development/python-modules/pexif/default.nix
index f3086b6b05530..326dde176ae61 100644
--- a/pkgs/development/python-modules/pexif/default.nix
+++ b/pkgs/development/python-modules/pexif/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "45a3be037c7ba8b64bbfc48f3586402cc17de55bb9d7357ef2bc99954a18da3f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A module for editing JPEG EXIF data";
     homepage = "http://www.benno.id.au/code/pexif/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pg8000/1_12.nix b/pkgs/development/python-modules/pg8000/1_12.nix
index bc4ff9f4f0318..d84bb2014b804 100644
--- a/pkgs/development/python-modules/pg8000/1_12.nix
+++ b/pkgs/development/python-modules/pg8000/1_12.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytz
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pytz six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tlocke/pg8000";
     description = "PostgreSQL interface library, for asyncio";
     maintainers = with maintainers; [ domenkozar ];
diff --git a/pkgs/development/python-modules/pg8000/default.nix b/pkgs/development/python-modules/pg8000/default.nix
index 0c94597721869..8f63e00e7997f 100644
--- a/pkgs/development/python-modules/pg8000/default.nix
+++ b/pkgs/development/python-modules/pg8000/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , scramp
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ passlib scramp ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tlocke/pg8000";
     description = "PostgreSQL interface library, for asyncio";
     maintainers = with maintainers; [ domenkozar ];
diff --git a/pkgs/development/python-modules/pgpdump/default.nix b/pkgs/development/python-modules/pgpdump/default.nix
index 0f200409622a8..d795cc3678f73 100644
--- a/pkgs/development/python-modules/pgpdump/default.nix
+++ b/pkgs/development/python-modules/pgpdump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Disabling check because of: https://github.com/toofishes/python-pgpdump/issues/18
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for parsing PGP packets";
     homepage = "https://github.com/toofishes/python-pgpdump";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pgsanity/default.nix b/pkgs/development/python-modules/pgsanity/default.nix
index f7212493e59c6..b95f461aa3701 100644
--- a/pkgs/development/python-modules/pgsanity/default.nix
+++ b/pkgs/development/python-modules/pgsanity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python
 , fetchPypi
 , buildPythonPackage
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   checkInputs = [ postgresql ];
   propagatedBuildInputs = [ postgresql ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/markdrago/pgsanity";
     description = "Checks the syntax of Postgresql SQL files";
     longDescription = ''
diff --git a/pkgs/development/python-modules/pgspecial/default.nix b/pkgs/development/python-modules/pgspecial/default.nix
index 61ab5532ca9d2..796a38198814b 100644
--- a/pkgs/development/python-modules/pgspecial/default.nix
+++ b/pkgs/development/python-modules/pgspecial/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, psycopg2, click, sqlparse }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, psycopg2, click, sqlparse }:
 
 buildPythonPackage rec {
   pname = "pgspecial";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Meta-commands handler for Postgres Database";
     homepage = "https://pypi.python.org/pypi/pgspecial";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/phe/default.nix b/pkgs/development/python-modules/phe/default.nix
index 6a849734e9086..5a00a4ccb099c 100644
--- a/pkgs/development/python-modules/phe/default.nix
+++ b/pkgs/development/python-modules/phe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPyPy, isPy3k, click, gmpy2, numpy } :
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPyPy, isPy3k, click, gmpy2, numpy } :
 
 let
   pname = "phe";
@@ -21,7 +21,7 @@ buildPythonPackage {
   # 29/233 tests fail
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for Partially Homomorphic Encryption in Python";
     homepage = "https://github.com/n1analytics/python-paillier";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/phonopy/default.nix b/pkgs/development/python-modules/phonopy/default.nix
index 1a768b7cf57fc..03e0c54caab76 100644
--- a/pkgs/development/python-modules/phonopy/default.nix
+++ b/pkgs/development/python-modules/phonopy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, python, fetchPypi, numpy, pyyaml, matplotlib, h5py, spglib, pytestCheckHook }:
+{ lib, stdenv, buildPythonPackage, python, fetchPypi, numpy, pyyaml, matplotlib, h5py, spglib, pytestCheckHook }:
 
 buildPythonPackage rec {
   pname = "phonopy";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     rm -r phonopy
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A package for phonon calculations at harmonic and quasi-harmonic levels";
     homepage = "https://atztogo.github.io/phonopy/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/phx-class-registry/default.nix b/pkgs/development/python-modules/phx-class-registry/default.nix
index db0359a1d4fc0..9ed84e86371ce 100644
--- a/pkgs/development/python-modules/phx-class-registry/default.nix
+++ b/pkgs/development/python-modules/phx-class-registry/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, pytestCheckHook }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, pytestCheckHook }:
 
 buildPythonPackage rec {
   pname = "phx-class-registry";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     "test_len"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Registry pattern for Python classes, with setuptools entry points integration";
     homepage = "https://github.com/todofixthis/class-registry";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pickleshare/default.nix b/pkgs/development/python-modules/pickleshare/default.nix
index 496d20d52e3c1..0171adc6bfcca 100644
--- a/pkgs/development/python-modules/pickleshare/default.nix
+++ b/pkgs/development/python-modules/pickleshare/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pathpy
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # No proper test suite
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiny 'shelve'-like database with concurrency support";
     homepage = "https://github.com/vivainio/pickleshare";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pid/default.nix b/pkgs/development/python-modules/pid/default.nix
index e934ea4577b4b..95aca29da5d10 100644
--- a/pkgs/development/python-modules/pid/default.nix
+++ b/pkgs/development/python-modules/pid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pidfile featuring stale detection and file-locking";
     homepage = "https://github.com/trbs/pid/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/piep/default.nix b/pkgs/development/python-modules/piep/default.nix
index 667a8e3b73711..c4fd24d070e62 100644
--- a/pkgs/development/python-modules/piep/default.nix
+++ b/pkgs/development/python-modules/piep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ pygments ];
   checkInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bringing the power of python to stream editing";
     homepage = "https://github.com/timbertson/piep";
     maintainers = with maintainers; [ timbertson ];
diff --git a/pkgs/development/python-modules/piexif/default.nix b/pkgs/development/python-modules/piexif/default.nix
index af4b539d4574b..c08ee8338b0a9 100644
--- a/pkgs/development/python-modules/piexif/default.nix
+++ b/pkgs/development/python-modules/piexif/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pillow }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pillow }:
 
 buildPythonPackage rec {
   pname = "piexif";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     sha256 = "06sz58q4mrw472p8fbnq7wsj8zpi5js5r8phm2hiwfmz0v33bjw3";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simplify Exif manipulations with Python";
     homepage = "https://github.com/hMatoba/Piexif";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pika-pool/default.nix b/pkgs/development/python-modules/pika-pool/default.nix
index c13490fb3e805..a36fcdf18bb58 100644
--- a/pkgs/development/python-modules/pika-pool/default.nix
+++ b/pkgs/development/python-modules/pika-pool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pika
 }:
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   doCheck = false;
 
   propagatedBuildInputs = [ pika ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bninja/pika-pool";
     license = licenses.bsdOriginal;
     description = "Pools for pikas.";
diff --git a/pkgs/development/python-modules/pika/default.nix b/pkgs/development/python-modules/pika/default.nix
index 8b0807e3569b6..ec8310bdb55f7 100644
--- a/pkgs/development/python-modules/pika/default.nix
+++ b/pkgs/development/python-modules/pika/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose mock twisted tornado ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure-Python implementation of the AMQP 0-9-1 protocol";
     homepage = "https://pika.readthedocs.org";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pikepdf/default.nix b/pkgs/development/python-modules/pikepdf/default.nix
index a5f512fae97fa..ff2a2ce4c5e7a 100644
--- a/pkgs/development/python-modules/pikepdf/default.nix
+++ b/pkgs/development/python-modules/pikepdf/default.nix
@@ -18,7 +18,7 @@
 , qpdf
 , setuptools-scm-git-archive
 , setuptools_scm
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -68,7 +68,7 @@ buildPythonPackage rec {
     HOME=$TMPDIR
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pikepdf/pikepdf";
     description = "Read and write PDFs with Python, powered by qpdf";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/pilkit/default.nix b/pkgs/development/python-modules/pilkit/default.nix
index 019d5551a3a68..4a3c682c1229a 100644
--- a/pkgs/development/python-modules/pilkit/default.nix
+++ b/pkgs/development/python-modules/pilkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pillow
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pillow nose_progressive nose mock blessings ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/matthewwithanm/pilkit/";
     description = "A collection of utilities and processors for the Python Imaging Libary";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pillow/6.nix b/pkgs/development/python-modules/pillow/6.nix
index 64f162c24eb7b..ce28b19a013e7 100644
--- a/pkgs/development/python-modules/pillow/6.nix
+++ b/pkgs/development/python-modules/pillow/6.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPyPy
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPyPy
 , olefile
 , freetype, libjpeg, zlib, libtiff, libwebp, tcl, lcms2, tk, libX11
 , openjpeg, libimagequant
@@ -67,7 +67,7 @@ buildPythonPackage rec {
       --replace '"/System/Library/Frameworks"' ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://python-pillow.github.io/";
     description = "Fork of The Python Imaging Library (PIL)";
     longDescription = ''
diff --git a/pkgs/development/python-modules/pillow/default.nix b/pkgs/development/python-modules/pillow/default.nix
index 199bdae8fc257..1122d21b5340a 100644
--- a/pkgs/development/python-modules/pillow/default.nix
+++ b/pkgs/development/python-modules/pillow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPyPy
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPyPy
 , olefile
 , freetype, libjpeg, zlib, libtiff, libwebp, tcl, lcms2, tk, libX11
 , openjpeg, libimagequant
@@ -67,7 +67,7 @@ buildPythonPackage rec {
       --replace '"/System/Library/Frameworks"' ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://python-pillow.org/";
     description = "The friendly PIL fork (Python Imaging Library)";
     longDescription = ''
diff --git a/pkgs/development/python-modules/pillowfight/default.nix b/pkgs/development/python-modules/pillowfight/default.nix
index ed0daf123d469..9e23f69d19c5d 100644
--- a/pkgs/development/python-modules/pillowfight/default.nix
+++ b/pkgs/development/python-modules/pillowfight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pillow
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pillow ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Eases the transition from PIL to Pillow for Python packages";
     homepage = "https://github.com/beanbaginc/pillowfight";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pims/default.nix b/pkgs/development/python-modules/pims/default.nix
index 76eaa4fac698e..d2a5641acff5e 100644
--- a/pkgs/development/python-modules/pims/default.nix
+++ b/pkgs/development/python-modules/pims/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , slicerator
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # not everything packaged with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/soft-matter/pims";
     description = "Python Image Sequence: Load video and sequential images in many formats with a simple, consistent interface";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/pip-tools/default.nix b/pkgs/development/python-modules/pip-tools/default.nix
index 0952c7056c316..398ab8cd29be9 100644
--- a/pkgs/development/python-modules/pip-tools/default.nix
+++ b/pkgs/development/python-modules/pip-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pip, pytest, click, six
+{ lib, stdenv, fetchPypi, buildPythonPackage, pip, pytest, click, six
 , setuptools_scm, git, glibcLocales, mock }:
 
 buildPythonPackage rec {
@@ -42,7 +42,7 @@ buildPythonPackage rec {
     py.test -k "${disabledTests}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Keeps your pinned dependencies fresh";
     homepage = "https://github.com/jazzband/pip-tools/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pivy/default.nix b/pkgs/development/python-modules/pivy/default.nix
index 3d3f93f21a27d..aae90d2f8b496 100644
--- a/pkgs/development/python-modules/pivy/default.nix
+++ b/pkgs/development/python-modules/pivy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pkgs, qtbase, qmake, soqt }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pkgs, qtbase, qmake, soqt }:
 
 buildPythonPackage rec {
   pname = "pivy";
@@ -38,7 +38,7 @@ buildPythonPackage rec {
       \$'{Coin_INCLUDE_DIR}'\;\$'{SoQt_INCLUDE_DIRS}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/coin3d/pivy/";
     description = "A Python binding for Coin";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pkginfo/default.nix b/pkgs/development/python-modules/pkginfo/default.nix
index 7a0fc20807024..dbf487c5d3aa0 100644
--- a/pkgs/development/python-modules/pkginfo/default.nix
+++ b/pkgs/development/python-modules/pkginfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pkginfo";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false; # I don't know why, but with doCheck = true it fails.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/pkginfo";
     license = licenses.mit;
     description = "Query metadatdata from sdists / bdists / installed packages";
diff --git a/pkgs/development/python-modules/pkuseg/default.nix b/pkgs/development/python-modules/pkuseg/default.nix
index 3b1c2bd5bce4d..8e3e301793aae 100644
--- a/pkgs/development/python-modules/pkuseg/default.nix
+++ b/pkgs/development/python-modules/pkuseg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "pkuseg" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Toolkit for multi-domain Chinese word segmentation";
     homepage = "https://github.com/lancopku/pkuseg-python";
     license = licenses.unfree;
diff --git a/pkgs/development/python-modules/plac/default.nix b/pkgs/development/python-modules/plac/default.nix
index dbcd7f2130088..9e2c66d9d1edf 100644
--- a/pkgs/development/python-modules/plac/default.nix
+++ b/pkgs/development/python-modules/plac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -17,7 +17,7 @@ buildPythonPackage rec {
       ${python.interpreter} -m unittest discover -p "*test_plac*"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parsing the Command Line the Easy Way";
     homepage = "https://github.com/micheles/plac";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/pluginbase/default.nix b/pkgs/development/python-modules/pluginbase/default.nix
index c35fbf7bd13ae..956ea1b720aef 100644
--- a/pkgs/development/python-modules/pluginbase/default.nix
+++ b/pkgs/development/python-modules/pluginbase/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pytest }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pytest }:
 
 buildPythonPackage rec {
   version = "1.0.0";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     PYTHONPATH=.. pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mitsuhiko/pluginbase";
     description = "A support library for building plugins sytems in Python";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/plyvel/default.nix b/pkgs/development/python-modules/plyvel/default.nix
index c768c606ca8a5..0872a53476047 100644
--- a/pkgs/development/python-modules/plyvel/default.nix
+++ b/pkgs/development/python-modules/plyvel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # no tests for python2
   doCheck = isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and feature-rich Python interface to LevelDB";
     platforms = platforms.unix;
     homepage = "https://github.com/wbolster/plyvel";
diff --git a/pkgs/development/python-modules/pocket/default.nix b/pkgs/development/python-modules/pocket/default.nix
index e351d26ca4815..3599d3dec55d6 100644
--- a/pkgs/development/python-modules/pocket/default.nix
+++ b/pkgs/development/python-modules/pocket/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wrapper for the pocket API";
     homepage    = "https://github.com/tapanpandita/pocket";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/polib/default.nix b/pkgs/development/python-modules/polib/default.nix
index 304ef95a88463..f7c4e1139a867 100644
--- a/pkgs/development/python-modules/polib/default.nix
+++ b/pkgs/development/python-modules/polib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "polib";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library to manipulate gettext files (po and mo files)";
     homepage = "https://bitbucket.org/izi/polib/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pomegranate/default.nix b/pkgs/development/python-modules/pomegranate/default.nix
index c3d5638841d60..7595730eb31b7 100644
--- a/pkgs/development/python-modules/pomegranate/default.nix
+++ b/pkgs/development/python-modules/pomegranate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, numpy, scipy, cython, networkx, joblib, nose, pyyaml }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, numpy, scipy, cython, networkx, joblib, nose, pyyaml }:
 
 buildPythonPackage rec {
   pname = "pomegranate";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Probabilistic and graphical models for Python, implemented in cython for speed";
     homepage = "https://github.com/jmschrei/pomegranate";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pony/default.nix b/pkgs/development/python-modules/pony/default.nix
index 1ed0a7cafffb0..7a734927ee1e0 100644
--- a/pkgs/development/python-modules/pony/default.nix
+++ b/pkgs/development/python-modules/pony/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, python, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pony";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     rm -rf $out/${python.sitePackages}/pony/orm/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pony is a Python ORM with beautiful query syntax";
     homepage = "https://ponyorm.org/";
     maintainers = with maintainers; [ d-goldin xvapx ];
diff --git a/pkgs/development/python-modules/pooch/default.nix b/pkgs/development/python-modules/pooch/default.nix
index 6530cbd4a5d1b..282239d9890bd 100644
--- a/pkgs/development/python-modules/pooch/default.nix
+++ b/pkgs/development/python-modules/pooch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy27
 , fetchPypi
@@ -40,7 +40,7 @@ buildPythonPackage rec {
     "integration"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A friend to fetch your data files.";
     homepage = "https://github.com/fatiando/pooch";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/poppler-qt5/default.nix b/pkgs/development/python-modules/poppler-qt5/default.nix
index 6f12a9e69810b..cd2aac6275e58 100644
--- a/pkgs/development/python-modules/poppler-qt5/default.nix
+++ b/pkgs/development/python-modules/poppler-qt5/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchPypi, stdenv, sip, qtbase, pyqt5, poppler, pkgconfig, fetchpatch
+{ buildPythonPackage, fetchPypi, lib, stdenv, sip, qtbase, pyqt5, poppler, pkgconfig, fetchpatch
 , substituteAll
 }:
 
@@ -34,7 +34,7 @@ buildPythonPackage rec {
   # no tests, just bindings for `poppler_qt5`
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/wbsoft/python-poppler-qt5";
     license = licenses.gpl2;
     maintainers = with maintainers; [ ];
diff --git a/pkgs/development/python-modules/portend/default.nix b/pkgs/development/python-modules/portend/default.nix
index 280cadf4db4ea..10b30d05fa3ea 100644
--- a/pkgs/development/python-modules/portend/default.nix
+++ b/pkgs/development/python-modules/portend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, setuptools_scm, tempora, pytest-black, pytestcov }:
 
 buildPythonPackage rec {
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   # Some of the tests use localhost networking.
   __darwinAllowLocalNetworking = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Monitor TCP ports for bound or unbound states";
     homepage = "https://github.com/jaraco/portend";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/posix_ipc/default.nix b/pkgs/development/python-modules/posix_ipc/default.nix
index 2be2a89cc6da5..2fb6128dc1b12 100644
--- a/pkgs/development/python-modules/posix_ipc/default.nix
+++ b/pkgs/development/python-modules/posix_ipc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "6cddb1ce2cf4aae383f2a0079c26c69bee257fe2720f372201ef047f8ceb8b97";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "POSIX IPC primitives (semaphores, shared memory and message queues)";
     license = licenses.bsd3;
     homepage = "http://semanchuk.com/philip/posix_ipc/";
diff --git a/pkgs/development/python-modules/potr/default.nix b/pkgs/development/python-modules/potr/default.nix
index adcb71104676e..9f2774b9a6077 100644
--- a/pkgs/development/python-modules/potr/default.nix
+++ b/pkgs/development/python-modules/potr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pycrypto }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pycrypto }:
 
 buildPythonPackage rec {
   pname = "python-potr";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pycrypto ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure Python OTR implementation";
     homepage = "http://python-otr.pentabarf.de/";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/power/default.nix b/pkgs/development/python-modules/power/default.nix
index b3d750f7e6526..d1998faf6b640 100644
--- a/pkgs/development/python-modules/power/default.nix
+++ b/pkgs/development/python-modules/power/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Tests can't work because there is no power information available.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform system power status information";
     homepage = "https://github.com/Kentzo/Power";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pox/default.nix b/pkgs/development/python-modules/pox/default.nix
index e4869a8f46cc7..e7013154f9988 100644
--- a/pkgs/development/python-modules/pox/default.nix
+++ b/pkgs/development/python-modules/pox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "06afe1a4a1dbf8b47f7ad5a3c1d8ada9104c64933a1da11338269a2bd8642778";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for filesystem exploration and automated builds";
     license = licenses.bsd3;
     homepage = "https://github.com/uqfoundation/pox/";
diff --git a/pkgs/development/python-modules/poyo/default.nix b/pkgs/development/python-modules/poyo/default.nix
index 3eff663aed9c9..d600e46c6b420 100644
--- a/pkgs/development/python-modules/poyo/default.nix
+++ b/pkgs/development/python-modules/poyo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1pflivs6j22frz0v3dqxnvc8yb8fb52g11lqr88z0i8cg2m5csg2";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hackebrot/poyo";
     description = "A lightweight YAML Parser for Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ppft/default.nix b/pkgs/development/python-modules/ppft/default.nix
index d8e8f33181f64..ba23948fdb8c8 100644
--- a/pkgs/development/python-modules/ppft/default.nix
+++ b/pkgs/development/python-modules/ppft/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m ppft.tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Distributed and parallel python";
     homepage = "https://github.com/uqfoundation";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/ppscore/default.nix b/pkgs/development/python-modules/ppscore/default.nix
index 3fd047402ee77..00542c6e90e1d 100644
--- a/pkgs/development/python-modules/ppscore/default.nix
+++ b/pkgs/development/python-modules/ppscore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     scikitlearn
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python implementation of the Predictive Power Score (PPS)";
     homepage = "https://github.com/8080labs/ppscore/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/praw/6.3.nix b/pkgs/development/python-modules/praw/6.3.nix
index 6c2201d1f1d22..00182eda03791 100644
--- a/pkgs/development/python-modules/praw/6.3.nix
+++ b/pkgs/development/python-modules/praw/6.3.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , betamax
 , betamax-serializers
 , betamax-matchers
@@ -44,7 +44,7 @@ buildPythonPackage rec {
     six
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Reddit API wrapper";
     homepage = "https://praw.readthedocs.org/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/praw/default.nix b/pkgs/development/python-modules/praw/default.nix
index 698c9cc1ccf62..61b869e87fb21 100644
--- a/pkgs/development/python-modules/praw/default.nix
+++ b/pkgs/development/python-modules/praw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , betamax
 , betamax-serializers
 , betamax-matchers
@@ -44,7 +44,7 @@ buildPythonPackage rec {
     six
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Reddit API wrapper";
     homepage = "https://praw.readthedocs.org/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/prawcore/default.nix b/pkgs/development/python-modules/prawcore/default.nix
index 7be75eae90a52..533c31d87ce22 100644
--- a/pkgs/development/python-modules/prawcore/default.nix
+++ b/pkgs/development/python-modules/prawcore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27
 , requests
 , testfixtures, mock, requests_toolbelt
 , betamax, betamax-serializers, betamax-matchers, pytest
@@ -32,7 +32,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Low-level communication layer for PRAW";
     homepage = "https://praw.readthedocs.org/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/preggy/default.nix b/pkgs/development/python-modules/preggy/default.nix
index a3ca7d15c77ed..a2144f303be72 100644
--- a/pkgs/development/python-modules/preggy/default.nix
+++ b/pkgs/development/python-modules/preggy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six, unidecode, nose, yanc }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six, unidecode, nose, yanc }:
 
 buildPythonPackage rec {
   pname = "preggy";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     nosetests .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Assertion library for Python";
     homepage = "http://heynemann.github.io/preggy/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/preshed/default.nix b/pkgs/development/python-modules/preshed/default.nix
index a544d6fab9102..5d75c95d770bb 100644
--- a/pkgs/development/python-modules/preshed/default.nix
+++ b/pkgs/development/python-modules/preshed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , murmurhash
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     ${python.interpreter} setup.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cython hash tables that assume keys are pre-hashed";
     homepage = "https://github.com/explosion/preshed";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pretend/default.nix b/pkgs/development/python-modules/pretend/default.nix
index af5b339983150..4fe726591e60c 100644
--- a/pkgs/development/python-modules/pretend/default.nix
+++ b/pkgs/development/python-modules/pretend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pretend";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/alex/pretend";
     license = licenses.bsd3;
   };
diff --git a/pkgs/development/python-modules/prettytable/1.nix b/pkgs/development/python-modules/prettytable/1.nix
index ccaa02e2f494d..5b7457af9bf7c 100644
--- a/pkgs/development/python-modules/prettytable/1.nix
+++ b/pkgs/development/python-modules/prettytable/1.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , glibcLocales
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "prettytable" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple Python library for easily displaying tabular data in a visually appealing ASCII table format";
     homepage = "http://code.google.com/p/prettytable/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/prettytable/default.nix b/pkgs/development/python-modules/prettytable/default.nix
index bc8bd3f835d6b..5a15cfd24eb00 100644
--- a/pkgs/development/python-modules/prettytable/default.nix
+++ b/pkgs/development/python-modules/prettytable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , glibcLocales
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "prettytable" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple Python library for easily displaying tabular data in a visually appealing ASCII table format";
     homepage = "http://code.google.com/p/prettytable/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/proboscis/default.nix b/pkgs/development/python-modules/proboscis/default.nix
index 9d4ae92f2c105..00905136716f4 100644
--- a/pkgs/development/python-modules/proboscis/default.nix
+++ b/pkgs/development/python-modules/proboscis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, nose }:
 
 buildPythonPackage rec {
   pname = "proboscis";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ nose ];
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python test framework that extends Python's built-in unittest module and Nose with features from TestNG";
     homepage = "https://pypi.python.org/pypi/proboscis";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/process-tests/default.nix b/pkgs/development/python-modules/process-tests/default.nix
index de43ea71fd48f..4b83205d723e3 100644
--- a/pkgs/development/python-modules/process-tests/default.nix
+++ b/pkgs/development/python-modules/process-tests/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for testing processes";
     license = licenses.bsd2;
     homepage = "https://github.com/ionelmc/python-process-tests";
diff --git a/pkgs/development/python-modules/proglog/default.nix b/pkgs/development/python-modules/proglog/default.nix
index ef5c21f450d52..3f8c110438114 100644
--- a/pkgs/development/python-modules/proglog/default.nix
+++ b/pkgs/development/python-modules/proglog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, tqdm }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, tqdm }:
 
 buildPythonPackage rec {
   pname = "proglog";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ tqdm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Logs and progress bars manager for Python";
     homepage = "https://github.com/Edinburgh-Genome-Foundry/Proglog";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/progress/default.nix b/pkgs/development/python-modules/progress/default.nix
index 9ebef268571cc..2c5dbc1386e85 100644
--- a/pkgs/development/python-modules/progress/default.nix
+++ b/pkgs/development/python-modules/progress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     ${python.interpreter} test_progress.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/verigak/progress/";
     description = "Easy to use progress bars";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/progressbar/default.nix b/pkgs/development/python-modules/progressbar/default.nix
index c756a41b5d0e9..a1fdddd95db80 100644
--- a/pkgs/development/python-modules/progressbar/default.nix
+++ b/pkgs/development/python-modules/progressbar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "progressbar";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/progressbar";
     description = "Text progressbar library for python";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/progressbar2/default.nix b/pkgs/development/python-modules/progressbar2/default.nix
index 55590f8bd0638..cc3029ade64e4 100644
--- a/pkgs/development/python-modules/progressbar2/default.nix
+++ b/pkgs/development/python-modules/progressbar2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python
 , buildPythonPackage
 , fetchPypi
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "progressbar" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://progressbar-2.readthedocs.io/en/latest/";
     description = "Text progressbar library for python";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/progressbar231/default.nix b/pkgs/development/python-modules/progressbar231/default.nix
index 5271912cc0ad5..f8980647482cd 100644
--- a/pkgs/development/python-modules/progressbar231/default.nix
+++ b/pkgs/development/python-modules/progressbar231/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k }:
 
 buildPythonPackage rec {
   pname = "progressbar231";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # no tests implemented
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/progressbar231";
     description = "Text progressbar library for python";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/progressbar33/default.nix b/pkgs/development/python-modules/progressbar33/default.nix
index 5aef284478497..0b53b83f5cca9 100644
--- a/pkgs/development/python-modules/progressbar33/default.nix
+++ b/pkgs/development/python-modules/progressbar33/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "progressbar33";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # no tests implemented
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/progressbar33";
     description = "Text progressbar library for python";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/proto-plus/default.nix b/pkgs/development/python-modules/proto-plus/default.nix
index 71949d0d4e094..1cd732b19aea1 100644
--- a/pkgs/development/python-modules/proto-plus/default.nix
+++ b/pkgs/development/python-modules/proto-plus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "proto" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Beautiful, idiomatic protocol buffers in Python";
     homepage = "https://github.com/googleapis/proto-plus-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/prov/default.nix b/pkgs/development/python-modules/prov/default.nix
index 3844a0fade9ec..fba5a41389c75 100644
--- a/pkgs/development/python-modules/prov/default.nix
+++ b/pkgs/development/python-modules/prov/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , lxml
@@ -42,7 +42,7 @@ buildPythonPackage rec {
     export LC_ALL="en_US.utf-8"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python library for W3C Provenance Data Model (PROV)";
     homepage = "https://github.com/trungdong/prov";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ptable/default.nix b/pkgs/development/python-modules/ptable/default.nix
index f1118325610ce..ffa9bdacd2d13 100644
--- a/pkgs/development/python-modules/ptable/default.nix
+++ b/pkgs/development/python-modules/ptable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, nose }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, nose }:
 
 buildPythonPackage {
   pname = "ptable";
@@ -18,7 +18,7 @@ buildPythonPackage {
     nosetests --with-coverage --cover-package=prettytable --cover-min-percentage=75
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kxxoling/PTable";
     description = "A simple Python library designed to make it quick and easy to represent tabular data in visually appealing ASCII tables";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/ptest/default.nix b/pkgs/development/python-modules/ptest/default.nix
index 0cdbeb372e3b5..c19780a4411c9 100644
--- a/pkgs/development/python-modules/ptest/default.nix
+++ b/pkgs/development/python-modules/ptest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "0v1zpfjagjlvdmgv6d502nmb7s996wadvpzg93i651s64rrlwq4s";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test classes and test cases using decorators, execute test cases by command line, and get clear reports";
     homepage = "https://pypi.python.org/pypi/ptest";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ptpython/default.nix b/pkgs/development/python-modules/ptpython/default.nix
index 85ba8838f667f..fd7b92692fc60 100644
--- a/pkgs/development/python-modules/ptpython/default.nix
+++ b/pkgs/development/python-modules/ptpython/default.nix
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # no tests to run
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An advanced Python REPL";
     license = licenses.bsd3;
     maintainers = with maintainers; [ mlieberman85 ];
diff --git a/pkgs/development/python-modules/publicsuffix/default.nix b/pkgs/development/python-modules/publicsuffix/default.nix
index 061ad6858614d..abac4fb3baa07 100644
--- a/pkgs/development/python-modules/publicsuffix/default.nix
+++ b/pkgs/development/python-modules/publicsuffix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k }:
 
 buildPythonPackage rec {
   pname = "publicsuffix";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
     \\t@unittest.skip('requires internet')" -e "/def additional_tests():/,+1d" tests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows to get the public suffix of a domain name";
     homepage = "https://pypi.python.org/pypi/publicsuffix/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/publicsuffix2/default.nix b/pkgs/development/python-modules/publicsuffix2/default.nix
index fe360168aa5ab..2d9bc73baa3fb 100644
--- a/pkgs/development/python-modules/publicsuffix2/default.nix
+++ b/pkgs/development/python-modules/publicsuffix2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, requests }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, requests }:
 
 buildPythonPackage rec {
   pname = "publicsuffix2";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   nativeBuildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Get a public suffix for a domain name using the Public Suffix
       List. Forked from and using the same API as the publicsuffix package.
diff --git a/pkgs/development/python-modules/pudb/default.nix b/pkgs/development/python-modules/pudb/default.nix
index 789a9484d7304..0ee2a8470b5ec 100644
--- a/pkgs/development/python-modules/pudb/default.nix
+++ b/pkgs/development/python-modules/pudb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pygments
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Tests fail on python 3 due to writes to the read-only home directory
   doCheck = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full-screen, console-based Python debugger";
     license = licenses.mit;
     platforms = platforms.all;
diff --git a/pkgs/development/python-modules/pulp/default.nix b/pkgs/development/python-modules/pulp/default.nix
index 590fc022d669f..480714e9e28de 100644
--- a/pkgs/development/python-modules/pulp/default.nix
+++ b/pkgs/development/python-modules/pulp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , pyparsing
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "pulp" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/coin-or/pulp";
     description = "PuLP is an LP modeler written in python";
     maintainers = with maintainers; [ teto ];
diff --git a/pkgs/development/python-modules/pure-pcapy3/default.nix b/pkgs/development/python-modules/pure-pcapy3/default.nix
index 43d6244ebf0c3..9679cc593df0d 100644
--- a/pkgs/development/python-modules/pure-pcapy3/default.nix
+++ b/pkgs/development/python-modules/pure-pcapy3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pure-pcapy3";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "14panfklap6wwi9avw46gvd7wg9mkv9xbixvbvmi1m2adpqlb7mr";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python reimplementation of pcapy. This package is API compatible and a drop-in replacement.";
     homepage = "https://bitbucket.org/viraptor/pure-pcapy";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/purepng/default.nix b/pkgs/development/python-modules/purepng/default.nix
index fe504a0776b70..715b2ca690292 100644
--- a/pkgs/development/python-modules/purepng/default.nix
+++ b/pkgs/development/python-modules/purepng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , python
 , fetchFromGitHub
@@ -38,7 +38,7 @@ buildPythonPackage {
     ${python.interpreter} code/test_png.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python library for PNG image encoding/decoding";
     homepage    = "https://github.com/scondo/purepng";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pushover/default.nix b/pkgs/development/python-modules/pushover/default.nix
index 72d38259129e3..1093f125a9695 100644
--- a/pkgs/development/python-modules/pushover/default.nix
+++ b/pkgs/development/python-modules/pushover/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , requests }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # tests require network
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bindings and command line utility for the Pushover notification service";
     homepage = "https://github.com/Thibauth/python-pushover";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/pvlib/default.nix b/pkgs/development/python-modules/pvlib/default.nix
index f9d97c2110550..006246e583662 100644
--- a/pkgs/development/python-modules/pvlib/default.nix
+++ b/pkgs/development/python-modules/pvlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, pythonOlder, numpy, pandas, pytz, six
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, pythonOlder, numpy, pandas, pytz, six
 , pytestCheckHook, flaky, mock, pytest-mock, requests }:
 
 buildPythonPackage rec {
@@ -45,7 +45,7 @@ buildPythonPackage rec {
     "backtrack"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pvlib-python.readthedocs.io";
     description = "Simulate the performance of photovoltaic energy systems";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pweave/default.nix b/pkgs/development/python-modules/pweave/default.nix
index aba58b54c3b53..fe74fcece1c08 100644
--- a/pkgs/development/python-modules/pweave/default.nix
+++ b/pkgs/development/python-modules/pweave/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -26,7 +26,7 @@ buildPythonPackage rec {
   # fails due to trying to run CSS as test
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scientific reports with embedded python computations with reST, LaTeX or markdown";
     homepage = "http://mpastell.com/pweave/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pwntools/default.nix b/pkgs/development/python-modules/pwntools/default.nix
index a6f43ae5b1f87..8f559edf41f28 100644
--- a/pkgs/development/python-modules/pwntools/default.nix
+++ b/pkgs/development/python-modules/pwntools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , debugger
 , fetchPypi
@@ -65,7 +65,7 @@ buildPythonPackage rec {
     makeWrapper "${debugger}/bin/${stdenv.lib.strings.getName debugger}" "$out/bin/pwntools-gdb"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pwntools.com";
     description = "CTF framework and exploit development library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pxml/default.nix b/pkgs/development/python-modules/pxml/default.nix
index 229b174adec27..57614089e66e2 100644
--- a/pkgs/development/python-modules/pxml/default.nix
+++ b/pkgs/development/python-modules/pxml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pythonAtLeast
 , isPy27
 , buildPythonPackage
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     nosetests -e 'test_prefixedWhitespace'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/metagriffin/pxml";
     description = ''A python library and command-line tool to "prettify" and colorize XML.'';
     maintainers = with maintainers; [ glittershark ];
diff --git a/pkgs/development/python-modules/py-radix/default.nix b/pkgs/development/python-modules/py-radix/default.nix
index 16a362591dd74..fa057ae992546 100644
--- a/pkgs/development/python-modules/py-radix/default.nix
+++ b/pkgs/development/python-modules/py-radix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , coverage
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   doCheck = true;
   checkInputs = [ coverage nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python radix tree for IPv4 and IPv6 prefix matching";
     homepage = "https://github.com/mjschultz/py-radix";
     license = with licenses; [ isc bsdOriginal ];
diff --git a/pkgs/development/python-modules/py/default.nix b/pkgs/development/python-modules/py/default.nix
index 19366ea7146cf..4d2b77bb1f2a0 100644
--- a/pkgs/development/python-modules/py/default.nix
+++ b/pkgs/development/python-modules/py/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm }:
 
 buildPythonPackage rec {
   pname = "py";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     "py"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library with cross-python path, ini-parsing, io, code, log facilities";
     homepage = "https://pylib.readthedocs.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/py3buddy/default.nix b/pkgs/development/python-modules/py3buddy/default.nix
index 459922c9bafdb..b8a25480799b3 100644
--- a/pkgs/development/python-modules/py3buddy/default.nix
+++ b/pkgs/development/python-modules/py3buddy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python
 , pyusb
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     install -D 99-ibuddy.rules $out/lib/udev/rules.d/99-ibuddy.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Code to work with the iBuddy MSN figurine";
     homepage = "https://github.com/armijnhemel/py3buddy";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/py3dns/default.nix b/pkgs/development/python-modules/py3dns/default.nix
index 223e6c0ab7a40..1f7aeaf1e1182 100644
--- a/pkgs/development/python-modules/py3dns/default.nix
+++ b/pkgs/development/python-modules/py3dns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python 3 DNS library";
     homepage = "https://launchpad.net/py3dns";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/py3status/default.nix b/pkgs/development/python-modules/py3status/default.nix
index 03f142a8aba66..a2aeaceef6dd2 100644
--- a/pkgs/development/python-modules/py3status/default.nix
+++ b/pkgs/development/python-modules/py3status/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -49,7 +49,7 @@ buildPythonPackage rec {
     sed -i -e "s|'xset|'${xorg.xset}/bin/xset|" py3status/modules/keyboard_layout.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extensible i3status wrapper";
     license = licenses.bsd3;
     homepage = "https://github.com/ultrabug/py3status";
diff --git a/pkgs/development/python-modules/py4j/default.nix b/pkgs/development/python-modules/py4j/default.nix
index e8faee8d817dd..588d7a32d22f4 100644
--- a/pkgs/development/python-modules/py4j/default.nix
+++ b/pkgs/development/python-modules/py4j/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchPypi, stdenv }:
+{ buildPythonPackage, fetchPypi, lib, stdenv }:
 
 buildPythonPackage rec {
   pname = "py4j";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Py4J enables Python programs running in a Python interpreter to dynamically access Java objects in a Java Virtual Machine. Methods are called as if the Java objects resided in the Python interpreter and Java collections can be accessed through standard Python collection methods. Py4J also enables Java programs to call back Python objects.";
     homepage = "https://www.py4j.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pyGithub/default.nix b/pkgs/development/python-modules/pyGithub/default.nix
index c82f18d377d31..e30ecb95765b1 100644
--- a/pkgs/development/python-modules/pyGithub/default.nix
+++ b/pkgs/development/python-modules/pyGithub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , cryptography
 , deprecated
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   # Test suite makes REST calls against github.com
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/PyGithub/PyGithub";
     description = "A Python (2 and 3) library to access the GitHub API v3";
     platforms = platforms.all;
diff --git a/pkgs/development/python-modules/py_scrypt/default.nix b/pkgs/development/python-modules/py_scrypt/default.nix
index e7c75f98231be..af86ce3821eb1 100644
--- a/pkgs/development/python-modules/py_scrypt/default.nix
+++ b/pkgs/development/python-modules/py_scrypt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , openssl
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   buildInputs = [ openssl ];
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bindings for scrypt key derivation function library";
     homepage = "https://pypi.python.org/pypi/scrypt";
     maintainers = [];
diff --git a/pkgs/development/python-modules/pyacoustid/default.nix b/pkgs/development/python-modules/pyacoustid/default.nix
index 75b0964e259db..d424b2144292d 100644
--- a/pkgs/development/python-modules/pyacoustid/default.nix
+++ b/pkgs/development/python-modules/pyacoustid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -23,7 +23,7 @@ buildPythonPackage rec {
         acoustid.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bindings for Chromaprint acoustic fingerprinting";
     homepage = "https://github.com/sampsyo/pyacoustid";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyalgotrade/default.nix b/pkgs/development/python-modules/pyalgotrade/default.nix
index 3703b5fcca4c1..075103e9e40fa 100644
--- a/pkgs/development/python-modules/pyalgotrade/default.nix
+++ b/pkgs/development/python-modules/pyalgotrade/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , matplotlib
@@ -32,7 +32,7 @@ buildPythonPackage rec {
   # no tests in PyPI tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Algorithmic Trading";
     homepage = "http://gbeced.github.io/pyalgotrade/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pyamf/default.nix b/pkgs/development/python-modules/pyamf/default.nix
index 1c31efadff7ce..f0cf111a87ade 100644
--- a/pkgs/development/python-modules/pyamf/default.nix
+++ b/pkgs/development/python-modules/pyamf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy3k, defusedxml }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy3k, defusedxml }:
 
 buildPythonPackage rec {
   pname = "PyAMF";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ defusedxml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AMF (Action Message Format) support for Python";
     homepage = "https://pypi.python.org/pypi/PyAMF";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyannotate/default.nix b/pkgs/development/python-modules/pyannotate/default.nix
index a2dd4eaf7cf0a..4442d90ae71a6 100644
--- a/pkgs/development/python-modules/pyannotate/default.nix
+++ b/pkgs/development/python-modules/pyannotate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dropbox/pyannotate";
     description = "Auto-generate PEP-484 annotations";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyasn1-modules/default.nix b/pkgs/development/python-modules/pyasn1-modules/default.nix
index 87e72e1ae5bdd..2be2e8b9c11a2 100644
--- a/pkgs/development/python-modules/pyasn1-modules/default.nix
+++ b/pkgs/development/python-modules/pyasn1-modules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyasn1
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of ASN.1-based protocols modules";
     homepage = "https://pypi.python.org/pypi/pyasn1-modules";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pyasn1/default.nix b/pkgs/development/python-modules/pyasn1/default.nix
index 206db053a564e..9b269f79c86a1 100644
--- a/pkgs/development/python-modules/pyasn1/default.nix
+++ b/pkgs/development/python-modules/pyasn1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, }:
 
 buildPythonPackage rec {
   pname = "pyasn1";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "aef77c9fb94a3ac588e87841208bdec464471d9871bd5050a287cc9a475cd0ba";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ASN.1 tools for Python";
     homepage = "http://pyasn1.sourceforge.net/";
     license = "mBSD";
diff --git a/pkgs/development/python-modules/pyatspi/default.nix b/pkgs/development/python-modules/pyatspi/default.nix
index 232e44d0999e6..6ac0c776fcd2d 100644
--- a/pkgs/development/python-modules/pyatspi/default.nix
+++ b/pkgs/development/python-modules/pyatspi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, buildPythonPackage, isPy3k, at-spi2-core, pygobject3, gnome3 }:
+{ lib, stdenv, fetchurl, pkgconfig, buildPythonPackage, isPy3k, at-spi2-core, pygobject3, gnome3 }:
 
 buildPythonPackage rec {
   pname = "pyatspi";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client bindings for D-Bus AT-SPI";
     homepage = "https://wiki.linuxfoundation.org/accessibility/d-bus";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/pyatv/default.nix b/pkgs/development/python-modules/pyatv/default.nix
index cbb61b21b10d2..187f94dbd778e 100644
--- a/pkgs/development/python-modules/pyatv/default.nix
+++ b/pkgs/development/python-modules/pyatv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage
+{ lib, stdenv, buildPythonPackage
 , aiohttp
 , aiozeroconf
 , asynctest
@@ -48,7 +48,7 @@ buildPythonPackage rec {
 
   __darwinAllowLocalNetworking = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python client library for the Apple TV";
     homepage = "https://github.com/postlund/pyatv";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyaudio/default.nix b/pkgs/development/python-modules/pyaudio/default.nix
index 91791f5a06744..d88dc7009b739 100644
--- a/pkgs/development/python-modules/pyaudio/default.nix
+++ b/pkgs/development/python-modules/pyaudio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pkgs.portaudio ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for PortAudio";
     homepage = "https://people.csail.mit.edu/hubert/pyaudio/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyaxmlparser/default.nix b/pkgs/development/python-modules/pyaxmlparser/default.nix
index 372d2feff15c6..63e180b11b2ba 100644
--- a/pkgs/development/python-modules/pyaxmlparser/default.nix
+++ b/pkgs/development/python-modules/pyaxmlparser/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, stdenv, lxml, click, fetchFromGitHub, pytest, isPy3k }:
+{ buildPythonPackage, lib, stdenv, lxml, click, fetchFromGitHub, pytest, isPy3k }:
 
 buildPythonPackage rec {
   version = "0.3.24";
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     py.test tests/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python3 Parser for Android XML file and get Application Name without using Androguard";
     homepage = "https://github.com/appknox/pyaxmlparser";
     # Files from Androguard are licensed ASL 2.0
diff --git a/pkgs/development/python-modules/pybase64/default.nix b/pkgs/development/python-modules/pybase64/default.nix
index d48fed13543bc..e462d53fea885 100644
--- a/pkgs/development/python-modules/pybase64/default.nix
+++ b/pkgs/development/python-modules/pybase64/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, isPy3k, stdenv, fetchPypi, six, pytest }:
+{ buildPythonPackage, isPy3k, lib, stdenv, fetchPypi, six, pytest }:
 
 buildPythonPackage rec {
   pname = "pybase64";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/pybase64";
     description = "Fast Base64 encoding/decoding";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/pybindgen/default.nix b/pkgs/development/python-modules/pybindgen/default.nix
index 136917c683714..4b6f7f1682ff3 100644
--- a/pkgs/development/python-modules/pybindgen/default.nix
+++ b/pkgs/development/python-modules/pybindgen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy3k, setuptools_scm, pygccxml }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy3k, setuptools_scm, pygccxml }:
 buildPythonPackage rec {
   pname = "PyBindGen";
   version = "0.21.0";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   checkInputs = [ pygccxml ];
   doCheck = (!isPy3k); # Fails to import module 'cxxfilt' from pygccxml on Py3k
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gjcarneiro/pybindgen";
     description = "Python Bindings Generator";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/pyblock/default.nix b/pkgs/development/python-modules/pyblock/default.nix
index e7af4f70b1e5e..0e94764e4a22c 100644
--- a/pkgs/development/python-modules/pyblock/default.nix
+++ b/pkgs/development/python-modules/pyblock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python
 , pkgs
 , isPy3k
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     "SITELIB=$(out)/${python.sitePackages}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.centos.org/docs/5/html/5.4/Technical_Notes/python-pyblock.html";
     description = "Interface for working with block devices";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/pyblosxom/default.nix b/pkgs/development/python-modules/pyblosxom/default.nix
index dfb3e94ba2765..dee6aea559a59 100644
--- a/pkgs/development/python-modules/pyblosxom/default.nix
+++ b/pkgs/development/python-modules/pyblosxom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , pygments
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # both tests fail due to time issue that doesn't seem to matter in practice
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pyblosxom.github.io";
     description = "File-based blogging engine";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pybluez/default.nix b/pkgs/development/python-modules/pybluez/default.nix
index 47c70758e4cac..a02861c68cda8 100644
--- a/pkgs/development/python-modules/pybluez/default.nix
+++ b/pkgs/development/python-modules/pybluez/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pkgs
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # the tests do not pass
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bluetooth Python extension module";
     license = licenses.gpl2;
     maintainers = with maintainers; [ leenaars ];
diff --git a/pkgs/development/python-modules/pybotvac/default.nix b/pkgs/development/python-modules/pybotvac/default.nix
index c5e239ab89737..06ebf85ffe8cd 100644
--- a/pkgs/development/python-modules/pybotvac/default.nix
+++ b/pkgs/development/python-modules/pybotvac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests }:
 
 buildPythonPackage rec {
   pname = "pybotvac";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python package for controlling Neato pybotvac Connected vacuum robot";
     homepage = "https://github.com/stianaske/pybotvac";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pybrowserid/default.nix b/pkgs/development/python-modules/pybrowserid/default.nix
index fe5ace886ac08..eacbd81055c50 100644
--- a/pkgs/development/python-modules/pybrowserid/default.nix
+++ b/pkgs/development/python-modules/pybrowserid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , requests, mock }:
 
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   checkInputs = [ mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for the BrowserID Protocol";
     homepage    = "https://github.com/mozilla/PyBrowserID";
     license     = licenses.mpl20;
diff --git a/pkgs/development/python-modules/pycallgraph/default.nix b/pkgs/development/python-modules/pycallgraph/default.nix
index 293489cce05b1..1353af406ca4f 100644
--- a/pkgs/development/python-modules/pycallgraph/default.nix
+++ b/pkgs/development/python-modules/pycallgraph/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Tests do not work due to this bug: https://github.com/gak/pycallgraph/issues/118
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pycallgraph.slowchop.com";
     description = "Call graph visualizations for Python applications";
     maintainers = with maintainers; [ auntie ];
diff --git a/pkgs/development/python-modules/pycangjie/default.nix b/pkgs/development/python-modules/pycangjie/default.nix
index dc4ab1d4bbda4..74c8ecd92b17e 100644
--- a/pkgs/development/python-modules/pycangjie/default.nix
+++ b/pkgs/development/python-modules/pycangjie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bash, autoconf, automake, libtool, pkgconfig, libcangjie
+{ lib, stdenv, fetchurl, bash, autoconf, automake, libtool, pkgconfig, libcangjie
 , sqlite, buildPythonPackage, cython
 }:
 
@@ -26,7 +26,7 @@ in buildPythonPackage {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper to libcangjie";
     homepage = "http://cangjians.github.io/projects/pycangjie/";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/pycapnp/default.nix b/pkgs/development/python-modules/pycapnp/default.nix
index 0d8dc6b53d890..ab9088cf1e5f1 100644
--- a/pkgs/development/python-modules/pycapnp/default.nix
+++ b/pkgs/development/python-modules/pycapnp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , capnproto
 , cython
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "capnp" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ cstrahan lukeadams ];
     license = licenses.bsd2;
     homepage = "https://capnproto.github.io/pycapnp/";
diff --git a/pkgs/development/python-modules/pycarddav/default.nix b/pkgs/development/python-modules/pycarddav/default.nix
index 674c9e9af86bf..7885cf65b83bf 100644
--- a/pkgs/development/python-modules/pycarddav/default.nix
+++ b/pkgs/development/python-modules/pycarddav/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ vobject lxml requests urwid pyxdg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line interface carddav client";
     homepage = "http://lostpackets.de/pycarddav";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pycares/default.nix b/pkgs/development/python-modules/pycares/default.nix
index e233d8d70884f..8404063ac1f83 100644
--- a/pkgs/development/python-modules/pycares/default.nix
+++ b/pkgs/development/python-modules/pycares/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -26,7 +26,7 @@ buildPythonPackage rec {
   # requires network access
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/saghul/pycares";
     description = "Interface for c-ares";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pycdio/default.nix b/pkgs/development/python-modules/pycdio/default.nix
index d5633f9eaefaf..b290d9ea959bf 100644
--- a/pkgs/development/python-modules/pycdio/default.nix
+++ b/pkgs/development/python-modules/pycdio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools
@@ -37,7 +37,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/libcdio/";
     description = "Wrapper around libcdio (CD Input and Control library)";
     maintainers = with maintainers; [ rycee ];
diff --git a/pkgs/development/python-modules/pychart/default.nix b/pkgs/development/python-modules/pychart/default.nix
index 98c3242cb29d3..2c2399fca92ed 100644
--- a/pkgs/development/python-modules/pychart/default.nix
+++ b/pkgs/development/python-modules/pychart/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27 }:
 
 buildPythonPackage rec {
   pname = "pychart";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
     sha256 = "882650928776a7ca72e67054a9e0ac98f78645f279c0cfb5910db28f03f07c2e";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for creating high quality encapsulated Postscript, PDF, PNG, or SVG charts";
     homepage = "https://pypi.python.org/pypi/PyChart";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/pychef/default.nix b/pkgs/development/python-modules/pychef/default.nix
index 6d60573b96eb1..1702cde840cf7 100644
--- a/pkgs/development/python-modules/pychef/default.nix
+++ b/pkgs/development/python-modules/pychef/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # FIXME
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/coderanger/pychef";
     description = "Python implementation of a Chef API client";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pyclipper/default.nix b/pkgs/development/python-modules/pyclipper/default.nix
index 6096f30181a16..e893895470966 100644
--- a/pkgs/development/python-modules/pyclipper/default.nix
+++ b/pkgs/development/python-modules/pyclipper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , setuptools_scm
@@ -26,7 +26,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "pyclipper" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cython wrapper for clipper library";
     homepage    = "https://github.com/fonttools/pyclipper";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pycm/default.nix b/pkgs/development/python-modules/pycm/default.nix
index a51aa1b931aa7..ada4eeeb556c9 100644
--- a/pkgs/development/python-modules/pycm/default.nix
+++ b/pkgs/development/python-modules/pycm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy3k, numpy, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy3k, numpy, pytest }:
 
 buildPythonPackage rec {
   pname = "pycm";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     pytest Test/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiclass confusion matrix library";
     homepage = "https://pycm.ir";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pycoin/default.nix b/pkgs/development/python-modules/pycoin/default.nix
index cb0431be61f87..a21c8f6f549d0 100644
--- a/pkgs/development/python-modules/pycoin/default.nix
+++ b/pkgs/development/python-modules/pycoin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , gnupg
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     "test_tx_with_gpg"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for Bitcoin and altcoin addresses and transaction manipulation";
     homepage = "https://github.com/richardkiss/pycoin";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pycollada/default.nix b/pkgs/development/python-modules/pycollada/default.nix
index 4015f9164e9de..4b177012f4edd 100644
--- a/pkgs/development/python-modules/pycollada/default.nix
+++ b/pkgs/development/python-modules/pycollada/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, numpy, dateutil }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, numpy, dateutil }:
 
 buildPythonPackage rec {
   pname = "pycollada";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # (upstream packaging issue)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for reading and writing collada documents";
     homepage = "http://pycollada.github.io/";
     license = "BSD"; # they don't specify which BSD variant
diff --git a/pkgs/development/python-modules/pycontracts/default.nix b/pkgs/development/python-modules/pycontracts/default.nix
index 330acab3e1d0b..0b511e024dc06 100644
--- a/pkgs/development/python-modules/pycontracts/default.nix
+++ b/pkgs/development/python-modules/pycontracts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose, pyparsing, decorator, six, future }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   buildInputs = [ nose ];
   propagatedBuildInputs = [ pyparsing decorator six future ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows to declare constraints on function parameters and return values";
     homepage = "https://pypi.python.org/pypi/PyContracts";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/pycountry/default.nix b/pkgs/development/python-modules/pycountry/default.nix
index 2cd707ee8dcb3..b402e9092406b 100644
--- a/pkgs/development/python-modules/pycountry/default.nix
+++ b/pkgs/development/python-modules/pycountry/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 ,
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     sha256 = "0hnbabsmqimx5hqh0jbd2f64i8fhzhhbrvid57048hs5sd9ll241";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/flyingcircus/pycountry";
     description = "ISO country, subdivision, language, currency and script definitions and their translations";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/pycparser/default.nix b/pkgs/development/python-modules/pycparser/default.nix
index f3fa6f883fb6c..a246ce53a1e08 100644
--- a/pkgs/development/python-modules/pycparser/default.nix
+++ b/pkgs/development/python-modules/pycparser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, python }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, python }:
 
 buildPythonPackage rec {
   pname = "pycparser";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover -s tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C parser in Python";
     homepage = "https://github.com/eliben/pycparser";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pycryptopp/default.nix b/pkgs/development/python-modules/pycryptopp/default.nix
index 25ac99082c0a5..0f17d9e59a80e 100644
--- a/pkgs/development/python-modules/pycryptopp/default.nix
+++ b/pkgs/development/python-modules/pycryptopp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -34,7 +34,7 @@ buildPythonPackage rec {
 
   buildInputs = [ setuptoolsDarcs darcsver pkgs.cryptopp ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tahoe-lafs.org/trac/pycryptopp";
     description = "Python wrappers for the Crypto++ library";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/pycuda/default.nix b/pkgs/development/python-modules/pycuda/default.nix
index 3876485dd966b..368894228afce 100644
--- a/pkgs/development/python-modules/pycuda/default.nix
+++ b/pkgs/development/python-modules/pycuda/default.nix
@@ -12,7 +12,7 @@
 , cudatoolkit
 , python
 , mkDerivation
-, stdenv
+, lib, stdenv
 }:
 let
   compyte = import ./compyte.nix {
@@ -60,7 +60,7 @@ buildPythonPackage rec {
     Mako
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/inducer/pycuda/";
     description = "CUDA integration for Python.";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pydenticon/default.nix b/pkgs/development/python-modules/pydenticon/default.nix
index db04991e6ebc0..763cfb9b84565 100644
--- a/pkgs/development/python-modules/pydenticon/default.nix
+++ b/pkgs/development/python-modules/pydenticon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pillow
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pillow mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/azaghal/pydenticon";
     description = "Library for generating identicons. Port of Sigil (https://github.com/cupcake/sigil) with enhancements";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pydicom/default.nix b/pkgs/development/python-modules/pydicom/default.nix
index 450a6a3c049ed..08c5f099d28c9 100644
--- a/pkgs/development/python-modules/pydicom/default.nix
+++ b/pkgs/development/python-modules/pydicom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -51,7 +51,7 @@ buildPythonPackage {
     "test_fetch_data_files"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pydicom.github.io";
     description = "Pure-Python package for working with DICOM files";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pydispatcher/default.nix b/pkgs/development/python-modules/pydispatcher/default.nix
index 066410b7a0da7..d132fad731380 100644
--- a/pkgs/development/python-modules/pydispatcher/default.nix
+++ b/pkgs/development/python-modules/pydispatcher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pydispatcher.sourceforge.net/";
     description = "Signal-registration and routing infrastructure for use in multiple contexts";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pydns/default.nix b/pkgs/development/python-modules/pydns/default.nix
index 399eab3e67423..a93820bfaef27 100644
--- a/pkgs/development/python-modules/pydns/default.nix
+++ b/pkgs/development/python-modules/pydns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python DNS library";
     homepage = "http://pydns.sourceforge.net/";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/pydotplus/default.nix b/pkgs/development/python-modules/pydotplus/default.nix
index bb25ecd85e26f..f794a150ec15a 100644
--- a/pkgs/development/python-modules/pydotplus/default.nix
+++ b/pkgs/development/python-modules/pydotplus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyparsing
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     graphviz
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/erocarrera/pydot";
     description = "An improved version of the old pydot project that provides a Python Interface to Graphviz’s Dot language";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pydub/default.nix b/pkgs/development/python-modules/pydub/default.nix
index 42d33c00cbe87..13b9998319851 100644
--- a/pkgs/development/python-modules/pydub/default.nix
+++ b/pkgs/development/python-modules/pydub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, scipy, ffmpeg-full }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, scipy, ffmpeg-full }:
 
 buildPythonPackage rec {
   pname = "pydub";
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     python test/test.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manipulate audio with a simple and easy high level interface.";
     homepage    = "http://pydub.com/";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pyechonest/default.nix b/pkgs/development/python-modules/pyechonest/default.nix
index 510849edf4757..10ade4fa2cabe 100644
--- a/pkgs/development/python-modules/pyechonest/default.nix
+++ b/pkgs/development/python-modules/pyechonest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k }:
 
 buildPythonPackage rec {
   pname = "pyechonest";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
     sha256 = "1da4b3b8b457232a7eb35b59a48390b3c208759b01d596acaa71e6a172b40495";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tap into The Echo Nest's Musical Brain for the best music search, information, recommendations and remix tools on the web";
     homepage = "https://github.com/echonest/pyechonest";
   };
diff --git a/pkgs/development/python-modules/pyelftools/default.nix b/pkgs/development/python-modules/pyelftools/default.nix
index 51e1886f1d0d0..5686a6ffadb2e 100644
--- a/pkgs/development/python-modules/pyelftools/default.nix
+++ b/pkgs/development/python-modules/pyelftools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , python
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "elftools" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for analyzing ELF files and DWARF debugging information";
     homepage = "https://github.com/eliben/pyelftools";
     license = licenses.publicDomain;
diff --git a/pkgs/development/python-modules/pyemd/default.nix b/pkgs/development/python-modules/pyemd/default.nix
index c6bc941046d5c..4e7594fbab5b7 100644
--- a/pkgs/development/python-modules/pyemd/default.nix
+++ b/pkgs/development/python-modules/pyemd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, numpy, cython }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, numpy, cython }:
 
 buildPythonPackage rec {
   pname = "pyemd";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ numpy ];
   buildInputs = [ cython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python wrapper for Ofir Pele and Michael Werman's implementation of the Earth Mover's Distance";
     homepage = "https://github.com/wmayner/pyemd";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyenchant/default.nix b/pkgs/development/python-modules/pyenchant/default.nix
index 1c82f7c9d630d..fe4182fd53d8e 100644
--- a/pkgs/development/python-modules/pyenchant/default.nix
+++ b/pkgs/development/python-modules/pyenchant/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy27
 , fetchPypi
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   # dictionaries needed for tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "pyenchant: Python bindings for the Enchant spellchecker";
     homepage = "https://github.com/pyenchant/pyenchant";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/pyexcelerator/default.nix b/pkgs/development/python-modules/pyexcelerator/default.nix
index 2dfb5831f7fee..3738850739490 100644
--- a/pkgs/development/python-modules/pyexcelerator/default.nix
+++ b/pkgs/development/python-modules/pyexcelerator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # No tests are included in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "library for generating Excel 97/2000/XP/2003 and OpenOffice Calc compatible spreadsheets.";
     homepage = "https://sourceforge.net/projects/pyexcelerator";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/pyext/default.nix b/pkgs/development/python-modules/pyext/default.nix
index 9351ee5d1043c..befbd3c2de1de 100644
--- a/pkgs/development/python-modules/pyext/default.nix
+++ b/pkgs/development/python-modules/pyext/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub }:
 
 buildPythonPackage {
     pname = "pyext";
@@ -15,7 +15,7 @@ buildPythonPackage {
     # Has no test suite
     doCheck = false;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Simple Python extensions";
       homepage = "https://github.com/kirbyfan64/PyExt";
       license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyface/default.nix b/pkgs/development/python-modules/pyface/default.nix
index 68afbafef3082..db118fbbd8c2a 100644
--- a/pkgs/development/python-modules/pyface/default.nix
+++ b/pkgs/development/python-modules/pyface/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , setuptools, six, traits
 }:
 
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   doCheck = false; # Needs X server
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Traits-capable windowing framework";
     homepage = "https://github.com/enthought/pyface";
     maintainers = with stdenv.lib.maintainers; [ knedlsepp ];
diff --git a/pkgs/development/python-modules/pyfakefs/default.nix b/pkgs/development/python-modules/pyfakefs/default.nix
index 6f44b7fb27964..4deaa3eb2688a 100644
--- a/pkgs/development/python-modules/pyfakefs/default.nix
+++ b/pkgs/development/python-modules/pyfakefs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder, python, pytest, glibcLocales }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder, python, pytest, glibcLocales }:
 
 buildPythonPackage rec {
   version = "4.3.2";
@@ -34,7 +34,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m pytest pyfakefs/pytest_tests/pytest_plugin_test.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fake file system that mocks the Python file system modules";
     license     = licenses.asl20;
     homepage    = "http://pyfakefs.org/";
diff --git a/pkgs/development/python-modules/pyfantom/default.nix b/pkgs/development/python-modules/pyfantom/default.nix
index a3facfc771ce1..a17388b34b5cf 100644
--- a/pkgs/development/python-modules/pyfantom/default.nix
+++ b/pkgs/development/python-modules/pyfantom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 }:
@@ -15,7 +15,7 @@ buildPythonPackage {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pyfantom.ni.fr.eu.org/";
     description = "Wrapper for the LEGO Mindstorms Fantom Driver";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/pyfftw/default.nix b/pkgs/development/python-modules/pyfftw/default.nix
index c8dc83b4eba51..ff66dc8f8675c 100644
--- a/pkgs/development/python-modules/pyfftw/default.nix
+++ b/pkgs/development/python-modules/pyfftw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , fftw, fftwFloat, fftwLongDouble, numpy, scipy, cython, dask }:
 
 buildPythonPackage rec {
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   #  export DYLD_LIBRARY_PATH="${pkgs.fftw.out}/lib"
   #'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pythonic wrapper around FFTW, the FFT library, presenting a unified interface for all the supported transforms";
     homepage = "http://hgomersall.github.com/pyFFTW/";
     license = with licenses; [ bsd2 bsd3 ];
diff --git a/pkgs/development/python-modules/pyfiglet/default.nix b/pkgs/development/python-modules/pyfiglet/default.nix
index d8256e9632a39..a4fe9ec9dfe69 100644
--- a/pkgs/development/python-modules/pyfiglet/default.nix
+++ b/pkgs/development/python-modules/pyfiglet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   version = "0.8.post1";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FIGlet in pure Python";
     license     = licenses.gpl2Plus;
     maintainers = with maintainers; [ thoughtpolice ];
diff --git a/pkgs/development/python-modules/pyflakes/default.nix b/pkgs/development/python-modules/pyflakes/default.nix
index 04bc56df12d2f..2ff88a78a4e76 100644
--- a/pkgs/development/python-modules/pyflakes/default.nix
+++ b/pkgs/development/python-modules/pyflakes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder, unittest2 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder, unittest2 }:
 
 buildPythonPackage rec {
   pname = "pyflakes";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # some tests are output dependent, which have changed slightly
   doCheck = pythonOlder "3.9";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/pyflakes";
     description = "A simple program which checks Python source files for errors";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyfribidi/default.nix b/pkgs/development/python-modules/pyfribidi/default.nix
index e71550867a3dd..17905b2bb396c 100644
--- a/pkgs/development/python-modules/pyfribidi/default.nix
+++ b/pkgs/development/python-modules/pyfribidi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple wrapper around fribidi";
     homepage = "https://github.com/pediapress/pyfribidi";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/development/python-modules/pyftpdlib/default.nix b/pkgs/development/python-modules/pyftpdlib/default.nix
index 721d279478d6d..5d0d72eb4959d 100644
--- a/pkgs/development/python-modules/pyftpdlib/default.nix
+++ b/pkgs/development/python-modules/pyftpdlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # on Hydra: https://hydra.nixos.org/build/84374861
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/giampaolo/pyftpdlib/";
     description = "Very fast asynchronous FTP server library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyfttt/default.nix b/pkgs/development/python-modules/pyfttt/default.nix
index 8592d9b0aeefa..8648ad4f876d7 100644
--- a/pkgs/development/python-modules/pyfttt/default.nix
+++ b/pkgs/development/python-modules/pyfttt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , requests }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # tests need a server to run against
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Package for sending events to the IFTTT Webhooks Channel";
     homepage = "https://github.com/briandconnelly/pyfttt";
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/development/python-modules/pygal/default.nix b/pkgs/development/python-modules/pygal/default.nix
index 617f5fa3fd58a..733bfa15a4c5f 100644
--- a/pkgs/development/python-modules/pygal/default.nix
+++ b/pkgs/development/python-modules/pygal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchpatch
@@ -57,7 +57,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ cairosvg tinycss cssselect ]
     ++ stdenv.lib.optionals (!isPyPy) [ lxml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sexy and simple python charting";
     homepage = "http://www.pygal.org";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/pygame_sdl2/default.nix b/pkgs/development/python-modules/pygame_sdl2/default.nix
index ab46a5670eeb2..afca3dd7bc19e 100644
--- a/pkgs/development/python-modules/pygame_sdl2/default.nix
+++ b/pkgs/development/python-modules/pygame_sdl2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchurl, isPy27
+{ lib, stdenv, buildPythonPackage, fetchurl, isPy27
 , cython, SDL2, SDL2_image, SDL2_ttf, SDL2_mixer, libjpeg, libpng }:
 
 buildPythonPackage rec {
@@ -34,7 +34,7 @@ buildPythonPackage rec {
       ln -s pygame-sdl2 pygame_sdl2 || true ; )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A reimplementation of parts of pygame API using SDL2";
     homepage    = "https://github.com/renpy/pygame_sdl2";
     # Some parts are also available under Zlib License
diff --git a/pkgs/development/python-modules/pygccxml/default.nix b/pkgs/development/python-modules/pygccxml/default.nix
index 14bd14ab75e70..a1a6b0222b83d 100644
--- a/pkgs/development/python-modules/pygccxml/default.nix
+++ b/pkgs/development/python-modules/pygccxml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, castxml, fetchFromGitHub, buildPythonPackage,
+{ lib, stdenv, castxml, fetchFromGitHub, buildPythonPackage,
 llvmPackages }:
 buildPythonPackage rec {
   pname = "pygccxml";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # but the format doesn't accept -isystem directives
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gccxml/pygccxml";
     description = "Python package for easy C++ declarations navigation";
     license = licenses.boost;
diff --git a/pkgs/development/python-modules/pygeoip/default.nix b/pkgs/development/python-modules/pygeoip/default.nix
index 6cd21a94a9bec..7aa16ac1e9a81 100644
--- a/pkgs/development/python-modules/pygeoip/default.nix
+++ b/pkgs/development/python-modules/pygeoip/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python GeoIP API";
     homepage = "https://github.com/appliedsec/pygeoip";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/pyglet/default.nix b/pkgs/development/python-modules/pyglet/default.nix
index a37872d909450..1bb36d6029ecc 100644
--- a/pkgs/development/python-modules/pyglet/default.nix
+++ b/pkgs/development/python-modules/pyglet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , libGL
@@ -75,7 +75,7 @@ buildPythonPackage rec {
     py.test tests/unit tests/integration
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.pyglet.org/";
     description = "A cross-platform windowing and multimedia library";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pygments-better-html/default.nix b/pkgs/development/python-modules/pygments-better-html/default.nix
index 87b8e0b3ffb74..2e5d6271c66ac 100644
--- a/pkgs/development/python-modules/pygments-better-html/default.nix
+++ b/pkgs/development/python-modules/pygments-better-html/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pygments
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "pygments_better_html" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Kwpolska/pygments_better_html";
     description = "Improved line numbering for Pygments’ HTML formatter.";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pygments-markdown-lexer/default.nix b/pkgs/development/python-modules/pygments-markdown-lexer/default.nix
index 8f41995cf395e..31a6b043494d8 100644
--- a/pkgs/development/python-modules/pygments-markdown-lexer/default.nix
+++ b/pkgs/development/python-modules/pygments-markdown-lexer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pygments
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jhermann/pygments-markdown-lexer";
     description = "Pygments Markdown Lexer – A Markdown lexer for Pygments to highlight Markdown code snippets";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pygmt/default.nix b/pkgs/development/python-modules/pygmt/default.nix
index 28e7db2a99ea0..318706edd9308 100644
--- a/pkgs/development/python-modules/pygmt/default.nix
+++ b/pkgs/development/python-modules/pygmt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pythonOlder
 , buildPythonPackage
 , fetchFromGitHub
@@ -36,7 +36,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "pygmt" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python interface for the Generic Mapping Tools";
     homepage = "https://github.com/GenericMappingTools/pygmt";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pygobject/3.36.nix b/pkgs/development/python-modules/pygobject/3.36.nix
index 7e31e788f31e5..59e192271960d 100644
--- a/pkgs/development/python-modules/pygobject/3.36.nix
+++ b/pkgs/development/python-modules/pygobject/3.36.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonPackage, pkgconfig, glib, gobject-introspection,
+{ lib, stdenv, fetchurl, buildPythonPackage, pkgconfig, glib, gobject-introspection,
 pycairo, cairo, which, ncurses, meson, ninja, isPy3k, gnome3 }:
 
 buildPythonPackage rec {
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pygobject.readthedocs.io/";
     description = "Python bindings for Glib";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/pygobject/3.nix b/pkgs/development/python-modules/pygobject/3.nix
index 6e34e7f910070..68f1bfa7b26d1 100644
--- a/pkgs/development/python-modules/pygobject/3.nix
+++ b/pkgs/development/python-modules/pygobject/3.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonPackage, pkgconfig, glib, gobject-introspection,
+{ lib, stdenv, fetchurl, buildPythonPackage, pkgconfig, glib, gobject-introspection,
 pycairo, cairo, which, ncurses, meson, ninja, isPy3k, gnome3 }:
 
 buildPythonPackage rec {
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pygobject.readthedocs.io/";
     description = "Python bindings for Glib";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/pygpgme/default.nix b/pkgs/development/python-modules/pygpgme/default.nix
index 4322e76e3e74c..416410ab3ce75 100644
--- a/pkgs/development/python-modules/pygpgme/default.nix
+++ b/pkgs/development/python-modules/pygpgme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchurl, isPyPy
+{ lib, stdenv, buildPythonPackage, fetchurl, isPyPy
 , gpgme }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ gpgme ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/pygpgme";
     description = "A Python wrapper for the GPGME library";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/pygraphviz/default.nix b/pkgs/development/python-modules/pygraphviz/default.nix
index a8d80f6e6175c..0b3e99dd28b71 100644
--- a/pkgs/development/python-modules/pygraphviz/default.nix
+++ b/pkgs/development/python-modules/pygraphviz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi, substituteAll, graphviz
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi, substituteAll, graphviz
 , pkgconfig, doctest-ignore-unicode, mock, nose }:
 
 buildPythonPackage rec {
@@ -31,7 +31,7 @@ buildPythonPackage rec {
   # https://github.com/pygraphviz/pygraphviz/pull/129
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python interface to Graphviz graph drawing package";
     homepage = "https://github.com/pygraphviz/pygraphviz";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pygreat/default.nix b/pkgs/development/python-modules/pygreat/default.nix
index bdced30f9831e..20a96d1f8f2c6 100644
--- a/pkgs/development/python-modules/pygreat/default.nix
+++ b/pkgs/development/python-modules/pygreat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchFromGitHub, future, pyusb }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchFromGitHub, future, pyusb }:
 
 buildPythonPackage {
   pname = "pygreat";
@@ -22,7 +22,7 @@ buildPythonPackage {
     echo "$version" > ../VERSION
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for talking with libGreat devices";
     homepage = "https://greatscottgadgets.com/greatfet/";
     license = with licenses; [ bsd3 ];
diff --git a/pkgs/development/python-modules/pygtk/default.nix b/pkgs/development/python-modules/pygtk/default.nix
index 4779f76aed462..22a44ce760792 100644
--- a/pkgs/development/python-modules/pygtk/default.nix
+++ b/pkgs/development/python-modules/pygtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, python, pkgconfig, gtk2, pygobject2, pycairo, pango
+{ lib, stdenv, fetchurl, fetchpatch, python, pkgconfig, gtk2, pygobject2, pycairo, pango
 , buildPythonPackage, libglade ? null, isPy3k }:
 
 buildPythonPackage rec {
@@ -65,7 +65,7 @@ buildPythonPackage rec {
                   $out/lib/${python.libPrefix}/site-packages/${pname}-${version}.pth
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK 2 Python bindings";
     homepage = "https://gitlab.gnome.org/Archive/pygtk";
     platforms = platforms.all;
diff --git a/pkgs/development/python-modules/pyhamcrest/1.nix b/pkgs/development/python-modules/pyhamcrest/1.nix
index 592172c6550d0..5df52d9b658cb 100644
--- a/pkgs/development/python-modules/pyhamcrest/1.nix
+++ b/pkgs/development/python-modules/pyhamcrest/1.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , mock, pytest
 , six
 }:
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   doCheck = false;  # pypi tarball does not include tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hamcrest/PyHamcrest";
     description = "Hamcrest framework for matcher objects";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pyhamcrest/default.nix b/pkgs/development/python-modules/pyhamcrest/default.nix
index 40469bd0deba6..a66e26b1319a2 100644
--- a/pkgs/development/python-modules/pyhamcrest/default.nix
+++ b/pkgs/development/python-modules/pyhamcrest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , mock, pytest
 , six
 }:
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   doCheck = false;  # pypi tarball does not include tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hamcrest/PyHamcrest";
     description = "Hamcrest framework for matcher objects";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pyhomematic/default.nix b/pkgs/development/python-modules/pyhomematic/default.nix
index 9534762f4e48d..502d648b40073 100644
--- a/pkgs/development/python-modules/pyhomematic/default.nix
+++ b/pkgs/development/python-modules/pyhomematic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pyhomematic";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Unreliable timing: https://github.com/danielperna84/pyhomematic/issues/126
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python 3 Interface to interact with Homematic devices";
     homepage = "https://github.com/danielperna84/pyhomematic";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyicu/default.nix b/pkgs/development/python-modules/pyicu/default.nix
index 9dcdfb64c93aa..3512e33c81d75 100644
--- a/pkgs/development/python-modules/pyicu/default.nix
+++ b/pkgs/development/python-modules/pyicu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -29,7 +29,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest ];
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/PyICU/";
     description = "Python extension wrapping the ICU C++ API";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyinotify/default.nix b/pkgs/development/python-modules/pyinotify/default.nix
index 7193fe118fd28..92c2f5bb67175 100644
--- a/pkgs/development/python-modules/pyinotify/default.nix
+++ b/pkgs/development/python-modules/pyinotify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests distributed
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/seb-m/pyinotify/wiki";
     description = "Monitor filesystems events on Linux platforms with inotify";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyinputevent/default.nix b/pkgs/development/python-modules/pyinputevent/default.nix
index 90d13ae07877e..a52a0bb400106 100644
--- a/pkgs/development/python-modules/pyinputevent/default.nix
+++ b/pkgs/development/python-modules/pyinputevent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage {
     sha256 = "0rkis0xp8f9jc00x7jb9kbvhdla24z1vl30djqa6wy6fx0cr6sib";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ntzrmtthihu777/pyinputevent";
     description = "Python interface to the Input Subsystem's input_event and uinput";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pykdtree/default.nix b/pkgs/development/python-modules/pykdtree/default.nix
index 9f355743ead22..f37ddb2483e12 100644
--- a/pkgs/development/python-modules/pykdtree/default.nix
+++ b/pkgs/development/python-modules/pykdtree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, numpy, nose, openmp }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, numpy, nose, openmp }:
 
 buildPythonPackage rec {
   pname = "pykdtree";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "kd-tree implementation for fast nearest neighbour search in Python";
     homepage = "https://github.com/storpipfugl/pykdtree";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pykerberos/default.nix b/pkgs/development/python-modules/pykerberos/default.nix
index 07db7e7002bdc..07a32a25a0c60 100644
--- a/pkgs/development/python-modules/pykerberos/default.nix
+++ b/pkgs/development/python-modules/pykerberos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, krb5 }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, krb5 }:
 
 buildPythonPackage rec {
   pname = "pykerberos";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # there are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-level interface to Kerberos";
     license     = licenses.asl20;
     maintainers = with maintainers; [ catern ];
diff --git a/pkgs/development/python-modules/pykickstart/default.nix b/pkgs/development/python-modules/pykickstart/default.nix
index 6461f0391caa3..bc10295e232a6 100644
--- a/pkgs/development/python-modules/pykickstart/default.nix
+++ b/pkgs/development/python-modules/pykickstart/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , urlgrabber
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     ${python.interpreter} tests/baseclass.py -vv
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fedoraproject.org/wiki/Pykickstart";
     description = "Read and write Fedora kickstart files";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/pylast/default.nix b/pkgs/development/python-modules/pylast/default.nix
index 3faf8d70fdf17..707554be55996 100644
--- a/pkgs/development/python-modules/pylast/default.nix
+++ b/pkgs/development/python-modules/pylast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, certifi, six
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, certifi, six
 , setuptools_scm
 }:
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # tests require last.fm credentials
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pylast/pylast";
     description = "A python interface to last.fm (and compatibles)";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pylibconfig2/default.nix b/pkgs/development/python-modules/pylibconfig2/default.nix
index 3c2a0be941df0..25989d0353e0a 100644
--- a/pkgs/development/python-modules/pylibconfig2/default.nix
+++ b/pkgs/development/python-modules/pylibconfig2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pyparsing }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pyparsing }:
 buildPythonPackage rec {
   pname = "pylibconfig2";
   version = "0.2.5";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyparsing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/heinzK1X/pylibconfig2";
     description = "Pure python library for libconfig syntax";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/pyliblo/default.nix b/pkgs/development/python-modules/pyliblo/default.nix
index 4c0a406bed349..454f08fd10ed7 100644
--- a/pkgs/development/python-modules/pyliblo/default.nix
+++ b/pkgs/development/python-modules/pyliblo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPyPy
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   buildInputs = [ liblo cython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://das.nasophon.de/pyliblo/";
     description = "Python wrapper for the liblo OSC library";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/pylibmc/default.nix b/pkgs/development/python-modules/pylibmc/default.nix
index 26d6e4fb6fb61..8bb62c0913480 100644
--- a/pkgs/development/python-modules/pylibmc/default.nix
+++ b/pkgs/development/python-modules/pylibmc/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchPypi, stdenv, libmemcached, zlib, cyrus_sasl }:
+{ buildPythonPackage, fetchPypi, lib, stdenv, libmemcached, zlib, cyrus_sasl }:
 
 buildPythonPackage rec {
   version = "1.6.1";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # requires an external memcached server running
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quick and small memcached client for Python";
     homepage = "http://sendapatch.se/projects/pylibmc/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pymaging/default.nix b/pkgs/development/python-modules/pymaging/default.nix
index 68a2e59b298c9..3b35ce3e71663 100644
--- a/pkgs/development/python-modules/pymaging/default.nix
+++ b/pkgs/development/python-modules/pymaging/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage {
     sha256 = "18g3n7kfrark30l4vzykh0gdbnfv5wb1zvvjbs17sj6yampypn38";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python imaging library with Python 2.6, 2.7, 3.1+ support";
     homepage    = "http://pymaging.rtfd.org";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pymaging_png/default.nix b/pkgs/development/python-modules/pymaging_png/default.nix
index 9bf2559e2f0c2..64ea5b4ff5b0a 100644
--- a/pkgs/development/python-modules/pymaging_png/default.nix
+++ b/pkgs/development/python-modules/pymaging_png/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pymaging
@@ -17,7 +17,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ pymaging ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python imaging library with Python 2.6, 2.7, 3.1+ support";
     homepage    = "https://github.com/ojii/pymaging-png/";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pymatgen/default.nix b/pkgs/development/python-modules/pymatgen/default.nix
index ce89cb1e079e6..84fcdbef6a3fd 100644
--- a/pkgs/development/python-modules/pymatgen/default.nix
+++ b/pkgs/development/python-modules/pymatgen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , enum34
 , glibcLocales
 , matplotlib
@@ -53,7 +53,7 @@ buildPythonPackage rec {
   # No tests in pypi tarball.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A robust materials analysis code that defines core object representations for structures and molecules";
     homepage = "https://pymatgen.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pymediainfo/default.nix b/pkgs/development/python-modules/pymediainfo/default.nix
index 8438df73c1c47..b04276f1f5596 100644
--- a/pkgs/development/python-modules/pymediainfo/default.nix
+++ b/pkgs/development/python-modules/pymediainfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , libmediainfo
 , setuptools_scm
 , pytest, glibcLocales }:
@@ -31,7 +31,7 @@ buildPythonPackage rec {
     py.test -k 'not test_parse_url' tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper for the mediainfo library";
     homepage = "https://github.com/sbraz/pymediainfo";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pymeeus/default.nix b/pkgs/development/python-modules/pymeeus/default.nix
index 4c8097325bccd..96fb9d6f6943e 100644
--- a/pkgs/development/python-modules/pymeeus/default.nix
+++ b/pkgs/development/python-modules/pymeeus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "PyMeeus";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     pytest .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/architest/pymeeus";
     description = "Library of astronomical algorithms";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pymemoize/default.nix b/pkgs/development/python-modules/pymemoize/default.nix
index 4efafeaaca423..b44ff9fef4912 100644
--- a/pkgs/development/python-modules/pymemoize/default.nix
+++ b/pkgs/development/python-modules/pymemoize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , django
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # django.core.exceptions.ImproperlyConfigured: Requested settings, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple Python cache and memoizing module";
     homepage = "https://github.com/mikeboers/PyMemoize";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pymetar/default.nix b/pkgs/development/python-modules/pymetar/default.nix
index 6896eaa097ec4..84139091ae49c 100644
--- a/pkgs/development/python-modules/pymetar/default.nix
+++ b/pkgs/development/python-modules/pymetar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python, buildPythonPackage, isPy3k, fetchPypi }:
+{ lib, stdenv, python, buildPythonPackage, isPy3k, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pymetar";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     ./runtests.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line tool to show the weather report by a given station ID";
     homepage = "http://www.schwarzvogel.de/software/pymetar.html";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/pymetno/default.nix b/pkgs/development/python-modules/pymetno/default.nix
index 92e26c4f6e536..2b10e2f164fb9 100644
--- a/pkgs/development/python-modules/pymetno/default.nix
+++ b/pkgs/development/python-modules/pymetno/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , aiohttp
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "metno"];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library to communicate with the met.no api";
     homepage = "https://github.com/Danielhiversen/pyMetno/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pympler/default.nix b/pkgs/development/python-modules/pympler/default.nix
index f80c91e8f2ddb..856458bf043f8 100644
--- a/pkgs/development/python-modules/pympler/default.nix
+++ b/pkgs/development/python-modules/pympler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   doCheck = stdenv.hostPlatform.isLinux;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to measure, monitor and analyze memory behavior";
     homepage = "https://pythonhosted.org/Pympler/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pymsgbox/default.nix b/pkgs/development/python-modules/pymsgbox/default.nix
index d844144addbcd..d69c0011ac539 100644
--- a/pkgs/development/python-modules/pymsgbox/default.nix
+++ b/pkgs/development/python-modules/pymsgbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, tkinter }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, tkinter }:
 
 buildPythonPackage rec {
   pname = "PyMsgBox";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # Finding tests fails
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple, cross-platform, pure Python module for JavaScript-like message boxes";
     homepage = "https://github.com/asweigart/PyMsgBox";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pymupdf/default.nix b/pkgs/development/python-modules/pymupdf/default.nix
index 30df7589c9ee2..8ce7d5a19c6f5 100644
--- a/pkgs/development/python-modules/pymupdf/default.nix
+++ b/pkgs/development/python-modules/pymupdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, mupdf, swig }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, mupdf, swig }:
 buildPythonPackage rec {
   pname = "pymupdf";
   version = "1.18.0";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for MuPDF's rendering library.";
     homepage = "https://github.com/pymupdf/PyMuPDF";
     maintainers = with maintainers; [ teto ];
diff --git a/pkgs/development/python-modules/pymysqlsa/default.nix b/pkgs/development/python-modules/pymysqlsa/default.nix
index 16c0e1a58d3fa..6009b03e50866 100644
--- a/pkgs/development/python-modules/pymysqlsa/default.nix
+++ b/pkgs/development/python-modules/pymysqlsa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pymysql
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pymysql sqlalchemy ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PyMySQL dialect for SQL Alchemy";
     homepage = "https://pypi.python.org/pypi/pymysql_sa";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pynac/default.nix b/pkgs/development/python-modules/pynac/default.nix
index 69233adc264e6..656825a36bbb1 100644
--- a/pkgs/development/python-modules/pynac/default.nix
+++ b/pkgs/development/python-modules/pynac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 }:
@@ -12,7 +12,7 @@ buildPythonPackage {
     sha256 = "0avzqqcxl54karjmla9jbsyid98mva36lxahwmrsx5h40ys2ggxp";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/se-esss-litterbox/Pynac";
     description = "A Python wrapper around the Dynac charged particle simulator";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/pynacl/default.nix b/pkgs/development/python-modules/pynacl/default.nix
index dfce6652d03a6..be69bf3d8023c 100644
--- a/pkgs/development/python-modules/pynacl/default.nix
+++ b/pkgs/development/python-modules/pynacl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ va1entin ];
     description = "Python binding to the Networking and Cryptography (NaCl) library";
     homepage = "https://github.com/pyca/pynacl/";
diff --git a/pkgs/development/python-modules/pync/default.nix b/pkgs/development/python-modules/pync/default.nix
index b7c819c4593da..20811f2df9d73 100644
--- a/pkgs/development/python-modules/pync/default.nix
+++ b/pkgs/development/python-modules/pync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     sed -i 's|^\([ ]*\)self.bin_path.*$|\1self.bin_path = "${pkgs.terminal-notifier}/bin/terminal-notifier"|' build/lib/pync/TerminalNotifier.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Wrapper for Mac OS 10.8 Notification Center";
     homepage    = "https://pypi.python.org/pypi/pync/1.4";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pynest2d/default.nix b/pkgs/development/python-modules/pynest2d/default.nix
index 3a7c6b43392b8..6214f3db42b2d 100644
--- a/pkgs/development/python-modules/pynest2d/default.nix
+++ b/pkgs/development/python-modules/pynest2d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python3, cmake
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python3, cmake
 , pythonOlder, libnest2d, sip, clipper }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
      sed -i 's#''${Python3_SITEARCH}#${placeholder "out"}/${python3.sitePackages}#' cmake/SIPMacros.cmake
    '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for libnest2d";
     homepage = "https://github.com/Ultimaker/pynest2d";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pynisher/default.nix b/pkgs/development/python-modules/pynisher/default.nix
index e2ead68d11b93..0ecac704e1e85 100644
--- a/pkgs/development/python-modules/pynisher/default.nix
+++ b/pkgs/development/python-modules/pynisher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, psutil, docutils }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, psutil, docutils }:
 
 buildPythonPackage rec {
   pname = "pynisher";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # no tests in the Pypi archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The pynisher is a little module intended to limit a functions resources.";
     homepage = "https://github.com/sfalkner/pynisher";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pynput/default.nix b/pkgs/development/python-modules/pynput/default.nix
index b525f22b2d343..5f193a8ab3510 100644
--- a/pkgs/development/python-modules/pynput/default.nix
+++ b/pkgs/development/python-modules/pynput/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, sphinx, setuptools-lint, xlib, evdev }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, sphinx, setuptools-lint, xlib, evdev }:
 
 buildPythonPackage rec {
   pname = "pynput";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library to control and monitor input devices";
     homepage = "https://github.com/moses-palmer/pynput";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pynzb/default.nix b/pkgs/development/python-modules/pynzb/default.nix
index 530a5e2e179ff..294c2374f537d 100644
--- a/pkgs/development/python-modules/pynzb/default.nix
+++ b/pkgs/development/python-modules/pynzb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Can't get them working
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ericflo/pynzb";
     description = "Unified API for parsing NZB files";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pyodbc/default.nix b/pkgs/development/python-modules/pyodbc/default.nix
index 7451b1102ed2a..2dec1d8705bb6 100644
--- a/pkgs/development/python-modules/pyodbc/default.nix
+++ b/pkgs/development/python-modules/pyodbc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPyPy, unixODBC }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPyPy, unixODBC }:
 
 buildPythonPackage rec {
   pname = "pyodbc";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false; # tests require a database server
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python ODBC module to connect to almost any database";
     homepage = "https://github.com/mkleehammer/pyodbc";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyopencl/default.nix b/pkgs/development/python-modules/pyopencl/default.nix
index 2977576876889..4171eaeeb57e4 100644
--- a/pkgs/development/python-modules/pyopencl/default.nix
+++ b/pkgs/development/python-modules/pyopencl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , Mako
@@ -40,7 +40,7 @@ buildPythonPackage rec {
   # gcc: error: pygpu_language_opencl.cpp: No such file or directory
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper for OpenCL";
     homepage = "https://github.com/pyopencl/pyopencl";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyopengl/default.nix b/pkgs/development/python-modules/pyopengl/default.nix
index 2a3b90733c46f..b2d62e3730d16 100644
--- a/pkgs/development/python-modules/pyopengl/default.nix
+++ b/pkgs/development/python-modules/pyopengl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -46,7 +46,7 @@ buildPythonPackage rec {
   # Should run test suite from $out/${python.sitePackages}
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pyopengl.sourceforge.net/";
     description = "PyOpenGL, the Python OpenGL bindings";
     longDescription = ''
diff --git a/pkgs/development/python-modules/pypandoc/default.nix b/pkgs/development/python-modules/pypandoc/default.nix
index 3da9c3ae0a7cf..ffe7bf014232f 100644
--- a/pkgs/development/python-modules/pypandoc/default.nix
+++ b/pkgs/development/python-modules/pypandoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch
 , pandoc, haskellPackages, texlive }:
 
 buildPythonPackage rec {
@@ -32,7 +32,7 @@ buildPythonPackage rec {
     export PATH="${haskellPackages.pandoc-citeproc}/bin:${texlive.combined.scheme-small}/bin:$PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Thin wrapper for pandoc";
     homepage = "https://github.com/bebraw/pypandoc";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyparted/default.nix b/pkgs/development/python-modules/pyparted/default.nix
index c51c55a5eb238..b6768ad992d14 100644
--- a/pkgs/development/python-modules/pyparted/default.nix
+++ b/pkgs/development/python-modules/pyparted/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , isPyPy
@@ -47,7 +47,7 @@ buildPythonPackage rec {
     make test PYTHON=${python.executable}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dcantrell/pyparted/";
     description = "Python interface for libparted";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/pypdf/default.nix b/pkgs/development/python-modules/pypdf/default.nix
index 5842e1c510af6..d69b1078aeeff 100644
--- a/pkgs/development/python-modules/pypdf/default.nix
+++ b/pkgs/development/python-modules/pypdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # Not supported. Package is no longer maintained.
   disabled = isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure-Python PDF toolkit";
     homepage = "http://pybrary.net/pyPdf/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pypdf2/default.nix b/pkgs/development/python-modules/pypdf2/default.nix
index 1c3b908396ec4..cd91cc347a4f9 100644
--- a/pkgs/development/python-modules/pypdf2/default.nix
+++ b/pkgs/development/python-modules/pypdf2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , glibcLocales
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # Tests broken on Python 3.x
   doCheck = !(isPy3k);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Pure-Python library built as a PDF toolkit";
     homepage = "http://mstamy2.github.com/PyPDF2/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pypeg2/default.nix b/pkgs/development/python-modules/pypeg2/default.nix
index 7aa0f2eda42cf..1f16a307a0c1b 100644
--- a/pkgs/development/python-modules/pypeg2/default.nix
+++ b/pkgs/development/python-modules/pypeg2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   #https://bitbucket.org/fdik/pypeg/issues/36/test-failures-on-py35
   doCheck = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PEG parser interpreter in Python";
     homepage = "http://fdik.org/pyPEG";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/pyphen/default.nix b/pkgs/development/python-modules/pyphen/default.nix
index b5018e40d7eba..d8b9abcf97a39 100644
--- a/pkgs/development/python-modules/pyphen/default.nix
+++ b/pkgs/development/python-modules/pyphen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "Pyphen";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "719b21dfb4b04fbc11cc0f6112418535fe35474021120cccfffc43a25fe63128";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python module to hyphenate text";
     homepage = "https://github.com/Kozea/Pyphen";
     license = with licenses; [gpl2 lgpl21 mpl20];
diff --git a/pkgs/development/python-modules/pypillowfight/default.nix b/pkgs/development/python-modules/pypillowfight/default.nix
index feb1f9451bca6..bc0e453599906 100644
--- a/pkgs/development/python-modules/pypillowfight/default.nix
+++ b/pkgs/development/python-modules/pypillowfight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitLab, nose, pillow
+{ lib, stdenv, buildPythonPackage, fetchFromGitLab, nose, pillow
 , isPy3k, isPyPy
 }:
 buildPythonPackage rec {
@@ -30,7 +30,7 @@ buildPythonPackage rec {
   buildInputs = [ nose ];
   propagatedBuildInputs = [ pillow ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library containing various image processing algorithms";
     inherit (src.meta) homepage;
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/pyplatec/default.nix b/pkgs/development/python-modules/pyplatec/default.nix
index 78d939bca1cf3..8747840fd7c0c 100644
--- a/pkgs/development/python-modules/pyplatec/default.nix
+++ b/pkgs/development/python-modules/pyplatec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0kqx33flcrrlipccmqs78d14pj5749bp85b6k5fgaq2c7yzz02jg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library to simulate plate tectonics with Python bindings";
     homepage    = "https://github.com/Mindwerks/plate-tectonics";
     license     = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pypoppler/default.nix b/pkgs/development/python-modules/pypoppler/default.nix
index 3287c70db9cb1..83190bc292ab1 100644
--- a/pkgs/development/python-modules/pypoppler/default.nix
+++ b/pkgs/development/python-modules/pypoppler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -32,7 +32,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://code.launchpad.net/~mriedesel/poppler-python/main";
     description = "Python bindings for poppler-glib, unofficial branch including bug fixes, and removal of gtk dependencies";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/pyprind/default.nix b/pkgs/development/python-modules/pyprind/default.nix
index 42c99c3008837..d270136558fc5 100644
--- a/pkgs/development/python-modules/pyprind/default.nix
+++ b/pkgs/development/python-modules/pyprind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , psutil
 , pytest }:
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Progress Bar and Percent Indicator Utility";
     homepage = "https://github.com/rasbt/pyprind";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pyptlib/default.nix b/pkgs/development/python-modules/pyptlib/default.nix
index f820f161de566..af2575d21431b 100644
--- a/pkgs/development/python-modules/pyptlib/default.nix
+++ b/pkgs/development/python-modules/pyptlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = false;  # No such file or directory errors on 32bit
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.org/project/pyptlib/";
     description = "A python implementation of the Pluggable Transports for Circumvention specification for Tor";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/pypugjs/default.nix b/pkgs/development/python-modules/pypugjs/default.nix
index e6bf3b9211afe..b806177b4d7d7 100644
--- a/pkgs/development/python-modules/pypugjs/default.nix
+++ b/pkgs/development/python-modules/pypugjs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, six, chardet, nose
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, six, chardet, nose
 , django, jinja2, tornado, pyramid, pyramid_mako, Mako }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     nosetests pypugjs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PugJS syntax template adapter for Django, Jinja2, Mako and Tornado templates";
     homepage = "https://github.com/kakulukia/pypugjs";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyqtgraph/default.nix b/pkgs/development/python-modules/pyqtgraph/default.nix
index 80f9142948482..98b30b247077c 100644
--- a/pkgs/development/python-modules/pyqtgraph/default.nix
+++ b/pkgs/development/python-modules/pyqtgraph/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "pyqtgraph" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scientific Graphics and GUI Library for Python";
     homepage = "http://www.pyqtgraph.org/";
     changelog = "https://github.com/pyqtgraph/pyqtgraph/blob/master/CHANGELOG";
diff --git a/pkgs/development/python-modules/pyquery/default.nix b/pkgs/development/python-modules/pyquery/default.nix
index 6ba9cb91982b4..2496d9d968fc7 100644
--- a/pkgs/development/python-modules/pyquery/default.nix
+++ b/pkgs/development/python-modules/pyquery/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cssselect
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # circular dependency on webtest
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gawel/pyquery";
     description = "A jquery-like library for python";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pyramid/default.nix b/pkgs/development/python-modules/pyramid/default.nix
index a7ba7728a355f..5f1e5c7d75a85 100644
--- a/pkgs/development/python-modules/pyramid/default.nix
+++ b/pkgs/development/python-modules/pyramid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , webtest
@@ -33,7 +33,7 @@ buildPythonPackage rec {
   # https://github.com/Pylons/pyramid/issues/1899
   doCheck = !isPy35;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Pyramid Web Framework, a Pylons project";
     homepage = "https://trypyramid.com/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pyramid_beaker/default.nix b/pkgs/development/python-modules/pyramid_beaker/default.nix
index 19b26a30ad712..88dc62886fc6f 100644
--- a/pkgs/development/python-modules/pyramid_beaker/default.nix
+++ b/pkgs/development/python-modules/pyramid_beaker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, beaker, pyramid }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, beaker, pyramid }:
 
 buildPythonPackage rec {
   pname = "pyramid_beaker";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ beaker pyramid ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ domenkozar ];
   };
 }
diff --git a/pkgs/development/python-modules/pyramid_chameleon/default.nix b/pkgs/development/python-modules/pyramid_chameleon/default.nix
index 9e148ca8ed515..2bb5a03bdb912 100644
--- a/pkgs/development/python-modules/pyramid_chameleon/default.nix
+++ b/pkgs/development/python-modules/pyramid_chameleon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , chameleon
@@ -23,7 +23,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ chameleon pyramid zope_interface setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chameleon template compiler for pyramid";
     homepage = "https://github.com/Pylons/pyramid_chameleon";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pyramid_exclog/default.nix b/pkgs/development/python-modules/pyramid_exclog/default.nix
index 0c2abeb74e282..80514cc91b481 100644
--- a/pkgs/development/python-modules/pyramid_exclog/default.nix
+++ b/pkgs/development/python-modules/pyramid_exclog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyramid
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyramid ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A package which logs to a Python logger when an exception is raised by a Pyramid application";
     homepage = "https://docs.pylonsproject.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pyramid_hawkauth/default.nix b/pkgs/development/python-modules/pyramid_hawkauth/default.nix
index fc76d9af68d9e..ab4025b72309e 100644
--- a/pkgs/development/python-modules/pyramid_hawkauth/default.nix
+++ b/pkgs/development/python-modules/pyramid_hawkauth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pyramid
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ pyramid hawkauthlib tokenlib ];
   buildInputs = [ webtest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mozilla-services/pyramid_hawkauth";
     description = "A Pyramid authentication plugin for HAWK";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/pyramid_jinja2/default.nix b/pkgs/development/python-modules/pyramid_jinja2/default.nix
index 6be0fe479d2ff..0497ab79613f2 100644
--- a/pkgs/development/python-modules/pyramid_jinja2/default.nix
+++ b/pkgs/development/python-modules/pyramid_jinja2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , webtest
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   buildInputs = [ webtest ];
   propagatedBuildInputs = [ jinja2 pyramid ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jinja2 template bindings for the Pyramid web framework";
     homepage = "https://github.com/Pylons/pyramid_jinja2";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pyramid_mako/default.nix b/pkgs/development/python-modules/pyramid_mako/default.nix
index 2bae93d1e306e..8c71563e2d773 100644
--- a/pkgs/development/python-modules/pyramid_mako/default.nix
+++ b/pkgs/development/python-modules/pyramid_mako/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , webtest
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   buildInputs = [ webtest ];
   propagatedBuildInputs = [ pyramid Mako ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Pylons/pyramid_mako";
     description = "Mako template bindings for the Pyramid web framework";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pyramid_multiauth/default.nix b/pkgs/development/python-modules/pyramid_multiauth/default.nix
index f441aaed8c13f..9167918fc47d3 100644
--- a/pkgs/development/python-modules/pyramid_multiauth/default.nix
+++ b/pkgs/development/python-modules/pyramid_multiauth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyramid
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyramid ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Authentication policy for Pyramid that proxies to a stack of other authentication policies";
     homepage = "https://github.com/mozilla-services/pyramid_multiauth";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/pyreport/default.nix b/pkgs/development/python-modules/pyreport/default.nix
index 9795d30ea2e2d..09a1e7c6b4180 100644
--- a/pkgs/development/python-modules/pyreport/default.nix
+++ b/pkgs/development/python-modules/pyreport/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/pyreport";
     license = licenses.bsd0;
     description = "Pyreport makes notes out of a python script";
diff --git a/pkgs/development/python-modules/pyres/default.nix b/pkgs/development/python-modules/pyres/default.nix
index d4bd8789144af..6d49bd025948c 100644
--- a/pkgs/development/python-modules/pyres/default.nix
+++ b/pkgs/development/python-modules/pyres/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, fetchFromGitHub, simplejson, redis, setproctitle, nose, pkgs }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, fetchFromGitHub, simplejson, redis, setproctitle, nose, pkgs }:
 
 let
 
@@ -36,7 +36,7 @@ buildPythonPackage rec {
     nosetests . --exclude test_worker_pids
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python resque clone";
     homepage = "https://github.com/binarydud/pyres";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyrfc3339/default.nix b/pkgs/development/python-modules/pyrfc3339/default.nix
index 3c157d83fec1b..f6be3c4c8974b 100644
--- a/pkgs/development/python-modules/pyrfc3339/default.nix
+++ b/pkgs/development/python-modules/pyrfc3339/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytz
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ pytz ];
   buildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate and parse RFC 3339 timestamps";
     homepage = "https://github.com/kurtraschke/pyRFC3339";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyro4/default.nix b/pkgs/development/python-modules/pyro4/default.nix
index 508722e70fb4f..a84b22e06567d 100644
--- a/pkgs/development/python-modules/pyro4/default.nix
+++ b/pkgs/development/python-modules/pyro4/default.nix
@@ -48,7 +48,7 @@ buildPythonPackage rec {
   # otherwise the tests hang the build
   __darwinAllowLocalNetworking = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Distributed object middleware for Python (RPC)";
     homepage = "https://github.com/irmen/Pyro4";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyroma/default.nix b/pkgs/development/python-modules/pyroma/default.nix
index 4ec06506b38b7..e533f6501697d 100644
--- a/pkgs/development/python-modules/pyroma/default.nix
+++ b/pkgs/development/python-modules/pyroma/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , docutils, pygments, setuptools
 }:
 
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ docutils pygments setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test your project's packaging friendliness";
     homepage = "https://github.com/regebro/pyroma";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyroute2/default.nix b/pkgs/development/python-modules/pyroute2/default.nix
index b7dfd6d42b3dd..f2378863720c4 100644
--- a/pkgs/development/python-modules/pyroute2/default.nix
+++ b/pkgs/development/python-modules/pyroute2/default.nix
@@ -1,4 +1,4 @@
-{stdenv, buildPythonPackage, fetchPypi}:
+{lib, stdenv, buildPythonPackage, fetchPypi}:
 
 buildPythonPackage rec {
   pname = "pyroute2";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # requires root priviledges
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Netlink library";
     homepage = "https://github.com/svinota/pyroute2";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pyrr/default.nix b/pkgs/development/python-modules/pyrr/default.nix
index 96d160619588a..f8ac5d8e86759 100644
--- a/pkgs/development/python-modules/pyrr/default.nix
+++ b/pkgs/development/python-modules/pyrr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   buildInputs = [ setuptools ];
   propagatedBuildInputs = [ multipledispatch numpy ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "3D mathematical functions using NumPy";
     homepage = "https://github.com/adamlwgriffiths/Pyrr/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/pyrsistent/default.nix b/pkgs/development/python-modules/pyrsistent/default.nix
index 7da3239f3e74c..211bc85f5112e 100644
--- a/pkgs/development/python-modules/pyrsistent/default.nix
+++ b/pkgs/development/python-modules/pyrsistent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace 'pytest<5' 'pytest'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tobgu/pyrsistent/";
     description = "Persistent/Functional/Immutable data structures";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyrss2gen/default.nix b/pkgs/development/python-modules/pyrss2gen/default.nix
index ee51e84ba0f40..e3586e6dbf1c4 100644
--- a/pkgs/development/python-modules/pyrss2gen/default.nix
+++ b/pkgs/development/python-modules/pyrss2gen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.dalkescientific.om/Python/PyRSS2Gen.html";
     description = "Library for generating RSS 2.0 feeds";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/pysaml2/default.nix b/pkgs/development/python-modules/pysaml2/default.nix
index f30fddc1efd85..7d2fdb5b42601 100644
--- a/pkgs/development/python-modules/pysaml2/default.nix
+++ b/pkgs/development/python-modules/pysaml2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchFromGitHub
@@ -53,7 +53,7 @@ buildPythonPackage rec {
             and not test_conf_syslog"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rohe/pysaml2";
     description = "Python implementation of SAML Version 2 Standard";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pyscss/default.nix b/pkgs/development/python-modules/pyscss/default.nix
index 30b5205050ddc..87f23b8edf7c1 100644
--- a/pkgs/development/python-modules/pyscss/default.nix
+++ b/pkgs/development/python-modules/pyscss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pytest
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Scss compiler for Python";
     homepage = "https://pyscss.readthedocs.org/en/latest/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pysendfile/default.nix b/pkgs/development/python-modules/pysendfile/default.nix
index b49ec5030f9a4..a35f2ae77f02d 100644
--- a/pkgs/development/python-modules/pysendfile/default.nix
+++ b/pkgs/development/python-modules/pysendfile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     ${python.executable} test/test_sendfile.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/giampaolo/pysendfile";
     description = "A Python interface to sendfile(2)";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pysensors/default.nix b/pkgs/development/python-modules/pysensors/default.nix
index cc2dee7957d8d..214412c4ceede 100644
--- a/pkgs/development/python-modules/pysensors/default.nix
+++ b/pkgs/development/python-modules/pysensors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, python, fetchFromGitHub, lm_sensors }:
+{ lib, stdenv, buildPythonPackage, python, fetchFromGitHub, lm_sensors }:
 buildPythonPackage {
   version = "2017-07-13";
   pname = "pysensors";
@@ -22,7 +22,7 @@ buildPythonPackage {
     ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ guibou ];
     description = "Easy hardware health monitoring in Python for Linux systems";
     homepage = "https://pysensors.readthedocs.org";
diff --git a/pkgs/development/python-modules/pyserial-asyncio/default.nix b/pkgs/development/python-modules/pyserial-asyncio/default.nix
index 5e721504eda59..ff3d624490bae 100644
--- a/pkgs/development/python-modules/pyserial-asyncio/default.nix
+++ b/pkgs/development/python-modules/pyserial-asyncio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , pyserial }:
 
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyserial ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "asyncio extension package for pyserial";
     homepage = "https://github.com/pyserial/pyserial-asyncio";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pysftp/default.nix b/pkgs/development/python-modules/pysftp/default.nix
index 61fc4f122d291..28daf6b385e61 100644
--- a/pkgs/development/python-modules/pysftp/default.nix
+++ b/pkgs/development/python-modules/pysftp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ paramiko ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/dundeemt/pysftp";
     description = "A friendly face on SFTP";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyshp/default.nix b/pkgs/development/python-modules/pyshp/default.nix
index 33ebe945b2312..661c70a0ab26d 100644
--- a/pkgs/development/python-modules/pyshp/default.nix
+++ b/pkgs/development/python-modules/pyshp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , setuptools }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   buildInputs = [ setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure Python read/write support for ESRI Shapefile format";
     homepage = "https://github.com/GeospatialPython/pyshp";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyside2-tools/default.nix b/pkgs/development/python-modules/pyside2-tools/default.nix
index 9f1f94ffecbb5..095a10c1047dc 100644
--- a/pkgs/development/python-modules/pyside2-tools/default.nix
+++ b/pkgs/development/python-modules/pyside2-tools/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, wrapPython, python, fetchurl, stdenv, cmake, qt5,
+{ buildPythonPackage, wrapPython, python, fetchurl, lib, stdenv, cmake, qt5,
   shiboken2, pyside2 }:
 
 stdenv.mkDerivation {
@@ -41,7 +41,7 @@ stdenv.mkDerivation {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PySide2 development tools";
     license = licenses.gpl2;
     homepage = "https://wiki.qt.io/Qt_for_Python";
diff --git a/pkgs/development/python-modules/pyside2/default.nix b/pkgs/development/python-modules/pyside2/default.nix
index 8133b677db28b..6986c8e5384bf 100644
--- a/pkgs/development/python-modules/pyside2/default.nix
+++ b/pkgs/development/python-modules/pyside2/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, python, fetchurl, stdenv,
+{ buildPythonPackage, python, fetchurl, lib, stdenv,
   cmake, ninja, qt5, shiboken2 }:
 
 stdenv.mkDerivation rec {
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
   ];
   propagatedBuildInputs = [ shiboken2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LGPL-licensed Python bindings for Qt";
     license = licenses.lgpl21;
     homepage = "https://wiki.qt.io/Qt_for_Python";
diff --git a/pkgs/development/python-modules/pysigset/default.nix b/pkgs/development/python-modules/pysigset/default.nix
index 4e1b87a1f1b0d..8e31735db2e42 100644
--- a/pkgs/development/python-modules/pysigset/default.nix
+++ b/pkgs/development/python-modules/pysigset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "pysigset";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "0ym44z3nwp8chfi7snmknkqnl2q9bghzv9p923r8w748i5hvyxx8";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides access to sigprocmask(2) and friends and convenience wrappers to python application developers wanting to SIG_BLOCK and SIG_UNBLOCK signals";
     homepage = "https://github.com/ossobv/pysigset";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/pysmbc/default.nix b/pkgs/development/python-modules/pysmbc/default.nix
index e242dbe5e96e3..eff4dd58c1dbb 100644
--- a/pkgs/development/python-modules/pysmbc/default.nix
+++ b/pkgs/development/python-modules/pysmbc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , samba, pkgconfig
 , setuptools }:
 
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ setuptools samba ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "libsmbclient binding for Python";
     homepage = "https://github.com/hamano/pysmbc";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/pysmf/default.nix b/pkgs/development/python-modules/pysmf/default.nix
index ef5e560b08c7f..02559510100cd 100644
--- a/pkgs/development/python-modules/pysmf/default.nix
+++ b/pkgs/development/python-modules/pysmf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pkg-config, libsmf, glib, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pkg-config, libsmf, glib, pytest }:
 
 buildPythonPackage rec {
   pname = "pysmf";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   nativeBuildInputs = [ pkg-config pytest ];
   buildInputs = [ libsmf glib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://das.nasophon.de/pysmf/";
     description = "Python extension module for reading and writing Standard MIDI Files, based on libsmf.";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/pysmi/default.nix b/pkgs/development/python-modules/pysmi/default.nix
index a3a7c3d7ec102..953581aa30298 100644
--- a/pkgs/development/python-modules/pysmi/default.nix
+++ b/pkgs/development/python-modules/pysmi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , ply
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Tests require pysnmp, which in turn requires pysmi => infinite recursion
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pysmi.sf.net";
     description = "SNMP SMI/MIB Parser";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/pysnmp/default.nix b/pkgs/development/python-modules/pysnmp/default.nix
index c0bed855a4cd8..7dce4d9b4d183 100644
--- a/pkgs/development/python-modules/pysnmp/default.nix
+++ b/pkgs/development/python-modules/pysnmp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyasn1
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyasn1 pycryptodomex pysmi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://snmplabs.com/pysnmp/index.html";
     description = "A pure-Python SNMPv1/v2c/v3 library";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/pysocks/default.nix b/pkgs/development/python-modules/pysocks/default.nix
index e8d853d625d4a..79c163726b76d 100644
--- a/pkgs/development/python-modules/pysocks/default.nix
+++ b/pkgs/development/python-modules/pysocks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SOCKS module for Python";
     license     = licenses.bsd3;
     maintainers = with maintainers; [ thoughtpolice ];
diff --git a/pkgs/development/python-modules/pyspark/default.nix b/pkgs/development/python-modules/pyspark/default.nix
index d181d6a29d907..342755131a3d4 100644
--- a/pkgs/development/python-modules/pyspark/default.nix
+++ b/pkgs/development/python-modules/pyspark/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchPypi, stdenv, py4j }:
+{ buildPythonPackage, fetchPypi, lib, stdenv, py4j }:
 
 buildPythonPackage rec {
   pname = "pyspark";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # Tests assume running spark...
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Apache Spark";
     homepage = "https://github.com/apache/spark/tree/master/python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pyspice/default.nix b/pkgs/development/python-modules/pyspice/default.nix
index bed00ddabe7dd..53fb7e6d248f0 100644
--- a/pkgs/development/python-modules/pyspice/default.nix
+++ b/pkgs/development/python-modules/pyspice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pythonOlder
 , fetchPypi
@@ -44,7 +44,7 @@ buildPythonPackage rec {
         "ffi.dlopen('${libngspice}/lib/libngspice${stdenv.hostPlatform.extensions.sharedLibrary}')"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simulate electronic circuit using Python and the Ngspice / Xyce simulators";
     homepage = "https://github.com/FabriceSalvaire/PySpice";
     license = licenses.gpl3Only;
diff --git a/pkgs/development/python-modules/pyspotify/default.nix b/pkgs/development/python-modules/pyspotify/default.nix
index d6d0a6007f661..a6bf14cdca08e 100644
--- a/pkgs/development/python-modules/pyspotify/default.nix
+++ b/pkgs/development/python-modules/pyspotify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , cffi
@@ -33,7 +33,7 @@ buildPythonPackage rec {
   # There are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://pyspotify.mopidy.com";
     description = "A Python interface to Spotify’s online music streaming service";
     license     = licenses.unfree;
diff --git a/pkgs/development/python-modules/pyspread/default.nix b/pkgs/development/python-modules/pyspread/default.nix
index 2e7f458253ea1..a14911b7a3eda 100644
--- a/pkgs/development/python-modules/pyspread/default.nix
+++ b/pkgs/development/python-modules/pyspread/default.nix
@@ -1,7 +1,7 @@
 { buildPythonPackage
 , fetchPypi
 , isPy3k
-, stdenv
+, lib, stdenv
 , numpy
 , wxPython
 , matplotlib
@@ -48,7 +48,7 @@ buildPythonPackage rec {
     cp $desktopItem/share/applications/* $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pyspread is a non-traditional spreadsheet application that is based on and written in the programming language Python";
     homepage = "https://manns.github.io/pyspread/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/pysqlite/default.nix b/pkgs/development/python-modules/pysqlite/default.nix
index a1916f09a6cd8..fec1bbd0beda4 100644
--- a/pkgs/development/python-modules/pysqlite/default.nix
+++ b/pkgs/development/python-modules/pysqlite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     ${stdenv.lib.optionalString (!stdenv.isDarwin) ''export LDSHARED="$CC -pthread -shared"''}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pysqlite.org/";
     description = "Python bindings for the SQLite embedded relational database engine";
     longDescription = ''
diff --git a/pkgs/development/python-modules/pysqueezebox/default.nix b/pkgs/development/python-modules/pysqueezebox/default.nix
index 11c9d9c40d067..7c5d8ca5abf58 100644
--- a/pkgs/development/python-modules/pysqueezebox/default.nix
+++ b/pkgs/development/python-modules/pysqueezebox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pythonOlder, aiohttp }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pythonOlder, aiohttp }:
 
 buildPythonPackage rec {
   pname = "pysqueezebox";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "pysqueezebox" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Asynchronous library to control Logitech Media Server";
     homepage = "https://github.com/rajlaud/pysqueezebox";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pysrt/default.nix b/pkgs/development/python-modules/pysrt/default.nix
index e8c9aa3d5c88c..4012a73246600 100644
--- a/pkgs/development/python-modules/pysrt/default.nix
+++ b/pkgs/development/python-modules/pysrt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , chardet
@@ -23,7 +23,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ chardet ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/byroot/pysrt";
     license = licenses.gpl3;
     description = "Python library used to edit or create SubRip files";
diff --git a/pkgs/development/python-modules/pyssim/default.nix b/pkgs/development/python-modules/pyssim/default.nix
index ad2057351d9ad..4f73ada61af61 100644
--- a/pkgs/development/python-modules/pyssim/default.nix
+++ b/pkgs/development/python-modules/pyssim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, numpy, scipy, pillow }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, numpy, scipy, pillow }:
 
 buildPythonPackage rec {
   pname = "pyssim";
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     $out/bin/pyssim --cw --width 128 --height 128 test-images/test3-orig.jpg test-images/test3-rot.jpg | grep 0.938
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Module for computing Structured Similarity Image Metric (SSIM) in Python";
     homepage = "https://github.com/jterrace/pyssim";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pystache/default.nix b/pkgs/development/python-modules/pystache/default.nix
index 1900bc31f2122..6ed036aecb1ad 100644
--- a/pkgs/development/python-modules/pystache/default.nix
+++ b/pkgs/development/python-modules/pystache/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, python, fetchPypi, isPy3k, glibcLocales }:
+{ lib, stdenv, buildPythonPackage, python, fetchPypi, isPy3k, glibcLocales }:
 
 buildPythonPackage rec {
   pname = "pystache";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # https://github.com/defunkt/pystache/issues/181
   doCheck = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A framework-agnostic, logic-free templating system inspired by ctemplate and et";
     homepage = "https://github.com/defunkt/pystache";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pystemd/default.nix b/pkgs/development/python-modules/pystemd/default.nix
index 1ff26ffa37baa..6918659194906 100644
--- a/pkgs/development/python-modules/pystemd/default.nix
+++ b/pkgs/development/python-modules/pystemd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python, systemd }:
+{ lib, stdenv, python, systemd }:
 
 python.pkgs.buildPythonPackage rec {
   pname = "pystemd";
@@ -15,7 +15,7 @@ python.pkgs.buildPythonPackage rec {
   checkInputs = with python.pkgs; [ pytest mock ];
   checkPhase = "pytest tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A thin Cython-based wrapper on top of libsystemd, focused on exposing the dbus API via sd-bus in an automated and easy to consume way.";
     homepage = "https://github.com/facebookincubator/pystemd/";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/python-modules/pystemmer/default.nix b/pkgs/development/python-modules/pystemmer/default.nix
index 37260404906bf..0ba23ffec5dfd 100644
--- a/pkgs/development/python-modules/pystemmer/default.nix
+++ b/pkgs/development/python-modules/pystemmer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python, fetchPypi, buildPythonPackage, cython }:
+{ lib, stdenv, python, fetchPypi, buildPythonPackage, cython }:
 
 buildPythonPackage rec {
   pname = "PyStemmer";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     ${python.interpreter} runtests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Snowball stemming algorithms, for information retrieval";
     homepage = "http://snowball.tartarus.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pysvn/default.nix b/pkgs/development/python-modules/pysvn/default.nix
index 0fca57cb2923d..9e9948607093c 100644
--- a/pkgs/development/python-modules/pysvn/default.nix
+++ b/pkgs/development/python-modules/pysvn/default.nix
@@ -75,7 +75,7 @@ buildPythonPackage rec {
     rm -v $out/share/doc/pysvn-${version}/generate_cpp_docs_from_html_docs.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for Subversion";
     homepage = "http://pysvn.tigris.org/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pytabix/default.nix b/pkgs/development/python-modules/pytabix/default.nix
index eb21ca1981808..db8437d8957c7 100644
--- a/pkgs/development/python-modules/pytabix/default.nix
+++ b/pkgs/development/python-modules/pytabix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   '';
   pythonImportsCheck = [ "tabix" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/slowkow/pytabix";
     description = "Python interface for tabix";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytado/default.nix b/pkgs/development/python-modules/pytado/default.nix
index 40b221d3dc9de..636210c93d599 100644
--- a/pkgs/development/python-modules/pytado/default.nix
+++ b/pkgs/development/python-modules/pytado/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub }:
 
 buildPythonPackage rec {
   pname = "PyTado";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "14xdfw4913g4j4h576hjbigm7fiw8k0dc8s98gh2ag9xrc2ifgr0";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python binding for Tado web API. Pythonize your central heating!";
     homepage = "https://github.com/wmalgadey/PyTado";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/pyte/default.nix b/pkgs/development/python-modules/pyte/default.nix
index f09bd95d0703a..65d3d9218d065 100644
--- a/pkgs/development/python-modules/pyte/default.nix
+++ b/pkgs/development/python-modules/pyte/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, pytestrunner, wcwidth }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, pytestrunner, wcwidth }:
 
 buildPythonPackage rec {
   pname = "pyte";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     py.test -k "not test_input_output"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple VTXXX-compatible linux terminal emulator";
     homepage = "https://github.com/selectel/pyte";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pytest-aiohttp/default.nix b/pkgs/development/python-modules/pytest-aiohttp/default.nix
index f2491bd571c1f..7384eb3607046 100644
--- a/pkgs/development/python-modules/pytest-aiohttp/default.nix
+++ b/pkgs/development/python-modules/pytest-aiohttp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, aiohttp }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, aiohttp }:
 
 buildPythonPackage rec {
   pname = "pytest-aiohttp";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # There are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/aio-libs/pytest-aiohttp/";
     description = "Pytest plugin for aiohttp support";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pytest-annotate/default.nix b/pkgs/development/python-modules/pytest-annotate/default.nix
index 53879bffbc8af..1a7f77bf9b6e5 100644
--- a/pkgs/development/python-modules/pytest-annotate/default.nix
+++ b/pkgs/development/python-modules/pytest-annotate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyannotate
@@ -30,7 +30,7 @@ buildPythonPackage rec {
   # no testing in a testing module...
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kensho-technologies/pytest-annotate";
     description = "Generate PyAnnotate annotations from your pytest tests";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pytest-ansible/default.nix b/pkgs/development/python-modules/pytest-ansible/default.nix
index 2e98654c5d460..309a33e89073e 100644
--- a/pkgs/development/python-modules/pytest-ansible/default.nix
+++ b/pkgs/development/python-modules/pytest-ansible/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , ansible
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     HOME=$TMPDIR pytest tests/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jlaska/pytest-ansible";
     description = "Plugin for py.test to simplify calling ansible modules from tests or fixtures";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-asyncio/default.nix b/pkgs/development/python-modules/pytest-asyncio/default.nix
index 8942263a5788c..961845a28e153 100644
--- a/pkgs/development/python-modules/pytest-asyncio/default.nix
+++ b/pkgs/development/python-modules/pytest-asyncio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, isPy3k, isPy35, async_generator }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, isPy3k, isPy35, async_generator }:
 buildPythonPackage rec {
   pname = "pytest-asyncio";
   version = "0.14.0";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     substituteInPlace setup.cfg --replace "license_file = LICENSE" ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "library for testing asyncio code with pytest";
     license = licenses.asl20;
     homepage = "https://github.com/pytest-dev/pytest-asyncio";
diff --git a/pkgs/development/python-modules/pytest-bdd/default.nix b/pkgs/development/python-modules/pytest-bdd/default.nix
index ccde881d38399..493a2307e7e7e 100644
--- a/pkgs/development/python-modules/pytest-bdd/default.nix
+++ b/pkgs/development/python-modules/pytest-bdd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , execnet
 , glob2
 , Mako
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     PATH=$PATH:$out/bin pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BDD library for the py.test runner";
     homepage = "https://github.com/pytest-dev/pytest-bdd";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-catchlog/default.nix b/pkgs/development/python-modules/pytest-catchlog/default.nix
index 35d3fce49d1b0..2fb02244d1d7c 100644
--- a/pkgs/development/python-modules/pytest-catchlog/default.nix
+++ b/pkgs/development/python-modules/pytest-catchlog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, unzip }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, unzip }:
 
 buildPythonPackage rec {
   pname = "pytest-catchlog";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # Requires pytest < 3.1
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     homepage = "https://pypi.python.org/pypi/pytest-catchlog/";
     description = "py.test plugin to catch log messages. This is a fork of pytest-capturelog.";
diff --git a/pkgs/development/python-modules/pytest-celery/default.nix b/pkgs/development/python-modules/pytest-celery/default.nix
index e3d463a39aa6e..034c657b5b0fe 100644
--- a/pkgs/development/python-modules/pytest-celery/default.nix
+++ b/pkgs/development/python-modules/pytest-celery/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, setuptools_scm }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, setuptools_scm }:
 
 buildPythonPackage rec {
   pname = "pytest-celery";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   doCheck = false; # This package has nothing to test or import.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "pytest plugin for unittest subTest() support and subtests fixture";
     homepage = "https://github.com/pytest-dev/pytest-subtests";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-check/default.nix b/pkgs/development/python-modules/pytest-check/default.nix
index 9636d20c73b73..41f316a18a659 100644
--- a/pkgs/development/python-modules/pytest-check/default.nix
+++ b/pkgs/development/python-modules/pytest-check/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ pytest ];
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "pytest plugin allowing multiple failures per test";
     homepage = "https://github.com/okken/pytest-check";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-cov/default.nix b/pkgs/development/python-modules/pytest-cov/default.nix
index 649e41f7d6629..aa921ddeb3d1b 100644
--- a/pkgs/development/python-modules/pytest-cov/default.nix
+++ b/pkgs/development/python-modules/pytest-cov/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, coverage }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin for coverage reporting with support for both centralised and distributed testing, including subprocesses and multiprocessing";
     homepage = "https://github.com/pytest-dev/pytest-cov";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-datadir/default.nix b/pkgs/development/python-modules/pytest-datadir/default.nix
index 6ce7844192068..b1cdb1033a64f 100644
--- a/pkgs/development/python-modules/pytest-datadir/default.nix
+++ b/pkgs/development/python-modules/pytest-datadir/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , setuptools_scm, pytest, cmake
 }:
 
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest ];
   checkPhase = "pytest";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gabrielcnr/pytest-datadir";
     description = "pytest plugin for manipulating test data directories and files";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-datafiles/default.nix b/pkgs/development/python-modules/pytest-datafiles/default.nix
index 2fafdcd1aaa09..bc6e2441b0f07 100644
--- a/pkgs/development/python-modules/pytest-datafiles/default.nix
+++ b/pkgs/development/python-modules/pytest-datafiles/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, py, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, py, pytest }:
 
 buildPythonPackage rec {
   pname = "pytest-datafiles";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
 
   buildInputs = [ py pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     homepage = "https://github.com/omarkohl/pytest-datafiles";
     description = "py.test plugin to create a 'tmpdir' containing predefined files/directories.";
diff --git a/pkgs/development/python-modules/pytest-dependency/default.nix b/pkgs/development/python-modules/pytest-dependency/default.nix
index 9e570a801f999..9a3dbed55b152 100644
--- a/pkgs/development/python-modules/pytest-dependency/default.nix
+++ b/pkgs/development/python-modules/pytest-dependency/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, pytest }:
 
 buildPythonPackage rec {
   version = "0.5.1";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/RKrahl/pytest-dependency";
     description = "Manage dependencies of tests";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pytest-django/default.nix b/pkgs/development/python-modules/pytest-django/default.nix
index 4b257b0a3d138..069aa2812eb58 100644
--- a/pkgs/development/python-modules/pytest-django/default.nix
+++ b/pkgs/development/python-modules/pytest-django/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # Complicated. Requires Django setup.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "py.test plugin for testing of Django applications";
     homepage = "https://pytest-django.readthedocs.org/en/latest/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pytest-factoryboy/default.nix b/pkgs/development/python-modules/pytest-factoryboy/default.nix
index 48c5020a44f88..66d7579d0ed18 100644
--- a/pkgs/development/python-modules/pytest-factoryboy/default.nix
+++ b/pkgs/development/python-modules/pytest-factoryboy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , pytestCheckHook
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   ];
   pytestFlagsArray = [ "--ignore=docs" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integration of factory_boy into the pytest runner.";
     homepage = "https://pytest-factoryboy.readthedocs.io/en/latest/";
     maintainers = with maintainers; [ winpat ];
diff --git a/pkgs/development/python-modules/pytest-fixture-config/default.nix b/pkgs/development/python-modules/pytest-fixture-config/default.nix
index 7c7d4c66cd47a..061f62bfc17bf 100644
--- a/pkgs/development/python-modules/pytest-fixture-config/default.nix
+++ b/pkgs/development/python-modules/pytest-fixture-config/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , setuptools-git, pytest }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple configuration objects for Py.test fixtures. Allows you to skip tests when their required config variables aren’t set.";
     homepage = "https://github.com/manahl/pytest-plugins";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-flakes/default.nix b/pkgs/development/python-modules/pytest-flakes/default.nix
index 440cc632185b1..fd4ed0978060e 100644
--- a/pkgs/development/python-modules/pytest-flakes/default.nix
+++ b/pkgs/development/python-modules/pytest-flakes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , pytest
 , pyflakes
 }:
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     py.test test_flakes.py -k 'not test_syntax_error'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     homepage = "https://pypi.python.org/pypi/pytest-flakes";
     description = "pytest plugin to check source code with pyflakes";
diff --git a/pkgs/development/python-modules/pytest-flask/default.nix b/pkgs/development/python-modules/pytest-flask/default.nix
index 1e6c34aee3c0d..74e33a7731b37 100644
--- a/pkgs/development/python-modules/pytest-flask/default.nix
+++ b/pkgs/development/python-modules/pytest-flask/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, flask, werkzeug, setuptools_scm, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, flask, werkzeug, setuptools_scm, isPy27 }:
 
 buildPythonPackage rec {
   pname = "pytest-flask";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   nativeBuildInputs = [ setuptools_scm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pytest-dev/pytest-flask/";
     license = licenses.mit;
     description = "A set of py.test fixtures to test Flask applications";
diff --git a/pkgs/development/python-modules/pytest-helpers-namespace/default.nix b/pkgs/development/python-modules/pytest-helpers-namespace/default.nix
index 8f24d1dc1f684..41263ce692b3f 100644
--- a/pkgs/development/python-modules/pytest-helpers-namespace/default.nix
+++ b/pkgs/development/python-modules/pytest-helpers-namespace/default.nix
@@ -1,7 +1,7 @@
 { buildPythonPackage
 , fetchFromGitHub
 , pytest
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -26,7 +26,7 @@ buildPythonPackage rec {
   # The tests fail with newest pytest. They passed with pytest_3, which no longer exists
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/saltstack/pytest-helpers-namespace";
     description = "PyTest Helpers Namespace";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/pytest-html/default.nix b/pkgs/development/python-modules/pytest-html/default.nix
index e6e17adc92ee3..0b1090f7b81d0 100644
--- a/pkgs/development/python-modules/pytest-html/default.nix
+++ b/pkgs/development/python-modules/pytest-html/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonOlder
 , pytest, pytest-metadata, setuptools_scm }:
 
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   nativeBuildInputs = [ setuptools_scm ];
   propagatedBuildInputs = [ pytest pytest-metadata ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin for generating HTML reports";
     homepage = "https://github.com/pytest-dev/pytest-html";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/pytest-metadata/default.nix b/pkgs/development/python-modules/pytest-metadata/default.nix
index f2191ab617d27..e8b224dc1d4d9 100644
--- a/pkgs/development/python-modules/pytest-metadata/default.nix
+++ b/pkgs/development/python-modules/pytest-metadata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, setuptools_scm }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   nativeBuildInputs = [ setuptools_scm ];
   propagatedBuildInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin for accessing test session metadata";
     homepage = "https://github.com/pytest-dev/pytest-metadata";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/pytest-mpl/default.nix b/pkgs/development/python-modules/pytest-mpl/default.nix
index 78d5243cf6417..0cc3a993c2353 100644
--- a/pkgs/development/python-modules/pytest-mpl/default.nix
+++ b/pkgs/development/python-modules/pytest-mpl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -44,7 +44,7 @@ buildPythonPackage rec {
     ln -s $HOME/.config/matplotlib $HOME/.matplotlib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pytest plugin to help with testing figures output from Matplotlib";
     homepage = "https://github.com/matplotlib/pytest-mpl";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pytest-pep257/default.nix b/pkgs/development/python-modules/pytest-pep257/default.nix
index 8c20cf873aba8..eb5203c02466c 100644
--- a/pkgs/development/python-modules/pytest-pep257/default.nix
+++ b/pkgs/development/python-modules/pytest-pep257/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, pep257 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, pep257 }:
 
 buildPythonPackage rec {
   pname = "pytest-pep257";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   buildInputs = [ pytest ];
   propagatedBuildInputs = [ pep257 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/anderslime/pytest-pep257";
     description = "py.test plugin for PEP257";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-quickcheck/default.nix b/pkgs/development/python-modules/pytest-quickcheck/default.nix
index 7db982ed857c9..5148fa4b76080 100644
--- a/pkgs/development/python-modules/pytest-quickcheck/default.nix
+++ b/pkgs/development/python-modules/pytest-quickcheck/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, pytest-flakes, tox }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, pytest-flakes, tox }:
 buildPythonPackage rec {
   pname = "pytest-quickcheck";
   version = "0.8.6";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
   buildInputs = [ pytest ];
   propagatedBuildInputs = [ pytest-flakes tox ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.asl20;
     homepage = "https://pypi.python.org/pypi/pytest-quickcheck";
     description = "pytest plugin to generate random data inspired by QuickCheck";
diff --git a/pkgs/development/python-modules/pytest-raisesregexp/default.nix b/pkgs/development/python-modules/pytest-raisesregexp/default.nix
index 638548e9424f1..0d02a25ec3c7b 100644
--- a/pkgs/development/python-modules/pytest-raisesregexp/default.nix
+++ b/pkgs/development/python-modules/pytest-raisesregexp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , py, pytest }:
 
 buildPythonPackage rec {
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace "long_description=open('README.rst').read()," "long_description=io.open('README.rst', encoding='utf-8').read(),"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple pytest plugin to look for regex in Exceptions";
     homepage = "https://github.com/Walkman/pytest_raisesregexp";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/python-modules/pytest-random-order/default.nix b/pkgs/development/python-modules/pytest-random-order/default.nix
index 088f8702436fb..2def886c5cba2 100644
--- a/pkgs/development/python-modules/pytest-random-order/default.nix
+++ b/pkgs/development/python-modules/pytest-random-order/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jbasko/pytest-random-order";
     description = "Randomise the order of tests with some control over the randomness";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-relaxed/default.nix b/pkgs/development/python-modules/pytest-relaxed/default.nix
index c9871368bbe4e..401307039e551 100644
--- a/pkgs/development/python-modules/pytest-relaxed/default.nix
+++ b/pkgs/development/python-modules/pytest-relaxed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -31,7 +31,7 @@ buildPythonPackage rec {
     pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pytest-relaxed.readthedocs.io/";
     description = "Relaxed test discovery/organization for pytest";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/pytest-rerunfailures/default.nix b/pkgs/development/python-modules/pytest-rerunfailures/default.nix
index 384681eee1f9c..537f32316a315 100644
--- a/pkgs/development/python-modules/pytest-rerunfailures/default.nix
+++ b/pkgs/development/python-modules/pytest-rerunfailures/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchPypi, pytest, mock }:
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchPypi, pytest, mock }:
 
 buildPythonPackage rec {
   pname = "pytest-rerunfailures";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     py.test test_pytest_rerunfailures.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "pytest plugin to re-run tests to eliminate flaky failures";
     homepage = "https://github.com/pytest-dev/pytest-rerunfailures";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/pytest-server-fixtures/default.nix b/pkgs/development/python-modules/pytest-server-fixtures/default.nix
index 90b60686ee6c7..41fcfc7b1597c 100644
--- a/pkgs/development/python-modules/pytest-server-fixtures/default.nix
+++ b/pkgs/development/python-modules/pytest-server-fixtures/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, pytest-shutil, pytest-fixture-config, psutil
 , requests, future, retry }:
 
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # RuntimeError: Unable to find a free server number to start Xvfb
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extensible server fixures for py.test";
     homepage  = "https://github.com/manahl/pytest-plugins";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-shutil/default.nix b/pkgs/development/python-modules/pytest-shutil/default.nix
index ef03762e188d7..3edafdfb47342 100644
--- a/pkgs/development/python-modules/pytest-shutil/default.nix
+++ b/pkgs/development/python-modules/pytest-shutil/default.nix
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     py.test ${lib.optionalString isPyPy "-k'not (test_run or test_run_integration)'"}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A goodie-bag of unix shell and environment tools for py.test";
     homepage = "https://github.com/manahl/pytest-plugins";
     maintainers = with maintainers; [ ryansydnor ];
diff --git a/pkgs/development/python-modules/pytest-subtesthack/default.nix b/pkgs/development/python-modules/pytest-subtesthack/default.nix
index d42eb5f8aa31b..f7454ee644ca9 100644
--- a/pkgs/development/python-modules/pytest-subtesthack/default.nix
+++ b/pkgs/development/python-modules/pytest-subtesthack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "pytest-subtesthack";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # no upstream test
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terrible plugin to set up and tear down fixtures within the test function itself";
     homepage = "https://github.com/untitaker/pytest-subtesthack";
     license = licenses.publicDomain;
diff --git a/pkgs/development/python-modules/pytest-virtualenv/default.nix b/pkgs/development/python-modules/pytest-virtualenv/default.nix
index 27350efd74576..5234723a536fd 100644
--- a/pkgs/development/python-modules/pytest-virtualenv/default.nix
+++ b/pkgs/development/python-modules/pytest-virtualenv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, pytestcov, mock, cmdline, pytest-fixture-config, pytest-shutil, virtualenv }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   nativeBuildInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create a Python virtual environment in your test that cleans up on teardown. The fixture has utility methods to install packages and list what’s installed.";
     homepage = "https://github.com/manahl/pytest-plugins";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-xdist/1.nix b/pkgs/development/python-modules/pytest-xdist/1.nix
index 6dc4b666db54f..0c5ae06e86111 100644
--- a/pkgs/development/python-modules/pytest-xdist/1.nix
+++ b/pkgs/development/python-modules/pytest-xdist/1.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, execnet, pytest
+{ lib, stdenv, fetchPypi, buildPythonPackage, execnet, pytest
 , setuptools_scm, pytest-forked, filelock, psutil, six, isPy3k }:
 
 buildPythonPackage rec {
@@ -27,7 +27,7 @@ buildPythonPackage rec {
                     and not test_rsyncignore"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "py.test xdist plugin for distributed testing and loop-on-failing modes";
     homepage = "https://github.com/pytest-dev/pytest-xdist";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest-xdist/default.nix b/pkgs/development/python-modules/pytest-xdist/default.nix
index cc58c5ab6bde4..e5019f842fee5 100644
--- a/pkgs/development/python-modules/pytest-xdist/default.nix
+++ b/pkgs/development/python-modules/pytest-xdist/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, execnet, pytest_6
+{ lib, stdenv, fetchPypi, buildPythonPackage, execnet, pytest_6
 , setuptools_scm, pytest-forked, filelock, psutil, six, isPy3k }:
 
 buildPythonPackage rec {
@@ -24,7 +24,7 @@ buildPythonPackage rec {
       -k "not (distribution_rsyncdirs_example or rsync or warning_captured_deprecated_in_pytest_6)"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "py.test xdist plugin for distributed testing and loop-on-failing modes";
     homepage = "https://github.com/pytest-dev/pytest-xdist";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytest/4.nix b/pkgs/development/python-modules/pytest/4.nix
index 43cfe6c822c4f..88963537c9d5e 100644
--- a/pkgs/development/python-modules/pytest/4.nix
+++ b/pkgs/development/python-modules/pytest/4.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchPypi, attrs, hypothesis, py
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchPypi, attrs, hypothesis, py
 , setuptools_scm, setuptools, six, pluggy, funcsigs, isPy3k, more-itertools
 , atomicwrites, mock, writeText, pathlib2, wcwidth, packaging, isPyPy
 }:
@@ -40,7 +40,7 @@ buildPythonPackage rec {
     preDistPhases+=" pytestcachePhase"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.pytest.org";
     description = "Framework for writing tests";
     maintainers = with maintainers; [ domenkozar lovek323 madjar lsix ];
diff --git a/pkgs/development/python-modules/pytest/5.nix b/pkgs/development/python-modules/pytest/5.nix
index 2b45c330cf385..ade36f4aa0b23 100644
--- a/pkgs/development/python-modules/pytest/5.nix
+++ b/pkgs/development/python-modules/pytest/5.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchPypi, isPy3k, isPyPy
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchPypi, isPy3k, isPyPy
 , atomicwrites
 , attrs
 , funcsigs
@@ -71,7 +71,7 @@ buildPythonPackage rec {
     "pytest"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.pytest.org";
     description = "Framework for writing tests";
     maintainers = with maintainers; [ domenkozar lovek323 madjar lsix ];
diff --git a/pkgs/development/python-modules/pytest/default.nix b/pkgs/development/python-modules/pytest/default.nix
index e0648285810bd..3c8e00f1af8d2 100644
--- a/pkgs/development/python-modules/pytest/default.nix
+++ b/pkgs/development/python-modules/pytest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchPypi, isPy3k, isPyPy
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchPypi, isPy3k, isPyPy
 , atomicwrites
 , attrs
 , funcsigs
@@ -79,7 +79,7 @@ buildPythonPackage rec {
     "pytest"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.pytest.org";
     description = "Framework for writing tests";
     maintainers = with maintainers; [ domenkozar lovek323 madjar lsix ];
diff --git a/pkgs/development/python-modules/pytestcache/default.nix b/pkgs/development/python-modules/pytestcache/default.nix
index f2427991e3f24..877e357d9469b 100644
--- a/pkgs/development/python-modules/pytestcache/default.nix
+++ b/pkgs/development/python-modules/pytestcache/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, execnet }:
 
 buildPythonPackage rec {
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Too many failing tests. Are they maintained?
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     homepage = "https://pypi.python.org/pypi/pytest-cache/";
     description = "pytest plugin with mechanisms for caching across test runs";
diff --git a/pkgs/development/python-modules/pytestrunner/default.nix b/pkgs/development/python-modules/pytestrunner/default.nix
index 5ea632fa7f80c..7fd901babd0b0 100644
--- a/pkgs/development/python-modules/pytestrunner/default.nix
+++ b/pkgs/development/python-modules/pytestrunner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm, pytest }:
 
 buildPythonPackage rec {
   pname = "pytest-runner";
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # Fixture not found
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Invoke py.test as distutils command with dependency resolution";
     homepage = "https://github.com/pytest-dev/pytest-runner";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-doi/default.nix b/pkgs/development/python-modules/python-doi/default.nix
index 2fcd30e84b3e1..7e94f743da46e 100644
--- a/pkgs/development/python-modules/python-doi/default.nix
+++ b/pkgs/development/python-modules/python-doi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy3k }:
 
 buildPythonPackage rec {
   pname = "python-doi";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   disabled = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library to work with Document Object Identifiers (doi)";
     homepage = "https://github.com/alejandrogallo/python-doi";
     maintainers = with maintainers; [ teto ];
diff --git a/pkgs/development/python-modules/python-editor/default.nix b/pkgs/development/python-modules/python-editor/default.nix
index 523229220efe7..19efcb89d3d38 100644
--- a/pkgs/development/python-modules/python-editor/default.nix
+++ b/pkgs/development/python-modules/python-editor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   version = "1.0.4";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # No proper tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library that provides the `editor` module for programmatically";
     homepage = "https://github.com/fmoo/python-editor";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/python-efl/default.nix b/pkgs/development/python-modules/python-efl/default.nix
index 4e3cffa9d223c..bfd14ab3635d2 100644
--- a/pkgs/development/python-modules/python-efl/default.nix
+++ b/pkgs/development/python-modules/python-efl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , buildPythonPackage
 , pkgconfig
@@ -38,7 +38,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for EFL and Elementary";
     homepage = "https://phab.enlightenment.org/w/projects/python_bindings_for_efl/";
     platforms = platforms.linux;
diff --git a/pkgs/development/python-modules/python-engineio/default.nix b/pkgs/development/python-modules/python-engineio/default.nix
index 37d1e362ac117..19c8941d2fcb6 100644
--- a/pkgs/development/python-modules/python-engineio/default.nix
+++ b/pkgs/development/python-modules/python-engineio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , aiohttp
@@ -49,7 +49,7 @@ buildPythonPackage rec {
   disabledTests = [ "test_logger" ];
   pythonImportsCheck = [ "engineio" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python based Engine.IO client and server";
     longDescription = ''
       Engine.IO is a lightweight transport protocol that enables real-time
diff --git a/pkgs/development/python-modules/python-etcd/default.nix b/pkgs/development/python-modules/python-etcd/default.nix
index 714c324b44051..f4305473797cd 100644
--- a/pkgs/development/python-modules/python-etcd/default.nix
+++ b/pkgs/development/python-modules/python-etcd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   # Some issues with etcd not in path even though most tests passed
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python client for Etcd";
     homepage = "https://github.com/jplana/python-etcd";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-forecastio/default.nix b/pkgs/development/python-modules/python-forecastio/default.nix
index 7ef2eee4f2e51..392c5c2126d39 100644
--- a/pkgs/development/python-modules/python-forecastio/default.nix
+++ b/pkgs/development/python-modules/python-forecastio/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, stdenv, fetchPypi
+{ buildPythonPackage, lib, stdenv, fetchPypi
 , requests
 , nose
 , responses
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zeevgilovitz.com/python-forecast.io/";
     description = "A thin Python Wrapper for the Dark Sky (formerly forecast.io) weather API";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/python-frontmatter/default.nix b/pkgs/development/python-modules/python-frontmatter/default.nix
index 8edd87556675d..661ea4ba2493e 100644
--- a/pkgs/development/python-modules/python-frontmatter/default.nix
+++ b/pkgs/development/python-modules/python-frontmatter/default.nix
@@ -20,7 +20,7 @@ python3Packages.buildPythonPackage rec {
     pytest
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/eyeseast/python-frontmatter";
     description = "Parse and manage posts with YAML (or other) frontmatter";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-gitlab/default.nix b/pkgs/development/python-modules/python-gitlab/default.nix
index 6108ea74a23af..c706ff7903c3b 100644
--- a/pkgs/development/python-modules/python-gitlab/default.nix
+++ b/pkgs/development/python-modules/python-gitlab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests, mock, httmock, pythonOlder, pytest, responses }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests, mock, httmock, pythonOlder, pytest, responses }:
 
 buildPythonPackage rec {
   pname = "python-gitlab";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.6";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interact with GitLab API";
     homepage = "https://github.com/python-gitlab/python-gitlab";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/python-gnupg/default.nix b/pkgs/development/python-modules/python-gnupg/default.nix
index 3dd44a72ea464..36ca3a7190613 100644
--- a/pkgs/development/python-modules/python-gnupg/default.nix
+++ b/pkgs/development/python-modules/python-gnupg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, gnupg }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, gnupg }:
 
 buildPythonPackage rec {
   pname   = "python-gnupg";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     --replace "test_search_keys" "disabled__test_search_keys"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A wrapper for the Gnu Privacy Guard";
     homepage    = "https://pypi.python.org/pypi/python-gnupg";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/python-hosts/default.nix b/pkgs/development/python-modules/python-hosts/default.nix
index e76dbc3e3b24a..238b9b9e4afa9 100644
--- a/pkgs/development/python-modules/python-hosts/default.nix
+++ b/pkgs/development/python-modules/python-hosts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pyyaml, pytest, pytestcov }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pyyaml, pytest, pytestcov }:
 
 buildPythonPackage rec {
   pname = "python-hosts";
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     pytest tests/test_utils.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for managing a hosts file. It enables adding and removing entries, or importing them from a file or URL";
     homepage = "https://github.com/jonhadfield/python-hosts";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-jose/default.nix b/pkgs/development/python-modules/python-jose/default.nix
index 6b8104516ea91..0de220094c064 100644
--- a/pkgs/development/python-modules/python-jose/default.nix
+++ b/pkgs/development/python-modules/python-jose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , future, six, ecdsa, rsa
 , pycrypto, pytestcov, pytestrunner, cryptography
 , pytestCheckHook
@@ -37,7 +37,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ future six ecdsa rsa ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mpdavis/python-jose";
     description = "A JOSE implementation in Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-json-logger/default.nix b/pkgs/development/python-modules/python-json-logger/default.nix
index d21e1dfccc915..96ce13ab265bc 100644
--- a/pkgs/development/python-modules/python-json-logger/default.nix
+++ b/pkgs/development/python-modules/python-json-logger/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/madzak/python-json-logger";
     description = "A python library adding a json log formatter";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/python-jsonrpc-server/default.nix b/pkgs/development/python-modules/python-jsonrpc-server/default.nix
index fa6ba97b406d4..1f33bac68273c 100644
--- a/pkgs/development/python-modules/python-jsonrpc-server/default.nix
+++ b/pkgs/development/python-modules/python-jsonrpc-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
 , pytest, mock, pytestcov, coverage
 , future, futures, ujson, isPy38
 , fetchpatch
@@ -43,7 +43,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ future ujson ]
     ++ stdenv.lib.optional (pythonOlder "3.2") futures;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/palantir/python-jsonrpc-server";
     description = "A Python 2 and 3 asynchronous JSON RPC server";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-language-server/default.nix b/pkgs/development/python-modules/python-language-server/default.nix
index 4558bc7edba48..757194d11a50a 100644
--- a/pkgs/development/python-modules/python-language-server/default.nix
+++ b/pkgs/development/python-modules/python-language-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, pythonOlder, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, pythonOlder, isPy27
 , backports_functools_lru_cache, configparser, futures, future, jedi, pluggy, python-jsonrpc-server, flake8
 , pytestCheckHook, mock, pytestcov, coverage, setuptools, ujson
 , # Allow building a limited set of providers, e.g. ["pycodestyle"].
@@ -81,7 +81,7 @@ buildPythonPackage rec {
     ++ stdenv.lib.optional isPy27 configparser
     ++ stdenv.lib.optionals (pythonOlder "3.2") [ backports_functools_lru_cache futures ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/palantir/python-language-server";
     description = "An implementation of the Language Server Protocol for Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-ldap-test/default.nix b/pkgs/development/python-modules/python-ldap-test/default.nix
index 3f543e8569b91..94d8abd1fabd8 100644
--- a/pkgs/development/python-modules/python-ldap-test/default.nix
+++ b/pkgs/development/python-modules/python-ldap-test/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, py4j }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, py4j }:
 
 buildPythonPackage rec {
   pname = "python-ldap-test";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # Tests needs java to be present in path
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for testing code speaking with LDAP server";
     homepage = "https://github.com/zoldar/python-ldap-test";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-levenshtein/default.nix b/pkgs/development/python-modules/python-levenshtein/default.nix
index 7a16621da0a5d..60767e77e7614 100644
--- a/pkgs/development/python-modules/python-levenshtein/default.nix
+++ b/pkgs/development/python-modules/python-levenshtein/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests included in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Functions for fast computation of Levenshtein distance and string similarity";
     homepage    = "https://github.com/ztane/python-Levenshtein";
     license     = licenses.gpl2;
diff --git a/pkgs/development/python-modules/python-ly/default.nix b/pkgs/development/python-modules/python-ly/default.nix
index f8b7f023717c4..6f83a7f61c75d 100644
--- a/pkgs/development/python-modules/python-ly/default.nix
+++ b/pkgs/development/python-modules/python-ly/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchPypi, stdenv }:
+{ buildPythonPackage, fetchPypi, lib, stdenv }:
 
 buildPythonPackage rec {
   pname = "python-ly";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # seem to be broken ATM: https://github.com/wbsoft/python-ly/issues/70
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool and library for manipulating LilyPond files";
     license = licenses.gpl2;
     maintainers = with maintainers; [ ];
diff --git a/pkgs/development/python-modules/python-lzf/default.nix b/pkgs/development/python-modules/python-lzf/default.nix
index 3064afe3ba425..a1fd01134235c 100644
--- a/pkgs/development/python-modules/python-lzf/default.nix
+++ b/pkgs/development/python-modules/python-lzf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   version = "0.2.4";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "1l8m6vzwm1m8hn7ldw8j8r2b6r199k8z3q0wnhdyy4p68hahyhni";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "liblzf python bindings";
     homepage = "https://github.com/teepark/python-lzf";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-mapnik/default.nix b/pkgs/development/python-modules/python-mapnik/default.nix
index 61cd5e34855ce..e129bf4521955 100644
--- a/pkgs/development/python-modules/python-mapnik/default.nix
+++ b/pkgs/development/python-modules/python-mapnik/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPyPy
 , python
@@ -57,7 +57,7 @@ in buildPythonPackage rec {
   ]);
   propagatedBuildInputs = [ pillow pycairo ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for Mapnik";
     homepage = "https://mapnik.org";
     license  = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/python-miio/default.nix b/pkgs/development/python-modules/python-miio/default.nix
index 136483761cf8c..8321795c2fbad 100644
--- a/pkgs/development/python-modules/python-miio/default.nix
+++ b/pkgs/development/python-modules/python-miio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , appdirs
@@ -42,7 +42,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for interfacing with Xiaomi smart appliances";
     homepage = "https://github.com/rytilahti/python-miio";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/python-mnist/default.nix b/pkgs/development/python-modules/python-mnist/default.nix
index 0004c297b6191..a24f2a383a316 100644
--- a/pkgs/development/python-modules/python-mnist/default.nix
+++ b/pkgs/development/python-modules/python-mnist/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "python-mnist";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "a0cced01e83b5b844cff86109280df7a672a8e4e38fc19fa68999a17f8a9fbd8";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sorki/python-mnist";
     description = "Simple MNIST data parser written in Python";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/python-nomad/default.nix b/pkgs/development/python-modules/python-nomad/default.nix
index f03b3b10e4871..ba3ecd3883a4d 100644
--- a/pkgs/development/python-modules/python-nomad/default.nix
+++ b/pkgs/development/python-modules/python-nomad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests }:
 
 buildPythonPackage rec {
   pname = "python-nomad";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # Tests require nomad agent
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python client library for Hashicorp Nomad";
     homepage = "https://github.com/jrxFive/python-nomad";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-otr/default.nix b/pkgs/development/python-modules/python-otr/default.nix
index d83d259724506..7a40998eebdc6 100644
--- a/pkgs/development/python-modules/python-otr/default.nix
+++ b/pkgs/development/python-modules/python-otr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy3k
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ zope_interface cryptography application gmpy2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure python implementation of OTR";
     homepage = "https://github.com/AGProjects/python-otr";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/python-modules/python-packer/default.nix b/pkgs/development/python-modules/python-packer/default.nix
index 420efb40039e4..ba02ec84635ff 100644
--- a/pkgs/development/python-modules/python-packer/default.nix
+++ b/pkgs/development/python-modules/python-packer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, sh }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, sh }:
 
 buildPythonPackage rec {
   pname = "python-packer";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Tests requires network connections
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interface for packer.io";
     homepage = "https://github.com/nir0s/python-packer";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/python-pipedrive/default.nix b/pkgs/development/python-modules/python-pipedrive/default.nix
index e21f01d5cd6b3..6e0c0ef5788e7 100644
--- a/pkgs/development/python-modules/python-pipedrive/default.nix
+++ b/pkgs/development/python-modules/python-pipedrive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   doCheck = false; # Tests are not provided.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for interacting with the pipedrive.com API";
     homepage = "https://github.com/jscott1989/python-pipedrive";
     license = licenses.unfree;
diff --git a/pkgs/development/python-modules/python-ptrace/default.nix b/pkgs/development/python-modules/python-ptrace/default.nix
index 5eff4707d4e26..2d81581c0cc12 100644
--- a/pkgs/development/python-modules/python-ptrace/default.nix
+++ b/pkgs/development/python-modules/python-ptrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python binding of ptrace library";
     homepage = "https://github.com/vstinner/python-ptrace";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/python-rapidjson/default.nix b/pkgs/development/python-modules/python-rapidjson/default.nix
index b128e767d8723..c4cf0dc742557 100644
--- a/pkgs/development/python-modules/python-rapidjson/default.nix
+++ b/pkgs/development/python-modules/python-rapidjson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/python-rapidjson/python-rapidjson";
     description = "Python wrapper around rapidjson ";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-redis-lock/default.nix b/pkgs/development/python-modules/python-redis-lock/default.nix
index 32189495cdd4a..7cf2affc4174d 100644
--- a/pkgs/development/python-modules/python-redis-lock/default.nix
+++ b/pkgs/development/python-modules/python-redis-lock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , redis
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   ++ stdenv.lib.optional withDjango django_redis;
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ionelmc/python-redis-lock";
     license = licenses.bsd2;
     description = "Lock context manager implemented via redis SETNX/BLPOP";
diff --git a/pkgs/development/python-modules/python-simple-hipchat/default.nix b/pkgs/development/python-modules/python-simple-hipchat/default.nix
index f41aefe92aaaa..8ec7f6887ad47 100644
--- a/pkgs/development/python-modules/python-simple-hipchat/default.nix
+++ b/pkgs/development/python-modules/python-simple-hipchat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , unzip }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   buildInputs = [ unzip ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easy peasy wrapper for HipChat's v1 API";
     homepage = "https://github.com/kurttheviking/simple-hipchat-py";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-slugify/default.nix b/pkgs/development/python-modules/python-slugify/default.nix
index 30ce55a12a0cb..1860ff6d24d56 100644
--- a/pkgs/development/python-modules/python-slugify/default.nix
+++ b/pkgs/development/python-modules/python-slugify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, python, text-unidecode }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, python, text-unidecode }:
 
 buildPythonPackage rec {
     pname = "python-slugify";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
       ${python.interpreter} test.py
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/un33k/python-slugify";
       description = "A Python Slugify application that handles Unicode";
       license = licenses.mit;
diff --git a/pkgs/development/python-modules/python-socketio/default.nix b/pkgs/development/python-modules/python-socketio/default.nix
index 64386e83f6940..ee9a603014440 100644
--- a/pkgs/development/python-modules/python-socketio/default.nix
+++ b/pkgs/development/python-modules/python-socketio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , bidict
 , buildPythonPackage
 , fetchFromGitHub
@@ -30,7 +30,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "socketio" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Socket.IO server and client";
     longDescription = ''
       Socket.IO is a lightweight transport protocol that enables real-time
diff --git a/pkgs/development/python-modules/python-telegram-bot/default.nix b/pkgs/development/python-modules/python-telegram-bot/default.nix
index f16f581ade3d2..52dea24c45fec 100644
--- a/pkgs/development/python-modules/python-telegram-bot/default.nix
+++ b/pkgs/development/python-modules/python-telegram-bot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , certifi
@@ -33,7 +33,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "telegram" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This library provides a pure Python interface for the Telegram Bot API.";
     homepage = "https://python-telegram-bot.org";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/python-twitter/default.nix b/pkgs/development/python-modules/python-twitter/default.nix
index 6210c13f56e84..4b1e7e2c1ebaa 100644
--- a/pkgs/development/python-modules/python-twitter/default.nix
+++ b/pkgs/development/python-modules/python-twitter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , fetchpatch
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ future requests requests_oauthlib ];
   checkInputs = [ pytest responses hypothesis ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python wrapper around the Twitter API";
     homepage = "https://github.com/bear/python-twitter";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/python-u2flib-host/default.nix b/pkgs/development/python-modules/python-u2flib-host/default.nix
index eddf0deb015c9..7f6f14c9888c2 100644
--- a/pkgs/development/python-modules/python-u2flib-host/default.nix
+++ b/pkgs/development/python-modules/python-u2flib-host/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, requests, hidapi }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, requests, hidapi }:
 
 buildPythonPackage rec {
   pname = "python-u2flib-host";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # Tests fail: "ValueError: underlying buffer has been detached"
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python based U2F host library";
     homepage = "https://github.com/Yubico/python-u2flib-host";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/python-uinput/default.nix b/pkgs/development/python-modules/python-uinput/default.nix
index e7579058f71ae..69f741e743797 100644
--- a/pkgs/development/python-modules/python-uinput/default.nix
+++ b/pkgs/development/python-modules/python-uinput/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , udev }:
 
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   NIX_CFLAGS_LINK = "-ludev";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pythonic API to Linux uinput kernel module";
     homepage = "http://tjjr.fi/sw/python-uinput/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/python-unshare/default.nix b/pkgs/development/python-modules/python-unshare/default.nix
index a7f0bd93b0af9..fa82027777f64 100644
--- a/pkgs/development/python-modules/python-unshare/default.nix
+++ b/pkgs/development/python-modules/python-unshare/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -16,7 +16,7 @@ buildPythonPackage {
     sha256 = "1h9biinhy5m7r2cj4abhvsg2hb6xjny3n2dxnj1336zpa082ys3h";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for the Linux unshare() syscall";
     homepage    = "https://github.com/thetincho/python-unshare";
     license     = licenses.gpl2;
diff --git a/pkgs/development/python-modules/python-vipaccess/default.nix b/pkgs/development/python-modules/python-vipaccess/default.nix
index cdafd3cd2a0f5..f96086393f2ea 100644
--- a/pkgs/development/python-modules/python-vipaccess/default.nix
+++ b/pkgs/development/python-modules/python-vipaccess/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , oath
@@ -31,7 +31,7 @@ buildPythonPackage rec {
     pytest tests/ -k 'not test_check_token'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free software implementation of Symantec's VIP Access application and protocol";
     homepage = "https://github.com/dlenski/python-vipaccess";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/python-wifi/default.nix b/pkgs/development/python-modules/python-wifi/default.nix
index 7300efc77bccf..503fbe101b922 100644
--- a/pkgs/development/python-modules/python-wifi/default.nix
+++ b/pkgs/development/python-modules/python-wifi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "149c3dznb63d82143cz5hqdim0mqjysz6p3yk0zv271vq3xnmzvv";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     description = "Read & write wireless card capabilities using the Linux Wireless Extensions";
     homepage = "http://pythonwifi.tuxfamily.org/";
diff --git a/pkgs/development/python-modules/python-xmp-toolkit/default.nix b/pkgs/development/python-modules/python-xmp-toolkit/default.nix
index e5d7a7f0326d5..ff4942abef55c 100644
--- a/pkgs/development/python-modules/python-xmp-toolkit/default.nix
+++ b/pkgs/development/python-modules/python-xmp-toolkit/default.nix
@@ -4,7 +4,7 @@
 , mock
 , pythonOlder
 , pytz
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage {
@@ -35,7 +35,7 @@ buildPythonPackage {
       --replace "ctypes.util.find_library('exempi')" "'${exempi}/lib/libexempi${stdenv.hostPlatform.extensions.sharedLibrary}'"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/python-xmp-toolkit/python-xmp-toolkit";
     description = "Python XMP Toolkit for working with metadata";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/python2-pythondialog/default.nix b/pkgs/development/python-modules/python2-pythondialog/default.nix
index a19156d1018b9..b9d9b110f60c3 100644
--- a/pkgs/development/python-modules/python2-pythondialog/default.nix
+++ b/pkgs/development/python-modules/python2-pythondialog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     substituteInPlace dialog.py --replace ":/bin:/usr/bin" ":$out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python interface to the UNIX dialog utility and mostly-compatible programs (Python 2 backport)";
     homepage = "http://pythondialog.sourceforge.net/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/python3-openid/default.nix b/pkgs/development/python-modules/python3-openid/default.nix
index 2a85482cbb68c..ad8ea88d1d0d5 100644
--- a/pkgs/development/python-modules/python3-openid/default.nix
+++ b/pkgs/development/python-modules/python3-openid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, isPy3k, buildPythonPackage, fetchPypi, defusedxml }:
+{ lib, stdenv, isPy3k, buildPythonPackage, fetchPypi, defusedxml }:
 
 buildPythonPackage rec {
   pname = "python3-openid";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   disabled = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenID support for modern servers and consumers";
     homepage = "https://github.com/necaris/python3-openid";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/python_fedora/default.nix b/pkgs/development/python-modules/python_fedora/default.nix
index 2224c94ac6f7b..df12d7aeaff6e 100644
--- a/pkgs/development/python-modules/python_fedora/default.nix
+++ b/pkgs/development/python-modules/python_fedora/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, kitchen, requests, bunch, paver
+{ lib, stdenv, buildPythonPackage, fetchPypi, kitchen, requests, bunch, paver
 , six, munch, urllib3, beautifulsoup4, openidc-client, lockfile }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     six munch urllib3 beautifulsoup4 openidc-client ];
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Fedora Module";
     homepage = "https://github.com/fedora-infra/python-fedora";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/python_keyczar/default.nix b/pkgs/development/python-modules/python_keyczar/default.nix
index c9e29ab5c6398..5fff75ada911f 100644
--- a/pkgs/development/python-modules/python_keyczar/default.nix
+++ b/pkgs/development/python-modules/python_keyczar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyasn1
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pyasn1 pycrypto ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Toolkit for safe and simple cryptography";
     homepage    = "https://pypi.python.org/pypi/python-keyczar";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/python_mimeparse/default.nix b/pkgs/development/python-modules/python_mimeparse/default.nix
index 9484d24f5e2fd..c3f85affe81b4 100644
--- a/pkgs/development/python-modules/python_mimeparse/default.nix
+++ b/pkgs/development/python-modules/python_mimeparse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A module provides basic functions for parsing mime-type names and matching them against a list of media-ranges";
     homepage = "https://github.com/dbtsai/python-mimeparse";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/python_openzwave/default.nix b/pkgs/development/python-modules/python_openzwave/default.nix
index d3f1a0a81204a..7c7151ed92835 100644
--- a/pkgs/development/python-modules/python_openzwave/default.nix
+++ b/pkgs/development/python-modules/python_openzwave/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , pkgconfig
 , systemd, libyaml, openzwave, cython, pyserial
 , six, pydispatcher, urwid }:
@@ -32,7 +32,7 @@ buildPythonPackage rec {
   # no tests available
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper for the OpenZWave C++ library";
     homepage = "https://github.com/OpenZWave/python-openzwave";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/python_statsd/default.nix b/pkgs/development/python-modules/python_statsd/default.nix
index 6455b69451724..ae293c44c0f77 100644
--- a/pkgs/development/python-modules/python_statsd/default.nix
+++ b/pkgs/development/python-modules/python_statsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   buildInputs = [ mock nose coverage ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A client for Etsy's node-js statsd server";
     homepage = "https://github.com/WoLpH/python-statsd";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pythondialog/default.nix b/pkgs/development/python-modules/pythondialog/default.nix
index 4f54c5a8fad8c..c385f11b2f01c 100644
--- a/pkgs/development/python-modules/pythondialog/default.nix
+++ b/pkgs/development/python-modules/pythondialog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     substituteInPlace dialog.py --replace ":/bin:/usr/bin" ":$out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python interface to the UNIX dialog utility and mostly-compatible programs";
     homepage = "http://pythondialog.sourceforge.net/";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pythonirclib/default.nix b/pkgs/development/python-modules/pythonirclib/default.nix
index 6074b76d300ac..178e1855a0616 100644
--- a/pkgs/development/python-modules/pythonirclib/default.nix
+++ b/pkgs/development/python-modules/pythonirclib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , paver
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ paver ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python IRC library";
     homepage = "https://github.com/jaraco/irc";
     license = with licenses; [ lgpl21 ];
diff --git a/pkgs/development/python-modules/pythonix/default.nix b/pkgs/development/python-modules/pythonix/default.nix
index 4ed0fb79127e5..80535b28bf239 100644
--- a/pkgs/development/python-modules/pythonix/default.nix
+++ b/pkgs/development/python-modules/pythonix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, ninja, boost, meson, pkg-config, nix, isPy3k, python }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, ninja, boost, meson, pkg-config, nix, isPy3k, python }:
 
 buildPythonPackage rec {
   pname = "pythonix";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "nix" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
        Eval nix code from python.
     '';
diff --git a/pkgs/development/python-modules/pythonocc-core/default.nix b/pkgs/development/python-modules/pythonocc-core/default.nix
index 96c79a45b277d..cbcf4ab9d02da 100644
--- a/pkgs/development/python-modules/pythonocc-core/default.nix
+++ b/pkgs/development/python-modules/pythonocc-core/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python, fetchFromGitHub, cmake, swig, ninja
+{ lib, stdenv, python, fetchFromGitHub, cmake, swig, ninja
 , opencascade, smesh, freetype, libGL, libGLU, libX11
 , Cocoa }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     "-DPYTHONOCC_WRAP_SMESH=TRUE"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper for the OpenCASCADE 3D modeling kernel";
     homepage = "https://github.com/tpaviot/pythonocc-core";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/pytidylib/default.nix b/pkgs/development/python-modules/pytidylib/default.nix
index a0aade1fe670f..16f6e4232b305 100644
--- a/pkgs/development/python-modules/pytidylib/default.nix
+++ b/pkgs/development/python-modules/pytidylib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, python, html-tidy }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, python, html-tidy }:
 
 buildPythonPackage rec {
   pname = "pytidylib";
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python wrapper for HTML Tidy (tidylib) on Python 2 and 3";
     homepage = "https://countergram.github.io/pytidylib/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytimeparse/default.nix b/pkgs/development/python-modules/pytimeparse/default.nix
index 9aa11a480cd66..1ced64375301a 100644
--- a/pkgs/development/python-modules/pytimeparse/default.nix
+++ b/pkgs/development/python-modules/pytimeparse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, nose }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, nose }:
 
 buildPythonPackage rec {
     pname = "pytimeparse";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
     checkInputs = [ nose ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A small Python library to parse various kinds of time expressions";
       homepage    = "https://github.com/wroberts/pytimeparse";
       license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pytoml/default.nix b/pkgs/development/python-modules/pytoml/default.nix
index 8ec17b158449d..64e6ed4c669a2 100644
--- a/pkgs/development/python-modules/pytoml/default.nix
+++ b/pkgs/development/python-modules/pytoml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , python
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A TOML parser/writer for Python";
     homepage    = "https://github.com/avakar/pytoml";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/pytorch/bin.nix b/pkgs/development/python-modules/pytorch/bin.nix
index 6a97e6d30a4fd..a25f2013adf7b 100644
--- a/pkgs/development/python-modules/pytorch/bin.nix
+++ b/pkgs/development/python-modules/pytorch/bin.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPy37
@@ -63,7 +63,7 @@ in buildPythonPackage {
 
   pythonImportsCheck = [ "torch" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source, prototype-to-production deep learning platform";
     homepage = "https://pytorch.org/";
     license = licenses.unfree; # Includes CUDA and Intel MKL.
diff --git a/pkgs/development/python-modules/pytrends/default.nix b/pkgs/development/python-modules/pytrends/default.nix
index 8317c5ea0182f..83980c3d00b92 100644
--- a/pkgs/development/python-modules/pytrends/default.nix
+++ b/pkgs/development/python-modules/pytrends/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests lxml pandas ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pseudo API for Google Trends";
     homepage = "https://github.com/GeneralMills/pytrends";
     license = [ licenses.asl20 ];
diff --git a/pkgs/development/python-modules/pytricia/default.nix b/pkgs/development/python-modules/pytricia/default.nix
index 80e95fb605077..8e168bf8181a6 100644
--- a/pkgs/development/python-modules/pytricia/default.nix
+++ b/pkgs/development/python-modules/pytricia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "0qp5774xkm700g35k5c76pck8pdzqlyzbaqgrz76a1yh67s2ri8h";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for fast IP address lookup in Python";
     homepage = "https://github.com/jsommers/pytricia";
     license = with licenses; [ lgpl3Plus ];
diff --git a/pkgs/development/python-modules/pytun/default.nix b/pkgs/development/python-modules/pytun/default.nix
index b37dbf26fb7b1..2b49b169c6d1c 100644
--- a/pkgs/development/python-modules/pytun/default.nix
+++ b/pkgs/development/python-modules/pytun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # Test directory contains examples, not tests.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/montag451/pytun";
     description = "Linux TUN/TAP wrapper for Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pytzdata/default.nix b/pkgs/development/python-modules/pytzdata/default.nix
index 5adcbd0d23684..739325d333376 100644
--- a/pkgs/development/python-modules/pytzdata/default.nix
+++ b/pkgs/development/python-modules/pytzdata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
   pname = "pytzdata";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Timezone database for Python";
     homepage = "https://github.com/sdispater/pytzdata";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyunifi/default.nix b/pkgs/development/python-modules/pyunifi/default.nix
index ed2dd4cc25649..1eec6f3ea84db 100644
--- a/pkgs/development/python-modules/pyunifi/default.nix
+++ b/pkgs/development/python-modules/pyunifi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , requests }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "API towards Ubiquity Networks UniFi controller";
     homepage = "https://github.com/finish06/unifi-api";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pyupdate/default.nix b/pkgs/development/python-modules/pyupdate/default.nix
index 9ce93d67a52ad..f33aba8d62561 100644
--- a/pkgs/development/python-modules/pyupdate/default.nix
+++ b/pkgs/development/python-modules/pyupdate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k
 , requests }:
 
 buildPythonPackage rec {
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     # This description is terrible, but it's what upstream uses.
     description = "Package to update stuff";
     homepage = "https://github.com/ludeeus/pyupdate";
diff --git a/pkgs/development/python-modules/pyusb/default.nix b/pkgs/development/python-modules/pyusb/default.nix
index 7e5fc90453ff0..41207984e0ca2 100644
--- a/pkgs/development/python-modules/pyusb/default.nix
+++ b/pkgs/development/python-modules/pyusb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, libusb1, setuptools_scm }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, libusb1, setuptools_scm }:
 
 buildPythonPackage rec {
   pname = "pyusb";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "usb" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python USB access module (wraps libusb 1.0)";  # can use other backends
     homepage = "https://pyusb.github.io/pyusb/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pyutil/default.nix b/pkgs/development/python-modules/pyutil/default.nix
index a943c8eb523ba..effb9f7b7e675 100644
--- a/pkgs/development/python-modules/pyutil/default.nix
+++ b/pkgs/development/python-modules/pyutil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptoolsDarcs
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     grep -rl 'utf-8-with-signature-unix' ./ | xargs sed -i -e "s|utf-8-with-signature-unix|utf-8|g"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pyutil, a collection of mature utilities for Python programmers";
 
     longDescription = ''
diff --git a/pkgs/development/python-modules/pyuv/default.nix b/pkgs/development/python-modules/pyuv/default.nix
index 7f476d3c11d2a..95477196d8b94 100644
--- a/pkgs/development/python-modules/pyuv/default.nix
+++ b/pkgs/development/python-modules/pyuv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPyPy
 , pkgs
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pkgs.libuv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python interface for libuv";
     homepage = "https://github.com/saghul/pyuv";
     repositories.git = "git://github.com/saghul/pyuv.git";
diff --git a/pkgs/development/python-modules/pyvoro/default.nix b/pkgs/development/python-modules/pyvoro/default.nix
index e998654178203..7013cc7809dd7 100644
--- a/pkgs/development/python-modules/pyvoro/default.nix
+++ b/pkgs/development/python-modules/pyvoro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # No tests in package
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/joe-jordan/pyvoro";
     description = "2D and 3D Voronoi tessellations: a python entry point for the voro++ library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/pywatchman/default.nix b/pkgs/development/python-modules/pywatchman/default.nix
index f9951465e2566..5e3c4d6cc5a04 100644
--- a/pkgs/development/python-modules/pywatchman/default.nix
+++ b/pkgs/development/python-modules/pywatchman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, watchman }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, watchman }:
 
 buildPythonPackage rec {
   pname = "pywatchman";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Watchman client for Python";
     homepage = "https://facebook.github.io/watchman/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/pywebdav/default.nix b/pkgs/development/python-modules/pywebdav/default.nix
index 9a56bf7604642..5ed3e28b5b1bc 100644
--- a/pkgs/development/python-modules/pywebdav/default.nix
+++ b/pkgs/development/python-modules/pywebdav/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy3k }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy3k }:
 
 buildPythonPackage rec {
   pname = "PyWebDAV";
@@ -8,7 +8,7 @@ buildPythonPackage rec {
     inherit pname version;
     sha256 = "1v10vg79h85milnq8w7yd75qq5z6297ywkn9b2kxajldzwqxn3ji";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://code.google.com/p/pywebdav/";
     description = "WebDAV library including a standalone server for python";
     maintainers = with maintainers; [ johbo ];
diff --git a/pkgs/development/python-modules/pyx/default.nix b/pkgs/development/python-modules/pyx/default.nix
index 339fa9029b70d..b19e5f97e141b 100644
--- a/pkgs/development/python-modules/pyx/default.nix
+++ b/pkgs/development/python-modules/pyx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python package for the generation of PostScript, PDF, and SVG files";
     homepage = "http://pyx.sourceforge.net/";
     license = with licenses; [ gpl2 ];
diff --git a/pkgs/development/python-modules/pyzufall/default.nix b/pkgs/development/python-modules/pyzufall/default.nix
index 2c5121e61e807..03fce00629d8b 100644
--- a/pkgs/development/python-modules/pyzufall/default.nix
+++ b/pkgs/development/python-modules/pyzufall/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, python, buildPythonPackage, nose, future, coverage }:
+{ lib, stdenv, fetchPypi, python, buildPythonPackage, nose, future, coverage }:
 
 buildPythonPackage rec {
   pname = "PyZufall";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     ${python.interpreter} setup.py nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pyzufall.readthedocs.io/de/latest/";
     description = "Library for generating random data and sentences in german language";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/qpid-python/default.nix b/pkgs/development/python-modules/qpid-python/default.nix
index f7221a981ea6b..ef540538792d6 100644
--- a/pkgs/development/python-modules/qpid-python/default.nix
+++ b/pkgs/development/python-modules/qpid-python/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPy3k
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # needs a broker running and then ./qpid-python-test
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://qpid.apache.org/";
     description = "Python client implementation and AMQP conformance tests for Apache Qpid";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/qrcode/default.nix b/pkgs/development/python-modules/qrcode/default.nix
index 714c741889763..113d53ff29b88 100644
--- a/pkgs/development/python-modules/qrcode/default.nix
+++ b/pkgs/development/python-modules/qrcode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ six pillow pymaging_png setuptools ];
   checkInputs = [ mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quick Response code generation for Python";
     homepage = "https://pypi.python.org/pypi/qrcode";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/qscintilla/default.nix b/pkgs/development/python-modules/qscintilla/default.nix
index e44f6205d39fc..82c3773f30328 100644
--- a/pkgs/development/python-modules/qscintilla/default.nix
+++ b/pkgs/development/python-modules/qscintilla/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , disabledIf
 , isPy3k
@@ -34,7 +34,7 @@ disabledIf (isPy3k || isPyPy)
           --sipdir $out/share/sip
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A Python binding to QScintilla, Qt based text editing control";
       license = licenses.lgpl21Plus;
       maintainers = with maintainers; [ danbst ];
diff --git a/pkgs/development/python-modules/qserve/default.nix b/pkgs/development/python-modules/qserve/default.nix
index ad1a7fd2ca366..ff606d132363f 100644
--- a/pkgs/development/python-modules/qserve/default.nix
+++ b/pkgs/development/python-modules/qserve/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "0b04b2d4d11b464ff1efd42a9ea9f8136187d59f4076f57c9ba95361d41cd7ed";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Job queue server";
     homepage = "https://github.com/pediapress/qserve";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/qtawesome/default.nix b/pkgs/development/python-modules/qtawesome/default.nix
index 6ec8ce367735a..11b4885e4c8a2 100644
--- a/pkgs/development/python-modules/qtawesome/default.nix
+++ b/pkgs/development/python-modules/qtawesome/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, qtpy, six, pyqt5, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, qtpy, six, pyqt5, pytest }:
 
 buildPythonPackage rec {
   pname = "QtAwesome";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Requires https://github.com/boylea/qtbot
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Iconic fonts in PyQt and PySide applications";
     homepage = "https://github.com/spyder-ide/qtawesome";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/qtpy/default.nix b/pkgs/development/python-modules/qtpy/default.nix
index 313b1266a52d9..76db7090a045a 100644
--- a/pkgs/development/python-modules/qtpy/default.nix
+++ b/pkgs/development/python-modules/qtpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pyside, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pyside, pytest }:
 
 buildPythonPackage rec {
   pname = "QtPy";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     py.test qtpy/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Abstraction layer for PyQt5/PyQt4/PySide2/PySide";
     homepage = "https://github.com/spyder-ide/qtpy";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/querystring-parser/default.nix b/pkgs/development/python-modules/querystring-parser/default.nix
index f9d04a8f797c5..25b3c113cec6a 100644
--- a/pkgs/development/python-modules/querystring-parser/default.nix
+++ b/pkgs/development/python-modules/querystring-parser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, python, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, python, isPy27
 , six
 }:
 
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # one test fails due to https://github.com/bernii/querystring-parser/issues/35
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bernii/querystring-parser";
     description = "QueryString parser for Python/Django that correctly handles nested dictionaries";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/queuelib/default.nix b/pkgs/development/python-modules/queuelib/default.nix
index dbcdd4c5924ec..7471ea180655f 100644
--- a/pkgs/development/python-modules/queuelib/default.nix
+++ b/pkgs/development/python-modules/queuelib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of persistent (disk-based) queues for Python";
     homepage = "https://github.com/scrapy/queuelib";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/r2pipe/default.nix b/pkgs/development/python-modules/r2pipe/default.nix
index 7c1bb88bcaaef..3fbb0fb4042c6 100644
--- a/pkgs/development/python-modules/r2pipe/default.nix
+++ b/pkgs/development/python-modules/r2pipe/default.nix
@@ -42,7 +42,7 @@ buildPythonPackage rec {
     EOF
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interact with radare2";
     homepage = "https://github.com/radare/radare2-r2pipe";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rabbitpy/default.nix b/pkgs/development/python-modules/rabbitpy/default.nix
index 9844c8dca4438..79975ada50159 100644
--- a/pkgs/development/python-modules/rabbitpy/default.nix
+++ b/pkgs/development/python-modules/rabbitpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , mock
@@ -34,7 +34,7 @@ buildPythonPackage rec {
       --replace 'pamqp>=2,<3' 'pamqp'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure python, thread-safe, minimalistic and pythonic RabbitMQ client library";
     homepage = "https://pypi.python.org/pypi/rabbitpy";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/radicale_infcloud/default.nix b/pkgs/development/python-modules/radicale_infcloud/default.nix
index 4b30d643fbd7d..5c561b6e65412 100644
--- a/pkgs/development/python-modules/radicale_infcloud/default.nix
+++ b/pkgs/development/python-modules/radicale_infcloud/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage }:
 
 buildPythonPackage {
   pname = "radicale_infcloud";
@@ -13,7 +13,7 @@ buildPythonPackage {
 
   doCheck = false; # Tries to import radicale, circular dependency
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Unrud/RadicaleInfCloud/";
     description = "Integrate InfCloud into Radicale's web interface";
     license = with licenses; [ agpl3 gpl3 ];
diff --git a/pkgs/development/python-modules/rainbowstream/default.nix b/pkgs/development/python-modules/rainbowstream/default.nix
index 7fc7f057009a0..c5ec1d3ab4efa 100644
--- a/pkgs/development/python-modules/rainbowstream/default.nix
+++ b/pkgs/development/python-modules/rainbowstream/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -44,7 +44,7 @@ buildPythonPackage rec {
 
   buildInputs =  [ pkgs.libjpeg pkgs.freetype pkgs.zlib pkgs.glibcLocales pillow twitter pyfiglet requests arrow dateutil pysocks pocket ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Streaming command-line twitter client";
     homepage    = "http://www.rainbowstream.org/";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/ramlfications/default.nix b/pkgs/development/python-modules/ramlfications/default.nix
index 0f870a5ab7a1b..2d3e2bdc0e03a 100644
--- a/pkgs/development/python-modules/ramlfications/default.nix
+++ b/pkgs/development/python-modules/ramlfications/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , mock, pytest, pytest-mock, pytest-server-fixtures, pytest-localserver
 , termcolor, click, markdown2, six, jsonref, pyyaml, xmltodict, attrs
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0xvnna7kaq4nm5nfnwcwbr5bcm2s532hgyp7kq4v9iivn48rrf3v";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python RAML parser.";
     homepage    = "https://ramlfications.readthedocs.org";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/random2/default.nix b/pkgs/development/python-modules/random2/default.nix
index 1334fa2aa32ca..9ed7701a3f458 100644
--- a/pkgs/development/python-modules/random2/default.nix
+++ b/pkgs/development/python-modules/random2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "34ad30aac341039872401595df9ab2c9dc36d0b7c077db1cea9ade430ed1c007";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pypi.python.org/pypi/random2";
     description = "Python 3 compatible Python 2 `random` Module";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/rarfile/default.nix b/pkgs/development/python-modules/rarfile/default.nix
index 6502d9f4ae6a6..6b875528d1df9 100644
--- a/pkgs/development/python-modules/rarfile/default.nix
+++ b/pkgs/development/python-modules/rarfile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pytestCheckHook, nose, libarchive, glibcLocales, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pytestCheckHook, nose, libarchive, glibcLocales, isPy27
 # unrar is non-free software
 , useUnrar ? false, unrar
 }:
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   LC_ALL = "en_US.UTF-8";
   pythonImportsCheck = [ "rarfile" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RAR archive reader for Python";
     homepage = "https://github.com/markokr/rarfile";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/ratelimiter/default.nix b/pkgs/development/python-modules/ratelimiter/default.nix
index 15437889fc2fb..4d3ff6d486b4a 100644
--- a/pkgs/development/python-modules/ratelimiter/default.nix
+++ b/pkgs/development/python-modules/ratelimiter/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv
+  lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/RazerM/ratelimiter";
     license = licenses.asl20;
     description = "Simple python rate limiting object";
diff --git a/pkgs/development/python-modules/rawkit/default.nix b/pkgs/development/python-modules/rawkit/default.nix
index a114d2400aa77..974f7ac4d1c63 100644
--- a/pkgs/development/python-modules/rawkit/default.nix
+++ b/pkgs/development/python-modules/rawkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, fetchpatch
+{ lib, stdenv, fetchPypi, buildPythonPackage, fetchpatch
 , libraw
 , pytest, mock }:
 
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CTypes based LibRaw bindings for Python";
     homepage = "https://rawkit.readthedocs.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rbtools/default.nix b/pkgs/development/python-modules/rbtools/default.nix
index 477a11f2ce907..f1c9685d5ccab 100644
--- a/pkgs/development/python-modules/rbtools/default.nix
+++ b/pkgs/development/python-modules/rbtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPy3k
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # The kgb test dependency is not in nixpkgs
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.reviewboard.org/docs/rbtools/dev/";
     description = "RBTools is a set of command line tools for working with Review Board and RBCommons";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rcssmin/default.nix b/pkgs/development/python-modules/rcssmin/default.nix
index 30d5a3c0e2782..507102222fe0a 100644
--- a/pkgs/development/python-modules/rcssmin/default.nix
+++ b/pkgs/development/python-modules/rcssmin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 buildPythonPackage rec {
   pname = "rcssmin";
   version = "1.0.6";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # tests auto-discovery
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://opensource.perlig.de/rcssmin/";
     license = licenses.asl20;
     description = "CSS minifier written in pure python";
diff --git a/pkgs/development/python-modules/readchar/default.nix b/pkgs/development/python-modules/readchar/default.nix
index 1ed4539dca08e..211f5d63a7dd3 100644
--- a/pkgs/development/python-modules/readchar/default.nix
+++ b/pkgs/development/python-modules/readchar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, flake8, pytest, pytestcov, pexpect }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, flake8, pytest, pytestcov, pexpect }:
 
 buildPythonPackage rec {
   pname = "readchar";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   nativeBuildInputs = [ flake8 ];
   checkInputs = [ pytest pytestcov pexpect ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/magmax/python-readchar";
     description = "Python library to read characters and key strokes";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/readme/default.nix b/pkgs/development/python-modules/readme/default.nix
index 057283babe7b5..044c487eb037c 100644
--- a/pkgs/development/python-modules/readme/default.nix
+++ b/pkgs/development/python-modules/readme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -30,7 +30,7 @@ buildPythonPackage rec {
   # package is not readme_renderer
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Readme is a library for rendering readme descriptions for Warehouse";
     homepage = "https://github.com/pypa/readme";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/rebulk/default.nix b/pkgs/development/python-modules/rebulk/default.nix
index f1591e4df7415..750efe357c228 100644
--- a/pkgs/development/python-modules/rebulk/default.nix
+++ b/pkgs/development/python-modules/rebulk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, pytestrunner, six, regex}:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, pytestrunner, six, regex}:
 
 buildPythonPackage rec {
   pname = "rebulk";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   buildInputs = [ pytest pytestrunner ];
   propagatedBuildInputs = [ six regex ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Toilal/rebulk/";
     license = licenses.mit;
     description = "Advanced string matching from simple patterns";
diff --git a/pkgs/development/python-modules/recaptcha_client/default.nix b/pkgs/development/python-modules/recaptcha_client/default.nix
index bcb6741bb2952..08e7ff47aa1c3 100644
--- a/pkgs/development/python-modules/recaptcha_client/default.nix
+++ b/pkgs/development/python-modules/recaptcha_client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonAtLeast
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "28c6853c1d13d365b7dc71a6b05e5ffb56471f70a850de318af50d3d7c0dea2f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CAPTCHA for Python using the reCAPTCHA service";
     homepage = "http://recaptcha.net/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rednose/default.nix b/pkgs/development/python-modules/rednose/default.nix
index 948fe39dae7d9..73b7f5d4758e0 100644
--- a/pkgs/development/python-modules/rednose/default.nix
+++ b/pkgs/development/python-modules/rednose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, pythonAtLeast
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, pythonAtLeast
 , nose, six, colorama, termstyle }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   checkInputs = [ six ];
   propagatedBuildInputs = [ nose colorama termstyle ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python nose plugin adding color to console results";
     homepage = "https://github.com/JBKahn/rednose";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/reedsolo/default.nix b/pkgs/development/python-modules/reedsolo/default.nix
index 2a22907ebe6ce..c87a89b82a447 100644
--- a/pkgs/development/python-modules/reedsolo/default.nix
+++ b/pkgs/development/python-modules/reedsolo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, cython, nose }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, cython, nose }:
 
 buildPythonPackage rec {
   pname = "reedsolo";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   checkInputs = [ nose ];
   checkPhase = "nosetests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure-python universal errors-and-erasures Reed-Solomon Codec";
     homepage = "https://github.com/tomerfiliba/reedsolomon";
     license = licenses.publicDomain;
diff --git a/pkgs/development/python-modules/remotecv/default.nix b/pkgs/development/python-modules/remotecv/default.nix
index 9ab250f78afbd..dc40763f6fe60 100644
--- a/pkgs/development/python-modules/remotecv/default.nix
+++ b/pkgs/development/python-modules/remotecv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pillow, pyres, nose
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pillow, pyres, nose
 , preggy, numpy, yanc, nose-focus, mock, opencv }:
 
 buildPythonPackage rec {
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     nosetests --with-yanc -s tests/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenCV worker for facial and feature recognition";
     homepage = "https://github.com/thumbor/remotecv/wiki";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rencode/default.nix b/pkgs/development/python-modules/rencode/default.nix
index 3240c524d3bd7..a8f0f81ee71dd 100644
--- a/pkgs/development/python-modules/rencode/default.nix
+++ b/pkgs/development/python-modules/rencode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , cython
@@ -16,7 +16,7 @@ buildPythonPackage {
 
   buildInputs = [ cython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/aresch/rencode";
     description = "Fast (basic) object serialization similar to bencode";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/repeated_test/default.nix b/pkgs/development/python-modules/repeated_test/default.nix
index c5c2e43b6573a..a9355cda41ca0 100644
--- a/pkgs/development/python-modules/repeated_test/default.nix
+++ b/pkgs/development/python-modules/repeated_test/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , unittest2
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   buildInputs = [ unittest2 ];
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A quick unittest-compatible framework for repeating a test function over many fixtures";
     homepage = "https://github.com/epsy/repeated_test";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/repocheck/default.nix b/pkgs/development/python-modules/repocheck/default.nix
index 88437ae903271..ad8c3aef2eac6 100644
--- a/pkgs/development/python-modules/repocheck/default.nix
+++ b/pkgs/development/python-modules/repocheck/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     owner = "kynikos";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Check the status of code repositories under a root directory";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/repoze_lru/default.nix b/pkgs/development/python-modules/repoze_lru/default.nix
index afaac0b35f3e1..7b8f0ecd80912 100644
--- a/pkgs/development/python-modules/repoze_lru/default.nix
+++ b/pkgs/development/python-modules/repoze_lru/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0429a75e19380e4ed50c0694e26ac8819b4ea7851ee1fc7583c8572db80aff77";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiny LRU cache implementation and decorator";
     homepage = "http://www.repoze.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/repoze_sphinx_autointerface/default.nix b/pkgs/development/python-modules/repoze_sphinx_autointerface/default.nix
index 0cc55ef7fea5c..53761203113da 100644
--- a/pkgs/development/python-modules/repoze_sphinx_autointerface/default.nix
+++ b/pkgs/development/python-modules/repoze_sphinx_autointerface/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_interface
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ zope_interface sphinx ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/repoze/repoze.sphinx.autointerface";
     description = "Auto-generate Sphinx API docs from Zope interfaces";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/repoze_who/default.nix b/pkgs/development/python-modules/repoze_who/default.nix
index 7f4a89f3d24e2..f64158f26a10a 100644
--- a/pkgs/development/python-modules/repoze_who/default.nix
+++ b/pkgs/development/python-modules/repoze_who/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_interface
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ zope_interface webob ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WSGI Authentication Middleware / API";
     homepage = "http://www.repoze.org";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/requests-cache/default.nix b/pkgs/development/python-modules/requests-cache/default.nix
index 4042197e1c31a..2b3d57831c8dd 100644
--- a/pkgs/development/python-modules/requests-cache/default.nix
+++ b/pkgs/development/python-modules/requests-cache/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , mock, requests, six, urllib3 }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   buildInputs = [ mock ];
   propagatedBuildInputs = [ requests six urllib3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Persistent cache for requests library";
     homepage = "https://pypi.python.org/pypi/requests-cache";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/requests-http-signature/default.nix b/pkgs/development/python-modules/requests-http-signature/default.nix
index 992c54930ca62..cd36a4528198f 100644
--- a/pkgs/development/python-modules/requests-http-signature/default.nix
+++ b/pkgs/development/python-modules/requests-http-signature/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , requests
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     ${python.interpreter} test/test.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Requests auth module for HTTP Signature";
     homepage = "https://github.com/kislyuk/requests-http-signature";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/requests-kerberos/default.nix b/pkgs/development/python-modules/requests-kerberos/default.nix
index ab0758a84e16b..a1c6f4fb0a1bb 100644
--- a/pkgs/development/python-modules/requests-kerberos/default.nix
+++ b/pkgs/development/python-modules/requests-kerberos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, requests, pykerberos, mock }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, requests, pykerberos, mock }:
 
 buildPythonPackage rec {
   pname = "requests-kerberos";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # they have a setup.py which mentions a test suite that doesn't exist...
   patches = [ ./fix_setup.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An authentication handler for using Kerberos with Python Requests.";
     homepage    = "https://github.com/requests/requests-kerberos";
     license     = licenses.isc;
diff --git a/pkgs/development/python-modules/requests-oauthlib/default.nix b/pkgs/development/python-modules/requests-oauthlib/default.nix
index c4394fa87cdf4..5de13530f66df 100644
--- a/pkgs/development/python-modules/requests-oauthlib/default.nix
+++ b/pkgs/development/python-modules/requests-oauthlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , oauthlib, requests }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   doCheck = false;        # Internet tests fail when building in chroot
   propagatedBuildInputs = [ oauthlib requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OAuthlib authentication support for Requests";
     homepage = "https://github.com/requests/requests-oauthlib";
     maintainers = with maintainers; [ prikhi ];
diff --git a/pkgs/development/python-modules/requests/default.nix b/pkgs/development/python-modules/requests/default.nix
index 47431274b2c6d..a49b07102201e 100644
--- a/pkgs/development/python-modules/requests/default.nix
+++ b/pkgs/development/python-modules/requests/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , urllib3, idna, chardet, certifi
 , pytest }:
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # sadly, tests require networking
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Apache2 licensed HTTP library, written in Python, for human beings";
     homepage = "http://docs.python-requests.org/en/latest/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/resampy/default.nix b/pkgs/development/python-modules/resampy/default.nix
index 43088cf5122ec..38b4ae9911d25 100644
--- a/pkgs/development/python-modules/resampy/default.nix
+++ b/pkgs/development/python-modules/resampy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pytest
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bmcfee/resampy";
     description = "Efficient signal resampling";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/rethinkdb/default.nix b/pkgs/development/python-modules/rethinkdb/default.nix
index 616cabc29a012..b359002337362 100644
--- a/pkgs/development/python-modules/rethinkdb/default.nix
+++ b/pkgs/development/python-modules/rethinkdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "rethinkdb" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python driver library for the RethinkDB database server";
     homepage = "https://pypi.python.org/pypi/rethinkdb";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/retry_decorator/default.nix b/pkgs/development/python-modules/retry_decorator/default.nix
index c1e495f56a999..12ba4f9a1a5b5 100644
--- a/pkgs/development/python-modules/retry_decorator/default.nix
+++ b/pkgs/development/python-modules/retry_decorator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "e1e8ad02e518fe11073f2ea7d80b6b8be19daa27a60a1838aff7c731ddcf2ebe";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pnpnpn/retry-decorator";
     description = "Retry Decorator for python functions";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/retrying/default.nix b/pkgs/development/python-modules/retrying/default.nix
index 75a17fb6dc44b..65127d040f42e 100644
--- a/pkgs/development/python-modules/retrying/default.nix
+++ b/pkgs/development/python-modules/retrying/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # doesn't ship tests in tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rholder/retrying";
     description = "General-purpose retrying library";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/rfc-bibtex/default.nix b/pkgs/development/python-modules/rfc-bibtex/default.nix
index 7eb79d1b251cc..c002f0baaa9dc 100644
--- a/pkgs/development/python-modules/rfc-bibtex/default.nix
+++ b/pkgs/development/python-modules/rfc-bibtex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchPypi, isPy3k }:
+{ lib, stdenv, buildPythonApplication, fetchPypi, isPy3k }:
 
 buildPythonApplication rec {
   pname = "rfc-bibtex";
@@ -11,7 +11,7 @@ buildPythonApplication rec {
 
   disabled = !isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/iluxonchik/rfc-bibtex/";
     description = "Generate Bibtex entries for IETF RFCs and Internet-Drafts";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rfc3986/default.nix b/pkgs/development/python-modules/rfc3986/default.nix
index 859b2cc3e1af9..561bda08d0cd1 100644
--- a/pkgs/development/python-modules/rfc3986/default.nix
+++ b/pkgs/development/python-modules/rfc3986/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, idna, pytestCheckHook }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, idna, pytestCheckHook }:
 
 buildPythonPackage rec {
   pname = "rfc3986";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Validating URI References per RFC 3986";
     homepage = "https://rfc3986.readthedocs.org";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/rfc3987/default.nix b/pkgs/development/python-modules/rfc3987/default.nix
index 6488dfdd8ce5a..1ec8fc2153c11 100644
--- a/pkgs/development/python-modules/rfc3987/default.nix
+++ b/pkgs/development/python-modules/rfc3987/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "rfc3987";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
   };
 
   doCheck = false;
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/rfc3987";
     license = licenses.gpl3Plus;
     description = "Parsing and validation of URIs (RFC 3986) and IRIs (RFC 3987)";
diff --git a/pkgs/development/python-modules/rich/default.nix b/pkgs/development/python-modules/rich/default.nix
index 6284ed7b649a3..1e667f1f3de66 100644
--- a/pkgs/development/python-modules/rich/default.nix
+++ b/pkgs/development/python-modules/rich/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pythonOlder
@@ -37,7 +37,7 @@ buildPythonPackage rec {
   checkInputs = [ pytestCheckHook ];
   pythonImportsCheck = [ "rich" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Render rich text, tables, progress bars, syntax highlighting, markdown and more to the terminal";
     homepage = "https://github.com/willmcgugan/rich";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rjsmin/default.nix b/pkgs/development/python-modules/rjsmin/default.nix
index 49520b1ee452e..7ca9d711739a2 100644
--- a/pkgs/development/python-modules/rjsmin/default.nix
+++ b/pkgs/development/python-modules/rjsmin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 buildPythonPackage rec {
   pname = "rjsmin";
   version = "1.1.0";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # tests auto-discovery
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://opensource.perlig.de/rjsmin/";
     license = licenses.asl20;
     description = "Javascript minifier written in python";
diff --git a/pkgs/development/python-modules/rl-coach/default.nix b/pkgs/development/python-modules/rl-coach/default.nix
index e9efb0c02b4ec..0ac5d9ab2a3b0 100644
--- a/pkgs/development/python-modules/rl-coach/default.nix
+++ b/pkgs/development/python-modules/rl-coach/default.nix
@@ -89,7 +89,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.5"; # minimum required version
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enables easy experimentation with state of the art Reinforcement Learning algorithms";
     homepage = "https://nervanasystems.github.io/coach/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robomachine/default.nix b/pkgs/development/python-modules/robomachine/default.nix
index 11fff472e98a1..fe069be459cc2 100644
--- a/pkgs/development/python-modules/robomachine/default.nix
+++ b/pkgs/development/python-modules/robomachine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pyparsing, robotframework, allpairspy }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pyparsing, robotframework, allpairspy }:
 
 buildPythonPackage rec {
   pname = "RoboMachine";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace "argparse" ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test data generator for Robot Framework";
     homepage = "https://github.com/mkorpela/RoboMachine";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robot-detection/default.nix b/pkgs/development/python-modules/robot-detection/default.nix
index 5cf864cd8019e..3cf064d2669db 100644
--- a/pkgs/development/python-modules/robot-detection/default.nix
+++ b/pkgs/development/python-modules/robot-detection/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six }:
 
 buildPythonPackage rec {
   pname = "robot-detection";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # no tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for detecting if a HTTP User Agent header is likely to be a bot";
     homepage = "https://github.com/rory/robot-detection";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/robotframework-databaselibrary/default.nix b/pkgs/development/python-modules/robotframework-databaselibrary/default.nix
index 73b538aa12f7c..c3eb309dfe0ba 100644
--- a/pkgs/development/python-modules/robotframework-databaselibrary/default.nix
+++ b/pkgs/development/python-modules/robotframework-databaselibrary/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , robotframework
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ robotframework ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Database Library contains utilities meant for Robot Framework";
     homepage = "https://github.com/franz-see/Robotframework-Database-Library";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robotframework-requests/default.nix b/pkgs/development/python-modules/robotframework-requests/default.nix
index 0a22dc1eec6c6..967138620e98d 100644
--- a/pkgs/development/python-modules/robotframework-requests/default.nix
+++ b/pkgs/development/python-modules/robotframework-requests/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , unittest2
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   buildInputs = [ unittest2 ];
   propagatedBuildInputs = [ robotframework lxml requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Robot Framework keyword library wrapper around the HTTP client library requests";
     homepage = "https://github.com/bulkan/robotframework-requests";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/robotframework-ride/default.nix b/pkgs/development/python-modules/robotframework-ride/default.nix
index 368c4e4c15ade..39e42596e2aea 100644
--- a/pkgs/development/python-modules/robotframework-ride/default.nix
+++ b/pkgs/development/python-modules/robotframework-ride/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonPackage, isPy3k, pygments, wxPython }:
+{ lib, stdenv, fetchurl, buildPythonPackage, isPy3k, pygments, wxPython }:
 
 buildPythonPackage rec {
   version = "1.2.3";
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Light-weight and intuitive editor for Robot Framework test case files";
     homepage = "https://code.google.com/p/robotframework-ride/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robotframework-selenium2library/default.nix b/pkgs/development/python-modules/robotframework-selenium2library/default.nix
index 14ce2db5d0b2b..5fa87d17d11f3 100644
--- a/pkgs/development/python-modules/robotframework-selenium2library/default.nix
+++ b/pkgs/development/python-modules/robotframework-selenium2library/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, robotframework-seleniumlibrary }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, robotframework-seleniumlibrary }:
 
 buildPythonPackage rec {
   version = "3.0.0";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ robotframework-seleniumlibrary ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web testing library for Robot Framework";
     homepage = "https://github.com/robotframework/Selenium2Library";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robotframework-seleniumlibrary/default.nix b/pkgs/development/python-modules/robotframework-seleniumlibrary/default.nix
index 2bba9cfbdd8af..60123d6b87d16 100644
--- a/pkgs/development/python-modules/robotframework-seleniumlibrary/default.nix
+++ b/pkgs/development/python-modules/robotframework-seleniumlibrary/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python, robotframework, selenium, mockito, robotstatuschecker, approvaltests }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python, robotframework, selenium, mockito, robotstatuschecker, approvaltests }:
 
 buildPythonPackage rec {
   version = "3.3.1";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     ${python.interpreter} utest/run.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web testing library for Robot Framework";
     homepage = "https://github.com/robotframework/SeleniumLibrary";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robotframework-sshlibrary/default.nix b/pkgs/development/python-modules/robotframework-sshlibrary/default.nix
index e5e2d022dc8ad..7e3bcbcc55dac 100644
--- a/pkgs/development/python-modules/robotframework-sshlibrary/default.nix
+++ b/pkgs/development/python-modules/robotframework-sshlibrary/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , robotframework
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ robotframework paramiko scp ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SSHLibrary is a Robot Framework test library for SSH and SFTP";
     homepage = "https://github.com/robotframework/SSHLibrary";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robotframework-tools/default.nix b/pkgs/development/python-modules/robotframework-tools/default.nix
index 0ed0bcaf4948b..5bc7bbceae71e 100644
--- a/pkgs/development/python-modules/robotframework-tools/default.nix
+++ b/pkgs/development/python-modules/robotframework-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -41,7 +41,7 @@ buildPythonPackage rec {
     pytest test --ignore test/remote/test_remote.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Tools for Robot Framework and Test Libraries";
     homepage = "https://bitbucket.org/userzimmermann/robotframework-tools";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/robotframework/default.nix b/pkgs/development/python-modules/robotframework/default.nix
index 1a3b554515377..953602ca1ada0 100644
--- a/pkgs/development/python-modules/robotframework/default.nix
+++ b/pkgs/development/python-modules/robotframework/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage }:
+{ lib, stdenv, fetchPypi, buildPythonPackage }:
 
 buildPythonPackage rec {
   pname = "robotframework";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
     extension = "zip";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generic test automation framework";
     homepage = "https://robotframework.org/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robotstatuschecker/default.nix b/pkgs/development/python-modules/robotstatuschecker/default.nix
index c5094b4ee59d4..b0bd44f9c1521 100644
--- a/pkgs/development/python-modules/robotstatuschecker/default.nix
+++ b/pkgs/development/python-modules/robotstatuschecker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python, robotframework }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python, robotframework }:
 
 buildPythonPackage rec {
   version = "1.3";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     ${python.interpreter} test/run.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for checking that Robot Framework test cases have expected statuses and log messages";
     homepage = "https://github.com/robotframework/statuschecker";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/robotsuite/default.nix b/pkgs/development/python-modules/robotsuite/default.nix
index e9d4ddbed1168..126153ec50e54 100644
--- a/pkgs/development/python-modules/robotsuite/default.nix
+++ b/pkgs/development/python-modules/robotsuite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , unittest2, lxml, robotframework
 }:
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
       --replace robotframework-python3 robotframework
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python unittest test suite for Robot Framework";
     homepage = "https://github.com/collective/robotsuite/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/roku/default.nix b/pkgs/development/python-modules/roku/default.nix
index 6cdfa2aa15b1a..5e3644468fe8e 100644
--- a/pkgs/development/python-modules/roku/default.nix
+++ b/pkgs/development/python-modules/roku/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, requests, pytest, flask, isPy27
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, requests, pytest, flask, isPy27
 }:
 
 buildPythonPackage rec {
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest flask ];
   pythonImportsCheck = [ "roku" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Screw remotes. Control your Roku with Python.";
     homepage = "https://github.com/jcarbaugh/python-roku";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/roman/default.nix b/pkgs/development/python-modules/roman/default.nix
index 52d45d7287520..33f0f7f18d7d2 100644
--- a/pkgs/development/python-modules/roman/default.nix
+++ b/pkgs/development/python-modules/roman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     sha256 = "90e83b512b44dd7fc83d67eb45aa5eb707df623e6fc6e66e7f273abd4b2613ae";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integer to Roman numerals converter";
     homepage = "https://pypi.python.org/pypi/roman";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/rope/default.nix b/pkgs/development/python-modules/rope/default.nix
index 81e306f81db2f..65edd602d8dea 100644
--- a/pkgs/development/python-modules/rope/default.nix
+++ b/pkgs/development/python-modules/rope/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonAtLeast, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonAtLeast, nose }:
 
 buildPythonPackage rec {
   pname = "rope";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     NOSE_IGNORE_FILES=type_hinting_test.py nosetests ropetest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python refactoring library";
     homepage = "https://github.com/python-rope/rope";
     maintainers = with maintainers; [ goibhniu ];
diff --git a/pkgs/development/python-modules/ropper/default.nix b/pkgs/development/python-modules/ropper/default.nix
index 51fc191dd4676..8b193caa7b8bb 100644
--- a/pkgs/development/python-modules/ropper/default.nix
+++ b/pkgs/development/python-modules/ropper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonApplication
 , fetchPypi
 , capstone
@@ -23,7 +23,7 @@ buildPythonApplication rec {
 
   checkInputs = [pytest];
   propagatedBuildInputs = [ capstone filebytes ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://scoding.de/ropper/";
     license = licenses.bsd3;
     description = "Show information about files in different file formats";
diff --git a/pkgs/development/python-modules/routes/default.nix b/pkgs/development/python-modules/routes/default.nix
index 95eebe8ab69d8..0129ef69e2c6e 100644
--- a/pkgs/development/python-modules/routes/default.nix
+++ b/pkgs/development/python-modules/routes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , repoze_lru
@@ -25,7 +25,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "routes" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python re-implementation of the Rails routes system for mapping URLs to application actions";
     homepage = "http://routes.groovie.org/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rpdb/default.nix b/pkgs/development/python-modules/rpdb/default.nix
index d7faeeaed7c98..fb84adb7d2402 100644
--- a/pkgs/development/python-modules/rpdb/default.nix
+++ b/pkgs/development/python-modules/rpdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "5d1a1cee34378ab075879dc30fa6328d448a9f680a66c4e84cac7382ad92f15f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "pdb wrapper with remote access via tcp socket";
     homepage = "https://github.com/tamentis/rpdb";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/rpkg/default.nix b/pkgs/development/python-modules/rpkg/default.nix
index 2be6830130dc6..731a5738e73ec 100644
--- a/pkgs/development/python-modules/rpkg/default.nix
+++ b/pkgs/development/python-modules/rpkg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchurl, six, pycurl, cccolutils
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchurl, six, pycurl, cccolutils
 , koji, rpmfluff }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = false; # needs /var/lib/rpm database to run tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for dealing with rpm packaging";
     homepage = "https://pagure.io/fedpkg";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/rply/default.nix b/pkgs/development/python-modules/rply/default.nix
index 1c4fd16eedf63..0da9d2b71018f 100644
--- a/pkgs/development/python-modules/rply/default.nix
+++ b/pkgs/development/python-modules/rply/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pytest, fetchFromGitHub, buildPythonPackage, appdirs }:
+{ lib, stdenv, pytest, fetchFromGitHub, buildPythonPackage, appdirs }:
 
 buildPythonPackage rec {
   pname = "rply";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     HOME=$(mktemp -d) py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python Lex/Yacc that works with RPython";
     homepage = "https://github.com/alex/rply";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/rpmfluff/default.nix b/pkgs/development/python-modules/rpmfluff/default.nix
index 1893f7dd19c3c..96050ba14b01a 100644
--- a/pkgs/development/python-modules/rpmfluff/default.nix
+++ b/pkgs/development/python-modules/rpmfluff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , glibcLocales
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   LC_ALL="en_US.utf-8";
   buildInputs = [ glibcLocales ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "lightweight way of building RPMs, and sabotaging them";
     homepage = "https://pagure.io/rpmfluff";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/rpyc/default.nix b/pkgs/development/python-modules/rpyc/default.nix
index 5b6dba0f9ed01..acd52c22d1b4d 100644
--- a/pkgs/development/python-modules/rpyc/default.nix
+++ b/pkgs/development/python-modules/rpyc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , nose
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     nosetests -I test_deploy -I test_gevent_server -I test_ssh -I test_registry
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Remote Python Call (RPyC), a transparent and symmetric RPC library";
     homepage = "https://rpyc.readthedocs.org";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rq/default.nix b/pkgs/development/python-modules/rq/default.nix
index c788d41641024..c9ca5977cb108 100644
--- a/pkgs/development/python-modules/rq/default.nix
+++ b/pkgs/development/python-modules/rq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, isPy27, click, redis }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, isPy27, click, redis }:
 
 buildPythonPackage rec {
   pname = "rq";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ click redis ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple, lightweight library for creating background jobs, and processing them";
     homepage = "https://github.com/nvie/rq/";
     maintainers = with maintainers; [ mrmebelman ];
diff --git a/pkgs/development/python-modules/rsa/4_0.nix b/pkgs/development/python-modules/rsa/4_0.nix
index 459ca04379689..a6aa89b2ea1ed 100644
--- a/pkgs/development/python-modules/rsa/4_0.nix
+++ b/pkgs/development/python-modules/rsa/4_0.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , unittest2
@@ -24,7 +24,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace "open('README.md')" "open('README.md',encoding='utf-8')"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://stuvel.eu/rsa";
     license = licenses.asl20;
     description = "A pure-Python RSA implementation";
diff --git a/pkgs/development/python-modules/rsa/default.nix b/pkgs/development/python-modules/rsa/default.nix
index a5380709eda97..1f26350fc36e5 100644
--- a/pkgs/development/python-modules/rsa/default.nix
+++ b/pkgs/development/python-modules/rsa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , unittest2
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://stuvel.eu/rsa";
     license = licenses.asl20;
     description = "A pure-Python RSA implementation";
diff --git a/pkgs/development/python-modules/rtslib/default.nix b/pkgs/development/python-modules/rtslib/default.nix
index aaf879d2a3f4f..e53756b0181a2 100644
--- a/pkgs/development/python-modules/rtslib/default.nix
+++ b/pkgs/development/python-modules/rtslib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, six, pyudev, pygobject3 }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, six, pyudev, pygobject3 }:
 
 buildPythonPackage rec {
   pname = "rtslib";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six pyudev pygobject3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python object API for managing the Linux LIO kernel target";
     homepage = "https://github.com/open-iscsi/rtslib-fb";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ruamel_base/default.nix b/pkgs/development/python-modules/ruamel_base/default.nix
index f7e473f9f5611..950f523f4a9a7 100644
--- a/pkgs/development/python-modules/ruamel_base/default.nix
+++ b/pkgs/development/python-modules/ruamel_base/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1wswxrn4givsm917mfl39rafgadimf1sldpbjdjws00g1wx36hf0";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Common routines for ruamel packages";
     homepage = "https://sourceforge.net/projects/ruamel-base/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ruamel_ordereddict/default.nix b/pkgs/development/python-modules/ruamel_ordereddict/default.nix
index 7f05229a4f549..1e5820a37f734 100644
--- a/pkgs/development/python-modules/ruamel_ordereddict/default.nix
+++ b/pkgs/development/python-modules/ruamel_ordereddict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "d7d9cf8b11e7662deb460260cf062980cd84b87a1d0457132060ab9d44e0a5f4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A version of dict that keeps keys in insertion resp. sorted order";
     homepage = "https://sourceforge.net/projects/ruamel-ordereddict/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ruamel_yaml_clib/default.nix b/pkgs/development/python-modules/ruamel_yaml_clib/default.nix
index 46b55c04d30ec..debf2aaf7747c 100644
--- a/pkgs/development/python-modules/ruamel_yaml_clib/default.nix
+++ b/pkgs/development/python-modules/ruamel_yaml_clib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchhg
 , ruamel_base
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # outputs match wheel
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "YAML parser/emitter that supports roundtrip preservation of comments, seq/map flow style, and map key order";
     homepage = "https://sourceforge.net/projects/ruamel-yaml-clib/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/rubymarshal/default.nix b/pkgs/development/python-modules/rubymarshal/default.nix
index 6115702009acd..edb793c19d515 100644
--- a/pkgs/development/python-modules/rubymarshal/default.nix
+++ b/pkgs/development/python-modules/rubymarshal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, hypothesis, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, hypothesis, isPy3k }:
 
 buildPythonPackage rec {
   pname = "rubymarshal";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "rubymarshal" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/d9pouces/RubyMarshal/";
     description = "Read and write Ruby-marshalled data";
     license = licenses.wtfpl;
diff --git a/pkgs/development/python-modules/ruffus/default.nix b/pkgs/development/python-modules/ruffus/default.nix
index da905f7ab477d..a425c077343fc 100644
--- a/pkgs/development/python-modules/ruffus/default.nix
+++ b/pkgs/development/python-modules/ruffus/default.nix
@@ -4,7 +4,7 @@
 , hostname
 , pytest
 , python
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -38,7 +38,7 @@ buildPythonPackage rec {
   '';
   pythonImportsCheck = [ "ruffus" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Light-weight Python Computational Pipeline Management";
     homepage = "http://www.ruffus.org.uk";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/runsnakerun/default.nix b/pkgs/development/python-modules/runsnakerun/default.nix
index 6d601197d76ee..1475b00323138 100644
--- a/pkgs/development/python-modules/runsnakerun/default.nix
+++ b/pkgs/development/python-modules/runsnakerun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , squaremap
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ squaremap wxPython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI Viewer for Python profiling runs";
     homepage = "http://www.vrplumber.com/programming/runsnakerun/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/s3fs/default.nix b/pkgs/development/python-modules/s3fs/default.nix
index 739b32ec70d14..0154059c4f7be 100644
--- a/pkgs/development/python-modules/s3fs/default.nix
+++ b/pkgs/development/python-modules/s3fs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, docutils, aiobotocore, fsspec }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, docutils, aiobotocore, fsspec }:
 
 buildPythonPackage rec {
   pname = "s3fs";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # pythonPackages.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "S3FS builds on boto3 to provide a convenient Python filesystem interface for S3.";
     homepage = "https://github.com/dask/s3fs/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/sacremoses/default.nix b/pkgs/development/python-modules/sacremoses/default.nix
index f5c0ee715c3a3..9f97757edad46 100644
--- a/pkgs/development/python-modules/sacremoses/default.nix
+++ b/pkgs/development/python-modules/sacremoses/default.nix
@@ -1,5 +1,5 @@
 { buildPythonPackage
-, stdenv
+, lib, stdenv
 , fetchFromGitHub
 , click
 , six
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     pytest -k 'not truecase'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/alvations/sacremoses";
     description = "Python port of Moses tokenizer, truecaser and normalizer";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/python-modules/safe/default.nix b/pkgs/development/python-modules/safe/default.nix
index f7f6f7eabf91a..d167760c3e0ef 100644
--- a/pkgs/development/python-modules/safe/default.nix
+++ b/pkgs/development/python-modules/safe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/lepture/safe";
     license = licenses.bsd3;
     description = "Check password strength";
diff --git a/pkgs/development/python-modules/salmon-mail/default.nix b/pkgs/development/python-modules/salmon-mail/default.nix
index 187f526b72f49..5e6aa5927eca1 100644
--- a/pkgs/development/python-modules/salmon-mail/default.nix
+++ b/pkgs/development/python-modules/salmon-mail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, dnspython, chardet, lmtpd
+{ lib, stdenv, buildPythonPackage, fetchPypi, dnspython, chardet, lmtpd
 , python-daemon, six, jinja2, mock, click }:
 
 buildPythonPackage rec {
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     PATH=$out/bin:$PATH python setup.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://salmon-mail.readthedocs.org/";
     description = "Pythonic mail application server";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/samplerate/default.nix b/pkgs/development/python-modules/samplerate/default.nix
index 02278d9be415c..a4a19f7ad12ec 100644
--- a/pkgs/development/python-modules/samplerate/default.nix
+++ b/pkgs/development/python-modules/samplerate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , numpy
 , pkgs
@@ -27,7 +27,7 @@ buildPythonPackage {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cournape/samplerate";
     description = "High quality sampling rate convertion from audio data in numpy arrays";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/sandboxlib/default.nix b/pkgs/development/python-modules/sandboxlib/default.nix
index 541bd81087148..42872e3189162 100644
--- a/pkgs/development/python-modules/sandboxlib/default.nix
+++ b/pkgs/development/python-modules/sandboxlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pbr
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   buildInputs = [ pbr ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sandboxing Library for Python";
     homepage = "https://pypi.python.org/pypi/sandboxlib/0.3.1";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/sapi-python-client/default.nix b/pkgs/development/python-modules/sapi-python-client/default.nix
index 847acb3c9cd41..8a7a62d8ce849 100644
--- a/pkgs/development/python-modules/sapi-python-client/default.nix
+++ b/pkgs/development/python-modules/sapi-python-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, git, setuptools, setuptools_scm, fetchFromGitHub, requests, boto3, buildPythonPackage, responses }:
+{ lib, stdenv, git, setuptools, setuptools_scm, fetchFromGitHub, requests, boto3, buildPythonPackage, responses }:
 
 buildPythonPackage rec {
     pname = "sapi-python-client";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
     propagatedBuildInputs = [ setuptools requests boto3 responses ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
         description = "Keboola Connection Storage API client";
         homepage = "https://github.com/keboola/sapi-python-client";
         maintainers = with maintainers; [ mrmebelman ];
diff --git a/pkgs/development/python-modules/scales/default.nix b/pkgs/development/python-modules/scales/default.nix
index 0407c1fa86d89..5aae629726880 100644
--- a/pkgs/development/python-modules/scales/default.nix
+++ b/pkgs/development/python-modules/scales/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stats for Python processes";
     homepage = "https://www.github.com/Cue/scales";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/schedule/default.nix b/pkgs/development/python-modules/schedule/default.nix
index 118c95cc8c57c..596ed993233e8 100644
--- a/pkgs/development/python-modules/schedule/default.nix
+++ b/pkgs/development/python-modules/schedule/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , mock
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python job scheduling for humans";
     homepage = "https://github.com/dbader/schedule";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/schema/default.nix b/pkgs/development/python-modules/schema/default.nix
index 8dd89480074ab..1502c7d10abec 100644
--- a/pkgs/development/python-modules/schema/default.nix
+++ b/pkgs/development/python-modules/schema/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, contextlib2, pytest, mock }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, contextlib2, pytest, mock }:
 
 buildPythonPackage rec {
 
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest mock ];
   checkPhase = "pytest ./test_schema.py";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for validating Python data structures";
     homepage = "https://github.com/keleshev/schema";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/scikit-bio/default.nix b/pkgs/development/python-modules/scikit-bio/default.nix
index 650a677099130..8fa0186498f49 100644
--- a/pkgs/development/python-modules/scikit-bio/default.nix
+++ b/pkgs/development/python-modules/scikit-bio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , cython
@@ -45,7 +45,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m skbio.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://scikit-bio.org/";
     description = "Data structures, algorithms and educational resources for bioinformatics";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/scikitlearn/0.20.nix b/pkgs/development/python-modules/scikitlearn/0.20.nix
index 4d8e8d00f4345..81915e83d2dc9 100644
--- a/pkgs/development/python-modules/scikitlearn/0.20.nix
+++ b/pkgs/development/python-modules/scikitlearn/0.20.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , gfortran, glibcLocales
 , numpy, scipy, pytest, pillow
 }:
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     HOME=$TMPDIR OMP_NUM_THREADS=1 pytest -k "not test_feature_importance_regression" --pyargs sklearn
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of python modules for machine learning and data mining";
     homepage = "https://scikit-learn.org";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/scikitlearn/default.nix b/pkgs/development/python-modules/scikitlearn/default.nix
index cffd29f09d3a2..5414fe43cc153 100644
--- a/pkgs/development/python-modules/scikitlearn/default.nix
+++ b/pkgs/development/python-modules/scikitlearn/default.nix
@@ -52,7 +52,7 @@ buildPythonPackage rec {
     HOME=$TMPDIR OMP_NUM_THREADS=1 pytest -k "not test_feature_importance_regression" --pyargs sklearn
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of python modules for machine learning and data mining";
     changelog = let
       major = versions.major version;
diff --git a/pkgs/development/python-modules/scikits-odes/default.nix b/pkgs/development/python-modules/scikits-odes/default.nix
index d85d8e396f20f..383cf1f70c686 100644
--- a/pkgs/development/python-modules/scikits-odes/default.nix
+++ b/pkgs/development/python-modules/scikits-odes/default.nix
@@ -45,7 +45,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A scikit offering extra ode/dae solvers, as an extension to what is available in scipy";
     homepage = "https://github.com/bmcage/odes";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/scp/default.nix b/pkgs/development/python-modules/scp/default.nix
index a37927b9a6416..f5cd96e71aaf6 100644
--- a/pkgs/development/python-modules/scp/default.nix
+++ b/pkgs/development/python-modules/scp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , paramiko
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   #The Pypi package doesn't include the test
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jbardin/scp.py";
     description = "SCP module for paramiko";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/scrapy-deltafetch/default.nix b/pkgs/development/python-modules/scrapy-deltafetch/default.nix
index cf6f8a0107140..090d31e67a9ad 100644
--- a/pkgs/development/python-modules/scrapy-deltafetch/default.nix
+++ b/pkgs/development/python-modules/scrapy-deltafetch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pytest, scrapy, bsddb3 }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pytest, scrapy, bsddb3 }:
 
 buildPythonPackage rec {
   pname = "scrapy-deltafetch";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scrapy spider middleware to ignore requests to pages containing items seen in previous crawls";
     homepage = "https://github.com/scrapy-plugins/scrapy-deltafetch";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/scrapy-fake-useragent/default.nix b/pkgs/development/python-modules/scrapy-fake-useragent/default.nix
index b2de4e9a993bd..4f6eecfe91436 100644
--- a/pkgs/development/python-modules/scrapy-fake-useragent/default.nix
+++ b/pkgs/development/python-modules/scrapy-fake-useragent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, pytestCheckHook, pytestcov, pytest-mock, fake-useragent, faker, scrapy }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, pytestCheckHook, pytestcov, pytest-mock, fake-useragent, faker, scrapy }:
 
 buildPythonPackage rec {
   pname = "scrapy-fake-useragent";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook scrapy pytestcov pytest-mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Random User-Agent middleware based on fake-useragent";
     homepage = "https://github.com/alecxe/scrapy-fake-useragent";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/scrapy-splash/default.nix b/pkgs/development/python-modules/scrapy-splash/default.nix
index 7799186d6216f..48988be2c0a71 100644
--- a/pkgs/development/python-modules/scrapy-splash/default.nix
+++ b/pkgs/development/python-modules/scrapy-splash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pytest, hypothesis, scrapy }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, pytest, hypothesis, scrapy }:
 
 buildPythonPackage rec {
   pname = "scrapy-splash";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest hypothesis scrapy ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scrapy+Splash for JavaScript integration";
     homepage = "https://github.com/scrapy-plugins/scrapy-splash";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/scrapy/default.nix b/pkgs/development/python-modules/scrapy/default.nix
index c377ace69685d..1b7b75eaff4ff 100644
--- a/pkgs/development/python-modules/scrapy/default.nix
+++ b/pkgs/development/python-modules/scrapy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy27
 , fetchPypi
@@ -92,7 +92,7 @@ buildPythonPackage rec {
     install -m 644 -D extras/scrapy_zsh_completion $out/share/zsh/site-functions/_scrapy
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast high-level web crawling and web scraping framework, used to crawl websites and extract structured data from their pages";
     homepage = "https://scrapy.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/screeninfo/default.nix b/pkgs/development/python-modules/screeninfo/default.nix
index 1b79a43af9c96..f53a7053ff58f 100644
--- a/pkgs/development/python-modules/screeninfo/default.nix
+++ b/pkgs/development/python-modules/screeninfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchPypi, isPy27, isPy36, dataclasses, libX11, libXinerama, libXrandr }:
+{ lib, stdenv, buildPythonApplication, fetchPypi, isPy27, isPy36, dataclasses, libX11, libXinerama, libXrandr }:
 
 buildPythonApplication rec {
   pname = "screeninfo";
@@ -27,7 +27,7 @@ buildPythonApplication rec {
 
   buildInputs = [ libX11 libXinerama libXrandr];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fetch location and size of physical screens";
     homepage = "https://github.com/rr-/screeninfo";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/scripttest/default.nix b/pkgs/development/python-modules/scripttest/default.nix
index ab53585fe8c20..ab234ce224343 100644
--- a/pkgs/development/python-modules/scripttest/default.nix
+++ b/pkgs/development/python-modules/scripttest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Tests are not included. See https://github.com/pypa/scripttest/issues/11
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for testing interactive command-line applications";
     homepage = "https://pypi.python.org/pypi/ScriptTest/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sdnotify/default.nix b/pkgs/development/python-modules/sdnotify/default.nix
index f1a7fc4d52c0a..0003d9c013123 100644
--- a/pkgs/development/python-modules/sdnotify/default.nix
+++ b/pkgs/development/python-modules/sdnotify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     inherit pname version;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure Python implementation of systemd's service notification protocol";
     homepage = "https://github.com/bb4242/sdnotify";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/seabreeze/default.nix b/pkgs/development/python-modules/seabreeze/default.nix
index 7cf062765d3be..cc9594d045258 100644
--- a/pkgs/development/python-modules/seabreeze/default.nix
+++ b/pkgs/development/python-modules/seabreeze/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , pyusb
@@ -34,7 +34,7 @@ buildPythonPackage rec {
 
   setupPyBuildFlags = [ "--without-cseabreeze" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ap--/python-seabreeze";
     description = "A python library to access Ocean Optics spectrometers";
     maintainers = [];
diff --git a/pkgs/development/python-modules/seekpath/default.nix b/pkgs/development/python-modules/seekpath/default.nix
index e70ba02ce0e33..637b55eec8d7f 100644
--- a/pkgs/development/python-modules/seekpath/default.nix
+++ b/pkgs/development/python-modules/seekpath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder, numpy, future, spglib, glibcLocales, pytest, scipy }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder, numpy, future, spglib, glibcLocales, pytest, scipy }:
 
 buildPythonPackage rec {
   pname = "seekpath";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     pytest . -k 'not oI2Y'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A module to obtain and visualize band paths in the Brillouin zone of crystal structures.";
     homepage = "https://github.com/giovannipizzi/seekpath";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/selectors2/default.nix b/pkgs/development/python-modules/selectors2/default.nix
index c78f1811a069d..ff6b81d3105d2 100644
--- a/pkgs/development/python-modules/selectors2/default.nix
+++ b/pkgs/development/python-modules/selectors2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose, psutil, mock }:
 
 buildPythonPackage rec {
@@ -21,7 +21,7 @@ buildPythonPackage rec {
       --exclude=test_above_fd_setsize
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.github.com/SethMichaelLarson/selectors2";
     description = "Back-ported, durable, and portable selectors";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/selectors34/default.nix b/pkgs/development/python-modules/selectors34/default.nix
index 6d02c9dc79b28..ea3b403fdaed6 100644
--- a/pkgs/development/python-modules/selectors34/default.nix
+++ b/pkgs/development/python-modules/selectors34/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     ${python.interpreter} setup.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A backport of the selectors module from Python 3.4";
     homepage = "https://github.com/berkerpeksag/selectors34";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/semantic/default.nix b/pkgs/development/python-modules/semantic/default.nix
index f0371f860cf56..83e4879e1fddd 100644
--- a/pkgs/development/python-modules/semantic/default.nix
+++ b/pkgs/development/python-modules/semantic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # strange setuptools error (can not import semantic.test)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Common Natural Language Processing Tasks for Python";
     homepage = "https://github.com/crm416/semantic";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/semver/default.nix b/pkgs/development/python-modules/semver/default.nix
index 5aca34b52f11e..71ec776db7c42 100644
--- a/pkgs/development/python-modules/semver/default.nix
+++ b/pkgs/development/python-modules/semver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , pytestCheckHook
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   preCheck = "rm -rf dist"; # confuses source vs dist imports in pytest
   checkInputs = [ pytestCheckHook pytestcov ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python package to work with Semantic Versioning (http://semver.org/)";
     homepage = "https://python-semver.readthedocs.io/en/latest/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/send2trash/default.nix b/pkgs/development/python-modules/send2trash/default.nix
index 16528c976ac6f..a91be01511191 100644
--- a/pkgs/development/python-modules/send2trash/default.nix
+++ b/pkgs/development/python-modules/send2trash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pytest
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   checkPhase = "HOME=$TMPDIR pytest";
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Send file to trash natively under macOS, Windows and Linux";
     homepage = "https://github.com/hsoft/send2trash";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/sentry-sdk/default.nix b/pkgs/development/python-modules/sentry-sdk/default.nix
index 5f640d44b1ca3..b846c0bc743bc 100644
--- a/pkgs/development/python-modules/sentry-sdk/default.nix
+++ b/pkgs/development/python-modules/sentry-sdk/default.nix
@@ -17,7 +17,7 @@
 , rq
 , sanic
 , sqlalchemy
-, stdenv
+, lib, stdenv
 , tornado
 , urllib3
 , trytond
@@ -58,7 +58,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "sentry_sdk" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/getsentry/sentry-python";
     description = "New Python SDK for Sentry.io";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/sepaxml/default.nix b/pkgs/development/python-modules/sepaxml/default.nix
index 94fd2d65d4645..095b47db2bff4 100644
--- a/pkgs/development/python-modules/sepaxml/default.nix
+++ b/pkgs/development/python-modules/sepaxml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy27
 , lxml
 , pytest
 , text-unidecode
@@ -28,7 +28,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/raphaelm/python-sepaxml/";
     description = "SEPA Direct Debit XML generation in python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/seqdiag/default.nix b/pkgs/development/python-modules/seqdiag/default.nix
index b7fba99860026..ba4cdca0c6361 100644
--- a/pkgs/development/python-modules/seqdiag/default.nix
+++ b/pkgs/development/python-modules/seqdiag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonPackage, isPy27, pep8, nose, unittest2, docutils
+{ lib, stdenv, fetchurl, buildPythonPackage, isPy27, pep8, nose, unittest2, docutils
 , blockdiag
 }:
 
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   #   ERROR: Failure: OSError ([Errno 2] No such file or directory: '/tmp/nix-build-python2.7-seqdiag-0.9.0.drv-0/seqdiag-0.9.0/src/seqdiag/tests/diagrams/')
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate sequence-diagram image from spec-text file (similar to Graphviz)";
     homepage = "http://blockdiag.com/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/serpent/default.nix b/pkgs/development/python-modules/serpent/default.nix
index cfb734e54759e..36840813b4012 100644
--- a/pkgs/development/python-modules/serpent/default.nix
+++ b/pkgs/development/python-modules/serpent/default.nix
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     ${python.interpreter} setup.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple serialization library based on ast.literal_eval";
     homepage = "https://github.com/irmen/Serpent";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/serversyncstorage/default.nix b/pkgs/development/python-modules/serversyncstorage/default.nix
index e8541da6cd454..fa212d6a4de5b 100644
--- a/pkgs/development/python-modules/serversyncstorage/default.nix
+++ b/pkgs/development/python-modules/serversyncstorage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -37,7 +37,7 @@ buildPythonPackage rec {
     pymysqlsa umemcache WSGIProxy requests pybrowserid
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = cornice.version != "0.17";
     description = "The SyncServer server software, as used by Firefox Sync";
     homepage = "https://github.com/mozilla-services/server-syncstorage";
diff --git a/pkgs/development/python-modules/setproctitle/default.nix b/pkgs/development/python-modules/setproctitle/default.nix
index 473ef25e162e2..a9c0e7fda893b 100644
--- a/pkgs/development/python-modules/setproctitle/default.nix
+++ b/pkgs/development/python-modules/setproctitle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # tries to compile programs with dependencies that aren't available
   pytestFlagsArray = [ "--ignore=tests/setproctitle_test.py" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows a process to change its title (as displayed by system tools such as ps and top)";
     homepage =  "https://github.com/dvarrazzo/py-setproctitle";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/setuptools-git/default.nix b/pkgs/development/python-modules/setuptools-git/default.nix
index 5c0b40b4af4e0..18fae7b1610bb 100644
--- a/pkgs/development/python-modules/setuptools-git/default.nix
+++ b/pkgs/development/python-modules/setuptools-git/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ pkgs.git ];
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Setuptools revision control system plugin for Git";
     homepage = "https://pypi.python.org/pypi/setuptools-git";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/setuptools-lint/default.nix b/pkgs/development/python-modules/setuptools-lint/default.nix
index fbe1528c4c3b2..ba42c21ad3603 100644
--- a/pkgs/development/python-modules/setuptools-lint/default.nix
+++ b/pkgs/development/python-modules/setuptools-lint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pylint }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pylint }:
 
 buildPythonPackage rec {
   pname = "setuptools-lint";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pylint ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Package to expose pylint as a lint command into setup.py";
     homepage = "https://github.com/johnnoone/setuptools-pylint";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/setuptools-rust/default.nix b/pkgs/development/python-modules/setuptools-rust/default.nix
index 5125e166a0ce3..2d9a4b17d40fa 100644
--- a/pkgs/development/python-modules/setuptools-rust/default.nix
+++ b/pkgs/development/python-modules/setuptools-rust/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -23,7 +23,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ semantic-version setuptools toml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Setuptools plugin for Rust support";
     homepage = "https://github.com/PyO3/setuptools-rust";
     changelog = "https://github.com/PyO3/setuptools-rust/releases/tag/v${version}";
diff --git a/pkgs/development/python-modules/setuptools-scm-git-archive/default.nix b/pkgs/development/python-modules/setuptools-scm-git-archive/default.nix
index d2b4640549690..d8558aaf83a72 100644
--- a/pkgs/development/python-modules/setuptools-scm-git-archive/default.nix
+++ b/pkgs/development/python-modules/setuptools-scm-git-archive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, setuptools_scm, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, setuptools_scm, pytest }:
 
 buildPythonPackage rec {
   pname = "setuptools-scm-git-archive";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "setuptools_scm_git_archive" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "setuptools_scm plugin for git archives";
     homepage = "https://github.com/Changaco/setuptools_scm_git_archive";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/setuptools/44.0.nix b/pkgs/development/python-modules/setuptools/44.0.nix
index c2f6eb230b478..7c7d6b01e4088 100644
--- a/pkgs/development/python-modules/setuptools/44.0.nix
+++ b/pkgs/development/python-modules/setuptools/44.0.nix
@@ -73,7 +73,7 @@ in buildPythonPackage rec {
   # Requires pytest, causing infinite recursion.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities to facilitate the installation of Python packages";
     homepage = "https://pypi.python.org/pypi/setuptools";
     license = with licenses; [ psfl zpl20 ];
diff --git a/pkgs/development/python-modules/setuptools/default.nix b/pkgs/development/python-modules/setuptools/default.nix
index 987c75ba5a030..12bbbb7d0e5b8 100644
--- a/pkgs/development/python-modules/setuptools/default.nix
+++ b/pkgs/development/python-modules/setuptools/default.nix
@@ -73,7 +73,7 @@ in buildPythonPackage rec {
   # Requires pytest, causing infinite recursion.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities to facilitate the installation of Python packages";
     homepage = "https://pypi.python.org/pypi/setuptools";
     license = with licenses; [ psfl zpl20 ];
diff --git a/pkgs/development/python-modules/setuptools_scm/default.nix b/pkgs/development/python-modules/setuptools_scm/default.nix
index fb527a1336d95..a766bb6c294fa 100644
--- a/pkgs/development/python-modules/setuptools_scm/default.nix
+++ b/pkgs/development/python-modules/setuptools_scm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pip, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pip, pytest }:
 
 buildPythonPackage rec {
   pname = "setuptools_scm";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   # Requires pytest, circular dependency
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/pypa/setuptools_scm/";
     description = "Handles managing your python package versions in scm metadata";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/setuptoolsdarcs/default.nix b/pkgs/development/python-modules/setuptoolsdarcs/default.nix
index 5e58f80985f5e..f6358a831c9c3 100644
--- a/pkgs/development/python-modules/setuptoolsdarcs/default.nix
+++ b/pkgs/development/python-modules/setuptoolsdarcs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , darcsver
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace "name=PKG" "name=PKG, version='${version}'"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Setuptools plugin for the Darcs version control system";
     homepage = "http://allmydata.org/trac/setuptools_darcs";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/setuptoolstrial/default.nix b/pkgs/development/python-modules/setuptoolstrial/default.nix
index b393d0eb2003b..1d29f77cf0f25 100644
--- a/pkgs/development/python-modules/setuptoolstrial/default.nix
+++ b/pkgs/development/python-modules/setuptoolstrial/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   # Couldn't get tests working
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Setuptools plugin that makes unit tests execute with trial instead of pyunit.";
     homepage = "https://github.com/rutsky/setuptools-trial";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/sexpdata/default.nix b/pkgs/development/python-modules/sexpdata/default.nix
index 1e282f9660a8f..89f716d9be254 100644
--- a/pkgs/development/python-modules/sexpdata/default.nix
+++ b/pkgs/development/python-modules/sexpdata/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "S-expression parser for Python";
     homepage = "https://github.com/tkf/sexpdata";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/shap/default.nix b/pkgs/development/python-modules/shap/default.nix
index deb6dcf2a21a7..1ce9a879ee19d 100644
--- a/pkgs/development/python-modules/shap/default.nix
+++ b/pkgs/development/python-modules/shap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -60,7 +60,7 @@ buildPythonPackage rec {
     "test_single_row_gradient_boosting_regressor"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A unified approach to explain the output of any machine learning model";
     homepage = "https://github.com/slundberg/shap";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/shapely/default.nix b/pkgs/development/python-modules/shapely/default.nix
index e2b738c479e67..f852f77bcfda1 100644
--- a/pkgs/development/python-modules/shapely/default.nix
+++ b/pkgs/development/python-modules/shapely/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, substituteAll, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, substituteAll, pythonOlder
 , geos, pytest, cython
 , numpy
 }:
@@ -39,7 +39,7 @@ buildPythonPackage rec {
     py.test tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Geometric objects, predicates, and operations";
     maintainers = with maintainers; [ knedlsepp ];
     homepage = "https://pypi.python.org/pypi/Shapely/";
diff --git a/pkgs/development/python-modules/shellingham/default.nix b/pkgs/development/python-modules/shellingham/default.nix
index 238d394ee11e7..77a4b98f54c30 100644
--- a/pkgs/development/python-modules/shellingham/default.nix
+++ b/pkgs/development/python-modules/shellingham/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 }:
 
 buildPythonPackage rec {
@@ -11,7 +11,7 @@ buildPythonPackage rec {
     sha256 = "576c1982bea0ba82fb46c36feb951319d7f42214a82634233f58b40d858a751e";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to Detect Surrounding Shell";
     homepage = "https://github.com/sarugaku/shellingham";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/shiboken2/default.nix b/pkgs/development/python-modules/shiboken2/default.nix
index ec44a9a15e14d..b7508a8f6447f 100644
--- a/pkgs/development/python-modules/shiboken2/default.nix
+++ b/pkgs/development/python-modules/shiboken2/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, python, fetchurl, stdenv, pyside2
+{ buildPythonPackage, python, fetchurl, lib, stdenv, pyside2
 , cmake, qt5, llvmPackages }:
 
 stdenv.mkDerivation {
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     rm $out/bin/shiboken_tool.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generator for the PySide2 Qt bindings";
     license = with licenses; [ gpl2 lgpl21 ];
     homepage = "https://wiki.qt.io/Qt_for_Python";
diff --git a/pkgs/development/python-modules/shippai/default.nix b/pkgs/development/python-modules/shippai/default.nix
index 1bae1c50fb66e..8fd15b71a0158 100644
--- a/pkgs/development/python-modules/shippai/default.nix
+++ b/pkgs/development/python-modules/shippai/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "shippai";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
     sha256 = "0r6iwvmay8ygn2m15pyjrk9am4mfpk7rkf0lcbcb15pnabixlyzj";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Use Rust failures as Python exceptions";
     homepage = "https://github.com/untitaker/shippai";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/shortuuid/default.nix b/pkgs/development/python-modules/shortuuid/default.nix
index 4fec2a3f04c00..35401afa6e3ee 100644
--- a/pkgs/development/python-modules/shortuuid/default.nix
+++ b/pkgs/development/python-modules/shortuuid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   buildInputs = [pep8];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A generator library for concise, unambiguous and URL-safe UUIDs";
     homepage = "https://github.com/stochastic-technologies/shortuuid/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/should-dsl/default.nix b/pkgs/development/python-modules/should-dsl/default.nix
index abfe47bfc7a72..1499f1ce4bc8b 100644
--- a/pkgs/development/python-modules/should-dsl/default.nix
+++ b/pkgs/development/python-modules/should-dsl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "should-dsl";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # There are no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Should assertions in Python as clear and readable as possible";
     homepage = "http://www.should-dsl.info/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/shouldbe/default.nix b/pkgs/development/python-modules/shouldbe/default.nix
index 068ed9343117f..9959f26036cfb 100644
--- a/pkgs/development/python-modules/shouldbe/default.nix
+++ b/pkgs/development/python-modules/shouldbe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pythonAtLeast
 , fetchPypi
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   checkInputs = [ nose ];
   propagatedBuildInputs = [ forbiddenfruit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Assertion Helpers inspired by Shouldly";
     homepage =  "https://pypi.python.org/pypi/shouldbe/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/signedjson/default.nix b/pkgs/development/python-modules/signedjson/default.nix
index 69f7a93f509d6..12614a3446bbd 100644
--- a/pkgs/development/python-modules/signedjson/default.nix
+++ b/pkgs/development/python-modules/signedjson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , canonicaljson
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ canonicaljson unpaddedbase64 pynacl typing-extensions ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.org/project/signedjson/";
     description = "Sign JSON with Ed25519 signatures";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/sigtools/default.nix b/pkgs/development/python-modules/sigtools/default.nix
index 92a39e26da0e6..0c11a2b6c5613 100644
--- a/pkgs/development/python-modules/sigtools/default.nix
+++ b/pkgs/development/python-modules/sigtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , repeated_test
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   patchPhase = ''sed -i s/test_suite="'"sigtools.tests"'"/test_suite="'"unittest2.collector"'"/ setup.py'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for working with 3.3's inspect.Signature objects.";
     homepage = "https://pypi.python.org/pypi/sigtools";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/simanneal/default.nix b/pkgs/development/python-modules/simanneal/default.nix
index 5b084c399ba50..958f53be567d5 100644
--- a/pkgs/development/python-modules/simanneal/default.nix
+++ b/pkgs/development/python-modules/simanneal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonPackage, pytest }:
+{ lib, stdenv, fetchFromGitHub, buildPythonPackage, pytest }:
 
 buildPythonPackage rec {
   pname = "simanneal";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest ];
   checkPhase = "pytest tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python implementation of the simulated annealing optimization technique";
     homepage = "https://github.com/perrygeo/simanneal";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/simple-websocket-server/default.nix b/pkgs/development/python-modules/simple-websocket-server/default.nix
index c802068137240..f8d579b6088de 100644
--- a/pkgs/development/python-modules/simple-websocket-server/default.nix
+++ b/pkgs/development/python-modules/simple-websocket-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub }:
 
 buildPythonPackage {
   pname = "simple-websocket-server";
@@ -12,7 +12,7 @@ buildPythonPackage {
 
   doCheck = false; # no tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python based websocket server that is simple and easy to use";
     homepage = "https://github.com/dpallot/simple-websocket-server/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/simpleai/default.nix b/pkgs/development/python-modules/simpleai/default.nix
index c8d1a99326f96..0786ebfae6e4a 100644
--- a/pkgs/development/python-modules/simpleai/default.nix
+++ b/pkgs/development/python-modules/simpleai/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -20,7 +20,7 @@ buildPythonPackage rec {
    #No tests in archive
    doCheck = false;
 
-   meta = with stdenv.lib; {
+   meta = with lib; {
      homepage = "https://github.com/simpleai-team/simpleai";
      description = "This lib implements many of the artificial intelligence algorithms described on the book 'Artificial Intelligence, a Modern Approach'";
      maintainers = with maintainers; [ NikolaMandic ];
diff --git a/pkgs/development/python-modules/simplebayes/default.nix b/pkgs/development/python-modules/simplebayes/default.nix
index 57f7df73c21d9..b7dd0310a0879 100644
--- a/pkgs/development/python-modules/simplebayes/default.nix
+++ b/pkgs/development/python-modules/simplebayes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , nose
@@ -27,7 +27,7 @@ buildPythonPackage {
 
   checkPhase = "nosetests tests/test.py";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Memory-based naive bayesian text classifier";
     homepage = "https://github.com/hickeroar/simplebayes";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/simpleparse/default.nix b/pkgs/development/python-modules/simpleparse/default.nix
index d1117b3a9d890..6395f4af223d5 100644
--- a/pkgs/development/python-modules/simpleparse/default.nix
+++ b/pkgs/development/python-modules/simpleparse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   doCheck = false;  # weird error
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Parser Generator for Python";
     homepage = "https://pypi.python.org/pypi/SimpleParse";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/skein/default.nix b/pkgs/development/python-modules/skein/default.nix
index 32320c5042fcb..40a179264273e 100644
--- a/pkgs/development/python-modules/skein/default.nix
+++ b/pkgs/development/python-modules/skein/default.nix
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     ln -s ${skeinJar} skein/java/skein.jar
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://jcristharif.com/skein";
     description = "A tool and library for easily deploying applications on Apache YARN";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/sklearn-deap/default.nix b/pkgs/development/python-modules/sklearn-deap/default.nix
index e4a01778352ad..36ec8b18ca7ee 100644
--- a/pkgs/development/python-modules/sklearn-deap/default.nix
+++ b/pkgs/development/python-modules/sklearn-deap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, numpy, scipy, deap, scikitlearn, python }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, fetchpatch, numpy, scipy, deap, scikitlearn, python }:
 
 buildPythonPackage rec {
   pname = "sklearn-deap";
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ${python.interpreter} test.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Use evolutionary algorithms instead of gridsearch in scikit-learn";
     homepage = "https://github.com/rsteca/sklearn-deap";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/slackclient/default.nix b/pkgs/development/python-modules/slackclient/default.nix
index b2578d5dd63da..571398b783dc5 100644
--- a/pkgs/development/python-modules/slackclient/default.nix
+++ b/pkgs/development/python-modules/slackclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , aiohttp
@@ -49,7 +49,7 @@ buildPythonPackage rec {
     responses
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A client for Slack, which supports the Slack Web API and Real Time Messaging (RTM) API";
     homepage = "https://github.com/slackapi/python-slackclient";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sleekxmpp/default.nix b/pkgs/development/python-modules/sleekxmpp/default.nix
index 426019fc8a97c..e6d5e59a80e7b 100644
--- a/pkgs/development/python-modules/sleekxmpp/default.nix
+++ b/pkgs/development/python-modules/sleekxmpp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, dns, pyasn1 }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, dns, pyasn1 }:
 
 buildPythonPackage rec {
   pname = "sleekxmpp";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "d213c1de71d92505f95ced0460ee0f84fdc4ddcacb7d7dd343739ed4028e5569";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XMPP library for Python";
     license = licenses.mit;
     homepage = "http://sleekxmpp.com/";
diff --git a/pkgs/development/python-modules/slicer/default.nix b/pkgs/development/python-modules/slicer/default.nix
index 8711055766c67..b5521f415d7b8 100644
--- a/pkgs/development/python-modules/slicer/default.nix
+++ b/pkgs/development/python-modules/slicer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook pandas pytorch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wraps tensor-like objects and provides a uniform slicing interface via __getitem__";
     homepage = "https://github.com/interpretml/slicer";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/slicerator/default.nix b/pkgs/development/python-modules/slicerator/default.nix
index 45d406f560e6f..396692200039e 100644
--- a/pkgs/development/python-modules/slicerator/default.nix
+++ b/pkgs/development/python-modules/slicerator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # run_tests.py not packaged with pypi release
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/soft-matter/slicerator";
     description = "A lazy-loading, fancy-sliceable iterable";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/slob/default.nix b/pkgs/development/python-modules/slob/default.nix
index 9e6ba2ff63500..a7520c62a62c9 100644
--- a/pkgs/development/python-modules/slob/default.nix
+++ b/pkgs/development/python-modules/slob/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy3k
@@ -24,7 +24,7 @@ buildPythonPackage {
     ${python.interpreter} -m unittest slob
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/itkach/slob/";
     description = "Reference implementation of the slob (sorted list of blobs) format";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/slowaes/default.nix b/pkgs/development/python-modules/slowaes/default.nix
index f9175e507b463..5d738fea57e06 100644
--- a/pkgs/development/python-modules/slowaes/default.nix
+++ b/pkgs/development/python-modules/slowaes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   disabled = isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://code.google.com/p/slowaes/";
     description = "AES implemented in pure python";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/development/python-modules/smartdc/default.nix b/pkgs/development/python-modules/smartdc/default.nix
index 2fe9926cab9a0..0b36a7e9f6e7c 100644
--- a/pkgs/development/python-modules/smartdc/default.nix
+++ b/pkgs/development/python-modules/smartdc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests http_signature ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Joyent SmartDataCenter CloudAPI connector using http-signature authentication via Requests";
     homepage = "https://github.com/atl/py-smartdc";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/smartypants/default.nix b/pkgs/development/python-modules/smartypants/default.nix
index 71ff2037de89f..a497f3db413b6 100644
--- a/pkgs/development/python-modules/smartypants/default.nix
+++ b/pkgs/development/python-modules/smartypants/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchhg
 , isPyPy
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     sha256 = "1cmzz44d2hm6y8jj2xcq1wfr26760gi7iq92ha8xbhb1axzd7nq6";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python with the SmartyPants";
     homepage = "https://bitbucket.org/livibetter/smartypants.py";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/snakeviz/default.nix b/pkgs/development/python-modules/snakeviz/default.nix
index a34996b8734cc..2c54f65d9c358 100644
--- a/pkgs/development/python-modules/snakeviz/default.nix
+++ b/pkgs/development/python-modules/snakeviz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, tornado }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, tornado }:
 
 buildPythonPackage rec {
   pname = "snakeviz";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   doCheck = false;
   propagatedBuildInputs = [ tornado ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Browser based viewer for profiling data";
     homepage = "https://jiffyclub.github.io/snakeviz";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/snapcast/default.nix b/pkgs/development/python-modules/snapcast/default.nix
index 93d7d1d9d9cf8..8446683cb1aa3 100644
--- a/pkgs/development/python-modules/snapcast/default.nix
+++ b/pkgs/development/python-modules/snapcast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, pytest
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, pytest
 , construct }:
 
 buildPythonPackage rec {
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # no checks from Pypi - https://github.com/happyleavesaoc/python-snapcast/issues/23
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Control Snapcast, a multi-room synchronous audio solution";
     homepage = "https://github.com/happyleavesaoc/python-snapcast/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/snappergui/default.nix b/pkgs/development/python-modules/snappergui/default.nix
index ff274c1ba8b3f..d63390185a98d 100644
--- a/pkgs/development/python-modules/snappergui/default.nix
+++ b/pkgs/development/python-modules/snappergui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , pygobject3
@@ -20,7 +20,7 @@ buildPythonPackage {
 
   propagatedBuildInputs = [ pygobject3 dbus-python ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ricardomv/snapper-gui";
     description = "Graphical frontend for snapper";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/snowballstemmer/default.nix b/pkgs/development/python-modules/snowballstemmer/default.nix
index c546fefcf5034..3364470da1b3f 100644
--- a/pkgs/development/python-modules/snowballstemmer/default.nix
+++ b/pkgs/development/python-modules/snowballstemmer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, PyStemmer, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, PyStemmer, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "snowballstemmer";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ PyStemmer ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "16 stemmer algorithms (15 + Poerter English stemmer) generated from Snowball algorithms";
     homepage = "http://sigal.saimon.org/en/latest/index.html";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/socksipy-branch/default.nix b/pkgs/development/python-modules/socksipy-branch/default.nix
index e17f38cb50dd6..ca9d8707ac63e 100644
--- a/pkgs/development/python-modules/socksipy-branch/default.nix
+++ b/pkgs/development/python-modules/socksipy-branch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "01l41v4g7fy9fzvinmjxy6zcbhgqaif8dhdqm4w90fwcw9h51a8p";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://code.google.com/p/socksipy-branch/";
     description = "This Python module allows you to create TCP connections through a SOCKS proxy without any special effort";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/somajo/default.nix b/pkgs/development/python-modules/somajo/default.nix
index c0b8aaca24fc7..bd351b5e86fac 100644
--- a/pkgs/development/python-modules/somajo/default.nix
+++ b/pkgs/development/python-modules/somajo/default.nix
@@ -1,4 +1,4 @@
-{ pkgs, stdenv, fetchFromGitHub, buildPythonPackage, isPy3k, regex }:
+{ pkgs, lib, stdenv, fetchFromGitHub, buildPythonPackage, isPy3k, regex }:
 
 buildPythonPackage rec {
   pname = "SoMaJo";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ regex ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tokenizer and sentence splitter for German and English web texts";
     homepage = "https://github.com/tsproisl/SoMaJo";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/sopel/default.nix b/pkgs/development/python-modules/sopel/default.nix
index 706175dfaad33..095c0917e5966 100644
--- a/pkgs/development/python-modules/sopel/default.nix
+++ b/pkgs/development/python-modules/sopel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPyPy
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPyPy
 , dnspython
 , geoip2
 , ipython
@@ -52,7 +52,7 @@ buildPythonPackage rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple and extensible IRC bot";
     homepage = "http://sopel.chat";
     license = licenses.efl20;
diff --git a/pkgs/development/python-modules/sorl_thumbnail/default.nix b/pkgs/development/python-modules/sorl_thumbnail/default.nix
index 03fbc638f1603..e918a1aee3bc9 100644
--- a/pkgs/development/python-modules/sorl_thumbnail/default.nix
+++ b/pkgs/development/python-modules/sorl_thumbnail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # Disabled due to an improper configuration error when tested against django. This looks like something broken in the test cases for sorl.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sorl-thumbnail.readthedocs.org/en/latest/";
     description = "Thumbnails for Django";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/sortedcollections/default.nix b/pkgs/development/python-modules/sortedcollections/default.nix
index b0b3df19bac3c..7bdeeffc0869f 100644
--- a/pkgs/development/python-modules/sortedcollections/default.nix
+++ b/pkgs/development/python-modules/sortedcollections/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , pytestCheckHook
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "sortedcollections" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python Sorted Collections";
     homepage = "http://www.grantjenks.com/docs/sortedcollections/";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/development/python-modules/spacy/models.nix b/pkgs/development/python-modules/spacy/models.nix
index c4a314ea47429..4279383ae6b19 100644
--- a/pkgs/development/python-modules/spacy/models.nix
+++ b/pkgs/development/python-modules/spacy/models.nix
@@ -16,7 +16,7 @@ let
 
     pythonImportsCheck = [ pname ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Models for the spaCy NLP library";
       homepage    = "https://github.com/explosion/spacy-models";
       license     = licenses.${license};
diff --git a/pkgs/development/python-modules/spark_parser/default.nix b/pkgs/development/python-modules/spark_parser/default.nix
index b513a9f33c8c5..cfb641ddcfb59 100644
--- a/pkgs/development/python-modules/spark_parser/default.nix
+++ b/pkgs/development/python-modules/spark_parser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   buildInputs = [ nose ];
   propagatedBuildInputs = [ click ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''An Early-Algorithm Context-free grammar Parser'';
     homepage = "https://github.com/rocky/python-spark";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sparqlwrapper/default.nix b/pkgs/development/python-modules/sparqlwrapper/default.nix
index fe400630507bc..b97cbee2a5feb 100644
--- a/pkgs/development/python-modules/sparqlwrapper/default.nix
+++ b/pkgs/development/python-modules/sparqlwrapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six isodate pyparsing html5lib keepalive ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This is a wrapper around a SPARQL service. It helps in creating the query URI and, possibly, convert the result into a more manageable format";
     homepage = "http://rdflib.github.io/sparqlwrapper";
     license = licenses.w3c;
diff --git a/pkgs/development/python-modules/speaklater/default.nix b/pkgs/development/python-modules/speaklater/default.nix
index 03b525147bfdf..efb0908dc5fc3 100644
--- a/pkgs/development/python-modules/speaklater/default.nix
+++ b/pkgs/development/python-modules/speaklater/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1ab5dbfzzgz6cnz4xlwx79gz83id4bhiw67k1cgqrlzfs0va7zjr";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Implements a lazy string for python useful for use with gettext";
     homepage = "https://github.com/mitsuhiko/speaklater";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/spglib/default.nix b/pkgs/development/python-modules/spglib/default.nix
index 37b9c24a22e1d..08bbb34156bf2 100644
--- a/pkgs/development/python-modules/spglib/default.nix
+++ b/pkgs/development/python-modules/spglib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, numpy, nose, pyyaml }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, numpy, nose, pyyaml }:
 
 buildPythonPackage rec {
   pname = "spglib";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose pyyaml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for C library for finding and handling crystal symmetries";
     homepage = "https://atztogo.github.io/spglib";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/sphinx_pypi_upload/default.nix b/pkgs/development/python-modules/sphinx_pypi_upload/default.nix
index 6d353cc63c966..77f283795db5d 100644
--- a/pkgs/development/python-modules/sphinx_pypi_upload/default.nix
+++ b/pkgs/development/python-modules/sphinx_pypi_upload/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "5f919a47ce7a7e6028dba809de81ae1297ac192347cf6fc54efca919d4865159";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Setuptools command for uploading Sphinx documentation to PyPI";
     homepage = "https://bitbucket.org/jezdez/sphinx-pypi-upload/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinx_rtd_theme/default.nix b/pkgs/development/python-modules/sphinx_rtd_theme/default.nix
index bb9fcb293da7c..11e3c2a87e936 100644
--- a/pkgs/development/python-modules/sphinx_rtd_theme/default.nix
+++ b/pkgs/development/python-modules/sphinx_rtd_theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , sphinx
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ReadTheDocs.org theme for Sphinx";
     homepage = "https://github.com/snide/sphinx_rtd_theme/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/sphinxcontrib-applehelp/default.nix b/pkgs/development/python-modules/sphinxcontrib-applehelp/default.nix
index 95aa0c5fdeb8f..e2bfc5bdaa553 100644
--- a/pkgs/development/python-modules/sphinxcontrib-applehelp/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-applehelp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Check is disabled due to circular dependency of sphinx
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sphinxcontrib-applehelp is a sphinx extension which outputs Apple help books";
     homepage = "http://sphinx-doc.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib-autoapi/default.nix b/pkgs/development/python-modules/sphinxcontrib-autoapi/default.nix
index 03ac746137f7a..6822c0f153d32 100644
--- a/pkgs/development/python-modules/sphinxcontrib-autoapi/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-autoapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -32,7 +32,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/readthedocs/sphinx-autoapi";
     description = "Provides 'autodoc' style documentation";
     longDescription = "Sphinx AutoAPI provides 'autodoc' style documentation for multiple programming languages without needing to load, run, or import the project being documented.";
diff --git a/pkgs/development/python-modules/sphinxcontrib-blockdiag/default.nix b/pkgs/development/python-modules/sphinxcontrib-blockdiag/default.nix
index b8f23afabcd50..a2603b876e5e4 100644
--- a/pkgs/development/python-modules/sphinxcontrib-blockdiag/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-blockdiag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover -s tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sphinx blockdiag extension";
     homepage = "https://github.com/blockdiag/sphinxcontrib-blockdiag";
     maintainers = with maintainers; [ nand0p ];
diff --git a/pkgs/development/python-modules/sphinxcontrib-devhelp/default.nix b/pkgs/development/python-modules/sphinxcontrib-devhelp/default.nix
index 01d34dd0ae62c..7398cbc433ffa 100644
--- a/pkgs/development/python-modules/sphinxcontrib-devhelp/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-devhelp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # Check is disabled due to circular dependency of sphinx
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sphinxcontrib-devhelp is a sphinx extension which outputs Devhelp document.";
     homepage = "http://sphinx-doc.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib-htmlhelp/default.nix b/pkgs/development/python-modules/sphinxcontrib-htmlhelp/default.nix
index 8eec8ab3267a9..150840f19b40c 100644
--- a/pkgs/development/python-modules/sphinxcontrib-htmlhelp/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-htmlhelp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Check is disabled due to circular dependency of sphinx
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sphinxcontrib-htmlhelp is a sphinx extension which ...";
     homepage = "http://sphinx-doc.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib-jsmath/default.nix b/pkgs/development/python-modules/sphinxcontrib-jsmath/default.nix
index 9b1d93287b03c..609799f18647a 100644
--- a/pkgs/development/python-modules/sphinxcontrib-jsmath/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-jsmath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Check is disabled due to circular dependency of sphinx
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sphinxcontrib-jsmath is a sphinx extension which renders display math in HTML via JavaScript.";
     homepage = "http://sphinx-doc.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib-openapi/default.nix b/pkgs/development/python-modules/sphinxcontrib-openapi/default.nix
index bd62d2ef4f8f5..6375bdab3c24b 100644
--- a/pkgs/development/python-modules/sphinxcontrib-openapi/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-openapi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -24,7 +24,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ikalnytskyi/sphinxcontrib-openapi";
     description = "OpenAPI (fka Swagger) spec renderer for Sphinx";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib-qthelp/default.nix b/pkgs/development/python-modules/sphinxcontrib-qthelp/default.nix
index f8e826adf1f38..adf02860d1277 100644
--- a/pkgs/development/python-modules/sphinxcontrib-qthelp/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-qthelp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Check is disabled due to circular dependency of sphinx
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document.";
     homepage = "http://sphinx-doc.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib-serializinghtml/default.nix b/pkgs/development/python-modules/sphinxcontrib-serializinghtml/default.nix
index 05f2749c49d64..52ebe15c1b62e 100644
--- a/pkgs/development/python-modules/sphinxcontrib-serializinghtml/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-serializinghtml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Check is disabled due to circular dependency of sphinx
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sphinxcontrib-serializinghtml is a sphinx extension which outputs \"serialized\" HTML files (json and pickle).";
     homepage = "http://sphinx-doc.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib-spelling/default.nix b/pkgs/development/python-modules/sphinxcontrib-spelling/default.nix
index 44e19997569c5..a3054f341450d 100644
--- a/pkgs/development/python-modules/sphinxcontrib-spelling/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib-spelling/default.nix
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # No tests included
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sphinx spelling extension";
     homepage = "https://bitbucket.org/dhellmann/sphinxcontrib-spelling";
     maintainers = with maintainers; [ nand0p ];
diff --git a/pkgs/development/python-modules/sphinxcontrib_httpdomain/default.nix b/pkgs/development/python-modules/sphinxcontrib_httpdomain/default.nix
index 9f042efcc97b7..ee652b42d8a15 100644
--- a/pkgs/development/python-modules/sphinxcontrib_httpdomain/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib_httpdomain/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , sphinx
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # https://bitbucket.org/pypa/setuptools/issue/137/typeerror-unorderable-types-str-nonetype
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a Sphinx domain for describing RESTful HTTP APIs";
     homepage = "https://bitbucket.org/birkenfeld/sphinx-contrib";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/sphinxcontrib_newsfeed/default.nix b/pkgs/development/python-modules/sphinxcontrib_newsfeed/default.nix
index 93c53581c4fac..2d56b57df9bed 100644
--- a/pkgs/development/python-modules/sphinxcontrib_newsfeed/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib_newsfeed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , sphinx
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ sphinx ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extension for adding a simple Blog, News or Announcements section to a Sphinx website";
     homepage = "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/sphinxcontrib_plantuml/default.nix b/pkgs/development/python-modules/sphinxcontrib_plantuml/default.nix
index ce65822e3b1f1..db8997dfd2162 100644
--- a/pkgs/development/python-modules/sphinxcontrib_plantuml/default.nix
+++ b/pkgs/development/python-modules/sphinxcontrib_plantuml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , sphinx
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ sphinx plantuml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a Sphinx domain for embedding UML diagram with PlantUML";
     homepage = "https://github.com/sphinx-contrib/plantuml/";
     license = with licenses; [ bsd2 ];
diff --git a/pkgs/development/python-modules/spyder-kernels/default.nix b/pkgs/development/python-modules/spyder-kernels/default.nix
index 8655d9cbbd5d4..e0a8d6b9c18ae 100644
--- a/pkgs/development/python-modules/spyder-kernels/default.nix
+++ b/pkgs/development/python-modules/spyder-kernels/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, cloudpickle, ipykernel, wurlitzer,
+{ lib, stdenv, buildPythonPackage, fetchPypi, cloudpickle, ipykernel, wurlitzer,
   jupyter_client, pyzmq }:
 
 buildPythonPackage rec {
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jupyter kernels for Spyder's console";
     homepage = "https://docs.spyder-ide.org/current/ipythonconsole.html";
     downloadPage = "https://github.com/spyder-ide/spyder-kernels/releases";
diff --git a/pkgs/development/python-modules/spyder/3.nix b/pkgs/development/python-modules/spyder/3.nix
index cac20ad6fce5d..34d59d0eb227c 100644
--- a/pkgs/development/python-modules/spyder/3.nix
+++ b/pkgs/development/python-modules/spyder/3.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, jedi, pycodestyle,
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, jedi, pycodestyle,
   psutil, pyflakes, rope, pylint, keyring, numpydoc,
   qtconsole, qtawesome, nbconvert, mccabe, pyopengl, cloudpickle, pygments,
   spyder-kernels_0_5, qtpy, pyzmq, chardet, pyqtwebengine
@@ -31,7 +31,7 @@ buildPythonPackage rec {
     substituteInPlace setup.py --replace "pyqt5<5.13" "pyqt5"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library providing a scientific python development environment";
     longDescription = ''
       Spyder (previously known as Pydee) is a powerful interactive development
diff --git a/pkgs/development/python-modules/spyder/default.nix b/pkgs/development/python-modules/spyder/default.nix
index f0c4ea50e72e8..a47a1278425da 100644
--- a/pkgs/development/python-modules/spyder/default.nix
+++ b/pkgs/development/python-modules/spyder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, makeDesktopItem, intervaltree, jedi, pycodestyle,
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, makeDesktopItem, intervaltree, jedi, pycodestyle,
   psutil, pyflakes, rope, numpy, scipy, matplotlib, pylint, keyring, numpydoc,
   qtconsole, qtawesome, nbconvert, mccabe, pyopengl, cloudpickle, pygments,
   spyder-kernels, qtpy, pyzmq, chardet, qdarkstyle, watchdog, python-language-server
@@ -65,7 +65,7 @@ buildPythonPackage rec {
     makeWrapperArgs+=("''${qtWrapperArgs[@]}")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scientific python development environment";
     longDescription = ''
       Spyder (previously known as Pydee) is a powerful interactive development
diff --git a/pkgs/development/python-modules/sqlalchemy-imageattach/default.nix b/pkgs/development/python-modules/sqlalchemy-imageattach/default.nix
index 35e6854137e39..6a8c910cfce6a 100644
--- a/pkgs/development/python-modules/sqlalchemy-imageattach/default.nix
+++ b/pkgs/development/python-modules/sqlalchemy-imageattach/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pytest
 , Wand
@@ -32,7 +32,7 @@ buildPythonPackage rec {
 
   doCheck = !isPyPy;  # failures due to sqla version mismatch
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dahlia/sqlalchemy-imageattach";
     description = "SQLAlchemy extension for attaching images to entity objects";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sqlalchemy-migrate/default.nix b/pkgs/development/python-modules/sqlalchemy-migrate/default.nix
index 1f5c893c6dbc0..bb757ab45b0ad 100644
--- a/pkgs/development/python-modules/sqlalchemy-migrate/default.nix
+++ b/pkgs/development/python-modules/sqlalchemy-migrate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, python
+{ lib, stdenv, buildPythonPackage, fetchPypi, fetchpatch, python
 , unittest2, scripttest, pytz, mock
 , testtools, pbr, tempita, decorator, sqlalchemy
 , six, sqlparse, testrepository
@@ -40,7 +40,7 @@ buildPythonPackage rec {
     ${python.interpreter} setup.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/openstack/sqlalchemy-migrate";
     description = "Schema migration tools for SQLAlchemy";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/sqlite3dbm/default.nix b/pkgs/development/python-modules/sqlite3dbm/default.nix
index 66a1200eeb2a5..1d0b3f15c3fcd 100644
--- a/pkgs/development/python-modules/sqlite3dbm/default.nix
+++ b/pkgs/development/python-modules/sqlite3dbm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "4721607e0b817b89efdba7e79cab881a03164b94777f4cf796ad5dd59a7612c5";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sqlite-backed dictionary";
     homepage = "https://github.com/Yelp/sqlite3dbm";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/sqlobject/default.nix b/pkgs/development/python-modules/sqlobject/default.nix
index ccd4190bbfdec..ccbc6659fe3dd 100644
--- a/pkgs/development/python-modules/sqlobject/default.nix
+++ b/pkgs/development/python-modules/sqlobject/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest ];
   propagatedBuildInputs = [ FormEncode PasteDeploy paste pydispatcher ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Object Relational Manager for providing an object interface to your database";
     homepage = "http://www.sqlobject.org/";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/squaremap/default.nix b/pkgs/development/python-modules/squaremap/default.nix
index 4927d8c725d4e..c17a88435dd67 100644
--- a/pkgs/development/python-modules/squaremap/default.nix
+++ b/pkgs/development/python-modules/squaremap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , isPy3k
 , fetchPypi
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six wxPython ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Hierarchic visualization control for wxPython";
     homepage = "https://launchpad.net/squaremap";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/srptools/default.nix b/pkgs/development/python-modules/srptools/default.nix
index 9fca318db0b9a..f130009d30d68 100644
--- a/pkgs/development/python-modules/srptools/default.nix
+++ b/pkgs/development/python-modules/srptools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six, pytest, pytestrunner }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six, pytest, pytestrunner }:
 
 buildPythonPackage rec {
   pname = "srptools";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest pytestrunner ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python-Tools to implement Secure Remote Password (SRP) authentication";
     homepage = "https://github.com/idlesign/srptools";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/srsly/default.nix b/pkgs/development/python-modules/srsly/default.nix
index ee53af641a059..42320e50fa8db 100644
--- a/pkgs/development/python-modules/srsly/default.nix
+++ b/pkgs/development/python-modules/srsly/default.nix
@@ -37,7 +37,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "srsly" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern high-performance serialization utilities for Python";
     homepage = "https://github.com/explosion/srsly";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/srvlookup/default.nix b/pkgs/development/python-modules/srvlookup/default.nix
index 6cbdc81ef86d2..c399ee760fd6c 100644
--- a/pkgs/development/python-modules/srvlookup/default.nix
+++ b/pkgs/development/python-modules/srvlookup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , dnspython
 , mock, nose
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ dnspython ];
   checkInputs = [ mock nose ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gmr/srvlookup";
     license = [ licenses.bsd3 ];
     description = "A small wrapper for dnspython to return SRV records for a given host, protocol, and domain name as a list of namedtuples.";
diff --git a/pkgs/development/python-modules/ssdeep/default.nix b/pkgs/development/python-modules/ssdeep/default.nix
index fc6b548ed5b85..8300c3ec2f656 100644
--- a/pkgs/development/python-modules/ssdeep/default.nix
+++ b/pkgs/development/python-modules/ssdeep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pkgs
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # tests repository does not include required files
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/DinoTools/python-ssdeep";
     description = "Python wrapper for the ssdeep library";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/ssdp/default.nix b/pkgs/development/python-modules/ssdp/default.nix
index 3c1d2c9976fa8..82ea4b066a3c4 100644
--- a/pkgs/development/python-modules/ssdp/default.nix
+++ b/pkgs/development/python-modules/ssdp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # test suite uses new async primitives
   doCheck = !isPy27;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/codingjoe/ssdp";
     description = "Python asyncio library for Simple Service Discovery Protocol (SSDP).";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sseclient/default.nix b/pkgs/development/python-modules/sseclient/default.nix
index ebc6435bc7946..9d944e112fe27 100644
--- a/pkgs/development/python-modules/sseclient/default.nix
+++ b/pkgs/development/python-modules/sseclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27
 , requests, six
 , backports_unittest-mock, pytestCheckHook, pytestrunner }:
 
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # tries to open connection to wikipedia
   disabledTests = [ "event_stream" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client library for reading Server Sent Event streams";
     homepage = "https://github.com/btubbs/sseclient";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sslib/default.nix b/pkgs/development/python-modules/sslib/default.nix
index 0f1edfd31bded..026ac8a30b752 100644
--- a/pkgs/development/python-modules/sslib/default.nix
+++ b/pkgs/development/python-modules/sslib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy3k }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy3k }:
 
 buildPythonPackage rec {
   pname = "sslib";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # No tests available
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jqueiroz/python-sslib";
     description = "A Python3 library for sharing secrets";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/statsd/default.nix b/pkgs/development/python-modules/statsd/default.nix
index cf376113b3e3c..447fed3263c3b 100644
--- a/pkgs/development/python-modules/statsd/default.nix
+++ b/pkgs/development/python-modules/statsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     sed -i 's/assert_called_once()/called/' statsd/tests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ domenkozar ];
     description = "A simple statsd client";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/stompclient/default.nix b/pkgs/development/python-modules/stompclient/default.nix
index 4cb59cf5f2852..17bafbad282e0 100644
--- a/pkgs/development/python-modules/stompclient/default.nix
+++ b/pkgs/development/python-modules/stompclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   # XXX: Ran 0 tests in 0.217s
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight and extensible STOMP messaging client";
     homepage = "https://bitbucket.org/hozn/stompclient";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/strict-rfc3339/default.nix b/pkgs/development/python-modules/strict-rfc3339/default.nix
index 7f45f326903a7..53701999b0211 100644
--- a/pkgs/development/python-modules/strict-rfc3339/default.nix
+++ b/pkgs/development/python-modules/strict-rfc3339/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "strict-rfc3339";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/danielrichman/strict-rfc3339";
     license = licenses.gpl3;
     description = "Strict, simple, lightweight RFC3339 functions";
diff --git a/pkgs/development/python-modules/stringcase/default.nix b/pkgs/development/python-modules/stringcase/default.nix
index 531f1eb92231d..10afb5113931d 100644
--- a/pkgs/development/python-modules/stringcase/default.nix
+++ b/pkgs/development/python-modules/stringcase/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, fetchPypi, stdenv
+{ buildPythonPackage, fetchPypi, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # PyPi package does not include tests.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/okunishinishi/python-stringcase";
     description = "Convert string cases between camel case, pascal case, snake case etc…";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/subdownloader/default.nix b/pkgs/development/python-modules/subdownloader/default.nix
index c4d57bef0ea9f..2dac94ac15d2e 100644
--- a/pkgs/development/python-modules/subdownloader/default.nix
+++ b/pkgs/development/python-modules/subdownloader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , mmpython
@@ -57,7 +57,7 @@ buildPythonPackage rec {
     echo '${setup}' > $sourceRoot/setup.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for automatic download/upload subtitles for videofiles using fast hashing";
     homepage = "https://www.subdownloader.net";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/suds-jurko/default.nix b/pkgs/development/python-modules/suds-jurko/default.nix
index e83448d82cf9a..4bf74fe00b4ef 100644
--- a/pkgs/development/python-modules/suds-jurko/default.nix
+++ b/pkgs/development/python-modules/suds-jurko/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -23,7 +23,7 @@ buildPythonPackage rec {
       --replace "test_sending_unicode_data" "noop"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight SOAP client (Jurko's fork)";
     homepage = "https://bitbucket.org/jurko/suds";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/suds/default.nix b/pkgs/development/python-modules/suds/default.nix
index 77f4c731265e3..24425fef95f14 100644
--- a/pkgs/development/python-modules/suds/default.nix
+++ b/pkgs/development/python-modules/suds/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   patches = [ ./suds-0.4-CVE-2013-2217.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     # Broken for security issues:
     # - https://github.com/NixOS/nixpkgs/issues/19678
     # - https://lwn.net/Vulnerabilities/559200/
diff --git a/pkgs/development/python-modules/sumo/default.nix b/pkgs/development/python-modules/sumo/default.nix
index 504d912128740..e647cd4a9d270 100644
--- a/pkgs/development/python-modules/sumo/default.nix
+++ b/pkgs/development/python-modules/sumo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, isPy27
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, isPy27
 , h5py
 , matplotlib
 , numpy
@@ -33,7 +33,7 @@ buildPythonPackage rec {
   # tests have type annotations, can only run on 3.5+
   doCheck = (!isPy27);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Toolkit for plotting and analysis of ab initio solid-state calculation data";
     homepage = "https://github.com/SMTG-UCL/sumo";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sure/default.nix b/pkgs/development/python-modules/sure/default.nix
index 2e6e7548efd8d..efff79f679f40 100644
--- a/pkgs/development/python-modules/sure/default.nix
+++ b/pkgs/development/python-modules/sure/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , rednose
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   buildInputs = [ rednose ];
   propagatedBuildInputs = [ six mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility belt for automated testing";
     homepage = "https://sure.readthedocs.io/en/latest/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/survey/default.nix b/pkgs/development/python-modules/survey/default.nix
index 1f5438140e2b0..f9bec0451ff45 100644
--- a/pkgs/development/python-modules/survey/default.nix
+++ b/pkgs/development/python-modules/survey/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , wrapio
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "survey" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Exahilosys/survey";
     description = "A simple library for creating beautiful interactive prompts";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/svg-path/default.nix b/pkgs/development/python-modules/svg-path/default.nix
index a8427558f4364..585dbf64b3c38 100644
--- a/pkgs/development/python-modules/svg-path/default.nix
+++ b/pkgs/development/python-modules/svg-path/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 buildPythonPackage rec {
   pname = "svg.path";
   version = "4.0.2";
@@ -8,7 +8,7 @@ buildPythonPackage rec {
     sha256 = "4bd627ec6526cd5da14f3c6a51205d930187db2d8992aed626825492c033b195";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SVG path objects and parser";
     homepage = "https://github.com/regebro/svg.path";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/svg2tikz/default.nix b/pkgs/development/python-modules/svg2tikz/default.nix
index b592ee75decec..fb0475ef3b979 100644
--- a/pkgs/development/python-modules/svg2tikz/default.nix
+++ b/pkgs/development/python-modules/svg2tikz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchgit
 , lxml
@@ -18,7 +18,7 @@ buildPythonPackage {
     rev = "ad36f2c3818da13c4136d70a0fd8153acf8daef4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kjellmf/svg2tikz";
     description = "An SVG to TikZ converter";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/swagger-ui-bundle/default.nix b/pkgs/development/python-modules/swagger-ui-bundle/default.nix
index 823f834b417c4..613de201b2d16 100644
--- a/pkgs/development/python-modules/swagger-ui-bundle/default.nix
+++ b/pkgs/development/python-modules/swagger-ui-bundle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, jinja2, flake8 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, jinja2, flake8 }:
 
 buildPythonPackage rec {
   pname = "swagger-ui-bundle";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # package contains no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "bundled swagger-ui pip package";
     homepage = "https://github.com/dtkav/swagger_ui_bundle";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/swspotify/default.nix b/pkgs/development/python-modules/swspotify/default.nix
index 27e5f0cb0bb82..30f34c56c81af 100644
--- a/pkgs/development/python-modules/swspotify/default.nix
+++ b/pkgs/development/python-modules/swspotify/default.nix
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/SwagLyrics/SwSpotify";
     description = "Library to get the currently playing song and artist from Spotify";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/sybase/default.nix b/pkgs/development/python-modules/sybase/default.nix
index 8fd0f023d0fa3..20c2a158a3b25 100644
--- a/pkgs/development/python-modules/sybase/default.nix
+++ b/pkgs/development/python-modules/sybase/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , isPy3k
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   SYBASE = freetds;
   setupPyBuildFlags = [ "-DHAVE_FREETDS" "-UWANT_BULKCOPY" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Sybase module provides a Python interface to the Sybase relational database system";
     homepage    = "http://python-sybase.sourceforge.net";
     license     = licenses.bsd3;
diff --git a/pkgs/development/python-modules/systemd/default.nix b/pkgs/development/python-modules/systemd/default.nix
index f0be01b92d89c..63ad1023b871a 100644
--- a/pkgs/development/python-modules/systemd/default.nix
+++ b/pkgs/development/python-modules/systemd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, systemd, pkgconfig }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, systemd, pkgconfig }:
 
 buildPythonPackage rec {
   pname = "systemd";
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python module for native access to the systemd facilities";
     homepage = "http://www.freedesktop.org/software/systemd/python-systemd/";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/sysv_ipc/default.nix b/pkgs/development/python-modules/sysv_ipc/default.nix
index 1c2e3baa526b2..87a81e4fb17da 100644
--- a/pkgs/development/python-modules/sysv_ipc/default.nix
+++ b/pkgs/development/python-modules/sysv_ipc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1p5lx3yz4p40rfb453m80a4hh8341yp4dki2nhhxz7bq2zfi1zwf";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SysV IPC primitives (semaphores, shared memory and message queues)";
     license = licenses.bsd3;
     homepage = "http://semanchuk.com/philip/sysv_ipc/";
diff --git a/pkgs/development/python-modules/tarman/default.nix b/pkgs/development/python-modules/tarman/default.nix
index f2a503cb55d86..682da22ced8a5 100644
--- a/pkgs/development/python-modules/tarman/default.nix
+++ b/pkgs/development/python-modules/tarman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   # tests are still failing
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/matejc/tarman";
     description = "Archive manager with curses interface";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/taskw/default.nix b/pkgs/development/python-modules/taskw/default.nix
index ee9a9716d1178..5a1358947130d 100644
--- a/pkgs/development/python-modules/taskw/default.nix
+++ b/pkgs/development/python-modules/taskw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -31,7 +31,7 @@ buildPythonPackage rec {
   buildInputs = [ nose pkgs.taskwarrior tox ];
   propagatedBuildInputs = [ six dateutil kitchen pytz ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage =  "https://github.com/ralphbean/taskw";
     description = "Python bindings for your taskwarrior database";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/tatsu/default.nix b/pkgs/development/python-modules/tatsu/default.nix
index 922ca1b9b9573..0469fc30e750b 100644
--- a/pkgs/development/python-modules/tatsu/default.nix
+++ b/pkgs/development/python-modules/tatsu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder
 , colorama, mypy, pyyaml, regex
 , dataclasses, typing
 , pytestrunner, pytest-mypy
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     pytest test/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generates Python parsers from grammars in a variation of EBNF";
     longDescription = ''
       TatSu (the successor to Grako) is a tool that takes grammars in a
diff --git a/pkgs/development/python-modules/tblib/default.nix b/pkgs/development/python-modules/tblib/default.nix
index 86992e6e16aaa..7e704e0b2c601 100644
--- a/pkgs/development/python-modules/tblib/default.nix
+++ b/pkgs/development/python-modules/tblib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "tblib";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "059bd77306ea7b419d4f76016aef6d7027cc8a0785579b5aad198803435f882c";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Traceback fiddling library. Allows you to pickle tracebacks.";
     homepage = "https://github.com/ionelmc/python-tblib";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/telegram/default.nix b/pkgs/development/python-modules/telegram/default.nix
index 6074f479071ec..95293d095fd53 100644
--- a/pkgs/development/python-modules/telegram/default.nix
+++ b/pkgs/development/python-modules/telegram/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1495l2ml8mg120wfvqhikqkfczhwwaby40vdmsz8v2l69jps01fl";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/liluo/telegram";
     description = "Telegram APIs";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/tensorflow-estimator/default.nix b/pkgs/development/python-modules/tensorflow-estimator/default.nix
index 750ef6e8a9076..f18364e111651 100644
--- a/pkgs/development/python-modules/tensorflow-estimator/default.nix
+++ b/pkgs/development/python-modules/tensorflow-estimator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , numpy
 , absl-py
 , mock
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ mock numpy absl-py ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TensorFlow Estimator is a high-level API that encapsulates model training, evaluation, prediction, and exporting.";
     homepage = "http://tensorflow.org";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/tensorflow/bin.nix b/pkgs/development/python-modules/tensorflow/bin.nix
index 8dd282666a75f..c0a9d5eadaffc 100644
--- a/pkgs/development/python-modules/tensorflow/bin.nix
+++ b/pkgs/development/python-modules/tensorflow/bin.nix
@@ -174,7 +174,7 @@ in buildPythonPackage {
     "tensorflow.python.framework"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Computation using data flow graphs for scalable machine learning";
     homepage = "http://tensorflow.org";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/tensorflow/default.nix b/pkgs/development/python-modules/tensorflow/default.nix
index 8d859920c7927..e726f927f5c01 100644
--- a/pkgs/development/python-modules/tensorflow/default.nix
+++ b/pkgs/development/python-modules/tensorflow/default.nix
@@ -323,7 +323,7 @@ let
       '';
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Computation using data flow graphs for scalable machine learning";
       homepage = "http://tensorflow.org";
       license = licenses.asl20;
diff --git a/pkgs/development/python-modules/termcolor/default.nix b/pkgs/development/python-modules/termcolor/default.nix
index 7879482f17d7d..df0f4d6208a3c 100644
--- a/pkgs/development/python-modules/termcolor/default.nix
+++ b/pkgs/development/python-modules/termcolor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "1d6d69ce66211143803fbc56652b41d73b4a400a2891d7bf7a1cdf4c02de613b";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Termcolor";
     homepage = "https://pypi.python.org/pypi/termcolor";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/terminaltables/default.nix b/pkgs/development/python-modules/terminaltables/default.nix
index bb6961f77ecfb..28e49316ad714 100644
--- a/pkgs/development/python-modules/terminaltables/default.nix
+++ b/pkgs/development/python-modules/terminaltables/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "f3eb0eb92e3833972ac36796293ca0906e998dc3be91fbe1f8615b331b853b81";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display simple tables in terminals";
     homepage = "https://github.com/Robpol86/terminaltables";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/testpath/default.nix b/pkgs/development/python-modules/testpath/default.nix
index 8357cd2c45683..a5ab52e5cdd5d 100644
--- a/pkgs/development/python-modules/testpath/default.nix
+++ b/pkgs/development/python-modules/testpath/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     sha256 = "bfcf9411ef4bf3db7579063e0546938b1edda3d69f4e1fb8756991f5951f85d4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test utilities for code working with files and commands";
     license = licenses.mit;
     homepage = "https://github.com/jupyter/testpath";
diff --git a/pkgs/development/python-modules/testrepository/default.nix b/pkgs/development/python-modules/testrepository/default.nix
index f3c7e169207f0..c249ca212b6dd 100644
--- a/pkgs/development/python-modules/testrepository/default.nix
+++ b/pkgs/development/python-modules/testrepository/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , testtools
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ${python.interpreter} ./testr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database of test results which can be used as part of developer workflow";
     homepage = "https://pypi.python.org/pypi/testrepository";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/testscenarios/default.nix b/pkgs/development/python-modules/testscenarios/default.nix
index 751ab02670a3b..465384edcb0c7 100644
--- a/pkgs/development/python-modules/testscenarios/default.nix
+++ b/pkgs/development/python-modules/testscenarios/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , testtools
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ testtools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pyunit extension for dependency injection";
     homepage = "https://pypi.python.org/pypi/testscenarios";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/thinc/default.nix b/pkgs/development/python-modules/thinc/default.nix
index cfc9264246051..bd520f2c4bfdb 100644
--- a/pkgs/development/python-modules/thinc/default.nix
+++ b/pkgs/development/python-modules/thinc/default.nix
@@ -74,7 +74,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "thinc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Practical Machine Learning for NLP in Python";
     homepage = "https://github.com/explosion/thinc";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/threadpool/default.nix b/pkgs/development/python-modules/threadpool/default.nix
index bbc3074c9642e..7a1696feb665b 100644
--- a/pkgs/development/python-modules/threadpool/default.nix
+++ b/pkgs/development/python-modules/threadpool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "197gzrxn9lbk0q1v079814c6s05cr4rwzyl6c1m6inkyif4yzr6c";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://chrisarndt.de/projects/threadpool/";
     description = "Easy to use object-oriented thread pool framework";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/thrift/default.nix b/pkgs/development/python-modules/thrift/default.nix
index 999d950771c71..c7279b867b106 100644
--- a/pkgs/development/python-modules/thrift/default.nix
+++ b/pkgs/development/python-modules/thrift/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # No tests. Breaks when not disabling.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for the Apache Thrift RPC system";
     homepage = "http://thrift.apache.org/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/thumborpexif/default.nix b/pkgs/development/python-modules/thumborpexif/default.nix
index 586045edc2738..abfad4ffaac9d 100644
--- a/pkgs/development/python-modules/thumborpexif/default.nix
+++ b/pkgs/development/python-modules/thumborpexif/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "96dcc03ea6066d9546baf54f6841f4048b0b24a291eed65d098b3348c8872d99";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Module to parse and edit the EXIF data tags in a JPEG image";
     homepage = "http://www.benno.id.au/code/pexif/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/tilestache/default.nix b/pkgs/development/python-modules/tilestache/default.nix
index d4e54fcc40e16..170360c133ed7 100644
--- a/pkgs/development/python-modules/tilestache/default.nix
+++ b/pkgs/development/python-modules/tilestache/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , modestmaps
@@ -23,7 +23,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ modestmaps pillow pycairo python-mapnik simplejson werkzeug ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tile server for rendered geographic data";
     homepage = "http://tilestache.org";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/timelib/default.nix b/pkgs/development/python-modules/timelib/default.nix
index 559dd0dd92f09..65b121ddfafd1 100644
--- a/pkgs/development/python-modules/timelib/default.nix
+++ b/pkgs/development/python-modules/timelib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -13,7 +13,7 @@ buildPythonPackage rec {
     sha256 = "6ac9f79b09b63bbc07db88525c1f62de1f6d50b0fd9937a0cb05e3d38ce0af45";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parse english textual date descriptions";
     homepage = "https://github.com/pediapress/timelib/";
     license = licenses.zlib;
diff --git a/pkgs/development/python-modules/timeout-decorator/default.nix b/pkgs/development/python-modules/timeout-decorator/default.nix
index d3b4a58c17e32..b1160cafe3091 100644
--- a/pkgs/development/python-modules/timeout-decorator/default.nix
+++ b/pkgs/development/python-modules/timeout-decorator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 buildPythonPackage rec {
   pname = "timeout-decorator";
   version = "0.5.0";
@@ -8,7 +8,7 @@ buildPythonPackage rec {
     sha256 = "6a2f2f58db1c5b24a2cc79de6345760377ad8bdc13813f5265f6c3e63d16b3d7";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Timeout decorator";
     license = licenses.mit;
     homepage = "https://github.com/pnpnpn/timeout-decorator";
diff --git a/pkgs/development/python-modules/tissue/default.nix b/pkgs/development/python-modules/tissue/default.nix
index 8f551ab5926da..fc4316c98fe97 100644
--- a/pkgs/development/python-modules/tissue/default.nix
+++ b/pkgs/development/python-modules/tissue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   buildInputs = [ nose ];
   propagatedBuildInputs = [ pep8 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/WoLpH/tissue";
     description = "Tissue - automated pep8 checker for nose";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/tld/default.nix b/pkgs/development/python-modules/tld/default.nix
index c3333aef9e1f7..01aa6a2900547 100644
--- a/pkgs/development/python-modules/tld/default.nix
+++ b/pkgs/development/python-modules/tld/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, python }:
+{ lib, stdenv, fetchPypi, python }:
 
 python.pkgs.buildPythonPackage rec {
   pname   = "tld";
@@ -29,7 +29,7 @@ python.pkgs.buildPythonPackage rec {
     "tld"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/barseghyanartur/tld";
     description = "Extracts the top level domain (TLD) from the URL given";
     license = licenses.lgpl21;
diff --git a/pkgs/development/python-modules/tlsh/default.nix b/pkgs/development/python-modules/tlsh/default.nix
index 3448d40cf3a49..302b113364d24 100644
--- a/pkgs/development/python-modules/tlsh/default.nix
+++ b/pkgs/development/python-modules/tlsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , cmake
@@ -24,7 +24,7 @@ buildPythonPackage {
     cd ../py_ext
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Trend Micro Locality Sensitive Hash";
     homepage = "https://github.com/trendmicro/tlsh";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/tlslite-ng/default.nix b/pkgs/development/python-modules/tlslite-ng/default.nix
index 7c8bb17b8b70c..a952c95d93e4a 100644
--- a/pkgs/development/python-modules/tlslite-ng/default.nix
+++ b/pkgs/development/python-modules/tlslite-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , ecdsa
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ ecdsa ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure python implementation of SSL and TLS.";
     homepage = "https://pypi.python.org/pypi/tlslite-ng";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/tlslite/default.nix b/pkgs/development/python-modules/tlslite/default.nix
index ac0c572ec3e70..a1e78c5db76c2 100644
--- a/pkgs/development/python-modules/tlslite/default.nix
+++ b/pkgs/development/python-modules/tlslite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "9b9a487694c239efea8cec4454a99a56ee1ae1a5f3af0858ccf8029e2ac2d42d";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure Python implementation of SSL and TLS";
     homepage = "https://pypi.python.org/pypi/tlslite";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/toggl-cli/default.nix b/pkgs/development/python-modules/toggl-cli/default.nix
index c004c4a5d9f30..875e70cee58ed 100644
--- a/pkgs/development/python-modules/toggl-cli/default.nix
+++ b/pkgs/development/python-modules/toggl-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pythonAtLeast, pythonOlder
+{ lib, stdenv, buildPythonPackage, fetchPypi, pythonAtLeast, pythonOlder
 , click
 , click-completion
 , factory_boy
@@ -61,7 +61,7 @@ buildPythonPackage rec {
     validate-email
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://toggl.uhlir.dev/";
     description = "Command line tool and set of Python wrapper classes for interacting with toggl's API";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/tokenizers/default.nix b/pkgs/development/python-modules/tokenizers/default.nix
index 4e5aacd6c7acc..d5d92b19061aa 100644
--- a/pkgs/development/python-modules/tokenizers/default.nix
+++ b/pkgs/development/python-modules/tokenizers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , fetchurl
@@ -105,7 +105,7 @@ in rustPlatform.buildRustPackage rec {
     pipInstallPhase
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/huggingface/tokenizers";
     description = "Fast State-of-the-Art Tokenizers optimized for Research and Production";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/tokenlib/default.nix b/pkgs/development/python-modules/tokenlib/default.nix
index 7c8e99cc399a9..2bed188701661 100644
--- a/pkgs/development/python-modules/tokenlib/default.nix
+++ b/pkgs/development/python-modules/tokenlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , requests
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests webob ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mozilla-services/tokenlib";
     description = "Generic support library for signed-token-based auth schemes";
     license = licenses.mpl20;
diff --git a/pkgs/development/python-modules/toml/default.nix b/pkgs/development/python-modules/toml/default.nix
index 96c6635771c7a..0d0d87c73d117 100644
--- a/pkgs/development/python-modules/toml/default.nix
+++ b/pkgs/development/python-modules/toml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "toml";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
   # git to download a test suite.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a Python library for parsing and creating TOML";
     homepage = "https://github.com/uiri/toml";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/toposort/default.nix b/pkgs/development/python-modules/toposort/default.nix
index f1767862ad326..43df3c4e21e94 100644
--- a/pkgs/development/python-modules/toposort/default.nix
+++ b/pkgs/development/python-modules/toposort/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "a7428f56ef844f5055bb9e9e44b343983773ae6dce0fe5b101e08e27ffbd50ac";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A topological sort algorithm";
     homepage = "https://pypi.python.org/pypi/toposort/1.1";
     maintainers = with maintainers; [ tstrobel ];
diff --git a/pkgs/development/python-modules/torchvision/default.nix b/pkgs/development/python-modules/torchvision/default.nix
index ea702a78fe1d7..928616eb4f8ad 100644
--- a/pkgs/development/python-modules/torchvision/default.nix
+++ b/pkgs/development/python-modules/torchvision/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , ninja
@@ -41,7 +41,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PyTorch vision library";
     homepage = "https://pytorch.org/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/traceback2/default.nix b/pkgs/development/python-modules/traceback2/default.nix
index 3a70df1548d0c..5309ae47a02d5 100644
--- a/pkgs/development/python-modules/traceback2/default.nix
+++ b/pkgs/development/python-modules/traceback2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pbr
@@ -19,7 +19,7 @@ buildPythonPackage rec {
   # circular dependencies for tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A backport of traceback to older supported Pythons";
     homepage = "https://pypi.python.org/pypi/traceback2/";
     license = licenses.psfl;
diff --git a/pkgs/development/python-modules/tracing/default.nix b/pkgs/development/python-modules/tracing/default.nix
index 6f9091d8517f4..f4c01f003a9a2 100644
--- a/pkgs/development/python-modules/tracing/default.nix
+++ b/pkgs/development/python-modules/tracing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , sphinx
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://liw.fi/tracing/";
     description = "Python debug logging helper";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/trackpy/default.nix b/pkgs/development/python-modules/trackpy/default.nix
index 6d198534149d2..6132a30c4141d 100644
--- a/pkgs/development/python-modules/trackpy/default.nix
+++ b/pkgs/development/python-modules/trackpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , numpy
@@ -49,7 +49,7 @@ buildPythonPackage rec {
                    --ignore trackpy/tests/test_legacy_linking.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Particle-tracking toolkit";
     homepage = "https://github.com/soft-matter/trackpy";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/traits/default.nix b/pkgs/development/python-modules/traits/default.nix
index 789ba7a1691ec..e3bc8b43fe4e7 100644
--- a/pkgs/development/python-modules/traits/default.nix
+++ b/pkgs/development/python-modules/traits/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -31,7 +31,7 @@ buildPythonPackage rec {
   # Furthermore, some tests fail due to being in a chroot
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Explicitly typed attributes for Python";
     homepage = "https://pypi.python.org/pypi/traits";
     license = "BSD";
diff --git a/pkgs/development/python-modules/transaction/default.nix b/pkgs/development/python-modules/transaction/default.nix
index 887c46863362c..def2559a72d0d 100644
--- a/pkgs/development/python-modules/transaction/default.nix
+++ b/pkgs/development/python-modules/transaction/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , zope_interface
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ zope_interface mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Transaction management";
     homepage = "https://pypi.python.org/pypi/transaction";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/transformers/default.nix b/pkgs/development/python-modules/transformers/default.nix
index bd9040668c086..743cbebea7550 100644
--- a/pkgs/development/python-modules/transformers/default.nix
+++ b/pkgs/development/python-modules/transformers/default.nix
@@ -1,5 +1,5 @@
 { buildPythonPackage
-, stdenv
+, lib, stdenv
 , fetchFromGitHub
 , isPy39
 , cookiecutter
@@ -97,7 +97,7 @@ buildPythonPackage rec {
     "test_tokenizer_identifier_non_existent"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/huggingface/transformers";
     description = "State-of-the-art Natural Language Processing for TensorFlow 2.0 and PyTorch";
     changelog = "https://github.com/huggingface/transformers/releases/tag/v${version}";
diff --git a/pkgs/development/python-modules/transip/default.nix b/pkgs/development/python-modules/transip/default.nix
index 8ea70a19ead49..e270d5a0662dd 100644
--- a/pkgs/development/python-modules/transip/default.nix
+++ b/pkgs/development/python-modules/transip/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , isPy27
@@ -32,7 +32,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ requests cryptography suds-jurko ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TransIP API Connector";
     homepage = "https://github.com/benkonrath/transip-api";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/transitions/default.nix b/pkgs/development/python-modules/transitions/default.nix
index 2691890a5ee1f..82958029923a4 100644
--- a/pkgs/development/python-modules/transitions/default.nix
+++ b/pkgs/development/python-modules/transitions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , six, nose, mock, dill, pycodestyle }:
 
 buildPythonPackage rec {
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pytransitions/transitions";
     description = "A lightweight, object-oriented finite state machine implementation in Python";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/translationstring/default.nix b/pkgs/development/python-modules/translationstring/default.nix
index 013615de800bd..2f39b57b480fe 100644
--- a/pkgs/development/python-modules/translationstring/default.nix
+++ b/pkgs/development/python-modules/translationstring/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "bf947538d76e69ba12ab17283b10355a9ecfbc078e6123443f43f2107f6376f3";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pylonsproject.org/";
     description = "Utility library for i18n relied on by various Repoze and Pyramid packages";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/transmissionrpc/default.nix b/pkgs/development/python-modules/transmissionrpc/default.nix
index eb209a0d49ecd..a128b150579a7 100644
--- a/pkgs/development/python-modules/transmissionrpc/default.nix
+++ b/pkgs/development/python-modules/transmissionrpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python implementation of the Transmission bittorent client RPC protocol";
     homepage = "https://pypi.python.org/pypi/transmissionrpc/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/treq/default.nix b/pkgs/development/python-modules/treq/default.nix
index 919ef529407ae..477223e96186b 100644
--- a/pkgs/development/python-modules/treq/default.nix
+++ b/pkgs/development/python-modules/treq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, service-identity, requests, six
+{ lib, stdenv, fetchPypi, buildPythonPackage, service-identity, requests, six
 , mock, twisted, incremental, pep8, httpbin
 }:
 
@@ -47,7 +47,7 @@ buildPythonPackage rec {
   # Failing tests https://github.com/twisted/treq/issues/208
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/twisted/treq";
     description = "A requests-like API built on top of twisted.web's Agent";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/trezor_agent/default.nix b/pkgs/development/python-modules/trezor_agent/default.nix
index fa9c11e95def2..537b4db7995ab 100644
--- a/pkgs/development/python-modules/trezor_agent/default.nix
+++ b/pkgs/development/python-modules/trezor_agent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , trezor
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "libagent" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Using Trezor as hardware SSH agent";
     homepage = "https://github.com/romanz/trezor-agent";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/trollius/default.nix b/pkgs/development/python-modules/trollius/default.nix
index b81a92d08e668..019326c542171 100644
--- a/pkgs/development/python-modules/trollius/default.nix
+++ b/pkgs/development/python-modules/trollius/default.nix
@@ -43,7 +43,7 @@ buildPythonPackage rec {
     sed -i -e "s|test_write_pty|skip_test_write_pty|g" tests/test_events.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Port of the asyncio project to Python 2.7";
     homepage = "https://github.com/vstinner/trollius";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/trueskill/default.nix b/pkgs/development/python-modules/trueskill/default.nix
index 18033aff391c4..0c3efa404ec62 100644
--- a/pkgs/development/python-modules/trueskill/default.nix
+++ b/pkgs/development/python-modules/trueskill/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , six }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # Can't build distribute, see https://github.com/NixOS/nixpkgs/pull/49340
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The video game rating system";
     homepage = "https://trueskill.org";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/ttystatus/default.nix b/pkgs/development/python-modules/ttystatus/default.nix
index a76a5f8df383b..24eb10637078a 100644
--- a/pkgs/development/python-modules/ttystatus/default.nix
+++ b/pkgs/development/python-modules/ttystatus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , sphinx
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # error: invalid command 'test'
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://liw.fi/ttystatus/";
     description = "Progress and status updates on terminals for Python";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/tvdb_api/default.nix b/pkgs/development/python-modules/tvdb_api/default.nix
index beabc8c231068..f2cdbe8dc6331 100644
--- a/pkgs/development/python-modules/tvdb_api/default.nix
+++ b/pkgs/development/python-modules/tvdb_api/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , requests-cache
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # requires network access
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple to use TVDB (thetvdb.com) API in Python";
     homepage = "https://github.com/dbr/tvdb_api";
     license = licenses.unlicense;
diff --git a/pkgs/development/python-modules/tvnamer/default.nix b/pkgs/development/python-modules/tvnamer/default.nix
index 81fa2e61b02af..fa155b86f4070 100644
--- a/pkgs/development/python-modules/tvnamer/default.nix
+++ b/pkgs/development/python-modules/tvnamer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # a ton of tests fail with: IOError: tvnamer/main.py could not be found in . or ..
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic TV episode file renamer, uses data from thetvdb.com via tvdb_api.";
     homepage = "https://github.com/dbr/tvnamer";
     license = licenses.unlicense;
diff --git a/pkgs/development/python-modules/twiggy/default.nix b/pkgs/development/python-modules/twiggy/default.nix
index fdff4a90f9e12..9647dc8ae67cf 100644
--- a/pkgs/development/python-modules/twiggy/default.nix
+++ b/pkgs/development/python-modules/twiggy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ six ];
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://twiggy.wearpants.org";
     # Taken from http://i.wearpants.org/blog/meet-twiggy/
     description = "Twiggy is the first totally new design for a logger since log4j";
diff --git a/pkgs/development/python-modules/twilio/default.nix b/pkgs/development/python-modules/twilio/default.nix
index d4cd7b5d59bfd..7931a4ad0ec9e 100644
--- a/pkgs/development/python-modules/twilio/default.nix
+++ b/pkgs/development/python-modules/twilio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , pyjwt, pysocks, pytz, requests, six, nose, mock }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyjwt pysocks pytz six requests ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twilio API client and TwiML generator";
     homepage = "https://github.com/twilio/twilio-python/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/twisted/default.nix b/pkgs/development/python-modules/twisted/default.nix
index d38d6aebcbd88..efec0b737bce0 100644
--- a/pkgs/development/python-modules/twisted/default.nix
+++ b/pkgs/development/python-modules/twisted/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -49,7 +49,7 @@ buildPythonPackage rec {
   # Tests require network
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://twistedmatrix.com/";
     description = "Twisted, an event-driven networking engine written in Python";
     longDescription = ''
diff --git a/pkgs/development/python-modules/twitter-common-collections/default.nix b/pkgs/development/python-modules/twitter-common-collections/default.nix
index d562eac5cc7d8..72f30514dc67a 100644
--- a/pkgs/development/python-modules/twitter-common-collections/default.nix
+++ b/pkgs/development/python-modules/twitter-common-collections/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , twitter-common-lang
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ twitter-common-lang ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twitter's common collections";
     homepage    = "https://twitter.github.io/commons/";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/twitter-common-confluence/default.nix b/pkgs/development/python-modules/twitter-common-confluence/default.nix
index 1253b8077e753..ee5bf9bdbe10e 100644
--- a/pkgs/development/python-modules/twitter-common-confluence/default.nix
+++ b/pkgs/development/python-modules/twitter-common-confluence/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , twitter-common-log
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ twitter-common-log ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twitter's API to the confluence wiki";
     homepage    = "https://twitter.github.io/commons/";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/twitter-common-dirutil/default.nix b/pkgs/development/python-modules/twitter-common-dirutil/default.nix
index df2f614c5a040..14b0bcd0673c2 100644
--- a/pkgs/development/python-modules/twitter-common-dirutil/default.nix
+++ b/pkgs/development/python-modules/twitter-common-dirutil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , twitter-common-lang
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ twitter-common-lang ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for manipulating and finding files and directories";
     homepage    = "https://twitter.github.io/commons/";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/twitter-common-lang/default.nix b/pkgs/development/python-modules/twitter-common-lang/default.nix
index 59f6d74ad67ab..4b4a5c0fc2e24 100644
--- a/pkgs/development/python-modules/twitter-common-lang/default.nix
+++ b/pkgs/development/python-modules/twitter-common-lang/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "6e967ca2b5bb96ea749d21052f45b18e37deb5cc160eb12c64a8f1cb9dba7a22";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twitter's 2.x / 3.x compatibility swiss-army knife";
     homepage    = "https://twitter.github.io/commons/";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/twitter-common-log/default.nix b/pkgs/development/python-modules/twitter-common-log/default.nix
index 1c3d1808f5ddc..8cf99c39dc206 100644
--- a/pkgs/development/python-modules/twitter-common-log/default.nix
+++ b/pkgs/development/python-modules/twitter-common-log/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , twitter-common-options
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ twitter-common-options twitter-common-dirutil ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twitter's common logging library";
     homepage    = "https://twitter.github.io/commons/";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/twitter-common-options/default.nix b/pkgs/development/python-modules/twitter-common-options/default.nix
index 12e55a46ab8ef..a5505330bc0a0 100644
--- a/pkgs/development/python-modules/twitter-common-options/default.nix
+++ b/pkgs/development/python-modules/twitter-common-options/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "a495bcdffc410039bc4166f1a30c2caa3c92769d7a161a4a39d3651836dd27e1";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twitter's optparse wrapper";
     homepage    = "https://twitter.github.io/commons/";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/twitter/default.nix b/pkgs/development/python-modules/twitter/default.nix
index 2e8481198a412..23d647d93153c 100644
--- a/pkgs/development/python-modules/twitter/default.nix
+++ b/pkgs/development/python-modules/twitter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Twitter API library";
     license     = licenses.mit;
     maintainers = with maintainers; [ thoughtpolice ];
diff --git a/pkgs/development/python-modules/txaio/default.nix b/pkgs/development/python-modules/txaio/default.nix
index 7e87a2d59ea4a..4d756fa89f3f3 100644
--- a/pkgs/development/python-modules/txaio/default.nix
+++ b/pkgs/development/python-modules/txaio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, mock, six, twisted, isPy37, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, mock, six, twisted, isPy37, isPy27 }:
 
 buildPythonPackage rec {
   pname = "txaio";
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # Needs some fixing
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities to support code that runs unmodified on Twisted and asyncio.";
     homepage    = "https://github.com/crossbario/txaio";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/txamqp/default.nix b/pkgs/development/python-modules/txamqp/default.nix
index db973dbffbed8..f0e3904a8815a 100644
--- a/pkgs/development/python-modules/txamqp/default.nix
+++ b/pkgs/development/python-modules/txamqp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , twisted
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ twisted ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/txamqp/txamqp";
     description = "Library for communicating with AMQP peers and brokers using Twisted";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/txdbus/default.nix b/pkgs/development/python-modules/txdbus/default.nix
index f6bc44981fb17..461ddeee34b41 100644
--- a/pkgs/development/python-modules/txdbus/default.nix
+++ b/pkgs/development/python-modules/txdbus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, six, twisted }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, six, twisted }:
 
 buildPythonPackage rec {
   pname = "txdbus";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ six twisted ];
   pythonImportsCheck = [ "txdbus" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Native Python implementation of DBus for Twisted";
     homepage = "https://github.com/cocagne/txdbus";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/txgithub/default.nix b/pkgs/development/python-modules/txgithub/default.nix
index 5340b202e688a..402e5011ede63 100644
--- a/pkgs/development/python-modules/txgithub/default.nix
+++ b/pkgs/development/python-modules/txgithub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pyopenssl
@@ -29,7 +29,7 @@ buildPythonPackage rec {
   # No tests distributed
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GitHub API client implemented using Twisted.";
     homepage    = "https://github.com/tomprince/txgithub";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/txrequests/default.nix b/pkgs/development/python-modules/txrequests/default.nix
index ee7d09d516578..06979e2b9b395 100644
--- a/pkgs/development/python-modules/txrequests/default.nix
+++ b/pkgs/development/python-modules/txrequests/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , twisted
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Asynchronous Python HTTP for Humans.";
     homepage    = "https://github.com/tardyp/txrequests";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/typeguard/default.nix b/pkgs/development/python-modules/typeguard/default.nix
index ee36a6dab8108..448e52af7afab 100644
--- a/pkgs/development/python-modules/typeguard/default.nix
+++ b/pkgs/development/python-modules/typeguard/default.nix
@@ -1,7 +1,7 @@
 { buildPythonPackage
 , fetchPypi
 , pythonOlder
-, stdenv
+, lib, stdenv
 , setuptools_scm
 , pytest
 , typing-extensions
@@ -34,7 +34,7 @@ buildPythonPackage rec {
 
   disabled = pythonOlder "3.3";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This library provides run-time type checking for functions defined with argument type annotations";
     homepage = "https://github.com/agronholm/typeguard";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/typogrify/default.nix b/pkgs/development/python-modules/typogrify/default.nix
index f5724877bf2b7..faa1c8641c05e 100644
--- a/pkgs/development/python-modules/typogrify/default.nix
+++ b/pkgs/development/python-modules/typogrify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -22,7 +22,7 @@ buildPythonPackage rec {
   # Wants to set up Django
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Filters to enhance web typography, including support for Django & Jinja templates";
     homepage = "https://github.com/mintchaos/typogrify";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/tzlocal/default.nix b/pkgs/development/python-modules/tzlocal/default.nix
index e5ab115953034..df0923833fd5b 100644
--- a/pkgs/development/python-modules/tzlocal/default.nix
+++ b/pkgs/development/python-modules/tzlocal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytz }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # test fail (timezone test fail)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tzinfo object for the local timezone";
     homepage = "https://github.com/regebro/tzlocal";
     license = licenses.cddl;
diff --git a/pkgs/development/python-modules/ua-parser/default.nix b/pkgs/development/python-modules/ua-parser/default.nix
index 875f0ee2075ae..370ed527d193e 100644
--- a/pkgs/development/python-modules/ua-parser/default.nix
+++ b/pkgs/development/python-modules/ua-parser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pyyaml }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pyyaml }:
 
 buildPythonPackage rec {
   pname = "ua-parser";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   doCheck = false; # requires files from uap-core
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python implementation of the UA Parser";
     homepage = "https://github.com/ua-parser/uap-python";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ujson/2.nix b/pkgs/development/python-modules/ujson/2.nix
index e1d1185f6f5e8..f31b26a1960ab 100644
--- a/pkgs/development/python-modules/ujson/2.nix
+++ b/pkgs/development/python-modules/ujson/2.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptools_scm
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     pytestCheckHook
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/ujson";
     description = "Ultra fast JSON encoder and decoder for Python";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/ujson/default.nix b/pkgs/development/python-modules/ujson/default.nix
index e7a9ee8f35a7a..1c12a092a2f5d 100644
--- a/pkgs/development/python-modules/ujson/default.nix
+++ b/pkgs/development/python-modules/ujson/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   nativeBuildInputs = [ setuptools_scm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/ujson";
     description = "Ultra fast JSON encoder and decoder for Python";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/umalqurra/default.nix b/pkgs/development/python-modules/umalqurra/default.nix
index 2eea9ebf385c4..4411dbac11b84 100644
--- a/pkgs/development/python-modules/umalqurra/default.nix
+++ b/pkgs/development/python-modules/umalqurra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   # See for license
   # https://github.com/tytkal/python-hijiri-ummalqura/issues/4
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Date Api that support Hijri Umalqurra calendar";
     homepage = "https://github.com/tytkal/python-hijiri-ummalqura";
     license = with licenses; [ publicDomain ];
diff --git a/pkgs/development/python-modules/umemcache/default.nix b/pkgs/development/python-modules/umemcache/default.nix
index 07bb181958adf..f852483cda689 100644
--- a/pkgs/development/python-modules/umemcache/default.nix
+++ b/pkgs/development/python-modules/umemcache/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchurl }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchurl }:
 
 buildPythonPackage rec {
   pname = "umemcache";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ultra fast memcache client written in highly optimized C++ with Python bindings";
     homepage = "https://github.com/esnme/ultramemcache";
     license = licenses.bsdOriginal;
diff --git a/pkgs/development/python-modules/uncertainties/default.nix b/pkgs/development/python-modules/uncertainties/default.nix
index 84705be59bc1f..117188198ca8d 100644
--- a/pkgs/development/python-modules/uncertainties/default.nix
+++ b/pkgs/development/python-modules/uncertainties/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage
+{ lib, stdenv, fetchPypi, buildPythonPackage
 , nose, numpy, future
 }:
 
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   checkPhase = "python setup.py nosetests -sv";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pythonhosted.org/uncertainties/";
     description = "Transparent calculations with uncertainties on the quantities involved (aka error propagation)";
     maintainers = with maintainers; [ rnhmjoj ];
diff --git a/pkgs/development/python-modules/uncompyle6/default.nix b/pkgs/development/python-modules/uncompyle6/default.nix
index 425b2e31ca614..4f8d461c87e27 100644
--- a/pkgs/development/python-modules/uncompyle6/default.nix
+++ b/pkgs/development/python-modules/uncompyle6/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonAtLeast
@@ -30,7 +30,7 @@ buildPythonPackage rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python cross-version byte-code deparser";
     homepage = "https://github.com/rocky/python-uncompyle6/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/unicode-slugify/default.nix b/pkgs/development/python-modules/unicode-slugify/default.nix
index 111ff6278eab3..80ac5151b53f4 100644
--- a/pkgs/development/python-modules/unicode-slugify/default.nix
+++ b/pkgs/development/python-modules/unicode-slugify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   checkInputs = [ nose unittest2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generates unicode slugs";
     homepage = "https://pypi.org/project/unicode-slugify/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/unicodecsv/default.nix b/pkgs/development/python-modules/unicodecsv/default.nix
index 83ef602de600e..9393ff58bc27d 100644
--- a/pkgs/development/python-modules/unicodecsv/default.nix
+++ b/pkgs/development/python-modules/unicodecsv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # ImportError: No module named runtests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Drop-in replacement for Python2's stdlib csv module, with unicode support";
     homepage = "https://github.com/jdunck/python-unicodecsv";
     maintainers = with maintainers; [ koral ];
diff --git a/pkgs/development/python-modules/unicorn/default.nix b/pkgs/development/python-modules/unicorn/default.nix
index 8bd6507bb5ba0..215a32e3b60f6 100644
--- a/pkgs/development/python-modules/unicorn/default.nix
+++ b/pkgs/development/python-modules/unicorn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, setuptools, unicorn-emu }:
+{ lib, stdenv, buildPythonPackage, setuptools, unicorn-emu }:
 
 buildPythonPackage rec {
   pname = "unicorn";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python bindings for Unicorn CPU emulator engine";
     homepage = "https://www.unicorn-engine.org/";
     license = [ licenses.gpl2 ];
diff --git a/pkgs/development/python-modules/unidecode/default.nix b/pkgs/development/python-modules/unidecode/default.nix
index 0ff066850ddb7..34de3d713866f 100644
--- a/pkgs/development/python-modules/unidecode/default.nix
+++ b/pkgs/development/python-modules/unidecode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, glibcLocales }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, glibcLocales }:
 
 buildPythonPackage rec {
   pname = "Unidecode";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
 
   buildInputs = [ glibcLocales ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/Unidecode/";
     description = "ASCII transliterations of Unicode text";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/unifi/default.nix b/pkgs/development/python-modules/unifi/default.nix
index 4d2eae618c32f..66ab9ba3972b1 100644
--- a/pkgs/development/python-modules/unifi/default.nix
+++ b/pkgs/development/python-modules/unifi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage
+{ lib, stdenv, buildPythonPackage
 , fetchPypi, urllib3 }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # upstream has no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An API towards the Ubiquity Networks UniFi controller";
     homepage    = "https://pypi.python.org/pypi/unifi/";
     license     = licenses.mit;
diff --git a/pkgs/development/python-modules/unittest2/default.nix b/pkgs/development/python-modules/unittest2/default.nix
index 65774d1e33ab0..a7c1252f4b46d 100644
--- a/pkgs/development/python-modules/unittest2/default.nix
+++ b/pkgs/development/python-modules/unittest2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -29,7 +29,7 @@ buildPythonPackage rec {
     sed -i 's/version=VERSION/version=str(VERSION)/' setup.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A backport of the new features added to the unittest testing framework";
     homepage = "https://pypi.python.org/pypi/unittest2";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/unpaddedbase64/default.nix b/pkgs/development/python-modules/unpaddedbase64/default.nix
index 386478cbb752b..52d2a42b4bafe 100644
--- a/pkgs/development/python-modules/unpaddedbase64/default.nix
+++ b/pkgs/development/python-modules/unpaddedbase64/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     sha256 = "0if3fjfxga0bwdq47v77fs9hrcqpmwdxry2i2a7pdqsp95258nxd";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/matrix-org/python-unpaddedbase64";
     description = "Unpadded Base64";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/upass/default.nix b/pkgs/development/python-modules/upass/default.nix
index 2d532be36404f..442876d7a975d 100644
--- a/pkgs/development/python-modules/upass/default.nix
+++ b/pkgs/development/python-modules/upass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchurl
 , pyperclip
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Console UI for pass";
     homepage = "https://github.com/Kwpolska/upass";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/update_checker/default.nix b/pkgs/development/python-modules/update_checker/default.nix
index 6779a50e2c47e..f9171e8cbc9d2 100644
--- a/pkgs/development/python-modules/update_checker/default.nix
+++ b/pkgs/development/python-modules/update_checker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, requests, isPy27
+{ lib, stdenv, buildPythonPackage, fetchPypi, requests, isPy27
 }:
 
 buildPythonPackage rec {
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # requires network
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A python module that will check for package updates";
     homepage = "https://github.com/bboe/update_checker";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/uproot3-methods/default.nix b/pkgs/development/python-modules/uproot3-methods/default.nix
index 3a9457a574baa..5164bf854ada9 100644
--- a/pkgs/development/python-modules/uproot3-methods/default.nix
+++ b/pkgs/development/python-modules/uproot3-methods/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # No tests on PyPi
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/scikit-hep/uproot3-methods";
     description = "Pythonic mix-ins for ROOT classes";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/uptime/default.nix b/pkgs/development/python-modules/uptime/default.nix
index 0e1d10f7ae5e0..8f8c067d36ae1 100644
--- a/pkgs/development/python-modules/uptime/default.nix
+++ b/pkgs/development/python-modules/uptime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0wr9jkixprlywz0plyn5p42a5fd31aiwvjrxdvj7r02vfxa04c3w";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Cairnarvon/uptime";
     description = "Cross-platform way to retrieve system uptime and boot time";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/uranium/default.nix b/pkgs/development/python-modules/uranium/default.nix
index 0bcfa0305e8c3..f5bca2ed0fef5 100644
--- a/pkgs/development/python-modules/uranium/default.nix
+++ b/pkgs/development/python-modules/uranium/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, python, cmake
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, python, cmake
 , pyqt5, numpy, scipy, shapely, libarcus, doxygen, gettext, pythonOlder }:
 
 buildPythonPackage rec {
@@ -27,7 +27,7 @@ buildPythonPackage rec {
      UM/Application.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python framework for building Desktop applications";
     homepage = "https://github.com/Ultimaker/Uranium";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/uritools/default.nix b/pkgs/development/python-modules/uritools/default.nix
index 570fc5dc7180f..b06da7c6acc78 100644
--- a/pkgs/development/python-modules/uritools/default.nix
+++ b/pkgs/development/python-modules/uritools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27 }:
 
 buildPythonPackage rec {
   pname = "uritools";
@@ -10,7 +10,7 @@ buildPythonPackage rec {
     sha256 = "405917a31ce58a57c8ccd0e4ea290f38baf2f4823819c3688f5331f1aee4ccb0";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RFC 3986 compliant, Unicode-aware, scheme-agnostic replacement for urlparse";
     license = licenses.mit;
     maintainers = [ maintainers.rvolosatovs ];
diff --git a/pkgs/development/python-modules/urlgrabber/default.nix b/pkgs/development/python-modules/urlgrabber/default.nix
index 7af69e5ded89e..3a7158be73c8d 100644
--- a/pkgs/development/python-modules/urlgrabber/default.nix
+++ b/pkgs/development/python-modules/urlgrabber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pycurl, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pycurl, six }:
 
 buildPythonPackage rec {
   pname = "urlgrabber";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pycurl six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://urlgrabber.baseurl.org";
     license = licenses.lgpl2Plus;
     description = "Python module for downloading files";
diff --git a/pkgs/development/python-modules/urllib3/default.nix b/pkgs/development/python-modules/urllib3/default.nix
index aafa11720a229..4bf364391744c 100644
--- a/pkgs/development/python-modules/urllib3/default.nix
+++ b/pkgs/development/python-modules/urllib3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, mock, tornado, pyopenssl, cryptography
 , idna, certifi, ipaddress, pysocks }:
 
@@ -25,7 +25,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest mock tornado ];
   propagatedBuildInputs = [ pyopenssl cryptography idna certifi ipaddress pysocks ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful, sanity-friendly HTTP client for Python";
     homepage = "https://github.com/shazow/urllib3";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/urwid/default.nix b/pkgs/development/python-modules/urwid/default.nix
index 0846d801059a8..e3c5311136c27 100644
--- a/pkgs/development/python-modules/urwid/default.nix
+++ b/pkgs/development/python-modules/urwid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy3k, isPy27, glibcLocales }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy3k, isPy27, glibcLocales }:
 
 buildPythonPackage rec {
   pname = "urwid";
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "urwid" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full-featured console (xterm et al.) user interface library";
     homepage = "http://excess.org/urwid";
     repositories.git = "git://github.com/wardi/urwid.git";
diff --git a/pkgs/development/python-modules/urwidtrees/default.nix b/pkgs/development/python-modules/urwidtrees/default.nix
index c441d93f6f769..4c3a3e896f862 100644
--- a/pkgs/development/python-modules/urwidtrees/default.nix
+++ b/pkgs/development/python-modules/urwidtrees/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , glibcLocales
@@ -29,7 +29,7 @@ buildPythonPackage rec {
   checkInputs = [ glibcLocales ];
   LC_ALL="en_US.UTF-8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tree widgets for urwid";
     homepage = "https://github.com/pazz/urwidtrees";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/usbtmc/default.nix b/pkgs/development/python-modules/usbtmc/default.nix
index 34e6025dcfb6c..b1f5b301dee44 100644
--- a/pkgs/development/python-modules/usbtmc/default.nix
+++ b/pkgs/development/python-modules/usbtmc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonPackage, pyusb }:
+{ lib, stdenv, fetchurl, buildPythonPackage, pyusb }:
 
 buildPythonPackage rec {
   pname = "usbtmc";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ pyusb ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python implementation of the USBTMC instrument control protocol";
     homepage = "http://alexforencich.com/wiki/en/python-usbtmc/start";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/user-agents/default.nix b/pkgs/development/python-modules/user-agents/default.nix
index 5fb926607bae4..7f8470cfbdc82 100644
--- a/pkgs/development/python-modules/user-agents/default.nix
+++ b/pkgs/development/python-modules/user-agents/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, ua-parser }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, ua-parser }:
 
 buildPythonPackage rec {
   pname = "user-agents";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ ua-parser ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python library to identify devices by parsing user agent strings";
     homepage = "https://github.com/selwin/python-user-agents";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/validate-email/default.nix b/pkgs/development/python-modules/validate-email/default.nix
index ea2c5a8db7491..327cfcf3f0d32 100644
--- a/pkgs/development/python-modules/validate-email/default.nix
+++ b/pkgs/development/python-modules/validate-email/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "validate-email";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/syrusakbary/validate_email";
     description = "Verify if an email address is valid and really exists";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/python-modules/validictory/default.nix b/pkgs/development/python-modules/validictory/default.nix
index 81e80375e6801..e89b3d7bcd230 100644
--- a/pkgs/development/python-modules/validictory/default.nix
+++ b/pkgs/development/python-modules/validictory/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Validate dicts against a schema";
     homepage = "https://github.com/sunlightlabs/validictory";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/vcversioner/default.nix b/pkgs/development/python-modules/vcversioner/default.nix
index 5f7f30e2c336e..7d73a6e812dde 100644
--- a/pkgs/development/python-modules/vcversioner/default.nix
+++ b/pkgs/development/python-modules/vcversioner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "vcversioner";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "16z10sm78jd7ca3jbkgc3q5i8a8q7y1h21q1li21yy3rlhbhrrns";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "take version numbers from version control";
     homepage = "https://github.com/habnabit/vcversioner";
     license = licenses.isc;
diff --git a/pkgs/development/python-modules/vdf/default.nix b/pkgs/development/python-modules/vdf/default.nix
index 7d4e3e34b86dd..9e4e92d21ae79 100644
--- a/pkgs/development/python-modules/vdf/default.nix
+++ b/pkgs/development/python-modules/vdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , pytest, pytestcov, mock }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   checkInputs = [ pytest pytestcov mock ];
   checkPhase = "make test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library for working with Valve's VDF text format";
     homepage = "https://github.com/ValvePython/vdf";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/vdirsyncer/default.nix b/pkgs/development/python-modules/vdirsyncer/default.nix
index b93050144eb63..bda65ab490767 100644
--- a/pkgs/development/python-modules/vdirsyncer/default.nix
+++ b/pkgs/development/python-modules/vdirsyncer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -58,7 +58,7 @@ buildPythonPackage rec {
     "test_create_collections" # Flaky test exceeds deadline on hydra: https://github.com/pimutils/vdirsyncer/issues/837
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pimutils/vdirsyncer";
     description = "Synchronize calendars and contacts";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/vega/default.nix b/pkgs/development/python-modules/vega/default.nix
index b81481b0774a3..3a36d5de6064a 100644
--- a/pkgs/development/python-modules/vega/default.nix
+++ b/pkgs/development/python-modules/vega/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage , fetchPypi, pythonOlder
+{ lib, stdenv, buildPythonPackage , fetchPypi, pythonOlder
 , pytest, jupyter_core, pandas, ipywidgets, jupyter, altair }:
 
 buildPythonPackage rec {
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   doCheck = false;
   checkInputs = [ altair ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An IPython/Jupyter widget for Vega and Vega-Lite";
     longDescription = ''
       To use this you have to enter a nix-shell with vega. Then run:
diff --git a/pkgs/development/python-modules/venusian/default.nix b/pkgs/development/python-modules/venusian/default.nix
index 06f0d55acf007..68d974aabec80 100644
--- a/pkgs/development/python-modules/venusian/default.nix
+++ b/pkgs/development/python-modules/venusian/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for deferring decorator actions";
     homepage = "https://pylonsproject.org/";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/versioneer/default.nix b/pkgs/development/python-modules/versioneer/default.nix
index 31042c8cc1c4b..fa3329503a36d 100644
--- a/pkgs/development/python-modules/versioneer/default.nix
+++ b/pkgs/development/python-modules/versioneer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27 }:
 
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   # pip.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Version-string management for VCS-controlled trees";
     homepage = "https://github.com/warner/python-versioneer";
     license = licenses.publicDomain;
diff --git a/pkgs/development/python-modules/versiontools/default.nix b/pkgs/development/python-modules/versiontools/default.nix
index ea282c22ddc8e..45b34d95301d5 100644
--- a/pkgs/development/python-modules/versiontools/default.nix
+++ b/pkgs/development/python-modules/versiontools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   doCheck = (!isPy3k);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/versiontools";
     description = "Smart replacement for plain tuple used in __version__";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/veryprettytable/default.nix b/pkgs/development/python-modules/veryprettytable/default.nix
index eff996c3ae4c8..f2c8cee451d3c 100644
--- a/pkgs/development/python-modules/veryprettytable/default.nix
+++ b/pkgs/development/python-modules/veryprettytable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , termcolor
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ termcolor colorama ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple Python library for easily displaying tabular data in a visually appealing ASCII table format";
     homepage = "https://github.com/smeggingsmegger/VeryPrettyTable";
     license = licenses.free;
diff --git a/pkgs/development/python-modules/vidstab/default.nix b/pkgs/development/python-modules/vidstab/default.nix
index f43fe542677b6..548105a01778c 100644
--- a/pkgs/development/python-modules/vidstab/default.nix
+++ b/pkgs/development/python-modules/vidstab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   # tests not packaged with pypi
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AdamSpannbauer/python_video_stab";
     description = "Video Stabilization using OpenCV";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/vine/default.nix b/pkgs/development/python-modules/vine/default.nix
index 1f4933d7dd8a6..048fa435e0bed 100644
--- a/pkgs/development/python-modules/vine/default.nix
+++ b/pkgs/development/python-modules/vine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , case, pytest, pythonOlder }:
 
 buildPythonPackage rec {
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   buildInputs = [ case pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python promises";
     homepage = "https://github.com/celery/vine";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/virtualenv-clone/default.nix b/pkgs/development/python-modules/virtualenv-clone/default.nix
index cc68d4b7090fd..9b225021cf211 100644
--- a/pkgs/development/python-modules/virtualenv-clone/default.nix
+++ b/pkgs/development/python-modules/virtualenv-clone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # needs tox to run the tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/edwardgeorge/virtualenv-clone";
     description = "Script to clone virtualenvs";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/virtualenvwrapper/default.nix b/pkgs/development/python-modules/virtualenvwrapper/default.nix
index 19ec56a1ece8b..658f41126fc92 100644
--- a/pkgs/development/python-modules/virtualenvwrapper/default.nix
+++ b/pkgs/development/python-modules/virtualenvwrapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pbr
@@ -66,7 +66,7 @@ EOF
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enhancements to virtualenv";
     homepage = "https://pypi.python.org/pypi/virtualenvwrapper";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/vmprof/default.nix b/pkgs/development/python-modules/vmprof/default.nix
index 149efb753e20c..f8be722ef90f9 100644
--- a/pkgs/development/python-modules/vmprof/default.nix
+++ b/pkgs/development/python-modules/vmprof/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , colorama
@@ -24,7 +24,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "vmprof" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A vmprof client";
     license = licenses.mit;
     homepage = "https://vmprof.readthedocs.org/";
diff --git a/pkgs/development/python-modules/vncdo/default.nix b/pkgs/development/python-modules/vncdo/default.nix
index ffc01906f459d..cb1b1677e1b56 100644
--- a/pkgs/development/python-modules/vncdo/default.nix
+++ b/pkgs/development/python-modules/vncdo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , buildPythonPackage, isPy27
 , pillow
 , twisted
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   doCheck = !isPy27;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sibson/vncdotool";
     description = "A command line VNC client and python library";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/voluptuous-serialize/default.nix b/pkgs/development/python-modules/voluptuous-serialize/default.nix
index 383eed03a4e3b..d054a32c30e0e 100644
--- a/pkgs/development/python-modules/voluptuous-serialize/default.nix
+++ b/pkgs/development/python-modules/voluptuous-serialize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, isPy3k, fetchPypi, voluptuous, pytest }:
+{ lib, stdenv, buildPythonPackage, isPy3k, fetchPypi, voluptuous, pytest }:
 
 buildPythonPackage rec  {
   pname = "voluptuous-serialize";
@@ -26,7 +26,7 @@ buildPythonPackage rec  {
   # no tests in PyPI tarball
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/balloob/voluptuous-serialize";
     license = licenses.asl20;
     description = "Convert Voluptuous schemas to dictionaries so they can be serialized";
diff --git a/pkgs/development/python-modules/voluptuous/default.nix b/pkgs/development/python-modules/voluptuous/default.nix
index 7c5c99a0bec4c..63be8cd4bd051 100644
--- a/pkgs/development/python-modules/voluptuous/default.nix
+++ b/pkgs/development/python-modules/voluptuous/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, nose }:
 
 buildPythonPackage rec {
   pname = "voluptuous";
@@ -14,7 +14,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Voluptuous is a Python data validation library";
     homepage = "http://alecthomas.github.io/voluptuous/";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/vultr/default.nix b/pkgs/development/python-modules/vultr/default.nix
index 236e4121cf865..d4349d310be2d 100644
--- a/pkgs/development/python-modules/vultr/default.nix
+++ b/pkgs/development/python-modules/vultr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , requests
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # Tests disabled. They fail because they try to access the network
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Vultr.com API Client";
     homepage = "https://github.com/spry-group/python-vultr";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/vulture/default.nix b/pkgs/development/python-modules/vulture/default.nix
index 76f379ef84493..b657d26c706f6 100644
--- a/pkgs/development/python-modules/vulture/default.nix
+++ b/pkgs/development/python-modules/vulture/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, isPy27, coverage, pytest, pytestcov }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, isPy27, coverage, pytest, pytestcov }:
 
 buildPythonPackage rec {
   pname = "vulture";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   checkInputs = [ coverage pytest pytestcov ];
   checkPhase = "pytest";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Finds unused code in Python programs";
     homepage = "https://github.com/jendrikseipp/vulture";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/vxi11/default.nix b/pkgs/development/python-modules/vxi11/default.nix
index 15a9d7073abc4..5d9531aa904d9 100644
--- a/pkgs/development/python-modules/vxi11/default.nix
+++ b/pkgs/development/python-modules/vxi11/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, nose }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, nose }:
 
 buildPythonPackage rec {
   pname = "python-vxi11";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VXI-11 driver for controlling instruments over Ethernet";
     homepage = "https://github.com/python-ivi/python-vxi11";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/w3lib/default.nix b/pkgs/development/python-modules/w3lib/default.nix
index a37f786c018d9..ae404e01cfb9f 100644
--- a/pkgs/development/python-modules/w3lib/default.nix
+++ b/pkgs/development/python-modules/w3lib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   buildInputs = [ six pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library of web-related functions";
     homepage = "https://github.com/scrapy/w3lib";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/waitress/default.nix b/pkgs/development/python-modules/waitress/default.nix
index 3812ed06b60c7..09f4f66e0b522 100644
--- a/pkgs/development/python-modules/waitress/default.nix
+++ b/pkgs/development/python-modules/waitress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -14,7 +14,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
      homepage = "https://github.com/Pylons/waitress";
      description = "Waitress WSGI server";
      license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/wakeonlan/default.nix b/pkgs/development/python-modules/wakeonlan/default.nix
index dd947c0555ce3..29c30e7ba6ada 100644
--- a/pkgs/development/python-modules/wakeonlan/default.nix
+++ b/pkgs/development/python-modules/wakeonlan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, setuptools_scm, pytest, mock }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, setuptools_scm, pytest, mock }:
 
 buildPythonPackage rec {
   pname = "wakeonlan";
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     py.test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small python module for wake on lan";
     homepage = "https://github.com/remcohaszing/pywakeonlan";
     license = licenses.wtfpl;
diff --git a/pkgs/development/python-modules/warlock/default.nix b/pkgs/development/python-modules/warlock/default.nix
index 34815f99a94c5..80dcabdcb2075 100644
--- a/pkgs/development/python-modules/warlock/default.nix
+++ b/pkgs/development/python-modules/warlock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six jsonpatch jsonschema jsonpointer ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bcwaldon/warlock";
     description = "Python object model built on JSON schema and JSON patch";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/wasabi/default.nix b/pkgs/development/python-modules/wasabi/default.nix
index ec9cbb3d5608c..5a0c2ecaa5f55 100644
--- a/pkgs/development/python-modules/wasabi/default.nix
+++ b/pkgs/development/python-modules/wasabi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytestCheckHook
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight console printing and formatting toolkit";
     homepage = "https://github.com/ines/wasabi";
     changelog = "https://github.com/ines/wasabi/releases/tag/v${version}";
diff --git a/pkgs/development/python-modules/watchdog/default.nix b/pkgs/development/python-modules/watchdog/default.nix
index ffec68785260b..893cdd7e99b4a 100644
--- a/pkgs/development/python-modules/watchdog/default.nix
+++ b/pkgs/development/python-modules/watchdog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , argh
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python API and shell utilities to monitor file system events";
     homepage = "https://github.com/gorakhargosh/watchdog";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/weasyprint/default.nix b/pkgs/development/python-modules/weasyprint/default.nix
index 06f7a9f1011b3..a7188a3103f4b 100644
--- a/pkgs/development/python-modules/weasyprint/default.nix
+++ b/pkgs/development/python-modules/weasyprint/default.nix
@@ -11,7 +11,7 @@
   glib,
   pango,
   fontconfig,
-  stdenv,
+  lib, stdenv,
   pytest,
   pytestrunner,
   pytest-isort,
@@ -62,7 +62,7 @@ buildPythonPackage rec {
     sha256 = "0rwf43111ws74m8b1alkkxzz57g0np3vmd8as74adwnxslfcg4gs";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://weasyprint.org/";
     description = "Converts web documents to PDF";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/web/default.nix b/pkgs/development/python-modules/web/default.nix
index ab91d80b8c7b8..84b4cc8dcfbb4 100644
--- a/pkgs/development/python-modules/web/default.nix
+++ b/pkgs/development/python-modules/web/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytestCheckHook
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytestCheckHook
 , cheroot
 , dbutils, mysqlclient, pymysql, mysql-connector, psycopg2
 }:
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   checkInputs = [ pytestCheckHook dbutils mysqlclient pymysql mysql-connector psycopg2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Makes web apps";
     longDescription = ''
       Think about the ideal way to write a web app.
diff --git a/pkgs/development/python-modules/webapp2/default.nix b/pkgs/development/python-modules/webapp2/default.nix
index 01c1ca309d4c2..048c5d91b1d2a 100644
--- a/pkgs/development/python-modules/webapp2/default.nix
+++ b/pkgs/development/python-modules/webapp2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , webob
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ webob six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Taking Google App Engine's webapp to the next level";
     homepage = "http://webapp-improved.appspot.com";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/webhelpers/default.nix b/pkgs/development/python-modules/webhelpers/default.nix
index d88f8210ae1dc..040341ed376a0 100644
--- a/pkgs/development/python-modules/webhelpers/default.nix
+++ b/pkgs/development/python-modules/webhelpers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , routes
@@ -21,7 +21,7 @@ buildPythonPackage rec {
   # TODO: failing tests https://bitbucket.org/bbangert/webhelpers/pull-request/1/fix-error-on-webob-123/diff
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://webhelpers.readthedocs.org/en/latest/";
     description = "Web Helpers";
     license = licenses.free;
diff --git a/pkgs/development/python-modules/webob/default.nix b/pkgs/development/python-modules/webob/default.nix
index 17b20ecd34dda..78ca8f918a3f4 100644
--- a/pkgs/development/python-modules/webob/default.nix
+++ b/pkgs/development/python-modules/webob/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , nose
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ nose pytest ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WSGI request and response object";
     homepage = "http://pythonpaste.org/webob/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/websockify/default.nix b/pkgs/development/python-modules/websockify/default.nix
index e885a1ba9b724..021344b2207ab 100644
--- a/pkgs/development/python-modules/websockify/default.nix
+++ b/pkgs/development/python-modules/websockify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , numpy
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ numpy ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WebSockets support for any application/server";
     homepage = "https://github.com/kanaka/websockify";
     license = licenses.lgpl3;
diff --git a/pkgs/development/python-modules/webtest/default.nix b/pkgs/development/python-modules/webtest/default.nix
index 48acb6c881de8..98ee58d3f6c40 100644
--- a/pkgs/development/python-modules/webtest/default.nix
+++ b/pkgs/development/python-modules/webtest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy27
@@ -35,7 +35,7 @@ buildPythonPackage rec {
   # Some of the tests use localhost networking.
   __darwinAllowLocalNetworking = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Helper to test WSGI applications";
     homepage = "https://webtest.readthedocs.org/en/latest/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/werkzeug/default.nix b/pkgs/development/python-modules/werkzeug/default.nix
index fd634e51796ec..858130b805f1f 100644
--- a/pkgs/development/python-modules/werkzeug/default.nix
+++ b/pkgs/development/python-modules/werkzeug/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , itsdangerous, hypothesis
 , pytestCheckHook, requests
 , pytest-timeout
@@ -21,7 +21,7 @@ buildPythonPackage rec {
     "test_get_machine_id"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://palletsprojects.com/p/werkzeug/";
     description = "A WSGI utility library for Python";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/whisper/default.nix b/pkgs/development/python-modules/whisper/default.nix
index 70709d3e6663a..ad25df4868a4d 100644
--- a/pkgs/development/python-modules/whisper/default.nix
+++ b/pkgs/development/python-modules/whisper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, mock, six }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, mock, six }:
 
 buildPythonPackage rec {
   pname = "whisper";
@@ -12,7 +12,7 @@ buildPythonPackage rec {
   propagatedBuildInputs = [ six ];
   checkInputs = [ mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://graphite.wikidot.com/";
     description = "Fixed size round-robin style database";
     maintainers = with maintainers; [ offline basvandijk ];
diff --git a/pkgs/development/python-modules/whitenoise/default.nix b/pkgs/development/python-modules/whitenoise/default.nix
index dbc069f434e4a..2399c6ed73f22 100644
--- a/pkgs/development/python-modules/whitenoise/default.nix
+++ b/pkgs/development/python-modules/whitenoise/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, isPy27 }:
+{ lib, stdenv, fetchPypi, buildPythonPackage, isPy27 }:
 
 buildPythonPackage rec {
   pname = "whitenoise";
@@ -13,7 +13,7 @@ buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Radically simplified static file serving for WSGI applications";
     homepage = "http://whitenoise.evans.io/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/whoosh/default.nix b/pkgs/development/python-modules/whoosh/default.nix
index e203cdb293441..f5bbccec2a5e3 100644
--- a/pkgs/development/python-modules/whoosh/default.nix
+++ b/pkgs/development/python-modules/whoosh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest }:
 
 buildPythonPackage rec {
   pname = "Whoosh";
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     py.test -k "not test_timelimit and not test_minimize_dfa"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, pure-Python full text indexing, search, and spell
 checking library.";
     homepage    = "https://bitbucket.org/mchaput/whoosh";
diff --git a/pkgs/development/python-modules/willow/default.nix b/pkgs/development/python-modules/willow/default.nix
index e9e5001fec91c..fbf4965117b3c 100644
--- a/pkgs/development/python-modules/willow/default.nix
+++ b/pkgs/development/python-modules/willow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pythonOlder
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # https://github.com/torchbox/Willow/issues/34
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python image library that sits on top of Pillow, Wand and OpenCV";
     homepage = "https://github.com/torchbox/Willow/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/word2vec/default.nix b/pkgs/development/python-modules/word2vec/default.nix
index 1e448c377096a..647914bfbe5f8 100644
--- a/pkgs/development/python-modules/word2vec/default.nix
+++ b/pkgs/development/python-modules/word2vec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , fetchzip
@@ -43,7 +43,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for computing continuous distributed representations of words";
     homepage = "https://github.com/danielfrg/word2vec";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/wordcloud/default.nix b/pkgs/development/python-modules/wordcloud/default.nix
index 6ed44c1e0c206..b4dd108ae739e 100644
--- a/pkgs/development/python-modules/wordcloud/default.nix
+++ b/pkgs/development/python-modules/wordcloud/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub
 , matplotlib
 , mock
 , numpy
@@ -39,7 +39,7 @@ buildPythonPackage rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A little word cloud generator in Python";
     homepage = "https://github.com/amueller/word_cloud";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/worldengine/default.nix b/pkgs/development/python-modules/worldengine/default.nix
index dafa948f69d83..fb7326c81d5bc 100644
--- a/pkgs/development/python-modules/worldengine/default.nix
+++ b/pkgs/development/python-modules/worldengine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , pythonOlder
 , isPy27
@@ -55,7 +55,7 @@ buildPythonPackage rec {
     nosetests tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://world-engine.org";
     description = "World generator using simulation of plates, rain shadow, erosion, etc";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/wrapio/default.nix b/pkgs/development/python-modules/wrapio/default.nix
index 4289c20207274..757585bd14556 100644
--- a/pkgs/development/python-modules/wrapio/default.nix
+++ b/pkgs/development/python-modules/wrapio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "wrapio" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Exahilosys/wrapio";
     description = "Handling event-based streams";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/ws4py/default.nix b/pkgs/development/python-modules/ws4py/default.nix
index 83e1fbad3233c..2b7a66df285c0 100644
--- a/pkgs/development/python-modules/ws4py/default.nix
+++ b/pkgs/development/python-modules/ws4py/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, pytest, mock, git
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, mock, git
 , cherrypy, gevent, tornado }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ws4py.readthedocs.org";
     description = "A WebSocket package for Python";
     maintainers = [];
diff --git a/pkgs/development/python-modules/wsgiproxy/default.nix b/pkgs/development/python-modules/wsgiproxy/default.nix
index 8ae8b4aefa541..12aa3c88d9680 100644
--- a/pkgs/development/python-modules/wsgiproxy/default.nix
+++ b/pkgs/development/python-modules/wsgiproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , paste
@@ -18,7 +18,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ paste six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WSGIProxy gives tools to proxy arbitrary(ish) WSGI requests to other";
     homepage = "http://pythonpaste.org/wsgiproxy/";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/wsgiproxy2/default.nix b/pkgs/development/python-modules/wsgiproxy2/default.nix
index ef3ce69742c12..81a2f98b86f85 100644
--- a/pkgs/development/python-modules/wsgiproxy2/default.nix
+++ b/pkgs/development/python-modules/wsgiproxy2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -20,7 +20,7 @@ buildPythonPackage rec {
   # circular dep on webtest
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pythonpaste.org/wsgiproxy/";
     description = "HTTP proxying tools for WSGI apps";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/wtforms/default.nix b/pkgs/development/python-modules/wtforms/default.nix
index 66667c74ef3dc..45c465ddcba70 100644
--- a/pkgs/development/python-modules/wtforms/default.nix
+++ b/pkgs/development/python-modules/wtforms/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , markupsafe
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # Django tests are broken "django.core.exceptions.AppRegistryNotReady: Apps aren't loaded yet."
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A flexible forms validation and rendering library for Python";
     homepage = "https://github.com/wtforms/wtforms";
     changelog = "https://github.com/wtforms/wtforms/blob/${version}/CHANGES.rst";
diff --git a/pkgs/development/python-modules/x11_hash/default.nix b/pkgs/development/python-modules/x11_hash/default.nix
index 22ce5917e2a61..21bb787402c15 100644
--- a/pkgs/development/python-modules/x11_hash/default.nix
+++ b/pkgs/development/python-modules/x11_hash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "172skm9xbbrivy1p4xabxihx9lsnzi53hvzryfw64m799k2fmp22";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Binding for X11 proof of work hashing";
     homepage = "https://github.com/mazaclub/x11_hash";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/x256/default.nix b/pkgs/development/python-modules/x256/default.nix
index bc0f0f6579089..4ceb2dcae791d 100644
--- a/pkgs/development/python-modules/x256/default.nix
+++ b/pkgs/development/python-modules/x256/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 }:
 
 buildPythonPackage rec {
@@ -12,7 +12,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Find the nearest xterm 256 color index for an RGB";
     homepage = "https://github.com/magarcia/python-x256";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/xapp/default.nix b/pkgs/development/python-modules/xapp/default.nix
index de779fc2c00ba..28901017b2b57 100644
--- a/pkgs/development/python-modules/xapp/default.nix
+++ b/pkgs/development/python-modules/xapp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , psutil
@@ -33,7 +33,7 @@ buildPythonPackage rec {
     substituteInPlace "xapp/os.py" --replace "/usr/bin/pkexec" "${polkit}/bin/pkexec"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/linuxmint/python-xapp";
     description = "Cross-desktop libraries and common resources for python";
     license = licenses.lgpl2;
diff --git a/pkgs/development/python-modules/xattr/default.nix b/pkgs/development/python-modules/xattr/default.nix
index 8634d616b736b..3583358a5605f 100644
--- a/pkgs/development/python-modules/xattr/default.nix
+++ b/pkgs/development/python-modules/xattr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m compileall -f xattr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/xattr/xattr";
     description = "Python wrapper for extended filesystem attributes";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/xcaplib/default.nix b/pkgs/development/python-modules/xcaplib/default.nix
index 25061d5321abf..f6bb5712c2eb1 100644
--- a/pkgs/development/python-modules/xcaplib/default.nix
+++ b/pkgs/development/python-modules/xcaplib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchdarcs
 , isPy3k
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ eventlib application ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AGProjects/python-xcaplib";
     description = "XCAP (RFC4825) client library";
     license = licenses.gpl2;
diff --git a/pkgs/development/python-modules/xcffib/default.nix b/pkgs/development/python-modules/xcffib/default.nix
index b75179bdc2a4e..33431684708b4 100644
--- a/pkgs/development/python-modules/xcffib/default.nix
+++ b/pkgs/development/python-modules/xcffib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , xorg
@@ -27,7 +27,7 @@ buildPythonPackage rec {
 
   pythonImportsCheck = [ "xcffib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A drop in replacement for xpyb, an XCB python binding";
     homepage = "https://github.com/tych0/xcffib";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/xhtml2pdf/default.nix b/pkgs/development/python-modules/xhtml2pdf/default.nix
index 88143b2193f45..e3328c7e4534f 100644
--- a/pkgs/development/python-modules/xhtml2pdf/default.nix
+++ b/pkgs/development/python-modules/xhtml2pdf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pillow
@@ -25,7 +25,7 @@ buildPythonPackage rec {
     sha256 = "6797e974fac66f0efbe927c1539a2756ca4fe8777eaa5882bac132fc76b39421";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PDF generator using HTML and CSS";
     homepage = "https://github.com/xhtml2pdf/xhtml2pdf";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/xkcdpass/default.nix b/pkgs/development/python-modules/xkcdpass/default.nix
index 8cb5b5f0777aa..88f7b9b94a1f2 100644
--- a/pkgs/development/python-modules/xkcdpass/default.nix
+++ b/pkgs/development/python-modules/xkcdpass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -16,7 +16,7 @@ buildPythonPackage rec {
   # https://github.com/redacted/XKCD-password-generator/issues/32
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/xkcdpass/";
     description = "Generate secure multiword passwords/passphrases, inspired by XKCD";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/xlib/default.nix b/pkgs/development/python-modules/xlib/default.nix
index 30a30232088e6..1819fd5a51240 100644
--- a/pkgs/development/python-modules/xlib/default.nix
+++ b/pkgs/development/python-modules/xlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , six
@@ -32,7 +32,7 @@ buildPythonPackage rec {
 
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fully functional X client library for Python programs";
     homepage = "http://python-xlib.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/python-modules/xlrd/default.nix b/pkgs/development/python-modules/xlrd/default.nix
index 9b5e8b83e3066..031ac047936eb 100644
--- a/pkgs/development/python-modules/xlrd/default.nix
+++ b/pkgs/development/python-modules/xlrd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , pytest
@@ -19,7 +19,7 @@ buildPythonPackage rec {
     py.test -k "not test_tilde_path_expansion"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.python-excel.org/";
     description = "Library for developers to extract data from Microsoft Excel (tm) spreadsheet files";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/xlsx2csv/default.nix b/pkgs/development/python-modules/xlsx2csv/default.nix
index 1c42b1b178451..a5b67632d836b 100644
--- a/pkgs/development/python-modules/xlsx2csv/default.nix
+++ b/pkgs/development/python-modules/xlsx2csv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "09vigknmz15izirfddkmb3a39h1rp2jmc00bnrff12i757n7jjl4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bitprophet/alabaster";
     description = "Convert xlsx to csv";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/xml2rfc/default.nix b/pkgs/development/python-modules/xml2rfc/default.nix
index 1a1ac6fc6d247..e06daf3c5b86a 100644
--- a/pkgs/development/python-modules/xml2rfc/default.nix
+++ b/pkgs/development/python-modules/xml2rfc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchPypi, buildPythonPackage, pythonAtLeast, intervaltree, pyflakes, requests, lxml, google-i18n-address
+{ lib, stdenv, fetchPypi, buildPythonPackage, pythonAtLeast, intervaltree, pyflakes, requests, lxml, google-i18n-address
 , pycountry, html5lib, six, kitchen, pypdf2, dict2xml, weasyprint, pyyaml, jinja2, ConfigArgParse, appdirs
 }:
 
@@ -39,7 +39,7 @@ buildPythonPackage rec {
   doCheck = false;
   pythonImportsCheck = [ "xml2rfc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool generating IETF RFCs and drafts from XML sources";
     homepage = "https://tools.ietf.org/tools/xml2rfc/trac/";
     # Well, parts might be considered unfree, if being strict; see:
diff --git a/pkgs/development/python-modules/xmodem/default.nix b/pkgs/development/python-modules/xmodem/default.nix
index 7e0a25709fb46..9023c4cc79eee 100644
--- a/pkgs/development/python-modules/xmodem/default.nix
+++ b/pkgs/development/python-modules/xmodem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pytest, which, lrzsz }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pytest, which, lrzsz }:
 
 buildPythonPackage rec {
   pname = "xmodem";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pure python implementation of the XMODEM protocol";
     maintainers = with maintainers; [ emantor ];
     homepage = "https://github.com/tehmaze/xmodem";
diff --git a/pkgs/development/python-modules/xmpppy/default.nix b/pkgs/development/python-modules/xmpppy/default.nix
index b812609a7d7bd..fd046adadd97f 100644
--- a/pkgs/development/python-modules/xmpppy/default.nix
+++ b/pkgs/development/python-modules/xmpppy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchurl, isPy3k }:
+{ lib, stdenv, buildPythonPackage, fetchurl, isPy3k }:
 buildPythonPackage rec {
   pname = "xmpp.py";
   version = "0.5.0rc1";
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   disabled = isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XMPP python library";
     homepage = "http://xmpppy.sourceforge.net/";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/xvfbwrapper/default.nix b/pkgs/development/python-modules/xvfbwrapper/default.nix
index dacb3b6343688..0852fd2e15cfc 100644
--- a/pkgs/development/python-modules/xvfbwrapper/default.nix
+++ b/pkgs/development/python-modules/xvfbwrapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , xorgserver
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   checkInputs = [ mock ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Run headless display inside X virtual framebuffer (Xvfb)";
     homepage = "https://github.com/cgoldberg/xvfbwrapper";
     license = licenses.mit;
diff --git a/pkgs/development/python-modules/xxhash/default.nix b/pkgs/development/python-modules/xxhash/default.nix
index 52b3f8b1b5b57..d2f6ae54a4cfb 100644
--- a/pkgs/development/python-modules/xxhash/default.nix
+++ b/pkgs/development/python-modules/xxhash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "58ca818554c1476fa1456f6cd4b87002e2294f09baf0f81e5a2a4968e62c423c";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ifduyue/python-xxhash";
     description = "Python Binding for xxHash https://pypi.org/project/xxhash/";
     license = licenses.bsd2;
diff --git a/pkgs/development/python-modules/yamllint/default.nix b/pkgs/development/python-modules/yamllint/default.nix
index f0407dff17351..7145c504cd923 100644
--- a/pkgs/development/python-modules/yamllint/default.nix
+++ b/pkgs/development/python-modules/yamllint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , nose, pyyaml, pathspec }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   # Two test failures
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A linter for YAML files";
     homepage = "https://github.com/adrienverge/yamllint";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/yanc/default.nix b/pkgs/development/python-modules/yanc/default.nix
index 9bbfc41006820..6d4a3b41fbccb 100644
--- a/pkgs/development/python-modules/yanc/default.nix
+++ b/pkgs/development/python-modules/yanc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, pythonOlder, fetchPypi, nose }:
+{ lib, stdenv, buildPythonPackage, pythonOlder, fetchPypi, nose }:
 
 buildPythonPackage rec {
   pname = "yanc";
@@ -18,7 +18,7 @@ buildPythonPackage rec {
     nosetests .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Yet another nose colorer";
     homepage = "https://github.com/0compute/yanc";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/yapf/default.nix b/pkgs/development/python-modules/yapf/default.nix
index 65a4e9abcb298..36409ae40195d 100644
--- a/pkgs/development/python-modules/yapf/default.nix
+++ b/pkgs/development/python-modules/yapf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "yapf";
@@ -9,7 +9,7 @@ buildPythonPackage rec {
     sha256 = "3000abee4c28daebad55da6c85f3cd07b8062ce48e2e9943c8da1b9667d48427";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A formatter for Python code.";
     homepage    = "https://github.com/google/yapf";
     license     = licenses.asl20;
diff --git a/pkgs/development/python-modules/yapsy/default.nix b/pkgs/development/python-modules/yapsy/default.nix
index f0d39f69e5558..359a855a3e5fe 100644
--- a/pkgs/development/python-modules/yapsy/default.nix
+++ b/pkgs/development/python-modules/yapsy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "12rznbnswfw0w7qfbvmmffr9r317gl1rqg36nijwzsklkjgks4fq";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://yapsy.sourceforge.net/";
     description = "Yet another plugin system";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/yarl/default.nix b/pkgs/development/python-modules/yarl/default.nix
index 7a15907e59be3..7a88b695f639d 100644
--- a/pkgs/development/python-modules/yarl/default.nix
+++ b/pkgs/development/python-modules/yarl/default.nix
@@ -25,7 +25,7 @@ buildPythonPackage rec {
       typing-extensions
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Yet another URL library";
     homepage = "https://github.com/aio-libs/yarl/";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/ydiff/default.nix b/pkgs/development/python-modules/ydiff/default.nix
index 3b9cf6530a659..89b063f84be71 100644
--- a/pkgs/development/python-modules/ydiff/default.nix
+++ b/pkgs/development/python-modules/ydiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi }:
+{ lib, stdenv, buildPythonPackage, fetchPypi }:
 
 buildPythonPackage rec {
   pname = "ydiff";
@@ -15,7 +15,7 @@ buildPythonPackage rec {
     $out/bin/ydiff --help
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "View colored, incremental diff in workspace or from stdin with side by side and auto pager support (Was \"cdiff\")";
     longDescription = ''
       Term based tool to view colored, incremental diff in a Git/Mercurial/Svn
diff --git a/pkgs/development/python-modules/yowsup/default.nix b/pkgs/development/python-modules/yowsup/default.nix
index c1f6b6632aab0..48c21434194f0 100644
--- a/pkgs/development/python-modules/yowsup/default.nix
+++ b/pkgs/development/python-modules/yowsup/default.nix
@@ -1,4 +1,4 @@
-{ buildPythonPackage, stdenv, fetchFromGitHub, six, python-axolotl, pytest
+{ buildPythonPackage, lib, stdenv, fetchFromGitHub, six, python-axolotl, pytest
 , isPy3k, consonance, appdirs
 }:
 
@@ -26,7 +26,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ six python-axolotl consonance appdirs ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tgalal/yowsup";
     description = "The python WhatsApp library";
     license = licenses.gpl3;
diff --git a/pkgs/development/python-modules/z3c-checkversions/default.nix b/pkgs/development/python-modules/z3c-checkversions/default.nix
index f4f42cf9e3fcd..f1af120d56eb6 100644
--- a/pkgs/development/python-modules/z3c-checkversions/default.nix
+++ b/pkgs/development/python-modules/z3c-checkversions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , python
@@ -23,7 +23,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m zope.testrunner --test-path=src []
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/z3c.checkversions";
     description = "Find newer package versions on PyPI";
     license = licenses.zpl21;
diff --git a/pkgs/development/python-modules/zake/default.nix b/pkgs/development/python-modules/zake/default.nix
index 8eafaafadf587..1d1d21a462ec5 100644
--- a/pkgs/development/python-modules/zake/default.nix
+++ b/pkgs/development/python-modules/zake/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , kazoo
@@ -26,7 +26,7 @@ buildPythonPackage rec {
     ${python.interpreter} -m unittest discover zake/tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/yahoo/Zake";
     description = "A python package that works to provide a nice set of testing utilities for the kazoo library";
     license = licenses.asl20;
diff --git a/pkgs/development/python-modules/zbaemon/default.nix b/pkgs/development/python-modules/zbaemon/default.nix
index a87bd3093f4f8..4e126074b184a 100644
--- a/pkgs/development/python-modules/zbaemon/default.nix
+++ b/pkgs/development/python-modules/zbaemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zconfig
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # too many deps..
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon process control library and tools for Unix-based systems";
     homepage = "https://pypi.python.org/pypi/zdaemon";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zbase32/default.nix b/pkgs/development/python-modules/zbase32/default.nix
index 9c97ad066ed5f..a4e7a476becae 100644
--- a/pkgs/development/python-modules/zbase32/default.nix
+++ b/pkgs/development/python-modules/zbase32/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptoolsDarcs
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ setuptoolsDarcs pyutil ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "zbase32, a base32 encoder/decoder";
     homepage = "https://pypi.python.org/pypi/zbase32";
     license = licenses.bsd0;
diff --git a/pkgs/development/python-modules/zc_lockfile/default.nix b/pkgs/development/python-modules/zc_lockfile/default.nix
index 18fc7bcf51150..3b75de3a24b6b 100644
--- a/pkgs/development/python-modules/zc_lockfile/default.nix
+++ b/pkgs/development/python-modules/zc_lockfile/default.nix
@@ -2,7 +2,7 @@
 , fetchPypi
 , mock
 , zope_testing
-, stdenv
+, lib, stdenv
 }:
 
 buildPythonPackage rec {
@@ -17,7 +17,7 @@ buildPythonPackage rec {
   buildInputs = [ mock ];
   propagatedBuildInputs = [ zope_testing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Inter-process locks";
     homepage =  "https://www.python.org/pypi/zc.lockfile";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zconfig/default.nix b/pkgs/development/python-modules/zconfig/default.nix
index ef4754504dd66..4882f92b0475a 100644
--- a/pkgs/development/python-modules/zconfig/default.nix
+++ b/pkgs/development/python-modules/zconfig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , fetchpatch
 , buildPythonPackage
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   buildInputs = [ manuel docutils ];
   propagatedBuildInputs = [ zope_testrunner ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Structured Configuration Library";
     homepage = "https://pypi.python.org/pypi/ZConfig";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zdaemon/default.nix b/pkgs/development/python-modules/zdaemon/default.nix
index a87bd3093f4f8..4e126074b184a 100644
--- a/pkgs/development/python-modules/zdaemon/default.nix
+++ b/pkgs/development/python-modules/zdaemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zconfig
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # too many deps..
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon process control library and tools for Unix-based systems";
     homepage = "https://pypi.python.org/pypi/zdaemon";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zerobin/default.nix b/pkgs/development/python-modules/zerobin/default.nix
index efc2bb380b8ec..e120887566862 100644
--- a/pkgs/development/python-modules/zerobin/default.nix
+++ b/pkgs/development/python-modules/zerobin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchFromGitHub
 , cherrypy
@@ -24,7 +24,7 @@ buildPythonPackage {
   # can wrongly fail the check phase.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A client side encrypted pastebin";
     homepage = "https://0bin.net/";
     license = licenses.wtfpl;
diff --git a/pkgs/development/python-modules/zeroc-ice/default.nix b/pkgs/development/python-modules/zeroc-ice/default.nix
index 16bf5b7855c57..f85674d68673b 100644
--- a/pkgs/development/python-modules/zeroc-ice/default.nix
+++ b/pkgs/development/python-modules/zeroc-ice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi, openssl, bzip2 }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, openssl, bzip2 }:
 
 buildPythonPackage rec {
   pname = "zeroc-ice";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
 
   buildInputs = [ openssl bzip2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zeroc.com/";
     license = licenses.gpl2;
     description = "Comprehensive RPC framework with support for Python, C++, .NET, Java, JavaScript and more.";
diff --git a/pkgs/development/python-modules/zfec/default.nix b/pkgs/development/python-modules/zfec/default.nix
index b365438a1c970..8a5aaf46b0e45 100644
--- a/pkgs/development/python-modules/zfec/default.nix
+++ b/pkgs/development/python-modules/zfec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , setuptoolsDarcs
@@ -22,7 +22,7 @@ buildPythonPackage rec {
     sed -i -e '/argparse/d' setup.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://allmydata.org/trac/zfec";
     description = "Zfec, a fast erasure codec which can be used with the command-line, C, Python, or Haskell";
     longDescription = ''
diff --git a/pkgs/development/python-modules/zict/default.nix b/pkgs/development/python-modules/zict/default.nix
index c5629a6fb73f2..da36c1cba899e 100644
--- a/pkgs/development/python-modules/zict/default.nix
+++ b/pkgs/development/python-modules/zict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchPypi
+{ lib, stdenv, buildPythonPackage, fetchPypi
 , pytest, heapdict, pythonOlder }:
 
 buildPythonPackage rec {
@@ -15,7 +15,7 @@ buildPythonPackage rec {
   buildInputs = [ pytest ];
   propagatedBuildInputs = [ heapdict ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mutable mapping tools.";
     homepage = "https://github.com/dask/zict";
     license = licenses.bsd3;
diff --git a/pkgs/development/python-modules/zigpy-znp/default.nix b/pkgs/development/python-modules/zigpy-znp/default.nix
index 01b3e9c6137a5..4de49cbc46b31 100644
--- a/pkgs/development/python-modules/zigpy-znp/default.nix
+++ b/pkgs/development/python-modules/zigpy-znp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , async-timeout
 , asynctest
 , buildPythonPackage
@@ -50,7 +50,7 @@ buildPythonPackage rec {
     "test_force_remove"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for zigpy which communicates with TI ZNP radios";
     homepage = "https://github.com/zha-ng/zigpy-znp";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/python-modules/zodb/default.nix b/pkgs/development/python-modules/zodb/default.nix
index e8097461d3b19..d48b9c4b95078 100644
--- a/pkgs/development/python-modules/zodb/default.nix
+++ b/pkgs/development/python-modules/zodb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchPypi
 , buildPythonPackage
 , python
@@ -52,7 +52,7 @@ buildPythonPackage rec {
       ${python.interpreter} -m zope.testrunner --test-path=src []
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Zope Object Database: object database and persistence";
       homepage = "https://pypi.python.org/pypi/ZODB";
       license = licenses.zpl21;
diff --git a/pkgs/development/python-modules/zope_broken/default.nix b/pkgs/development/python-modules/zope_broken/default.nix
index aa12167bddc2f..899d7f3344be5 100644
--- a/pkgs/development/python-modules/zope_broken/default.nix
+++ b/pkgs/development/python-modules/zope_broken/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_interface
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   buildInputs = [ zope_interface ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pypi.python.org/pypi/zope.broken";
     description = "Zope Broken Object Interfaces";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_component/default.nix b/pkgs/development/python-modules/zope_component/default.nix
index df0835841bced..6ea86b9b984d4 100644
--- a/pkgs/development/python-modules/zope_component/default.nix
+++ b/pkgs/development/python-modules/zope_component/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope-deferredimport
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   # ignore tests because of a circular dependency on zope_security
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.component";
     description = "Zope Component Architecture";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_configuration/default.nix b/pkgs/development/python-modules/zope_configuration/default.nix
index 587cbf60d88c9..e8d05b7767b34 100644
--- a/pkgs/development/python-modules/zope_configuration/default.nix
+++ b/pkgs/development/python-modules/zope_configuration/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_i18nmessageid
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # Need to investigate how to run the tests with zope-testrunner
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Zope Configuration Markup Language (ZCML)";
     homepage = "https://github.com/zopefoundation/zope.configuration";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_contenttype/default.nix b/pkgs/development/python-modules/zope_contenttype/default.nix
index b1792d7185434..6b66cca18aab5 100644
--- a/pkgs/development/python-modules/zope_contenttype/default.nix
+++ b/pkgs/development/python-modules/zope_contenttype/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_testrunner
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   checkInputs = [ zope_testrunner ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.contenttype";
     description = "A utility module for content-type (MIME type) handling";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_deprecation/default.nix b/pkgs/development/python-modules/zope_deprecation/default.nix
index c4059dbcd4161..cda7af8e7a0c0 100644
--- a/pkgs/development/python-modules/zope_deprecation/default.nix
+++ b/pkgs/development/python-modules/zope_deprecation/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_testing
@@ -15,7 +15,7 @@ buildPythonPackage rec {
 
   buildInputs = [ zope_testing ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.deprecation";
     description = "Zope Deprecation Infrastructure";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_dottedname/default.nix b/pkgs/development/python-modules/zope_dottedname/default.nix
index b2afc9cc23f4f..0e8f35431364a 100644
--- a/pkgs/development/python-modules/zope_dottedname/default.nix
+++ b/pkgs/development/python-modules/zope_dottedname/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "0cec09844d309550359ac1941abfcd9141e213f67f3c19bb8f90360c40787576";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pypi.python.org/pypi/zope.dottedname";
     description = "Resolver for Python dotted names";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_event/default.nix b/pkgs/development/python-modules/zope_event/default.nix
index b5481ae2e2b70..cc82da7ea9a19 100644
--- a/pkgs/development/python-modules/zope_event/default.nix
+++ b/pkgs/development/python-modules/zope_event/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 }:
@@ -12,7 +12,7 @@ buildPythonPackage rec {
     sha256 = "5e76517f5b9b119acf37ca8819781db6c16ea433f7e2062c4afc2b6fbedb1330";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An event publishing system";
     homepage = "https://pypi.python.org/pypi/zope.event";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_exceptions/default.nix b/pkgs/development/python-modules/zope_exceptions/default.nix
index ae7797b8736b4..09f08c7bba482 100644
--- a/pkgs/development/python-modules/zope_exceptions/default.nix
+++ b/pkgs/development/python-modules/zope_exceptions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_interface
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # circular deps
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Exception interfaces and implementations";
     homepage = "https://pypi.python.org/pypi/zope.exceptions";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_filerepresentation/default.nix b/pkgs/development/python-modules/zope_filerepresentation/default.nix
index 635727a117345..7aae2a24d6235 100644
--- a/pkgs/development/python-modules/zope_filerepresentation/default.nix
+++ b/pkgs/development/python-modules/zope_filerepresentation/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_schema
@@ -20,7 +20,7 @@ buildPythonPackage rec {
     cd src/zope/filerepresentation && python -m unittest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zopefilerepresentation.readthedocs.io/";
     description = "File-system Representation Interfaces";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_i18nmessageid/default.nix b/pkgs/development/python-modules/zope_i18nmessageid/default.nix
index ca5f818cd6206..49270488ecdb4 100644
--- a/pkgs/development/python-modules/zope_i18nmessageid/default.nix
+++ b/pkgs/development/python-modules/zope_i18nmessageid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , six
@@ -19,7 +19,7 @@ buildPythonPackage rec {
 
   checkInputs = [ coverage zope_testrunner ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.i18nmessageid";
     description = "Message Identifiers for internationalization";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_interface/default.nix b/pkgs/development/python-modules/zope_interface/default.nix
index 919c3ade3c280..7a32045fc3e31 100644
--- a/pkgs/development/python-modules/zope_interface/default.nix
+++ b/pkgs/development/python-modules/zope_interface/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_event
@@ -17,7 +17,7 @@ buildPythonPackage rec {
 
   doCheck = false; # Circular deps.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Zope.Interface";
     homepage = "https://zope.org/Products/ZopeInterface";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_lifecycleevent/default.nix b/pkgs/development/python-modules/zope_lifecycleevent/default.nix
index 6494aa7a71afc..28070ea67e701 100644
--- a/pkgs/development/python-modules/zope_lifecycleevent/default.nix
+++ b/pkgs/development/python-modules/zope_lifecycleevent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPy3k
@@ -27,7 +27,7 @@ buildPythonPackage rec {
     "zope.interface"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.lifecycleevent";
     description = "Object life-cycle events";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_location/default.nix b/pkgs/development/python-modules/zope_location/default.nix
index 1c868a7397193..62b2cef9ea75b 100644
--- a/pkgs/development/python-modules/zope_location/default.nix
+++ b/pkgs/development/python-modules/zope_location/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_proxy
@@ -22,7 +22,7 @@ buildPythonPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.location/";
     description = "Zope Location";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_proxy/default.nix b/pkgs/development/python-modules/zope_proxy/default.nix
index 7092f7508708d..af108c058c7f4 100644
--- a/pkgs/development/python-modules/zope_proxy/default.nix
+++ b/pkgs/development/python-modules/zope_proxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_interface
@@ -18,7 +18,7 @@ buildPythonPackage rec {
   # circular deps
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.proxy";
     description = "Generic Transparent Proxies";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_schema/default.nix b/pkgs/development/python-modules/zope_schema/default.nix
index d32fb05ef94ae..c7e228c4e05be 100644
--- a/pkgs/development/python-modules/zope_schema/default.nix
+++ b/pkgs/development/python-modules/zope_schema/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_location
@@ -23,7 +23,7 @@ buildPythonPackage rec {
   # Package seems to work fine.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.schema";
     description = "zope.interface extension for defining data schemas";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_size/default.nix b/pkgs/development/python-modules/zope_size/default.nix
index 92df0aa1eb7e6..79eadc880a259 100644
--- a/pkgs/development/python-modules/zope_size/default.nix
+++ b/pkgs/development/python-modules/zope_size/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_i18nmessageid
@@ -16,7 +16,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ zope_i18nmessageid zope_interface ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zopefoundation/zope.size";
     description = "Interfaces and simple adapter that give the size of an object";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_testing/default.nix b/pkgs/development/python-modules/zope_testing/default.nix
index 1ea12eb377d92..3d7cbf90c25f9 100644
--- a/pkgs/development/python-modules/zope_testing/default.nix
+++ b/pkgs/development/python-modules/zope_testing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , isPyPy
@@ -20,7 +20,7 @@ buildPythonPackage rec {
 
   propagatedBuildInputs = [ zope_interface zope_exceptions zope_location ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Zope testing helpers";
     homepage =  "http://pypi.python.org/pypi/zope.testing";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zope_testrunner/default.nix b/pkgs/development/python-modules/zope_testrunner/default.nix
index 90fa0b8143cde..c516106e48bbc 100644
--- a/pkgs/development/python-modules/zope_testrunner/default.nix
+++ b/pkgs/development/python-modules/zope_testrunner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonPackage
 , fetchPypi
 , zope_interface
@@ -21,7 +21,7 @@ buildPythonPackage rec {
 
   doCheck = false; # custom test modifies sys.path
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A flexible test runner with layer support";
     homepage = "https://pypi.python.org/pypi/zope.testrunner";
     license = licenses.zpl20;
diff --git a/pkgs/development/python-modules/zstd/default.nix b/pkgs/development/python-modules/zstd/default.nix
index 95626c802badc..716b13726452c 100644
--- a/pkgs/development/python-modules/zstd/default.nix
+++ b/pkgs/development/python-modules/zstd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, fetchPypi, buildPythonPackage
+{ lib, stdenv, pkgconfig, fetchPypi, buildPythonPackage
 , buildPackages
 , zstd, pytest }:
 
@@ -36,7 +36,7 @@ buildPythonPackage rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple python bindings to Yann Collet ZSTD compression library";
     homepage = "https://github.com/sergey-dryabzhinsky/python-zstd";
     license = licenses.bsd2;
diff --git a/pkgs/development/ruby-modules/rbenv/default.nix b/pkgs/development/ruby-modules/rbenv/default.nix
index dd6b1d95b4b65..c3c462332691b 100644
--- a/pkgs/development/ruby-modules/rbenv/default.nix
+++ b/pkgs/development/ruby-modules/rbenv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bash, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, bash, installShellFiles }:
 
 stdenv.mkDerivation rec {
   pname = "rbenv";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     installShellCompletion completions/rbenv.{bash,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Groom your app’s Ruby environment";
     longDescription = ''
       Use rbenv to pick a Ruby version for your application and guarantee that your development environment matches production.
diff --git a/pkgs/development/tools/ameba/default.nix b/pkgs/development/tools/ameba/default.nix
index b46f6efd634ca..f8cb744111612 100644
--- a/pkgs/development/tools/ameba/default.nix
+++ b/pkgs/development/tools/ameba/default.nix
@@ -11,7 +11,7 @@ crystal.buildCrystalPackage rec {
     sha256 = "0yhb8vfrfzsm3a45h2jmcrn1n7jy3zn2hwims3dikgq8kaggws9y";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A static code analysis tool for Crystal";
     homepage = "https://crystal-ameba.github.io";
     license = licenses.mit;
diff --git a/pkgs/development/tools/async/default.nix b/pkgs/development/tools/async/default.nix
index e63f9a18a63a1..54e16cb6faafd 100644
--- a/pkgs/development/tools/async/default.nix
+++ b/pkgs/development/tools/async/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "async";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1zgds5rjjikvaj0rxc7slyvkjn067s0v8vdnxn3vsv819q5yd707";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to parallelize shell commands";
     longDescription = ''
       `async` is a tool to run shell commands in parallel and is designed to be
diff --git a/pkgs/development/tools/cmake-language-server/default.nix b/pkgs/development/tools/cmake-language-server/default.nix
index 628bb31fbe934..c5398f695d225 100644
--- a/pkgs/development/tools/cmake-language-server/default.nix
+++ b/pkgs/development/tools/cmake-language-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub
 , poetry, pygls, pyparsing
 , cmake, pytest, pytest-datadir
 , fetchpatch
@@ -34,7 +34,7 @@ buildPythonApplication rec {
   dontUseCmakeConfigure = true;
   checkPhase = "pytest";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/regen100/cmake-language-server";
     description = "CMake LSP Implementation";
     license = licenses.mit;
diff --git a/pkgs/development/tools/dapr/cli/default.nix b/pkgs/development/tools/dapr/cli/default.nix
index ef61edcbb8dd6..7a8243ece25da 100644
--- a/pkgs/development/tools/dapr/cli/default.nix
+++ b/pkgs/development/tools/dapr/cli/default.nix
@@ -1,4 +1,4 @@
-{ buildGoModule, fetchFromGitHub, stdenv }:
+{ buildGoModule, fetchFromGitHub, lib, stdenv }:
 
 let
   pname = "dapr";
@@ -22,7 +22,7 @@ in buildGoModule {
     mv $out/bin/cli $out/bin/dapr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://dapr.io";
     description = "A CLI for managing Dapr, the distributed application runtime";
     license = licenses.mit;
diff --git a/pkgs/development/tools/dep2nix/default.nix b/pkgs/development/tools/dep2nix/default.nix
index 9d14f7c1c1e33..daa68b1b93113 100644
--- a/pkgs/development/tools/dep2nix/default.nix
+++ b/pkgs/development/tools/dep2nix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage
+{ lib, stdenv, fetchFromGitHub, buildGoPackage
 , makeWrapper, nix-prefetch-scripts }:
 
 buildGoPackage rec {
@@ -25,7 +25,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert `Gopkg.lock` files from golang dep into `deps.nix`";
     license = licenses.bsd3;
     homepage = "https://github.com/nixcloud/dep2nix";
diff --git a/pkgs/development/tools/dot-http/default.nix b/pkgs/development/tools/dot-http/default.nix
index 1c81a4145d29b..9ff3001882cee 100644
--- a/pkgs/development/tools/dot-http/default.nix
+++ b/pkgs/development/tools/dot-http/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, libiconv, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, pkg-config, openssl, libiconv, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "dot-http";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
     libiconv Security
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Text-based scriptable HTTP client";
     homepage = "https://github.com/bayne/dot-http";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/eclipse-mat/default.nix b/pkgs/development/tools/eclipse-mat/default.nix
index 600b2b0e56ce9..e424c5ce70b7e 100644
--- a/pkgs/development/tools/eclipse-mat/default.nix
+++ b/pkgs/development/tools/eclipse-mat/default.nix
@@ -100,7 +100,7 @@ stdenv.mkDerivation rec {
   dontBuild = true;
   dontConfigure = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and feature-rich Java heap analyzer";
     longDescription = ''
       The Eclipse Memory Analyzer is a tool that helps you find memory
diff --git a/pkgs/development/tools/eliot-tree/default.nix b/pkgs/development/tools/eliot-tree/default.nix
index 95108c21bb9cf..e60642c5fe607 100644
--- a/pkgs/development/tools/eliot-tree/default.nix
+++ b/pkgs/development/tools/eliot-tree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "eliot-tree";
@@ -29,7 +29,7 @@ python3Packages.buildPythonApplication rec {
     pytest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jonathanj/eliottree";
     description = "Render Eliot logs as an ASCII tree";
     license = licenses.mit;
diff --git a/pkgs/development/tools/ginkgo/default.nix b/pkgs/development/tools/ginkgo/default.nix
index 4670c13a63ab7..b65e7c6a5eef4 100644
--- a/pkgs/development/tools/ginkgo/default.nix
+++ b/pkgs/development/tools/ginkgo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "ginkgo";
@@ -13,7 +13,7 @@ buildGoModule rec {
   vendorSha256 = "072amyw1ir18v9vk268j2y7dhw3lfwvxzvzsdqhnp50rxsa911bx";
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BDD Testing Framework for Go";
     homepage = "https://github.com/onsi/ginkgo";
     license = licenses.mit;
diff --git a/pkgs/development/tools/gir/default.nix b/pkgs/development/tools/gir/default.nix
index 02a3c13afb3d6..8f38b41f7ae2c 100644
--- a/pkgs/development/tools/gir/default.nix
+++ b/pkgs/development/tools/gir/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "gir";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "048qhlc4f5khxi7dnakgqkhgww44r6h3mlx2fm7y2wqivr3rj8p1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to generate rust bindings and user API for glib-based libraries";
     homepage = "https://github.com/gtk-rs/gir/";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/tools/glade/default.nix b/pkgs/development/tools/glade/default.nix
index 363e429b6baa6..0e3cdf4bda1e4 100644
--- a/pkgs/development/tools/glade/default.nix
+++ b/pkgs/development/tools/glade/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , gettext
 , fetchurl
 , python3
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Glade";
     description = "User interface designer for GTK applications";
     maintainers = teams.gnome.members;
diff --git a/pkgs/development/tools/global-platform-pro/default.nix b/pkgs/development/tools/global-platform-pro/default.nix
index 2f125d3ea8a36..4d80010f71eab 100644
--- a/pkgs/development/tools/global-platform-pro/default.nix
+++ b/pkgs/development/tools/global-platform-pro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jdk8, maven, makeWrapper, jre8_headless, pcsclite }:
+{ lib, stdenv, fetchFromGitHub, jdk8, maven, makeWrapper, jre8_headless, pcsclite }:
 
 let jdk = jdk8; jre_headless = jre8_headless; in
 # TODO: This is quite a bit of duplicated logic with gephi. Factor it out?
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : "${pcsclite.out}/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line utility for managing applets and keys on Java Cards";
     longDescription = ''
       This command-line utility can be used to manage applets and keys
diff --git a/pkgs/development/tools/glpaper/default.nix b/pkgs/development/tools/glpaper/default.nix
index 94d140552a10d..9ad85e840bad8 100644
--- a/pkgs/development/tools/glpaper/default.nix
+++ b/pkgs/development/tools/glpaper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchhg, meson, ninja, pkg-config, wlroots, wayland, wayland-protocols
+{ lib, stdenv, fetchhg, meson, ninja, pkg-config, wlroots, wayland, wayland-protocols
 , libX11, libGL }:
 
 stdenv.mkDerivation {
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     libGL
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Wallpaper program for wlroots based Wayland compositors such as sway that allows you to render glsl shaders as your wallpaper";
     homepage = "https://hg.sr.ht/~scoopta/glpaper";
diff --git a/pkgs/development/tools/go-junit-report/default.nix b/pkgs/development/tools/go-junit-report/default.nix
index 96ebce0eaca6f..f1e822e3633fb 100644
--- a/pkgs/development/tools/go-junit-report/default.nix
+++ b/pkgs/development/tools/go-junit-report/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "go-junit-report-unstable";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "109zs8wpdmc2ijc2khyqija8imay88ka6v50xvrpnnwnd3ywckxi";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts go test output to an xml report, suitable for applications that expect junit xml reports (e.g. Jenkins)";
     homepage    = "https://${goPackagePath}";
     maintainers = with maintainers; [ cryptix ];
diff --git a/pkgs/development/tools/go-migrate/default.nix b/pkgs/development/tools/go-migrate/default.nix
index 3a424014ec337..1786bfe5f0f96 100644
--- a/pkgs/development/tools/go-migrate/default.nix
+++ b/pkgs/development/tools/go-migrate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "go-migrate";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   subPackages = [ "cmd/migrate" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/golang-migrate/migrate";
     description = "Database migrations. CLI and Golang library";
     maintainers = with maintainers; [ offline ];
diff --git a/pkgs/development/tools/gojsontoyaml/default.nix b/pkgs/development/tools/gojsontoyaml/default.nix
index ed8cc3587c17f..0f772134a0e2a 100644
--- a/pkgs/development/tools/gojsontoyaml/default.nix
+++ b/pkgs/development/tools/gojsontoyaml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "gojsontoyaml";
@@ -13,7 +13,7 @@ buildGoModule rec {
 
   vendorSha256 = null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simply tool to convert json to yaml written in Go";
     homepage = "https://github.com/brancz/gojsontoyaml";
     license = licenses.mit;
diff --git a/pkgs/development/tools/gomplate/default.nix b/pkgs/development/tools/gomplate/default.nix
index 2bef9d53ff9e5..f8d6553f74d8e 100644
--- a/pkgs/development/tools/gomplate/default.nix
+++ b/pkgs/development/tools/gomplate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "gomplate";
@@ -26,7 +26,7 @@ buildGoModule rec {
     "-X github.com/${owner}/${pname}/v3/version.Version=${rev}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A flexible commandline tool for template rendering";
     homepage = "https://gomplate.ca/";
     maintainers = with maintainers; [ ris jlesquembre ];
diff --git a/pkgs/development/tools/gopls/default.nix b/pkgs/development/tools/gopls/default.nix
index 983b36feb2405..7a7c98e28940f 100644
--- a/pkgs/development/tools/gopls/default.nix
+++ b/pkgs/development/tools/gopls/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchgit }:
+{ lib, stdenv, buildGoModule, fetchgit }:
 
 buildGoModule rec {
   pname = "gopls";
@@ -18,7 +18,7 @@ buildGoModule rec {
   # Only build gopls, and not the integration tests or documentation generator.
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official language server for the Go language";
     homepage = "https://github.com/golang/tools/tree/master/gopls";
     license = licenses.bsd3;
diff --git a/pkgs/development/tools/gore/default.nix b/pkgs/development/tools/gore/default.nix
index ca9c8d9eec0f4..0e0264f1522da 100644
--- a/pkgs/development/tools/gore/default.nix
+++ b/pkgs/development/tools/gore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "gore";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Yet another Go REPL that works nicely";
     homepage = "https://github.com/motemen/gore";
     license = licenses.mit;
diff --git a/pkgs/development/tools/gotestsum/default.nix b/pkgs/development/tools/gotestsum/default.nix
index 8ccc1b593fd79..3e3ae19a382a8 100644
--- a/pkgs/development/tools/gotestsum/default.nix
+++ b/pkgs/development/tools/gotestsum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 
 buildGoModule rec {
   pname = "gotestsum";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gotestyourself/gotestsum";
     description = "A human friendly `go test` runner";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/development/tools/hobbes/default.nix b/pkgs/development/tools/hobbes/default.nix
index 5fd9d314c5e05..667997ddff4de 100644
--- a/pkgs/development/tools/hobbes/default.nix
+++ b/pkgs/development/tools/hobbes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, llvm_6, ncurses, readline, zlib }:
+{ lib, stdenv, fetchFromGitHub, cmake, llvm_6, ncurses, readline, zlib }:
 
 stdenv.mkDerivation {
   name = "hobbes";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
   doCheck = false; # Running tests in NixOS hangs. See https://git.io/JvK7R.
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A language and an embedded JIT compiler";
     longDescription = ''
       Hobbes is a a language, embedded compiler, and runtime for efficient
diff --git a/pkgs/development/tools/jpexs/default.nix b/pkgs/development/tools/jpexs/default.nix
index 87bba3847b559..24aa43cdeba3f 100644
--- a/pkgs/development/tools/jpexs/default.nix
+++ b/pkgs/development/tools/jpexs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, makeWrapper, makeDesktopItem, jdk8 }:
+{ lib, stdenv, fetchzip, makeWrapper, makeDesktopItem, jdk8 }:
 
 stdenv.mkDerivation rec {
   pname = "jpexs";
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flash SWF decompiler and editor";
     longDescription = ''
       Open-source Flash SWF decompiler and editor. Extract resources,
diff --git a/pkgs/development/tools/jtc/default.nix b/pkgs/development/tools/jtc/default.nix
index f0e708d58aa59..947dee9ee3c0b 100644
--- a/pkgs/development/tools/jtc/default.nix
+++ b/pkgs/development/tools/jtc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "jtc";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "JSON manipulation and transformation tool";
     homepage = "https://github.com/ldn-softdev/jtc";
     license = licenses.mit;
diff --git a/pkgs/development/tools/kcli/default.nix b/pkgs/development/tools/kcli/default.nix
index 3a0fff71dc79e..6c9f62c6f72d9 100644
--- a/pkgs/development/tools/kcli/default.nix
+++ b/pkgs/development/tools/kcli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "kcli";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A kafka command line browser";
     homepage = "https://github.com/cswank/kcli";
     license = licenses.mit;
diff --git a/pkgs/development/tools/knightos/genkfs/default.nix b/pkgs/development/tools/knightos/genkfs/default.nix
index b826c1a58b997..9f553aa6bae3e 100644
--- a/pkgs/development/tools/knightos/genkfs/default.nix
+++ b/pkgs/development/tools/knightos/genkfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, asciidoc }:
+{ lib, stdenv, fetchFromGitHub, cmake, asciidoc }:
 
 stdenv.mkDerivation rec {
   pname = "genkfs";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "Utility to write a KFS filesystem into a ROM file";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/knightos/kcc/default.nix b/pkgs/development/tools/knightos/kcc/default.nix
index 364d46de56d95..5f047d79a1381 100644
--- a/pkgs/development/tools/knightos/kcc/default.nix
+++ b/pkgs/development/tools/knightos/kcc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, bison, flex, boost }:
+{ lib, stdenv, fetchFromGitHub, cmake, bison, flex, boost }:
 
 stdenv.mkDerivation rec {
   pname = "kcc";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ boost ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "KnightOS C compiler";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/development/tools/knightos/kimg/default.nix b/pkgs/development/tools/knightos/kimg/default.nix
index 3f3f698693df9..33ec5b8bbb2ad 100644
--- a/pkgs/development/tools/knightos/kimg/default.nix
+++ b/pkgs/development/tools/knightos/kimg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, asciidoc }:
+{ lib, stdenv, fetchFromGitHub, cmake, asciidoc }:
 
 stdenv.mkDerivation rec {
   pname = "kimg";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "Converts image formats supported by stb_image to the KnightOS image format";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/knightos/kpack/default.nix b/pkgs/development/tools/knightos/kpack/default.nix
index 657a1712ed24f..43a8e4eddfa8c 100644
--- a/pkgs/development/tools/knightos/kpack/default.nix
+++ b/pkgs/development/tools/knightos/kpack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, asciidoc, libxslt, docbook_xsl }:
+{ lib, stdenv, fetchFromGitHub, cmake, asciidoc, libxslt, docbook_xsl }:
 
 stdenv.mkDerivation rec {
   pname = "kpack";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "fortify" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "A tool to create or extract KnightOS packages";
     license     = licenses.lgpl2Only;
diff --git a/pkgs/development/tools/knightos/mkrom/default.nix b/pkgs/development/tools/knightos/mkrom/default.nix
index 46482a8491343..b1ee36ac2dab3 100644
--- a/pkgs/development/tools/knightos/mkrom/default.nix
+++ b/pkgs/development/tools/knightos/mkrom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, asciidoc }:
+{ lib, stdenv, fetchFromGitHub, cmake, asciidoc }:
 
 stdenv.mkDerivation rec {
   pname = "mkrom";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "Packages KnightOS distribution files into a ROM";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/knightos/mktiupgrade/default.nix b/pkgs/development/tools/knightos/mktiupgrade/default.nix
index 171c1671b3326..a91d1e5beda86 100644
--- a/pkgs/development/tools/knightos/mktiupgrade/default.nix
+++ b/pkgs/development/tools/knightos/mktiupgrade/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, asciidoc }:
+{ lib, stdenv, fetchFromGitHub, cmake, asciidoc }:
 
 stdenv.mkDerivation rec {
   pname = "mktiupgrade";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "Makes TI calculator upgrade files from ROM dumps";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/knightos/patchrom/default.nix b/pkgs/development/tools/knightos/patchrom/default.nix
index 9feab36ec8228..33ed8d38c63d6 100644
--- a/pkgs/development/tools/knightos/patchrom/default.nix
+++ b/pkgs/development/tools/knightos/patchrom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, asciidoc, libxslt, docbook_xsl }:
+{ lib, stdenv, fetchFromGitHub, cmake, asciidoc, libxslt, docbook_xsl }:
 
 
 stdenv.mkDerivation rec {
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "Patches jumptables into TI calculator ROM files and generates an include file";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/knightos/scas/default.nix b/pkgs/development/tools/knightos/scas/default.nix
index b87650d5bf95b..573d261306a60 100644
--- a/pkgs/development/tools/knightos/scas/default.nix
+++ b/pkgs/development/tools/knightos/scas/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, cmake }:
+{ fetchFromGitHub, lib, stdenv, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "scas";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "Assembler and linker for the Z80";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/knightos/z80e/default.nix b/pkgs/development/tools/knightos/z80e/default.nix
index d8f6a12740328..a089511fb6849 100644
--- a/pkgs/development/tools/knightos/z80e/default.nix
+++ b/pkgs/development/tools/knightos/z80e/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, knightos-scas, readline, SDL2 }:
+{ lib, stdenv, fetchFromGitHub, cmake, knightos-scas, readline, SDL2 }:
 
 stdenv.mkDerivation rec {
   pname = "z80e";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-Denable-sdl=YES" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://knightos.org/";
     description = "A Z80 calculator emulator and debugger";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/krew/default.nix b/pkgs/development/tools/krew/default.nix
index b5fc91b62dda9..8e5d9d76fc493 100644
--- a/pkgs/development/tools/krew/default.nix
+++ b/pkgs/development/tools/krew/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "krew";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   subPackages = [ "cmd/krew" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Package manager for kubectl plugins";
     homepage = "https://github.com/kubernetes-sigs/krew";
     maintainers = with maintainers; [ vdemeester ];
diff --git a/pkgs/development/tools/kubeprompt/default.nix b/pkgs/development/tools/kubeprompt/default.nix
index 51369bc1f91e5..4fc8f3253429d 100644
--- a/pkgs/development/tools/kubeprompt/default.nix
+++ b/pkgs/development/tools/kubeprompt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "kubeprompt";
@@ -22,7 +22,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kubernetes prompt";
     homepage = "https://github.com/jlesquembre/kubeprompt";
     license = licenses.epl20;
diff --git a/pkgs/development/tools/kubie/default.nix b/pkgs/development/tools/kubie/default.nix
index cae76669ab42d..33d4ea0df1d21 100644
--- a/pkgs/development/tools/kubie/default.nix
+++ b/pkgs/development/tools/kubie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, installShellFiles, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, installShellFiles, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "kubie";
@@ -21,7 +21,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion completion/kubie.bash
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shell independent context and namespace switcher for kubectl";
     homepage = "https://github.com/sbstp/kubie";
     license = with licenses; [ zlib ];
diff --git a/pkgs/development/tools/lc3tools/default.nix b/pkgs/development/tools/lc3tools/default.nix
index 122271c34a4d4..3e7f81bb4e7bc 100644
--- a/pkgs/development/tools/lc3tools/default.nix
+++ b/pkgs/development/tools/lc3tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, flex, tk, ncurses, readline }:
+{ lib, stdenv, fetchurl, unzip, flex, tk, ncurses, readline }:
 
 stdenv.mkDerivation {
   pname = "lc3tools";
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
     mv -t $out/bin $out/lc3*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Toolchain and emulator for the LC-3 architecture";
     license = licenses.gpl2;
     maintainers = with maintainers; [ anna328p ];
diff --git a/pkgs/development/tools/metals/default.nix b/pkgs/development/tools/metals/default.nix
index 951e9a0ac2e8f..0937ccb598714 100644
--- a/pkgs/development/tools/metals/default.nix
+++ b/pkgs/development/tools/metals/default.nix
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
       --add-flags "${extraJavaOpts} -Dmetals.client=sublime -cp $CLASSPATH scala.meta.metals.Main"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://scalameta.org/metals/";
     license = licenses.asl20;
     description = "Work-in-progress language server for Scala";
diff --git a/pkgs/development/tools/micronaut/default.nix b/pkgs/development/tools/micronaut/default.nix
index 5d032d42108fe..ddf9d84f3bf47 100644
--- a/pkgs/development/tools/micronaut/default.nix
+++ b/pkgs/development/tools/micronaut/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jdk, makeWrapper, installShellFiles }:
+{ lib, stdenv, fetchzip, jdk, makeWrapper, installShellFiles }:
 
 stdenv.mkDerivation rec {
   pname = "micronaut";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern, JVM-based, full-stack framework for building microservice applications";
     longDescription = ''
       Micronaut is a modern, JVM-based, full stack microservices framework
diff --git a/pkgs/development/tools/mmixware/default.nix b/pkgs/development/tools/mmixware/default.nix
index 0b0d394b4e1e9..b6d03f4567124 100644
--- a/pkgs/development/tools/mmixware/default.nix
+++ b/pkgs/development/tools/mmixware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, tetex }:
+{ lib, stdenv, fetchFromGitLab, tetex }:
 
 stdenv.mkDerivation {
   pname = "mmixware";
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "MMIX simulator and assembler";
     homepage     = "https://www-cs-faculty.stanford.edu/~knuth/mmix-news.html";
     maintainers  = with maintainers; [ siraben ];
diff --git a/pkgs/development/tools/msgpack-tools/default.nix b/pkgs/development/tools/msgpack-tools/default.nix
index c04a93eeee4fd..a7b3c36d87b2f 100644
--- a/pkgs/development/tools/msgpack-tools/default.nix
+++ b/pkgs/development/tools/msgpack-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchurl, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "msgpack-tools";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line tools for converting between MessagePack and JSON";
     homepage = "https://github.com/ludocode/msgpack-tools";
     license = licenses.mit;
diff --git a/pkgs/development/tools/nailgun/default.nix b/pkgs/development/tools/nailgun/default.nix
index 84e5a6b1d9fc6..9832de15140a9 100644
--- a/pkgs/development/tools/nailgun/default.nix
+++ b/pkgs/development/tools/nailgun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchMavenArtifact, fetchFromGitHub, jre, makeWrapper }:
+{ lib, stdenv, fetchMavenArtifact, fetchFromGitHub, jre, makeWrapper }:
 
 let
   version = "1.0.0";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
       --add-flags '-classpath ${nailgun-server.jar}:$CLASSPATH com.facebook.nailgun.NGServer'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client, protocol, and server for running Java programs from the command line without incurring the JVM startup overhead";
     homepage = "http://www.martiansoftware.com/nailgun/";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/nemiver/default.nix b/pkgs/development/tools/nemiver/default.nix
index 8890ceca9d39d..191b172134952 100644
--- a/pkgs/development/tools/nemiver/default.nix
+++ b/pkgs/development/tools/nemiver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , pkgconfig
@@ -78,7 +78,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Nemiver";
     description = "Easy to use standalone C/C++ debugger";
     license = licenses.gpl2;
diff --git a/pkgs/development/tools/nsis/default.nix b/pkgs/development/tools/nsis/default.nix
index 303ea6a00fe88..2d3f54bbf75bc 100644
--- a/pkgs/development/tools/nsis/default.nix
+++ b/pkgs/development/tools/nsis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchzip
 , sconsPackages
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
   prefixKey = "PREFIX=";
   installTargets = [ "install-compiler" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free scriptable win32 installer/uninstaller system that doesn't suck and isn't huge";
     homepage = "https://nsis.sourceforge.io/";
     license = licenses.zlib;
diff --git a/pkgs/development/tools/ocaml/ocamlscript/default.nix b/pkgs/development/tools/ocaml/ocamlscript/default.nix
index 2172c7f6161ac..4518e7a22e414 100644
--- a/pkgs/development/tools/ocaml/ocamlscript/default.nix
+++ b/pkgs/development/tools/ocaml/ocamlscript/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ocaml, findlib, camlp4}:
+{lib, stdenv, fetchurl, ocaml, findlib, camlp4}:
 stdenv.mkDerivation {
   name = "ocamlscript-2.0.3";
   src = fetchurl {
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
   preInstall = "mkdir $out/bin";
   createFindlibDestdir = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://martin.jambon.free.fr/ocamlscript.html";
     license = licenses.boost;
     platforms = ocaml.meta.platforms or [];
diff --git a/pkgs/development/tools/ocaml/opam/opam.nix.pl b/pkgs/development/tools/ocaml/opam/opam.nix.pl
index 828e209fac61a..1cbad6f5f44e3 100755
--- a/pkgs/development/tools/ocaml/opam/opam.nix.pl
+++ b/pkgs/development/tools/ocaml/opam/opam.nix.pl
@@ -120,7 +120,7 @@ print <<'EOF';
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A package manager for OCaml";
     homepage = "https://opam.ocaml.org/";
     maintainers = [ maintainers.henrytill maintainers.marsam ];
diff --git a/pkgs/development/tools/ofono-phonesim/default.nix b/pkgs/development/tools/ofono-phonesim/default.nix
index e651c7cfab50a..086cd818a4673 100644
--- a/pkgs/development/tools/ofono-phonesim/default.nix
+++ b/pkgs/development/tools/ofono-phonesim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchgit
 , autoreconfHook
@@ -30,7 +30,7 @@ mkDerivation {
     "UIC=${qtbase.dev}/bin/uic"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Phone Simulator for modem testing";
     homepage = "https://01.org/ofono";
     license = licenses.gpl2;
diff --git a/pkgs/development/tools/osslsigncode/default.nix b/pkgs/development/tools/osslsigncode/default.nix
index ef673ed018f2d..349a6b10104ee 100644
--- a/pkgs/development/tools/osslsigncode/default.nix
+++ b/pkgs/development/tools/osslsigncode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , libgsf
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook libgsf pkgconfig openssl curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mtrojnar/osslsigncode";
     description = "OpenSSL based Authenticode signing for PE/MSI/Java CAB files";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/tools/out-of-tree/default.nix b/pkgs/development/tools/out-of-tree/default.nix
index b902dd2cc4067..7573776421904 100644
--- a/pkgs/development/tools/out-of-tree/default.nix
+++ b/pkgs/development/tools/out-of-tree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchgit, qemu, docker, which, makeWrapper }:
+{ lib, stdenv, buildGoModule, fetchgit, qemu, docker, which, makeWrapper }:
 
 buildGoModule rec {
   pname = "out-of-tree";
@@ -21,7 +21,7 @@ buildGoModule rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ qemu docker which ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "kernel {module, exploit} development tool";
     homepage = "https://out-of-tree.io";
     maintainers = [ maintainers.dump_stack ];
diff --git a/pkgs/development/tools/packer/default.nix b/pkgs/development/tools/packer/default.nix
index 8570e10a07c3d..d4dd46cdcb5c5 100644
--- a/pkgs/development/tools/packer/default.nix
+++ b/pkgs/development/tools/packer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 buildGoPackage rec {
   pname = "packer";
   version = "1.6.6";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "sha256-kFDy8Zlx+D5JDyNlAmB/ICTe4K9s6KDbALP5pom5OQg=";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for creating identical machine images for multiple platforms from a single source configuration";
     homepage    = "https://www.packer.io";
     license     = licenses.mpl20;
diff --git a/pkgs/development/tools/packet-cli/default.nix b/pkgs/development/tools/packet-cli/default.nix
index 4c4cb6a28d42a..ec07e4b058ee4 100644
--- a/pkgs/development/tools/packet-cli/default.nix
+++ b/pkgs/development/tools/packet-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "packet-cli";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official Packet CLI";
     homepage = "https://github.com/packethost/packet-cli";
     license = licenses.mit;
diff --git a/pkgs/development/tools/parinfer-rust/default.nix b/pkgs/development/tools/parinfer-rust/default.nix
index f697e00b56a46..79c8f3791880e 100644
--- a/pkgs/development/tools/parinfer-rust/default.nix
+++ b/pkgs/development/tools/parinfer-rust/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, llvmPackages }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, llvmPackages }:
 
 rustPlatform.buildRustPackage rec {
   pname = "parinfer-rust";
@@ -27,7 +27,7 @@ rustPlatform.buildRustPackage rec {
       plugin/parinfer.vim >$rtpPath/plugin/parinfer.vim
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Infer parentheses for Clojure, Lisp, and Scheme";
     homepage = "https://github.com/eraserhd/parinfer-rust";
     license = licenses.isc;
diff --git a/pkgs/development/tools/parse-cli-bin/default.nix b/pkgs/development/tools/parse-cli-bin/default.nix
index 0f8ead579d0ae..7cda74db5ef63 100644
--- a/pkgs/development/tools/parse-cli-bin/default.nix
+++ b/pkgs/development/tools/parse-cli-bin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "parse-cli-bin";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1iyfizbbxmr87wjgqiwqds51irgw6l3vm9wn89pc3zpj2zkyvf5h";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parse Command Line Interface";
     homepage    = "https://parse.com";
     platforms   = platforms.linux;
diff --git a/pkgs/development/tools/parsing/antlr/2.7.7.nix b/pkgs/development/tools/parsing/antlr/2.7.7.nix
index 55800a8009848..fed96e954751b 100644
--- a/pkgs/development/tools/parsing/antlr/2.7.7.nix
+++ b/pkgs/development/tools/parsing/antlr/2.7.7.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jdk, python2 }:
+{ lib, stdenv, fetchurl, jdk, python2 }:
 
 stdenv.mkDerivation {
   name = "antlr-2.7.7";
@@ -10,7 +10,7 @@ stdenv.mkDerivation {
   buildInputs = [ jdk ];
   nativeBuildInputs = [ python2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful parser generator";
     longDescription = ''
       ANTLR (ANother Tool for Language Recognition) is a powerful parser
diff --git a/pkgs/development/tools/parsing/antlr/3.4.nix b/pkgs/development/tools/parsing/antlr/3.4.nix
index 1263e7934be7f..962cd079a8e94 100644
--- a/pkgs/development/tools/parsing/antlr/3.4.nix
+++ b/pkgs/development/tools/parsing/antlr/3.4.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, jre}:
+{lib, stdenv, fetchurl, jre}:
 
 stdenv.mkDerivation rec {
   pname = "antlr";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   inherit jre;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful parser generator";
     longDescription = ''
       ANTLR (ANother Tool for Language Recognition) is a powerful parser
diff --git a/pkgs/development/tools/parsing/antlr/3.5.nix b/pkgs/development/tools/parsing/antlr/3.5.nix
index 6fa6323d3e876..39c022604d8ff 100644
--- a/pkgs/development/tools/parsing/antlr/3.5.nix
+++ b/pkgs/development/tools/parsing/antlr/3.5.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, fetchFromGitHub, jre}:
+{lib, stdenv, fetchurl, fetchFromGitHub, jre}:
 
 stdenv.mkDerivation rec {
   pname = "antlr";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   inherit jre;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful parser generator";
     longDescription = ''
       ANTLR (ANother Tool for Language Recognition) is a powerful parser
diff --git a/pkgs/development/tools/parsing/antlr/4.8.nix b/pkgs/development/tools/parsing/antlr/4.8.nix
index 1c88c82e16ae3..411364e203bf3 100644
--- a/pkgs/development/tools/parsing/antlr/4.8.nix
+++ b/pkgs/development/tools/parsing/antlr/4.8.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre
+{ lib, stdenv, fetchurl, jre
 , fetchFromGitHub, cmake, ninja, pkgconfig, libuuid, darwin }:
 
 let
@@ -26,7 +26,7 @@ let
         export sourceRoot=$sourceRoot/runtime/Cpp
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "C++ target for ANTLR 4";
         homepage = "https://www.antlr.org/";
         license = licenses.bsd3;
@@ -67,7 +67,7 @@ let
       jarLocation = "${antlr}/share/java/antlr-${version}-complete.jar";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Powerful parser generator";
       longDescription = ''
         ANTLR (ANother Tool for Language Recognition) is a powerful parser
diff --git a/pkgs/development/tools/parsing/bisonc++/default.nix b/pkgs/development/tools/parsing/bisonc++/default.nix
index c6a4fc1a068d1..5710500a18f73 100644
--- a/pkgs/development/tools/parsing/bisonc++/default.nix
+++ b/pkgs/development/tools/parsing/bisonc++/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, fetchFromGitLab
+{lib, stdenv, fetchurl, fetchFromGitLab
 , yodl, icmake, flexcpp, bobcat
 }:
 stdenv.mkDerivation rec {
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     ./build install x
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     description = "A parser generator like bison, but it generates C++ code";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/tools/parsing/byacc/default.nix b/pkgs/development/tools/parsing/byacc/default.nix
index 60e6796850c2b..4f6f00e968efe 100644
--- a/pkgs/development/tools/parsing/byacc/default.nix
+++ b/pkgs/development/tools/parsing/byacc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "byacc";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     ln -s $out/bin/byacc $out/bin/yacc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Berkeley YACC";
     homepage = "https://invisible-island.net/byacc/byacc.html";
     license = licenses.publicDomain;
diff --git a/pkgs/development/tools/parsing/flex/2.5.35.nix b/pkgs/development/tools/parsing/flex/2.5.35.nix
index 504e5b090497d..c352b5a38374a 100644
--- a/pkgs/development/tools/parsing/flex/2.5.35.nix
+++ b/pkgs/development/tools/parsing/flex/2.5.35.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, flex, bison, texinfo, help2man, m4 }:
+{ lib, stdenv, fetchurl, autoreconfHook, flex, bison, texinfo, help2man, m4 }:
 
 stdenv.mkDerivation {
   name = "flex-2.5.35";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
 
   doCheck = false; # fails 2 out of 46 tests
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     branch = "2.5.35";
     homepage = "http://flex.sourceforge.net/";
     description = "A fast lexical analyser generator";
diff --git a/pkgs/development/tools/parsing/flex/2.6.1.nix b/pkgs/development/tools/parsing/flex/2.6.1.nix
index 2562b3c26134d..3a032e60c32f6 100644
--- a/pkgs/development/tools/parsing/flex/2.6.1.nix
+++ b/pkgs/development/tools/parsing/flex/2.6.1.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bison, m4 }:
+{ lib, stdenv, fetchurl, bison, m4 }:
 
 stdenv.mkDerivation {
   name = "flex-2.6.1";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     sed -i Makefile -e 's/-no-undefined//;'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/westes/flex";
     description = "A fast lexical analyser generator";
     license = licenses.bsd2;
diff --git a/pkgs/development/tools/parsing/flex/default.nix b/pkgs/development/tools/parsing/flex/default.nix
index 51373f4a4fd7f..c77c1f73c69e6 100644
--- a/pkgs/development/tools/parsing/flex/default.nix
+++ b/pkgs/development/tools/parsing/flex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, bison, m4
+{ lib, stdenv, buildPackages, fetchurl, bison, m4
 , fetchpatch, autoreconfHook, help2man
 }:
 
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
 
   dontDisableStatic = stdenv.buildPlatform != stdenv.hostPlatform;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/westes/flex";
     description = "A fast lexical analyser generator";
     license = licenses.bsd2;
diff --git a/pkgs/development/tools/parsing/flexc++/default.nix b/pkgs/development/tools/parsing/flexc++/default.nix
index a9482f9fd4939..e4db5631e7fe0 100644
--- a/pkgs/development/tools/parsing/flexc++/default.nix
+++ b/pkgs/development/tools/parsing/flexc++/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bobcat, icmake, yodl }:
+{ lib, stdenv, fetchFromGitHub, bobcat, icmake, yodl }:
 
 stdenv.mkDerivation rec {
   pname = "flexc++";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     ./build install x
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C++ tool for generating lexical scanners";
     longDescription = ''
       Flexc++ was designed after `flex'. Flexc++ offers a cleaner class design
diff --git a/pkgs/development/tools/parsing/hammer/default.nix b/pkgs/development/tools/parsing/hammer/default.nix
index d36dfa9219d42..b6cb2447710c8 100644
--- a/pkgs/development/tools/parsing/hammer/default.nix
+++ b/pkgs/development/tools/parsing/hammer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, glib, pkgconfig, python, scons }:
+{ lib, stdenv, fetchgit, glib, pkgconfig, python, scons }:
 
 stdenv.mkDerivation {
   pname = "hammer";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ glib python scons ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A bit-oriented parser combinator library";
     longDescription = ''
       Hammer is a parsing library. Like many modern parsing libraries,
diff --git a/pkgs/development/tools/parsing/jikespg/default.nix b/pkgs/development/tools/parsing/jikespg/default.nix
index 18dd531e4b14a..34e628866838f 100644
--- a/pkgs/development/tools/parsing/jikespg/default.nix
+++ b/pkgs/development/tools/parsing/jikespg/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   name = "jikespg-1.3";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
       cp jikespg $out/bin
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://jikes.sourceforge.net/";
     description = "The Jikes Parser Generator";
     platforms = platforms.linux;
diff --git a/pkgs/development/tools/parsing/lemon/default.nix b/pkgs/development/tools/parsing/lemon/default.nix
index b10e989095171..3db9e0f6d9ed7 100644
--- a/pkgs/development/tools/parsing/lemon/default.nix
+++ b/pkgs/development/tools/parsing/lemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
 
@@ -30,7 +30,7 @@ in stdenv.mkDerivation {
     install -Dvm644 ${srcs.lempar} $out/bin/lempar.c
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An LALR(1) parser generator";
     longDescription = ''
       The Lemon program is an LALR(1) parser generator that takes a
diff --git a/pkgs/development/tools/parsing/peg/default.nix b/pkgs/development/tools/parsing/peg/default.nix
index 458ddc007f5ed..a7ffeb697459a 100644
--- a/pkgs/development/tools/parsing/peg/default.nix
+++ b/pkgs/development/tools/parsing/peg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "peg-0.1.18";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   preBuild="makeFlagsArray+=( PREFIX=$out )";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://piumarta.com/software/peg/";
     description = "Tools for generating recursive-descent parsers: programs that perform pattern matching on text";
     platforms = platforms.all;
diff --git a/pkgs/development/tools/parsing/ragel/default.nix b/pkgs/development/tools/parsing/ragel/default.nix
index dddddba129c93..fd7308097110e 100644
--- a/pkgs/development/tools/parsing/ragel/default.nix
+++ b/pkgs/development/tools/parsing/ragel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, transfig, tex, ghostscript, colm
+{ lib, stdenv, fetchurl, transfig, tex, ghostscript, colm
 , build-manual ? false
 }:
 
@@ -25,7 +25,7 @@ let
 
       doCheck = true;
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.colm.net/open-source/ragel/";
         description = "State machine compiler";
         inherit license;
diff --git a/pkgs/development/tools/parsing/re2c/default.nix b/pkgs/development/tools/parsing/re2c/default.nix
index 482beeff12219..665609fe90af7 100644
--- a/pkgs/development/tools/parsing/re2c/default.nix
+++ b/pkgs/development/tools/parsing/re2c/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "re2c";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     patchShebangs run_tests.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for writing very fast and very flexible scanners";
     homepage    = "http://re2c.org";
     license     = licenses.publicDomain;
diff --git a/pkgs/development/tools/pax-rs/default.nix b/pkgs/development/tools/pax-rs/default.nix
index 6aa38104bcacc..cda3ba5e8a8b9 100644
--- a/pkgs/development/tools/pax-rs/default.nix
+++ b/pkgs/development/tools/pax-rs/default.nix
@@ -1,11 +1,11 @@
-{ stdenv, fetchFromGitHub, fetchurl, rustPlatform, runCommand } :
+{ lib, stdenv, fetchFromGitHub, fetchurl, rustPlatform, runCommand } :
 with rustPlatform;
 
 buildRustPackage rec {
   pname = "pax-rs";
   version = "0.4.0";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The fastest JavaScript bundler in the galaxy";
     longDescription = ''
       The fastest JavaScript bundler in the galaxy. Fully supports ECMAScript module syntax (import/export) in addition to CommonJS require(<string>).
diff --git a/pkgs/development/tools/pew/default.nix b/pkgs/development/tools/pew/default.nix
index a7fabb7839516..6ca94041bb505 100644
--- a/pkgs/development/tools/pew/default.nix
+++ b/pkgs/development/tools/pew/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3 }:
+{ lib, stdenv, python3 }:
 
 with python3.pkgs;
 
@@ -20,7 +20,7 @@ buildPythonApplication rec {
 
   pythonImportsCheck = [ "pew" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/berdario/pew";
     description = "Tools to manage multiple virtualenvs written in pure python";
     license = licenses.mit;
diff --git a/pkgs/development/tools/pgformatter/default.nix b/pkgs/development/tools/pgformatter/default.nix
index 1cd9f9ea17ba2..0e3e1b7e9ca65 100644
--- a/pkgs/development/tools/pgformatter/default.nix
+++ b/pkgs/development/tools/pgformatter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, perlPackages, fetchFromGitHub, shortenPerlShebang }:
+{ lib, stdenv, perlPackages, fetchFromGitHub, shortenPerlShebang }:
 
 perlPackages.buildPerlPackage rec {
   pname = "pgformatter";
@@ -31,7 +31,7 @@ perlPackages.buildPerlPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PostgreSQL SQL syntax beautifier that can work as a console program or as a CGI";
     homepage = "https://github.com/darold/pgFormatter";
     changelog = "https://github.com/darold/pgFormatter/releases/tag/v${version}";
diff --git a/pkgs/development/tools/pgloader/default.nix b/pkgs/development/tools/pgloader/default.nix
index 6d4bcaadd1182..0e16726bb8078 100644
--- a/pkgs/development/tools/pgloader/default.nix
+++ b/pkgs/development/tools/pgloader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, sbcl, sqlite, freetds, libzip, curl, git, cacert, openssl }:
+{ lib, stdenv, fetchurl, makeWrapper, sbcl, sqlite, freetds, libzip, curl, git, cacert, openssl }:
 stdenv.mkDerivation rec {
   pname = "pgloader";
   version = "3.6.2";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/pgloader --prefix LD_LIBRARY_PATH : "${LD_LIBRARY_PATH}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pgloader.io/";
     description = "Loads data into PostgreSQL and allows you to implement Continuous Migration from your current database to PostgreSQL";
     maintainers = with maintainers; [ mguentner ];
diff --git a/pkgs/development/tools/phantomjs2/default.nix b/pkgs/development/tools/phantomjs2/default.nix
index d565a70798ae5..9fc2f416b7678 100644
--- a/pkgs/development/tools/phantomjs2/default.nix
+++ b/pkgs/development/tools/phantomjs2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , bison, flex, fontconfig, freetype, gperf, icu, openssl, libjpeg
 , libpng, perl, python, ruby, sqlite, qtwebkit, qmake, qtbase
 , darwin, writeScriptBin, cups, makeWrapper
@@ -95,7 +95,7 @@ in stdenv.mkDerivation rec {
     --prefix PATH : ${stdenv.lib.makeBinPath [ qtbase ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Headless WebKit with JavaScript API";
     longDescription = ''
       PhantomJS2 is a headless WebKit with JavaScript API.
diff --git a/pkgs/development/tools/postiats-utilities/default.nix b/pkgs/development/tools/postiats-utilities/default.nix
index 4b6d230becd64..b9ca9ae578140 100644
--- a/pkgs/development/tools/postiats-utilities/default.nix
+++ b/pkgs/development/tools/postiats-utilities/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3, python3Packages }:
+{ lib, stdenv, fetchurl, python3, python3Packages }:
 
 stdenv.mkDerivation {
   name = "postiats-utilities-2.0.1";
@@ -7,7 +7,7 @@ stdenv.mkDerivation {
     sha256 = "12jlzqigmaa9m37x0nq5v3gq8v61m73i5kzdnsm06chf0przpaix";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Hibou57/PostiATS-Utilities";
     license = licenses.bsd2;
     platforms = platforms.linux;
diff --git a/pkgs/development/tools/profiling/pprof/default.nix b/pkgs/development/tools/profiling/pprof/default.nix
index 2618dd3ef1ecc..dd2345378d437 100644
--- a/pkgs/development/tools/profiling/pprof/default.nix
+++ b/pkgs/development/tools/profiling/pprof/default.nix
@@ -1,5 +1,5 @@
 # This file was originally generated by https://github.com/kamilchm/go2nix v1.2.1
-{ stdenv, buildGoPackage, fetchgit }:
+{ lib, stdenv, buildGoPackage, fetchgit }:
 
 buildGoPackage rec {
   pname = "pprof-unstable";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for visualization and analysis of profiling data";
     homepage = "https://github.com/google/pprof";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/profiling/sysprof/default.nix b/pkgs/development/tools/profiling/sysprof/default.nix
index 49b8e88486ca6..6974800e87f82 100644
--- a/pkgs/development/tools/profiling/sysprof/default.nix
+++ b/pkgs/development/tools/profiling/sysprof/default.nix
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System-wide profiler for Linux";
     homepage = "https://wiki.gnome.org/Apps/Sysprof";
     longDescription = ''
diff --git a/pkgs/development/tools/pxview/default.nix b/pkgs/development/tools/pxview/default.nix
index 6b11071b6fa3b..30d109beb9702 100644
--- a/pkgs/development/tools/pxview/default.nix
+++ b/pkgs/development/tools/pxview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, perl, perlPackages, pxlib }:
+{ lib, stdenv, fetchurl, pkgconfig, perl, perlPackages, pxlib }:
 
 stdenv.mkDerivation rec {
   pname = "pxview";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   LDFLAGS = "-lm";
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Program to convert Paradox databases";
     homepage = "http://pxlib.sourceforge.net/pxview/";
     license = licenses.gpl2;
diff --git a/pkgs/development/tools/py-spy/default.nix b/pkgs/development/tools/py-spy/default.nix
index 5e1dcbfa6fce3..5edd73eba9506 100644
--- a/pkgs/development/tools/py-spy/default.nix
+++ b/pkgs/development/tools/py-spy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgsBuildBuild, rustPlatform, fetchFromGitHub, pkgconfig, libunwind, python3 }:
+{ lib, stdenv, pkgsBuildBuild, rustPlatform, fetchFromGitHub, pkgconfig, libunwind, python3 }:
 
 rustPlatform.buildRustPackage rec {
   pname = "py-spy";
@@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0hrzmpwd2k4l8gjbry8ddrkv9q9qh8ag096md4q0fyn5bgnxhkah";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sampling profiler for Python programs";
     license = licenses.mit;
     maintainers = [ maintainers.lnl7 ];
diff --git a/pkgs/development/tools/quicktemplate/default.nix b/pkgs/development/tools/quicktemplate/default.nix
index cb9b4f950c929..4edb60d11a156 100644
--- a/pkgs/development/tools/quicktemplate/default.nix
+++ b/pkgs/development/tools/quicktemplate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "quicktemplate";
@@ -13,7 +13,7 @@ buildGoModule rec {
 
   vendorSha256 = null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/valyala/quicktemplate";
     description = "Fast, powerful, yet easy to use template engine for Go";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rdbtools/default.nix b/pkgs/development/tools/rdbtools/default.nix
index 624434101d996..5674876daba6c 100644
--- a/pkgs/development/tools/rdbtools/default.nix
+++ b/pkgs/development/tools/rdbtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python }:
+{ lib, stdenv, python }:
 
 with python.pkgs;
 
@@ -16,7 +16,7 @@ buildPythonApplication rec {
   # No tests in published package
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parse Redis dump.rdb files, Analyze Memory, and Export Data to JSON";
     homepage = "https://github.com/sripathikrishnan/redis-rdb-tools";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rdocker/default.nix b/pkgs/development/tools/rdocker/default.nix
index 60df0df10031e..16e832a99b84d 100644
--- a/pkgs/development/tools/rdocker/default.nix
+++ b/pkgs/development/tools/rdocker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, openssh }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, openssh }:
 
 stdenv.mkDerivation {
   pname = "rdocker";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
       --prefix PATH : ${stdenv.lib.makeBinPath [ openssh ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Securely control a remote docker daemon CLI using ssh forwarding, no SSL setup needed";
     homepage = "https://github.com/dvddarias/rdocker";
     maintainers = [ stdenv.lib.maintainers.pneumaticat ];
diff --git a/pkgs/development/tools/react-native-debugger/default.nix b/pkgs/development/tools/react-native-debugger/default.nix
index 6ee5e884ea2db..f5174da13a1b3 100644
--- a/pkgs/development/tools/react-native-debugger/default.nix
+++ b/pkgs/development/tools/react-native-debugger/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, cairo, xorg, gdk-pixbuf, fontconfig, pango, gnome3, atk, at-spi2-atk, at-spi2-core
+{ lib, stdenv, fetchurl, unzip, cairo, xorg, gdk-pixbuf, fontconfig, pango, gnome3, atk, at-spi2-atk, at-spi2-core
 , gtk3, glib, freetype, dbus, nss, nspr, alsaLib, cups, expat, udev, makeDesktopItem
 }:
 
@@ -73,7 +73,7 @@ in stdenv.mkDerivation rec {
     categories = "Development;Debugger;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jhen0409/react-native-debugger";
     license = licenses.mit;
     description = "The standalone app based on official debugger of React Native, and includes React Inspector / Redux DevTools";
diff --git a/pkgs/development/tools/remarshal/default.nix b/pkgs/development/tools/remarshal/default.nix
index d28ca286f086d..c37779a5293bf 100644
--- a/pkgs/development/tools/remarshal/default.nix
+++ b/pkgs/development/tools/remarshal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "remarshal";
@@ -13,7 +13,7 @@ python3Packages.buildPythonApplication rec {
     pyyaml cbor2 dateutil tomlkit u-msgpack-python
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert between TOML, YAML and JSON";
     license = licenses.mit;
     homepage = "https://github.com/dbohdan/remarshal";
diff --git a/pkgs/development/tools/renderizer/default.nix b/pkgs/development/tools/renderizer/default.nix
index 2b2c57135cb01..747e80adf4f22 100644
--- a/pkgs/development/tools/renderizer/default.nix
+++ b/pkgs/development/tools/renderizer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "renderizer";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI to render Go template text files";
     inherit (src.meta) homepage;
     license = licenses.gpl3;
diff --git a/pkgs/development/tools/reno/default.nix b/pkgs/development/tools/reno/default.nix
index b05bb2cd26a30..17a334aba205e 100644
--- a/pkgs/development/tools/reno/default.nix
+++ b/pkgs/development/tools/reno/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , git
 , gnupg1
 , python3Packages
@@ -49,7 +49,7 @@ with python3Packages; buildPythonApplication rec {
     $out/bin/reno -h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Release Notes Manager";
     homepage = "https://docs.openstack.org/reno/latest";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/rep/default.nix b/pkgs/development/tools/rep/default.nix
index d24056f1d02b9..bc73c39277714 100644
--- a/pkgs/development/tools/rep/default.nix
+++ b/pkgs/development/tools/rep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, asciidoc-full }:
+{ lib, stdenv, fetchFromGitHub, asciidoc-full }:
 
 stdenv.mkDerivation rec {
   pname = "rep";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   '';
   makeFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Single-shot nREPL client";
     homepage = "https://github.com/eraserhd/rep";
     license = licenses.epl10;
diff --git a/pkgs/development/tools/repository-managers/nexus/default.nix b/pkgs/development/tools/repository-managers/nexus/default.nix
index 1b4509a4057b7..ad83b0f30c7ae 100644
--- a/pkgs/development/tools/repository-managers/nexus/default.nix
+++ b/pkgs/development/tools/repository-managers/nexus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre_headless, gawk }:
+{ lib, stdenv, fetchurl, makeWrapper, jre_headless, gawk }:
 
 stdenv.mkDerivation rec {
   pname = "nexus";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Repository manager for binary software components";
     homepage = "http://www.sonatype.org/nexus";
     license = licenses.epl10;
diff --git a/pkgs/development/tools/richgo/default.nix b/pkgs/development/tools/richgo/default.nix
index 441c0d8bdf1da..1013c4aa8b439 100644
--- a/pkgs/development/tools/richgo/default.nix
+++ b/pkgs/development/tools/richgo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "richgo";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enrich `go test` outputs with text decorations";
     homepage = "https://github.com/kyoh86/richgo";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rucksack/default.nix b/pkgs/development/tools/rucksack/default.nix
index c6da50288a794..1aad7a5c8da1b 100644
--- a/pkgs/development/tools/rucksack/default.nix
+++ b/pkgs/development/tools/rucksack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, liblaxjson, cmake, freeimage }:
+{ lib, stdenv, fetchFromGitHub, liblaxjson, cmake, freeimage }:
 
 stdenv.mkDerivation rec {
   version = "3.1.0";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ liblaxjson freeimage ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Texture packer and resource bundler";
     platforms = [ "i686-linux" "x86_64-linux" ]; # fails on Darwin and AArch64
     homepage = "https://github.com/andrewrk/rucksack";
diff --git a/pkgs/development/tools/run/default.nix b/pkgs/development/tools/run/default.nix
index 7ec08d02020ad..a0c169d846610 100644
--- a/pkgs/development/tools/run/default.nix
+++ b/pkgs/development/tools/run/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 buildGoModule rec {
   pname = "run";
   version = "0.7.2";
@@ -14,7 +14,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easily manage and invoke small scripts and wrappers";
     homepage    = "https://github.com/TekWizely/run";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/rund/default.nix b/pkgs/development/tools/rund/default.nix
index 9a7ac0b63244a..0752f803c3c91 100644
--- a/pkgs/development/tools/rund/default.nix
+++ b/pkgs/development/tools/rund/default.nix
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     mv $NIX_BUILD_TOP/rund $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A compiler-wrapper that runs and caches D programs";
     homepage = "https://github.com/dragon-lang/rund";
     license = lib.licenses.boost;
diff --git a/pkgs/development/tools/rust/bindgen/default.nix b/pkgs/development/tools/rust/bindgen/default.nix
index 01e29036dbc73..0330edb4804be 100644
--- a/pkgs/development/tools/rust/bindgen/default.nix
+++ b/pkgs/development/tools/rust/bindgen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, clang, llvmPackages, rustfmt, writeScriptBin,
+{ lib, stdenv, fetchFromGitHub, rustPlatform, clang, llvmPackages, rustfmt, writeScriptBin,
   runtimeShell }:
 
 rustPlatform.buildRustPackage rec {
@@ -50,7 +50,7 @@ rustPlatform.buildRustPackage rec {
     patchShebangs .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically generates Rust FFI bindings to C (and some C++) libraries";
     longDescription = ''
       Bindgen takes a c or c++ header file and turns them into
diff --git a/pkgs/development/tools/rust/cargo-asm/default.nix b/pkgs/development/tools/rust/cargo-asm/default.nix
index 76b49056a3f2b..490fa9e09c37c 100644
--- a/pkgs/development/tools/rust/cargo-asm/default.nix
+++ b/pkgs/development/tools/rust/cargo-asm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-asm";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
   # LLVM/compiler versions.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display the assembly or LLVM-IR generated for Rust source code";
     homepage = "https://github.com/gnzlbg/cargo-asm";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rust/cargo-cache/default.nix b/pkgs/development/tools/rust/cargo-cache/default.nix
index 3271e7951faca..ade568df67418 100644
--- a/pkgs/development/tools/rust/cargo-cache/default.nix
+++ b/pkgs/development/tools/rust/cargo-cache/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, libiconv, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, libiconv, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-cache";
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
 
   checkFlagsArray = [ "offline_tests" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manage cargo cache (\${CARGO_HOME}, ~/.cargo/), print sizes of dirs and remove dirs selectively";
     homepage = "https://github.com/matthiaskrgr/cargo-cache";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/development/tools/rust/cargo-crev/default.nix b/pkgs/development/tools/rust/cargo-crev/default.nix
index 6c85a52380399..29d8dfdead543 100644
--- a/pkgs/development/tools/rust/cargo-crev/default.nix
+++ b/pkgs/development/tools/rust/cargo-crev/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , perl
@@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = [ openssl ] ++ stdenv.lib.optionals stdenv.isDarwin [ Security libiconv curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cryptographically verifiable code review system for the cargo (Rust) package manager";
     homepage = "https://github.com/crev-dev/cargo-crev";
     license = with licenses; [ asl20 mit mpl20 ];
diff --git a/pkgs/development/tools/rust/cargo-fund/default.nix b/pkgs/development/tools/rust/cargo-fund/default.nix
index 06f99268d0b7a..4e30ea48272d1 100644
--- a/pkgs/development/tools/rust/cargo-fund/default.nix
+++ b/pkgs/development/tools/rust/cargo-fund/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, rustPlatform, Security, curl, openssl, libiconv }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, rustPlatform, Security, curl, openssl, libiconv }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-fund";
@@ -20,7 +20,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = [ openssl ] ++ stdenv.lib.optionals stdenv.isDarwin [ Security libiconv curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Discover funding links for your project's dependencies";
     homepage = "https://github.com/acfoltzer/cargo-fund";
     license = with licenses; [ mit /* or */ asl20 ];
diff --git a/pkgs/development/tools/rust/cargo-fuzz/default.nix b/pkgs/development/tools/rust/cargo-fuzz/default.nix
index 14c849ac0afe6..904ba6efb52b5 100644
--- a/pkgs/development/tools/rust/cargo-fuzz/default.nix
+++ b/pkgs/development/tools/rust/cargo-fuzz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-fuzz";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line helpers for fuzzing";
     homepage = "https://github.com/rust-fuzz/cargo-fuzz";
     license = with licenses; [ mit asl20 ];
diff --git a/pkgs/development/tools/rust/cargo-generate/default.nix b/pkgs/development/tools/rust/cargo-generate/default.nix
index 5f803635dd2e4..21b986f9a5daf 100644
--- a/pkgs/development/tools/rust/cargo-generate/default.nix
+++ b/pkgs/development/tools/rust/cargo-generate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security, openssl, pkgconfig, libiconv, curl }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security, openssl, pkgconfig, libiconv, curl }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-generate";
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
     git config --global user.email nixbld@localhost.localnet
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "cargo, make me a project";
     homepage = "https://github.com/ashleygwilliams/cargo-generate";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/rust/cargo-make/default.nix b/pkgs/development/tools/rust/cargo-make/default.nix
index 881a53872c96f..e10590f5e593e 100644
--- a/pkgs/development/tools/rust/cargo-make/default.nix
+++ b/pkgs/development/tools/rust/cargo-make/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, runCommand, fetchCrate, rustPlatform, Security, openssl, pkg-config
+{ lib, stdenv, fetchurl, runCommand, fetchCrate, rustPlatform, Security, openssl, pkg-config
 , SystemConfiguration
 }:
 
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
   #   https://travis-ci.org/sagiegurari/cargo-make
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Rust task runner and build tool";
     homepage = "https://github.com/sagiegurari/cargo-make";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/rust/cargo-raze/default.nix b/pkgs/development/tools/rust/cargo-raze/default.nix
index 8df03a4bd15cf..6f06648a057a1 100644
--- a/pkgs/development/tools/rust/cargo-raze/default.nix
+++ b/pkgs/development/tools/rust/cargo-raze/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform
+{ lib, stdenv, fetchFromGitHub, rustPlatform
 , pkgconfig, curl, libgit2, openssl, Security }:
 
 rustPlatform.buildRustPackage rec {
@@ -21,7 +21,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate Bazel BUILD files from Cargo dependencies";
     homepage = "https://github.com/google/cargo-raze";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/rust/cargo-sweep/default.nix b/pkgs/development/tools/rust/cargo-sweep/default.nix
index 72883ab4508e4..210449a72300a 100644
--- a/pkgs/development/tools/rust/cargo-sweep/default.nix
+++ b/pkgs/development/tools/rust/cargo-sweep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-sweep";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1sxjc64g8h77a3dvzb99f1f72zrak1nh4jgfjfkw4yc4dhkpyrmz";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Cargo subcommand for cleaning up unused build files generated by Cargo";
     homepage = "https://github.com/holmgr/cargo-sweep";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rust/cargo-sync-readme/default.nix b/pkgs/development/tools/rust/cargo-sync-readme/default.nix
index f42868826d554..45ea6c430d15a 100644
--- a/pkgs/development/tools/rust/cargo-sync-readme/default.nix
+++ b/pkgs/development/tools/rust/cargo-sync-readme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-sync-readme";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1x15q6wv5278hm3ns2wmw4i8602g35y1jyv1b8wa5i4dnh52dj83";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cargo plugin that generates a Markdown section in your README based on your Rust documentation";
     homepage = "https://github.com/phaazon/cargo-sync-readme";
     license = licenses.bsd3;
diff --git a/pkgs/development/tools/rust/cargo-udeps/default.nix b/pkgs/development/tools/rust/cargo-udeps/default.nix
index 840f2ae27c3c4..df30ec5d3604a 100644
--- a/pkgs/development/tools/rust/cargo-udeps/default.nix
+++ b/pkgs/development/tools/rust/cargo-udeps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, pkgconfig, openssl, CoreServices, Security, libiconv }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, pkgconfig, openssl, CoreServices, Security, libiconv }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-udeps";
@@ -21,7 +21,7 @@ rustPlatform.buildRustPackage rec {
   # Requires network access
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Find unused dependencies in Cargo.toml";
     homepage = "https://github.com/est31/cargo-udeps";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rust/cargo-wipe/default.nix b/pkgs/development/tools/rust/cargo-wipe/default.nix
index 1ad0fbbb4b012..7be91e69f9d78 100644
--- a/pkgs/development/tools/rust/cargo-wipe/default.nix
+++ b/pkgs/development/tools/rust/cargo-wipe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , nix-update-script
@@ -23,7 +23,7 @@ rustPlatform.buildRustPackage rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''Cargo subcommand "wipe": recursively finds and optionally wipes all "target" or "node_modules" folders'';
     homepage = "https://github.com/mihai-dinculescu/cargo-wipe";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/tools/rust/cargo-xbuild/default.nix b/pkgs/development/tools/rust/cargo-xbuild/default.nix
index 477f26e8b8191..2e800402c1dd7 100644
--- a/pkgs/development/tools/rust/cargo-xbuild/default.nix
+++ b/pkgs/development/tools/rust/cargo-xbuild/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-xbuild";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1gcixzxca1yi4rvy55s986my6j0vx7n6fm1g5r4v4w0zgzlz4d89";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically cross-compiles the sysroot crates core, compiler_builtins, and alloc";
     homepage = "https://github.com/rust-osdev/cargo-xbuild";
     license = with licenses; [ mit asl20 ];
diff --git a/pkgs/development/tools/rust/cbindgen/default.nix b/pkgs/development/tools/rust/cbindgen/default.nix
index 0b557af425850..db2a1c4c6607b 100644
--- a/pkgs/development/tools/rust/cbindgen/default.nix
+++ b/pkgs/development/tools/rust/cbindgen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "rust-cbindgen";
@@ -20,7 +20,7 @@ rustPlatform.buildRustPackage rec {
     "--skip test_expand"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A project for generating C bindings from Rust code";
     homepage = "https://github.com/eqrion/cbindgen";
     license = licenses.mpl20;
diff --git a/pkgs/development/tools/rust/maturin/default.nix b/pkgs/development/tools/rust/maturin/default.nix
index 723ea94152ca6..882622bff7b88 100644
--- a/pkgs/development/tools/rust/maturin/default.nix
+++ b/pkgs/development/tools/rust/maturin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, dbus, gmp, openssl, pkgconfig
+{ lib, stdenv, fetchFromGitHub, rustPlatform, dbus, gmp, openssl, pkgconfig
 , darwin }:
 
 let
@@ -25,7 +25,7 @@ in rustPlatform.buildRustPackage rec {
   # Requires network access, fails in sandbox.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Build and publish crates with pyo3 bindings as python packages";
     homepage = "https://github.com/PyO3/maturin";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rust/racer/default.nix b/pkgs/development/tools/rust/racer/default.nix
index 7de30855dd37f..d5482d58457c3 100644
--- a/pkgs/development/tools/rust/racer/default.nix
+++ b/pkgs/development/tools/rust/racer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, makeWrapper, substituteAll, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, makeWrapper, substituteAll, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "racer";
@@ -39,7 +39,7 @@ rustPlatform.buildRustPackage rec {
     $out/bin/racer --version
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility intended to provide Rust code completion for editors and IDEs";
     homepage = "https://github.com/racer-rust/racer";
     license = licenses.mit;
diff --git a/pkgs/development/tools/rust/racerd/default.nix b/pkgs/development/tools/rust/racerd/default.nix
index 26e2a5ba50e32..19cc3fdf58046 100644
--- a/pkgs/development/tools/rust/racerd/default.nix
+++ b/pkgs/development/tools/rust/racerd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, rustPlatform, makeWrapper, Security }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, rustPlatform, makeWrapper, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "racerd";
@@ -36,7 +36,7 @@ rustPlatform.buildRustPackage rec {
     wrapProgram $out/bin/racerd --set-default RUST_SRC_PATH "$RUST_SRC_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true;
     description = "JSON/HTTP Server based on racer for adding Rust support to editors and IDEs";
     homepage = "https://github.com/jwilm/racerd";
diff --git a/pkgs/development/tools/rust/rust-analyzer/generic.nix b/pkgs/development/tools/rust/rust-analyzer/generic.nix
index 1bab5b9518373..10f0c6b26ad75 100644
--- a/pkgs/development/tools/rust/rust-analyzer/generic.nix
+++ b/pkgs/development/tools/rust/rust-analyzer/generic.nix
@@ -41,7 +41,7 @@ rustPlatform.buildRustPackage {
     runHook postInstallCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An experimental modular compiler frontend for the Rust language";
     homepage = "https://github.com/rust-analyzer/rust-analyzer";
     license = with licenses; [ mit asl20 ];
diff --git a/pkgs/development/tools/rust/rustup/default.nix b/pkgs/development/tools/rust/rustup/default.nix
index f846ed5f02e1e..dcb435d514031 100644
--- a/pkgs/development/tools/rust/rustup/default.nix
+++ b/pkgs/development/tools/rust/rustup/default.nix
@@ -70,7 +70,7 @@ rustPlatform.buildRustPackage rec {
     $out/bin/rustup completions zsh cargo >  "$out/share/zsh/site-functions/_cargo"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Rust toolchain installer";
     homepage = "https://www.rustup.rs/";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/development/tools/rust/svd2rust/default.nix b/pkgs/development/tools/rust/svd2rust/default.nix
index 348fe6d9c71fb..97da80562905b 100644
--- a/pkgs/development/tools/rust/svd2rust/default.nix
+++ b/pkgs/development/tools/rust/svd2rust/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 with rustPlatform;
 
@@ -19,7 +19,7 @@ buildRustPackage rec {
   # doc tests fail due to missing dependency
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate Rust register maps (`struct`s) from SVD files";
     homepage = "https://github.com/rust-embedded/svd2rust";
     license = with licenses; [ mit asl20 ];
diff --git a/pkgs/development/tools/sassc/default.nix b/pkgs/development/tools/sassc/default.nix
index 373a7ea66658b..d9662cd7ddb91 100644
--- a/pkgs/development/tools/sassc/default.nix
+++ b/pkgs/development/tools/sassc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, libsass }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, libsass }:
 
 stdenv.mkDerivation rec {
   pname = "sassc";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libsass ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A front-end for libsass";
     homepage = "https://github.com/sass/sassc/";
     license = licenses.mit;
diff --git a/pkgs/development/tools/scalafix/default.nix b/pkgs/development/tools/scalafix/default.nix
index aa3a6cfb0dcf3..00fda8bfc3682 100644
--- a/pkgs/development/tools/scalafix/default.nix
+++ b/pkgs/development/tools/scalafix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, jdk, jre, coursier, makeWrapper }:
+{ lib, stdenv, jdk, jre, coursier, makeWrapper }:
 
 let
   baseName = "scalafix";
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
     $out/bin/${baseName} --version | grep -q "${version}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Refactoring and linting tool for Scala";
     homepage = "https://scalacenter.github.io/scalafix/";
     license = licenses.bsd3;
diff --git a/pkgs/development/tools/scalafmt/default.nix b/pkgs/development/tools/scalafmt/default.nix
index 0f14f52295e88..45efd813a38b7 100644
--- a/pkgs/development/tools/scalafmt/default.nix
+++ b/pkgs/development/tools/scalafmt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, jdk, jre, coursier, makeWrapper }:
+{ lib, stdenv, jdk, jre, coursier, makeWrapper }:
 
 let
   baseName = "scalafmt";
@@ -35,7 +35,7 @@ stdenv.mkDerivation {
     $out/bin/${baseName} --version | grep -q "${version}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Opinionated code formatter for Scala";
     homepage = "http://scalameta.org/scalafmt";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/selenium/chromedriver/default.nix b/pkgs/development/tools/selenium/chromedriver/default.nix
index de1c9c9c11aab..5f01b98e8d113 100644
--- a/pkgs/development/tools/selenium/chromedriver/default.nix
+++ b/pkgs/development/tools/selenium/chromedriver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, makeWrapper
+{ lib, stdenv, fetchurl, unzip, makeWrapper
 , cairo, fontconfig, freetype, gdk-pixbuf, glib
 , glibc, gtk2, libX11, nspr, nss, pango, gconf
 , libxcb, libXi, libXrender, libXext
@@ -49,7 +49,7 @@ in stdenv.mkDerivation rec {
     wrapProgram "$out/bin/chromedriver" --prefix LD_LIBRARY_PATH : "${libs}:\$LD_LIBRARY_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://chromedriver.chromium.org/";
     description = "A WebDriver server for running Selenium tests on Chrome";
     longDescription = ''
diff --git a/pkgs/development/tools/sigrok-cli/default.nix b/pkgs/development/tools/sigrok-cli/default.nix
index b71e9fb3a99cb..79b4a6acdf63d 100644
--- a/pkgs/development/tools/sigrok-cli/default.nix
+++ b/pkgs/development/tools/sigrok-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, glib, libsigrok, libsigrokdecode }:
+{ lib, stdenv, fetchurl, pkgconfig, glib, libsigrok, libsigrokdecode }:
 
 stdenv.mkDerivation rec {
   name = "sigrok-cli-0.7.1";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ glib libsigrok libsigrokdecode ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line frontend for the sigrok signal analysis software suite";
     homepage = "https://sigrok.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/development/tools/simavr/default.nix b/pkgs/development/tools/simavr/default.nix
index 83ae00ce7b665..5fd99f1407483 100644
--- a/pkgs/development/tools/simavr/default.nix
+++ b/pkgs/development/tools/simavr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libelf, which, pkgconfig, freeglut
+{ lib, stdenv, fetchFromGitHub, libelf, which, pkgconfig, freeglut
 , avrgcc, avrlibc
 , libGLU, libGL
 , GLUT }:
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
   doCheck = true;
   checkTarget = "-C tests run_tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lean and mean Atmel AVR simulator";
     homepage    = "https://github.com/buserror/simavr";
     license     = licenses.gpl3;
diff --git a/pkgs/development/tools/skopeo/default.nix b/pkgs/development/tools/skopeo/default.nix
index db5f392b2ce69..147ab877d6b5a 100644
--- a/pkgs/development/tools/skopeo/default.nix
+++ b/pkgs/development/tools/skopeo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , gpgme
@@ -47,7 +47,7 @@ buildGoModule rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ fuse-overlayfs ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line utility for various operations on container images and image repositories";
     homepage = "https://github.com/containers/skopeo";
     maintainers = with maintainers; [ lewo ] ++ teams.podman.members;
diff --git a/pkgs/development/tools/so/default.nix b/pkgs/development/tools/so/default.nix
index 0ee2359c8413c..08481169dcdd0 100644
--- a/pkgs/development/tools/so/default.nix
+++ b/pkgs/development/tools/so/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, openssl, pkg-config, libiconv, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, openssl, pkg-config, libiconv, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "so";
@@ -18,7 +18,7 @@ rustPlatform.buildRustPackage rec {
     libiconv Security
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A TUI interface to the StackExchange network";
     homepage = "https://github.com/samtay/so";
     license = licenses.mit;
diff --git a/pkgs/development/tools/sourcetrail/default.nix b/pkgs/development/tools/sourcetrail/default.nix
index 91653d3773e16..d1e26662f0c24 100644
--- a/pkgs/development/tools/sourcetrail/default.nix
+++ b/pkgs/development/tools/sourcetrail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, callPackage, writeScript, cmake, wrapQtAppsHook
+{ lib, stdenv, fetchFromGitHub, callPackage, writeScript, cmake, wrapQtAppsHook
 , boost, qt5, llvmPackages, gcc, jdk, pythonPackages, desktop-file-utils
 , shared-mime-info, imagemagick, which, coreutils, maven, fetchpatch }:
 
@@ -203,7 +203,7 @@ stdenv.mkDerivation rec {
   # FIXME: some test cases are disabled in the patch phase
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.sourcetrail.com";
     description = "A cross-platform source explorer for C/C++ and Java";
     platforms = platforms.all;
diff --git a/pkgs/development/tools/sourcetrail/jedi.nix b/pkgs/development/tools/sourcetrail/jedi.nix
index 14a40a6e6db46..fa25604f9fc5a 100644
--- a/pkgs/development/tools/sourcetrail/jedi.nix
+++ b/pkgs/development/tools/sourcetrail/jedi.nix
@@ -1,6 +1,6 @@
 # Taken from a past commit of nixpkgs
 
-{ stdenv, buildPythonPackage, fetchPypi, pytest, glibcLocales, tox, pytestcov, parso }:
+{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, glibcLocales, tox, pytestcov, parso }:
 
 buildPythonPackage rec {
   pname = "jedi";
@@ -28,7 +28,7 @@ buildPythonPackage rec {
   # tox required for tests: https://github.com/davidhalter/jedi/issues/808
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/davidhalter/jedi";
     description = "An autocompletion tool for Python that can be used for text editors";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/development/tools/spirv-tools/default.nix b/pkgs/development/tools/spirv-tools/default.nix
index 6157e3fa0fd4b..57f04b00c0d20 100644
--- a/pkgs/development/tools/spirv-tools/default.nix
+++ b/pkgs/development/tools/spirv-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, python3, spirv-headers }:
+{ lib, stdenv, fetchFromGitHub, cmake, python3, spirv-headers }:
 let
   # Update spirv-headers rev in lockstep according to DEPs file
   version = "2020.2";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DSPIRV-Headers_SOURCE_DIR=${spirv-headers.src}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "The SPIR-V Tools project provides an API and commands for processing SPIR-V modules";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/spring-boot-cli/default.nix b/pkgs/development/tools/spring-boot-cli/default.nix
index 38573e0751463..5bc89e839e929 100644
--- a/pkgs/development/tools/spring-boot-cli/default.nix
+++ b/pkgs/development/tools/spring-boot-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jdk, makeWrapper, installShellFiles, coreutils }:
+{ lib, stdenv, fetchzip, jdk, makeWrapper, installShellFiles, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "spring-boot-cli";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       CLI which makes it easy to create spring-based applications
     '';
diff --git a/pkgs/development/tools/sqsh/default.nix b/pkgs/development/tools/sqsh/default.nix
index d6087cd02244f..6b408592a0d03 100644
--- a/pkgs/development/tools/sqsh/default.nix
+++ b/pkgs/development/tools/sqsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, freetds, readline, libiconv }:
+{ lib, stdenv, fetchurl, autoreconfHook, freetds, readline, libiconv }:
 
 let
   mainVersion = "2.5";
@@ -27,7 +27,7 @@ in stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tool for querying Sybase/MSSQL databases";
     longDescription = ''
       Sqsh (pronounced skwish) is short for SQshelL (pronounced s-q-shell),
diff --git a/pkgs/development/tools/sslmate/default.nix b/pkgs/development/tools/sslmate/default.nix
index a6d1ce55fdb72..cdf2242bdbaa2 100644
--- a/pkgs/development/tools/sslmate/default.nix
+++ b/pkgs/development/tools/sslmate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, makeWrapper, openssl }:
+{ lib, stdenv, fetchurl, perlPackages, makeWrapper, openssl }:
 
 stdenv.mkDerivation rec {
   name = "sslmate-1.7.1";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${openssl.bin}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sslmate.com";
     maintainers = [ maintainers.domenkozar ];
     description = "Easy to buy, deploy, and manage your SSL certs";
diff --git a/pkgs/development/tools/stagit/default.nix b/pkgs/development/tools/stagit/default.nix
index dacee9aa78e15..1cabcfe044f32 100644
--- a/pkgs/development/tools/stagit/default.nix
+++ b/pkgs/development/tools/stagit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libgit2, fetchgit }:
+{ lib, stdenv, libgit2, fetchgit }:
 
 stdenv.mkDerivation rec {
   pname = "stagit";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libgit2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "git static site generator";
     homepage = "https://git.codemadness.org/stagit/";
     license = licenses.mit;
diff --git a/pkgs/development/tools/sunxi-tools/default.nix b/pkgs/development/tools/sunxi-tools/default.nix
index 5a530c6e9f18c..009172d772519 100644
--- a/pkgs/development/tools/sunxi-tools/default.nix
+++ b/pkgs/development/tools/sunxi-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libusb1, zlib }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libusb1, zlib }:
 
 stdenv.mkDerivation {
   name = "sunxi-tools-20181113";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   installTargets = [ "install-tools" "install-misc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for Allwinner SoC devices";
     homepage = "http://linux-sunxi.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/development/tools/textql/default.nix b/pkgs/development/tools/textql/default.nix
index 4cdb5b8dd1634..7dc899c4fc46d 100644
--- a/pkgs/development/tools/textql/default.nix
+++ b/pkgs/development/tools/textql/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, sqlite }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, sqlite }:
 
 buildGoPackage rec {
   pname = "textql";
@@ -24,7 +24,7 @@ buildGoPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Execute SQL against structured text like CSV or TSV";
     homepage = "https://github.com/dinedal/textql";
     license = licenses.mit;
diff --git a/pkgs/development/tools/the-way/default.nix b/pkgs/development/tools/the-way/default.nix
index 5506201b74273..7eec364c47b12 100644
--- a/pkgs/development/tools/the-way/default.nix
+++ b/pkgs/development/tools/the-way/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, installShellFiles, AppKit, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles, AppKit, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "the-way";
@@ -27,7 +27,7 @@ rustPlatform.buildRustPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal code snippets manager";
     homepage = "https://github.com/out-of-cheese-error/the-way";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/tools/thrust/default.nix b/pkgs/development/tools/thrust/default.nix
index a0bc39f2816d7..44dfa1a4ba11c 100644
--- a/pkgs/development/tools/thrust/default.nix
+++ b/pkgs/development/tools/thrust/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildEnv, makeWrapper, glib, alsaLib , dbus, gtk2, atk
+{ lib, stdenv, fetchurl, buildEnv, makeWrapper, glib, alsaLib , dbus, gtk2, atk
 , pango, freetype, fontconfig, gdk-pixbuf , cairo, cups, expat, nspr, gconf, nss
 , xorg, libcap, unzip
 }:
@@ -37,7 +37,7 @@ in stdenv.mkDerivation rec {
     ln -s $out/libexec/thrust/thrust_shell $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chromium-based cross-platform / cross-language application framework";
     homepage = "https://github.com/breach/thrust";
     license = licenses.mit;
diff --git a/pkgs/development/tools/toluapp/default.nix b/pkgs/development/tools/toluapp/default.nix
index 8f4e66703478b..5f938547cdd87 100644
--- a/pkgs/development/tools/toluapp/default.nix
+++ b/pkgs/development/tools/toluapp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, sconsPackages, lua }:
+{ lib, stdenv, fetchFromGitHub, sconsPackages, lua }:
 
 stdenv.mkDerivation rec {
   version = "1.0.93";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       --replace /usr/local $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to integrate C/Cpp code with Lua";
     homepage = "http://www.codenix.com/~tolua/";
     license = licenses.mit;
diff --git a/pkgs/development/tools/tracy/default.nix b/pkgs/development/tools/tracy/default.nix
index 4efef71f6ad07..927b792b6ba42 100644
--- a/pkgs/development/tools/tracy/default.nix
+++ b/pkgs/development/tools/tracy/default.nix
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     install_name_tool -change libcapstone.4.dylib ${capstone}/lib/libcapstone.4.dylib $out/bin/Tracy
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A real time, nanosecond resolution, remote telemetry frame profiler for games and other applications";
     homepage = "https://github.com/wolfpld/tracy";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/development/tools/tradcpp/default.nix b/pkgs/development/tools/tradcpp/default.nix
index ddcdc38a4fb97..dc7156febe983 100644
--- a/pkgs/development/tools/tradcpp/default.nix
+++ b/pkgs/development/tools/tradcpp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf }:
+{ lib, stdenv, fetchurl, autoconf }:
 
 stdenv.mkDerivation {
   name = "tradcpp-0.5.2";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     ./aarch64.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A traditional (K&R-style) C macro preprocessor";
     platforms = platforms.all;
     license = licenses.bsd2;
diff --git a/pkgs/development/tools/trellis/default.nix b/pkgs/development/tools/trellis/default.nix
index 974562a8ef69d..003e3cec9cee3 100644
--- a/pkgs/development/tools/trellis/default.nix
+++ b/pkgs/development/tools/trellis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , python3, boost
 , cmake
 }:
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     cd libtrellis
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description     = "Documentation and bitstream tools for Lattice ECP5 FPGAs";
     longDescription = ''
       Project Trellis documents the Lattice ECP5 architecture
diff --git a/pkgs/development/tools/udis86/default.nix b/pkgs/development/tools/udis86/default.nix
index 6996d5bf13fac..22977d6ea9548 100644
--- a/pkgs/development/tools/udis86/default.nix
+++ b/pkgs/development/tools/udis86/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, python }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, python }:
 
 stdenv.mkDerivation rec {
   pname = "udis86";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "bin" "out" "dev" "lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://udis86.sourceforge.net";
     license = licenses.bsd2;
     maintainers = with maintainers; [ timor ];
diff --git a/pkgs/development/tools/unity3d/default.nix b/pkgs/development/tools/unity3d/default.nix
index dfb5f6abf4814..9441a3217b77a 100644
--- a/pkgs/development/tools/unity3d/default.nix
+++ b/pkgs/development/tools/unity3d/default.nix
@@ -129,7 +129,7 @@ in stdenv.mkDerivation {
   dontStrip = true;
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://unity3d.com/";
     description = "Game development tool";
     longDescription = ''
diff --git a/pkgs/development/tools/unityhub/default.nix b/pkgs/development/tools/unityhub/default.nix
index 85b7a704b9ccd..baa89a33ad910 100644
--- a/pkgs/development/tools/unityhub/default.nix
+++ b/pkgs/development/tools/unityhub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, appimageTools, gsettings-desktop-schemas, gtk3 }:
+{ lib, stdenv, fetchurl, appimageTools, gsettings-desktop-schemas, gtk3 }:
 
 let
   version = "2.3.2";
@@ -26,7 +26,7 @@ in appimageTools.wrapType2 rec {
     sha256 = "07nfyfp9apshqarc6pgshsczila6x4943hiyyizc55kp85aw0imn";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://unity3d.com/";
     description = "Game development tool";
     longDescription = ''
diff --git a/pkgs/development/tools/vala-language-server/default.nix b/pkgs/development/tools/vala-language-server/default.nix
index f26615e26b7ab..696776a69720d 100644
--- a/pkgs/development/tools/vala-language-server/default.nix
+++ b/pkgs/development/tools/vala-language-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     vala
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Code Intelligence for Vala & Genie";
     homepage = "https://github.com/benwaffle/vala-language-server";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/development/tools/vala-lint/default.nix b/pkgs/development/tools/vala-lint/default.nix
index 378bc935e22ad..73ab21716b7e4 100644
--- a/pkgs/development/tools/vala-lint/default.nix
+++ b/pkgs/development/tools/vala-lint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , glib
 , meson
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
   # See https://github.com/vala-lang/vala-lint/issues/133
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/vala-lang/vala-lint";
     description = "Check Vala code files for code-style errors";
     longDescription = ''
diff --git a/pkgs/development/tools/vcstool/default.nix b/pkgs/development/tools/vcstool/default.nix
index e99f7dca9bf5a..95ebfcf64b4c0 100644
--- a/pkgs/development/tools/vcstool/default.nix
+++ b/pkgs/development/tools/vcstool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages
+{ lib, stdenv, python3Packages
 , git, breezy, subversion }:
 
 with python3Packages;
@@ -18,7 +18,7 @@ buildPythonApplication rec {
 
   doCheck = false; # requires network
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a command line tool to invoke vcs commands on multiple repositories";
     homepage = "https://github.com/dirk-thomas/vcstool";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/vend/default.nix b/pkgs/development/tools/vend/default.nix
index ef59ea8dd65c3..cfadf694320e8 100644
--- a/pkgs/development/tools/vend/default.nix
+++ b/pkgs/development/tools/vend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "vend";
@@ -28,7 +28,7 @@ buildGoModule rec {
 
   vendorSha256 = null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nomad-software/vend";
     description = "A utility which vendors go code including c dependencies";
     maintainers = with maintainers; [ c00w mic92 zowoq ];
diff --git a/pkgs/development/tools/vulkan-validation-layers/default.nix b/pkgs/development/tools/vulkan-validation-layers/default.nix
index 70a5f784afe36..48e3b39b9557b 100644
--- a/pkgs/development/tools/vulkan-validation-layers/default.nix
+++ b/pkgs/development/tools/vulkan-validation-layers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , writeText
@@ -97,7 +97,7 @@ stdenv.mkDerivation rec {
     sed "s|\([[:space:]]*set(INSTALL_DEFINES \''${INSTALL_DEFINES} -DRELATIVE_LAYER_BINARY=\"\)\(\$<TARGET_FILE_NAME:\''${TARGET_NAME}>\")\)|\1$out/lib/\2|" -i layers/CMakeLists.txt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The official Khronos Vulkan validation layers";
     homepage    = "https://github.com/KhronosGroup/Vulkan-ValidationLayers";
     platforms   = platforms.linux;
diff --git a/pkgs/development/tools/vultr-cli/default.nix b/pkgs/development/tools/vultr-cli/default.nix
index 58ee064ad5529..23dda32b72328 100644
--- a/pkgs/development/tools/vultr-cli/default.nix
+++ b/pkgs/development/tools/vultr-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "vultr-cli";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official command line tool for Vultr services";
     homepage = "https://github.com/vultr/vultr-cli";
     license = licenses.asl20;
diff --git a/pkgs/development/tools/wabt/default.nix b/pkgs/development/tools/wabt/default.nix
index b910a31e1552a..27b11870a8990 100644
--- a/pkgs/development/tools/wabt/default.nix
+++ b/pkgs/development/tools/wabt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchFromGitHub, cmake, python3, substituteAll }:
+{ lib, stdenv, fetchpatch, fetchFromGitHub, cmake, python3, substituteAll }:
 
 stdenv.mkDerivation rec {
   pname = "wabt";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   cmakeFlags = [ "-DBUILD_TESTS=OFF" "-DCMAKE_PROJECT_VERSION=${version}" ];
   buildInputs = [ python3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The WebAssembly Binary Toolkit";
     longDescription = ''
       WABT (pronounced "wabbit") is a suite of tools for WebAssembly, including:
diff --git a/pkgs/development/tools/wasm-pack/default.nix b/pkgs/development/tools/wasm-pack/default.nix
index 93bda0b818077..c5e5190feb37a 100644
--- a/pkgs/development/tools/wasm-pack/default.nix
+++ b/pkgs/development/tools/wasm-pack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , pkgconfig
@@ -33,7 +33,7 @@ rustPlatform.buildRustPackage rec {
   # Disabling check here to work with build sandboxing.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility that builds rust-generated WebAssembly package";
     homepage = "https://github.com/rustwasm/wasm-pack";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/development/tools/wiiload/default.nix b/pkgs/development/tools/wiiload/default.nix
index 37d909461d078..2f2fe174d14e6 100644
--- a/pkgs/development/tools/wiiload/default.nix
+++ b/pkgs/development/tools/wiiload/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, zlib }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, zlib }:
 stdenv.mkDerivation rec {
   version = "0.5.1";
   pname = "wiiload";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "./autogen.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Load homebrew apps over network/usbgecko to your Wii";
     homepage = "https://wiibrew.org/wiki/Wiiload";
     license = licenses.gpl2;
diff --git a/pkgs/development/tools/winpdb/default.nix b/pkgs/development/tools/winpdb/default.nix
index 8db0b719c67bf..4730ff676d1b1 100644
--- a/pkgs/development/tools/winpdb/default.nix
+++ b/pkgs/development/tools/winpdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages, makeDesktopItem }:
+{ lib, stdenv, fetchurl, pythonPackages, makeDesktopItem }:
 
 pythonPackages.buildPythonApplication rec {
   name = "winpdb-1.4.8";
@@ -36,7 +36,7 @@ pythonPackages.buildPythonApplication rec {
     cp artwork/winpdb-icon.svg "$out"/share/icons/winpdb.svg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Platform independent Python debugger";
     longDescription = ''
       Winpdb is a platform independent GPL Python debugger with support for
diff --git a/pkgs/development/tools/wllvm/default.nix b/pkgs/development/tools/wllvm/default.nix
index cd002bd2ef612..a3702f2e3e652 100644
--- a/pkgs/development/tools/wllvm/default.nix
+++ b/pkgs/development/tools/wllvm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   version = "1.2.8";
@@ -10,7 +10,7 @@ python3Packages.buildPythonApplication rec {
     sha256 = "1d88fzg4ba4r3hwrinnv6agiyj3xxdy4yryb8wz2ml51nc6bi591";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/travitch/whole-program-llvm";
     description = "A wrapper script to build whole-program LLVM bitcode files";
     license = licenses.mit;
diff --git a/pkgs/development/tools/wrangler/default.nix b/pkgs/development/tools/wrangler/default.nix
index 6b85e20612bfe..046905528940a 100644
--- a/pkgs/development/tools/wrangler/default.nix
+++ b/pkgs/development/tools/wrangler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl, curl, darwin, perl }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl, curl, darwin, perl }:
 
 rustPlatform.buildRustPackage rec {
   pname = "wrangler";
@@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec {
   # tries to use "/homeless-shelter" and fails
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CLI tool designed for folks who are interested in using Cloudflare Workers";
     homepage = "https://github.com/cloudflare/wrangler";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/development/tools/ws/default.nix b/pkgs/development/tools/ws/default.nix
index 4a6d8892208dc..3026289fec1ea 100644
--- a/pkgs/development/tools/ws/default.nix
+++ b/pkgs/development/tools/ws/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by https://github.com/kamilchm/go2nix v1.2.1
-{ stdenv, buildGoPackage, fetchgit }:
+{ lib, stdenv, buildGoPackage, fetchgit }:
 
 buildGoPackage rec {
   pname = "ws";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "192slrz1cj1chzmfrl0d9ai8bq6s4w0iwpvxkhxb9krga7mkp9xb";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "websocket command line tool";
     homepage    = "https://github.com/hashrocket/ws";
     license     = licenses.mit;
diff --git a/pkgs/development/tools/wxformbuilder/default.nix b/pkgs/development/tools/wxformbuilder/default.nix
index a3f8196b124ba..5c78d730d203e 100644
--- a/pkgs/development/tools/wxformbuilder/default.nix
+++ b/pkgs/development/tools/wxformbuilder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , wxGTK31
 , meson
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     wxGTK31
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RAD tool for wxWidgets GUI design";
     homepage = "https://github.com/wxFormBuilder/wxFormBuilder";
     license = licenses.gpl2;
diff --git a/pkgs/development/tools/xcbuild/default.nix b/pkgs/development/tools/xcbuild/default.nix
index f02933e921e35..abc48b41446ea 100644
--- a/pkgs/development/tools/xcbuild/default.nix
+++ b/pkgs/development/tools/xcbuild/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, fetchFromGitHub, zlib, libxml2, libpng
+{ lib, stdenv, cmake, fetchFromGitHub, zlib, libxml2, libpng
 , CoreServices, CoreGraphics, ImageIO, ninja }:
 
 let
@@ -61,7 +61,7 @@ in stdenv.mkDerivation {
   buildInputs = [ zlib libxml2 libpng ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ CoreServices CoreGraphics ImageIO ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Xcode-compatible build tool";
     homepage = "https://github.com/facebook/xcbuild";
     platforms = platforms.unix;
diff --git a/pkgs/development/tools/xib2nib/default.nix b/pkgs/development/tools/xib2nib/default.nix
index 4d62f5b857141..67900dda1406b 100644
--- a/pkgs/development/tools/xib2nib/default.nix
+++ b/pkgs/development/tools/xib2nib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pugixml, boost, PlistCpp }:
+{ lib, stdenv, fetchFromGitHub, pugixml, boost, PlistCpp }:
 
 stdenv.mkDerivation {
   name = "xib2nib-730e177";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
   buildInputs = [ PlistCpp pugixml boost ];
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ matthewbauer ];
     description = "Compiles CocoaTouch .xib files into .nib";
     license = licenses.mit;
diff --git a/pkgs/development/tools/xqilla/default.nix b/pkgs/development/tools/xqilla/default.nix
index e97a6f1cdb785..033d18608ac86 100644
--- a/pkgs/development/tools/xqilla/default.nix
+++ b/pkgs/development/tools/xqilla/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xercesc }:
+{ lib, stdenv, fetchurl, xercesc }:
 
 stdenv.mkDerivation rec {
   pname = "xqilla";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--with-xerces=${xercesc}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An XQuery and XPath 2 library and command line utility written in C++, implemented on top of the Xerces-C library";
     license     = licenses.asl20 ;
     maintainers = with maintainers; [ obadz ];
diff --git a/pkgs/development/tools/yaml2json/default.nix b/pkgs/development/tools/yaml2json/default.nix
index e1427476dd8c8..d707caaec5a7d 100644
--- a/pkgs/development/tools/yaml2json/default.nix
+++ b/pkgs/development/tools/yaml2json/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 
 buildGoPackage {
@@ -15,7 +15,7 @@ buildGoPackage {
     sha256 = "16a2sqzbam5adbhfvilnpdabzwncs7kgpr0cn4gp09h2imzsprzw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bronze1man/yaml2json";
     description = "Convert yaml to json";
     license = with licenses; [ mit ];
diff --git a/pkgs/development/tools/yarn/default.nix b/pkgs/development/tools/yarn/default.nix
index 7151c872e4d04..1868bdaf2c326 100644
--- a/pkgs/development/tools/yarn/default.nix
+++ b/pkgs/development/tools/yarn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, nodejs, fetchzip }:
+{ lib, stdenv, nodejs, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "yarn";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     ln -s $out/libexec/yarn/bin/yarn.js $out/bin/yarnpkg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://yarnpkg.com/";
     description = "Fast, reliable, and secure dependency management for javascript";
     license = licenses.bsd2;
diff --git a/pkgs/development/tools/yj/default.nix b/pkgs/development/tools/yj/default.nix
index 43771e4b67985..3244d7a0c8486 100644
--- a/pkgs/development/tools/yj/default.nix
+++ b/pkgs/development/tools/yj/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "yj";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.Version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''Convert YAML <=> TOML <=> JSON <=> HCL'';
     license = licenses.asl20;
     maintainers = with maintainers; [ Profpatsch ];
diff --git a/pkgs/development/tools/yuicompressor/default.nix b/pkgs/development/tools/yuicompressor/default.nix
index 70160c1ce6649..549cc5046c4ce 100644
--- a/pkgs/development/tools/yuicompressor/default.nix
+++ b/pkgs/development/tools/yuicompressor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 stdenv.mkDerivation rec {
   pname = "yuicompressor";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
      "-cp $out/lib/yuicompressor.jar com.yahoo.platform.yui.compressor.YUICompressor"
   '';
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A JavaScript and CSS minifier";
     homepage = "http://yui.github.io/yuicompressor/";
     license = licenses.bsd3;
diff --git a/pkgs/development/web/csslint/default.nix b/pkgs/development/web/csslint/default.nix
index a1c656fb766e2..9a8169429791c 100644
--- a/pkgs/development/web/csslint/default.nix
+++ b/pkgs/development/web/csslint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nodejs }:
+{ lib, stdenv, fetchurl, nodejs }:
 
 stdenv.mkDerivation rec {
   version = "0.10.0";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     mv $out/bin/cli.js $out/bin/csslint
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Checks CSS for syntax errors and other problems";
     longDescription = ''
       CSSLint is a tool to help point out problems with your CSS
diff --git a/pkgs/development/web/cypress/default.nix b/pkgs/development/web/cypress/default.nix
index 7802bd6ebcbf9..927414993231d 100644
--- a/pkgs/development/web/cypress/default.nix
+++ b/pkgs/development/web/cypress/default.nix
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     ln -s $out/opt/cypress/Cypress $out/bin/Cypress
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, easy and reliable testing for anything that runs in a browser";
     homepage = "https://www.cypress.io";
     license = licenses.mit;
diff --git a/pkgs/development/web/deno/default.nix b/pkgs/development/web/deno/default.nix
index 12bd54852a0b2..b669d34739e45 100644
--- a/pkgs/development/web/deno/default.nix
+++ b/pkgs/development/web/deno/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchFromGitHub
 , rust
@@ -64,7 +64,7 @@ rustPlatform.buildRustPackage rec {
 
   passthru.updateScript = ./update/update.ts;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://deno.land/";
     changelog = "${src.meta.homepage}/releases/tag/v${version}";
     description = "A secure runtime for JavaScript and TypeScript";
diff --git a/pkgs/development/web/grails/default.nix b/pkgs/development/web/grails/default.nix
index 55ec74eb1735d..0668c5107b44b 100644
--- a/pkgs/development/web/grails/default.nix
+++ b/pkgs/development/web/grails/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip
+{ lib, stdenv, fetchurl, unzip
 # If jdk is null, require JAVA_HOME in runtime environment, else store
 # JAVA_HOME=${jdk.home} into grails.
 , jdk ? null
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Full stack, web application framework for the JVM";
     longDescription = ''
       Grails is an Open Source, full stack, web application framework for the
diff --git a/pkgs/development/web/insomnia/default.nix b/pkgs/development/web/insomnia/default.nix
index 15dc040dc571c..3311253e202d2 100644
--- a/pkgs/development/web/insomnia/default.nix
+++ b/pkgs/development/web/insomnia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, fetchurl, dpkg, alsaLib, atk, cairo, cups, dbus, expat
+{ lib, stdenv, makeWrapper, fetchurl, dpkg, alsaLib, atk, cairo, cups, dbus, expat
 , fontconfig, freetype, gdk-pixbuf, glib, gnome2, pango, nspr, nss, gtk3, gtk2
 , at-spi2-atk, gsettings-desktop-schemas, gobject-introspection, wrapGAppsHook
 , libX11, libXScrnSaver, libXcomposite, libXcursor, libXdamage, libXext
@@ -81,7 +81,7 @@ in stdenv.mkDerivation rec {
     wrapProgram "$out/bin/insomnia" --prefix LD_LIBRARY_PATH : ${runtimeLibs}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://insomnia.rest/";
     description = "The most intuitive cross-platform REST API Client";
     license = licenses.mit;
diff --git a/pkgs/development/web/kcgi/default.nix b/pkgs/development/web/kcgi/default.nix
index 0ba764ddbfda7..152094b4498bf 100644
--- a/pkgs/development/web/kcgi/default.nix
+++ b/pkgs/development/web/kcgi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, fetchFromGitHub, libbsd }:
+{ lib, stdenv, pkgconfig, fetchFromGitHub, libbsd }:
 
 stdenv.mkDerivation rec {
   pname = "kcgi";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kristaps.bsd.lv/kcgi";
     description = "Minimal CGI and FastCGI library for C/C++";
     license = licenses.isc;
diff --git a/pkgs/development/web/kore/default.nix b/pkgs/development/web/kore/default.nix
index 5a6b9930d21e0..d3efdc53ca464 100644
--- a/pkgs/development/web/kore/default.nix
+++ b/pkgs/development/web/kore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, curl, postgresql, yajl }:
+{ lib, stdenv, fetchFromGitHub, openssl, curl, postgresql, yajl }:
 
 stdenv.mkDerivation rec {
   pname = "kore";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An easy to use web application framework for C";
     homepage = "https://kore.io";
     license = licenses.isc;
diff --git a/pkgs/development/web/now-cli/default.nix b/pkgs/development/web/now-cli/default.nix
index 3016ba4cb84b1..3b1d2b4be4b5a 100644
--- a/pkgs/development/web/now-cli/default.nix
+++ b/pkgs/development/web/now-cli/default.nix
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
 
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zeit.co/now";
     description = "The Command Line Interface for Now - Global Serverless Deployments";
     license = licenses.asl20;
diff --git a/pkgs/development/web/postman/default.nix b/pkgs/development/web/postman/default.nix
index 924f449369583..5ff4f7efb91e8 100644
--- a/pkgs/development/web/postman/default.nix
+++ b/pkgs/development/web/postman/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, wrapGAppsHook
+{ lib, stdenv, fetchurl, makeDesktopItem, wrapGAppsHook
 , atk, at-spi2-atk, at-spi2-core, alsaLib, cairo, cups, dbus, expat, gdk-pixbuf, glib, gtk3
 , freetype, fontconfig, nss, nspr, pango, udev, libuuid, libX11, libxcb, libXi
 , libXcursor, libXdamage, libXrandr, libXcomposite, libXext, libXfixes
@@ -93,7 +93,7 @@ stdenv.mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.getpostman.com";
     description = "API Development Environment";
     license = licenses.postman;
diff --git a/pkgs/development/web/shopify-themekit/default.nix b/pkgs/development/web/shopify-themekit/default.nix
index a50140c15327f..60a3d330ab82e 100644
--- a/pkgs/development/web/shopify-themekit/default.nix
+++ b/pkgs/development/web/shopify-themekit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "shopify-themekit";
@@ -15,7 +15,7 @@ buildGoPackage rec {
     sha256 = "1780h33mf2h2lv6mr4xx3shfvsabr7w138yb59vvdgvjng9wjkg0";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line tool for shopify themes";
     homepage = "https://shopify.github.io/themekit/";
     license = licenses.mit;
diff --git a/pkgs/development/web/valum/default.nix b/pkgs/development/web/valum/default.nix
index e4407b9f556bf..59db90741d347 100644
--- a/pkgs/development/web/valum/default.nix
+++ b/pkgs/development/web/valum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, meson, ninja, pkgconfig, fetchFromGitHub, glib, vala, ctpl
+{ lib, stdenv, meson, ninja, pkgconfig, fetchFromGitHub, glib, vala, ctpl
 , libgee, libsoup, fcgi }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson ninja pkgconfig ];
   buildInputs = [ glib vala ctpl libgee libsoup fcgi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/valum-framework/valum";
     description = "Web micro-framework written in Vala";
     license = licenses.lgpl3;
diff --git a/pkgs/development/web/wml/default.nix b/pkgs/development/web/wml/default.nix
index 6208bff15bc42..2b882ccc84183 100644
--- a/pkgs/development/web/wml/default.nix
+++ b/pkgs/development/web/wml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, ncurses, lynx, makeWrapper }:
+{ lib, stdenv, fetchurl, perlPackages, ncurses, lynx, makeWrapper }:
 
 perlPackages.buildPerlPackage {
   pname = "wml";
@@ -55,7 +55,7 @@ perlPackages.buildPerlPackage {
 
   installTargets = [ "install" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.shlomifish.org/open-source/projects/website-meta-language/";
     description = "Off-line HTML generation toolkit for Unix";
     license = licenses.gpl2;
diff --git a/pkgs/development/web/woff2/default.nix b/pkgs/development/web/woff2/default.nix
index aadeb3cd04373..fd296d37f87ee 100644
--- a/pkgs/development/web/woff2/default.nix
+++ b/pkgs/development/web/woff2/default.nix
@@ -1,4 +1,4 @@
-{ brotli, cmake, pkgconfig, fetchFromGitHub, stdenv
+{ brotli, cmake, pkgconfig, fetchFromGitHub, lib, stdenv
 , static ? stdenv.hostPlatform.isStatic
 }:
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     sed 's@^if (NOT BUILD_SHARED_LIBS)$@if (TRUE)@g' -i CMakeLists.txt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Webfont compression reference code";
     homepage = "https://github.com/google/woff2";
     license = licenses.mit;
diff --git a/pkgs/games/0ad/data.nix b/pkgs/games/0ad/data.nix
index eeedae924405d..1bebf922c48d2 100644
--- a/pkgs/games/0ad/data.nix
+++ b/pkgs/games/0ad/data.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zeroad-unwrapped }:
+{ lib, stdenv, fetchurl, zeroad-unwrapped }:
 
 stdenv.mkDerivation rec {
   pname = "0ad-data";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     cp -r binaries/data $out/share/0ad/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, open-source game of ancient warfare -- data files";
     homepage = "https://play0ad.com/";
     license = licenses.cc-by-sa-30;
diff --git a/pkgs/games/0ad/game.nix b/pkgs/games/0ad/game.nix
index 4c9ad7068878e..558c69c14d6ea 100644
--- a/pkgs/games/0ad/game.nix
+++ b/pkgs/games/0ad/game.nix
@@ -90,7 +90,7 @@ stdenv.mkDerivation rec {
     install -D build/resources/0ad.desktop $out/share/applications/0ad.desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, open-source game of ancient warfare";
     homepage = "https://play0ad.com/";
     license = with licenses; [
diff --git a/pkgs/games/1oom/default.nix b/pkgs/games/1oom/default.nix
index 70c21a3cc1d8d..54bfb4d0b3219 100644
--- a/pkgs/games/1oom/default.nix
+++ b/pkgs/games/1oom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, autoreconfHook, libsamplerate, SDL2, SDL2_mixer, readline }:
+{ lib, stdenv, fetchFromGitLab, autoreconfHook, libsamplerate, SDL2, SDL2_mixer, readline }:
 
 stdenv.mkDerivation rec {
   pname = "1oom";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       HACKING NEWS PHILOSOPHY README doc/*.txt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kilgoretroutmaskreplicant.gitlab.io/plain-html/";
     description = "Master of Orion (1993) game engine recreation";
     license = licenses.gpl2Only;
diff --git a/pkgs/games/2048-in-terminal/default.nix b/pkgs/games/2048-in-terminal/default.nix
index 446252062fac5..8ac72db65f5fa 100644
--- a/pkgs/games/2048-in-terminal/default.nix
+++ b/pkgs/games/2048-in-terminal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "2048-in-terminal";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   '';
   installFlags = [ "DESTDIR=$(out)/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Animated console version of the 2048 game";
     license = licenses.mit;
diff --git a/pkgs/games/20kly/default.nix b/pkgs/games/20kly/default.nix
index 8c81b8b2360e6..e8778d7bebcfb 100644
--- a/pkgs/games/20kly/default.nix
+++ b/pkgs/games/20kly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python }:
 
@@ -30,7 +30,7 @@ python.pkgs.buildPythonApplication rec {
     install -Dm755 lightyears "$out/bin/lightyears"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A steampunk-themed strategy game where you have to manage a steam supply network";
     homepage = "http://jwhitham.org.uk/20kly/";
     license = licenses.gpl2;
diff --git a/pkgs/games/90secondportraits/default.nix b/pkgs/games/90secondportraits/default.nix
index 334a7f873bb84..a5b504995f792 100644
--- a/pkgs/games/90secondportraits/default.nix
+++ b/pkgs/games/90secondportraits/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "90secondportraits";
@@ -48,7 +48,7 @@ stdenv.mkDerivation {
     ln -s ${desktopItem}/share/applications/* $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A silly speed painting game";
     maintainers = with maintainers; [ leenaars ];
     platforms = platforms.linux;
diff --git a/pkgs/games/abbaye-des-morts/default.nix b/pkgs/games/abbaye-des-morts/default.nix
index 103b67e99edf2..5e536d2b18dff 100644
--- a/pkgs/games/abbaye-des-morts/default.nix
+++ b/pkgs/games/abbaye-des-morts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, SDL2, SDL2_image, SDL2_mixer }:
+{ lib, stdenv, fetchFromGitHub, SDL2, SDL2_image, SDL2_mixer }:
 
 stdenv.mkDerivation rec {
   pname = "abbaye-des-morts";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://locomalito.com/abbaye_des_morts.php";
     description = "A retro arcade video game";
     license = licenses.gpl3;
diff --git a/pkgs/games/adom/default.nix b/pkgs/games/adom/default.nix
index 055959fff2d06..c5ffe950983ac 100644
--- a/pkgs/games/adom/default.nix
+++ b/pkgs/games/adom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, patchelf, zlib, libmad, libpng12, libcaca, libGLU, libGL, alsaLib, libpulseaudio
+{ lib, stdenv, fetchurl, patchelf, zlib, libmad, libpng12, libcaca, libGLU, libGL, alsaLib, libpulseaudio
 , xorg }:
 
 let
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/adom
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A rogue-like game with nice graphical interface";
     homepage = "http://adom.de/";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/games/airstrike/default.nix b/pkgs/games/airstrike/default.nix
index 10dfc7501fb74..f45ac2f015322 100644
--- a/pkgs/games/airstrike/default.nix
+++ b/pkgs/games/airstrike/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, SDL, SDL_image }:
+{ lib, stdenv, fetchurl, makeWrapper, SDL, SDL_image }:
 
 stdenv.mkDerivation rec {
   pname = "airstrike-pre";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
       --run "cd $out/share"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 2d dogfighting game";
     homepage = "https://icculus.org/airstrike/";
     license = licenses.gpl2;
diff --git a/pkgs/games/alephone/default.nix b/pkgs/games/alephone/default.nix
index 8dfef420a8d84..7691001edacf9 100644
--- a/pkgs/games/alephone/default.nix
+++ b/pkgs/games/alephone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, boost, curl, ffmpeg, icoutils, libGLU, libmad, libogg
+{ lib, stdenv, fetchurl, boost, curl, ffmpeg, icoutils, libGLU, libmad, libogg
 , libpng, libsndfile, libvorbis, lua, pkgconfig, SDL2, SDL2_image, SDL2_net
 , SDL2_ttf, smpeg, speex, zziplib, zlib, makeWrapper, makeDesktopItem, unzip
 , alephone }:
@@ -52,7 +52,7 @@ let
       popd
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description =
         "Aleph One is the open source continuation of Bungie’s Marathon 2 game engine";
       homepage = "https://alephone.lhowon.org/";
diff --git a/pkgs/games/alienarena/default.nix b/pkgs/games/alienarena/default.nix
index a28cf2508e282..5e9fd54e4ffd6 100644
--- a/pkgs/games/alienarena/default.nix
+++ b/pkgs/games/alienarena/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libjpeg, libX11, libXxf86vm, curl, libogg
+{ lib, stdenv, fetchurl, pkgconfig, libjpeg, libX11, libXxf86vm, curl, libogg
 , libvorbis, freetype, openal, libGL }:
 
 stdenv.mkDerivation {
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
       --replace libGL.so.1 ${libGL}/lib/libGL.so.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, stand-alone first-person shooter computer game";
     longDescription = ''
       Do you like old school deathmatch with modern features? How
diff --git a/pkgs/games/amoeba/data.nix b/pkgs/games/amoeba/data.nix
index f86ee71aa424f..193c710b31a10 100644
--- a/pkgs/games/amoeba/data.nix
+++ b/pkgs/games/amoeba/data.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "amoeba-data";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     cp demo.dat $out/share/amoeba/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast-paced, polished OpenGL demonstration by Excess (data files)";
     homepage = "https://packages.qa.debian.org/a/amoeba-data.html";
     license = licenses.unfree;
diff --git a/pkgs/games/amoeba/default.nix b/pkgs/games/amoeba/default.nix
index 8c4d9ef109261..071a81bcb923b 100644
--- a/pkgs/games/amoeba/default.nix
+++ b/pkgs/games/amoeba/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, amoeba-data, alsaLib, expat, freetype, gtk2, libvorbis, libGLU, xorg, pkgconfig }:
+{ lib, stdenv, fetchurl, amoeba-data, alsaLib, expat, freetype, gtk2, libvorbis, libGLU, xorg, pkgconfig }:
 
 stdenv.mkDerivation rec {
   name = "amoeba-${version}-${debver}";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     cp ../debian/amoeba.1 $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast-paced, polished OpenGL demonstration by Excess";
     homepage = "https://packages.qa.debian.org/a/amoeba.html";
     license = licenses.gpl2; # Engine is GPLv2, data files in amoeba-data nonfree
diff --git a/pkgs/games/among-sus/default.nix b/pkgs/games/among-sus/default.nix
index c422ed1c8e52c..1ec0a42ea18e4 100644
--- a/pkgs/games/among-sus/default.nix
+++ b/pkgs/games/among-sus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, port ? "1234" }:
+{ lib, stdenv, fetchgit, port ? "1234" }:
 
 stdenv.mkDerivation {
   pname = "among-sus-unstable";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     install -Dm755 among-sus $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~martijnbraam/among-sus";
     description = "Among us, but it's a text adventure";
     license = licenses.agpl3Plus;
diff --git a/pkgs/games/angband/default.nix b/pkgs/games/angband/default.nix
index 937fd30d405a8..ddf3c62307d3e 100644
--- a/pkgs/games/angband/default.nix
+++ b/pkgs/games/angband/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, ncurses5 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, ncurses5 }:
 
 stdenv.mkDerivation rec {
   pname = "angband";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ ncurses5 ];
   installFlags = [ "bindir=$(out)/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://rephial.org/";
     description = "A single-player roguelike dungeon exploration game";
     maintainers = [ maintainers.chattered ];
diff --git a/pkgs/games/armagetronad/default.nix b/pkgs/games/armagetronad/default.nix
index d4d2cbef164d0..e271db8673404 100644
--- a/pkgs/games/armagetronad/default.nix
+++ b/pkgs/games/armagetronad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL, libxml2, SDL_image, libjpeg, libpng, libGLU, libGL, zlib }:
+{ lib, stdenv, fetchurl, SDL, libxml2, SDL_image, libjpeg, libpng, libGLU, libGL, zlib }:
 
 let
   versionMajor = "0.2.8";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
   configureFlags = [ "--disable-etc" ];
   buildInputs = [ SDL SDL_image libxml2 libjpeg libpng libGLU libGL zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://armagetronad.org";
     description = "An multiplayer networked arcade racing game in 3D similar to Tron";
     license = licenses.gpl2;
diff --git a/pkgs/games/asc/default.nix b/pkgs/games/asc/default.nix
index 28b144a4e864d..1b7feda4ebb78 100644
--- a/pkgs/games/asc/default.nix
+++ b/pkgs/games/asc/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, SDL, SDL_image, SDL_mixer, SDL_sound, libsigcxx, physfs
+{ fetchurl, lib, stdenv, SDL, SDL_image, SDL_mixer, SDL_sound, libsigcxx, physfs
 , boost, expat, freetype, libjpeg, wxGTK, lua, perl, pkgconfig, zlib, zip, bzip2
 , libpng, libtiff, fluidsynth, libmikmod, libvorbis, flac, libogg }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     libtiff fluidsynth libmikmod flac libvorbis libogg
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Turn based strategy game";
 
     longDescription = ''
diff --git a/pkgs/games/atanks/default.nix b/pkgs/games/atanks/default.nix
index bb11acf38664e..f92f2e19c33d2 100644
--- a/pkgs/games/atanks/default.nix
+++ b/pkgs/games/atanks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, allegro }:
+{ lib, stdenv, fetchurl, allegro }:
 
 stdenv.mkDerivation rec {
   pname = "atanks";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)/" "INSTALL=install" "CXX=g++" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Atomic Tanks ballistics game";
     homepage = "http://atanks.sourceforge.net/";
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/games/augustus/default.nix b/pkgs/games/augustus/default.nix
index 18c8842e594e8..b7c2a0b797920 100644
--- a/pkgs/games/augustus/default.nix
+++ b/pkgs/games/augustus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, SDL2, SDL2_mixer, libpng }:
+{ lib, stdenv, fetchFromGitHub, cmake, SDL2, SDL2_mixer, libpng }:
 
 stdenv.mkDerivation rec {
   pname = "augustus";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ SDL2 SDL2_mixer libpng ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source re-implementation of Caesar III. Fork of Julius incorporating gameplay changes";
     homepage = "https://github.com/Keriew/augustus";
     license = licenses.agpl3Only;
diff --git a/pkgs/games/banner/default.nix b/pkgs/games/banner/default.nix
index e0f9ca41c6d0e..084dd37d3224e 100644
--- a/pkgs/games/banner/default.nix
+++ b/pkgs/games/banner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "banner";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
     sha256 = "ISSnGzrFSzSj/+KxgeFtaw4H+4Ea5x5S5C8xjcjKWqQ=";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://software.cedar-solutions.com/utilities.html";
     description = "Print large banners to ASCII terminals";
     license = licenses.gpl2Only;
diff --git a/pkgs/games/bastet/default.nix b/pkgs/games/bastet/default.nix
index d68a05137b431..053eca57528b0 100644
--- a/pkgs/games/bastet/default.nix
+++ b/pkgs/games/bastet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, ncurses, boost }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, ncurses, boost }:
 
 stdenv.mkDerivation rec {
   pname = "bastet";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     cp bastet.6 "$out"/share/man/man6
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tetris clone with 'bastard' block-choosing AI";
     homepage = "http://fph.altervista.org/prog/bastet.html";
     license = licenses.gpl3;
diff --git a/pkgs/games/beret/default.nix b/pkgs/games/beret/default.nix
index f640e2c6aefa4..db9e6b96902a7 100644
--- a/pkgs/games/beret/default.nix
+++ b/pkgs/games/beret/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL, SDL_image, SDL_ttf, SDL_mixer }:
+{ lib, stdenv, fetchurl, SDL, SDL_image, SDL_ttf, SDL_mixer }:
 
 stdenv.mkDerivation {
   name = "beret-1.2.0";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     cp -av tahoma.ttf images music rooms sfx $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 2D puzzle-platformer game about a scientist with telekinetic abilities";
     homepage    = "http://kiwisauce.com/beret/";
     license     = licenses.lgpl2;
diff --git a/pkgs/games/boohu/default.nix b/pkgs/games/boohu/default.nix
index 3ca8ee4693a3e..9b46420d5fff4 100644
--- a/pkgs/games/boohu/default.nix
+++ b/pkgs/games/boohu/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, buildGoPackage}:
+{lib, stdenv, fetchurl, buildGoPackage}:
 
 buildGoPackage rec {
 
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   postInstall = "mv $out/bin/boohu.git $out/bin/boohu";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A new coffee-break roguelike game";
     longDescription = ''
       Break Out Of Hareka's Underground (Boohu) is a roguelike game mainly
diff --git a/pkgs/games/braincurses/default.nix b/pkgs/games/braincurses/default.nix
index 86a8f865442b4..f3f862b97ef9f 100644
--- a/pkgs/games/braincurses/default.nix
+++ b/pkgs/games/braincurses/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "braincurses";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -Dt $out/bin braincurses
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bderrly/braincurses";
     description = "A version of the classic game Mastermind";
     license = licenses.gpl2;
diff --git a/pkgs/games/brogue/default.nix b/pkgs/games/brogue/default.nix
index 1662f847bfa95..77811e76e96da 100644
--- a/pkgs/games/brogue/default.nix
+++ b/pkgs/games/brogue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL, ncurses, libtcod, makeDesktopItem }:
+{ lib, stdenv, fetchurl, SDL, ncurses, libtcod, makeDesktopItem }:
 
 stdenv.mkDerivation rec {
   pname = "brogue";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
   # fix crash; shouldn’t be a security risk because it’s an offline game
   hardeningDisable = [ "stackprotector" "fortify" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A roguelike game";
     homepage = "https://sites.google.com/site/broguegame/";
     license = licenses.agpl3;
diff --git a/pkgs/games/btanks/default.nix b/pkgs/games/btanks/default.nix
index 5bb7cfa215bcf..cb6078026dc2c 100644
--- a/pkgs/games/btanks/default.nix
+++ b/pkgs/games/btanks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, sconsPackages, pkgconfig, SDL, libGL, zlib, smpeg
+{ lib, stdenv, fetchurl, fetchpatch, sconsPackages, pkgconfig, SDL, libGL, zlib, smpeg
 , SDL_image, libvorbis, expat, zip, lua }:
 
 stdenv.mkDerivation rec {
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast 2d tank arcade game";
     homepage = "https://sourceforge.net/projects/btanks/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/cataclysm-dda/common.nix b/pkgs/games/cataclysm-dda/common.nix
index 9ec73cdebe031..c41b0df5a80dd 100644
--- a/pkgs/games/cataclysm-dda/common.nix
+++ b/pkgs/games/cataclysm-dda/common.nix
@@ -1,4 +1,4 @@
-{ stdenv, runtimeShell, pkgconfig, gettext, ncurses, CoreFoundation
+{ lib, stdenv, runtimeShell, pkgconfig, gettext, ncurses, CoreFoundation
 , tiles, SDL2, SDL2_image, SDL2_mixer, SDL2_ttf, freetype, Cocoa
 , debug
 , useXdgDir
@@ -79,7 +79,7 @@ stdenv.mkDerivation {
     isCurses = !tiles;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, post apocalyptic, zombie infested rogue-like";
     longDescription = ''
       Cataclysm: Dark Days Ahead is a roguelike set in a post-apocalyptic world.
diff --git a/pkgs/games/chessx/default.nix b/pkgs/games/chessx/default.nix
index 5b3be969cf1ee..9f8e4c6cc5ac8 100644
--- a/pkgs/games/chessx/default.nix
+++ b/pkgs/games/chessx/default.nix
@@ -1,5 +1,5 @@
 { mkDerivation
-, stdenv
+, lib, stdenv
 , pkgconfig
 , zlib
 , qtbase
@@ -46,7 +46,7 @@ mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://chessx.sourceforge.net/";
     description = "Browse and analyse chess games";
     license = licenses.gpl2;
diff --git a/pkgs/games/chiaki/default.nix b/pkgs/games/chiaki/default.nix
index 23ea59d8e758f..e3a2560ac101d 100644
--- a/pkgs/games/chiaki/default.nix
+++ b/pkgs/games/chiaki/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , cmake
 , pkg-config
@@ -54,7 +54,7 @@ mkDerivation rec {
 
   installCheckPhase = "$out/bin/chiaki --help";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.sr.ht/~thestr4ng3r/chiaki";
     description = "Free and Open Source PlayStation Remote Play Client";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/ckan/default.nix b/pkgs/games/ckan/default.nix
index 2400f2fb5e854..b0a509ce4db14 100644
--- a/pkgs/games/ckan/default.nix
+++ b/pkgs/games/ckan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, mono, gtk2, curl }:
+{ lib, stdenv, fetchurl, makeWrapper, mono, gtk2, curl }:
 
 stdenv.mkDerivation rec {
   pname = "ckan";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --set LD_LIBRARY_PATH $libraries
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mod manager for Kerbal Space Program";
     homepage = "https://github.com/KSP-CKAN/CKAN";
     license = licenses.mit;
diff --git a/pkgs/games/colobot/data.nix b/pkgs/games/colobot/data.nix
index f1a4782fad6ef..7ae9dbb2b5ed9 100644
--- a/pkgs/games/colobot/data.nix
+++ b/pkgs/games/colobot/data.nix
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     cd localSrc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://colobot.info/";
     description = "Game data for colobot";
     license = licenses.gpl3;
diff --git a/pkgs/games/colobot/default.nix b/pkgs/games/colobot/default.nix
index 9c0cbe7949c0a..25b91d80f2729 100644
--- a/pkgs/games/colobot/default.nix
+++ b/pkgs/games/colobot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, boost, SDL2, SDL2_image, SDL2_ttf, libpng
+{ lib, stdenv, fetchFromGitHub, cmake, boost, SDL2, SDL2_image, SDL2_ttf, libpng
 , glew, gettext, libsndfile, libvorbis, libogg, physfs, openal
 , xmlstarlet, doxygen, python3, callPackage }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://colobot.info/";
     description = "Colobot: Gold Edition is a real-time strategy game, where you can program your bots";
     license = licenses.gpl3;
diff --git a/pkgs/games/commandergenius/default.nix b/pkgs/games/commandergenius/default.nix
index 251ea852cf18d..c375668c2221b 100644
--- a/pkgs/games/commandergenius/default.nix
+++ b/pkgs/games/commandergenius/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, SDL2, SDL2_image, pkgconfig
+{ lib, stdenv, fetchFromGitLab, SDL2, SDL2_image, pkgconfig
 , libvorbis, libGL, boost, cmake, zlib, curl, SDL2_mixer, python3
 }:
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     sed -i 's,APPDIR games,APPDIR bin,' src/install.cmake
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern Interpreter for the Commander Keen Games";
     longDescription = ''
       Commander Genius is an open-source clone of
diff --git a/pkgs/games/crawl/default.nix b/pkgs/games/crawl/default.nix
index 20e31c979e6ff..353a7b029cf32 100644
--- a/pkgs/games/crawl/default.nix
+++ b/pkgs/games/crawl/default.nix
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open-source, single-player, role-playing roguelike game";
     homepage = "http://crawl.develz.org/";
     longDescription = ''
diff --git a/pkgs/games/curseofwar/default.nix b/pkgs/games/curseofwar/default.nix
index 9aff3798b6ba7..6271a60f5b9c0 100644
--- a/pkgs/games/curseofwar/default.nix
+++ b/pkgs/games/curseofwar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , ncurses
 , SDL
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "CC=${stdenv.cc.targetPrefix}cc"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast-paced action strategy game";
     homepage = "https://a-nikolaev.github.io/curseofwar/";
     license = licenses.gpl3;
diff --git a/pkgs/games/cutemaze/default.nix b/pkgs/games/cutemaze/default.nix
index a293989d5e6a0..89fdc7e9d8701 100644
--- a/pkgs/games/cutemaze/default.nix
+++ b/pkgs/games/cutemaze/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qmake, qttools, qtsvg, mkDerivation }:
+{ lib, stdenv, fetchurl, qmake, qttools, qtsvg, mkDerivation }:
 
 mkDerivation rec {
   pname = "cutemaze";
@@ -18,7 +18,7 @@ mkDerivation rec {
     mv CuteMaze.app $out/Applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gottcode.org/cutemaze/";
     description = "Simple, top-down game in which mazes are randomly generated";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/devilutionx/default.nix b/pkgs/games/devilutionx/default.nix
index 69d7e3ca66622..73968b5156498 100644
--- a/pkgs/games/devilutionx/default.nix
+++ b/pkgs/games/devilutionx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, SDL2, SDL2_mixer, SDL2_ttf, libsodium, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, cmake, SDL2, SDL2_mixer, SDL2_ttf, libsodium, pkg-config }:
 stdenv.mkDerivation rec {
   version = "1.0.1";
   pname = "devilutionx";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/diasurgical/devilutionX";
     description = "Diablo build for modern operating systems";
     longDescription = "In order to play this game a copy of diabdat.mpq is required. Place a copy of diabdat.mpq in ~/.local/share/diasurgical/devilution before executing the game.";
diff --git a/pkgs/games/dhewm3/default.nix b/pkgs/games/dhewm3/default.nix
index d2e87336e1ed1..edec85a1c6502 100644
--- a/pkgs/games/dhewm3/default.nix
+++ b/pkgs/games/dhewm3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, SDL2, libGLU, libGL, zlib, libjpeg, libogg, libvorbis
+{ lib, stdenv, fetchFromGitHub, cmake, SDL2, libGLU, libGL, zlib, libjpeg, libogg, libvorbis
 , openal, curl }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dhewm/dhewm3";
     description = "Doom 3 port to SDL";
     license = stdenv.lib.licenses.gpl3;
diff --git a/pkgs/games/duckmarines/default.nix b/pkgs/games/duckmarines/default.nix
index 7af31c606a938..013ebcc7ec5f4 100644
--- a/pkgs/games/duckmarines/default.nix
+++ b/pkgs/games/duckmarines/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "duckmarines";
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     ln -s ${desktopItem}/share/applications/* $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Duck-themed action puzzle video game";
     maintainers = with maintainers; [ leenaars ];
     platforms = platforms.linux;
diff --git a/pkgs/games/dwarf-fortress/dfhack/default.nix b/pkgs/games/dwarf-fortress/dfhack/default.nix
index b92169fade567..2e27d9493bd13 100644
--- a/pkgs/games/dwarf-fortress/dfhack/default.nix
+++ b/pkgs/games/dwarf-fortress/dfhack/default.nix
@@ -156,7 +156,7 @@ buildEnv {
 
   paths = [ dfhack ] ++ lib.optionals enableTWBT [ twbt.lib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Memory hacking library for Dwarf Fortress and a set of tools that use it";
     homepage = "https://github.com/DFHack/dfhack/";
     license = licenses.zlib;
diff --git a/pkgs/games/dwarf-fortress/dwarf-therapist/default.nix b/pkgs/games/dwarf-fortress/dwarf-therapist/default.nix
index f5c093e1f16c4..83e181c85e654 100644
--- a/pkgs/games/dwarf-fortress/dwarf-therapist/default.nix
+++ b/pkgs/games/dwarf-fortress/dwarf-therapist/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qtbase
+{ lib, stdenv, fetchFromGitHub, qtbase
 , qtdeclarative, cmake, texlive, ninja }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp -r DwarfTherapist.app $out/Applications
   '' else null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to manage dwarves in a running game of Dwarf Fortress";
     maintainers = with maintainers; [ abbradar bendlas numinit jonringer ];
     license = licenses.mit;
diff --git a/pkgs/games/dwarf-fortress/unfuck.nix b/pkgs/games/dwarf-fortress/unfuck.nix
index 1b097fc7e6171..0fb08aa7e87f1 100644
--- a/pkgs/games/dwarf-fortress/unfuck.nix
+++ b/pkgs/games/dwarf-fortress/unfuck.nix
@@ -84,7 +84,7 @@ stdenv.mkDerivation {
 
   passthru = { inherit dfVersion; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unfucked multimedia layer for Dwarf Fortress";
     homepage = "https://github.com/svenstaro/dwarf_fortress_unfuck";
     license = licenses.free;
diff --git a/pkgs/games/dxx-rebirth/assets.nix b/pkgs/games/dxx-rebirth/assets.nix
index 47a8222cd6a9d..b214d49659b6e 100644
--- a/pkgs/games/dxx-rebirth/assets.nix
+++ b/pkgs/games/dxx-rebirth/assets.nix
@@ -1,4 +1,4 @@
-{ stdenv, requireFile, gogUnpackHook }:
+{ lib, stdenv, requireFile, gogUnpackHook }:
 
 let
   generic = ver: source: let
@@ -40,7 +40,7 @@ let
       runHook postInstall
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Descent ${toString ver} assets from GOG";
       homepage    = "https://www.dxx-rebirth.com/";
       license     = licenses.unfree;
diff --git a/pkgs/games/dxx-rebirth/default.nix b/pkgs/games/dxx-rebirth/default.nix
index aa2563d4e4b9e..43c3fd00a0201 100644
--- a/pkgs/games/dxx-rebirth/default.nix
+++ b/pkgs/games/dxx-rebirth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchurl
 , fetchpatch
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     install -Dm644 -t $out/share/doc/dxx-rebirth *.txt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Source Port of the Descent 1 and 2 engines";
     homepage = "https://www.dxx-rebirth.com/";
     license = licenses.gpl3;
diff --git a/pkgs/games/dxx-rebirth/full.nix b/pkgs/games/dxx-rebirth/full.nix
index 782a2d21112c3..f3349c114eed1 100644
--- a/pkgs/games/dxx-rebirth/full.nix
+++ b/pkgs/games/dxx-rebirth/full.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper
+{ lib, stdenv, makeWrapper
 , dxx-rebirth, descent1-assets, descent2-assets }:
 
 let
@@ -14,7 +14,7 @@ let
         --add-flags "-hogdir ${assets}/share/games/descent${toString ver}"
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Descent ${toString ver} using the DXX-Rebirth project engine and game assets from GOG";
       homepage    = "https://www.dxx-rebirth.com/";
       license     = with licenses; [ free unfree ];
diff --git a/pkgs/games/easyrpg-player/default.nix b/pkgs/games/easyrpg-player/default.nix
index f3f039fe78bbd..7ebba6c3d72da 100644
--- a/pkgs/games/easyrpg-player/default.nix
+++ b/pkgs/games/easyrpg-player/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, doxygen ? null, pkgconfig, freetype ? null, glib, harfbuzz ? null
+{ lib, stdenv, fetchFromGitHub, cmake, doxygen ? null, pkgconfig, freetype ? null, glib, harfbuzz ? null
 , liblcf, libpng, libsndfile ? null, libvorbis ? null, libxmp ? null
 , libXcursor, libXext, libXi, libXinerama, libXrandr, libXScrnSaver, libXxf86vm
 , mpg123 ? null, opusfile ? null, pcre, pixman, SDL2_mixer, speexdsp ? null, wildmidi ? null, zlib }:
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     zlib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RPG Maker 2000/2003 and EasyRPG games interpreter";
     homepage = "https://easyrpg.org/";
     license = licenses.gpl3;
diff --git a/pkgs/games/eduke32/default.nix b/pkgs/games/eduke32/default.nix
index df0950eb93766..f264fd0b9e325 100644
--- a/pkgs/games/eduke32/default.nix
+++ b/pkgs/games/eduke32/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, pkgconfig, nasm, makeDesktopItem
+{ lib, stdenv, fetchurl, makeWrapper, pkgconfig, nasm, makeDesktopItem
 , alsaLib, flac, gtk2, libvorbis, libvpx, libGLU, libGL
 , SDL2, SDL2_mixer }:
 
@@ -66,7 +66,7 @@ in stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enhanched port of Duke Nukem 3D for various platforms";
     homepage = "http://eduke32.com";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/eidolon/default.nix b/pkgs/games/eidolon/default.nix
index 4ae64df41437b..bb7f7a68bcf05 100644
--- a/pkgs/games/eidolon/default.nix
+++ b/pkgs/games/eidolon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, rustPlatform, pkgconfig, openssl }:
+{ lib, stdenv, fetchgit, rustPlatform, pkgconfig, openssl }:
 
 rustPlatform.buildRustPackage rec {
   pname = "eidolon";
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A single TUI-based registry for drm-free, wine and steam games on linux, accessed through a rofi launch menu";
     homepage = "https://github.com/nicohman/eidolon";
     license = licenses.gpl3;
diff --git a/pkgs/games/endless-sky/default.nix b/pkgs/games/endless-sky/default.nix
index cfcbcde6efd17..010f90a049bd7 100644
--- a/pkgs/games/endless-sky/default.nix
+++ b/pkgs/games/endless-sky/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , SDL2, libpng, libjpeg, glew, openal, scons, libmad
 }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
 
   prefixKey = "PREFIX=";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A sandbox-style space exploration game similar to Elite, Escape Velocity, or Star Control";
     homepage = "https://endless-sky.github.io/";
     license = with licenses; [
diff --git a/pkgs/games/ezquake/default.nix b/pkgs/games/ezquake/default.nix
index 802125e3f8b12..143a7d94015ae 100644
--- a/pkgs/games/ezquake/default.nix
+++ b/pkgs/games/ezquake/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, curl, expat
+{ lib, stdenv, fetchFromGitHub, curl, expat
 , jansson, libpng, libjpeg, libGLU, libGL, libXxf86vm, pcre
 , pkgconfig, SDL2, vim, speex }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ezquake.github.io/";
     description = "A modern QuakeWorld client focused on competitive online play";
     license = licenses.gpl2;
diff --git a/pkgs/games/flare/engine.nix b/pkgs/games/flare/engine.nix
index 74f983c64413c..22a12fda0545f 100644
--- a/pkgs/games/flare/engine.nix
+++ b/pkgs/games/flare/engine.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, SDL2, SDL2_image, SDL2_mixer, SDL2_ttf, Cocoa }:
+{ lib, stdenv, fetchFromGitHub, cmake, SDL2, SDL2_image, SDL2_mixer, SDL2_ttf, Cocoa }:
 
 stdenv.mkDerivation rec {
   pname = "flare-engine";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ SDL2 SDL2_image SDL2_mixer SDL2_ttf ]
     ++ stdenv.lib.optional stdenv.isDarwin Cocoa;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free/Libre Action Roleplaying Engine";
     homepage = "https://github.com/flareteam/flare-engine";
     maintainers = [ maintainers.aanderse ];
diff --git a/pkgs/games/flare/game.nix b/pkgs/games/flare/game.nix
index 6a231a5ff7d72..6b7f15fd9ccbe 100644
--- a/pkgs/games/flare/game.nix
+++ b/pkgs/games/flare/game.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "flare-game";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fantasy action RPG using the FLARE engine";
     homepage = "https://github.com/flareteam/flare-game";
     maintainers = [ maintainers.aanderse ];
diff --git a/pkgs/games/flightgear/default.nix b/pkgs/games/flightgear/default.nix
index 2156acf2d90a7..3e65915ec1dc3 100644
--- a/pkgs/games/flightgear/default.nix
+++ b/pkgs/games/flightgear/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, wrapQtAppsHook
+{ lib, stdenv, fetchurl, wrapQtAppsHook
 , freeglut, freealut, libGLU, libGL, libICE, libjpeg, openal, openscenegraph, plib
 , libSM, libunwind, libX11, xorgproto, libXext, libXi
 , libXmu, libXt, simgear, zlib, boost, cmake, libpng, udev, fltk13, apr
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     "--set FG_ROOT ${data}/share/FlightGear"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flight simulator";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/games/fltrator/default.nix b/pkgs/games/fltrator/default.nix
index e01a3f9fb9c0d..9df7d9cccfd84 100644
--- a/pkgs/games/fltrator/default.nix
+++ b/pkgs/games/fltrator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, fltk, which, libjpeg }:
+{ lib, stdenv, fetchurl, unzip, fltk, which, libjpeg }:
 
 stdenv.mkDerivation rec {
   pname = "fltrator";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     cp rsc/fltrator-128.png $out/share/icons/hicolor/128x128/apps/fltrator2.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple retro style arcade side-scroller game";
     longDescription = '' FLTrator is a simple retro style arcade side-scroller game in which you steer a spaceship through a landscape with hostile rockets and other obstacles.
     It has ten different levels and a level editor to create new levels or modify the existing.''; # from https://libregamewiki.org/FLTrator
diff --git a/pkgs/games/freeciv/default.nix b/pkgs/games/freeciv/default.nix
index c8f9c7908428d..31532a6c2e29d 100644
--- a/pkgs/games/freeciv/default.nix
+++ b/pkgs/games/freeciv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, lua5_3, pkgconfig, python3
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, lua5_3, pkgconfig, python3
 , zlib, bzip2, curl, lzma, gettext, libiconv
 , sdlClient ? true, SDL, SDL_mixer, SDL_image, SDL_ttf, SDL_gfx, freetype, fluidsynth
 , gtkClient ? false, gtk3
@@ -49,7 +49,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiplayer (or single player), turn-based strategy game";
 
     longDescription = ''
diff --git a/pkgs/games/freedroidrpg/default.nix b/pkgs/games/freedroidrpg/default.nix
index 443d60b9d672f..aab2b748d1a19 100644
--- a/pkgs/games/freedroidrpg/default.nix
+++ b/pkgs/games/freedroidrpg/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, pkgconfig, gettext, python3, SDL, SDL_image, SDL_gfx, SDL_mixer, libogg, libvorbis, lua5_3, libjpeg, libpng, zlib, libiconv }:
+{ fetchurl, lib, stdenv, pkgconfig, gettext, python3, SDL, SDL_image, SDL_gfx, SDL_mixer, libogg, libvorbis, lua5_3, libjpeg, libpng, zlib, libiconv }:
 
 let
   version = "0.16.1";
@@ -17,7 +17,7 @@ in stdenv.mkDerivation {
     SDL SDL_image SDL_gfx SDL_mixer libogg libvorbis lua5_3 libjpeg libpng zlib
   ] ++ stdenv.lib.optional stdenv.isDarwin libiconv;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Isometric 3D RPG similar to game Diablo";
 
     longDescription = ''
diff --git a/pkgs/games/freenukum/default.nix b/pkgs/games/freenukum/default.nix
index d428a0bf02f14..36639140702af 100644
--- a/pkgs/games/freenukum/default.nix
+++ b/pkgs/games/freenukum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitLab
 , makeDesktopItem
@@ -63,7 +63,7 @@ rustPlatform.buildRustPackage rec {
     install -Dm644 "${desktopItem}/share/applications/"* -t $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clone of the original Duke Nukum 1 Jump'n Run game";
     license = licenses.agpl3Plus;
     maintainers = with maintainers; [ _0x4A6F ];
diff --git a/pkgs/games/freeorion/default.nix b/pkgs/games/freeorion/default.nix
index 70a207cd7986f..de25fa691d515 100644
--- a/pkgs/games/freeorion/default.nix
+++ b/pkgs/games/freeorion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, doxygen, graphviz, makeWrapper
+{ lib, stdenv, fetchFromGitHub, cmake, doxygen, graphviz, makeWrapper
 , boost168, SDL2, python2, freetype, openal, libogg, libvorbis, zlib, libpng, libtiff
 , libjpeg, libGLU, libGL, glew, libxslt
 }:
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : $out/lib/freeorion
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, open source, turn-based space empire and galactic conquest (4X) computer game";
     homepage = "http://www.freeorion.org";
     license = with licenses; [ gpl2 cc-by-sa-30 ];
diff --git a/pkgs/games/freesweep/default.nix b/pkgs/games/freesweep/default.nix
index fdaaadbe42f03..7c17877e93416 100644
--- a/pkgs/games/freesweep/default.nix
+++ b/pkgs/games/freesweep/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, ncurses, stdenv,
+{ fetchFromGitHub, ncurses, lib, stdenv,
   updateAutotoolsGnuConfigScriptsHook }:
 
 stdenv.mkDerivation rec {
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A console minesweeper-style game written in C for Unix-like systems";
     homepage = "https://github.com/rwestlund/freesweep";
     license = licenses.gpl2;
diff --git a/pkgs/games/frogatto/data.nix b/pkgs/games/frogatto/data.nix
index 3313f156ed282..a077d01f3b65f 100644
--- a/pkgs/games/frogatto/data.nix
+++ b/pkgs/games/frogatto/data.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
   
 stdenv.mkDerivation {
   pname = "frogatto-data";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     cp -ar . $out/share/frogatto/modules/frogatto
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/frogatto/frogatto";
     description = "Data files to the frogatto game";
     license = with licenses; [ cc-by-30 unfree ];
diff --git a/pkgs/games/frogatto/default.nix b/pkgs/games/frogatto/default.nix
index ee3803617dcae..fb09847908da6 100644
--- a/pkgs/games/frogatto/default.nix
+++ b/pkgs/games/frogatto/default.nix
@@ -1,4 +1,4 @@
-{ buildEnv, stdenv, callPackage, makeWrapper, makeDesktopItem }:
+{ buildEnv, lib, stdenv, callPackage, makeWrapper, makeDesktopItem }:
 
 let
   description = "Action-adventure game, starring a certain quixotic frog";
@@ -33,7 +33,7 @@ in buildEnv {
       --run "cd $out/share/frogatto"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true;
     homepage = "https://frogatto.com";
     description = description;
diff --git a/pkgs/games/frogatto/engine.nix b/pkgs/games/frogatto/engine.nix
index 94c2a038d9204..7449926365005 100644
--- a/pkgs/games/frogatto/engine.nix
+++ b/pkgs/games/frogatto/engine.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which
+{ lib, stdenv, fetchFromGitHub, which
 , boost, SDL2, SDL2_image, SDL2_mixer, SDL2_ttf
 , glew, zlib, icu, pkgconfig, cairo, libvpx }:
 
@@ -40,7 +40,7 @@ stdenv.mkDerivation {
     cp -a anura $out/bin/frogatto
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/anura-engine/anura";
     description = "Game engine used by Frogatto";
     license = licenses.zlib;
diff --git a/pkgs/games/frotz/default.nix b/pkgs/games/frotz/default.nix
index 6ff163105da8a..58339e5d26f07 100644
--- a/pkgs/games/frotz/default.nix
+++ b/pkgs/games/frotz/default.nix
@@ -5,7 +5,7 @@
 , libsndfile
 , libvorbis
 , ncurses
-, stdenv }:
+, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   version = "2.52";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
   '';
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://davidgriffith.gitlab.io/frotz/";
     changelog = "https://gitlab.com/DavidGriffith/frotz/-/raw/${version}/NEWS";
     description = "A z-machine interpreter for Infocom games and other interactive fiction";
diff --git a/pkgs/games/gambatte/default.nix b/pkgs/games/gambatte/default.nix
index b2a2f0a3f92d8..4d6795070ca2c 100644
--- a/pkgs/games/gambatte/default.nix
+++ b/pkgs/games/gambatte/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, scons, qt4, alsaLib }:
+{ lib, stdenv, fetchFromGitHub, scons, qt4, alsaLib }:
 
 stdenv.mkDerivation {
   pname = "gambatte";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     cp gambatte_qt/bin/gambatte_qt $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Portable, open-source Game Boy Color emulator";
     homepage = "https://github.com/sinamas/gambatte";
     license = licenses.gpl2;
diff --git a/pkgs/games/garden-of-coloured-lights/default.nix b/pkgs/games/garden-of-coloured-lights/default.nix
index fde573cecd854..d38d8936c1a9e 100644
--- a/pkgs/games/garden-of-coloured-lights/default.nix
+++ b/pkgs/games/garden-of-coloured-lights/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, allegro }:
+{ lib, stdenv, fetchurl, autoconf, automake, allegro }:
 
 stdenv.mkDerivation rec {
   pname = "garden-of-coloured-lights";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     sha256 = "1qsj4d7r22m5f9f5f6cyvam1y5q5pbqvy5058r7w0k4s48n77y6s";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Old-school vertical shoot-em-up / bullet hell";
     homepage = "http://garden.sourceforge.net/drupal/";
     maintainers = with maintainers; [ Profpatsch ];
diff --git a/pkgs/games/gargoyle/default.nix b/pkgs/games/gargoyle/default.nix
index c4c512be2b898..78bffaf16af55 100644
--- a/pkgs/games/gargoyle/default.nix
+++ b/pkgs/games/gargoyle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll, jam, cctools, pkgconfig
+{ lib, stdenv, fetchFromGitHub, substituteAll, jam, cctools, pkgconfig
 , SDL, SDL_mixer, SDL_sound, gtk2, libvorbis, smpeg }:
 
 let
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ccxvii.net/gargoyle/";
     license = licenses.gpl2Plus;
     description = "Interactive fiction interpreter GUI";
diff --git a/pkgs/games/gcs/default.nix b/pkgs/games/gcs/default.nix
index 9c0b479304a6e..a471b425f0c61 100644
--- a/pkgs/games/gcs/default.nix
+++ b/pkgs/games/gcs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, runCommand
+{ lib, stdenv, fetchFromGitHub, runCommand
 , jdk8, ant
 , jre8, makeWrapper
 }:
@@ -66,7 +66,7 @@ in stdenv.mkDerivation rec {
       --add-flags "-cp $out/share/java/gcs-${version}.jar com.trollworks.gcs.app.GCS"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A stand-alone, interactive, character sheet editor for the GURPS 4th Edition roleplaying game system";
     homepage = "https://gurpscharactersheet.com/";
     license = licenses.mpl20;
diff --git a/pkgs/games/gemrb/default.nix b/pkgs/games/gemrb/default.nix
index 5fa58c7c3565b..fb49779eb535c 100644
--- a/pkgs/games/gemrb/default.nix
+++ b/pkgs/games/gemrb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake
+{ lib, stdenv, fetchFromGitHub, cmake
 , freetype, SDL2, SDL2_mixer, openal, zlib, libpng, python, libvorbis
 , libiconv }:
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     # "-DOpenGL_GL_PREFERENCE=GLVND"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A reimplementation of the Infinity Engine, used by games such as Baldur's Gate";
     longDescription = ''
       GemRB (Game engine made with pre-Rendered Background) is a portable
diff --git a/pkgs/games/gl-117/default.nix b/pkgs/games/gl-117/default.nix
index f76f761189c1b..0acabb4a55f31 100644
--- a/pkgs/games/gl-117/default.nix
+++ b/pkgs/games/gl-117/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , libGLU, libGL, SDL, freeglut, SDL_mixer, autoconf, automake, libtool
 }:
 
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libGLU libGL SDL freeglut SDL_mixer autoconf automake libtool ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An air combat simulator";
     homepage = "https://sourceforge.net/projects/gl-117";
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/games/globulation/default.nix b/pkgs/games/globulation/default.nix
index e0e4b876f3ec7..f25b1084b852d 100644
--- a/pkgs/games/globulation/default.nix
+++ b/pkgs/games/globulation/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libGLU, libGL, SDL, sconsPackages, SDL_ttf, SDL_image, zlib, SDL_net
+{ lib, stdenv, fetchurl, libGLU, libGL, SDL, sconsPackages, SDL_ttf, SDL_image, zlib, SDL_net
 , speex, libvorbis, libogg, boost, fribidi, bsdiff
 , fetchpatch
 }:
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = "-lboost_system";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RTS without micromanagement";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/games/gnome-hexgl/default.nix b/pkgs/games/gnome-hexgl/default.nix
index cfa9a0b81d02f..8e2fa41f4200e 100644
--- a/pkgs/games/gnome-hexgl/default.nix
+++ b/pkgs/games/gnome-hexgl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , ninja
 , meson
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     gtk3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gthree port of HexGL";
     homepage = "https://github.com/alexlarsson/gnome-hexgl";
     license = licenses.mit;
diff --git a/pkgs/games/gnujump/default.nix b/pkgs/games/gnujump/default.nix
index 8af7b84db26ef..240481b7bba0b 100644
--- a/pkgs/games/gnujump/default.nix
+++ b/pkgs/games/gnujump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL, SDL_image, SDL_mixer }:
+{ lib, stdenv, fetchurl, SDL, SDL_image, SDL_mixer }:
 
 stdenv.mkDerivation rec {
   pname = "gnujump";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = "-lm";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://jump.gnu.sinusoid.es/index.php?title=Main_Page";
     description = "A clone of the simple yet addictive game Xjump";
     longDescription = ''
diff --git a/pkgs/games/gnushogi/default.nix b/pkgs/games/gnushogi/default.nix
index 01c08fbf3dcbf..ef1950aaf40f8 100644
--- a/pkgs/games/gnushogi/default.nix
+++ b/pkgs/games/gnushogi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib }:
+{ lib, stdenv, fetchurl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "gnushogi";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     sha256 = "0a9bsl2nbnb138lq0h14jfc5xvz7hpb2bcsj4mjn6g1hcsl4ik0y";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNU implementation of Shogi, also known as Japanese Chess";
     homepage = "https://www.gnu.org/software/gnushogi/";
     license = licenses.gpl3;
diff --git a/pkgs/games/gscrabble/default.nix b/pkgs/games/gscrabble/default.nix
index cab509a3e9a61..7d63510aa991b 100644
--- a/pkgs/games/gscrabble/default.nix
+++ b/pkgs/games/gscrabble/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub
 , gtk3, wrapGAppsHook, gst_all_1, gobject-introspection
 , python3Packages, gnome3 }:
 
@@ -30,7 +30,7 @@ buildPythonApplication {
       )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Golden Scrabble crossword puzzle game";
     homepage = "https://github.com/RaaH/gscrabble/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/gshogi/default.nix b/pkgs/games/gshogi/default.nix
index 9004bd3d0423a..5ed4bf5a3763b 100644
--- a/pkgs/games/gshogi/default.nix
+++ b/pkgs/games/gshogi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub
 , gtk3, gobject-introspection
 , wrapGAppsHook, python3Packages }:
 
@@ -27,7 +27,7 @@ buildPythonApplication rec {
     pycairo
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A graphical implementation of the Shogi board game, also known as Japanese Chess";
     homepage = "http://johncheetham.com/projects/gshogi/";
     license = licenses.gpl3;
diff --git a/pkgs/games/gtypist/default.nix b/pkgs/games/gtypist/default.nix
index ae12c325306b3..52794ca3218b0 100644
--- a/pkgs/games/gtypist/default.nix
+++ b/pkgs/games/gtypist/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, makeWrapper, libiconv, ncurses, perl, fortune}:
+{lib, stdenv, fetchurl, makeWrapper, libiconv, ncurses, perl, fortune}:
 
 stdenv.mkDerivation rec {
   pname = "gtypist";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
        --prefix PATH : "${fortune}/bin" \
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/gtypist";
     description = "Universal typing tutor";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/gweled/default.nix b/pkgs/games/gweled/default.nix
index fce5ec09c79ca..faa6a225ed762 100644
--- a/pkgs/games/gweled/default.nix
+++ b/pkgs/games/gweled/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchbzr, intltool
+{ lib, stdenv, fetchbzr, intltool
 , gtk2, wrapGAppsHook, autoreconfHook, pkgconfig
 , libmikmod, librsvg, libcanberra-gtk2, hicolor-icon-theme }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--disable-setgid" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bejeweled clone game";
     homepage = "https://gweled.org";
     license = licenses.gpl2;
diff --git a/pkgs/games/gzdoom/default.nix b/pkgs/games/gzdoom/default.nix
index a46d8ce1c2c80..edfe13c982189 100644
--- a/pkgs/games/gzdoom/default.nix
+++ b/pkgs/games/gzdoom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper, openal, fluidsynth_1
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper, openal, fluidsynth_1
 , soundfont-fluid, libGL, SDL2, bzip2, zlib, libjpeg, libsndfile, mpg123
 , game-music-emu, pkgconfig }:
 
@@ -70,7 +70,7 @@ let
       makeWrapper $out/lib/gzdoom/gzdoom $out/bin/gzdoom
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/coelckers/gzdoom";
       description =
         "A Doom source port based on ZDoom. It features an OpenGL renderer and lots of new features";
diff --git a/pkgs/games/harmonist/default.nix b/pkgs/games/harmonist/default.nix
index fb9e1cf661765..0705da6bfe949 100644
--- a/pkgs/games/harmonist/default.nix
+++ b/pkgs/games/harmonist/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, buildGoPackage}:
+{lib, stdenv, fetchurl, buildGoPackage}:
 
 buildGoPackage rec {
 
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   postInstall = "mv $out/bin/harmonist.git $out/bin/harmonist";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A stealth coffee-break roguelike game";
     longDescription = ''
       Harmonist is a stealth coffee-break roguelike game. The game has a heavy
diff --git a/pkgs/games/holdingnuts/default.nix b/pkgs/games/holdingnuts/default.nix
index 39ee7af30f34b..2bda182092801 100644
--- a/pkgs/games/holdingnuts/default.nix
+++ b/pkgs/games/holdingnuts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, SDL, qt4 }:
+{ lib, stdenv, fetchurl, cmake, SDL, qt4 }:
 
 let mirror = "http://download.holdingnuts.net";
 in stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ in stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ SDL qt4 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://www.holdingnuts.net/";
     description = "Open Source Poker client and server";
     license     = licenses.gpl3;
diff --git a/pkgs/games/hyperrogue/default.nix b/pkgs/games/hyperrogue/default.nix
index 32882f1689456..08427bd29205f 100644
--- a/pkgs/games/hyperrogue/default.nix
+++ b/pkgs/games/hyperrogue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, SDL, SDL_ttf, SDL_gfx, SDL_mixer, autoreconfHook,
+{ lib, stdenv, fetchFromGitHub, SDL, SDL_ttf, SDL_gfx, SDL_mixer, autoreconfHook,
   libpng, glew, makeDesktopItem }:
 
 stdenv.mkDerivation rec {
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.roguetemple.com/z/hyper/";
     description = "A roguelike game set in hyperbolic geometry";
     maintainers = with maintainers; [ rardiol ];
diff --git a/pkgs/games/instead-launcher/default.nix b/pkgs/games/instead-launcher/default.nix
index 84e3474225ad5..1f03a72390ebb 100644
--- a/pkgs/games/instead-launcher/default.nix
+++ b/pkgs/games/instead-launcher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, instead, qmake4Hook, zlib }:
+{ lib, stdenv, fetchFromGitHub, instead, qmake4Hook, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "instead-launcher";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://instead.syscall.ru/wiki/en/instead-launcher";
     description = "Install and play games from INSTEAD repository";
     license = licenses.gpl2;
diff --git a/pkgs/games/instead/default.nix b/pkgs/games/instead/default.nix
index 8672a7e44940e..02a54dc7604c9 100644
--- a/pkgs/games/instead/default.nix
+++ b/pkgs/games/instead/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL2, SDL2_ttf, SDL2_image, SDL2_mixer, pkgconfig, lua, zlib, unzip }:
+{ lib, stdenv, fetchurl, SDL2, SDL2_ttf, SDL2_image, SDL2_mixer, pkgconfig, lua, zlib, unzip }:
 
 let
   version = "3.3.2";
@@ -62,7 +62,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple text adventure interpreter for Unix and Windows";
     homepage = "https://instead.syscall.ru/";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/games/iortcw/sp.nix b/pkgs/games/iortcw/sp.nix
index 71144ad0eb851..fc1976b0fb175 100644
--- a/pkgs/games/iortcw/sp.nix
+++ b/pkgs/games/iortcw/sp.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, opusfile, libogg, SDL2, openal, freetype
+{ lib, stdenv, fetchFromGitHub, opusfile, libogg, SDL2, openal, freetype
 , libjpeg, curl, makeWrapper }:
 
 stdenv.mkDerivation rec {
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Single player version of game engine for Return to Castle Wolfenstein";
     homepage = src.meta.homepage;
     license = licenses.gpl3;
diff --git a/pkgs/games/ivan/default.nix b/pkgs/games/ivan/default.nix
index c5a93939a0f94..459d1a69633a9 100644
--- a/pkgs/games/ivan/default.nix
+++ b/pkgs/games/ivan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, SDL2, SDL2_mixer, alsaLib, libpng
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, SDL2, SDL2_mixer, alsaLib, libpng
 , pcre, makeDesktopItem }:
 
 stdenv.mkDerivation rec {
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     cp ${ivanDesktop}/share/applications/* $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical roguelike game";
     longDescription = ''
       Iter Vehemens ad Necem (IVAN) is a graphical roguelike game, which currently
diff --git a/pkgs/games/julius/default.nix b/pkgs/games/julius/default.nix
index 435db5772ba02..c11e93670cf7d 100644
--- a/pkgs/games/julius/default.nix
+++ b/pkgs/games/julius/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, SDL2, SDL2_mixer, libpng }:
+{ lib, stdenv, fetchFromGitHub, cmake, SDL2, SDL2_mixer, libpng }:
 
 stdenv.mkDerivation rec {
   pname = "julius";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ SDL2 SDL2_mixer libpng ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source re-implementation of Caesar III";
     homepage = "https://github.com/bvschaik/julius";
     license = licenses.agpl3;
diff --git a/pkgs/games/katago/default.nix b/pkgs/games/katago/default.nix
index a9ac9e8ac598b..9499d47c42f3a 100644
--- a/pkgs/games/katago/default.nix
+++ b/pkgs/games/katago/default.nix
@@ -104,7 +104,7 @@ in env.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : "/run/opengl-driver/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Go engine modeled after AlphaGo Zero";
     homepage    = "https://github.com/lightvector/katago";
     license     = licenses.mit;
diff --git a/pkgs/games/keeperrl/default.nix b/pkgs/games/keeperrl/default.nix
index 68426a4aedfd0..568a0449ac282 100644
--- a/pkgs/games/keeperrl/default.nix
+++ b/pkgs/games/keeperrl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, requireFile
+{ lib, stdenv, fetchFromGitHub, requireFile
 , openal, curl, libogg, libvorbis
 , SDL2, SDL2_image, zlib
 , unfree_assets ? false }:
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
     ${stdenv.lib.optionalString unfree_assets "cp -r data $out/share"}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A dungeon management rogue-like";
     homepage = "https://keeperrl.com/";
     license = licenses.gpl2;
diff --git a/pkgs/games/klavaro/default.nix b/pkgs/games/klavaro/default.nix
index ac2c787d3ff22..a7e6eeef93ce7 100644
--- a/pkgs/games/klavaro/default.nix
+++ b/pkgs/games/klavaro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeWrapper
 , curl
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
   # Hack to avoid TMPDIR in RPATHs.
   preFixup = ''rm -rf "$(pwd)" '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free touch typing tutor program";
     homepage = "http://klavaro.sourceforge.net/";
     changelog = "https://sourceforge.net/p/klavaro/code/HEAD/tree/trunk/ChangeLog";
diff --git a/pkgs/games/lbreakout2/default.nix b/pkgs/games/lbreakout2/default.nix
index ddd7e454efbad..24797952d589b 100644
--- a/pkgs/games/lbreakout2/default.nix
+++ b/pkgs/games/lbreakout2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL, SDL_mixer, zlib, libpng, libintl }:
+{ lib, stdenv, fetchurl, SDL, SDL_mixer, zlib, libpng, libintl }:
 
 stdenv.mkDerivation rec {
   pname = "lbreakout2";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     sha256 = "0vwdlyvh7c4y80q5vp7fyfpzbqk9lq3w8pvavi139njkalbxc14i";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Breakout clone from the LGames series";
     homepage = "http://lgames.sourceforge.net/LBreakout2/";
     license = licenses.gpl2;
diff --git a/pkgs/games/leela-zero/default.nix b/pkgs/games/leela-zero/default.nix
index 5a5e6442ce7f3..4a71fc25c0f24 100644
--- a/pkgs/games/leela-zero/default.nix
+++ b/pkgs/games/leela-zero/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, boost
+{ lib, stdenv, fetchFromGitHub, cmake, boost
 , opencl-headers, ocl-icd, qtbase , zlib }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Go engine modeled after AlphaGo Zero";
     homepage    = "https://github.com/gcp/leela-zero";
     license     = licenses.gpl3;
diff --git a/pkgs/games/lgogdownloader/default.nix b/pkgs/games/lgogdownloader/default.nix
index 6fba4da3a0e43..e19febe42f11e 100644
--- a/pkgs/games/lgogdownloader/default.nix
+++ b/pkgs/games/lgogdownloader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , pkgconfig
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ boost curl htmlcxx jsoncpp liboauth rhash tinyxml-2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unofficial downloader to GOG.com for Linux users. It uses the same API as the official GOGDownloader";
     homepage = "https://github.com/Sude-/lgogdownloader";
     license = licenses.wtfpl;
diff --git a/pkgs/games/liberal-crime-squad/default.nix b/pkgs/games/liberal-crime-squad/default.nix
index 25d8bf3eae53b..d8048b01d21e3 100644
--- a/pkgs/games/liberal-crime-squad/default.nix
+++ b/pkgs/games/liberal-crime-squad/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, autoreconfHook, libiconv, ncurses, SDL2, SDL2_mixer }:
+{ fetchFromGitHub, lib, stdenv, autoreconfHook, libiconv, ncurses, SDL2, SDL2_mixer }:
 
 stdenv.mkDerivation {
   version = "2016-07-06";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A humorous politically themed ncurses game";
     longDescription = ''
       Welcome to Liberal Crime Squad! The Conservatives have taken the Executive, Legislative, and Judicial branches of government. Over time, the Liberal laws of this nation will erode and turn the country into a BACKWOODS YET CORPORATE NIGHTMARE. To prevent this from happening, the Liberal Crime Squad was established. The mood of the country is shifting, and we need to turn things around. Go out on the streets and indoctrinate Conservative automatons. That is, let them see their True Liberal Nature. Then arm them and send them forth to Stop Evil.
diff --git a/pkgs/games/lincity/default.nix b/pkgs/games/lincity/default.nix
index 574b8ead0950a..397ca0cfe8ef0 100644
--- a/pkgs/games/lincity/default.nix
+++ b/pkgs/games/lincity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, libX11, libXext, xorgproto, libICE, libSM, libpng12, zlib }:
+{ lib, stdenv, fetchurl, fetchpatch, libX11, libXext, xorgproto, libICE, libSM, libpng12, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "lincity";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "City simulation game";
     license = licenses.gpl2Plus;
     homepage = "https://sourceforge.net/projects/lincity";
diff --git a/pkgs/games/lincity/ng.nix b/pkgs/games/lincity/ng.nix
index 67f15be1ed3e0..4c3114a92027e 100644
--- a/pkgs/games/lincity/ng.nix
+++ b/pkgs/games/lincity/ng.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, jam, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, jam, pkgconfig
 , zlib, libxml2, libxslt, xorgproto, libX11, libGLU, libGL, SDL
 , SDL_mixer, SDL_image, SDL_ttf, SDL_gfx, physfs
 }:
@@ -46,7 +46,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "City building game";
     license = licenses.gpl2;
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/games/liquidwar/5.nix b/pkgs/games/liquidwar/5.nix
index 3d8cf3840f8b7..8abb1c7d53ee2 100644
--- a/pkgs/games/liquidwar/5.nix
+++ b/pkgs/games/liquidwar/5.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, allegro }:
+{ lib, stdenv, fetchurl, allegro }:
 stdenv.mkDerivation rec {
   version = "5.6.5";
   pname = "liquidwar5";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = [ "-lm" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''The classic version of a quick tactics game LiquidWar'';
     maintainers = [ maintainers.raskin ];
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/liquidwar/default.nix b/pkgs/games/liquidwar/default.nix
index 341d077879c28..09ddcb0346c8f 100644
--- a/pkgs/games/liquidwar/default.nix
+++ b/pkgs/games/liquidwar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xorgproto, libX11, libXrender
+{ lib, stdenv, fetchurl, xorgproto, libX11, libXrender
 , gmp, libjpeg, libpng
 , expat, gettext, perl, guile
 , SDL, SDL_image, SDL_mixer, SDL_ttf
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
   # To avoid problems finding SDL_types.h.
   configureFlags = [ "CFLAGS=-I${SDL.dev}/include/SDL" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quick tactics game";
     homepage = "https://www.gnu.org/software/liquidwar6/";
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/games/ltris/default.nix b/pkgs/games/ltris/default.nix
index 0ea4143bc3d23..d128f6c6c0178 100644
--- a/pkgs/games/ltris/default.nix
+++ b/pkgs/games/ltris/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL, SDL_mixer }:
+{ lib, stdenv, fetchurl, SDL, SDL_mixer }:
 
 stdenv.mkDerivation rec {
   pname = "ltris";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   patchPhase = "patch -p0 < ${./gcc5_compliance.diff}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tetris clone from the LGames series";
     homepage = "http://lgames.sourceforge.net/LBreakout2/";
     license = licenses.gpl2;
diff --git a/pkgs/games/mar1d/default.nix b/pkgs/games/mar1d/default.nix
index 9fe99bff2f92f..1323e1a8ac9c0 100644
--- a/pkgs/games/mar1d/default.nix
+++ b/pkgs/games/mar1d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , libGLU
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     cd src
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "First person Super Mario Bros";
     longDescription = ''
       The original Super Mario Bros as you've never seen it. Step into Mario's
diff --git a/pkgs/games/mari0/default.nix b/pkgs/games/mari0/default.nix
index c3fb66208b80f..cb3349960f02e 100644
--- a/pkgs/games/mari0/default.nix
+++ b/pkgs/games/mari0/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zip, love_11, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchFromGitHub, zip, love_11, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "mari0";
@@ -40,7 +40,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Crossover between Super Mario Bros. and Portal";
     platforms = platforms.linux;
     license = licenses.mit;
diff --git a/pkgs/games/mars/default.nix b/pkgs/games/mars/default.nix
index bab1279fb0503..0fa744677d83b 100644
--- a/pkgs/games/mars/default.nix
+++ b/pkgs/games/mars/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libGLU, libGL, sfml, fribidi, taglib }:
+{ lib, stdenv, fetchFromGitHub, cmake, libGLU, libGL, sfml, fribidi, taglib }:
 stdenv.mkDerivation rec {
   pname = "mars";
   version = "0.7.5";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     EOF
     chmod +x "$out/bin/mars"
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mars-game.sourceforge.net/";
     description = "A game about fighting with ships in a 2D space setting";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/meritous/default.nix b/pkgs/games/meritous/default.nix
index 2958c6a9210fc..e7dd1bee70c92 100644
--- a/pkgs/games/meritous/default.nix
+++ b/pkgs/games/meritous/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, SDL, SDL_image, SDL_mixer, zlib }:
+{ lib, stdenv, fetchFromGitLab, SDL, SDL_image, SDL_mixer, zlib }:
 
 stdenv.mkDerivation {
   pname = "meritous";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "stackprotector" "fortify" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Action-adventure dungeon crawl game";
     homepage = "http://www.asceai.net/meritous/";
     license = licenses.gpl3;
diff --git a/pkgs/games/mindustry/default.nix b/pkgs/games/mindustry/default.nix
index 731a63f90f93a..db2dcdf918079 100644
--- a/pkgs/games/mindustry/default.nix
+++ b/pkgs/games/mindustry/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , makeWrapper
 , makeDesktopItem
 , fetchFromGitHub
@@ -128,7 +128,7 @@ stdenv.mkDerivation rec {
     ${optionalString enableServer installServer}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mindustrygame.github.io/";
     downloadPage = "https://github.com/Anuken/Mindustry/releases";
     description = "A sandbox tower defense game";
diff --git a/pkgs/games/minecraft-server/default.nix b/pkgs/games/minecraft-server/default.nix
index 77181692ec223..bba64fe4b4f9e 100644
--- a/pkgs/games/minecraft-server/default.nix
+++ b/pkgs/games/minecraft-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nixosTests, jre_headless }:
+{ lib, stdenv, fetchurl, nixosTests, jre_headless }:
 stdenv.mkDerivation {
   pname = "minecraft-server";
   version = "1.16.4";
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
     updateScript = ./update.sh;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minecraft Server";
     homepage = "https://minecraft.net";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/games/minecraft/default.nix b/pkgs/games/minecraft/default.nix
index 292b43bec0ad1..814abd698cee4 100644
--- a/pkgs/games/minecraft/default.nix
+++ b/pkgs/games/minecraft/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , nixosTests
 , copyDesktopItems
@@ -145,7 +145,7 @@ stdenv.mkDerivation rec {
 
   desktopItems = [ desktopItem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official launcher for Minecraft, a sandbox-building game";
     homepage = "https://minecraft.net";
     maintainers = with maintainers; [ cpages ryantm infinisil ];
diff --git a/pkgs/games/minetest/default.nix b/pkgs/games/minetest/default.nix
index f49ec1f4a8266..763c7f4bd67d1 100644
--- a/pkgs/games/minetest/default.nix
+++ b/pkgs/games/minetest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, irrlicht, libpng, bzip2, curl, libogg, jsoncpp
+{ lib, stdenv, fetchFromGitHub, cmake, irrlicht, libpng, bzip2, curl, libogg, jsoncpp
 , libjpeg, libXxf86vm, libGLU, libGL, openal, libvorbis, sqlite, luajit
 , freetype, gettext, doxygen, ncurses, graphviz, xorg, gmp, libspatialindex
 , leveldb, postgresql, hiredis, libiconv, OpenGL, OpenAL ? openal, Carbon, Cocoa
@@ -60,7 +60,7 @@ let
       cp -rv ${sources.data}/* $out/share/minetest/games/minetest_game/
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://minetest.net/";
       description = "Infinite-world block sandbox game";
       license = licenses.lgpl21Plus;
diff --git a/pkgs/games/mrrescue/default.nix b/pkgs/games/mrrescue/default.nix
index 367a7a5c5e614..d3caa986b8573 100644
--- a/pkgs/games/mrrescue/default.nix
+++ b/pkgs/games/mrrescue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "mrrescue";
@@ -48,7 +48,7 @@ stdenv.mkDerivation {
     ln -s ${desktopItem}/share/applications/* $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Arcade-style fire fighting game";
     maintainers = with maintainers; [ ];
     platforms = platforms.linux;
diff --git a/pkgs/games/mudlet/default.nix b/pkgs/games/mudlet/default.nix
index 732ead49cc095..b6f66b30769de 100644
--- a/pkgs/games/mudlet/default.nix
+++ b/pkgs/games/mudlet/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, fetchpatch, stdenv, wrapQtAppsHook, git, pcre, pugixml, qtbase, libsForQt5, qtmultimedia, qttools, yajl, libzip, hunspell
+{ fetchFromGitHub, fetchpatch, lib, stdenv, wrapQtAppsHook, git, pcre, pugixml, qtbase, libsForQt5, qtmultimedia, qttools, yajl, libzip, hunspell
 , boost, libGLU, lua, cmake,  which, }:
 
 let
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
       --run "cd $out";
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Crossplatform mud client";
     homepage = "http://mudlet.org/";
     maintainers = [ maintainers.wyvie maintainers.pstn ];
diff --git a/pkgs/games/multimc/default.nix b/pkgs/games/multimc/default.nix
index 66138f79e36a6..6ac2e65b57768 100644
--- a/pkgs/games/multimc/default.nix
+++ b/pkgs/games/multimc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, jdk8, zlib, file, makeWrapper, xorg, libpulseaudio, qtbase }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, jdk8, zlib, file, makeWrapper, xorg, libpulseaudio, qtbase }:
 
 let
   jdk = jdk8;
@@ -26,7 +26,7 @@ in mkDerivation rec {
     wrapProgram $out/bin/multimc --set GAME_LIBRARY_PATH /run/opengl-driver/lib:${libpath} --prefix PATH : ${jdk}/bin/:${xorg.xrandr}/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://multimc.org/";
     description = "A free, open source launcher for Minecraft";
     longDescription = ''
diff --git a/pkgs/games/nethack/default.nix b/pkgs/games/nethack/default.nix
index 1b082537148b8..a922064f78b69 100644
--- a/pkgs/games/nethack/default.nix
+++ b/pkgs/games/nethack/default.nix
@@ -141,7 +141,7 @@ in stdenv.mkDerivation rec {
     ${lib.optionalString (!(x11Mode || qtMode)) "install -Dm 555 util/dlb -t $out/libexec/nethack/"}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rogue-like game";
     homepage = "http://nethack.org/";
     license = "nethack";
diff --git a/pkgs/games/netris/default.nix b/pkgs/games/netris/default.nix
index 994db4e67f8ab..ff898128ca06e 100644
--- a/pkgs/games/netris/default.nix
+++ b/pkgs/games/netris/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation {
   pname = "netris";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     cp ./netris $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free networked version of T*tris";
     license = licenses.gpl2;
     maintainers = with maintainers; [ patryk27 ];
diff --git a/pkgs/games/newtonwars/default.nix b/pkgs/games/newtonwars/default.nix
index 093f071c7233c..0da6d9352e06a 100644
--- a/pkgs/games/newtonwars/default.nix
+++ b/pkgs/games/newtonwars/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, freeglut, libGLU, libGL }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, freeglut, libGLU, libGL }:
 
 stdenv.mkDerivation {
   pname = "newtonwars";
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
       --prefix LD_LIBRARY_PATH ":" ${libGL}/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A space battle game with gravity as the main theme";
     maintainers = with maintainers; [ pSub ];
     platforms = platforms.linux;
diff --git a/pkgs/games/ninvaders/default.nix b/pkgs/games/ninvaders/default.nix
index 7005ef8512f8d..df4a3ad111b67 100644
--- a/pkgs/games/ninvaders/default.nix
+++ b/pkgs/games/ninvaders/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, ncurses }:
+{ lib, stdenv, fetchFromGitHub, cmake, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "ninvaders";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Space Invaders clone based on ncurses";
     homepage = "http://ninvaders.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/games/nottetris2/default.nix b/pkgs/games/nottetris2/default.nix
index dde35e4fe3204..53e7dec08032b 100644
--- a/pkgs/games/nottetris2/default.nix
+++ b/pkgs/games/nottetris2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zip, love_0_7, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchFromGitHub, zip, love_0_7, makeWrapper, makeDesktopItem }:
 
 let
   pname = "nottetris2";
@@ -40,7 +40,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "It's like Tetris, but it's not";
     platforms = platforms.linux;
     license = licenses.wtfpl;
diff --git a/pkgs/games/nudoku/default.nix b/pkgs/games/nudoku/default.nix
index 0e1bd9eb4a9db..d10807071a97c 100644
--- a/pkgs/games/nudoku/default.nix
+++ b/pkgs/games/nudoku/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, gettext, ncurses }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, gettext, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "nudoku";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = stdenv.lib.optional stdenv.hostPlatform.isMusl "--disable-nls";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An ncurses based sudoku game";
     homepage = "http://jubalh.github.io/nudoku/";
     license = licenses.gpl3;
diff --git a/pkgs/games/onscripter-en/default.nix b/pkgs/games/onscripter-en/default.nix
index ebcf755780d30..bcd33eb989286 100644
--- a/pkgs/games/onscripter-en/default.nix
+++ b/pkgs/games/onscripter-en/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , libpng, libjpeg, libogg, libvorbis, freetype, smpeg
 , SDL, SDL_image, SDL_mixer, SDL_ttf }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     sed -i 's/.dll//g' Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Japanese visual novel scripting engine";
     homepage = "http://unclemion.com/onscripter/";
     license = licenses.gpl2;
diff --git a/pkgs/games/openclonk/default.nix b/pkgs/games/openclonk/default.nix
index 7343c79434f2a..db9b4760b2535 100644
--- a/pkgs/games/openclonk/default.nix
+++ b/pkgs/games/openclonk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkgconfig
+{ lib, stdenv, fetchurl, cmake, pkgconfig
 , SDL2, libvorbis, libogg, libjpeg, libpng, freetype, glew, tinyxml, openal
 , freealut, readline, gcc-unwrapped
 , enableSoundtrack ? false # Enable the "Open Clonk Soundtrack - Explorers Journey" by David Oerther
@@ -35,7 +35,7 @@ in stdenv.mkDerivation rec {
 
   cmakeBuildType = "RelWithDebInfo";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free multiplayer action game in which you control clonks, small but witty and nimble humanoid beings";
     homepage = "https://www.openclonk.org";
     license = if enableSoundtrack then licenses.unfreeRedistributable else licenses.isc;
diff --git a/pkgs/games/opendune/default.nix b/pkgs/games/opendune/default.nix
index 591bea12297dd..cf15568b37df6 100644
--- a/pkgs/games/opendune/default.nix
+++ b/pkgs/games/opendune/default.nix
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dune, Reinvented";
     homepage = "https://github.com/OpenDUNE/OpenDUNE";
     license = licenses.gpl2;
diff --git a/pkgs/games/opendungeons/default.nix b/pkgs/games/opendungeons/default.nix
index f0cb8120170f3..d18682b8807f1 100644
--- a/pkgs/games/opendungeons/default.nix
+++ b/pkgs/games/opendungeons/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ogre, cegui, boost, sfml, openal, cmake, ois, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, ogre, cegui, boost, sfml, openal, cmake, ois, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "opendungeons";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ ogre cegui boost sfml openal ois ];
   NIX_LDFLAGS = "-lpthread";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source, real time strategy game sharing game elements with the Dungeon Keeper series and Evil Genius";
     homepage = "https://opendungeons.github.io";
     license = with licenses; [ gpl3Plus zlib mit cc-by-sa-30 cc0 ofl cc-by-30 ];
diff --git a/pkgs/games/openjk/default.nix b/pkgs/games/openjk/default.nix
index a51a0f13cc49b..ecb2cd3c46c24 100644
--- a/pkgs/games/openjk/default.nix
+++ b/pkgs/games/openjk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeDesktopItem, makeWrapper, cmake, libjpeg, zlib, libpng, libGL, SDL2 }:
+{ lib, stdenv, fetchFromGitHub, makeDesktopItem, makeWrapper, cmake, libjpeg, zlib, libpng, libGL, SDL2 }:
 
 let
   jamp = makeDesktopItem rec {
@@ -53,7 +53,7 @@ in stdenv.mkDerivation {
     ln -s ${jasp}/share/applications/* $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open-source engine for Star Wars Jedi Academy game";
     homepage = "https://github.com/JACoders/OpenJK";
     license = licenses.gpl2;
diff --git a/pkgs/games/openmw/default.nix b/pkgs/games/openmw/default.nix
index 34897c690aadc..23572998d034a 100644
--- a/pkgs/games/openmw/default.nix
+++ b/pkgs/games/openmw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qtbase, openscenegraph, mygui, bullet, ffmpeg_3
+{ lib, stdenv, fetchFromGitHub, qtbase, openscenegraph, mygui, bullet, ffmpeg_3
 , boost, cmake, SDL2, unshield, openal, libXt, pkg-config }:
 
 let
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     "-DDESIRED_QT_VERSION:INT=5"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An unofficial open source engine reimplementation of the game Morrowind";
     homepage = "http://openmw.org";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/openmw/tes3mp.nix b/pkgs/games/openmw/tes3mp.nix
index df332c0e5bf32..47b383a82bd9d 100644
--- a/pkgs/games/openmw/tes3mp.nix
+++ b/pkgs/games/openmw/tes3mp.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, openmw, fetchFromGitHub, luajit, makeWrapper, mygui }:
+{ lib, stdenv, cmake, openmw, fetchFromGitHub, luajit, makeWrapper, mygui }:
 
 # revisions are taken from https://github.com/GrimKriegor/TES3MP-deploy
 
@@ -84,7 +84,7 @@ in openmw.overrideAttrs (oldAttrs: rec {
       --run "cd $out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiplayer for TES3:Morrowind based on OpenMW";
     homepage = "https://tes3mp.com/";
     license = licenses.gpl3;
diff --git a/pkgs/games/openrct2/default.nix b/pkgs/games/openrct2/default.nix
index 1004be6df7ddb..96d79a8744e87 100644
--- a/pkgs/games/openrct2/default.nix
+++ b/pkgs/games/openrct2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , SDL2, cmake, curl, duktape, fontconfig, freetype, icu, jansson, libGLU
 , libiconv, libpng, libpthreadstubs, libzip, nlohmann_json, openssl, pkgconfig
 , speexdsp, zlib
@@ -70,7 +70,7 @@ stdenv.mkDerivation {
 
   preFixup = "ln -s $out/share/openrct2 $out/bin/data";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source re-implementation of RollerCoaster Tycoon 2 (original game required)";
     homepage = "https://openrct2.io/";
     license = licenses.gpl3;
diff --git a/pkgs/games/openrw/default.nix b/pkgs/games/openrw/default.nix
index b53850a87438e..7258ed6550c5f 100644
--- a/pkgs/games/openrw/default.nix
+++ b/pkgs/games/openrw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, cmake, sfml, libGLU, libGL, bullet, glm, libmad, xlibsWrapper, openal
+{ lib, stdenv, fetchgit, cmake, sfml, libGLU, libGL, bullet, glm, libmad, xlibsWrapper, openal
 , SDL2, boost, ffmpeg_3, Cocoa, OpenAL }:
 
 stdenv.mkDerivation {
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     sfml libGLU libGL bullet glm libmad xlibsWrapper openal SDL2 boost ffmpeg_3
   ] ++ stdenv.lib.optionals stdenv.isDarwin [ OpenAL Cocoa ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unofficial open source recreation of the classic Grand Theft Auto III game executable";
     homepage = "https://github.com/rwengine/openrw";
     license = licenses.gpl3;
diff --git a/pkgs/games/openspades/default.nix b/pkgs/games/openspades/default.nix
index 2bfdd563c8aa1..fdd429e376fe1 100644
--- a/pkgs/games/openspades/default.nix
+++ b/pkgs/games/openspades/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, fetchpatch, cmake, unzip, zip, file
+{ lib, stdenv, fetchurl, fetchFromGitHub, fetchpatch, cmake, unzip, zip, file
 , curl, glew , libGL, SDL2, SDL2_image, zlib, freetype, imagemagick
 , openal , opusfile, libogg
 , Cocoa
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_LINK = "-lopenal";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A compatible client of Ace of Spades 0.75";
     homepage    = "https://github.com/yvt/openspades/";
     license     = licenses.gpl3;
diff --git a/pkgs/games/openttd/default.nix b/pkgs/games/openttd/default.nix
index bab4e510e7daf..8c0755127cbea 100644
--- a/pkgs/games/openttd/default.nix
+++ b/pkgs/games/openttd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchzip, pkgconfig, which, SDL2, libpng, zlib, xz, freetype, fontconfig, libxdg_basedir
+{ lib, stdenv, fetchurl, fetchzip, pkgconfig, which, SDL2, libpng, zlib, xz, freetype, fontconfig, libxdg_basedir
 , withOpenGFX ? true, withOpenSFX ? true, withOpenMSX ? true
 , withFluidSynth ? true, audioDriver ? "alsa", fluidsynth, soundfont-fluid, procps
 , writeScriptBin, makeWrapper, runtimeShell
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
     ''}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''Open source clone of the Microprose game "Transport Tycoon Deluxe"'';
     longDescription = ''
       OpenTTD is a transportation economics simulator. In single player mode,
diff --git a/pkgs/games/openxray/default.nix b/pkgs/games/openxray/default.nix
index 33a0ae1059736..8fe47d31ca730 100644
--- a/pkgs/games/openxray/default.nix
+++ b/pkgs/games/openxray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, glew, freeimage,  liblockfile
+{ lib, stdenv, fetchFromGitHub, cmake, glew, freeimage,  liblockfile
 , openal, libtheora, SDL2, lzo, libjpeg, libogg, tbb
 , pcre, makeWrapper, fetchpatch }:
 
@@ -27,7 +27,7 @@ let
 
     doCheck = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Crypto++, a free C++ class library of cryptographic schemes";
       homepage = "https://cryptopp.com/";
       license = with licenses; [ boost publicDomain ];
@@ -65,7 +65,7 @@ in stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Improved version of the X-Ray Engine, the game engine used in the world-famous S.T.A.L.K.E.R. game series by GSC Game World";
     homepage = src.meta.homepage;
     license = licenses.unfree // {
diff --git a/pkgs/games/orthorobot/default.nix b/pkgs/games/orthorobot/default.nix
index a2a66f6838bcc..e1067645b620a 100644
--- a/pkgs/games/orthorobot/default.nix
+++ b/pkgs/games/orthorobot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, zip, love, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, fetchFromGitHub, zip, love, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "orthorobot";
@@ -46,7 +46,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recharge the robot";
     maintainers = with maintainers; [ leenaars ];
     platforms = platforms.linux;
diff --git a/pkgs/games/pacvim/default.nix b/pkgs/games/pacvim/default.nix
index 6e28753b4f319..dc2c216b1bf19 100644
--- a/pkgs/games/pacvim/default.nix
+++ b/pkgs/games/pacvim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation {
   pname = "pacvim";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
   buildInputs = [ ncurses ];
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jmoon018/PacVim";
     description = "A game that teaches you vim commands";
     maintainers = with maintainers; [ infinisil ];
diff --git a/pkgs/games/performous/default.nix b/pkgs/games/performous/default.nix
index 96b07e9787e8f..d5128aaec0771 100644
--- a/pkgs/games/performous/default.nix
+++ b/pkgs/games/performous/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, gettext
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, gettext
 , glibmm, libxmlxx, pango, librsvg
 , SDL2, glew, boost, libav, portaudio, epoxy
 }:
@@ -7,7 +7,7 @@ stdenv.mkDerivation rec {
   pname = "performous";
   version = "1.1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Karaoke, band and dancing game";
     homepage    = "http://performous.org/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/games/pioneer/default.nix b/pkgs/games/pioneer/default.nix
index 3f3a2dd363d46..d801e7c82ec4e 100644
--- a/pkgs/games/pioneer/default.nix
+++ b/pkgs/games/pioneer/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, cmake, pkgconfig, curl, libsigcxx, SDL2
+{ fetchFromGitHub, lib, stdenv, cmake, pkgconfig, curl, libsigcxx, SDL2
 , SDL2_image, freetype, libvorbis, libpng, assimp, libGLU, libGL
 , glew
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     export PIONEER_DATA_DIR="$out/share/pioneer/data";
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A space adventure game set in the Milky Way galaxy at the turn of the 31st century";
     homepage = "https://pioneerspacesim.net";
     license = with licenses; [
diff --git a/pkgs/games/pioneers/default.nix b/pkgs/games/pioneers/default.nix
index 882303ab02328..9e292da8c98b1 100644
--- a/pkgs/games/pioneers/default.nix
+++ b/pkgs/games/pioneers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkg-config
 , intltool
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ gtk3 libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Addicting game based on The Settlers of Catan";
     homepage = "http://pio.sourceforge.net/";  # https does not work
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/planetaryannihilation/default.nix b/pkgs/games/planetaryannihilation/default.nix
index a42eb672e62e5..768e0a1d724b1 100644
--- a/pkgs/games/planetaryannihilation/default.nix
+++ b/pkgs/games/planetaryannihilation/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, config, fetchurl, patchelf, makeWrapper, gtk2, glib, udev, alsaLib, atk
+{ lib, stdenv, config, fetchurl, patchelf, makeWrapper, gtk2, glib, udev, alsaLib, atk
 , nspr, fontconfig, cairo, pango, nss, freetype, gnome2, gdk-pixbuf, curl, systemd, xorg }:
 
 # TODO: use dynamic attributes once Nix 1.7 is out
@@ -43,7 +43,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.uberent.com/pa/";
     description = "Next-generation RTS that takes the genre to a planetary scale";
     license = stdenv.lib.licenses.unfree;
diff --git a/pkgs/games/privateer/default.nix b/pkgs/games/privateer/default.nix
index 9f555b88bcb25..f3ea6dc8cb192 100644
--- a/pkgs/games/privateer/default.nix
+++ b/pkgs/games/privateer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchsvn, boost, cmake, ffmpeg_3, freeglut, glib,
+{ lib, stdenv, fetchsvn, boost, cmake, ffmpeg_3, freeglut, glib,
   gtk2, libjpeg, libpng, libpthreadstubs, libvorbis, libXau, libXdmcp,
   libXmu, libGLU, libGL, openal, pixman, pkg-config, python27, SDL }:
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
     cp vegaserver $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://privateer.sourceforge.net/";
     description = "Adventure space flight simulation computer game";
     license = licenses.gpl2Plus; # and a special license for art data
diff --git a/pkgs/games/pro-office-calculator/default.nix b/pkgs/games/pro-office-calculator/default.nix
index 35571ff149ac6..dbe2db363ea1a 100644
--- a/pkgs/games/pro-office-calculator/default.nix
+++ b/pkgs/games/pro-office-calculator/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, tinyxml-2, cmake, qtbase, qtmultimedia }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, tinyxml-2, cmake, qtbase, qtmultimedia }:
 mkDerivation rec {
   version = "1.0.13";
   pname = "pro-office-calculator";
@@ -14,7 +14,7 @@ mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A completely normal office calculator";
     homepage = "https://proofficecalculator.com/";
     maintainers = [ maintainers.pmiddend ];
diff --git a/pkgs/games/pysolfc/default.nix b/pkgs/games/pysolfc/default.nix
index 31dbe7f6bbcc5..c765a1cbdf5bb 100644
--- a/pkgs/games/pysolfc/default.nix
+++ b/pkgs/games/pysolfc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, buildPythonApplication, python3Packages
+{ lib, stdenv, fetchzip, buildPythonApplication, python3Packages
   , desktop-file-utils, freecell-solver }:
 
 buildPythonApplication rec {
@@ -39,7 +39,7 @@ buildPythonApplication rec {
   # No tests in archive
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of more than 1000 solitaire card games";
     homepage = "https://pysolfc.sourceforge.io";
     license = licenses.gpl3;
diff --git a/pkgs/games/qqwing/default.nix b/pkgs/games/qqwing/default.nix
index 43fa45ca4325c..3fadd73ce18e5 100644
--- a/pkgs/games/qqwing/default.nix
+++ b/pkgs/games/qqwing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl, autoconf, automake, libtool }:
+{ lib, stdenv, fetchFromGitHub, perl, autoconf, automake, libtool }:
 
 stdenv.mkDerivation rec {
   pname = "qqwing";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=$(out)" "tgz" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://qqwing.com";
     description = "Sudoku generating and solving software";
     license = licenses.gpl2;
diff --git a/pkgs/games/quake2/yquake2/default.nix b/pkgs/games/quake2/yquake2/default.nix
index 3d59fc8afb03e..57405d9abd389 100644
--- a/pkgs/games/quake2/yquake2/default.nix
+++ b/pkgs/games/quake2/yquake2/default.nix
@@ -55,7 +55,7 @@ let
       cp $src/stuff/yq2.cfg $out/share/games/quake2
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Yamagi Quake II client";
       homepage = "https://www.yamagi.org/quake2/";
       license = licenses.gpl2;
diff --git a/pkgs/games/quake2/yquake2/games.nix b/pkgs/games/quake2/yquake2/games.nix
index 091853e485f69..02b130489115f 100644
--- a/pkgs/games/quake2/yquake2/games.nix
+++ b/pkgs/games/quake2/yquake2/games.nix
@@ -44,7 +44,7 @@ let
       cp Release/* $out/lib/yquake2/${id}
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       inherit (data) description;
       homepage = "https://www.yamagi.org/quake2/";
       license = licenses.unfree;
diff --git a/pkgs/games/quake3/content/demo.nix b/pkgs/games/quake3/content/demo.nix
index 0d8a64f14cdc7..36d0396ec7960 100644
--- a/pkgs/games/quake3/content/demo.nix
+++ b/pkgs/games/quake3/content/demo.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   version = "1.11-6";
@@ -20,7 +20,7 @@ in stdenv.mkDerivation {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quake 3 Arena demo content";
     license = licenses.unfreeRedistributable;
     platforms = platforms.all;
diff --git a/pkgs/games/quake3/content/pointrelease.nix b/pkgs/games/quake3/content/pointrelease.nix
index e34064d93b057..d9c9a55ddce97 100644
--- a/pkgs/games/quake3/content/pointrelease.nix
+++ b/pkgs/games/quake3/content/pointrelease.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   version = "1.32b-3";
@@ -20,7 +20,7 @@ in stdenv.mkDerivation {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quake 3 Arena point release";
     license = licenses.unfreeRedistributable;
     platforms = platforms.all;
diff --git a/pkgs/games/quake3/ioquake/default.nix b/pkgs/games/quake3/ioquake/default.nix
index 133e679b460cd..e006507a63353 100644
--- a/pkgs/games/quake3/ioquake/default.nix
+++ b/pkgs/games/quake3/ioquake/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which, pkg-config, SDL2, libGL, openalSoft
+{ lib, stdenv, fetchFromGitHub, which, pkg-config, SDL2, libGL, openalSoft
 , curl, speex, opusfile, libogg, libvorbis, libopus, libjpeg, mumble, freetype
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     mkdir -p $out/baseq3
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ioquake3.org/";
     description = "First person shooter engine based on the Quake 3: Arena and Quake 3: Team Arena";
     license = licenses.gpl2Only;
diff --git a/pkgs/games/quake3/quake3e/default.nix b/pkgs/games/quake3/quake3e/default.nix
index 0e3e74ae7a739..691406160d1d6 100644
--- a/pkgs/games/quake3/quake3e/default.nix
+++ b/pkgs/games/quake3/quake3e/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, curl, libGL, libX11, libXxf86dga, alsaLib, libXrandr, libXxf86vm, libXext, fetchFromGitHub }:
+{ lib, stdenv, curl, libGL, libX11, libXxf86dga, alsaLib, libXrandr, libXxf86vm, libXext, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "Quake3e";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     cp build/*/*x64 $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ec-/Quake3e";
     description = "Improved Quake III Arena engine";
     license = licenses.gpl2;
diff --git a/pkgs/games/quakespasm/vulkan.nix b/pkgs/games/quakespasm/vulkan.nix
index 73639fd7553ce..fbca6e0eb540b 100644
--- a/pkgs/games/quakespasm/vulkan.nix
+++ b/pkgs/games/quakespasm/vulkan.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, SDL2, gzip, libvorbis, libmad, vulkan-headers, vulkan-loader }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, SDL2, gzip, libvorbis, libmad, vulkan-headers, vulkan-loader }:
 
 stdenv.mkDerivation rec {
   pname = "vkquake";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Vulkan Quake port based on QuakeSpasm";
     homepage = src.meta.homepage;
     longDescription = ''
diff --git a/pkgs/games/r2mod_cli/default.nix b/pkgs/games/r2mod_cli/default.nix
index d49dda36e5707..edf53482ac3f2 100644
--- a/pkgs/games/r2mod_cli/default.nix
+++ b/pkgs/games/r2mod_cli/default.nix
@@ -2,7 +2,7 @@
 , jq
 , makeWrapper
 , p7zip
-, stdenv
+, lib, stdenv
 }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/r2mod --prefix PATH : "${stdenv.lib.makeBinPath [ jq p7zip ]}";
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Risk of Rain 2 Mod Manager in Bash";
     homepage = "https://github.com/foldex/r2mod_cli";
     license = licenses.gpl3Only;
diff --git a/pkgs/games/redeclipse/default.nix b/pkgs/games/redeclipse/default.nix
index d99d7ccb1d90d..4b24de28c4512 100644
--- a/pkgs/games/redeclipse/default.nix
+++ b/pkgs/games/redeclipse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchurl, fetchpatch
 , curl, ed, pkgconfig, freetype, zlib, libX11
 , SDL2, SDL2_image, SDL2_mixer
 }:
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
       cp -R -t $out/share/redeclipse/data/ data/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A first person arena shooter, featuring parkour, impulse boosts, and more";
     longDescription = ''
       Red Eclipse is a fun-filled new take on the first person arena shooter,
diff --git a/pkgs/games/riko4/default.nix b/pkgs/games/riko4/default.nix
index 247c6575ec388..7014bf9ca21be 100644
--- a/pkgs/games/riko4/default.nix
+++ b/pkgs/games/riko4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, SDL2, libGLU, luajit, curl, curlpp }:
+{ lib, stdenv, fetchFromGitHub, cmake, SDL2, libGLU, luajit, curl, curlpp }:
 
 let
   # Newer versions of sdl-gpu don't work with Riko4 (corrupted graphics),
@@ -16,7 +16,7 @@ let
     buildInputs = [ SDL2 libGLU ];
     nativeBuildInputs = [ cmake ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/grimfang4/sdl-gpu";
       description = "A library for high-performance, modern 2D graphics with SDL written in C";
       license = licenses.mit;
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/riko4
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/incinirate/Riko4";
     description = "Fantasy console for pixel art game development";
     license = licenses.mit;
diff --git a/pkgs/games/rimshot/default.nix b/pkgs/games/rimshot/default.nix
index 2e5087319f0c0..381d00bf992c5 100644
--- a/pkgs/games/rimshot/default.nix
+++ b/pkgs/games/rimshot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, love, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, unzip, love, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "rimshot";
@@ -51,7 +51,7 @@ stdenv.mkDerivation {
     ln -s ${desktopItem}/share/applications/* $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create your own music";
     maintainers = with maintainers; [ leenaars ];
     platforms = platforms.linux;
diff --git a/pkgs/games/rocksndiamonds/default.nix b/pkgs/games/rocksndiamonds/default.nix
index ebced6467d2aa..c31bf78a35529 100644
--- a/pkgs/games/rocksndiamonds/default.nix
+++ b/pkgs/games/rocksndiamonds/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, SDL2, SDL2_image, SDL2_mixer, SDL2_net }:
+{ lib, stdenv, fetchurl, makeDesktopItem, SDL2, SDL2_image, SDL2_mixer, SDL2_net }:
 
 stdenv.mkDerivation rec {
   name = "${project}-${version}";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scrolling tile-based arcade style puzzle game";
     homepage = "https://www.artsoft.org/rocksndiamonds/";
     license = licenses.gpl2;
diff --git a/pkgs/games/rogue/default.nix b/pkgs/games/rogue/default.nix
index 592f897f20f18..1e215c813b531 100644
--- a/pkgs/games/rogue/default.nix
+++ b/pkgs/games/rogue/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, ncurses}:
+{lib, stdenv, fetchurl, ncurses}:
 
 stdenv.mkDerivation {
   name = "rogue-5.4.4";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
   # Fix build for recent ncurses versions
   NIX_CFLAGS_COMPILE = "-DNCURSES_INTERNALS=1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://rogue.rogueforge.net/rogue-5-4/";
     description = "The final version of the original Rogue game developed for the UNIX operating system";
     platforms = platforms.all;
diff --git a/pkgs/games/rrootage/default.nix b/pkgs/games/rrootage/default.nix
index 459ff238b4a47..6cd5919c4e8f4 100644
--- a/pkgs/games/rrootage/default.nix
+++ b/pkgs/games/rrootage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchurl, SDL, SDL_mixer, bulletml }:
+{ lib, stdenv, fetchpatch, fetchurl, SDL, SDL_mixer, bulletml }:
 
 let
   version = "0.23a";
@@ -72,7 +72,7 @@ in stdenv.mkDerivation {
     install -m 644 readme_linux "$out"/share/doc/rrootage/README
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Abstract shooter created by Kenta Cho";
     homepage = "http://rrootage.sourceforge.net/";
     license = licenses.bsd2;
diff --git a/pkgs/games/sauerbraten/default.nix b/pkgs/games/sauerbraten/default.nix
index 277c195d44241..2d5f3d9a3c710 100644
--- a/pkgs/games/sauerbraten/default.nix
+++ b/pkgs/games/sauerbraten/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, SDL2, SDL2_image, SDL2_mixer
+{ lib, stdenv, fetchzip, SDL2, SDL2_image, SDL2_mixer
 , zlib, makeWrapper
 }:
 
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
       --add-flags "-q\''${HOME}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free multiplayer & singleplayer first person shooter, the successor of the Cube FPS";
     maintainers = with maintainers; [ raskin ajs124 ];
     hydraPlatforms =
diff --git a/pkgs/games/scid-vs-pc/default.nix b/pkgs/games/scid-vs-pc/default.nix
index 1ff0a0dc728be..bb33faf7374bb 100644
--- a/pkgs/games/scid-vs-pc/default.nix
+++ b/pkgs/games/scid-vs-pc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, tcl, tk, libX11, zlib, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, tcl, tk, libX11, zlib, makeWrapper, makeDesktopItem }:
 
 stdenv.mkDerivation rec {
   pname = "scid-vs-pc";
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     categories = "Game;BoardGame;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chess database with play and training functionality";
     homepage = "http://scidvspc.sourceforge.net/";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/games/scorched3d/default.nix b/pkgs/games/scorched3d/default.nix
index b7f448e119a5b..47c17ce60d7a4 100644
--- a/pkgs/games/scorched3d/default.nix
+++ b/pkgs/games/scorched3d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libGLU, libGL, glew, pkgconfig, openalSoft, freealut, wxGTK, libogg
+{ lib, stdenv, fetchurl, libGLU, libGL, glew, pkgconfig, openalSoft, freealut, wxGTK, libogg
 , freetype, libvorbis, fftwSinglePrec, SDL, SDL_net, expat, libjpeg, libpng }:
 
 stdenv.mkDerivation rec {
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = "-lopenal";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://scorched3d.co.uk/";
     description = "3D Clone of the classic Scorched Earth";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/scummvm/default.nix b/pkgs/games/scummvm/default.nix
index 02df60c829f20..20d781db23d9c 100644
--- a/pkgs/games/scummvm/default.nix
+++ b/pkgs/games/scummvm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nasm
+{ lib, stdenv, fetchurl, nasm
 , alsaLib, curl, flac, fluidsynth, freetype, libjpeg, libmad, libmpeg2, libogg, libvorbis, libGLU, libGL, SDL2, zlib
 }:
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     sed -i "s/-c -s/-c -s --strip-program=''${STRIP@Q}/" ports.mk
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Program to run certain classic graphical point-and-click adventure games (such as Monkey Island)";
     homepage = "https://www.scummvm.org/";
     license = licenses.gpl2;
diff --git a/pkgs/games/scummvm/games.nix b/pkgs/games/scummvm/games.nix
index 0165a797c3a6e..2ffd176ccf6ef 100644
--- a/pkgs/games/scummvm/games.nix
+++ b/pkgs/games/scummvm/games.nix
@@ -51,7 +51,7 @@ let
         runHook postInstall
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.scummvm.org";
         license = licenses.free; # refer to the readme for exact wording
         maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/games/sfrotz/default.nix b/pkgs/games/sfrotz/default.nix
index 6e4839703a1c9..e6b959371995e 100644
--- a/pkgs/games/sfrotz/default.nix
+++ b/pkgs/games/sfrotz/default.nix
@@ -10,7 +10,7 @@
 , pkg-config
 , SDL2
 , SDL2_mixer
-, stdenv
+, lib, stdenv
 , zlib }:
 
 stdenv.mkDerivation rec {
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
   buildPhase = "make sdl";
   installTargets = [ "install_sfrotz" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Interpreter for Infocom and other Z-Machine games (SDL interface)";
     longDescription = ''
diff --git a/pkgs/games/sgt-puzzles/default.nix b/pkgs/games/sgt-puzzles/default.nix
index 4cac596282e21..24ea62d9db83d 100644
--- a/pkgs/games/sgt-puzzles/default.nix
+++ b/pkgs/games/sgt-puzzles/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, desktop-file-utils
+{ lib, stdenv, fetchurl, desktop-file-utils
 , gtk3, libX11
 , makeWrapper, pkgconfig, perl, autoreconfHook, wrapGAppsHook
 }:
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -Wno-error"
     cp Makefile.gtk Makefile
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simon Tatham's portable puzzle collection";
     license = licenses.mit;
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/games/shattered-pixel-dungeon/default.nix b/pkgs/games/shattered-pixel-dungeon/default.nix
index f3808102bd1d5..f8aa4397ddad8 100644
--- a/pkgs/games/shattered-pixel-dungeon/default.nix
+++ b/pkgs/games/shattered-pixel-dungeon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , makeWrapper
 , fetchFromGitHub
 , nixosTests
@@ -71,7 +71,7 @@ in stdenv.mkDerivation rec {
     shattered-pixel-dungeon-starts = nixosTests.shattered-pixel-dungeon;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://shatteredpixel.com/";
     downloadPage = "https://github.com/00-Evan/shattered-pixel-dungeon/releases";
     description = "Traditional roguelike game with pixel-art graphics and simple interface";
diff --git a/pkgs/games/sienna/default.nix b/pkgs/games/sienna/default.nix
index bedd446e34cca..0a38723368e82 100644
--- a/pkgs/games/sienna/default.nix
+++ b/pkgs/games/sienna/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "sienna";
@@ -48,7 +48,7 @@ stdenv.mkDerivation {
     ln -s ${desktopItem}/share/applications/* $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast-paced one button platformer";
     maintainers = with maintainers; [ leenaars ];
     platforms = platforms.linux;
diff --git a/pkgs/games/simutrans/default.nix b/pkgs/games/simutrans/default.nix
index 5d33ae99149a9..b45a182cc0146 100644
--- a/pkgs/games/simutrans/default.nix
+++ b/pkgs/games/simutrans/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, unzip, zlib, libpng, bzip2, SDL, SDL_mixer
+{ lib, stdenv, fetchurl, pkgconfig, unzip, zlib, libpng, bzip2, SDL, SDL_mixer
 , buildEnv, config, runtimeShell
 }:
 
@@ -152,7 +152,7 @@ let
       mv build/default/sim $out/bin/simutrans
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A simulation game in which the player strives to run a successful transport system";
       longDescription = ''
         Simutrans is a cross-platform simulation game in which the
diff --git a/pkgs/games/sm64ex/default.nix b/pkgs/games/sm64ex/default.nix
index e5aeb84fbf111..1e678a49f05cf 100644
--- a/pkgs/games/sm64ex/default.nix
+++ b/pkgs/games/sm64ex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3
 , pkg-config
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     cp build/${region}_pc/sm64.${region}.f3dex2e $out/bin/sm64ex
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sm64pc/sm64ex";
     description = "Super Mario 64 port based off of decompilation";
     longDescription = ''
diff --git a/pkgs/games/snake4/default.nix b/pkgs/games/snake4/default.nix
index 4c4161d5049a4..e5419cef249e7 100644
--- a/pkgs/games/snake4/default.nix
+++ b/pkgs/games/snake4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, shhmsg, shhopt, xorg }:
+{ lib, stdenv, fetchurl, shhmsg, shhopt, xorg }:
 
 stdenv.mkDerivation rec {
   name = "snake4-1.0.14";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
                    "INSTBINDIR=$(out)/bin"
                    "INSTMANDIR=$(out)/man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A game starring a fruit-eating snake";
     homepage = "https://shh.thathost.com/pub-unix/html/snake4.html";
     license = licenses.artistic1;
diff --git a/pkgs/games/snipes/default.nix b/pkgs/games/snipes/default.nix
index 37993e32a5d1e..66188ba0efe8f 100644
--- a/pkgs/games/snipes/default.nix
+++ b/pkgs/games/snipes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, SDL2, SDL2_ttf }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, SDL2, SDL2_ttf }:
 
 let
   font = fetchurl {
@@ -36,7 +36,7 @@ in stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern port of the classic 1982 text-mode game Snipes";
     homepage    = "https://www.vogons.org/viewtopic.php?f=7&t=49073";
     license     = licenses.free; # This reverse-engineered source code is released with the original authors' permission.
diff --git a/pkgs/games/soi/default.nix b/pkgs/games/soi/default.nix
index 0e4722cebb1ad..c9d35a08dc236 100644
--- a/pkgs/games/soi/default.nix
+++ b/pkgs/games/soi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake
+{ lib, stdenv, fetchurl, cmake
 , boost, eigen2, lua, luabind, libGLU, libGL, SDL }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "-DEIGEN_INCLUDE_DIR=${eigen2}/include/eigen2"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A physics-based puzzle game";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/games/space-orbit/default.nix b/pkgs/games/space-orbit/default.nix
index e9fe6257fb63e..6794a340310a4 100644
--- a/pkgs/games/space-orbit/default.nix
+++ b/pkgs/games/space-orbit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , libGLU, libGL, libXi, libXt, libXext, libX11, libXmu, freeglut
 }:
 
@@ -37,7 +37,7 @@ EOF
     chmod a+x $out/bin/space-orbit
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A space combat simulator";
     license = licenses.gpl2;
     platforms = platforms.all;
diff --git a/pkgs/games/spring/default.nix b/pkgs/games/spring/default.nix
index 9583895e17a3e..9bc204c08d045 100644
--- a/pkgs/games/spring/default.nix
+++ b/pkgs/games/spring/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, lzma, boost, libdevil, zlib, p7zip
+{ lib, stdenv, fetchFromGitHub, cmake, lzma, boost, libdevil, zlib, p7zip
 , openal, libvorbis, glew, freetype, xorg, SDL2, libGLU, libGL
 , asciidoc, docbook_xsl, docbook_xsl_ns, curl, makeWrapper
 , jdk ? null, python ? null, systemd, libunwind, which, minizip
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [ stdenv.cc.cc systemd ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://springrts.com/";
     description = "A powerful real-time strategy (RTS) game engine";
     license = licenses.gpl2;
diff --git a/pkgs/games/spring/springlobby.nix b/pkgs/games/spring/springlobby.nix
index 9a93b8ec6b911..2f8a9d9885b97 100644
--- a/pkgs/games/spring/springlobby.nix
+++ b/pkgs/games/spring/springlobby.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, cmake, wxGTK30, openal, pkgconfig, curl, libtorrent-rasterbar
+{ lib, stdenv, fetchurl, fetchpatch, cmake, wxGTK30, openal, pkgconfig, curl, libtorrent-rasterbar
 , libpng, libX11, gettext, boost, libnotify, gtk2, doxygen, spring
 , makeWrapper, glib, minizip, alure, pcre, jsoncpp }:
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
       --set SPRING_BUNDLE_DIR "${spring}/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://springlobby.info/";
     repositories.git = "git://github.com/springlobby/springlobby.git";
     description = "Cross-platform lobby client for the Spring RTS project";
diff --git a/pkgs/games/stardust/default.nix b/pkgs/games/stardust/default.nix
index 1e2089b9c5031..2555950506ab5 100644
--- a/pkgs/games/stardust/default.nix
+++ b/pkgs/games/stardust/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, libtiff, libxml2, SDL, xorgproto, libX11
+{ lib, stdenv, fetchurl, zlib, libtiff, libxml2, SDL, xorgproto, libX11
 , libXi, libXmu, libXext, libGLU, libGL }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --replace '#define PACKAGE ""' '#define PACKAGE "stardust"'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Space flight simulator";
     maintainers = [ maintainers.raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/games/steam/runtime.nix b/pkgs/games/steam/runtime.nix
index 69e222ab0d66a..70c6abe8db413 100644
--- a/pkgs/games/steam/runtime.nix
+++ b/pkgs/games/steam/runtime.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 
 # for update script
 , writeShellScript, curl, nix-update
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The official runtime used by Steam";
     homepage = "https://github.com/ValveSoftware/steam-runtime";
     license = licenses.unfreeRedistributable; # Includes NVIDIA CG toolkit
diff --git a/pkgs/games/steam/steam.nix b/pkgs/games/steam/steam.nix
index ed837c9f0bd2e..f7ef287c1ffaa 100644
--- a/pkgs/games/steam/steam.nix
+++ b/pkgs/games/steam/steam.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, runtimeShell, traceDeps ? false, bash }:
+{ lib, stdenv, fetchurl, runtimeShell, traceDeps ? false, bash }:
 
 let
   traceLog = "/tmp/steam-trace-dependencies.log";
@@ -38,7 +38,7 @@ in stdenv.mkDerivation {
     sed -e 's,/usr/bin/steam,steam,g' steam.desktop > $out/share/applications/steam.desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A digital distribution platform";
     homepage = "http://store.steampowered.com/";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/games/steam/steamcmd.nix b/pkgs/games/steam/steamcmd.nix
index 223dff332a705..1c834f1c2ea69 100644
--- a/pkgs/games/steam/steamcmd.nix
+++ b/pkgs/games/steam/steamcmd.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, steam-run, bash, coreutils
+{ lib, stdenv, fetchurl, steam-run, bash, coreutils
 , steamRoot ? "~/.local/share/Steam"
 }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
     chmod 0755 $out/bin/steamcmd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Steam command-line tools";
     homepage = "https://developer.valvesoftware.com/wiki/SteamCMD";
     platforms = platforms.linux;
diff --git a/pkgs/games/stockfish/default.nix b/pkgs/games/stockfish/default.nix
index bdea1db9b3e93..075db08a5ce34 100644
--- a/pkgs/games/stockfish/default.nix
+++ b/pkgs/games/stockfish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let arch = if stdenv.isx86_64 then "x86-64" else
            if stdenv.isi686 then "x86-32" else
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://stockfishchess.org/";
     description = "Strong open source chess engine";
     longDescription = ''
diff --git a/pkgs/games/stuntrally/default.nix b/pkgs/games/stuntrally/default.nix
index 5b8650029aa98..bf9e034d7b4a8 100644
--- a/pkgs/games/stuntrally/default.nix
+++ b/pkgs/games/stuntrally/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, cmake, boost, ogre, mygui, ois, SDL2, libvorbis, pkg-config
+{ lib, fetchurl, stdenv, cmake, boost, ogre, mygui, ois, SDL2, libvorbis, pkg-config
 , makeWrapper, enet, libXcursor, bullet, openal }:
 
 stdenv.mkDerivation rec {
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     makeWrapper enet libXcursor bullet openal
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stunt Rally game with Track Editor, based on VDrift and OGRE";
     homepage = "http://stuntrally.tuxfamily.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/supertux/default.nix b/pkgs/games/supertux/default.nix
index 68b49fd551724..01048c8254321 100644
--- a/pkgs/games/supertux/default.nix
+++ b/pkgs/games/supertux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkgconfig, SDL2, SDL2_image , curl
+{ lib, stdenv, fetchurl, cmake, pkgconfig, SDL2, SDL2_image , curl
 , libogg, libvorbis, libGLU, libGL, openal, boost, glew
 , libpng, freetype
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     ln -s $out/games/supertux2 $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Classic 2D jump'n run sidescroller game";
     homepage = "http://supertux.github.io/";
     license = licenses.gpl2;
diff --git a/pkgs/games/t4kcommon/default.nix b/pkgs/games/t4kcommon/default.nix
index 997ce72db33cd..bc820c8e8e454 100644
--- a/pkgs/games/t4kcommon/default.nix
+++ b/pkgs/games/t4kcommon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, cmake, pkgconfig, SDL, SDL_image, SDL_mixer, SDL_net, SDL_ttf, libpng, librsvg, libxml2 }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, cmake, pkgconfig, SDL, SDL_image, SDL_mixer, SDL_net, SDL_ttf, libpng, librsvg, libxml2 }:
 
 stdenv.mkDerivation rec {
   version = "0.1.1";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkgconfig ];
   buildInputs = [ SDL SDL_image SDL_mixer SDL_net SDL_ttf libpng librsvg libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library of code shared between tuxmath and tuxtype";
     homepage = "https://github.com/tux4kids/t4kcommon";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/taisei/default.nix b/pkgs/games/taisei/default.nix
index 3c4d0df2b036b..e0d1175fce899 100644
--- a/pkgs/games/taisei/default.nix
+++ b/pkgs/games/taisei/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 # Build depends
 , docutils, meson, ninja, pkgconfig, python3
 # Runtime depends
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     patchShebangs .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free and open-source Touhou Project clone and fangame";
     longDescription = ''
       Taisei is an open clone of the Tōhō Project series. Tōhō is a one-man
diff --git a/pkgs/games/tennix/default.nix b/pkgs/games/tennix/default.nix
index 56ac0a2faf4e7..c8b2a415923f4 100644
--- a/pkgs/games/tennix/default.nix
+++ b/pkgs/games/tennix/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, SDL, SDL_mixer, SDL_image, SDL_ttf, SDL_net, python } :
+{lib, stdenv, fetchurl, SDL, SDL_mixer, SDL_image, SDL_ttf, SDL_net, python } :
 
 stdenv.mkDerivation rec {
   name = "tennix-1.1";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     installFlags="PREFIX=$out install"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://icculus.org/tennix/";
     description = "Classic Championship Tour 2011";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/the-butterfly-effect/default.nix b/pkgs/games/the-butterfly-effect/default.nix
index c0c8771032a14..c87d1bea1c735 100644
--- a/pkgs/games/the-butterfly-effect/default.nix
+++ b/pkgs/games/the-butterfly-effect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qt5, box2d, which, cmake, gettext }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qt5, box2d, which, cmake, gettext }:
 
 mkDerivation rec {
   pname = "tbe";
@@ -25,7 +25,7 @@ mkDerivation rec {
     cp -r ../usr/share $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A physics-based game vaguely similar to Incredible Machine";
     homepage = "http://the-butterfly-effect.org/";
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/games/the-powder-toy/default.nix b/pkgs/games/the-powder-toy/default.nix
index af392eca8d8f9..084a4103bd57e 100644
--- a/pkgs/games/the-powder-toy/default.nix
+++ b/pkgs/games/the-powder-toy/default.nix
@@ -1,5 +1,5 @@
 
-{ stdenv, fetchFromGitHub, scons, pkgconfig, SDL2, lua, fftwFloat,
+{ lib, stdenv, fetchFromGitHub, scons, pkgconfig, SDL2, lua, fftwFloat,
   zlib, bzip2, curl, darwin }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free 2D physics sandbox game";
     homepage = "http://powdertoy.co.uk/";
     platforms = [ "i686-linux" "x86_64-linux" "x86_64-darwin" ];
diff --git a/pkgs/games/tintin/default.nix b/pkgs/games/tintin/default.nix
index cd58fcf24fd80..80f9ffa8f4ff9 100644
--- a/pkgs/games/tintin/default.nix
+++ b/pkgs/games/tintin/default.nix
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cd src
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free MUD client for macOS, Linux and Windows";
     homepage    = "http://tintin.sourceforge.net";
     license     = licenses.gpl2;
diff --git a/pkgs/games/tome2/default.nix b/pkgs/games/tome2/default.nix
index 1fc80b1764d5c..d40717c9a3854 100644
--- a/pkgs/games/tome2/default.nix
+++ b/pkgs/games/tome2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeDesktopItem, ncurses, libX11, boost, cmake }:
+{ lib, stdenv, fetchFromGitHub, makeDesktopItem, ncurses, libX11, boost, cmake }:
 
 let
   pname = "tome2";
@@ -41,7 +41,7 @@ in stdenv.mkDerivation {
     cp ${desktopItem}/share/applications/*.desktop $out/share/applications
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit description;
     license = licenses.unfree;
     maintainers = with maintainers; [ cizra ];
diff --git a/pkgs/games/tome4/default.nix b/pkgs/games/tome4/default.nix
index 59dced9ac67db..70a0321715826 100644
--- a/pkgs/games/tome4/default.nix
+++ b/pkgs/games/tome4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, makeWrapper, premake4, unzip
+{ lib, stdenv, fetchurl, makeDesktopItem, makeWrapper, premake4, unzip
 , openal, libpng, libvorbis, libGLU, SDL2, SDL2_image, SDL2_ttf }:
 
 let
@@ -70,7 +70,7 @@ in stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tales of Maj'eyal (rogue-like game)";
     homepage = "https://te4.org/";
     license = licenses.gpl3;
diff --git a/pkgs/games/toppler/default.nix b/pkgs/games/toppler/default.nix
index cf037a0f43627..08baf2ab6fd2c 100644
--- a/pkgs/games/toppler/default.nix
+++ b/pkgs/games/toppler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , SDL
 , SDL_mixer
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     zlib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Jump and run game, reimplementation of Tower Toppler/Nebulus";
     homepage = "http://toppler.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/games/tremulous/default.nix b/pkgs/games/tremulous/default.nix
index cab77b23ee911..a4bf47b5e3624 100644
--- a/pkgs/games/tremulous/default.nix
+++ b/pkgs/games/tremulous/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, libGLU, libGL, libX11, SDL, openal, runtimeShell }:
+{ lib, stdenv, fetchurl, unzip, libGLU, libGL, libX11, SDL, openal, runtimeShell }:
 stdenv.mkDerivation rec {
   pname = "tremulous";
   version = "1.1.0";
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     done
   '';
   dontPatchELF = true;
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A game that blends a team based FPS with elements of an RTS";
     longDescription = ''
       Tremulous is a free, open source game that blends a team based FPS with
diff --git a/pkgs/games/tuxtype/default.nix b/pkgs/games/tuxtype/default.nix
index 9d04440a1672c..1032eba4bcb53 100644
--- a/pkgs/games/tuxtype/default.nix
+++ b/pkgs/games/tuxtype/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, librsvg, libxml2, SDL, SDL_image, SDL_mixer, SDL_net, SDL_ttf, t4kcommon }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, librsvg, libxml2, SDL, SDL_image, SDL_mixer, SDL_net, SDL_ttf, t4kcommon }:
 
 stdenv.mkDerivation rec {
   version = "1.8.3";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--without-sdlpango" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Educational Typing Tutor Game Starring Tux, the Linux Penguin";
     homepage = "https://github.com/tux4kids/tuxtype";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/typespeed/default.nix b/pkgs/games/typespeed/default.nix
index 9da67cbd1ea1e..396e41c467148 100644
--- a/pkgs/games/typespeed/default.nix
+++ b/pkgs/games/typespeed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation {
   name = "typespeed-0.6.5";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
   configureFlags = [ "--datadir=\${out}/share/" ];
   makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A curses based typing game";
     homepage = "http://typespeed.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/games/ultrastardx/default.nix b/pkgs/games/ultrastardx/default.nix
index b6e1da204edf1..43fd30f1d7de8 100644
--- a/pkgs/games/ultrastardx/default.nix
+++ b/pkgs/games/ultrastardx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoreconfHook
 , fetchFromGitHub
 , fetchpatch
@@ -64,7 +64,7 @@ in stdenv.mkDerivation rec {
   # dlopened libgcc requires the rpath not to be shrinked
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ultrastardx.sourceforge.net/";
     description = "Free and open source karaoke game";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/unnethack/default.nix b/pkgs/games/unnethack/default.nix
index 94f39a4b5789a..03928ff48f4c0 100644
--- a/pkgs/games/unnethack/default.nix
+++ b/pkgs/games/unnethack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, util-linux, ncurses, flex, bison }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, util-linux, ncurses, flex, bison }:
 
 stdenv.mkDerivation rec {
   pname = "unnethack";
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/unnethack
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fork of NetHack";
     homepage = "https://unnethack.wordpress.com/";
     license = "nethack";
diff --git a/pkgs/games/urbanterror/default.nix b/pkgs/games/urbanterror/default.nix
index ccc20281302b2..10553d483a501 100644
--- a/pkgs/games/urbanterror/default.nix
+++ b/pkgs/games/urbanterror/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, SDL, libGLU, libGL, openal, curl, libXxf86vm }:
+{ lib, stdenv, fetchurl, unzip, SDL, libGLU, libGL, openal, curl, libXxf86vm }:
 
 stdenv.mkDerivation rec {
   pname = "urbanterror";
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multiplayer tactical FPS on top of Quake 3 engine";
     longDescription = ''
       Urban Terror is a free multiplayer first person shooter developed by
diff --git a/pkgs/games/ut2004/demo.nix b/pkgs/games/ut2004/demo.nix
index 5b501022e2a68..5203453cc6010 100644
--- a/pkgs/games/ut2004/demo.nix
+++ b/pkgs/games/ut2004/demo.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   arch =
@@ -30,7 +30,7 @@ in stdenv.mkDerivation rec {
   dontStrip = true;
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A first-person shooter video game developed by Epic Games and Digital Extreme -- demo version";
     homepage = "http://www.unrealtournament2004.com";
     license = licenses.unfree;
diff --git a/pkgs/games/vapor/default.nix b/pkgs/games/vapor/default.nix
index a8d345151d64d..e79c49779af5b 100644
--- a/pkgs/games/vapor/default.nix
+++ b/pkgs/games/vapor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
+{ lib, stdenv, fetchurl, love, lua, makeWrapper, makeDesktopItem }:
 
 let
   pname = "vapor";
@@ -50,7 +50,7 @@ stdenv.mkDerivation {
     ln -s ${desktopItem}/share/applications/* $out/share/applications/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LÖVE Distribution Client allowing access to many games";
     platforms = platforms.linux;
     license = licenses.zlib;
diff --git a/pkgs/games/vassal/default.nix b/pkgs/games/vassal/default.nix
index dd6c4e36e3c49..effb999e02c35 100644
--- a/pkgs/games/vassal/default.nix
+++ b/pkgs/games/vassal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jre, makeWrapper }:
+{ lib, stdenv, fetchzip, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "VASSAL";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
   # Don't move doc to share/, VASSAL expects it to be in the root
   forceShare = [ "man" "info" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
       description = "A free, open-source boardgame engine";
       homepage = "http://www.vassalengine.org/";
       license = licenses.lgpl21Only;
diff --git a/pkgs/games/vessel/default.nix b/pkgs/games/vessel/default.nix
index 4e0337fa1b47f..fa5aff2b81b42 100644
--- a/pkgs/games/vessel/default.nix
+++ b/pkgs/games/vessel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, requireFile, SDL, libpulseaudio, alsaLib, runtimeShell }:
+{ lib, stdenv, requireFile, SDL, libpulseaudio, alsaLib, runtimeShell }:
 
 stdenv.mkDerivation rec {
   name = "vessel-12082012";
@@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/Vessel
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fluid physics based puzzle game";
     longDescription = ''
       Living liquid machines have overrun this world of unstoppable progress,
diff --git a/pkgs/games/voxelands/default.nix b/pkgs/games/voxelands/default.nix
index 5e52cba3b49c3..0d28a93e401e9 100644
--- a/pkgs/games/voxelands/default.nix
+++ b/pkgs/games/voxelands/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , bzip2
 , cmake
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     xlibsWrapper
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://voxelands.net/";
     description = "Infinite-world block sandbox game based on Minetest";
     license = licenses.gpl3Plus;
diff --git a/pkgs/games/warmux/default.nix b/pkgs/games/warmux/default.nix
index dc8b53d09ad6a..464095e714bca 100644
--- a/pkgs/games/warmux/default.nix
+++ b/pkgs/games/warmux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake
+{ lib, stdenv, fetchFromGitHub, autoconf, automake
 , zlib, curl, gnutls, fribidi, libpng, SDL, SDL_gfx, SDL_image, SDL_mixer
 , SDL_net, SDL_ttf, libunwind, libX11, xorgproto, libxml2, pkgconfig
 , gettext, intltool, libtool, perl
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
   ];
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ballistics turn-based battle game between teams - unofficial copy";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/games/warsow/default.nix b/pkgs/games/warsow/default.nix
index 64c275ec44419..81c467dd9db74 100644
--- a/pkgs/games/warsow/default.nix
+++ b/pkgs/games/warsow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, warsow-engine, makeWrapper }:
+{ lib, stdenv, fetchurl, warsow-engine, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "warsow";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiplayer FPS game designed for competitive gaming";
     longDescription = ''
       Set in a futuristic cartoon-like world where rocketlauncher-wielding
diff --git a/pkgs/games/warsow/engine.nix b/pkgs/games/warsow/engine.nix
index c8c26757baf37..4c8de4a02d339 100644
--- a/pkgs/games/warsow/engine.nix
+++ b/pkgs/games/warsow/engine.nix
@@ -40,7 +40,7 @@ in stdenv.mkDerivation (libs // rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiplayer FPS game designed for competitive gaming (engine only)";
     homepage = "http://www.warsow.net";
     license = licenses.gpl2;
diff --git a/pkgs/games/warzone2100/default.nix b/pkgs/games/warzone2100/default.nix
index 3d7be936f1bc6..2dfb2a72d89b6 100644
--- a/pkgs/games/warzone2100/default.nix
+++ b/pkgs/games/warzone2100/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, autoconf, automake
+{ lib, stdenv, mkDerivation, fetchurl, autoconf, automake
 , perl, unzip, zip, which, pkgconfig, qtbase, qtscript
 , SDL2, libtheora, openal, glew, physfs, fribidi, libXrandr
 , withVideos ? false
@@ -47,7 +47,7 @@ mkDerivation rec {
   postInstall = stdenv.lib.optionalString withVideos
     "cp ${sequences_src} $out/share/warzone2100/sequences.wz";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free RTS game, originally developed by Pumpkin Studios";
     longDescription = ''
         Warzone 2100 is an open source real-time strategy and real-time tactics
diff --git a/pkgs/games/wesnoth/default.nix b/pkgs/games/wesnoth/default.nix
index 349338d883076..d5eb7495df080 100644
--- a/pkgs/games/wesnoth/default.nix
+++ b/pkgs/games/wesnoth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, SDL2, SDL2_image, SDL2_mixer, SDL2_net, SDL2_ttf
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, SDL2, SDL2_image, SDL2_mixer, SDL2_net, SDL2_ttf
 , pango, gettext, boost, libvorbis, fribidi, dbus, libpng, pcre, openssl, icu
 , Cocoa, Foundation
 , enableTools ? false
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DENABLE_TOOLS=${if enableTools then "ON" else "OFF"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Battle for Wesnoth, a free, turn-based strategy game with a fantasy theme";
     longDescription = ''
       The Battle for Wesnoth is a Free, turn-based tactical strategy
diff --git a/pkgs/games/widelands/default.nix b/pkgs/games/widelands/default.nix
index 1c908ffa1fc5e..ba7ce241b8686 100644
--- a/pkgs/games/widelands/default.nix
+++ b/pkgs/games/widelands/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, python, gettext
+{ lib, stdenv, fetchurl, cmake, python, gettext
 , boost, libpng, zlib, glew, lua, doxygen, icu
 , SDL2, SDL2_image, SDL2_mixer, SDL2_net, SDL2_ttf
 }:
@@ -7,7 +7,7 @@ stdenv.mkDerivation rec {
   pname = "widelands";
   version = "20";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RTS with multiple-goods economy";
     homepage    = "http://widelands.org/";
     longDescription = ''
diff --git a/pkgs/games/worldofgoo/default.nix b/pkgs/games/worldofgoo/default.nix
index 81540fa4d9624..8d06b94271f46 100644
--- a/pkgs/games/worldofgoo/default.nix
+++ b/pkgs/games/worldofgoo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, requireFile, unzip, makeDesktopItem, SDL2, SDL2_mixer, libogg, libvorbis }:
+{ lib, stdenv, requireFile, unzip, makeDesktopItem, SDL2, SDL2_mixer, libogg, libvorbis }:
 
 let
   arch = if stdenv.system == "x86_64-linux"
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     patchelf --interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" --set-rpath $libPath $out/bin/WorldOfGoo.bin.${arch}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A physics based puzzle game";
     longDescription = ''
       World of Goo is a physics based puzzle / construction game. The millions of Goo
diff --git a/pkgs/games/wyvern/default.nix b/pkgs/games/wyvern/default.nix
index dcf81bc0985fa..82209a69a44bf 100644
--- a/pkgs/games/wyvern/default.nix
+++ b/pkgs/games/wyvern/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , rustPlatform
 , unzip
@@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec {
   nativeBuildInputs = [ cmake pkgconfig ];
   buildInputs = [ openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple CLI client for installing and maintaining linux GOG games";
     homepage = "https://git.sr.ht/~nicohman/wyvern";
     license = licenses.gpl3;
diff --git a/pkgs/games/xbomb/default.nix b/pkgs/games/xbomb/default.nix
index 0754905ce50d7..8ec625a0b6bb8 100644
--- a/pkgs/games/xbomb/default.nix
+++ b/pkgs/games/xbomb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXaw }:
+{ lib, stdenv, fetchurl, libX11, libXaw }:
 
 stdenv.mkDerivation rec {
   name = "xbomb-2.2b";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     "INSTDIR=${placeholder ''out''}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.gedanken.org.uk/software/xbomb/";
     description = "Minesweeper for X11 with various grid sizes and shapes";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/xconq/default.nix b/pkgs/games/xconq/default.nix
index 6e85263997949..8f4366fbcb87d 100644
--- a/pkgs/games/xconq/default.nix
+++ b/pkgs/games/xconq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cpio, xorgproto, libX11, libXmu, libXaw, libXt, tcl, tk
+{ lib, stdenv, fetchurl, cpio, xorgproto, libX11, libXmu, libXaw, libXt, tcl, tk
 , libXext, fontconfig, makeWrapper }:
 
 stdenv.mkDerivation rec {
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A programmable turn-based strategy game";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/games/xcowsay/default.nix b/pkgs/games/xcowsay/default.nix
index dd95bf1e5a168..0a6371801bd51 100644
--- a/pkgs/games/xcowsay/default.nix
+++ b/pkgs/games/xcowsay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, pkg-config
+{ lib, stdenv, fetchurl, makeWrapper, pkg-config
 , dbus, dbus-glib, gtk3, gdk-pixbuf, librsvg
 , fortune
 }:
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.doof.me.uk/xcowsay";
     description =
       "A program based on cowsay that displays a cute cow and message on your desktop";
diff --git a/pkgs/games/xjump/default.nix b/pkgs/games/xjump/default.nix
index afac2de9fcec7..3c13fc1a9b782 100644
--- a/pkgs/games/xjump/default.nix
+++ b/pkgs/games/xjump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libX11, libXt, libXpm, libXaw, localStateDir?null }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libX11, libXt, libXpm, libXaw, localStateDir?null }:
 
 stdenv.mkDerivation {
   pname = "xjump";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     else
       [];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The falling tower game";
     license = licenses.gpl2;
     maintainers = with maintainers; [ pmeunier ];
diff --git a/pkgs/games/xmage/default.nix b/pkgs/games/xmage/default.nix
index e8b8eb8a94197..7552ce700f32d 100644
--- a/pkgs/games/xmage/default.nix
+++ b/pkgs/games/xmage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , jdk8
 , unzip
@@ -30,7 +30,7 @@ EOS
     chmod +x $out/bin/xmage
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Magic Another Game Engine";
     license = licenses.mit;
     maintainers = with maintainers; [ matthiasbeyer ];
diff --git a/pkgs/games/xmoto/default.nix b/pkgs/games/xmoto/default.nix
index d49998a68d73e..afeded792f2eb 100644
--- a/pkgs/games/xmoto/default.nix
+++ b/pkgs/games/xmoto/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, chipmunk, sqlite, curl, zlib, bzip2, libjpeg
+{ lib, stdenv, fetchurl, chipmunk, sqlite, curl, zlib, bzip2, libjpeg
 , libpng, freeglut, libGLU, libGL, SDL, SDL_mixer, SDL_image, SDL_net
 , SDL_ttf, lua5, ode, libxdg_basedir, libxml2 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     "-D_GLIBCXX_USE_CXX11_ABI=0"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Obstacled race game";
     homepage = "http://xmoto.tuxfamily.org";
     maintainers = with maintainers; [ raskin pSub ];
diff --git a/pkgs/games/xpilot/bloodspilot-server.nix b/pkgs/games/xpilot/bloodspilot-server.nix
index 6b0a0603af51a..a860c4e1d5ffb 100644
--- a/pkgs/games/xpilot/bloodspilot-server.nix
+++ b/pkgs/games/xpilot/bloodspilot-server.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, expat }:
+{ lib, stdenv, fetchurl, expat }:
 
 stdenv.mkDerivation rec {
   pname = "bloodspilot-xpilot-fxi-server";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     ./server-gcc5.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multiplayer X11 space combat game (server part)";
     homepage = "http://bloodspilot.sf.net/";
     license = licenses.gpl2Plus ;
diff --git a/pkgs/games/xpilot/default.nix b/pkgs/games/xpilot/default.nix
index 8803806547bfe..bd86538d99ec0 100644
--- a/pkgs/games/xpilot/default.nix
+++ b/pkgs/games/xpilot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libSM, SDL, libGLU, libGL, expat, SDL_ttf
+{ lib, stdenv, fetchurl, libX11, libSM, SDL, libGLU, libGL, expat, SDL_ttf
 , SDL_image, zlib, libXxf86misc }:
 stdenv.mkDerivation rec {
   pname = "xpilot-ng";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
   buildInputs = [
     libX11 libSM SDL SDL_ttf SDL_image libGLU libGL expat zlib libXxf86misc
   ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multiplayer X11 space combat game";
     homepage = "http://xpilot.sf.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/xsokoban/default.nix b/pkgs/games/xsokoban/default.nix
index 3f6062c4f6862..68b47e6225a59 100644
--- a/pkgs/games/xsokoban/default.nix
+++ b/pkgs/games/xsokoban/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, xorgproto, libXpm, libXt }:
+{ lib, stdenv, fetchurl, libX11, xorgproto, libXpm, libXt }:
 
 stdenv.mkDerivation rec {
   pname = "xsokoban";
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin $out/share $out/man/man1 $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "X sokoban";
     license = licenses.publicDomain;
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/games/xtris/default.nix b/pkgs/games/xtris/default.nix
index c9421b23a821a..e6da0c6f17ccd 100644
--- a/pkgs/games/xtris/default.nix
+++ b/pkgs/games/xtris/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, xorg }:
+{ lib, stdenv, fetchzip, xorg }:
 stdenv.mkDerivation rec {
   pname = "xtris";
   version = "1.15";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   '';
   buildInputs = [ xorg.libX11 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multi-player version of the classical game of Tetris, for the X Window system";
     homepage = "https://web.archive.org/web/20120315061213/http://www.iagora.com/~espel/xtris/xtris.html";
     license = licenses.gpl2;
diff --git a/pkgs/games/zandronum/default.nix b/pkgs/games/zandronum/default.nix
index c8d33a198619f..25f536885d616 100644
--- a/pkgs/games/zandronum/default.nix
+++ b/pkgs/games/zandronum/default.nix
@@ -72,7 +72,7 @@ in stdenv.mkDerivation rec {
     inherit fmod sqlite;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zandronum.com/";
     description = "Multiplayer oriented port, based off Skulltag, for Doom and Doom II by id Software";
     maintainers = with maintainers; [ lassulus MP2E ];
diff --git a/pkgs/games/zandronum/fmod.nix b/pkgs/games/zandronum/fmod.nix
index 5eebcd4a38e7c..257dd3751c8e9 100644
--- a/pkgs/games/zandronum/fmod.nix
+++ b/pkgs/games/zandronum/fmod.nix
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     cp -r api/inc $out/include
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Programming library and toolkit for the creation and playback of interactive audio";
     homepage    = "http://www.fmod.org/";
     license     = licenses.unfreeRedistributable;
diff --git a/pkgs/games/zaz/default.nix b/pkgs/games/zaz/default.nix
index 9d42cfd6896dc..00416eb1c980e 100644
--- a/pkgs/games/zaz/default.nix
+++ b/pkgs/games/zaz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , SDL
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     "ZAZ_LIBS+=-lvorbisfile"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A puzzle game about arranging balls in triplets, like Luxor, Zuma, or Puzzle Bobble";
     homepage = "http://zaz.sourceforge.net/";
     license = licenses.gpl3;
diff --git a/pkgs/games/zdoom/bcc-git.nix b/pkgs/games/zdoom/bcc-git.nix
index ae7a4ae6f426f..8716a82fc1053 100644
--- a/pkgs/games/zdoom/bcc-git.nix
+++ b/pkgs/games/zdoom/bcc-git.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   name = "doom-bcc-git-0.8.0.2018.01.04";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     cp -av lib $out/lib/bcc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compiler for Doom/Hexen scripts (ACS, BCS)";
     homepage = "https://github.com/wormt/bcc";
     license = licenses.mit;
diff --git a/pkgs/games/zdoom/default.nix b/pkgs/games/zdoom/default.nix
index 37a8fd0fda8d2..3a31f8fdfb5f6 100644
--- a/pkgs/games/zdoom/default.nix
+++ b/pkgs/games/zdoom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, p7zip, cmake
+{ lib, stdenv, fetchurl, p7zip, cmake
 , SDL2, openal, fluidsynth, soundfont-fluid, bzip2, zlib, libjpeg, game-music-emu
 , libsndfile, mpg123 }:
 
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     ln -s $out/lib/zdoom/zdoom $out/bin/zdoom
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://zdoom.org/";
     description = "Enhanced port of the official DOOM source code";
     # Doom source license, MAME license
diff --git a/pkgs/games/zdoom/zdbsp.nix b/pkgs/games/zdoom/zdbsp.nix
index 9b318ef6e7148..e688b908e1268 100644
--- a/pkgs/games/zdoom/zdbsp.nix
+++ b/pkgs/games/zdoom/zdbsp.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, cmake, zlib }:
+{ lib, stdenv, fetchzip, cmake, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "zdbsp";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     install -Dm755 zdbsp $out/bin/zdbsp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ZDoom's internal node builder for DOOM maps";
     homepage = "https://zdoom.org/wiki/ZDBSP";
     license = licenses.gpl2Plus;
diff --git a/pkgs/games/zoom/default.nix b/pkgs/games/zoom/default.nix
index 827fb351f1de2..086d860872c71 100644
--- a/pkgs/games/zoom/default.nix
+++ b/pkgs/games/zoom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, expat, xlibsWrapper, freetype }:
+{ lib, stdenv, fetchurl, perl, expat, xlibsWrapper, freetype }:
 
 # !!! assert freetype == xorg.freetype
 
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-I${freetype}/include/freetype2 -fgnu89-inline";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Player for Z-Code, TADS and HUGO stories or games";
     longDescription = ''
       Zoom is a player for Z-Code, TADS and HUGO stories or games. These are
diff --git a/pkgs/misc/acpilight/default.nix b/pkgs/misc/acpilight/default.nix
index 1975e2d379077..b5a385ab40769 100644
--- a/pkgs/misc/acpilight/default.nix
+++ b/pkgs/misc/acpilight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, python3, coreutils }:
+{ lib, stdenv, fetchgit, python3, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "acpilight";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out) prefix=" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/wavexx/acpilight";
     description = "ACPI backlight control";
     license = licenses.gpl3;
diff --git a/pkgs/misc/apulse/default.nix b/pkgs/misc/apulse/default.nix
index ccb7d4750519d..6f13414701a90 100644
--- a/pkgs/misc/apulse/default.nix
+++ b/pkgs/misc/apulse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, alsaLib, cmake, pkgconfig, glib
+{ lib, stdenv, fetchFromGitHub, alsaLib, cmake, pkgconfig, glib
 , tracingSupport ? true, logToStderr ? true }:
 
 let oz = x: if x then "1" else "0"; in
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     "-DLOG_TO_STDERR=${oz logToStderr}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PulseAudio emulation for ALSA";
     homepage = "https://github.com/i-rinat/apulse";
     license = licenses.mit;
diff --git a/pkgs/misc/beep/default.nix b/pkgs/misc/beep/default.nix
index bb62271a3109a..92d84bdf6dc84 100644
--- a/pkgs/misc/beep/default.nix
+++ b/pkgs/misc/beep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 # this package is working only as root
 # in order to work as a non privileged user you would need to suid the bin
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=\${out}" "prefix="];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The advanced PC speaker beeper";
     homepage = "https://github.com/spkr-beep/beep";
     license = licenses.gpl2Only;
diff --git a/pkgs/misc/brightnessctl/default.nix b/pkgs/misc/brightnessctl/default.nix
index 37956785a5bb1..2fab8b4bd676c 100644
--- a/pkgs/misc/brightnessctl/default.nix
+++ b/pkgs/misc/brightnessctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, systemd }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, systemd }:
 
 stdenv.mkDerivation rec {
   pname = "brightnessctl";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkg-config ];
   buildInputs = [ systemd ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Hummer12007/brightnessctl";
     description = "This program allows you read and control device brightness";
     license = licenses.mit;
diff --git a/pkgs/misc/calaos/installer/default.nix b/pkgs/misc/calaos/installer/default.nix
index ee7c089bc8ee3..575471b2ee51e 100644
--- a/pkgs/misc/calaos/installer/default.nix
+++ b/pkgs/misc/calaos/installer/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, qmake, qttools, qtbase }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, qmake, qttools, qtbase }:
 
 mkDerivation rec {
   pname = "calaos_installer";
@@ -24,7 +24,7 @@ mkDerivation rec {
     cp -a calaos_installer $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calaos Installer, a tool to create calaos configuration";
     homepage = "https://www.calaos.fr/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/misc/cups/cups-pk-helper.nix b/pkgs/misc/cups/cups-pk-helper.nix
index 3151bace5587d..3be5bd7711fa3 100644
--- a/pkgs/misc/cups/cups-pk-helper.nix
+++ b/pkgs/misc/cups/cups-pk-helper.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, pkgconfig, glib, polkit, cups, fetchpatch }:
+{ lib, stdenv, fetchurl, intltool, pkgconfig, glib, polkit, cups, fetchpatch }:
 
 stdenv.mkDerivation rec {
   version = "0.2.6";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PolicyKit helper to configure cups with fine-grained privileges";
     homepage = "http://www.freedesktop.org/wiki/Software/cups-pk-helper/";
     license = licenses.gpl2;
diff --git a/pkgs/misc/cups/drivers/brlaser/default.nix b/pkgs/misc/cups/drivers/brlaser/default.nix
index 141e3f9e6123f..b0dfd8d8170a3 100644
--- a/pkgs/misc/cups/drivers/brlaser/default.nix
+++ b/pkgs/misc/cups/drivers/brlaser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, zlib, cups }:
+{ lib, stdenv, fetchFromGitHub, cmake, zlib, cups }:
 
 stdenv.mkDerivation rec {
   pname = "brlaser";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DCUPS_SERVER_BIN=lib/cups" "-DCUPS_DATA_DIR=share/cups" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CUPS driver for Brother laser printers";
     longDescription =
       ''
diff --git a/pkgs/misc/cups/drivers/canon/default.nix b/pkgs/misc/cups/drivers/canon/default.nix
index dbc6390ef4985..754c0f4d1d0eb 100644
--- a/pkgs/misc/cups/drivers/canon/default.nix
+++ b/pkgs/misc/cups/drivers/canon/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip, autoreconfHook, libtool, makeWrapper, cups, ghostscript, pkgsi686Linux, zlib }:
+{lib, stdenv, fetchurl, unzip, autoreconfHook, libtool, makeWrapper, cups, ghostscript, pkgsi686Linux, zlib }:
 
 let
 
@@ -214,7 +214,7 @@ stdenv.mkDerivation {
       --prefix PATH ":" "$out/bin"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CUPS Linux drivers for Canon printers";
     homepage = "http://www.canon.com/";
     license = licenses.unfree;
diff --git a/pkgs/misc/cups/drivers/estudio/default.nix b/pkgs/misc/cups/drivers/estudio/default.nix
index 9aaae31488d39..37b39556d9323 100644
--- a/pkgs/misc/cups/drivers/estudio/default.nix
+++ b/pkgs/misc/cups/drivers/estudio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation {
   pname = "cups-toshiba-estudio";
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     chmod 755 $out/share/cups/model/Toshiba/TOSHIBA_ColorMFP_CUPS.gz
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Printer only driver for the Toshiba e-STUDIO class of printers";
     longDescription = ''
       This driver supports the following printers: TOSHIBA e-STUDIO2000AC,
diff --git a/pkgs/misc/cups/drivers/fxlinuxprint/default.nix b/pkgs/misc/cups/drivers/fxlinuxprint/default.nix
index 30d7378710476..36134780e9bfd 100644
--- a/pkgs/misc/cups/drivers/fxlinuxprint/default.nix
+++ b/pkgs/misc/cups/drivers/fxlinuxprint/default.nix
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     mv usr/share/ppd/FujiXerox/* $out/share/cups/model
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fuji Xerox Linux Printer Driver";
     longDescription = ''
       DocuPrint P365/368 d
diff --git a/pkgs/misc/cups/drivers/googlecloudprint/default.nix b/pkgs/misc/cups/drivers/googlecloudprint/default.nix
index 9b612c43a0007..6503571eb6b69 100644
--- a/pkgs/misc/cups/drivers/googlecloudprint/default.nix
+++ b/pkgs/misc/cups/drivers/googlecloudprint/default.nix
@@ -55,7 +55,7 @@ in stdenv.mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Google Cloud Print driver for CUPS, allows printing to printers hosted on Google Cloud Print";
     homepage    = "http://ccp.niftiestsoftware.com";
     platforms   = platforms.linux;
diff --git a/pkgs/misc/cups/drivers/hll2340dw/default.nix b/pkgs/misc/cups/drivers/hll2340dw/default.nix
index a291f16628834..a621137c8f19e 100644
--- a/pkgs/misc/cups/drivers/hll2340dw/default.nix
+++ b/pkgs/misc/cups/drivers/hll2340dw/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, cups, dpkg, gnused, makeWrapper, ghostscript, file, a2ps, coreutils, gawk, perl, gnugrep, which}:
+{lib, stdenv, fetchurl, cups, dpkg, gnused, makeWrapper, ghostscript, file, a2ps, coreutils, gawk, perl, gnugrep, which}:
 
 let
   version = "3.2.0-1";
@@ -57,7 +57,7 @@ stdenv.mkDerivation {
       --prefix PATH ":" ${ stdenv.lib.makeBinPath [ ghostscript a2ps file gnused gnugrep coreutils which ] }
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.brother.com/";
     description = "Brother hl-l2340dw printer driver";
     license = licenses.unfree;
diff --git a/pkgs/misc/cups/drivers/hll2390dw-cups/default.nix b/pkgs/misc/cups/drivers/hll2390dw-cups/default.nix
index 0a55ee0c8bbf4..1e247d42ca4b7 100644
--- a/pkgs/misc/cups/drivers/hll2390dw-cups/default.nix
+++ b/pkgs/misc/cups/drivers/hll2390dw-cups/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper
+{ lib, stdenv, fetchurl, makeWrapper
 , cups
 , dpkg
 , a2ps, ghostscript, gnugrep, gnused, coreutils, file, perl, which
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" ${ stdenv.lib.makeBinPath [ ghostscript a2ps file gnused gnugrep coreutils which ] }
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.brother.com/";
     description = "Brother HL-L2390DW combined print driver";
     license = licenses.unfree;
diff --git a/pkgs/misc/cups/drivers/mfcj6510dwcupswrapper/default.nix b/pkgs/misc/cups/drivers/mfcj6510dwcupswrapper/default.nix
index 8a5c9644512ed..1653ced85c5a9 100644
--- a/pkgs/misc/cups/drivers/mfcj6510dwcupswrapper/default.nix
+++ b/pkgs/misc/cups/drivers/mfcj6510dwcupswrapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mfcj6510dwlpr, makeWrapper}:
+{ lib, stdenv, fetchurl, mfcj6510dwlpr, makeWrapper}:
 
 stdenv.mkDerivation rec {
   pname = "mfcj6510dw-cupswrapper";
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     make clean
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.brother.com/";
     description = "Brother MFC-J6510DW CUPS wrapper driver";
     license = with licenses; gpl2;
diff --git a/pkgs/misc/cups/drivers/mfcj6510dwlpr/default.nix b/pkgs/misc/cups/drivers/mfcj6510dwlpr/default.nix
index 8f07d4b419708..ea06e8c104d12 100644
--- a/pkgs/misc/cups/drivers/mfcj6510dwlpr/default.nix
+++ b/pkgs/misc/cups/drivers/mfcj6510dwlpr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgsi686Linux, dpkg, makeWrapper, coreutils, gnused, gawk, file, cups, util-linux, xxd, runtimeShell
+{ lib, stdenv, fetchurl, pkgsi686Linux, dpkg, makeWrapper, coreutils, gnused, gawk, file, cups, util-linux, xxd, runtimeShell
 , ghostscript, a2ps }:
 
 # Why:
@@ -78,7 +78,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" ${ stdenv.lib.makeBinPath [ coreutils gnused file ghostscript a2ps ] }
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "Brother MFC-J6510DW LPR driver";
     downloadPage = "http://support.brother.com/g/b/downloadlist.aspx?c=us&lang=en&prod=mfcj6510dw_all&os=128";
     homepage     = "http://www.brother.com/";
diff --git a/pkgs/misc/cups/drivers/samsung/1.00.36/default.nix b/pkgs/misc/cups/drivers/samsung/1.00.36/default.nix
index 4088ce700de25..f346b6e3c40da 100644
--- a/pkgs/misc/cups/drivers/samsung/1.00.36/default.nix
+++ b/pkgs/misc/cups/drivers/samsung/1.00.36/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cups, libusb-compat-0_1, libxml2, perl }:
+{ lib, stdenv, fetchurl, cups, libusb-compat-0_1, libxml2, perl }:
 
 let
 
@@ -102,7 +102,7 @@ in stdenv.mkDerivation rec {
   # we did this in prefixup already
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unified Linux Driver for Samsung printers and scanners";
     homepage = "http://www.bchemnet.com/suldr";
     downloadPage = "http://www.bchemnet.com/suldr/driver/";
diff --git a/pkgs/misc/cups/drivers/samsung/1.00.37.nix b/pkgs/misc/cups/drivers/samsung/1.00.37.nix
index c205560706f65..af022454e42b9 100644
--- a/pkgs/misc/cups/drivers/samsung/1.00.37.nix
+++ b/pkgs/misc/cups/drivers/samsung/1.00.37.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cups, libusb-compat-0_1, libxml2 }:
+{ lib, stdenv, fetchurl, cups, libusb-compat-0_1, libxml2 }:
 
 let
 
@@ -85,7 +85,7 @@ in stdenv.mkDerivation rec {
   # we did this in prefixup already
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unified Linux Driver for Samsung printers and scanners";
     homepage = "http://www.bchemnet.com/suldr";
     downloadPage = "http://www.bchemnet.com/suldr/driver/";
diff --git a/pkgs/misc/cups/drivers/samsung/4.00.39/default.nix b/pkgs/misc/cups/drivers/samsung/4.00.39/default.nix
index c3c3613bbda89..9982e7b4282cb 100644
--- a/pkgs/misc/cups/drivers/samsung/4.00.39/default.nix
+++ b/pkgs/misc/cups/drivers/samsung/4.00.39/default.nix
@@ -11,7 +11,7 @@
 # }
 # (This advice was tested on 2010 August 2.)
 
-{ stdenv, fetchurl, cups, gcc, ghostscript, glibc, patchelf }:
+{ lib, stdenv, fetchurl, cups, gcc, ghostscript, glibc, patchelf }:
 
 # Do not bump lightly! Visit <http://www.bchemnet.com/suldr/supported.html>
 # to see what will break when upgrading. Consider a new versioned attribute.
@@ -34,7 +34,7 @@ in stdenv.mkDerivation rec {
 
   builder = ./builder.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Samsung's Linux printing drivers; includes binaries without source code";
     homepage = "http://www.samsung.com/";
     license = licenses.unfree;
diff --git a/pkgs/misc/cups/drivers/samsung/4.01.17.nix b/pkgs/misc/cups/drivers/samsung/4.01.17.nix
index 5de93b20cb803..68f2abde7057f 100644
--- a/pkgs/misc/cups/drivers/samsung/4.01.17.nix
+++ b/pkgs/misc/cups/drivers/samsung/4.01.17.nix
@@ -11,7 +11,7 @@
 # }
 # (This advice was tested on the 1st November 2016.)
 
-{ stdenv, fetchurl, cups, libusb-compat-0_1 }:
+{ lib, stdenv, fetchurl, cups, libusb-compat-0_1 }:
 
 # Do not bump lightly! Visit <http://www.bchemnet.com/suldr/supported.html>
 # to see what will break when upgrading. Consider a new versioned attribute.
@@ -72,7 +72,7 @@ in stdenv.mkDerivation rec {
     cp -r ./* $out/share/cups/model/samsung
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Samsung's Linux printing drivers; includes binaries without source code";
     homepage = "http://www.samsung.com/";
     license = licenses.unfree;
diff --git a/pkgs/misc/cups/drivers/splix/default.nix b/pkgs/misc/cups/drivers/splix/default.nix
index c65ca401d60f2..1125e76971126 100644
--- a/pkgs/misc/cups/drivers/splix/default.nix
+++ b/pkgs/misc/cups/drivers/splix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchsvn, fetchurl, cups, cups-filters, jbigkit, zlib }:
+{ lib, stdenv, fetchsvn, fetchurl, cups, cups-filters, jbigkit, zlib }:
 
 let
 
@@ -45,7 +45,7 @@ in stdenv.mkDerivation rec {
 
   buildInputs = [ cups zlib jbigkit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CUPS drivers for SPL (Samsung Printer Language) printers";
     homepage = "http://splix.ap2c.org";
     license = licenses.gpl2;
diff --git a/pkgs/misc/cups/drivers/zj-58/default.nix b/pkgs/misc/cups/drivers/zj-58/default.nix
index 67df20df4911d..0e2534997e350 100644
--- a/pkgs/misc/cups/drivers/zj-58/default.nix
+++ b/pkgs/misc/cups/drivers/zj-58/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, cups}:
+{lib, stdenv, fetchFromGitHub, cups}:
 
 stdenv.mkDerivation {
   pname = "cups-zj-58";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     install -D ZJ-58.ppd $out/share/cups/model/zjiang/ZJ-58.ppd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CUPS filter for thermal printer Zjiang ZJ-58";
     homepage = "https://github.com/klirichek/zj-58";
     platforms = platforms.linux;
diff --git a/pkgs/misc/doge/default.nix b/pkgs/misc/doge/default.nix
index 37a3b4be70637..8334444ec4c96 100644
--- a/pkgs/misc/doge/default.nix
+++ b/pkgs/misc/doge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv , python3Packages }:
+{ lib, stdenv , python3Packages }:
 
 python3Packages.buildPythonPackage rec {
   pname = "doge";
@@ -9,7 +9,7 @@ python3Packages.buildPythonPackage rec {
     sha256 = "0lwdl06lbpnaqqjk8ap9dsags3bzma30z17v0zc7spng1gz8m6xj";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/thiderman/doge";
     description = "wow very terminal doge";
     license = licenses.mit;
diff --git a/pkgs/misc/drivers/epson-201106w/default.nix b/pkgs/misc/drivers/epson-201106w/default.nix
index 95eb59f7167c3..690a4e4841e7b 100644
--- a/pkgs/misc/drivers/epson-201106w/default.nix
+++ b/pkgs/misc/drivers/epson-201106w/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, rpmextract, autoreconfHook, file, libjpeg, cups }:
+{ lib, stdenv, fetchurl, rpmextract, autoreconfHook, file, libjpeg, cups }:
 
 let
   version = "1.0.1";
@@ -48,7 +48,7 @@ in
       cp -a README $out/doc/README.driver
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.openprinting.org/driver/epson-201106w";
       description = "Epson printer driver (BX535WD, BX630FW, BX635FWD, ME940FW, NX530, NX635, NX635, SX535WD, WorkForce 545, WorkForce 645";
       longDescription = ''
diff --git a/pkgs/misc/drivers/epson-alc1100/default.nix b/pkgs/misc/drivers/epson-alc1100/default.nix
index fe52b104a5289..fc467e8a4d2d1 100644
--- a/pkgs/misc/drivers/epson-alc1100/default.nix
+++ b/pkgs/misc/drivers/epson-alc1100/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cups, pkgsi686Linux, dpkg, psutils, makeWrapper, ghostscript, bash }:
+{ lib, stdenv, fetchurl, cups, pkgsi686Linux, dpkg, psutils, makeWrapper, ghostscript, bash }:
 
 let
   version = "1.2-0";
@@ -49,7 +49,7 @@ in
         --suffix PATH : "\$PATH:${psutils}/bin:${ghostscript}/bin:${bash}/bin:/var/lib/cups/path/bin"
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://download.ebz.epson.net/dsc/search/01/search/";
       description = "Epson AcuLaser C1100 Driver";
       longDescription = ''
diff --git a/pkgs/misc/drivers/epson-escpr/default.nix b/pkgs/misc/drivers/epson-escpr/default.nix
index d90ef2c91f642..8d8951db249dd 100644
--- a/pkgs/misc/drivers/epson-escpr/default.nix
+++ b/pkgs/misc/drivers/epson-escpr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cups }:
+{ lib, stdenv, fetchurl, cups }:
 
 stdenv.mkDerivation {
   pname = "epson-escpr";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ cups ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://download.ebz.epson.net/dsc/search/01/search/";
     description = "ESC/P-R Driver (generic driver)";
     longDescription = ''
diff --git a/pkgs/misc/drivers/epson-escpr2/default.nix b/pkgs/misc/drivers/epson-escpr2/default.nix
index afde25ee6b4e9..934f00d7492bb 100644
--- a/pkgs/misc/drivers/epson-escpr2/default.nix
+++ b/pkgs/misc/drivers/epson-escpr2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cups, busybox }:
+{ lib, stdenv, fetchurl, cups, busybox }:
 
 stdenv.mkDerivation rec {
   pname = "epson-inkjet-printer-escpr2";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     cd ${pname}-${version}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://download.ebz.epson.net/dsc/search/01/search/";
     description = "ESC/P-R 2 Driver (generic driver)";
     longDescription = ''
diff --git a/pkgs/misc/drivers/epson_201207w/default.nix b/pkgs/misc/drivers/epson_201207w/default.nix
index 6a9782715d219..6de25dbe678dc 100644
--- a/pkgs/misc/drivers/epson_201207w/default.nix
+++ b/pkgs/misc/drivers/epson_201207w/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, rpmextract, autoreconfHook, file, libjpeg, cups }:
+{ lib, stdenv, fetchurl, rpmextract, autoreconfHook, file, libjpeg, cups }:
 
 let
   version = "1.0.0";
@@ -46,7 +46,7 @@ in
       cp -a README $out/doc/README.driver
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.openprinting.org/driver/epson-201207w";
       description = "Epson printer driver (L110, L210, L300, L350, L355, L550, L555)";
       longDescription = ''
diff --git a/pkgs/misc/drivers/foo2zjs/default.nix b/pkgs/misc/drivers/foo2zjs/default.nix
index 7e1ff01bda05c..deea3bd25f50e 100644
--- a/pkgs/misc/drivers/foo2zjs/default.nix
+++ b/pkgs/misc/drivers/foo2zjs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, foomatic-filters, bc, unzip, ghostscript, systemd, vim, time }:
+{ lib, stdenv, fetchurl, foomatic-filters, bc, unzip, ghostscript, systemd, vim, time }:
 
 stdenv.mkDerivation rec {
   name = "foo2zjs-20180519";
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     cp -v getweb arm2hpdl "$out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ZjStream printer drivers";
     maintainers = with maintainers;
     [
diff --git a/pkgs/misc/drivers/gutenprint/default.nix b/pkgs/misc/drivers/gutenprint/default.nix
index c7fc859576ba6..5957f30327fab 100644
--- a/pkgs/misc/drivers/gutenprint/default.nix
+++ b/pkgs/misc/drivers/gutenprint/default.nix
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
   # Testing is very, very long.
   # doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ghostscript and cups printer drivers";
     homepage = "https://sourceforge.net/projects/gimp-print/";
     license = licenses.gpl2;
diff --git a/pkgs/misc/drivers/hplip/3.16.11.nix b/pkgs/misc/drivers/hplip/3.16.11.nix
index 4b9f47d88f94d..c48c5bff4bf3d 100644
--- a/pkgs/misc/drivers/hplip/3.16.11.nix
+++ b/pkgs/misc/drivers/hplip/3.16.11.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll
+{ lib, stdenv, fetchurl, substituteAll
 , pkgconfig
 , cups, libjpeg, libusb1, python2Packages, sane-backends, dbus, usbutils
 , net-snmp, openssl, nettools
@@ -179,7 +179,7 @@ python2Packages.buildPythonApplication {
       --replace {/usr,$out}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Print, scan and fax HP drivers for Linux";
     homepage = "http://hplipopensource.com/";
     downloadPage = "https://sourceforge.net/projects/hplip/files/hplip/";
diff --git a/pkgs/misc/drivers/hplip/3.18.5.nix b/pkgs/misc/drivers/hplip/3.18.5.nix
index 59b3d2b9d6342..c7e1f47e2e52f 100644
--- a/pkgs/misc/drivers/hplip/3.18.5.nix
+++ b/pkgs/misc/drivers/hplip/3.18.5.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll
+{ lib, stdenv, fetchurl, substituteAll
 , pkgconfig
 , cups, zlib, libjpeg, libusb1, python2Packages, sane-backends
 , dbus, file, ghostscript, usbutils
@@ -216,7 +216,7 @@ python2Packages.buildPythonApplication {
       --replace {/usr,$out}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Print, scan and fax HP drivers for Linux";
     homepage = "https://developers.hp.com/hp-linux-imaging-and-printing";
     downloadPage = "https://sourceforge.net/projects/hplip/files/hplip/";
diff --git a/pkgs/misc/drivers/hplip/default.nix b/pkgs/misc/drivers/hplip/default.nix
index f1688a1b56fce..b20797808af5d 100644
--- a/pkgs/misc/drivers/hplip/default.nix
+++ b/pkgs/misc/drivers/hplip/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll
+{ lib, stdenv, fetchurl, substituteAll
 , pkgconfig
 , cups, zlib, libjpeg, libusb1, python3Packages, sane-backends
 , dbus, file, ghostscript, usbutils
@@ -240,7 +240,7 @@ python3Packages.buildPythonApplication {
     "share/hplip" "lib/cups/backend" "lib/cups/filter" python3Packages.python.sitePackages "lib/sane"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Print, scan and fax HP drivers for Linux";
     homepage = "https://developers.hp.com/hp-linux-imaging-and-printing";
     downloadPage = "https://sourceforge.net/projects/hplip/files/hplip/";
diff --git a/pkgs/misc/drivers/m33-linux/default.nix b/pkgs/misc/drivers/m33-linux/default.nix
index cb78bd3498a96..d2ba2685a291d 100644
--- a/pkgs/misc/drivers/m33-linux/default.nix
+++ b/pkgs/misc/drivers/m33-linux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   name = "M33-Linux-2016-06-23";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     install -Dm755 90-micro-3d-local.rules $out/lib/udev/rules.d/90-micro-3d-local.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/donovan6000/M3D-Linux";
     description = "A Linux program that can communicate with the Micro 3D printer";
     license = licenses.gpl2;
diff --git a/pkgs/misc/drivers/moltengamepad/default.nix b/pkgs/misc/drivers/moltengamepad/default.nix
index e5b3b5bab2289..486e4e96dd41a 100644
--- a/pkgs/misc/drivers/moltengamepad/default.nix
+++ b/pkgs/misc/drivers/moltengamepad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, udev }:
+{ lib, stdenv, fetchFromGitHub, udev }:
 
 stdenv.mkDerivation {
   pname = "moltengamepad-git";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
     sed -i -e '159d;161d;472d;473d;474d;475d' source/eventlists/key_list.cpp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jgeumlek/MoltenGamepad";
     description = "Flexible Linux input device translator, geared for gamepads";
     license = licenses.mit;
diff --git a/pkgs/misc/drivers/pentablet-driver/default.nix b/pkgs/misc/drivers/pentablet-driver/default.nix
index 2f46d950d584b..91564f2db89f6 100644
--- a/pkgs/misc/drivers/pentablet-driver/default.nix
+++ b/pkgs/misc/drivers/pentablet-driver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchzip, autoPatchelfHook, libusb1, libX11, libXtst, qtbase, libglvnd }:
+{ lib, stdenv, mkDerivation, fetchzip, autoPatchelfHook, libusb1, libX11, libXtst, qtbase, libglvnd }:
 
 mkDerivation rec {
   pname = "pentablet-driver";
@@ -28,7 +28,7 @@ mkDerivation rec {
     cp config.xml $out/bin/config.xml
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.xp-pen.com/download-46.html";
     description = "Driver for XP-PEN Pentablet drawing tablets";
     license = licenses.unfree;
diff --git a/pkgs/misc/drivers/postscript-lexmark/default.nix b/pkgs/misc/drivers/postscript-lexmark/default.nix
index 74b7c68d38e7f..ebc6439dd5ca3 100644
--- a/pkgs/misc/drivers/postscript-lexmark/default.nix
+++ b/pkgs/misc/drivers/postscript-lexmark/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, rpmextract }:
+{ lib, stdenv, fetchurl, rpmextract }:
 let
   version = "20160218";
 in
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
     cp -r opt/OpenPrinting-Lexmark/doc $out/doc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.openprinting.org/driver/Postscript-Lexmark/";
     description = "Lexmark Postscript Drivers";
     platforms = platforms.linux;
diff --git a/pkgs/misc/drivers/steamcontroller/default.nix b/pkgs/misc/drivers/steamcontroller/default.nix
index 4877886d500d2..77a2e03d1618c 100644
--- a/pkgs/misc/drivers/steamcontroller/default.nix
+++ b/pkgs/misc/drivers/steamcontroller/default.nix
@@ -27,7 +27,7 @@ buildPythonApplication {
   doCheck = false;
   pythonImportsCheck = [ "steamcontroller" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A standalone Steam controller driver";
     homepage    = "https://github.com/ynsta/steamcontroller";
     license     = licenses.mit;
diff --git a/pkgs/misc/drivers/utsushi/default.nix b/pkgs/misc/drivers/utsushi/default.nix
index 748930da54602..ae3a083148ba8 100644
--- a/pkgs/misc/drivers/utsushi/default.nix
+++ b/pkgs/misc/drivers/utsushi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, writeScriptBin, fetchFromGitLab, autoreconfHook, pkg-config
+{ lib, stdenv, writeScriptBin, fetchFromGitLab, autoreconfHook, pkg-config
 , autoconf-archive, libxslt, boost , gtkmm2 , imagemagick, sane-backends
 , tesseract4, udev, libusb1, gnum4 }:
 
@@ -77,7 +77,7 @@ in stdenv.mkDerivation rec {
 
   doInstallCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SANE utsushi backend for some Epson scanners";
     longDescription = ''
       ImageScanV3 (aka utsushi) scanner driver. Non-free plugins are not
diff --git a/pkgs/misc/drivers/xboxdrv/default.nix b/pkgs/misc/drivers/xboxdrv/default.nix
index f7fd59fd9fd18..82678eec16420 100644
--- a/pkgs/misc/drivers/xboxdrv/default.nix
+++ b/pkgs/misc/drivers/xboxdrv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, sconsPackages, libX11, pkgconfig
+{ lib, stdenv, fetchurl, sconsPackages, libX11, pkgconfig
 , libusb1, boost, glib, dbus-glib }:
 
 let
@@ -17,7 +17,7 @@ in stdenv.mkDerivation {
   buildInputs = [ libX11 libusb1 boost glib dbus-glib ];
   dontUseSconsInstall = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pingus.seul.org/~grumbel/xboxdrv/";
     description = "Xbox/Xbox360 (and more) gamepad driver for Linux that works in userspace";
     license = licenses.gpl3Plus;
diff --git a/pkgs/misc/drivers/xow/default.nix b/pkgs/misc/drivers/xow/default.nix
index 785f7f396e9dd..309db8908c77f 100644
--- a/pkgs/misc/drivers/xow/default.nix
+++ b/pkgs/misc/drivers/xow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cabextract, fetchurl, fetchFromGitHub, libusb1 }:
+{ lib, stdenv, cabextract, fetchurl, fetchFromGitHub, libusb1 }:
 
 stdenv.mkDerivation rec {
   pname = "xow";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cabextract ];
   buildInputs = [ libusb1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/medusalix/xow";
     description = "Linux driver for the Xbox One wireless dongle";
     license = licenses.gpl2Plus;
diff --git a/pkgs/misc/dumb/default.nix b/pkgs/misc/dumb/default.nix
index 422885c73ed75..9b733e00f69c8 100644
--- a/pkgs/misc/dumb/default.nix
+++ b/pkgs/misc/dumb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, allegro, SDL2 }:
+{ lib, stdenv, fetchFromGitHub, cmake, allegro, SDL2 }:
 
 stdenv.mkDerivation rec {
   pname = "dumb";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "-DBUILD_EXAMPLES='OFF'"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kode54/dumb";
     description = "Module/tracker based music format parser and player library";
     license = licenses.free;  # Derivative of GPL
diff --git a/pkgs/misc/emulators/atari++/default.nix b/pkgs/misc/emulators/atari++/default.nix
index 9d7a477be61df..4758d173e92dc 100644
--- a/pkgs/misc/emulators/atari++/default.nix
+++ b/pkgs/misc/emulators/atari++/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libSM, libX11, libICE, SDL, alsaLib, gcc-unwrapped, libXext }:
+{ lib, stdenv, fetchurl, libSM, libX11, libICE, SDL, alsaLib, gcc-unwrapped, libXext }:
 
 stdenv.mkDerivation rec {
   pname = "atari++";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     patchelf --set-rpath ${stdenv.lib.makeLibraryPath buildInputs} "$out/bin/atari++"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.xl-project.com/";
     description = "An enhanced, cycle-accurated Atari emulator";
     longDescription = ''
diff --git a/pkgs/misc/emulators/attract-mode/default.nix b/pkgs/misc/emulators/attract-mode/default.nix
index ac87190b0507e..1550f71fb40ae 100644
--- a/pkgs/misc/emulators/attract-mode/default.nix
+++ b/pkgs/misc/emulators/attract-mode/default.nix
@@ -1,5 +1,5 @@
 { expat, fetchFromGitHub, ffmpeg_3, fontconfig, freetype, libarchive, libjpeg
-, libGLU, libGL, openal, pkgconfig, sfml, stdenv, zlib
+, libGLU, libGL, openal, pkgconfig, sfml, lib, stdenv, zlib
 }:
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     expat ffmpeg_3 fontconfig freetype libarchive libjpeg libGLU libGL openal sfml zlib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A frontend for arcade cabinets and media PCs";
     homepage = "http://attractmode.org";
     license = licenses.gpl3Plus;
diff --git a/pkgs/misc/emulators/caprice32/default.nix b/pkgs/misc/emulators/caprice32/default.nix
index 4b2b6208bb406..69002d00f80a5 100644
--- a/pkgs/misc/emulators/caprice32/default.nix
+++ b/pkgs/misc/emulators/caprice32/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, desktop-file-utils, libpng
+{ lib, stdenv, fetchFromGitHub, desktop-file-utils, libpng
 , pkgconfig, SDL, freetype, zlib }:
 
 stdenv.mkDerivation rec {
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     install -Dm644 $out/share/caprice32/resources/freedesktop/caprice32.menu -t $out/etc/xdg/menus/applications-merged/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A complete emulation of CPC464, CPC664 and CPC6128";
     homepage = "https://github.com/ColinPitrat/caprice32";
     license = licenses.gpl2;
diff --git a/pkgs/misc/emulators/ccemux/default.nix b/pkgs/misc/emulators/ccemux/default.nix
index 2313a63dc698b..96cb9afaf2f8b 100644
--- a/pkgs/misc/emulators/ccemux/default.nix
+++ b/pkgs/misc/emulators/ccemux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, makeWrapper, jre
+{ lib, stdenv, fetchurl, makeDesktopItem, makeWrapper, jre
 , useCCTweaked ? true
 }:
 
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modular ComputerCraft emulator";
     homepage = "https://github.com/CCEmuX/CCEmuX";
     license = licenses.mit;
diff --git a/pkgs/misc/emulators/cdemu/base.nix b/pkgs/misc/emulators/cdemu/base.nix
index f493faaac54f1..51e6a6ac5c8f5 100644
--- a/pkgs/misc/emulators/cdemu/base.nix
+++ b/pkgs/misc/emulators/cdemu/base.nix
@@ -1,5 +1,5 @@
 { pkgName, version, pkgSha256 }:
-{ stdenv, fetchurl, cmake, pkgconfig, buildInputs, drvParams ? {} }:
+{ lib, stdenv, fetchurl, cmake, pkgconfig, buildInputs, drvParams ? {} }:
 let name = "${pkgName}-${version}";
 in stdenv.mkDerivation ({
   inherit name buildInputs;
@@ -16,7 +16,7 @@ in stdenv.mkDerivation ({
   configurePhase = ''
     cmake ../${name} -DCMAKE_INSTALL_PREFIX=$out -DCMAKE_BUILD_TYPE=Release -DCMAKE_SKIP_RPATH=ON
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A suite of tools for emulating optical drives and discs";
     longDescription = ''
       CDEmu consists of:
diff --git a/pkgs/misc/emulators/cdemu/vhba.nix b/pkgs/misc/emulators/cdemu/vhba.nix
index 9723e53a8fdbb..17d2f8f5e97ad 100644
--- a/pkgs/misc/emulators/cdemu/vhba.nix
+++ b/pkgs/misc/emulators/cdemu/vhba.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, kernel }:
+{ lib, stdenv, fetchurl, kernel }:
 
 stdenv.mkDerivation rec {
   pname = "vhba";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "pic" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a Virtual (SCSI) HBA";
     homepage = "http://cdemu.sourceforge.net/about/vhba/";
     platforms = platforms.linux;
diff --git a/pkgs/misc/emulators/citra/default.nix b/pkgs/misc/emulators/citra/default.nix
index dbfc96c229811..b4afb6bbf9754 100644
--- a/pkgs/misc/emulators/citra/default.nix
+++ b/pkgs/misc/emulators/citra/default.nix
@@ -21,7 +21,7 @@ mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://citra-emu.org";
     description = "An open-source emulator for the Nintendo 3DS";
     license = licenses.gpl2;
diff --git a/pkgs/misc/emulators/craftos-pc/default.nix b/pkgs/misc/emulators/craftos-pc/default.nix
index 42fb33051e611..3bc9e0b81cc05 100644
--- a/pkgs/misc/emulators/craftos-pc/default.nix
+++ b/pkgs/misc/emulators/craftos-pc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, poco, openssl, SDL2, SDL2_mixer }:
+{ lib, stdenv, fetchFromGitHub, poco, openssl, SDL2, SDL2_mixer }:
 
 let
   craftos2-lua = fetchFromGitHub {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     DESTDIR=$out/bin make install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of the CraftOS-PC API written in C++ using SDL";
     homepage = "https://www.craftos-pc.cc";
     license = licenses.mit;
diff --git a/pkgs/misc/emulators/dgen-sdl/default.nix b/pkgs/misc/emulators/dgen-sdl/default.nix
index 1eabf5b53b015..4a76ee0df0262 100644
--- a/pkgs/misc/emulators/dgen-sdl/default.nix
+++ b/pkgs/misc/emulators/dgen-sdl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , libarchive
 , doxygen
@@ -33,7 +33,7 @@ in stdenv.mkDerivation {
     "--with-dz80"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://dgen.sourceforge.net/";
     description = "Sega Genesis/Mega Drive emulator";
     longDescription = ''
diff --git a/pkgs/misc/emulators/emu2/default.nix b/pkgs/misc/emulators/emu2/default.nix
index fb13b602b6a65..eef361ecd0378 100644
--- a/pkgs/misc/emulators/emu2/default.nix
+++ b/pkgs/misc/emulators/emu2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "emu2";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dmsc/emu2/";
     description = "A simple text-mode x86 + DOS emulator";
     platforms = platforms.linux;
diff --git a/pkgs/misc/emulators/gens-gs/default.nix b/pkgs/misc/emulators/gens-gs/default.nix
index a9449808d5272..563ea5f46f895 100644
--- a/pkgs/misc/emulators/gens-gs/default.nix
+++ b/pkgs/misc/emulators/gens-gs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk2, SDL, nasm, zlib, libpng, libGLU, libGL }:
+{ lib, stdenv, fetchurl, pkgconfig, gtk2, SDL, nasm, zlib, libpng, libGLU, libGL }:
 
 stdenv.mkDerivation {
   name = "gens-gs-7";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
   # See http://ubuntuforums.org/showthread.php?p=10535837
   NIX_CFLAGS_COMPILE = "-UGTK_DISABLE_DEPRECATED -UGSEAL_ENABLE";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://segaretro.org/Gens/GS";
     description = "A Genesis/Mega Drive emulator";
     platforms = [ "i686-linux" ];
diff --git a/pkgs/misc/emulators/gxemul/default.nix b/pkgs/misc/emulators/gxemul/default.nix
index 8671056d14ebe..3149ccaaaac0a 100644
--- a/pkgs/misc/emulators/gxemul/default.nix
+++ b/pkgs/misc/emulators/gxemul/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "gxemul";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp -r ./man $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gavare.se/gxemul/";
     description = "Gavare's experimental emulator";
     longDescription = ''
diff --git a/pkgs/misc/emulators/higan/default.nix b/pkgs/misc/emulators/higan/default.nix
index e735bdb38eed4..88872dd3972b5 100644
--- a/pkgs/misc/emulators/higan/default.nix
+++ b/pkgs/misc/emulators/higan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgconfig
 , libX11, libXv
 , udev
@@ -104,7 +104,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/higan-init.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open-source, cycle-accurate multi-system emulator";
     longDescription = ''
       higan is a multi-system game console emulator. The purpose of higan is to
diff --git a/pkgs/misc/emulators/kega-fusion/default.nix b/pkgs/misc/emulators/kega-fusion/default.nix
index 0b6fb0dea54dd..1b00a55fe0586 100644
--- a/pkgs/misc/emulators/kega-fusion/default.nix
+++ b/pkgs/misc/emulators/kega-fusion/default.nix
@@ -68,7 +68,7 @@ in stdenv.mkDerivation {
     chmod +x "$out/bin/kega-fusion"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sega SG1000, SC3000, SF7000, Master System, Game Gear, Genesis/Megadrive, SVP, Pico, SegaCD/MegaCD and 32X emulator";
     homepage = "https://www.carpeludum.com/kega-fusion/";
     maintainers = with maintainers; [ abbradar ];
diff --git a/pkgs/misc/emulators/lambda-delta/default.nix b/pkgs/misc/emulators/lambda-delta/default.nix
index 0668d2db90864..a17a0eadfd5b9 100644
--- a/pkgs/misc/emulators/lambda-delta/default.nix
+++ b/pkgs/misc/emulators/lambda-delta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkg-config, SDL2 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config, SDL2 }:
 
 stdenv.mkDerivation rec {
   pname = "lambda-delta";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--without-SDL1" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LMI (Lambda Lisp Machine) emulator";
     homepage = "https://github.com/dseagrav/ld";
     license = licenses.gpl2;
diff --git a/pkgs/misc/emulators/libdsk/default.nix b/pkgs/misc/emulators/libdsk/default.nix
index 219875ba6fcb2..c0e54e48db329 100644
--- a/pkgs/misc/emulators/libdsk/default.nix
+++ b/pkgs/misc/emulators/libdsk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "libdsk";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0s2k9vkrf95pf4ydc6vazb29ysrnhdpcfjnf17lpk4nmlv1j3vyv";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library for accessing discs and disc image files";
     homepage = "http://www.seasip.info/Unix/LibDsk/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/misc/emulators/mednafen/default.nix b/pkgs/misc/emulators/mednafen/default.nix
index cb4b7997383fd..693ada8d3c7f9 100644
--- a/pkgs/misc/emulators/mednafen/default.nix
+++ b/pkgs/misc/emulators/mednafen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, freeglut, libGLU, libGL, libcdio, libjack2
+{ lib, stdenv, fetchurl, pkgconfig, freeglut, libGLU, libGL, libcdio, libjack2
 , libsamplerate, libsndfile, libX11, SDL2, SDL2_net, zlib, alsaLib }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     mv Documentation $out/share/doc/mednafen
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A portable, CLI-driven, SDL+OpenGL-based, multi-system emulator";
     longDescription = ''
       Mednafen is a portable, utilizing OpenGL and SDL,
diff --git a/pkgs/misc/emulators/mednafen/server.nix b/pkgs/misc/emulators/mednafen/server.nix
index 9a1edc00452d3..0654262555493 100644
--- a/pkgs/misc/emulators/mednafen/server.nix
+++ b/pkgs/misc/emulators/mednafen/server.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "mednafen-server";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   postInstall = "install -m 644 -Dt $out/share/mednafen-server standard.conf";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Netplay server for Mednafen";
     homepage = "https://mednafen.github.io/";
     license = licenses.gpl2;
diff --git a/pkgs/misc/emulators/melonDS/default.nix b/pkgs/misc/emulators/melonDS/default.nix
index 7e0e9647db28a..98754de8d4f03 100644
--- a/pkgs/misc/emulators/melonDS/default.nix
+++ b/pkgs/misc/emulators/melonDS/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , mkDerivation
 , cmake
@@ -31,7 +31,7 @@ mkDerivation rec {
 
   cmakeFlags = [ "-UUNIX_PORTABLE" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://melonds.kuribo64.net/";
     description = "Work in progress Nintendo DS emulator";
     license = licenses.gpl3Plus;
diff --git a/pkgs/misc/emulators/mgba/default.nix b/pkgs/misc/emulators/mgba/default.nix
index ddbe276de3c44..a6f59122b64d6 100644
--- a/pkgs/misc/emulators/mgba/default.nix
+++ b/pkgs/misc/emulators/mgba/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeDesktopItem, wrapQtAppsHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, makeDesktopItem, wrapQtAppsHook, pkgconfig
 , cmake, epoxy, libzip, libelf, libedit, ffmpeg_3, SDL2, imagemagick
 , qtbase, qtmultimedia, qttools, minizip }:
 
@@ -35,7 +35,7 @@ in stdenv.mkDerivation rec {
     cp -r ${desktopItem}/share/applications $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mgba.io";
     description = "A modern GBA emulator with a focus on accuracy";
 
diff --git a/pkgs/misc/emulators/mupen64plus/default.nix b/pkgs/misc/emulators/mupen64plus/default.nix
index 621559627a75d..49681aaee9420 100644
--- a/pkgs/misc/emulators/mupen64plus/default.nix
+++ b/pkgs/misc/emulators/mupen64plus/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, boost, dash, freetype, libpng, pkgconfig, SDL, which, zlib, nasm }:
+{lib, stdenv, fetchurl, boost, dash, freetype, libpng, pkgconfig, SDL, which, zlib, nasm }:
 
 stdenv.mkDerivation rec {
   pname = "mupen64plus";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     dash m64p_install.sh DESTDIR="$out" PREFIX=""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Nintendo 64 Emulator";
     license = licenses.gpl2Plus;
     homepage = "http://www.mupen64plus.org/";
diff --git a/pkgs/misc/emulators/pcsx2/default.nix b/pkgs/misc/emulators/pcsx2/default.nix
index 5bbf70004abe7..a71ccb46b9985 100644
--- a/pkgs/misc/emulators/pcsx2/default.nix
+++ b/pkgs/misc/emulators/pcsx2/default.nix
@@ -19,7 +19,7 @@
 , portaudio
 , SDL2
 , soundtouch
-, stdenv
+, lib, stdenv
 , udev
 , wrapGAppsHook
 , wxGTK
@@ -91,7 +91,7 @@ stdenv.mkDerivation {
     zlib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Playstation 2 emulator";
     longDescription= ''
       PCSX2 is an open-source PlayStation 2 (AKA PS2) emulator. Its purpose
diff --git a/pkgs/misc/emulators/pcsxr/default.nix b/pkgs/misc/emulators/pcsxr/default.nix
index ae608f5631285..47a87dcca0b5e 100644
--- a/pkgs/misc/emulators/pcsxr/default.nix
+++ b/pkgs/misc/emulators/pcsxr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, intltool, pkgconfig, gtk3, SDL2, xorg
+{ lib, stdenv, fetchurl, autoreconfHook, intltool, pkgconfig, gtk3, SDL2, xorg
 , wrapGAppsHook, libcdio, nasm, ffmpeg, file
 , fetchpatch }:
 
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
        "$out/share/doc/${pname}-${version}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Playstation 1 emulator";
     homepage = "https://pcsxr.codeplex.com/";
     maintainers = with maintainers; [ rardiol ];
diff --git a/pkgs/misc/emulators/qmc2/default.nix b/pkgs/misc/emulators/qmc2/default.nix
index 5a813c5d2efe2..b38692de26330 100644
--- a/pkgs/misc/emulators/qmc2/default.nix
+++ b/pkgs/misc/emulators/qmc2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl, qttools, pkgconfig
 , minizip, zlib
 , qtbase, qtsvg, qtmultimedia, qtwebkit, qttranslations, qtxmlpatterns
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
                 "DATADIR=/share/"
                 "SYSCONFDIR=/etc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Qt frontend for MAME/MESS";
     homepage = "https://qmc2.batcom-it.net";
     license = licenses.gpl2;
diff --git a/pkgs/misc/emulators/reicast/default.nix b/pkgs/misc/emulators/reicast/default.nix
index c9dff7217d2f1..8c0bc30d4384a 100644
--- a/pkgs/misc/emulators/reicast/default.nix
+++ b/pkgs/misc/emulators/reicast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , pkg-config
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://reicast.com/";
     description = "A multi-platform Sega Dreamcast emulator";
     license = with licenses; [ bsd3 gpl2Only lgpl2Only ];
diff --git a/pkgs/misc/emulators/retroarch/cores.nix b/pkgs/misc/emulators/retroarch/cores.nix
index c210b3ddeecee..6577157789608 100644
--- a/pkgs/misc/emulators/retroarch/cores.nix
+++ b/pkgs/misc/emulators/retroarch/cores.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchFromGitHub, fetchFromGitLab, fetchpatch, cmake, pkgconfig, makeWrapper, python27, python37, retroarch
+{ lib, stdenv, fetchgit, fetchFromGitHub, fetchFromGitLab, fetchpatch, cmake, pkgconfig, makeWrapper, python27, python37, retroarch
 , alsaLib, fluidsynth, curl, hidapi, libGLU, gettext, glib, gtk2, portaudio, SDL, SDL_net, SDL2, SDL2_image, libGL
 , ffmpeg_3, pcre, libevdev, libpng, libjpeg, libzip, udev, libvorbis, snappy, which, hexdump
 , miniupnpc, sfml, xorg, zlib, nasm, libpcap, boost, icu, openssl
@@ -46,7 +46,7 @@ let
       libretroCore = "/lib/retroarch/cores";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       inherit (a) description license;
       broken = a.broken or false;
       homepage = "https://www.libretro.com/";
diff --git a/pkgs/misc/emulators/retrofe/default.nix b/pkgs/misc/emulators/retrofe/default.nix
index d2c904723b1ed..f69505b65f12d 100644
--- a/pkgs/misc/emulators/retrofe/default.nix
+++ b/pkgs/misc/emulators/retrofe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchhg, cmake, glib, gst_all_1, makeWrapper, pkgconfig
+{ lib, stdenv, fetchhg, cmake, glib, gst_all_1, makeWrapper, pkgconfig
 , python, SDL2, SDL2_image, SDL2_mixer, SDL2_ttf, sqlite, zlib, runtimeShell
 }:
 
@@ -68,7 +68,7 @@ stdenv.mkDerivation {
       --run 'export RETROFE_PATH=''${RETROFE_PATH:-$PWD}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A frontend for arcade cabinets and media PCs";
     homepage = "http://retrofe.com";
     license = licenses.gpl3Plus;
diff --git a/pkgs/misc/emulators/ruffle/default.nix b/pkgs/misc/emulators/ruffle/default.nix
index f3518a647fa10..b817716075cc8 100644
--- a/pkgs/misc/emulators/ruffle/default.nix
+++ b/pkgs/misc/emulators/ruffle/default.nix
@@ -4,7 +4,7 @@
 , pkg-config
 , python3
 , rustPlatform
-, stdenv
+, lib, stdenv
 , wayland
 , xorg
 }:
@@ -39,7 +39,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "05kwfcbzjyyfhiqklhhlv06pinzw9bry4j8l9lk3k04c1q30gzkw";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Adobe Flash Player emulator written in the Rust programming language.";
     homepage = "https://ruffle.rs/";
     license = with licenses; [ mit asl20 ];
diff --git a/pkgs/misc/emulators/ryujinx/default.nix b/pkgs/misc/emulators/ryujinx/default.nix
index 0e6784e69eabb..b7259a3deb32f 100644
--- a/pkgs/misc/emulators/ryujinx/default.nix
+++ b/pkgs/misc/emulators/ryujinx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, makeWrapper, makeDesktopItem, linkFarmFromDrvs
+{ lib, stdenv, fetchFromGitHub, fetchurl, makeWrapper, makeDesktopItem, linkFarmFromDrvs
 , dotnet-sdk_3, dotnetPackages, dotnetCorePackages
 , SDL2, libX11, openal
 , gtk3, gobject-introspection, wrapGAppsHook
@@ -96,7 +96,7 @@ in stdenv.mkDerivation rec {
   # Strip breaks the executable.
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Experimental Nintendo Switch Emulator written in C#";
     homepage = "https://ryujinx.org/";
     license = licenses.mit;
diff --git a/pkgs/misc/emulators/sameboy/default.nix b/pkgs/misc/emulators/sameboy/default.nix
index e90cc5a00f505..d23129eba7e5c 100644
--- a/pkgs/misc/emulators/sameboy/default.nix
+++ b/pkgs/misc/emulators/sameboy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, rgbds, SDL2, wrapGAppsHook, glib }:
+{ lib, stdenv, fetchFromGitHub, gtk3, rgbds, SDL2, wrapGAppsHook, glib }:
 
 stdenv.mkDerivation rec {
   pname = "sameboy";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sameboy.github.io";
     description = "Game Boy, Game Boy Color, and Super Game Boy emulator";
 
diff --git a/pkgs/misc/emulators/simh/default.nix b/pkgs/misc/emulators/simh/default.nix
index 50e02a8f2403c..08068debeefcb 100644
--- a/pkgs/misc/emulators/simh/default.nix
+++ b/pkgs/misc/emulators/simh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , SDL2
 , SDL2_ttf
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     (cd $out/bin; for i in *; do ln -s $i simh-$i; done)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://simh.trailing-edge.com/";
     description = "A collection of simulators of historic hardware";
     longDescription = ''
diff --git a/pkgs/misc/emulators/simplenes/default.nix b/pkgs/misc/emulators/simplenes/default.nix
index d4805a62d761e..d073098507ee2 100644
--- a/pkgs/misc/emulators/simplenes/default.nix
+++ b/pkgs/misc/emulators/simplenes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , sfml
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp ./SimpleNES $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/amhndu/SimpleNES";
     description = "An NES emulator written in C++";
     license = licenses.gpl3;
diff --git a/pkgs/misc/emulators/snes9x-gtk/default.nix b/pkgs/misc/emulators/snes9x-gtk/default.nix
index f33af245f7102..254c4a329e540 100644
--- a/pkgs/misc/emulators/snes9x-gtk/default.nix
+++ b/pkgs/misc/emulators/snes9x-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, wrapGAppsHook
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, wrapGAppsHook
 , SDL2, zlib, gtk3, libxml2, libXv, epoxy, minizip, pulseaudio, portaudio }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "cd gtk";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.snes9x.com";
     description = "Super Nintendo Entertainment System (SNES) emulator";
 
diff --git a/pkgs/misc/emulators/tilem/default.nix b/pkgs/misc/emulators/tilem/default.nix
index 8a6c5075c9b31..4c51759e71e83 100644
--- a/pkgs/misc/emulators/tilem/default.nix
+++ b/pkgs/misc/emulators/tilem/default.nix
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ glib gnome2.gtk libticonv libtifiles2 libticables2 libticalcs2 ];
   NIX_CFLAGS_COMPILE = [ "-lm" ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://lpg.ticalc.org/prj_tilem/";
     description = "Emulator and debugger for Texas Instruments Z80-based graphing calculators";
     license = licenses.gpl3Plus;
diff --git a/pkgs/misc/emulators/wine/vkd3d.nix b/pkgs/misc/emulators/wine/vkd3d.nix
index 91bef28559d55..303d33df217df 100644
--- a/pkgs/misc/emulators/wine/vkd3d.nix
+++ b/pkgs/misc/emulators/wine/vkd3d.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, vulkan-headers, spirv-headers, vulkan-loader }:
+{ lib, stdenv, fetchurl, vulkan-headers, spirv-headers, vulkan-loader }:
 
 #TODO: MoltenVK
 #TODO: unstable
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 3d library build on top on Vulkan with a similar api to DirectX 12";
     homepage = "https://source.winehq.org/git/vkd3d.git";
     license = licenses.lgpl21;
diff --git a/pkgs/misc/emulators/yabause/default.nix b/pkgs/misc/emulators/yabause/default.nix
index 584a7b47dc700..80ddc32ac6cf9 100644
--- a/pkgs/misc/emulators/yabause/default.nix
+++ b/pkgs/misc/emulators/yabause/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, cmake, pkgconfig, qtbase, qt5, libGLU, libGL
+{ mkDerivation, lib, stdenv, fetchurl, cmake, pkgconfig, qtbase, qt5, libGLU, libGL
 , freeglut ? null, openal ? null, SDL2 ? null }:
 
 mkDerivation rec {
@@ -26,7 +26,7 @@ mkDerivation rec {
     "-DYAB_PORTS=qt"
   ] ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open-source Sega Saturn emulator";
     homepage = "https://yabause.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/misc/emulators/yuzu/default.nix b/pkgs/misc/emulators/yuzu/default.nix
index 3c643822c16e4..ae151f96ed369 100644
--- a/pkgs/misc/emulators/yuzu/default.nix
+++ b/pkgs/misc/emulators/yuzu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, pkgconfig, wrapQtAppsHook
 , boost173, catch2, fmt, lz4, nlohmann_json, rapidjson, zlib, zstd, SDL2
 , udev, libusb1, libzip, qtbase, qtwebengine, qttools, ffmpeg
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/yuzu-cmd --prefix LD_LIBRARY_PATH : ${vulkan-loader}/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://yuzu-emu.org";
     description = "An experimental Nintendo Switch emulator written in C++";
     license = with licenses; [
diff --git a/pkgs/misc/gnuk/generic.nix b/pkgs/misc/gnuk/generic.nix
index c7bbb3b530d77..8ed186e1ed619 100644
--- a/pkgs/misc/gnuk/generic.nix
+++ b/pkgs/misc/gnuk/generic.nix
@@ -1,4 +1,4 @@
-{ stdenv, gcc-arm-embedded, binutils-arm-embedded, makeWrapper
+{ lib, stdenv, gcc-arm-embedded, binutils-arm-embedded, makeWrapper
 , python, pythonPackages
 
 # Extra options
@@ -43,7 +43,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/{unlock,flash}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.fsij.org/pages/gnuk";
     description = "An implementation of USB cryptographic token for gpg";
     license = licenses.gpl3;
diff --git a/pkgs/misc/hdt/default.nix b/pkgs/misc/hdt/default.nix
index a8cf5c5d4d354..a01668e138f48 100644
--- a/pkgs/misc/hdt/default.nix
+++ b/pkgs/misc/hdt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, libtool, pkgconfig, zlib, serd }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, libtool, pkgconfig, zlib, serd }:
 
 stdenv.mkDerivation rec {
   pname = "hdt";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.rdfhdt.org/";
     description = "Header Dictionary Triples (HDT) is a compression format for RDF data that can also be queried for Triple Patterns";
     license = licenses.lgpl21;
diff --git a/pkgs/misc/jackaudio/jack1.nix b/pkgs/misc/jackaudio/jack1.nix
index 2b5d0d960caf1..2a5bf806d0f30 100644
--- a/pkgs/misc/jackaudio/jack1.nix
+++ b/pkgs/misc/jackaudio/jack1.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 
 # Optional Dependencies
 , alsaLib ? null, db ? null, libuuid ? null, libffado ? null, celt ? null
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ optAlsaLib optDb optLibffado optCelt ];
   propagatedBuildInputs = [ optLibuuid ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "JACK audio connection kit";
     homepage = "https://jackaudio.org";
     license = with licenses; [ gpl2 lgpl21 ];
diff --git a/pkgs/misc/lguf-brightness/default.nix b/pkgs/misc/lguf-brightness/default.nix
index 02ce011c59dfb..efdc8e151482b 100644
--- a/pkgs/misc/lguf-brightness/default.nix
+++ b/pkgs/misc/lguf-brightness/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libusb1, ncurses5 }:
+{ lib, stdenv, fetchFromGitHub, cmake, libusb1, ncurses5 }:
 
 stdenv.mkDerivation rec {
   pname = "lguf-brightness";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -D lguf_brightness $out/bin/lguf_brightness
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Adjust brightness for LG UltraFine 4K display (cross platform)";
     homepage = "https://github.com/periklis/lguf-brightness";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/misc/lightspark/default.nix b/pkgs/misc/lightspark/default.nix
index 0e098d3a704db..bd33997d09af3 100644
--- a/pkgs/misc/lightspark/default.nix
+++ b/pkgs/misc/lightspark/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, cmake, curl, zlib, ffmpeg_3, glew, pcre
+{ lib, stdenv, fetchFromGitHub, pkgconfig, cmake, curl, zlib, ffmpeg_3, glew, pcre
 , rtmpdump, cairo, boost, SDL2, SDL2_mixer, libjpeg, pango, lzma, nasm
 , llvm, glibmm
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     pango lzma nasm llvm glibmm
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source Flash Player implementation";
     homepage = "https://lightspark.github.io/";
     license = licenses.lgpl3;
diff --git a/pkgs/misc/lilypond/fonts.nix b/pkgs/misc/lilypond/fonts.nix
index deeedf6799543..ca87db757cc06 100644
--- a/pkgs/misc/lilypond/fonts.nix
+++ b/pkgs/misc/lilypond/fonts.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, lilypond }:
+{ lib, stdenv, fetchFromGitHub, lilypond }:
 
 let
 
@@ -29,7 +29,7 @@ let
         done
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         inherit (lilypond.meta) homepage platforms;
         description = "${fontName} font for LilyPond";
         license = licenses.ofl;
diff --git a/pkgs/misc/logging/beats/6.x.nix b/pkgs/misc/logging/beats/6.x.nix
index 2d01ea622612d..7196202dba4ac 100644
--- a/pkgs/misc/logging/beats/6.x.nix
+++ b/pkgs/misc/logging/beats/6.x.nix
@@ -15,7 +15,7 @@ let beat = package : extraArgs : buildGoPackage (rec {
 
       subPackages = [ package ];
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.elastic.co/products/beats";
         license = licenses.asl20;
         maintainers = with maintainers; [ fadenb basvandijk ];
diff --git a/pkgs/misc/logging/beats/7.x.nix b/pkgs/misc/logging/beats/7.x.nix
index 465051d3726ea..9e524e6a5e6c0 100644
--- a/pkgs/misc/logging/beats/7.x.nix
+++ b/pkgs/misc/logging/beats/7.x.nix
@@ -15,7 +15,7 @@ let beat = package : extraArgs : buildGoPackage (rec {
 
       subPackages = [ package ];
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://www.elastic.co/products/beats";
         license = licenses.asl20;
         maintainers = with maintainers; [ fadenb basvandijk ];
diff --git a/pkgs/misc/mxt-app/default.nix b/pkgs/misc/mxt-app/default.nix
index 96d1c17fb2948..099300634e8c9 100644
--- a/pkgs/misc/mxt-app/default.nix
+++ b/pkgs/misc/mxt-app/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, libtool }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, libtool }:
 
 stdenv.mkDerivation rec {
   version="1.32";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "fortify" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line utility for Atmel maXTouch devices";
     homepage = "https://github.com/atmel-maxtouch/mxt-app";
     license = licenses.bsd2;
diff --git a/pkgs/misc/ptouch-print/default.nix b/pkgs/misc/ptouch-print/default.nix
index ac15ec6330973..f9889cfe4bef9 100644
--- a/pkgs/misc/ptouch-print/default.nix
+++ b/pkgs/misc/ptouch-print/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , autoreconfHook
 , gd
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     libusb1
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tool to print labels on Brother P-Touch printers on Linux";
     license = licenses.gpl3Plus;
     homepage = "https://mockmoon-cybernetics.ch/computer/p-touch2430pc/";
diff --git a/pkgs/misc/rkdeveloptool/default.nix b/pkgs/misc/rkdeveloptool/default.nix
index 8ce4fd8e14c70..f149072a7bbac 100644
--- a/pkgs/misc/rkdeveloptool/default.nix
+++ b/pkgs/misc/rkdeveloptool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libusb1 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libusb1 }:
 
 stdenv.mkDerivation {
   pname = "rkdeveloptool";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ libusb1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rockchip-linux/rkdeveloptool";
     description = "A tool from Rockchip to communicate with Rockusb devices";
     license = licenses.gpl2;
diff --git a/pkgs/misc/sailsd/default.nix b/pkgs/misc/sailsd/default.nix
index 0dca07010980a..2c67853ae317b 100644
--- a/pkgs/misc/sailsd/default.nix
+++ b/pkgs/misc/sailsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, jansson }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, jansson }:
 
 let
   libsailing = fetchFromGitHub {
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
       --replace gcc cc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simulator daemon for autonomous sailing boats";
     homepage = "https://github.com/sails-simulator/sailsd";
     license = licenses.gpl3;
diff --git a/pkgs/misc/scrcpy/default.nix b/pkgs/misc/scrcpy/default.nix
index adebcbd633db3..0e0769f35de55 100644
--- a/pkgs/misc/scrcpy/default.nix
+++ b/pkgs/misc/scrcpy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchurl, fetchFromGitHub, makeWrapper
 , meson
 , ninja
 , pkg-config
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     wrapProgram "$out/bin/scrcpy" --prefix PATH : "${platform-tools}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display and control Android devices over USB or TCP/IP";
     homepage = "https://github.com/Genymobile/scrcpy";
     license = licenses.asl20;
diff --git a/pkgs/misc/screensavers/alock/default.nix b/pkgs/misc/screensavers/alock/default.nix
index c9340b2503e8f..3457454575053 100644
--- a/pkgs/misc/screensavers/alock/default.nix
+++ b/pkgs/misc/screensavers/alock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchgit, pkgconfig, autoreconfHook
 , libX11, pam, libgcrypt, libXrender, imlib2 }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     pam libgcrypt libXrender imlib2
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Arkq/alock";
     description = "Simple screen lock application for X server";
     longDescription = ''
diff --git a/pkgs/misc/screensavers/betterlockscreen/default.nix b/pkgs/misc/screensavers/betterlockscreen/default.nix
index f090156a85c0d..a62aeda9f5069 100644
--- a/pkgs/misc/screensavers/betterlockscreen/default.nix
+++ b/pkgs/misc/screensavers/betterlockscreen/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv, makeWrapper, fetchFromGitHub,
+  lib, stdenv, makeWrapper, fetchFromGitHub,
   imagemagick, i3lock-color, xdpyinfo, xrandr, bc, feh, procps, xrdb
 }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
       wrapProgram "$out/bin/betterlockscreen" --prefix PATH : "$out/bin:${PATH}"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple minimal lock screen which allows you to cache images with different filters and lockscreen with blazing speed";
     homepage = "https://github.com/pavanjadhaw/betterlockscreen";
     license = licenses.mit;
diff --git a/pkgs/misc/screensavers/electricsheep/default.nix b/pkgs/misc/screensavers/electricsheep/default.nix
index 0d772da679059..b9aa087283956 100644
--- a/pkgs/misc/screensavers/electricsheep/default.nix
+++ b/pkgs/misc/screensavers/electricsheep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, wxGTK30, libav, lua5_1, curl
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, wxGTK30, libav, lua5_1, curl
 , libpng, xorg, pkgconfig, flam3, libgtop, boost, tinyxml, freeglut, libGLU, libGL
 , glee }:
 
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     sed -i "s|/usr|$out|" Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Electric Sheep, a distributed screen saver for evolving artificial organisms";
     homepage = "https://electricsheep.org/";
     maintainers = with maintainers; [ nand0p fpletz ];
diff --git a/pkgs/misc/screensavers/i3lock-pixeled/default.nix b/pkgs/misc/screensavers/i3lock-pixeled/default.nix
index 39497917755f1..cb7a2fd1e1845 100644
--- a/pkgs/misc/screensavers/i3lock-pixeled/default.nix
+++ b/pkgs/misc/screensavers/i3lock-pixeled/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, i3lock, imagemagick, scrot, playerctl, fetchFromGitLab }:
+{ lib, stdenv, i3lock, imagemagick, scrot, playerctl, fetchFromGitLab }:
 
 stdenv.mkDerivation rec {
   pname = "i3lock-pixeled";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
        --replace playerctl "${playerctl}/bin/playerctl"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple i3lock helper which pixels a screenshot by scaling it down and up to get a pixeled version of the screen when the lock is active";
     homepage = "https://gitlab.com/Ma27/i3lock-pixeled";
     license = licenses.mit;
diff --git a/pkgs/misc/screensavers/light-locker/default.nix b/pkgs/misc/screensavers/light-locker/default.nix
index c4915bec8959a..0853a25a3eb1f 100644
--- a/pkgs/misc/screensavers/light-locker/default.nix
+++ b/pkgs/misc/screensavers/light-locker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/the-cavalry/light-locker";
     description = "A simple session-locker for LightDM";
     longDescription = ''
diff --git a/pkgs/misc/screensavers/multilockscreen/default.nix b/pkgs/misc/screensavers/multilockscreen/default.nix
index 3fa6dbc725e94..4d4e7609d9367 100644
--- a/pkgs/misc/screensavers/multilockscreen/default.nix
+++ b/pkgs/misc/screensavers/multilockscreen/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv, makeWrapper, fetchFromGitHub, writeShellScriptBin,
+  lib, stdenv, makeWrapper, fetchFromGitHub, writeShellScriptBin,
   imagemagick, i3lock-color, xdpyinfo, xrandr, bc, feh, procps, xrdb, xset,
   gnused, gnugrep, coreutils
 }:
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     wrapProgram "$out/bin/multilockscreen" --prefix PATH : "${binPath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wrapper script for i3lock-color";
     longDescription = ''
       multilockscreen is a wrapper script for i3lock-color.
diff --git a/pkgs/misc/screensavers/physlock/default.nix b/pkgs/misc/screensavers/physlock/default.nix
index c27ac344e0550..d25a777e650be 100644
--- a/pkgs/misc/screensavers/physlock/default.nix
+++ b/pkgs/misc/screensavers/physlock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pam, systemd }:
+{ lib, stdenv, fetchFromGitHub, pam, systemd }:
 
 stdenv.mkDerivation rec {
   version = "v13";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" "SESSION=systemd" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A secure suspend/hibernate-friendly alternative to `vlock -an`";
     license = licenses.gpl2;
     platforms = platforms.linux;
diff --git a/pkgs/misc/screensavers/pipes/default.nix b/pkgs/misc/screensavers/pipes/default.nix
index 94d6299d38328..a4e40fd77efe3 100644
--- a/pkgs/misc/screensavers/pipes/default.nix
+++ b/pkgs/misc/screensavers/pipes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, coreutils, ncurses }:
+{ lib, stdenv, fetchurl, makeWrapper, coreutils, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "pipes";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       --set PATH "${stdenv.lib.makeBinPath [ coreutils ncurses ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pipeseroni/pipes.sh";
     description = "Animated pipes terminal screensaver";
     license = licenses.mit;
diff --git a/pkgs/misc/screensavers/vlock/default.nix b/pkgs/misc/screensavers/vlock/default.nix
index 83d82e2b3b34c..243d582bdcee7 100644
--- a/pkgs/misc/screensavers/vlock/default.nix
+++ b/pkgs/misc/screensavers/vlock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pam }:
+{ lib, stdenv, fetchurl, pam }:
 
 stdenv.mkDerivation {
   name = "vlock-2.2.2";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ pam ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Virtual console locking program";
     license = licenses.gpl2;
     maintainers = [ maintainers.lethalman ];
diff --git a/pkgs/misc/screensavers/xautolock/default.nix b/pkgs/misc/screensavers/xautolock/default.nix
index d46f772e49539..cdb12b5546472 100644
--- a/pkgs/misc/screensavers/xautolock/default.nix
+++ b/pkgs/misc/screensavers/xautolock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xlibsWrapper
+{ lib, stdenv, fetchFromGitHub, xlibsWrapper
 , imake, gccmakedep, libXScrnSaver, xorgproto
 }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   installTargets = [ "install" "install.man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Launch a given program when your X session has been idle for a given time";
     homepage = "http://www.ibiblio.org/pub/linux/X11/screensavers";
     maintainers = with maintainers; [ peti ];
diff --git a/pkgs/misc/screensavers/xss-lock/default.nix b/pkgs/misc/screensavers/xss-lock/default.nix
index fcd2e877b267d..c6dafd2a81272 100644
--- a/pkgs/misc/screensavers/xss-lock/default.nix
+++ b/pkgs/misc/screensavers/xss-lock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, docutils, pkg-config, glib, libpthreadstubs
+{ lib, stdenv, fetchFromGitHub, cmake, docutils, pkg-config, glib, libpthreadstubs
 , libXau, libXdmcp, xcbutil }:
 
 stdenv.mkDerivation {
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ cmake pkg-config docutils ];
   buildInputs = [ glib libpthreadstubs libXau libXdmcp xcbutil ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Use external locker (such as i3lock) as X screen saver";
     license = licenses.mit;
     maintainers = with maintainers; [ malyn offline ];
diff --git a/pkgs/misc/seafile-shared/default.nix b/pkgs/misc/seafile-shared/default.nix
index 0d911cd35c1ef..21e2d4516cbea 100644
--- a/pkgs/misc/seafile-shared/default.nix
+++ b/pkgs/misc/seafile-shared/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , ccnet
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/haiwen/seafile";
     description = "Shared components of Seafile: seafile-daemon, libseafile, libseafile python bindings, manuals, and icons";
     license = licenses.gpl3;
diff --git a/pkgs/misc/sndio/default.nix b/pkgs/misc/sndio/default.nix
index 34e60b8a4bb76..179148ac3fcf3 100644
--- a/pkgs/misc/sndio/default.nix
+++ b/pkgs/misc/sndio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, fixDarwinDylibNames }:
+{ lib, stdenv, fetchurl, alsaLib, fixDarwinDylibNames }:
 
 stdenv.mkDerivation rec {
   pname = "sndio";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
     sha256 = "0ljmac0lnjn61admgbcwjfcr5fwccrsblx9rj9bys8wlhz8f796x";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.sndio.org";
     description = "Small audio and MIDI framework part of the OpenBSD project";
     license = licenses.isc;
diff --git a/pkgs/misc/sound-of-sorting/default.nix b/pkgs/misc/sound-of-sorting/default.nix
index 6b660232d52c6..6e838803dea05 100644
--- a/pkgs/misc/sound-of-sorting/default.nix
+++ b/pkgs/misc/sound-of-sorting/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, SDL2, wxGTK } :
+{ lib, stdenv, fetchFromGitHub, SDL2, wxGTK } :
 
 stdenv.mkDerivation rec {
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     export SDL_CONFIG=${SDL2.dev}/bin/sdl2-config
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Audibilization and Visualization of Sorting Algorithms";
     homepage = "https://panthema.net/2013/sound-of-sorting/";
     license = with licenses; gpl3;
diff --git a/pkgs/misc/tmux-plugins/default.nix b/pkgs/misc/tmux-plugins/default.nix
index e41427d89e599..2b5d7f7caed27 100644
--- a/pkgs/misc/tmux-plugins/default.nix
+++ b/pkgs/misc/tmux-plugins/default.nix
@@ -136,7 +136,7 @@ in rec {
       rev = "6757a5329948f00addd66b02ea94f61dd94456f5";
       sha256 = "0wwwzg3bwcrbr2nmf84prz7k4i79yq0960vs6zjp0x8nqn2fvziy";
     };
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://draculatheme.com/tmux";
       description = "A feature packed Dracula theme for tmux!";
       license = licenses.mit;
@@ -213,7 +213,7 @@ in rec {
     '';
     dependencies = [ pkgs.ruby ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/schasse/tmux-jump";
       description = "Vimium/Easymotion like navigation for tmux";
       license = licenses.gpl3;
@@ -430,7 +430,7 @@ in rec {
       sha256 = "1x58h3bg9d69j40fh8rcjpxvg0i6j04pj8p3jk57l3cghxis5j05";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/jabirali/tmux-tilish";
       description = "Plugin which makes tmux work and feel like i3wm";
       license = licenses.mit;
@@ -510,7 +510,7 @@ in rec {
       sha256 = "130l73v18md95djkc4s9d0fr018f8f183sjcgy7dgldwdaxlqdi1";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/tmux-plugins/vim-tmux-focus-events";
       description = "Makes FocusGained and FocusLost autocommand events work in vim when using tmux";
       license = licenses.mit;
diff --git a/pkgs/misc/urbit/default.nix b/pkgs/misc/urbit/default.nix
index 031b65a1ef613..97f5edd94b363 100644
--- a/pkgs/misc/urbit/default.nix
+++ b/pkgs/misc/urbit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, curl, git, gmp, libsigsegv, meson, ncurses, ninja
+{ lib, stdenv, fetchFromGitHub, curl, git, gmp, libsigsegv, meson, ncurses, ninja
 , openssl, pkgconfig, re2c, zlib
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     patchShebangs .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An operating function";
     homepage = "https://urbit.org";
     license = licenses.mit;
diff --git a/pkgs/misc/vim-plugins/overrides.nix b/pkgs/misc/vim-plugins/overrides.nix
index 17d5dd925eb2a..48c86ed5b480d 100644
--- a/pkgs/misc/vim-plugins/overrides.nix
+++ b/pkgs/misc/vim-plugins/overrides.nix
@@ -231,7 +231,7 @@ self: super: {
   });
 
   vimsence = super.vimsence.overrideAttrs(old: {
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Discord rich presence for Vim";
       homepage = "https://github.com/hugolgst/vimsence";
       maintainers = with stdenv.lib.maintainers; [ hugolgst ];
@@ -321,7 +321,7 @@ self: super: {
       # remove unnecessary duplicated bin wrapper script
       rm -r plugin/vimacs
     '';
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Vim-Improved eMACS: Emacs emulation plugin for Vim";
       homepage = "http://algorithm.com.au/code/vimacs";
       license = licenses.gpl2Plus;
@@ -557,7 +557,7 @@ self: super: {
       ln -s ${ycmd}/lib/ycmd third_party
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A code-completion engine for Vim";
       homepage = "https://github.com/Valloric/YouCompleteMe";
       license = licenses.gpl3;
diff --git a/pkgs/misc/vscode-extensions/cpptools/default.nix b/pkgs/misc/vscode-extensions/cpptools/default.nix
index f6c765383ea3f..bb547b3d34d08 100644
--- a/pkgs/misc/vscode-extensions/cpptools/default.nix
+++ b/pkgs/misc/vscode-extensions/cpptools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, vscode-utils
+{ lib, stdenv, vscode-utils
 , fetchurl, unzip
 , mono, writeScript, runtimeShell
 , jq, clang-tools
@@ -92,7 +92,7 @@ vscode-utils.buildVscodeMarketplaceExtension rec {
     chmod a+x ./bin/cpptools{-srv,}
   '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       license = licenses.unfree;
       maintainers = [ maintainers.jraygauthier ];
       # A 32 bit linux would also be possible with some effort (specific download of binaries +
diff --git a/pkgs/misc/vscode-extensions/default.nix b/pkgs/misc/vscode-extensions/default.nix
index 42983053c1acc..180dddab98eb9 100644
--- a/pkgs/misc/vscode-extensions/default.nix
+++ b/pkgs/misc/vscode-extensions/default.nix
@@ -58,7 +58,7 @@ let
           version = "1.0.1";
           sha256 = "0zd0n9f5z1f0ckzfjr38xw2zzmcxg1gjrava7yahg5cvdcw6l35b";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
         };
       };
@@ -70,7 +70,7 @@ let
           version = "0.0.1";
           sha256 = "07w35c69vk1l6vipnq3qfack36qcszqxn8j3v332bl0w6m02aa7k";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mpl20;
         };
       };
@@ -82,7 +82,7 @@ let
           version = "0.1.0";
           sha256 = "0q089jnzqzhjfnv0vlb5kf747s3mgz64r7q3zscl66zb2pz5q4zd";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
         };
       };
@@ -94,7 +94,7 @@ let
           version = "0.2.0";
           sha256 = "0nppgfbmw0d089rka9cqs3sbd5260dhhiipmjfga3nar9vp87slh";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
         };
       };
@@ -162,7 +162,7 @@ let
           version = "1.1.0";
           sha256 = "1wg06lyk0qn9jd6gi007sg7v0z9z8gwq7x2449d4ihs9n3w5l0gb";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
         };
       };
@@ -174,7 +174,7 @@ let
           version = "0.1.2";
           sha256 = "0i9kpnlk3naycc7k8gmcxas3s06d67wxr3nnyv5hxmsnsx5sfvb7";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
         };
       };
@@ -186,7 +186,7 @@ let
           version = "8.2.0";
           sha256 = "1ai16aam4v5jzhxgms589q0l24kyk1a9in6z4i7g05b3sahyxab2";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
         };
       };
@@ -364,7 +364,7 @@ let
           version = "0.2.1";
           sha256 = "0y1ivymn81ranmir25zk83kdjpjwcqpnc9r3jwfykjd9x0jib2hl";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
         };
       };
@@ -430,7 +430,7 @@ let
           version = "1.9.0";
           sha256 = "abd0ef9176eff864f278c548c944032b8f4d8ec97d9ac6e7383d60c92e258c2f";
         };
-        meta = with stdenv.lib; {
+        meta = with lib; {
           license = licenses.mit;
           maintainers = [ maintainers.zeratax ];
         };
diff --git a/pkgs/misc/vscode-extensions/remote-ssh/default.nix b/pkgs/misc/vscode-extensions/remote-ssh/default.nix
index e58ea98a606fc..575b9ed490ca9 100644
--- a/pkgs/misc/vscode-extensions/remote-ssh/default.nix
+++ b/pkgs/misc/vscode-extensions/remote-ssh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , vscode-utils
 , useLocalExtensions ? false}:
 # Note that useLocalExtensions requires that vscode-server is not running
@@ -45,7 +45,7 @@ in
         --replace "# install extensions" '${patch}'
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description ="Use any remote machine with a SSH server as your development environment.";
       license = licenses.unfree;
       maintainers = with maintainers; [
diff --git a/pkgs/misc/vscode-extensions/wakatime/default.nix b/pkgs/misc/vscode-extensions/wakatime/default.nix
index b1c7142c59176..336cd059f57a7 100644
--- a/pkgs/misc/vscode-extensions/wakatime/default.nix
+++ b/pkgs/misc/vscode-extensions/wakatime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , wakatime, vscode-utils }:
 
 let
@@ -17,7 +17,7 @@ in
       cp -rt wakatime-master --no-preserve=all ${wakatime}/lib/python*/site-packages/wakatime
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = ''
         Visual Studio Code plugin for automatic time tracking and metrics generated
         from your programming activity
diff --git a/pkgs/misc/xosd/default.nix b/pkgs/misc/xosd/default.nix
index 561f915d66360..3190cfb380d8e 100644
--- a/pkgs/misc/xosd/default.nix
+++ b/pkgs/misc/xosd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXext, libXt, xorgproto }:
+{ lib, stdenv, fetchurl, libX11, libXext, libXt, xorgproto }:
 
 stdenv.mkDerivation rec {
   pname = "xosd";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libX11 libXext libXt xorgproto ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Displays text on your screen";
     homepage = "https://sourceforge.net/projects/libxosd";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/darwin/apple-sdk/default.nix b/pkgs/os-specific/darwin/apple-sdk/default.nix
index 97523cf15a8d3..a768accdbcb8a 100644
--- a/pkgs/os-specific/darwin/apple-sdk/default.nix
+++ b/pkgs/os-specific/darwin/apple-sdk/default.nix
@@ -51,7 +51,7 @@ let
       popd
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Apple SDK ${version}";
       maintainers = with maintainers; [ copumpkin ];
       platforms   = platforms.darwin;
@@ -183,7 +183,7 @@ let
       "/System/Library/Frameworks/${name}.framework/${name}"
     ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Apple SDK framework ${name}";
       maintainers = with maintainers; [ copumpkin ];
       platforms   = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/CarbonHeaders/default.nix b/pkgs/os-specific/darwin/apple-source-releases/CarbonHeaders/default.nix
index 5c6d54aeb9c32..9afd4b475de5e 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/CarbonHeaders/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/CarbonHeaders/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation }:
+{ lib, stdenv, appleDerivation }:
 
 appleDerivation {
   dontBuild = true;
@@ -12,7 +12,7 @@ appleDerivation {
       --replace "CarbonCore/" ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ copumpkin ];
     platforms   = platforms.darwin;
     license     = licenses.apsl20;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/CommonCrypto/default.nix b/pkgs/os-specific/darwin/apple-source-releases/CommonCrypto/default.nix
index ad51f1df2bcdd..3e5399dbb3559 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/CommonCrypto/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/CommonCrypto/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation }:
+{ lib, stdenv, appleDerivation }:
 
 appleDerivation {
   installPhase = ''
@@ -6,7 +6,7 @@ appleDerivation {
     cp include/* $out/include/CommonCrypto
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ copumpkin ];
     platforms   = platforms.darwin;
     license     = licenses.apsl20;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/Csu/default.nix b/pkgs/os-specific/darwin/apple-source-releases/Csu/default.nix
index 7fd32a64fe575..2f6c8319b1cf6 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/Csu/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/Csu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation }:
+{ lib, stdenv, appleDerivation }:
 
 appleDerivation {
   prePatch = ''
@@ -18,7 +18,7 @@ appleDerivation {
 
   installFlags = [ "DSTROOT=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Apple's common startup stubs for darwin";
     maintainers = with maintainers; [ copumpkin ];
     platforms   = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/IOKit/default.nix b/pkgs/os-specific/darwin/apple-source-releases/IOKit/default.nix
index a945409ed7a04..976b977e60230 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/IOKit/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/IOKit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation, IOKitSrcs, xnu, darwin-stubs }:
+{ lib, stdenv, appleDerivation, IOKitSrcs, xnu, darwin-stubs }:
 
 # Someday it'll make sense to split these out into their own packages, but today is not that day.
 appleDerivation {
@@ -182,7 +182,7 @@ appleDerivation {
     # video: missing altogether
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ joelteon copumpkin ];
     platforms   = platforms.darwin;
     license     = licenses.apsl20;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/Librpcsvc/default.nix b/pkgs/os-specific/darwin/apple-source-releases/Librpcsvc/default.nix
index a7b2bd7d981d7..7f93a87837a2e 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/Librpcsvc/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/Librpcsvc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation, developer_cmds }:
+{ lib, stdenv, appleDerivation, developer_cmds }:
 
 appleDerivation {
   buildInputs = [ developer_cmds ];
@@ -14,7 +14,7 @@ appleDerivation {
     rmdir $out/usr/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ matthewbauer ];
     platforms   = platforms.darwin;
     license     = licenses.apsl20;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix b/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix
index 24526f05f0629..a5508b5ec12fd 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/Libsystem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation, cpio, xnu, Libc, Libm, libdispatch, cctools, Libinfo
+{ lib, stdenv, appleDerivation, cpio, xnu, Libc, Libm, libdispatch, cctools, Libinfo
 , dyld, Csu, architecture, libclosure, CarbonHeaders, ncurses, CommonCrypto
 , copyfile, removefile, libresolv, Libnotify, libplatform, libpthread
 , mDNSResponder, launchd, libutil, hfs, darling, darwin-stubs }:
@@ -115,7 +115,7 @@ appleDerivation {
     ln -s libresolv.9.dylib $out/lib/libresolv.dylib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Mac OS libc/libSystem (tapi library with pure headers)";
     maintainers = with maintainers; [ copumpkin gridaphobe ];
     platforms   = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix b/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix
index ebeb3ef08845f..f7503dbb953c7 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/architecture/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation }:
+{ lib, stdenv, appleDerivation }:
 
 appleDerivation {
   dontBuild = true;
@@ -13,7 +13,7 @@ appleDerivation {
 
   DSTROOT = "$(out)";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ copumpkin ];
     platforms   = platforms.darwin;
     license     = licenses.apsl20;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/dyld/default.nix b/pkgs/os-specific/darwin/apple-source-releases/dyld/default.nix
index ddadf1f3940b8..4a72ea337ebfb 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/dyld/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/dyld/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation }:
+{ lib, stdenv, appleDerivation }:
 
 appleDerivation {
   installPhase = ''
@@ -7,7 +7,7 @@ appleDerivation {
     cp -r include $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Impure primitive symlinks to the Mac OS native dyld, along with headers";
     maintainers = with maintainers; [ copumpkin ];
     platforms   = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/apple-source-releases/libunwind/default.nix b/pkgs/os-specific/darwin/apple-source-releases/libunwind/default.nix
index bd219ae434c04..24986e288524b 100644
--- a/pkgs/os-specific/darwin/apple-source-releases/libunwind/default.nix
+++ b/pkgs/os-specific/darwin/apple-source-releases/libunwind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, appleDerivation }:
+{ lib, stdenv, appleDerivation }:
 
 appleDerivation {
   buildPhase = ":";
@@ -9,7 +9,7 @@ appleDerivation {
     cp -R include $out/include
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ copumpkin lnl7 ];
     platforms   = platforms.darwin;
     license     = licenses.apsl20;
diff --git a/pkgs/os-specific/darwin/chunkwm/default.nix b/pkgs/os-specific/darwin/chunkwm/default.nix
index d94f66969f461..b326b98de539c 100644
--- a/pkgs/os-specific/darwin/chunkwm/default.nix
+++ b/pkgs/os-specific/darwin/chunkwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, Carbon, Cocoa, ScriptingBridge }:
+{ lib, stdenv, fetchzip, Carbon, Cocoa, ScriptingBridge }:
 
 stdenv.mkDerivation rec {
   pname = "chunkwm";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     cp plugins/*.so $out/lib/chunkwm/plugins
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiling window manager for macOS based on plugin architecture";
     homepage = "https://github.com/koekeishiya/chunkwm";
     platforms = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/goku/default.nix b/pkgs/os-specific/darwin/goku/default.nix
index f6834fca7351e..b65547ff32fbd 100644
--- a/pkgs/os-specific/darwin/goku/default.nix
+++ b/pkgs/os-specific/darwin/goku/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl }:
+{lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "goku";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp gokuw $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Karabiner configurator";
     homepage = "https://github.com/yqrashawn/GokuRakuJoudo";
     license = licenses.gpl3;
diff --git a/pkgs/os-specific/darwin/iproute2mac/default.nix b/pkgs/os-specific/darwin/iproute2mac/default.nix
index edf1583de9a84..915ef7c915889 100644
--- a/pkgs/os-specific/darwin/iproute2mac/default.nix
+++ b/pkgs/os-specific/darwin/iproute2mac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, darwin, python2 }:
+{ lib, stdenv, fetchFromGitHub, darwin, python2 }:
 
 stdenv.mkDerivation rec {
   version = "1.2.1";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     install -D -m 755 src/ip.py $out/bin/ip
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/brona/iproute2mac";
     description = "CLI wrapper for basic network utilites on Mac OS X inspired with iproute2 on Linux systems - ip command.";
     license = licenses.mit;
diff --git a/pkgs/os-specific/darwin/khd/default.nix b/pkgs/os-specific/darwin/khd/default.nix
index b09b65f33d567..87e1a8bf6ae6e 100644
--- a/pkgs/os-specific/darwin/khd/default.nix
+++ b/pkgs/os-specific/darwin/khd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, Carbon, Cocoa }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, Carbon, Cocoa }:
 
 stdenv.mkDerivation rec {
   pname = "khd";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/Library/LaunchDaemons/org.nixos.khd.plist --subst-var out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple modal hotkey daemon for OSX";
     homepage = "https://github.com/koekeishiya/khd";
     downloadPage = "https://github.com/koekeishiya/khd/releases";
diff --git a/pkgs/os-specific/darwin/kwm/default.nix b/pkgs/os-specific/darwin/kwm/default.nix
index 8c412aa68ed78..273ea7345d9da 100644
--- a/pkgs/os-specific/darwin/kwm/default.nix
+++ b/pkgs/os-specific/darwin/kwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "kwm";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/Library/LaunchDaemons/org.nixos.kwm.plist --subst-var out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiling window manager with focus follows mouse for OSX";
     homepage = "https://github.com/koekeishiya/kwm";
     downloadPage = "https://github.com/koekeishiya/kwm/releases";
diff --git a/pkgs/os-specific/darwin/m-cli/default.nix b/pkgs/os-specific/darwin/m-cli/default.nix
index 2699bb8e1408b..b69849d82453e 100644
--- a/pkgs/os-specific/darwin/m-cli/default.nix
+++ b/pkgs/os-specific/darwin/m-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "m-cli";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     install -Dt "$out/share/zsh/site-functions/" -m444 completion/zsh/_m
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Swiss Army Knife for macOS";
     inherit (src.meta) homepage;
     repositories.git = "git://github.com/rgcr/m-cli.git";
diff --git a/pkgs/os-specific/darwin/noah/default.nix b/pkgs/os-specific/darwin/noah/default.nix
index 81f4ab2bd9e9b..f4d8a4b21a87a 100644
--- a/pkgs/os-specific/darwin/noah/default.nix
+++ b/pkgs/os-specific/darwin/noah/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, Hypervisor }:
+{ lib, stdenv, fetchFromGitHub, cmake, Hypervisor }:
 
 stdenv.mkDerivation rec {
   pname = "noah";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ Hypervisor ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bash on Ubuntu on macOS";
     homepage = "https://github.com/linux-noah/noah";
     license = [ licenses.mit licenses.gpl2 ];
diff --git a/pkgs/os-specific/darwin/osx-cpu-temp/default.nix b/pkgs/os-specific/darwin/osx-cpu-temp/default.nix
index 1e8a56154f34a..ea9d8399667ac 100644
--- a/pkgs/os-specific/darwin/osx-cpu-temp/default.nix
+++ b/pkgs/os-specific/darwin/osx-cpu-temp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , IOKit
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp osx-cpu-temp $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Outputs current CPU temperature for OSX.";
     homepage = "https://github.com/lavoiesl/osx-cpu-temp";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/darwin/osxfuse/default.nix b/pkgs/os-specific/darwin/osxfuse/default.nix
index e13a084201201..d0f6b0f53117b 100644
--- a/pkgs/os-specific/darwin/osxfuse/default.nix
+++ b/pkgs/os-specific/darwin/osxfuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, runCommand, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, runCommand, fetchFromGitHub, autoreconfHook }:
 
 let
   version = "3.8.3";
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ headers ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://osxfuse.github.io";
     description = "C-based FUSE for macOS SDK";
     platforms = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/qes/default.nix b/pkgs/os-specific/darwin/qes/default.nix
index f231ee5716778..dce6e52662601 100644
--- a/pkgs/os-specific/darwin/qes/default.nix
+++ b/pkgs/os-specific/darwin/qes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, Carbon }:
+{ lib, stdenv, fetchFromGitHub, Carbon }:
 
 stdenv.mkDerivation {
   pname = "qes";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "BUILD_PATH=$(out)/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quartz Event Synthesizer";
     homepage = "https://github.com/koekeishiya/qes";
     platforms = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/reattach-to-user-namespace/default.nix b/pkgs/os-specific/darwin/reattach-to-user-namespace/default.nix
index 685837768504a..dedc757895101 100644
--- a/pkgs/os-specific/darwin/reattach-to-user-namespace/default.nix
+++ b/pkgs/os-specific/darwin/reattach-to-user-namespace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "reattach-to-user-namespace";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp reattach-to-user-namespace $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A wrapper that provides access to the Mac OS X pasteboard service";
     license = licenses.bsd2;
     maintainers = with maintainers; [ lnl7 ];
diff --git a/pkgs/os-specific/darwin/skhd/default.nix b/pkgs/os-specific/darwin/skhd/default.nix
index d145c0d75d097..ad33cf713d0c6 100644
--- a/pkgs/os-specific/darwin/skhd/default.nix
+++ b/pkgs/os-specific/darwin/skhd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, Carbon }:
+{ lib, stdenv, fetchFromGitHub, Carbon }:
 
 stdenv.mkDerivation rec {
   pname = "skhd";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/Library/LaunchDaemons/org.nixos.skhd.plist --subst-var out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple hotkey daemon for macOS";
     homepage = "https://github.com/koekeishiya/skhd";
     platforms = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/spacebar/default.nix b/pkgs/os-specific/darwin/spacebar/default.nix
index 6d47499b83503..780347c60c584 100644
--- a/pkgs/os-specific/darwin/spacebar/default.nix
+++ b/pkgs/os-specific/darwin/spacebar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, Carbon, Cocoa, ScriptingBridge }:
+{ lib, stdenv, fetchFromGitHub, Carbon, Cocoa, ScriptingBridge }:
 
 stdenv.mkDerivation rec {
   pname = "spacebar";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp ./doc/spacebar.1 $out/share/man/man1/spacebar.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal status bar for macOS";
     homepage = "https://github.com/cmacrae/spacebar";
     platforms = platforms.darwin;
diff --git a/pkgs/os-specific/darwin/xcode/default.nix b/pkgs/os-specific/darwin/xcode/default.nix
index 34e3b2dfeeae2..851110f7b65ad 100644
--- a/pkgs/os-specific/darwin/xcode/default.nix
+++ b/pkgs/os-specific/darwin/xcode/default.nix
@@ -31,7 +31,7 @@ let requireXcode = version: sha256:
         rm -rf Xcode.app
       '';
     };
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://developer.apple.com/downloads/";
       description = "Apple's XCode SDK";
       license = licenses.unfree;
diff --git a/pkgs/os-specific/darwin/yabai/default.nix b/pkgs/os-specific/darwin/yabai/default.nix
index d4471da4781f3..b371e97d06fc3 100644
--- a/pkgs/os-specific/darwin/yabai/default.nix
+++ b/pkgs/os-specific/darwin/yabai/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, Carbon, Cocoa, ScriptingBridge, xxd }:
+{ lib, stdenv, fetchFromGitHub, Carbon, Cocoa, ScriptingBridge, xxd }:
 
 stdenv.mkDerivation rec {
   pname = "yabai";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp ./doc/yabai.1 $out/share/man/man1/yabai.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A tiling window manager for macOS based on binary space partitioning
     '';
diff --git a/pkgs/os-specific/linux/915resolution/default.nix b/pkgs/os-specific/linux/915resolution/default.nix
index 906ea04293fe4..57f8ba0d33b32 100644
--- a/pkgs/os-specific/linux/915resolution/default.nix
+++ b/pkgs/os-specific/linux/915resolution/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   name = "915resolution-0.5.3";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   patchPhase = "rm *.o";
   installPhase = "mkdir -p $out/sbin; cp 915resolution $out/sbin/";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://915resolution.mango-lang.org/";
     description = "A tool to modify Intel 800/900 video BIOS";
     platforms = [ "i686-linux" "x86_64-linux" ];
diff --git a/pkgs/os-specific/linux/acpi-call/default.nix b/pkgs/os-specific/linux/acpi-call/default.nix
index bb3aef885a7c1..87535b92e4659 100644
--- a/pkgs/os-specific/linux/acpi-call/default.nix
+++ b/pkgs/os-specific/linux/acpi-call/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 stdenv.mkDerivation rec {
   pname = "acpi-call";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     install -D -m755 examples/turn_off_gpu.sh $out/bin/test_discrete_video_off.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = with maintainers; [ raskin mic92 ];
     inherit (src.meta) homepage;
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/acpi/default.nix b/pkgs/os-specific/linux/acpi/default.nix
index 69a36d7bf52b0..127d0c4b02231 100644
--- a/pkgs/os-specific/linux/acpi/default.nix
+++ b/pkgs/os-specific/linux/acpi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "acpi";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "01ahldvf0gc29dmbd5zi4rrnrw2i1ajnf30sx2vyaski3jv099fp";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Show battery status and other ACPI information";
     longDescription = ''
       Linux ACPI client is a small command-line
diff --git a/pkgs/os-specific/linux/acpid/default.nix b/pkgs/os-specific/linux/acpid/default.nix
index 5ef5e2724b23e..d28ff447681ed 100644
--- a/pkgs/os-specific/linux/acpid/default.nix
+++ b/pkgs/os-specific/linux/acpid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook }:
+{ lib, stdenv, fetchurl, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   name = "acpid-2.0.32";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       --replace "strrchr strtol" "strrchr strtol malloc realloc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/acpid2/";
     description = "A daemon for delivering ACPI events to userspace programs";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/alsa-lib/default.nix b/pkgs/os-specific/linux/alsa-lib/default.nix
index b1d85f2674cbf..30bb669cf4ce2 100644
--- a/pkgs/os-specific/linux/alsa-lib/default.nix
+++ b/pkgs/os-specific/linux/alsa-lib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsa-ucm-conf, alsa-topology-conf }:
+{ lib, stdenv, fetchurl, alsa-ucm-conf, alsa-topology-conf }:
 
 stdenv.mkDerivation rec {
   pname = "alsa-lib";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "dev" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.alsa-project.org/";
     description = "ALSA, the Advanced Linux Sound Architecture libraries";
 
diff --git a/pkgs/os-specific/linux/alsa-oss/default.nix b/pkgs/os-specific/linux/alsa-oss/default.nix
index 774dc3d8d6767..9c87dbe8e8c8b 100644
--- a/pkgs/os-specific/linux/alsa-oss/default.nix
+++ b/pkgs/os-specific/linux/alsa-oss/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, alsaLib, gettext, ncurses, libsamplerate}:
+{lib, stdenv, fetchurl, alsaLib, gettext, ncurses, libsamplerate}:
 
 stdenv.mkDerivation rec {
   pname = "alsa-oss";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "ASOUND_STATE_DIR=$(TMPDIR)/dummy" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.alsa-project.org/";
     description = "ALSA, the Advanced Linux Sound Architecture alsa-oss emulation";
 
diff --git a/pkgs/os-specific/linux/alsa-tools/default.nix b/pkgs/os-specific/linux/alsa-tools/default.nix
index 2fef5e07c63cd..4feb99f6bef91 100644
--- a/pkgs/os-specific/linux/alsa-tools/default.nix
+++ b/pkgs/os-specific/linux/alsa-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, pkgconfig, gtk2, gtk3, fltk13 }:
+{ lib, stdenv, fetchurl, alsaLib, pkgconfig, gtk2, gtk3, fltk13 }:
 # Comes from upstream as as bundle of several tools,
 # some use gtk2, some gtk3 (and some even fltk13).
 
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.alsa-project.org/";
     description = "ALSA, the Advanced Linux Sound Architecture tools";
 
diff --git a/pkgs/os-specific/linux/alsa-topology-conf/default.nix b/pkgs/os-specific/linux/alsa-topology-conf/default.nix
index 4b6678d09b23a..2328fea91fd7a 100644
--- a/pkgs/os-specific/linux/alsa-topology-conf/default.nix
+++ b/pkgs/os-specific/linux/alsa-topology-conf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "alsa-topology-conf-${version}";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.alsa-project.org/";
     description = "ALSA topology configuration files";
 
diff --git a/pkgs/os-specific/linux/alsa-ucm-conf/default.nix b/pkgs/os-specific/linux/alsa-ucm-conf/default.nix
index 3ee800438175e..d667cd3d51bb4 100644
--- a/pkgs/os-specific/linux/alsa-ucm-conf/default.nix
+++ b/pkgs/os-specific/linux/alsa-ucm-conf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "alsa-ucm-conf-${version}";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.alsa-project.org/";
     description = "ALSA Use Case Manager configuration";
 
diff --git a/pkgs/os-specific/linux/alsa-utils/default.nix b/pkgs/os-specific/linux/alsa-utils/default.nix
index 055927b7a31e0..40db2261007e3 100644
--- a/pkgs/os-specific/linux/alsa-utils/default.nix
+++ b/pkgs/os-specific/linux/alsa-utils/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, alsaLib, gettext, makeWrapper, ncurses, libsamplerate, pciutils, which, fftw}:
+{lib, stdenv, fetchurl, alsaLib, gettext, makeWrapper, ncurses, libsamplerate, pciutils, which, fftw}:
 
 stdenv.mkDerivation rec {
   pname = "alsa-utils";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/alsa-info.sh --prefix PATH : "${stdenv.lib.makeBinPath [ which pciutils ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.alsa-project.org/";
     description = "ALSA, the Advanced Linux Sound Architecture utils";
     longDescription = ''
diff --git a/pkgs/os-specific/linux/amdgpu-pro/default.nix b/pkgs/os-specific/linux/amdgpu-pro/default.nix
index 32763fcded51a..78d0748ed3b02 100644
--- a/pkgs/os-specific/linux/amdgpu-pro/default.nix
+++ b/pkgs/os-specific/linux/amdgpu-pro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, elfutils
+{ lib, stdenv, fetchurl, elfutils
 , xorg, patchelf, openssl, libdrm, udev
 , libxcb, libxshmfence, epoxy, perl, zlib
 , ncurses
@@ -171,7 +171,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AMDGPU-PRO drivers";
     homepage =  "http://support.amd.com/en-us/kb-articles/Pages/AMDGPU-PRO-Beta-Driver-for-Vulkan-Release-Notes.aspx";
     license = licenses.unfree;
diff --git a/pkgs/os-specific/linux/anbox/default.nix b/pkgs/os-specific/linux/anbox/default.nix
index cf51681a1531d..cfbdb37697755 100644
--- a/pkgs/os-specific/linux/anbox/default.nix
+++ b/pkgs/os-specific/linux/anbox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl
+{ lib, stdenv, fetchFromGitHub, fetchurl
 , cmake, pkg-config, dbus, makeWrapper
 , boost
 , elfutils # for libdw
@@ -148,7 +148,7 @@ stdenv.mkDerivation rec {
       };
     }.${stdenv.system} or null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://anbox.io";
     description = "Android in a box";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/anbox/kmod.nix b/pkgs/os-specific/linux/anbox/kmod.nix
index 896beaf3056ec..f62e6ee6aa53e 100644
--- a/pkgs/os-specific/linux/anbox/kmod.nix
+++ b/pkgs/os-specific/linux/anbox/kmod.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel, fetchFromGitHub }:
+{ lib, stdenv, kernel, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "anbox-modules";
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Anbox ashmem and binder drivers.";
     homepage = "https://github.com/anbox/anbox-modules";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/android-udev-rules/default.nix b/pkgs/os-specific/linux/android-udev-rules/default.nix
index b6fe86d1b26a9..3d69f5ce0e59b 100644
--- a/pkgs/os-specific/linux/android-udev-rules/default.nix
+++ b/pkgs/os-specific/linux/android-udev-rules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 ## Usage
 # In NixOS, simply add this package to services.udev.packages:
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D 51-android.rules $out/lib/udev/rules.d/51-android.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/M0Rf30/android-udev-rules";
     description = "Android udev rules list aimed to be the most comprehensive on the net";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/asus-wmi-sensors/default.nix b/pkgs/os-specific/linux/asus-wmi-sensors/default.nix
index 8eb8a7484e157..3098cbb72538e 100644
--- a/pkgs/os-specific/linux/asus-wmi-sensors/default.nix
+++ b/pkgs/os-specific/linux/asus-wmi-sensors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 stdenv.mkDerivation rec {
   name = "asus-wmi-sensors-${version}-${kernel.version}";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "MODDESTDIR=${placeholder "out"}/lib/modules/${kernel.modDirVersion}/kernel/drivers/hwmon"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux HWMON (lmsensors) sensors driver for various ASUS Ryzen and Threadripper motherboards";
     homepage = "https://github.com/electrified/asus-wmi-sensors";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/ati-drivers/default.nix b/pkgs/os-specific/linux/ati-drivers/default.nix
index 63f9b5399da9b..f4378cad816c6 100644
--- a/pkgs/os-specific/linux/ati-drivers/default.nix
+++ b/pkgs/os-specific/linux/ati-drivers/default.nix
@@ -126,7 +126,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ATI Catalyst display drivers";
     homepage = "http://support.amd.com/us/gpudownload/Pages/index.aspx";
     license = licenses.unfree;
diff --git a/pkgs/os-specific/linux/atop/default.nix b/pkgs/os-specific/linux/atop/default.nix
index 7557497b959e5..f3df61c15108f 100644
--- a/pkgs/os-specific/linux/atop/default.nix
+++ b/pkgs/os-specific/linux/atop/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, zlib, ncurses}:
+{lib, stdenv, fetchurl, zlib, ncurses}:
 
 stdenv.mkDerivation rec {
   pname = "atop";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out"/{bin,sbin}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     maintainers = with maintainers; [ raskin ];
     description = ''Console system performance monitor'';
diff --git a/pkgs/os-specific/linux/bbswitch/default.nix b/pkgs/os-specific/linux/bbswitch/default.nix
index 67cbc6e5c5e62..837906fb55498 100644
--- a/pkgs/os-specific/linux/bbswitch/default.nix
+++ b/pkgs/os-specific/linux/bbswitch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, kernel, runtimeShell }:
+{ lib, stdenv, fetchurl, fetchpatch, kernel, runtimeShell }:
 
 let
   baseName = "bbswitch";
@@ -54,7 +54,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/discrete_vga_poweroff $out/bin/discrete_vga_poweron
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A module for powering off hybrid GPUs";
     platforms = [ "x86_64-linux" "i686-linux" ];
     homepage = "https://github.com/Bumblebee-Project/bbswitch";
diff --git a/pkgs/os-specific/linux/bcc/default.nix b/pkgs/os-specific/linux/bcc/default.nix
index 2bc705d4487a0..5338562b7e71b 100644
--- a/pkgs/os-specific/linux/bcc/default.nix
+++ b/pkgs/os-specific/linux/bcc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch
+{ lib, stdenv, fetchurl, fetchpatch
 , makeWrapper, cmake, llvmPackages, kernel
 , flex, bison, elfutils, python, luajit, netperf, iperf, libelf
 , systemtap, bash
@@ -68,7 +68,7 @@ python.pkgs.buildPythonApplication rec {
     wrapPythonProgramsIn "$out/share/bcc/tools" "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynamic Tracing Tools for Linux";
     homepage    = "https://iovisor.github.io/bcc/";
     license     = licenses.asl20;
diff --git a/pkgs/os-specific/linux/bluez/default.nix b/pkgs/os-specific/linux/bluez/default.nix
index 8e110fb13aceb..be7435fb1d0f4 100644
--- a/pkgs/os-specific/linux/bluez/default.nix
+++ b/pkgs/os-specific/linux/bluez/default.nix
@@ -112,7 +112,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bluetooth support for Linux";
     homepage = "http://www.bluez.org/";
     license = with licenses; [ gpl2 lgpl21 ];
diff --git a/pkgs/os-specific/linux/bolt/default.nix b/pkgs/os-specific/linux/bolt/default.nix
index 1508125695e77..d857fa1463a9f 100644
--- a/pkgs/os-specific/linux/bolt/default.nix
+++ b/pkgs/os-specific/linux/bolt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , meson
 , ninja
 , pkgconfig
@@ -85,7 +85,7 @@ stdenv.mkDerivation rec {
   PKG_CONFIG_SYSTEMD_SYSTEMDSYSTEMUNITDIR = "${placeholder "out"}/lib/systemd/system";
   PKG_CONFIG_UDEV_UDEVDIR = "${placeholder "out"}/lib/udev";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Thunderbolt 3 device management daemon";
     homepage = "https://gitlab.freedesktop.org/bolt/bolt";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/os-specific/linux/bpftool/default.nix b/pkgs/os-specific/linux/bpftool/default.nix
index 34ddcc3a213f8..d8c64738d829a 100644
--- a/pkgs/os-specific/linux/bpftool/default.nix
+++ b/pkgs/os-specific/linux/bpftool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , libopcodes, libbfd, libelf
 , linuxPackages_latest, zlib
 , python3
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
       --replace '/sbin'      '/bin'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Debugging/program analysis tool for the eBPF subsystem";
     license     = [ licenses.gpl2 licenses.bsd2 ];
     platforms   = platforms.linux;
diff --git a/pkgs/os-specific/linux/bpftrace/default.nix b/pkgs/os-specific/linux/bpftrace/default.nix
index f4e01f75d52e3..ce890ec578b5c 100644
--- a/pkgs/os-specific/linux/bpftrace/default.nix
+++ b/pkgs/os-specific/linux/bpftrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, pkgconfig, flex, bison
 , llvmPackages, kernel, elfutils
 , libelf, libbfd, libbpf, libopcodes, bcc
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-level tracing language for Linux eBPF";
     homepage    = "https://github.com/iovisor/bpftrace";
     license     = licenses.asl20;
diff --git a/pkgs/os-specific/linux/brillo/default.nix b/pkgs/os-specific/linux/brillo/default.nix
index 5baaa0752aa68..0736a13ce12e8 100644
--- a/pkgs/os-specific/linux/brillo/default.nix
+++ b/pkgs/os-specific/linux/brillo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab , go-md2man, coreutils, substituteAll }:
+{ lib, stdenv, fetchFromGitLab , go-md2man, coreutils, substituteAll }:
 
 stdenv.mkDerivation rec {
   pname = "brillo";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   installTargets = [ "install-dist" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Backlight and Keyboard LED control tool";
     homepage = "https://gitlab.com/cameronnemo/brillo";
     license = [ licenses.gpl3 licenses.bsd0 ];
diff --git a/pkgs/os-specific/linux/btfs/default.nix b/pkgs/os-specific/linux/btfs/default.nix
index 6d919ce57d4f0..8aa1bf4889226 100644
--- a/pkgs/os-specific/linux/btfs/default.nix
+++ b/pkgs/os-specific/linux/btfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , python3, boost, fuse, libtorrent-rasterbar, curl }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     boost fuse libtorrent-rasterbar curl python3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A bittorrent filesystem based on FUSE";
     homepage    = "https://github.com/johang/btfs";
     license     = licenses.gpl3;
diff --git a/pkgs/os-specific/linux/busybox/default.nix b/pkgs/os-specific/linux/busybox/default.nix
index c157c492043c5..49b07bd18e7ee 100644
--- a/pkgs/os-specific/linux/busybox/default.nix
+++ b/pkgs/os-specific/linux/busybox/default.nix
@@ -129,7 +129,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false; # tries to access the net
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiny versions of common UNIX utilities in a single small executable";
     homepage = "https://busybox.net/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/cachefilesd/default.nix b/pkgs/os-specific/linux/cachefilesd/default.nix
index 27fd8c9613ac3..6c52eb4a7f600 100644
--- a/pkgs/os-specific/linux/cachefilesd/default.nix
+++ b/pkgs/os-specific/linux/cachefilesd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "cachefilesd";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     "MANDIR=$(out)/share/man"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Local network file caching management daemon";
     homepage = "https://people.redhat.com/dhowells/fscache/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/can-isotp/default.nix b/pkgs/os-specific/linux/can-isotp/default.nix
index cccc7550fba86..89857a35d9214 100644
--- a/pkgs/os-specific/linux/can-isotp/default.nix
+++ b/pkgs/os-specific/linux/can-isotp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel, fetchFromGitHub }:
+{ lib, stdenv, kernel, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "can-isotp";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
 
   nativeBuildInputs = kernel.moduleBuildDependencies;
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kernel module for ISO-TP (ISO 15765-2)";
     homepage = "https://github.com/hartkopp/can-isotp";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/can-utils/default.nix b/pkgs/os-specific/linux/can-utils/default.nix
index 2b6b82591b594..90261e8290488 100644
--- a/pkgs/os-specific/linux/can-utils/default.nix
+++ b/pkgs/os-specific/linux/can-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "can-utils";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
 
   preConfigure = ''makeFlagsArray+=(PREFIX="$out")'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CAN userspace utilities and tools (for use with Linux SocketCAN)";
     homepage = "https://github.com/linux-can/can-utils";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/checksec/default.nix b/pkgs/os-specific/linux/checksec/default.nix
index eb33aedd1d49f..f5d4c44b05349 100644
--- a/pkgs/os-specific/linux/checksec/default.nix
+++ b/pkgs/os-specific/linux/checksec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, file, findutils
+{ lib, stdenv, fetchFromGitHub, makeWrapper, file, findutils
 , binutils-unwrapped, glibc, coreutils, sysctl, openssl
 }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${path}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for checking security bits on executables";
     homepage    = "http://www.trapkit.de/tools/checksec.html";
     license     = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/cifs-utils/default.nix b/pkgs/os-specific/linux/cifs-utils/default.nix
index 11544d9466626..3171c30987e2c 100644
--- a/pkgs/os-specific/linux/cifs-utils/default.nix
+++ b/pkgs/os-specific/linux/cifs-utils/default.nix
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "root_sbindir=$(out)/sbin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.samba.org/linux-cifs/cifs-utils/";
     description = "Tools for managing Linux CIFS client filesystems";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/compsize/default.nix b/pkgs/os-specific/linux/compsize/default.nix
index dd54df77c3485..e1979997d11be 100644
--- a/pkgs/os-specific/linux/compsize/default.nix
+++ b/pkgs/os-specific/linux/compsize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, btrfs-progs }:
+{ lib, stdenv, fetchFromGitHub, btrfs-progs }:
 
 stdenv.mkDerivation rec {
   pname = "compsize";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -m 0444 compsize.8 $out/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "btrfs: Find compression type/ratio on a file or set of files";
     homepage    = "https://github.com/kilobyte/compsize";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/conky/default.nix b/pkgs/os-specific/linux/conky/default.nix
index ee67140cd8614..fa3aa563fb154 100644
--- a/pkgs/os-specific/linux/conky/default.nix
+++ b/pkgs/os-specific/linux/conky/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv, fetchFromGitHub, pkgconfig, cmake
+{ config, lib, stdenv, fetchFromGitHub, pkgconfig, cmake
 
 # dependencies
 , glib, libXinerama
@@ -133,7 +133,7 @@ stdenv.mkDerivation rec {
   # src/conky.cc:137:23: fatal error: defconfig.h: No such file or directory
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://conky.sourceforge.net/";
     description = "Advanced, highly configurable system monitor based on torsmo";
     maintainers = [ maintainers.guibert ];
diff --git a/pkgs/os-specific/linux/conntrack-tools/default.nix b/pkgs/os-specific/linux/conntrack-tools/default.nix
index 43306e51166b0..c41f1410b01a8 100644
--- a/pkgs/os-specific/linux/conntrack-tools/default.nix
+++ b/pkgs/os-specific/linux/conntrack-tools/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, flex, bison, pkgconfig, libmnl, libnfnetlink
+{ fetchurl, lib, stdenv, flex, bison, pkgconfig, libmnl, libnfnetlink
 , libnetfilter_conntrack, libnetfilter_queue, libnetfilter_cttimeout
 , libnetfilter_cthelper, systemd
 , libtirpc
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   ];
   nativeBuildInputs = [ flex bison pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://conntrack-tools.netfilter.org/";
     description = "Connection tracking userspace tools";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/consoletools/default.nix b/pkgs/os-specific/linux/consoletools/default.nix
index 83de8f5ae1a50..8def013b956f4 100644
--- a/pkgs/os-specific/linux/consoletools/default.nix
+++ b/pkgs/os-specific/linux/consoletools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL }:
+{ lib, stdenv, fetchurl, SDL }:
 
 stdenv.mkDerivation rec {
   pname = "linuxconsoletools";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=\"\"" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/linuxconsole/";
     description = "A set of tools for joysticks and serial peripherals";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/cpufrequtils/default.nix b/pkgs/os-specific/linux/cpufrequtils/default.nix
index 4c0515e94b3b6..d099a62bc8104 100644
--- a/pkgs/os-specific/linux/cpufrequtils/default.nix
+++ b/pkgs/os-specific/linux/cpufrequtils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libtool, gettext }:
+{ lib, stdenv, fetchurl, libtool, gettext }:
 
 stdenv.mkDerivation rec {
   name = "cpufrequtils-008";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ stdenv.cc.libc.linuxHeaders libtool gettext ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools to display or change the CPU governor settings";
     homepage = "http://ftp.be.debian.org/pub/linux/utils/kernel/cpufreq/cpufrequtils.html";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/cpupower/default.nix b/pkgs/os-specific/linux/cpupower/default.nix
index b6ecaa11de28f..cdc76b6772e26 100644
--- a/pkgs/os-specific/linux/cpupower/default.nix
+++ b/pkgs/os-specific/linux/cpupower/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, kernel, pciutils, gettext }:
+{ lib, stdenv, buildPackages, kernel, pciutils, gettext }:
 
 stdenv.mkDerivation {
   pname = "cpupower";
@@ -35,7 +35,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to examine and tune power saving features";
     homepage = "https://www.kernel.org/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/cpuset/default.nix b/pkgs/os-specific/linux/cpuset/default.nix
index 9e775de62f585..d1a93e4247e9b 100644
--- a/pkgs/os-specific/linux/cpuset/default.nix
+++ b/pkgs/os-specific/linux/cpuset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , pythonPackages
@@ -35,7 +35,7 @@ pythonPackages.buildPythonApplication rec {
     make
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python application that forms a wrapper around the standard Linux filesystem calls to make using the cpusets facilities in the Linux kernel easier";
     homepage    = "https://github.com/lpechacek/cpuset";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/cramfsprogs/default.nix b/pkgs/os-specific/linux/cramfsprogs/default.nix
index 8633823ab5c5a..3f3e8a075b198 100644
--- a/pkgs/os-specific/linux/cramfsprogs/default.nix
+++ b/pkgs/os-specific/linux/cramfsprogs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , zlib
 }:
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools to create, check, and extract content of CramFs images";
     homepage = "https://packages.debian.org/jessie/cramfsprogs";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/cramfsswap/default.nix b/pkgs/os-specific/linux/cramfsswap/default.nix
index afb38364c4e61..f47482c1111f4 100644
--- a/pkgs/os-specific/linux/cramfsswap/default.nix
+++ b/pkgs/os-specific/linux/cramfsswap/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, zlib}:
+{lib, stdenv, fetchurl, zlib}:
 
 stdenv.mkDerivation rec {
   pname = "cramfsswap";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     install --target $out/bin -D cramfsswap
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Swap endianess of a cram filesystem (cramfs)";
     homepage = "https://packages.debian.org/sid/utils/cramfsswap";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/crda/default.nix b/pkgs/os-specific/linux/crda/default.nix
index 979b7cf1deb3e..a970451e0dd15 100644
--- a/pkgs/os-specific/linux/crda/default.nix
+++ b/pkgs/os-specific/linux/crda/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, libgcrypt, libnl, pkgconfig, python3Packages, wireless-regdb }:
+{ lib, stdenv, fetchurl, fetchpatch, libgcrypt, libnl, pkgconfig, python3Packages, wireless-regdb }:
 
 stdenv.mkDerivation rec {
   pname = "crda";
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     rm $out/include/reglib/keys-gcrypt.h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux wireless Central Regulatory Domain Agent";
     longDescription = ''
       CRDA acts as the udev helper for communication between the kernel and
diff --git a/pkgs/os-specific/linux/criu/default.nix b/pkgs/os-specific/linux/criu/default.nix
index abc11a4a5f067..3c46595ed87c3 100644
--- a/pkgs/os-specific/linux/criu/default.nix
+++ b/pkgs/os-specific/linux/criu/default.nix
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Userspace checkpoint/restore for Linux";
     homepage    = "https://criu.org";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/dbus-broker/default.nix b/pkgs/os-specific/linux/dbus-broker/default.nix
index d84676bcda6f2..74b35c50de594 100644
--- a/pkgs/os-specific/linux/dbus-broker/default.nix
+++ b/pkgs/os-specific/linux/dbus-broker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, docutils, meson, ninja, pkgconfig
+{ lib, stdenv, fetchFromGitHub, docutils, meson, ninja, pkgconfig
 , dbus, linuxHeaders, systemd }:
 
 stdenv.mkDerivation rec {
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux D-Bus Message Broker";
     homepage    = "https://github.com/bus1/dbus-broker/wiki";
     license     = licenses.asl20;
diff --git a/pkgs/os-specific/linux/ddcci/default.nix b/pkgs/os-specific/linux/ddcci/default.nix
index c977db64ee8ad..7e5f95cb20678 100644
--- a/pkgs/os-specific/linux/ddcci/default.nix
+++ b/pkgs/os-specific/linux/ddcci/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, kernel }:
+{ lib, stdenv, fetchFromGitLab, kernel }:
 
 stdenv.mkDerivation rec {
   pname = "ddcci-driver";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     "INCLUDEDIR=$(out)/include"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kernel module driver for DDC/CI monitors";
     homepage = "https://gitlab.com/ddcci-driver-linux/ddcci-driver-linux";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/devmem2/default.nix b/pkgs/os-specific/linux/devmem2/default.nix
index 9115601e35735..86f6f916cefc7 100644
--- a/pkgs/os-specific/linux/devmem2/default.nix
+++ b/pkgs/os-specific/linux/devmem2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "devmem2-2004-08-05";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     install -D devmem2 "$out/bin/devmem2"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple program to read/write from/to any location in memory";
     homepage = "http://lartmaker.nl/lartware/port/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/digimend/default.nix b/pkgs/os-specific/linux/digimend/default.nix
index 94f32d2c4329b..d0f02097587bf 100644
--- a/pkgs/os-specific/linux/digimend/default.nix
+++ b/pkgs/os-specific/linux/digimend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, kernel }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, kernel }:
 
 assert stdenv.lib.versionAtLeast kernel.version "3.5";
 
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     "DESTDIR=${placeholder "out"}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DIGImend graphics tablet drivers for the Linux kernel";
     homepage = "https://digimend.github.io/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/directvnc/default.nix b/pkgs/os-specific/linux/directvnc/default.nix
index c79371909152b..fad9559cc6387 100644
--- a/pkgs/os-specific/linux/directvnc/default.nix
+++ b/pkgs/os-specific/linux/directvnc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, directfb, zlib, libjpeg, xorgproto }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, directfb, zlib, libjpeg, xorgproto }:
 
 stdenv.mkDerivation {
   pname = "directvnc";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ directfb zlib libjpeg xorgproto ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DirectFB VNC client";
     homepage = "http://drinkmilk.github.io/directvnc/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/displaylink/default.nix b/pkgs/os-specific/linux/displaylink/default.nix
index 5e60d68bc2bbf..bd50852bd9d45 100644
--- a/pkgs/os-specific/linux/displaylink/default.nix
+++ b/pkgs/os-specific/linux/displaylink/default.nix
@@ -65,7 +65,7 @@ stdenv.mkDerivation rec {
   dontPatchELF = true;
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DisplayLink DL-5xxx, DL-41xx and DL-3x00 Driver for Linux";
     maintainers = with maintainers; [ nshalman abbradar peterhoeg eyjhb ];
     platforms = [ "x86_64-linux" "i686-linux" ];
diff --git a/pkgs/os-specific/linux/dmidecode/default.nix b/pkgs/os-specific/linux/dmidecode/default.nix
index 7d0990d9f81ac..a4e09492debd2 100644
--- a/pkgs/os-specific/linux/dmidecode/default.nix
+++ b/pkgs/os-specific/linux/dmidecode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch }:
+{ lib, stdenv, fetchurl, fetchpatch }:
 
 stdenv.mkDerivation rec {
   name = "dmidecode-3.2";
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.nongnu.org/dmidecode/";
     description = "A tool that reads information about your system's hardware from the BIOS according to the SMBIOS/DMI standard";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/dmtcp/default.nix b/pkgs/os-specific/linux/dmtcp/default.nix
index 0f7f2f9817a51..21458daf966fc 100644
--- a/pkgs/os-specific/linux/dmtcp/default.nix
+++ b/pkgs/os-specific/linux/dmtcp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bash, perl, python }:
+{ lib, stdenv, fetchFromGitHub, bash, perl, python }:
 
 stdenv.mkDerivation rec {
   pname = "dmtcp";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
       --replace "os.getenv('USER')" "\"nixbld1\""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Distributed MultiThreaded Checkpointing";
     longDescription = ''
       DMTCP (Distributed MultiThreaded Checkpointing) is a tool to
diff --git a/pkgs/os-specific/linux/drbd/default.nix b/pkgs/os-specific/linux/drbd/default.nix
index bbf2535ce3d6d..ae3e986e14afa 100644
--- a/pkgs/os-specific/linux/drbd/default.nix
+++ b/pkgs/os-specific/linux/drbd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, flex, systemd, perl }:
+{ lib, stdenv, fetchurl, flex, systemd, perl }:
 
 stdenv.mkDerivation rec {
   name = "drbd-8.4.4";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     "INITDIR=$(out)/etc/init.d"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.drbd.org/";
     description = "Distributed Replicated Block Device, a distributed storage system for Linux";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/dropwatch/default.nix b/pkgs/os-specific/linux/dropwatch/default.nix
index 69acfa9682b6a..915d79aabac57 100644
--- a/pkgs/os-specific/linux/dropwatch/default.nix
+++ b/pkgs/os-specific/linux/dropwatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , libnl, readline, libbfd, ncurses, zlib }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux kernel dropped packet monitor";
     homepage = "https://github.com/nhorman/dropwatch";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/dstat/default.nix b/pkgs/os-specific/linux/dstat/default.nix
index 6d2d8eb75b00b..7d0b87609b367 100644
--- a/pkgs/os-specific/linux/dstat/default.nix
+++ b/pkgs/os-specific/linux/dstat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python2Packages }:
+{ lib, stdenv, fetchurl, python2Packages }:
 
 python2Packages.buildPythonApplication rec {
   pname = "dstat";
@@ -16,7 +16,7 @@ python2Packages.buildPythonApplication rec {
 
   makeFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://dag.wieers.com/home-made/dstat/";
     description = "Versatile resource statistics tool";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/earlyoom/default.nix b/pkgs/os-specific/linux/earlyoom/default.nix
index 1eecacad60c0a..668a3795b993f 100644
--- a/pkgs/os-specific/linux/earlyoom/default.nix
+++ b/pkgs/os-specific/linux/earlyoom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pandoc, installShellFiles, withManpage ? false }:
+{ lib, stdenv, fetchFromGitHub, pandoc, installShellFiles, withManpage ? false }:
 
 stdenv.mkDerivation rec {
   pname = "earlyoom";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     installManPage earlyoom.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Early OOM Daemon for Linux";
     homepage = "https://github.com/rfjakob/earlyoom";
     license = licenses.mit;
diff --git a/pkgs/os-specific/linux/ebtables/default.nix b/pkgs/os-specific/linux/ebtables/default.nix
index d3705195f599b..2045c4b112c8f 100644
--- a/pkgs/os-specific/linux/ebtables/default.nix
+++ b/pkgs/os-specific/linux/ebtables/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "ebtables";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   preInstall = "mkdir -p $out/etc/sysconfig";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A filtering tool for Linux-based bridging firewalls";
     homepage = "http://ebtables.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/edac-utils/default.nix b/pkgs/os-specific/linux/edac-utils/default.nix
index fb0a6dbf62ecd..9b8b998127421 100644
--- a/pkgs/os-specific/linux/edac-utils/default.nix
+++ b/pkgs/os-specific/linux/edac-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl, makeWrapper
+{ lib, stdenv, fetchFromGitHub, perl, makeWrapper
 , sysfsutils, dmidecode, kmod }:
 
 stdenv.mkDerivation {
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
       --set PATH ${stdenv.lib.makeBinPath [ dmidecode kmod ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/grondo/edac-utils";
     description = "Handles the reporting of hardware-related memory errors";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/ell/default.nix b/pkgs/os-specific/linux/ell/default.nix
index c6aed21cd8e81..183c82f467a5d 100644
--- a/pkgs/os-specific/linux/ell/default.nix
+++ b/pkgs/os-specific/linux/ell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , autoreconfHook
 , pkgconfig
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://01.org/ell";
     description = "Embedded Linux Library";
     longDescription = ''
diff --git a/pkgs/os-specific/linux/ena/default.nix b/pkgs/os-specific/linux/ena/default.nix
index 2f06e99b3e136..dc17f7f169655 100644
--- a/pkgs/os-specific/linux/ena/default.nix
+++ b/pkgs/os-specific/linux/ena/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 stdenv.mkDerivation rec {
   version = "2.3.0";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     xz $dest/ena.ko
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Amazon Elastic Network Adapter (ENA) driver for Linux";
     homepage = "https://github.com/amzn/amzn-drivers";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/erofs-utils/default.nix b/pkgs/os-specific/linux/erofs-utils/default.nix
index 21ad77f234a9b..ffa39dc58028b 100644
--- a/pkgs/os-specific/linux/erofs-utils/default.nix
+++ b/pkgs/os-specific/linux/erofs-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, pkgconfig, fuse, libuuid, lz4 }:
+{ lib, stdenv, fetchgit, autoreconfHook, pkgconfig, fuse, libuuid, lz4 }:
 
 stdenv.mkDerivation rec {
   pname = "erofs-utils";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--enable-fuse" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Userspace utilities for linux-erofs file system";
     license = with licenses; [ gpl2 ];
     maintainers = with maintainers; [ ehmry ];
diff --git a/pkgs/os-specific/linux/evdi/default.nix b/pkgs/os-specific/linux/evdi/default.nix
index 986bb402e57ff..0f56d0e95ca6e 100644
--- a/pkgs/os-specific/linux/evdi/default.nix
+++ b/pkgs/os-specific/linux/evdi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, kernel, libdrm }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, kernel, libdrm }:
 
 stdenv.mkDerivation rec {
   pname = "evdi";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     install -Dm755 library/libevdi.so $out/lib/libevdi.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extensible Virtual Display Interface";
     maintainers = with maintainers; [ eyjhb ];
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/extrace/default.nix b/pkgs/os-specific/linux/extrace/default.nix
index 23a9c68b5d5b8..8a02d9c67b14c 100644
--- a/pkgs/os-specific/linux/extrace/default.nix
+++ b/pkgs/os-specific/linux/extrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "extrace";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -m644 LICENSE "$out/share/licenses/extrace/LICENSE"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/leahneukirchen/extrace";
     description = "Trace exec() calls system-wide";
     license = with licenses; [ gpl2 bsd2 ];
diff --git a/pkgs/os-specific/linux/facetimehd/default.nix b/pkgs/os-specific/linux/facetimehd/default.nix
index 941e71c3bfc7d..80c823b31d738 100644
--- a/pkgs/os-specific/linux/facetimehd/default.nix
+++ b/pkgs/os-specific/linux/facetimehd/default.nix
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     "KDIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/patjak/bcwc_pcie";
     description = "Linux driver for the Facetime HD (Broadcom 1570) PCIe webcam";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/fatrace/default.nix b/pkgs/os-specific/linux/fatrace/default.nix
index 62767f6827854..a7f754a53ab53 100644
--- a/pkgs/os-specific/linux/fatrace/default.nix
+++ b/pkgs/os-specific/linux/fatrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3
 , which
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Report system-wide file access events";
     homepage = "https://github.com/martinpitt/fatrace";
     license = licenses.gpl3Plus;
diff --git a/pkgs/os-specific/linux/fbterm/default.nix b/pkgs/os-specific/linux/fbterm/default.nix
index 2b049bc6df5d2..e1909eea8947c 100644
--- a/pkgs/os-specific/linux/fbterm/default.nix
+++ b/pkgs/os-specific/linux/fbterm/default.nix
@@ -51,7 +51,7 @@ stdenv.mkDerivation {
     ./select.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (s) version;
     description = "Framebuffer terminal emulator";
     homepage = "https://code.google.com/archive/p/fbterm/";
diff --git a/pkgs/os-specific/linux/ffado/default.nix b/pkgs/os-specific/linux/ffado/default.nix
index b93caccc7574a..96ebaf178bf7e 100644
--- a/pkgs/os-specific/linux/ffado/default.nix
+++ b/pkgs/os-specific/linux/ffado/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , dbus
 , dbus_cplusplus
@@ -98,7 +98,7 @@ mkDerivation rec {
     wrapQtApp $bin/bin/ffado-mixer
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.ffado.org";
     description = "FireWire audio drivers";
     license = licenses.gpl3;
diff --git a/pkgs/os-specific/linux/firmware/b43-firmware/6.30.163.46.nix b/pkgs/os-specific/linux/firmware/b43-firmware/6.30.163.46.nix
index 3972e52977f68..c0226065ea269 100644
--- a/pkgs/os-specific/linux/firmware/b43-firmware/6.30.163.46.nix
+++ b/pkgs/os-specific/linux/firmware/b43-firmware/6.30.163.46.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, b43FirmwareCutter }:
+{ lib, stdenv, fetchurl, b43FirmwareCutter }:
 
 stdenv.mkDerivation rec {
   pname = "b43-firmware";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     b43-fwcutter -w $out *.wl_apsta.o
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware for cards supported by the b43 kernel module";
     homepage = "http://wireless.kernel.org/en/users/Drivers/b43";
     downloadPage = "http://www.lwfinger.com/b43-firmware";
diff --git a/pkgs/os-specific/linux/firmware/broadcom-bt-firmware/default.nix b/pkgs/os-specific/linux/firmware/broadcom-bt-firmware/default.nix
index 314a6b7521b88..5118d0a0b9bf5 100644
--- a/pkgs/os-specific/linux/firmware/broadcom-bt-firmware/default.nix
+++ b/pkgs/os-specific/linux/firmware/broadcom-bt-firmware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cabextract, bt-fw-converter }:
+{ lib, stdenv, fetchurl, cabextract, bt-fw-converter }:
 
 # Kernels between 4.2 and 4.7 will not work with
 # this packages as they expect the firmware to be named "BCM.hcd"
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
   outputHashAlgo = "sha256";
   outputHash = "042frb2dmrqfj8q83h5p769q6hg2b3i8fgnyvs9r9a71z7pbsagq";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware for Broadcom WIDCOMM® Bluetooth devices";
     homepage = "http://www.catalog.update.microsoft.com/Search.aspx?q=Broadcom+bluetooth";
     license = licenses.unfree;
diff --git a/pkgs/os-specific/linux/firmware/bt-fw-converter/default.nix b/pkgs/os-specific/linux/firmware/bt-fw-converter/default.nix
index 5b4506a10eae6..f9218b688a97e 100644
--- a/pkgs/os-specific/linux/firmware/bt-fw-converter/default.nix
+++ b/pkgs/os-specific/linux/firmware/bt-fw-converter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, perl, perlPackages, bluez }:
+{ lib, stdenv, fetchurl, makeWrapper, perl, perlPackages, bluez }:
 
 stdenv.mkDerivation  rec {
   pname = "bt-fw-converter";
@@ -25,7 +25,7 @@ stdenv.mkDerivation  rec {
     wrapProgram $out/bin/bt-fw-converter --set PERL5LIB $PERL5LIB
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/winterheart/broadcom-bt-firmware/";
     description = "A tool that converts hex to hcd based on inf file";
     license = licenses.mit;
diff --git a/pkgs/os-specific/linux/firmware/facetimehd-firmware/default.nix b/pkgs/os-specific/linux/firmware/facetimehd-firmware/default.nix
index 7d735e69f5687..88a32f174d54a 100644
--- a/pkgs/os-specific/linux/firmware/facetimehd-firmware/default.nix
+++ b/pkgs/os-specific/linux/firmware/facetimehd-firmware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cpio, xz, pkgs }:
+{ lib, stdenv, fetchurl, cpio, xz, pkgs }:
 
 let
 
@@ -54,7 +54,7 @@ stdenv.mkDerivation {
     gunzip -c ${firmwareOut}.gz > $out/lib/firmware/facetimehd/${firmwareOut}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "facetimehd firmware";
     homepage = "https://support.apple.com/kb/DL1877";
     license = licenses.unfree;
diff --git a/pkgs/os-specific/linux/firmware/fwupd/default.nix b/pkgs/os-specific/linux/firmware/fwupd/default.nix
index eb984d54c783f..25e0e6b0d8829 100644
--- a/pkgs/os-specific/linux/firmware/fwupd/default.nix
+++ b/pkgs/os-specific/linux/firmware/fwupd/default.nix
@@ -1,6 +1,6 @@
 # Updating? Keep $out/etc synchronized with passthru keys
 
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchFromGitHub
 , substituteAll
@@ -329,7 +329,7 @@ let
       };
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://fwupd.org/";
       maintainers = with maintainers; [ jtojnar ];
       license = licenses.lgpl21Plus;
diff --git a/pkgs/os-specific/linux/firmware/openelec-dvb-firmware/default.nix b/pkgs/os-specific/linux/firmware/openelec-dvb-firmware/default.nix
index ff0081a71e17d..3181072ea1821 100644
--- a/pkgs/os-specific/linux/firmware/openelec-dvb-firmware/default.nix
+++ b/pkgs/os-specific/linux/firmware/openelec-dvb-firmware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "openelec-dvb-firmware";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     find $out \( -name 'README.*' -or -name 'LICEN[SC]E.*' -or -name '*.txt' \) | xargs rm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DVB firmware from OpenELEC";
     homepage = "https://github.com/OpenELEC/dvb-firmware";
     license = licenses.unfreeRedistributableFirmware;
diff --git a/pkgs/os-specific/linux/firmware/raspberrypi-wireless/default.nix b/pkgs/os-specific/linux/firmware/raspberrypi-wireless/default.nix
index 1a432eb768c94..041694e2ec17a 100644
--- a/pkgs/os-specific/linux/firmware/raspberrypi-wireless/default.nix
+++ b/pkgs/os-specific/linux/firmware/raspberrypi-wireless/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "raspberrypi-wireless-firmware";
@@ -43,7 +43,7 @@ stdenv.mkDerivation {
   outputHashAlgo = "sha256";
   outputHash = "17k9y499kjc4zv7ivnsfrgfibwj0ldr3sqdgia4dackbr70jfg2h";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware for builtin Wifi/Bluetooth devices in the Raspberry Pi 3+ and Zero W";
     homepage = "https://github.com/RPi-Distro/firmware-nonfree";
     license = licenses.unfreeRedistributableFirmware;
diff --git a/pkgs/os-specific/linux/firmware/raspberrypi/armstubs.nix b/pkgs/os-specific/linux/firmware/raspberrypi/armstubs.nix
index 2f2d0081fffb4..ce4b14910b6b8 100644
--- a/pkgs/os-specific/linux/firmware/raspberrypi/armstubs.nix
+++ b/pkgs/os-specific/linux/firmware/raspberrypi/armstubs.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig }:
 
 let
   inherit (stdenv.lib) optionals;
@@ -41,7 +41,7 @@ stdenv.mkDerivation {
     cp -v *.bin $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware related ARM stubs for the Raspberry Pi";
     homepage = https://github.com/raspberrypi/tools;
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/firmware/rt5677/default.nix b/pkgs/os-specific/linux/firmware/rt5677/default.nix
index af0c07d105960..f5d84179fd29d 100644
--- a/pkgs/os-specific/linux/firmware/rt5677/default.nix
+++ b/pkgs/os-specific/linux/firmware/rt5677/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit }:
+{ lib, stdenv, fetchgit }:
 
 stdenv.mkDerivation {
   name = "rt5677-firmware";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     cp ./firmware/rt5677_elf_vad $out/lib/firmware
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware for Realtek rt5677 device";
     license = licenses.unfreeRedistributableFirmware;
     maintainers = [ maintainers.zohl ];
diff --git a/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix b/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix
index 9b68a49266f57..84a753ca8eac2 100644
--- a/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix
+++ b/pkgs/os-specific/linux/firmware/rtl8192su-firmware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 with stdenv.lib;
 stdenv.mkDerivation {
   name = "rtl8192su-unstable-2016-10-05";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware for Realtek RTL8188SU/RTL8191SU/RTL8192SU";
     homepage = "https://github.com/chunkeey/rtl8192su";
     license = licenses.unfreeRedistributableFirmware;
diff --git a/pkgs/os-specific/linux/firmware/rtl8723bs-firmware/default.nix b/pkgs/os-specific/linux/firmware/rtl8723bs-firmware/default.nix
index f95d1efcef77e..4f33f09cc787f 100644
--- a/pkgs/os-specific/linux/firmware/rtl8723bs-firmware/default.nix
+++ b/pkgs/os-specific/linux/firmware/rtl8723bs-firmware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, linuxPackages }:
+{ lib, stdenv, linuxPackages }:
 with stdenv.lib;
 stdenv.mkDerivation {
   name = "rtl8723bs-firmware-${linuxPackages.rtl8723bs.version}";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
     cp rtl8723bs_wowlan.bin "$out/lib/firmware/rtlwifi"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware for RealTek 8723bs";
     homepage = "https://github.com/hadess/rtl8723bs";
     license = licenses.unfreeRedistributableFirmware;
diff --git a/pkgs/os-specific/linux/firmware/rtl8761b-firmware/default.nix b/pkgs/os-specific/linux/firmware/rtl8761b-firmware/default.nix
index 4418722c7c45f..f2dd36a0e065a 100644
--- a/pkgs/os-specific/linux/firmware/rtl8761b-firmware/default.nix
+++ b/pkgs/os-specific/linux/firmware/rtl8761b-firmware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   name = "rtl8761b-firmware";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
       $out/lib/firmware/rtl_bt/rtl8761b_config.bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware for Realtek RTL8761b";
     license = licenses.unfreeRedistributableFirmware;
     maintainers = with maintainers; [ edibopp ];
diff --git a/pkgs/os-specific/linux/firmware/sof-firmware/default.nix b/pkgs/os-specific/linux/firmware/sof-firmware/default.nix
index 684d638ce29ff..c1f99bdad6867 100644
--- a/pkgs/os-specific/linux/firmware/sof-firmware/default.nix
+++ b/pkgs/os-specific/linux/firmware/sof-firmware/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 with stdenv.lib;
 stdenv.mkDerivation rec {
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     ROOT=$out SOF_VERSION=v${version} ./go.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sound Open Firmware";
     homepage = "https://www.sofproject.org/";
     license = with licenses; [ bsd3 isc ];
diff --git a/pkgs/os-specific/linux/flashbench/default.nix b/pkgs/os-specific/linux/flashbench/default.nix
index 70ad779c239b3..9c14fde319df5 100644
--- a/pkgs/os-specific/linux/flashbench/default.nix
+++ b/pkgs/os-specific/linux/flashbench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit }:
+{ lib, stdenv, fetchgit }:
 
 stdenv.mkDerivation {
   pname = "flashbench";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     install -v -m644 README $out/share/doc/flashbench
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Testing tool for flash based memory devices";
     homepage = "https://github.com/bradfa/flashbench";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/freefall/default.nix b/pkgs/os-specific/linux/freefall/default.nix
index a6c5a6593d1c8..683b599e5beb8 100644
--- a/pkgs/os-specific/linux/freefall/default.nix
+++ b/pkgs/os-specific/linux/freefall/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel }:
+{ lib, stdenv, kernel }:
 
 stdenv.mkDerivation {
   inherit (kernel) version src;
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (kernel.meta) homepage license;
 
     description = "Free-fall protection for spinning HP/Dell laptop hard drives";
diff --git a/pkgs/os-specific/linux/fscrypt/default.nix b/pkgs/os-specific/linux/fscrypt/default.nix
index 000400e4cdf94..db4b70037c8f7 100644
--- a/pkgs/os-specific/linux/fscrypt/default.nix
+++ b/pkgs/os-specific/linux/fscrypt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, gnum4, pam, fscrypt-experimental }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, gnum4, pam, fscrypt-experimental }:
 
 # Don't use this for anything important yet!
 
@@ -34,7 +34,7 @@ buildGoModule rec {
     make install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "A high-level tool for the management of Linux filesystem encryption";
     longDescription = ''
diff --git a/pkgs/os-specific/linux/fscryptctl/default.nix b/pkgs/os-specific/linux/fscryptctl/default.nix
index ecab0350d7897..204ce6bf992c8 100644
--- a/pkgs/os-specific/linux/fscryptctl/default.nix
+++ b/pkgs/os-specific/linux/fscryptctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 # Don't use this for anything important yet!
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A low-level tool that handles raw keys and manages policies for Linux
       filesystem encryption
diff --git a/pkgs/os-specific/linux/ftop/default.nix b/pkgs/os-specific/linux/ftop/default.nix
index d7791cd1a629b..abd6d78846198 100644
--- a/pkgs/os-specific/linux/ftop/default.nix
+++ b/pkgs/os-specific/linux/ftop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "ftop";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     substituteInPlace configure --replace "curses" "ncurses"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Show progress of open files and file systems";
     homepage = "https://code.google.com/archive/p/ftop/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/os-specific/linux/fuse/common.nix b/pkgs/os-specific/linux/fuse/common.nix
index b40bd84cbb8db..faef3673bb984 100644
--- a/pkgs/os-specific/linux/fuse/common.nix
+++ b/pkgs/os-specific/linux/fuse/common.nix
@@ -1,6 +1,6 @@
 { version, sha256Hash }:
 
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , fusePackages, util-linux, gettext
 , meson, ninja, pkg-config
 , autoreconfHook
@@ -83,7 +83,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library that allows filesystems to be implemented in user space";
     longDescription = ''
       FUSE (Filesystem in Userspace) is an interface for userspace programs to
diff --git a/pkgs/os-specific/linux/fwts/default.nix b/pkgs/os-specific/linux/fwts/default.nix
index 58d4bdbae8553..857d30859b5ae 100644
--- a/pkgs/os-specific/linux/fwts/default.nix
+++ b/pkgs/os-specific/linux/fwts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, autoreconfHook, pkgconfig, glib, libtool, pcre
+{ lib, stdenv, fetchzip, autoreconfHook, pkgconfig, glib, libtool, pcre
 , json_c, flex, bison, dtc, pciutils, dmidecode, iasl, libbsd }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.ubuntu.com/FirmwareTestSuite";
     description = "Firmware Test Suite";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/fwts/module.nix b/pkgs/os-specific/linux/fwts/module.nix
index ef90e0c303baa..737d3316e21dd 100644
--- a/pkgs/os-specific/linux/fwts/module.nix
+++ b/pkgs/os-specific/linux/fwts/module.nix
@@ -1,4 +1,4 @@
-{ stdenv, fwts, kernel }:
+{ lib, stdenv, fwts, kernel }:
 
 stdenv.mkDerivation rec {
   pname = "fwts-efi-runtime";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     "INSTALL_MOD_PATH=${placeholder "out"}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (fwts.meta) homepage license;
     description = fwts.meta.description + "(efi-runtime kernel module)";
     maintainers = with maintainers; [ dtzWill ];
diff --git a/pkgs/os-specific/linux/fxload/default.nix b/pkgs/os-specific/linux/fxload/default.nix
index e77983254e431..3255c992f8641 100644
--- a/pkgs/os-specific/linux/fxload/default.nix
+++ b/pkgs/os-specific/linux/fxload/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "fxload-2002_04_11";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     mkdir -p $out/share/usb
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://linux-hotplug.sourceforge.net/?selected=usb";
     description = "Tool to upload firmware to Cypress EZ-USB microcontrollers";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/gcadapter-oc-kmod/default.nix b/pkgs/os-specific/linux/gcadapter-oc-kmod/default.nix
index dd2979b587129..ab2e099d97087 100644
--- a/pkgs/os-specific/linux/gcadapter-oc-kmod/default.nix
+++ b/pkgs/os-specific/linux/gcadapter-oc-kmod/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , kernel
 , kmod
@@ -28,7 +28,7 @@ in stdenv.mkDerivation rec {
     install -D {,$out/${kerneldir}/extra/}gcadapter_oc.ko
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kernel module for overclocking the Nintendo Wii U/Mayflash GameCube adapter";
     homepage = "https://github.com/HannesMann/gcadapter-oc-kmod";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/gobi_loader/default.nix b/pkgs/os-specific/linux/gobi_loader/default.nix
index b8735354c2c61..b7972007719c9 100644
--- a/pkgs/os-specific/linux/gobi_loader/default.nix
+++ b/pkgs/os-specific/linux/gobi_loader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = "prefix=${placeholder "out"}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Firmware loader for Qualcomm Gobi USB chipsets";
     homepage = "https://www.codon.org.uk/~mjg59/gobi_loader/";
     license = with licenses; [ gpl2 ];
diff --git a/pkgs/os-specific/linux/gogoclient/default.nix b/pkgs/os-specific/linux/gogoclient/default.nix
index d107f18c8da25..b5eb1ce1a50cd 100644
--- a/pkgs/os-specific/linux/gogoclient/default.nix
+++ b/pkgs/os-specific/linux/gogoclient/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, openssl, nettools, iproute, sysctl}:
+{lib, stdenv, fetchurl, openssl, nettools, iproute, sysctl}:
 
 let baseName = "gogoclient";
     version  = "1.2";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     sed -i -e 's/^.*Exec \$route -A.*$/& metric 128/' $out/template/linux.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ipv6.ernet.in/Tunnel_broker";
     description = "Client to connect to the Freenet6 IPv6 tunnel broker service";
     maintainers = [ maintainers.bluescreen303 ];
diff --git a/pkgs/os-specific/linux/gradm/default.nix b/pkgs/os-specific/linux/gradm/default.nix
index fee183c825999..90f8df63e3b34 100644
--- a/pkgs/os-specific/linux/gradm/default.nix
+++ b/pkgs/os-specific/linux/gradm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , bison, flex
 , pam
 }:
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   postInstall = ''rmdir $out/dev'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "grsecurity RBAC administration and policy analysis utility";
     homepage    = "https://grsecurity.net";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/guvcview/default.nix b/pkgs/os-specific/linux/guvcview/default.nix
index d780cade78659..00e726d7222b9 100644
--- a/pkgs/os-specific/linux/guvcview/default.nix
+++ b/pkgs/os-specific/linux/guvcview/default.nix
@@ -1,5 +1,5 @@
 { config
-, stdenv
+, lib, stdenv
 , fetchurl
 , intltool
 , pkgconfig
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     gsl
     libpng
     sfml
-  ] 
+  ]
     ++ stdenv.lib.optionals (pulseaudioSupport) [ libpulseaudio ]
     ++ stdenv.lib.optionals (useGtk) [ gtk3 ]
     ++ stdenv.lib.optionals (useQt) [
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
     ++ stdenv.lib.optionals (useQt) [ "--enable-qt5" ]
   ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple interface for devices supported by the linux UVC driver";
     homepage = "http://guvcview.sourceforge.net";
     maintainers = [ maintainers.coconnor ];
diff --git a/pkgs/os-specific/linux/hal-flash/default.nix b/pkgs/os-specific/linux/hal-flash/default.nix
index c3463851fd3e8..a24bf093f8cf8 100644
--- a/pkgs/os-specific/linux/hal-flash/default.nix
+++ b/pkgs/os-specific/linux/hal-flash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, dbus, glib, libtool, pkgconfig, udisks2 }:
+{ lib, stdenv, fetchurl, autoconf, automake, dbus, glib, libtool, pkgconfig, udisks2 }:
 
 stdenv.mkDerivation {
   name = "hal-flash-0.3.3";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
 
   preConfigure = "libtoolize && aclocal && autoconf && automake --add-missing";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cshorler/hal-flash";
     description = "libhal stub library to satisfy the Flash Player DRM requirements";
     longDescription =
diff --git a/pkgs/os-specific/linux/hd-idle/default.nix b/pkgs/os-specific/linux/hd-idle/default.nix
index 5e32e220b2f81..3e4b08151463c 100644
--- a/pkgs/os-specific/linux/hd-idle/default.nix
+++ b/pkgs/os-specific/linux/hd-idle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "hd-idle-1.05";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "TARGET_DIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Spins down external disks after a period of idle time";
     homepage = "http://hd-idle.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/hdparm/default.nix b/pkgs/os-specific/linux/hdparm/default.nix
index 012cfb7e6032a..ada0ddef2330f 100644
--- a/pkgs/os-specific/linux/hdparm/default.nix
+++ b/pkgs/os-specific/linux/hdparm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "hdparm";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     makeFlagsArray=(sbindir=$out/sbin manprefix=$out)
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to get/set ATA/SATA drive parameters under Linux";
     homepage = "https://sourceforge.net/projects/hdparm/";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/hostapd/default.nix b/pkgs/os-specific/linux/hostapd/default.nix
index 991dcbe26152d..f004a27fca1fa 100644
--- a/pkgs/os-specific/linux/hostapd/default.nix
+++ b/pkgs/os-specific/linux/hostapd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libnl, openssl, sqlite ? null }:
+{ lib, stdenv, fetchurl, pkgconfig, libnl, openssl, sqlite ? null }:
 
 stdenv.mkDerivation rec {
   pname = "hostapd";
@@ -94,7 +94,7 @@ stdenv.mkDerivation rec {
     install -vD hostapd_cli.1 -t $man/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://hostap.epitest.fi";
     repositories.git = "git://w1.fi/hostap.git";
     description = "A user space daemon for access point and authentication servers";
diff --git a/pkgs/os-specific/linux/hyperv-daemons/default.nix b/pkgs/os-specific/linux/hyperv-daemons/default.nix
index 1a111a295a428..2d7644e6bda62 100644
--- a/pkgs/os-specific/linux/hyperv-daemons/default.nix
+++ b/pkgs/os-specific/linux/hyperv-daemons/default.nix
@@ -98,7 +98,7 @@ in stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integration Services for running NixOS under HyperV";
     longDescription = ''
       This packages contains the daemons that are used by the Hyper-V hypervisor
diff --git a/pkgs/os-specific/linux/i2c-tools/default.nix b/pkgs/os-specific/linux/i2c-tools/default.nix
index d1dc94290fab9..23bc89b7d1c92 100644
--- a/pkgs/os-specific/linux/i2c-tools/default.nix
+++ b/pkgs/os-specific/linux/i2c-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, read-edid }:
+{ lib, stdenv, fetchurl, perl, read-edid }:
 
 stdenv.mkDerivation rec {
   pname = "i2c-tools";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/include # Installs include/linux/i2c-dev.h that conflics with kernel headers
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of I2C tools for Linux";
     homepage = "https://i2c.wiki.kernel.org/index.php/I2C_Tools";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/ifmetric/default.nix b/pkgs/os-specific/linux/ifmetric/default.nix
index 1f69d728f604c..f5d55db5e41bd 100644
--- a/pkgs/os-specific/linux/ifmetric/default.nix
+++ b/pkgs/os-specific/linux/ifmetric/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, lynx }:
+{ lib, stdenv, fetchurl, lynx }:
 
 stdenv.mkDerivation rec {
   pname = "ifmetric";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for setting IP interface metrics";
     longDescription = ''
       ifmetric is a Linux tool for setting the metrics of all IPv4 routes
diff --git a/pkgs/os-specific/linux/iio-sensor-proxy/default.nix b/pkgs/os-specific/linux/iio-sensor-proxy/default.nix
index 95f555cef8c04..3f4a8e2348b57 100644
--- a/pkgs/os-specific/linux/iio-sensor-proxy/default.nix
+++ b/pkgs/os-specific/linux/iio-sensor-proxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf-archive, gettext, libtool, intltool, autoconf, automake
+{ lib, stdenv, fetchFromGitHub, autoconf-archive, gettext, libtool, intltool, autoconf, automake
 , glib, gtk3, gtk-doc, libgudev, pkgconfig, systemd }:
 
 stdenv.mkDerivation rec {
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     pkgconfig
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Proxy for sending IIO sensor data to D-Bus";
     homepage = "https://github.com/hadess/iio-sensor-proxy";
     license = licenses.gpl3 ;
diff --git a/pkgs/os-specific/linux/input-utils/default.nix b/pkgs/os-specific/linux/input-utils/default.nix
index 0fc2130d102a8..3be25867c335d 100644
--- a/pkgs/os-specific/linux/input-utils/default.nix
+++ b/pkgs/os-specific/linux/input-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, linuxHeaders }:
+{ lib, stdenv, fetchurl, linuxHeaders }:
 
 stdenv.mkDerivation rec {
   pname = "input-utils";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "STRIP="
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Input layer utilities, includes lsinput";
     homepage    = "https://www.kraxel.org/blog/linux/input/";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/intel-compute-runtime/default.nix b/pkgs/os-specific/linux/intel-compute-runtime/default.nix
index 7b8c2197d706b..9d69eca57f444 100644
--- a/pkgs/os-specific/linux/intel-compute-runtime/default.nix
+++ b/pkgs/os-specific/linux/intel-compute-runtime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , patchelf
 , cmake
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
       $out/lib/intel-opencl/libigdrcl.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/intel/compute-runtime";
     description = "Intel Graphics Compute Runtime for OpenCL. Replaces Beignet for Gen8 (Broadwell) and beyond";
     license     = licenses.mit;
diff --git a/pkgs/os-specific/linux/intel-speed-select/default.nix b/pkgs/os-specific/linux/intel-speed-select/default.nix
index 12536130a864b..89b4feff7a502 100644
--- a/pkgs/os-specific/linux/intel-speed-select/default.nix
+++ b/pkgs/os-specific/linux/intel-speed-select/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel }:
+{ lib, stdenv, kernel }:
 
 stdenv.mkDerivation {
   pname = "intel-speed-select";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
     sed -i 's,/usr,,g' Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to enumerate and control the Intel Speed Select Technology features";
     homepage = "https://www.kernel.org/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/ioport/default.nix b/pkgs/os-specific/linux/ioport/default.nix
index fad85335200cb..543495ec2afc0 100644
--- a/pkgs/os-specific/linux/ioport/default.nix
+++ b/pkgs/os-specific/linux/ioport/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, perl, fetchurl }:
+{ lib, stdenv, perl, fetchurl }:
 
 stdenv.mkDerivation {
   name = "ioport-1.2";
@@ -7,7 +7,7 @@ stdenv.mkDerivation {
     sha256 = "1h4d5g78y7kla0zl25jgyrk43wy3m3bygqg0blki357bc55irb3z";
   };
   buildInputs = [ perl ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Direct access to I/O ports from the command line";
     homepage = "https://people.redhat.com/rjones/ioport/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/iotop/default.nix b/pkgs/os-specific/linux/iotop/default.nix
index 8f742aa01be8f..1924e326c1e57 100644
--- a/pkgs/os-specific/linux/iotop/default.nix
+++ b/pkgs/os-specific/linux/iotop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3Packages, fetchpatch }:
+{ lib, stdenv, fetchurl, python3Packages, fetchpatch }:
 
 python3Packages.buildPythonApplication rec {
   name = "iotop-0.6";
@@ -17,7 +17,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to find out the processes doing the most IO";
     homepage = "http://guichaz.free.fr/iotop";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/iproute/default.nix b/pkgs/os-specific/linux/iproute/default.nix
index 55fa6b36de271..afd495dd6d1d0 100644
--- a/pkgs/os-specific/linux/iproute/default.nix
+++ b/pkgs/os-specific/linux/iproute/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , buildPackages, bison, flex, pkg-config
 , db, iptables, libelf, libmnl
 }:
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.linuxfoundation.org/networking/iproute2";
     description = "A collection of utilities for controlling TCP/IP networking and traffic control in Linux";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/iproute/mptcp.nix b/pkgs/os-specific/linux/iproute/mptcp.nix
index 63f0abcd2a299..6505d1d80eea2 100644
--- a/pkgs/os-specific/linux/iproute/mptcp.nix
+++ b/pkgs/os-specific/linux/iproute/mptcp.nix
@@ -1,4 +1,4 @@
-{ stdenv, iproute, fetchFromGitHub }:
+{ lib, stdenv, iproute, fetchFromGitHub }:
 
 iproute.overrideAttrs (oa: rec {
   pname = "iproute_mptcp";
@@ -17,7 +17,7 @@ iproute.overrideAttrs (oa: rec {
     patchShebangs configure
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/multipath-tcp/iproute-mptcp";
     description = "IP-Route extensions for MultiPath TCP";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/ipsec-tools/default.nix b/pkgs/os-specific/linux/ipsec-tools/default.nix
index bff356ccb6cf5..4e0ae7955beee 100644
--- a/pkgs/os-specific/linux/ipsec-tools/default.nix
+++ b/pkgs/os-specific/linux/ipsec-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, linuxHeaders, readline, openssl, flex, kerberos, pam }:
+{ lib, stdenv, fetchurl, fetchpatch, linuxHeaders, readline, openssl, flex, kerberos, pam }:
 
 # TODO: These tools are supposed to work under NetBSD and FreeBSD as
 # well, so I guess it's not appropriate to place this expression in
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     "--enable-stats"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ipsec-tools.sourceforge.net/";
     description = "Port of KAME's IPsec utilities to the Linux-2.6 IPsec implementation";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/ipset/default.nix b/pkgs/os-specific/linux/ipset/default.nix
index 647e5e3597df2..083c9aa726c6c 100644
--- a/pkgs/os-specific/linux/ipset/default.nix
+++ b/pkgs/os-specific/linux/ipset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libmnl }:
+{ lib, stdenv, fetchurl, pkgconfig, libmnl }:
 
 stdenv.mkDerivation rec {
   pname = "ipset";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--with-kmod=no" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ipset.netfilter.org/";
     description = "Administration tool for IP sets";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/iptstate/default.nix b/pkgs/os-specific/linux/iptstate/default.nix
index 529a82e96469b..94693f1559e53 100644
--- a/pkgs/os-specific/linux/iptstate/default.nix
+++ b/pkgs/os-specific/linux/iptstate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libnetfilter_conntrack, ncurses }:
+{ lib, stdenv, fetchurl, libnetfilter_conntrack, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "iptstate";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libnetfilter_conntrack ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Conntrack top like tool";
     homepage = "https://github.com/jaymzh/iptstate";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/ipvsadm/default.nix b/pkgs/os-specific/linux/ipvsadm/default.nix
index 5f91fa5dccd9d..aab8c2c7c83f0 100644
--- a/pkgs/os-specific/linux/ipvsadm/default.nix
+++ b/pkgs/os-specific/linux/ipvsadm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libnl, popt, gnugrep }:
+{ lib, stdenv, fetchurl, pkgconfig, libnl, popt, gnugrep }:
 
 stdenv.mkDerivation rec {
   pname = "ipvsadm";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     sed -i -e "s|^PATH=.*|PATH=$out/bin:${gnugrep}/bin|" $out/sbin/ipvsadm-{restore,save}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux Virtual Server support programs";
     homepage = "http://www.linuxvirtualserver.org/software/ipvs.html";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/it87/default.nix b/pkgs/os-specific/linux/it87/default.nix
index c48de130e5a12..1e56d3a830cc7 100644
--- a/pkgs/os-specific/linux/it87/default.nix
+++ b/pkgs/os-specific/linux/it87/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 stdenv.mkDerivation rec {
   name = "it87-${version}-${kernel.version}";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "MODDESTDIR=$(out)/lib/modules/${kernel.modDirVersion}/kernel/drivers/hwmon"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Patched module for IT87xx superio chip sensors support";
     homepage = "https://github.com/hannesha/it87";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/iwd/default.nix b/pkgs/os-specific/linux/iwd/default.nix
index 0cbd7ff3a3ad4..0e73dc94e5a01 100644
--- a/pkgs/os-specific/linux/iwd/default.nix
+++ b/pkgs/os-specific/linux/iwd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , fetchpatch
 , autoreconfHook
@@ -85,7 +85,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.kernel.org/pub/scm/network/wireless/iwd.git";
     description = "Wireless daemon for Linux";
     license = licenses.lgpl21;
diff --git a/pkgs/os-specific/linux/ixgbevf/default.nix b/pkgs/os-specific/linux/ixgbevf/default.nix
index 67b9a66a8abb2..6a748c4701903 100644
--- a/pkgs/os-specific/linux/ixgbevf/default.nix
+++ b/pkgs/os-specific/linux/ixgbevf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, kernel, kmod }:
+{ lib, stdenv, fetchurl, kernel, kmod }:
 
 stdenv.mkDerivation rec {
   name = "ixgbevf-${version}-${kernel.version}";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Intel 82599 Virtual Function Driver";
     homepage = "https://sourceforge.net/projects/e1000/files/ixgbevf%20stable/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/jfbview/default.nix b/pkgs/os-specific/linux/jfbview/default.nix
index 7984e2678070c..8ed1d87c195a7 100644
--- a/pkgs/os-specific/linux/jfbview/default.nix
+++ b/pkgs/os-specific/linux/jfbview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , freetype, harfbuzz, jbig2dec, libjpeg, libX11, mupdf_1_17, ncurses, openjpeg
 , openssl
 
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     install ${toString binaries} $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PDF and image viewer for the Linux framebuffer";
     longDescription = ''
       A very fast PDF and image viewer for the Linux framebuffer with some
diff --git a/pkgs/os-specific/linux/jool/cli.nix b/pkgs/os-specific/linux/jool/cli.nix
index 2d6e624fee696..8572f8ebdb93b 100644
--- a/pkgs/os-specific/linux/jool/cli.nix
+++ b/pkgs/os-specific/linux/jool/cli.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libnl, iptables }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libnl, iptables }:
 
 let
   sourceAttrs = (import ./source.nix) { inherit fetchFromGitHub; };
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     sed -e 's%^XTABLES_SO_DIR = .*%XTABLES_SO_DIR = '"$out"'/lib/xtables%g' -i src/usr/iptables/Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.jool.mx/";
     description = "Fairly compliant SIIT and Stateful NAT64 for Linux - CLI tools";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/jool/default.nix b/pkgs/os-specific/linux/jool/default.nix
index 69c0da3313642..58894de6c2e6a 100644
--- a/pkgs/os-specific/linux/jool/default.nix
+++ b/pkgs/os-specific/linux/jool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 let
   sourceAttrs = (import ./source.nix) { inherit fetchFromGitHub; };
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     make -C src/mod modules_install INSTALL_MOD_PATH=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.jool.mx/";
     description = "Fairly compliant SIIT and Stateful NAT64 for Linux - kernel modules";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/kbd/default.nix b/pkgs/os-specific/linux/kbd/default.nix
index 7ee449ff33ede..80cb98feffe11 100644
--- a/pkgs/os-specific/linux/kbd/default.nix
+++ b/pkgs/os-specific/linux/kbd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook,
+{ lib, stdenv, fetchurl, autoreconfHook,
   gzip, bzip2, pkgconfig, flex, check,
   pam, coreutils
 }:
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "setowner=" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "ftp://ftp.altlinux.org/pub/people/legion/kbd/";
     description = "Linux keyboard utilities and keyboard maps";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/kbdlight/default.nix b/pkgs/os-specific/linux/kbdlight/default.nix
index bc2d53b5e5d94..0ed575b82546a 100644
--- a/pkgs/os-specific/linux/kbdlight/default.nix
+++ b/pkgs/os-specific/linux/kbdlight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "kbdlight";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
       --replace 4755 0755
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hobarrera/kbdlight";
     description = "A very simple application that changes MacBooks' keyboard backlight level";
     license = licenses.isc;
diff --git a/pkgs/os-specific/linux/kexectools/default.nix b/pkgs/os-specific/linux/kexectools/default.nix
index a70cb2e087fc0..21d803e2b7211 100644
--- a/pkgs/os-specific/linux/kexectools/default.nix
+++ b/pkgs/os-specific/linux/kexectools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, zlib, fetchpatch }:
+{ lib, stdenv, buildPackages, fetchurl, zlib, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "kexec-tools";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://horms.net/projects/kexec/kexec-tools";
     description = "Tools related to the kexec Linux feature";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/keyutils/default.nix b/pkgs/os-specific/linux/keyutils/default.nix
index fe9cb46fb8a92..81d37d14d9d7c 100644
--- a/pkgs/os-specific/linux/keyutils/default.nix
+++ b/pkgs/os-specific/linux/keyutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 # Note: this package is used for bootstrapping fetchurl, and thus
 # cannot use fetchpatch! All mutable patches (generated by GitHub or
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     "USRLIBDIR=$(lib)/lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://people.redhat.com/dhowells/keyutils/";
     description = "Tools used to control the Linux kernel key management system";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix b/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix
index 17f34f9bbd795..1c7ea22b75846 100644
--- a/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix
+++ b/pkgs/os-specific/linux/kmod-blacklist-ubuntu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnugrep, findutils }:
+{ lib, stdenv, fetchurl, gnugrep, findutils }:
 
 let
   version = "22-1.1ubuntu1"; # Zesty
@@ -30,7 +30,7 @@ in stdenv.mkDerivation {
       --replace " xargs " " ${findutils}/bin/xargs "
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://packages.ubuntu.com/source/zesty/kmod";
     description = "Linux kernel module blacklists from Ubuntu";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/kmod/default.nix b/pkgs/os-specific/linux/kmod/default.nix
index 56fd4c353d922..9feb4fe98216e 100644
--- a/pkgs/os-specific/linux/kmod/default.nix
+++ b/pkgs/os-specific/linux/kmod/default.nix
@@ -38,7 +38,7 @@ in stdenv.mkDerivation rec {
     ln -s bin $out/sbin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for loading and managing Linux kernel modules";
     longDescription = ''
       kmod is a set of tools to handle common tasks with Linux kernel modules
diff --git a/pkgs/os-specific/linux/kmscon/default.nix b/pkgs/os-specific/linux/kmscon/default.nix
index 8b01fe94d4c7f..ee6a108301baf 100644
--- a/pkgs/os-specific/linux/kmscon/default.nix
+++ b/pkgs/os-specific/linux/kmscon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , libtsm
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "KMS/DRM based System Console";
     homepage = "http://www.freedesktop.org/wiki/Software/kmscon/";
     license = licenses.mit;
diff --git a/pkgs/os-specific/linux/kmscube/default.nix b/pkgs/os-specific/linux/kmscube/default.nix
index e2e63bc10a182..147b82c82bffe 100644
--- a/pkgs/os-specific/linux/kmscube/default.nix
+++ b/pkgs/os-specific/linux/kmscube/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, libdrm, libX11, libGL, mesa, pkgconfig }:
+{ lib, stdenv, fetchgit, autoreconfHook, libdrm, libX11, libGL, mesa, pkgconfig }:
 
 stdenv.mkDerivation {
   name = "kmscube-2018-06-17";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ libdrm libX11 libGL mesa ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Example OpenGL app using KMS/GBM";
     homepage = "https://gitlab.freedesktop.org/mesa/kmscube";
     license = licenses.mit;
diff --git a/pkgs/os-specific/linux/ledger-udev-rules/default.nix b/pkgs/os-specific/linux/ledger-udev-rules/default.nix
index e85eb02f8c80f..7b23719c791c3 100644
--- a/pkgs/os-specific/linux/ledger-udev-rules/default.nix
+++ b/pkgs/os-specific/linux/ledger-udev-rules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "ledger-udev-rules";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp 20-hw1.rules $out/lib/udev/rules.d/20-ledger.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "udev rules for Ledger devices";
     license = licenses.asl20;
     maintainers = with maintainers; [ asymmetric ];
diff --git a/pkgs/os-specific/linux/libatasmart/default.nix b/pkgs/os-specific/linux/libatasmart/default.nix
index cf5fc54ed65b7..5060df1638b66 100644
--- a/pkgs/os-specific/linux/libatasmart/default.nix
+++ b/pkgs/os-specific/linux/libatasmart/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, udev, buildPackages }:
+{ lib, stdenv, fetchurl, pkgconfig, udev, buildPackages }:
 
 stdenv.mkDerivation rec {
   name = "libatasmart-0.19";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ udev ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://0pointer.de/blog/projects/being-smart.html";
     description = "Library for querying ATA SMART status";
     license = licenses.lgpl21;
diff --git a/pkgs/os-specific/linux/libbpf/default.nix b/pkgs/os-specific/linux/libbpf/default.nix
index 948b8aab9afda..c454fc5f3b1e1 100644
--- a/pkgs/os-specific/linux/libbpf/default.nix
+++ b/pkgs/os-specific/linux/libbpf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig
+{ lib, stdenv, fetchFromGitHub, pkgconfig
 , libelf, zlib
 , fetchpatch
 }:
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
 
   # outputs = [ "out" "dev" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Upstream mirror of libbpf";
     homepage    = "https://github.com/libbpf/libbpf";
     license     = with licenses; [ lgpl21 /* or */ bsd2 ];
diff --git a/pkgs/os-specific/linux/libevdevc/default.nix b/pkgs/os-specific/linux/libevdevc/default.nix
index 372f110f34716..cb21eeaa75338 100644
--- a/pkgs/os-specific/linux/libevdevc/default.nix
+++ b/pkgs/os-specific/linux/libevdevc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, coreutils, pkgconfig, glib, jsoncpp }:
+{ lib, stdenv, fetchFromGitHub, coreutils, pkgconfig, glib, jsoncpp }:
 
 stdenv.mkDerivation rec {
   name = "libevdevc";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" "LIBDIR=/lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ChromiumOS libevdev. Renamed to avoid conflicts with the standard libevdev found in Linux distros";
     license = licenses.bsd3;
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/libfabric/default.nix b/pkgs/os-specific/linux/libfabric/default.nix
index 1911391c935cd..f6171220fb653 100644
--- a/pkgs/os-specific/linux/libfabric/default.nix
+++ b/pkgs/os-specific/linux/libfabric/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, libpsm2 }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, libpsm2 }:
 
 stdenv.mkDerivation rec {
   pname = "libfabric";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--enable-psm2=${libpsm2}" ] ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://libfabric.org/";
     description = "Open Fabric Interfaces";
     license = with licenses; [ gpl2 bsd2 ];
diff --git a/pkgs/os-specific/linux/libgestures/default.nix b/pkgs/os-specific/linux/libgestures/default.nix
index 46d25df31b9f9..9aaa1c2bce62e 100644
--- a/pkgs/os-specific/linux/libgestures/default.nix
+++ b/pkgs/os-specific/linux/libgestures/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, glib, jsoncpp }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, glib, jsoncpp }:
 
 stdenv.mkDerivation rec {
   name = "libgestures-${version}";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" "LIBDIR=/lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ChromiumOS libgestures modified to compile for Linux";
     license = licenses.bsd3;
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/libpsm2/default.nix b/pkgs/os-specific/linux/libpsm2/default.nix
index 501453b88216b..b7163617ce53d 100644
--- a/pkgs/os-specific/linux/libpsm2/default.nix
+++ b/pkgs/os-specific/linux/libpsm2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, numactl, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, numactl, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "libpsm2";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     rmdir $out/usr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/intel/opa-psm2";
     description = "The PSM2 library supports a number of fabric media and stacks";
     license = with licenses; [ gpl2 bsd3 ];
diff --git a/pkgs/os-specific/linux/libratbag/default.nix b/pkgs/os-specific/linux/libratbag/default.nix
index e9f090255f924..2a52e72cc91f0 100644
--- a/pkgs/os-specific/linux/libratbag/default.nix
+++ b/pkgs/os-specific/linux/libratbag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig
 , glib, systemd, udev, libevdev, gitMinimal, check, valgrind, swig, python3
 , json-glib, libunistring }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "-Dsystemd-unit-dir=./lib/systemd/system/"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configuration library for gaming mice";
     homepage    = "https://github.com/libratbag/libratbag";
     license     = licenses.mit;
diff --git a/pkgs/os-specific/linux/libsepol/default.nix b/pkgs/os-specific/linux/libsepol/default.nix
index 3592ba1637c1b..f5a190718bf8c 100644
--- a/pkgs/os-specific/linux/libsepol/default.nix
+++ b/pkgs/os-specific/linux/libsepol/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, flex }:
+{ lib, stdenv, fetchurl, flex }:
 
 stdenv.mkDerivation rec {
   pname = "libsepol";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   passthru = { inherit se_release se_url; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SELinux binary policy manipulation library";
     homepage = "http://userspace.selinuxproject.org";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/libsmbios/default.nix b/pkgs/os-specific/linux/libsmbios/default.nix
index 268588f53ab15..108568d0b5196 100644
--- a/pkgs/os-specific/linux/libsmbios/default.nix
+++ b/pkgs/os-specific/linux/libsmbios/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, help2man, gettext
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook, help2man, gettext
 , libxml2, perl, python3, doxygen }:
 
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   preFixup = ''rm -rf "$(pwd)" ''; # Hack to avoid TMPDIR in RPATHs
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dell/libsmbios";
     description = "A library to obtain BIOS information";
     license = with licenses; [ osl21 gpl2Plus ];
diff --git a/pkgs/os-specific/linux/libudev0-shim/default.nix b/pkgs/os-specific/linux/libudev0-shim/default.nix
index 2073f9f6f56ff..642dd534232ba 100644
--- a/pkgs/os-specific/linux/libudev0-shim/default.nix
+++ b/pkgs/os-specific/linux/libudev0-shim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, udev }:
+{ lib, stdenv, fetchFromGitHub, udev }:
 
 stdenv.mkDerivation rec {
   pname = "libudev0-shim";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     ln -s "$name" "$out/lib/libudev.so.0"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shim to preserve libudev.so.0 compatibility";
     homepage = "https://github.com/archlinux/libudev0-shim";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/libvolume_id/default.nix b/pkgs/os-specific/linux/libvolume_id/default.nix
index 98ddc50e2e482..f6b760668636c 100644
--- a/pkgs/os-specific/linux/libvolume_id/default.nix
+++ b/pkgs/os-specific/linux/libvolume_id/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "libvolume_id-0.81.1";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     cp -f libvolume_id.so.0 $out/lib/
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     license = licenses.gpl2;
   };
diff --git a/pkgs/os-specific/linux/linuxptp/default.nix b/pkgs/os-specific/linux/linuxptp/default.nix
index c836cfe5c4335..c9de5f874a3a9 100644
--- a/pkgs/os-specific/linux/linuxptp/default.nix
+++ b/pkgs/os-specific/linux/linuxptp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, linuxHeaders } :
+{ lib, stdenv, fetchurl, linuxHeaders } :
 
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Implementation of the Precision Time Protocol (PTP) according to IEEE standard 1588 for Linux";
     homepage = "http://linuxptp.sourceforge.net/";
     maintainers = [ maintainers.markuskowa ];
diff --git a/pkgs/os-specific/linux/lksctp-tools/default.nix b/pkgs/os-specific/linux/lksctp-tools/default.nix
index 6ddf4db562b7c..8bbd3ab7f4272 100644
--- a/pkgs/os-specific/linux/lksctp-tools/default.nix
+++ b/pkgs/os-specific/linux/lksctp-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "lksctp-tools-1.0.17";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "05da6c2v3acc18ndvmkrag6x5lf914b7s0xkkr6wkvrbvd621sqs";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux Kernel Stream Control Transmission Protocol Tools";
     homepage = "http://lksctp.sourceforge.net/";
     license = with licenses; [ gpl2 lgpl21 ]; # library is lgpl21
diff --git a/pkgs/os-specific/linux/lm-sensors/default.nix b/pkgs/os-specific/linux/lm-sensors/default.nix
index fa71d1fd15515..7bde5bd84a74f 100644
--- a/pkgs/os-specific/linux/lm-sensors/default.nix
+++ b/pkgs/os-specific/linux/lm-sensors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, bison, flex, which, perl
+{ lib, stdenv, fetchzip, bison, flex, which, perl
 , sensord ? false, rrdtool ? null
 }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     "AR=${stdenv.cc.targetPrefix}ar"
   ] ++ stdenv.lib.optional sensord "PROG_EXTRA=sensord";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://hwmon.wiki.kernel.org/lm_sensors";
     changelog = "https://raw.githubusercontent.com/lm-sensors/lm-sensors/V${dashedVersion}/CHANGES";
     description = "Tools for reading hardware sensors";
diff --git a/pkgs/os-specific/linux/logitech-udev-rules/default.nix b/pkgs/os-specific/linux/logitech-udev-rules/default.nix
index 369f412fbfc52..fde75fdcd6505 100644
--- a/pkgs/os-specific/linux/logitech-udev-rules/default.nix
+++ b/pkgs/os-specific/linux/logitech-udev-rules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, solaar }:
+{ lib, stdenv, solaar }:
 
 # ltunifi and solaar both provide udev rules but solaar's rules are more
 # up-to-date so we simply use that instead of having to maintain our own rules
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
     install -Dm644 -t $out/etc/udev/rules.d ${solaar.src}/rules.d/*.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "udev rules for Logitech devices";
     inherit (solaar.meta) homepage license platforms;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/os-specific/linux/lsscsi/default.nix b/pkgs/os-specific/linux/lsscsi/default.nix
index 57778357d0065..90c0361bce353 100644
--- a/pkgs/os-specific/linux/lsscsi/default.nix
+++ b/pkgs/os-specific/linux/lsscsi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "lsscsi-0.31";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
     substituteInPlace Makefile.in --replace /usr "$out"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl2;
     platforms = platforms.linux;
   };
diff --git a/pkgs/os-specific/linux/lttng-modules/default.nix b/pkgs/os-specific/linux/lttng-modules/default.nix
index 30d4a29b166cf..8e20ffda346e7 100644
--- a/pkgs/os-specific/linux/lttng-modules/default.nix
+++ b/pkgs/os-specific/linux/lttng-modules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, kernel }:
+{ lib, stdenv, fetchurl, kernel }:
 
 stdenv.mkDerivation rec {
   pname = "lttng-modules-${version}";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux kernel modules for LTTng tracing";
     homepage = "https://lttng.org/";
     license = with licenses; [ lgpl21 gpl2 mit ];
diff --git a/pkgs/os-specific/linux/lvm2/default.nix b/pkgs/os-specific/linux/lvm2/default.nix
index 6f1290cf07051..a7666cc6a7f5c 100644
--- a/pkgs/os-specific/linux/lvm2/default.nix
+++ b/pkgs/os-specific/linux/lvm2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchpatch
 , fetchurl
 , pkgconfig
@@ -118,7 +118,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.installer = nixosTests.installer.lvm;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://sourceware.org/lvm2/";
     description = "Tools to support Logical Volume Management (LVM) on Linux";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/macchanger/default.nix b/pkgs/os-specific/linux/macchanger/default.nix
index 29d2a3914a299..5c3646f7b3cc7 100644
--- a/pkgs/os-specific/linux/macchanger/default.nix
+++ b/pkgs/os-specific/linux/macchanger/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, texinfo }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, texinfo }:
 
 stdenv.mkDerivation rec {
   pname = "macchanger";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "info" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility for viewing/manipulating the MAC address of network interfaces";
     maintainers = with maintainers; [ joachifm ma27 ];
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/mba6x_bl/default.nix b/pkgs/os-specific/linux/mba6x_bl/default.nix
index f48a3dbb62f5f..441476d5f0656 100644
--- a/pkgs/os-specific/linux/mba6x_bl/default.nix
+++ b/pkgs/os-specific/linux/mba6x_bl/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, kernel, stdenv }:
+{ fetchFromGitHub, kernel, lib, stdenv }:
 
 stdenv.mkDerivation {
   name = "mba6x_bl-2016-12-08";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     "INSTALL_MOD_PATH=$(out)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MacBook Air 6,1 and 6,2 (mid 2013) backlight driver";
     homepage = "https://github.com/patjak/mba6x_bl";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/mcelog/default.nix b/pkgs/os-specific/linux/mcelog/default.nix
index 2e97f9da1eae5..de2c1afb06587 100644
--- a/pkgs/os-specific/linux/mcelog/default.nix
+++ b/pkgs/os-specific/linux/mcelog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, util-linux }:
+{ lib, stdenv, fetchFromGitHub, util-linux }:
 
 stdenv.mkDerivation rec {
   pname = "mcelog";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
       --replace /usr/sbin $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Log x86 machine checks: memory, IO, and CPU hardware errors";
     longDescription = ''
       The mcelog daemon accounts memory and some other errors in various ways
diff --git a/pkgs/os-specific/linux/mdadm/default.nix b/pkgs/os-specific/linux/mdadm/default.nix
index 2fbe05557a2f5..6a319572cbe98 100644
--- a/pkgs/os-specific/linux/mdadm/default.nix
+++ b/pkgs/os-specific/linux/mdadm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, util-linux, coreutils, fetchurl, groff, system-sendmail }:
+{ lib, stdenv, util-linux, coreutils, fetchurl, groff, system-sendmail }:
 
 stdenv.mkDerivation rec {
   name = "mdadm-4.1";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     grep -r $out $out/bin && false || true
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Programs for managing RAID arrays under Linux";
     homepage = "http://neil.brown.name/blog/mdadm";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/metastore/default.nix b/pkgs/os-specific/linux/metastore/default.nix
index 590b931ac9202..c9875297186e2 100644
--- a/pkgs/os-specific/linux/metastore/default.nix
+++ b/pkgs/os-specific/linux/metastore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libbsd, fetchFromGitHub }:
+{ lib, stdenv, libbsd, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   version = "1.1.2";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libbsd ];
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Store and restore metadata from a filesystem";
     homepage = "https://software.przemoc.net/#metastore";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/microcode/amd.nix b/pkgs/os-specific/linux/microcode/amd.nix
index 135187c9a108b..72f413f9cb662 100644
--- a/pkgs/os-specific/linux/microcode/amd.nix
+++ b/pkgs/os-specific/linux/microcode/amd.nix
@@ -1,4 +1,4 @@
-{ stdenv, firmwareLinuxNonfree, libarchive }:
+{ lib, stdenv, firmwareLinuxNonfree, libarchive }:
 
 stdenv.mkDerivation {
   name = "amd-ucode-${firmwareLinuxNonfree.version}";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     echo kernel/x86/microcode/AuthenticAMD.bin | bsdcpio -o -H newc -R 0:0 > $out/amd-ucode.img
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AMD Processor microcode patch";
     homepage = "https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git";
     license = licenses.unfreeRedistributableFirmware;
diff --git a/pkgs/os-specific/linux/microcode/intel.nix b/pkgs/os-specific/linux/microcode/intel.nix
index 50055102dbbe7..d6d04f12f8850 100644
--- a/pkgs/os-specific/linux/microcode/intel.nix
+++ b/pkgs/os-specific/linux/microcode/intel.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libarchive, iucode-tool }:
+{ lib, stdenv, fetchFromGitHub, libarchive, iucode-tool }:
 
 stdenv.mkDerivation rec {
   pname = "microcode-intel";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.intel.com/";
     description = "Microcode for Intel processors";
     license = licenses.unfreeRedistributableFirmware;
diff --git a/pkgs/os-specific/linux/microcode/iucode-tool.nix b/pkgs/os-specific/linux/microcode/iucode-tool.nix
index 65cb01c84a52d..e38dd83e0dba6 100644
--- a/pkgs/os-specific/linux/microcode/iucode-tool.nix
+++ b/pkgs/os-specific/linux/microcode/iucode-tool.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, autoreconfHook }:
+{ lib, stdenv, fetchFromGitLab, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "iucode-tool";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Intel® 64 and IA-32 processor microcode tool";
     homepage = "https://gitlab.com/iucode-tool/iucode-tool";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/mingetty/default.nix b/pkgs/os-specific/linux/mingetty/default.nix
index 775910d30d6ff..8a2cf69dd368f 100644
--- a/pkgs/os-specific/linux/mingetty/default.nix
+++ b/pkgs/os-specific/linux/mingetty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "mingetty-1.08";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
     makeFlagsArray=(SBINDIR=$out/sbin MANDIR=$out/share/man/man8)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/mingetty";
     license = licenses.gpl2;
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/miraclecast/default.nix b/pkgs/os-specific/linux/miraclecast/default.nix
index d04695ef619d0..e2230da3d2c0a 100644
--- a/pkgs/os-specific/linux/miraclecast/default.nix
+++ b/pkgs/os-specific/linux/miraclecast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig
 , glib, readline, pcre, systemd, udev }:
 
 stdenv.mkDerivation {
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     "-Dbuild-tests=true"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Connect external monitors via Wi-Fi";
     homepage    = "https://github.com/albfan/miraclecast";
     license     = licenses.lgpl21Plus;
diff --git a/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix b/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix
index 8a20a2f733af1..eeea1d74dcac4 100644
--- a/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix
+++ b/pkgs/os-specific/linux/mkinitcpio-nfs-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "mkinitcpio-nfs-utils-0.3";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/usr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://archlinux.org/";
     description = "ipconfig and nfsmount tools for root on NFS, ported from klibc";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/mmc-utils/default.nix b/pkgs/os-specific/linux/mmc-utils/default.nix
index 6a9f807947d41..aff847c20ff68 100644
--- a/pkgs/os-specific/linux/mmc-utils/default.nix
+++ b/pkgs/os-specific/linux/mmc-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit }:
+{ lib, stdenv, fetchgit }:
 
 stdenv.mkDerivation {
   pname = "mmc-utils";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     cp man/mmc.1 $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configure MMC storage devices from userspace";
     homepage = "http://git.kernel.org/cgit/linux/kernel/git/cjb/mmc-utils.git/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/molly-guard/default.nix b/pkgs/os-specific/linux/molly-guard/default.nix
index c9bdff9de3ec4..de396e4f5c762 100644
--- a/pkgs/os-specific/linux/molly-guard/default.nix
+++ b/pkgs/os-specific/linux/molly-guard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg, busybox, systemd }:
+{ lib, stdenv, fetchurl, dpkg, busybox, systemd }:
 
 stdenv.mkDerivation rec {
   pname = "molly-guard";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     done;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Attempts to prevent you from accidentally shutting down or rebooting machines";
     homepage    = "https://salsa.debian.org/debian/molly-guard";
     license     = licenses.artistic2;
diff --git a/pkgs/os-specific/linux/msr-tools/default.nix b/pkgs/os-specific/linux/msr-tools/default.nix
index f7b81bd3915d6..67356719ffdba 100644
--- a/pkgs/os-specific/linux/msr-tools/default.nix
+++ b/pkgs/os-specific/linux/msr-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "msr-tools";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
       --replace /usr/sbin $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to read/write from/to MSR CPU registers on Linux";
     license = licenses.gpl2;
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/mstpd/default.nix b/pkgs/os-specific/linux/mstpd/default.nix
index 4a7c6282d4c76..389acdf91e6e9 100644
--- a/pkgs/os-specific/linux/mstpd/default.nix
+++ b/pkgs/os-specific/linux/mstpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "mstpd";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     "--libexecdir=$(out)/lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multiple Spanning Tree Protocol daemon";
     homepage = "https://github.com/mstpd/mstpd";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/multipath-tools/default.nix b/pkgs/os-specific/linux/multipath-tools/default.nix
index 02853f6497fc0..57c75210568f2 100644
--- a/pkgs/os-specific/linux/multipath-tools/default.nix
+++ b/pkgs/os-specific/linux/multipath-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, perl, lvm2, libaio, gzip, readline, systemd, liburcu, json_c }:
+{ lib, stdenv, fetchurl, pkgconfig, perl, lvm2, libaio, gzip, readline, systemd, liburcu, json_c }:
 
 stdenv.mkDerivation rec {
   pname = "multipath-tools";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     "SYSTEMDPATH=lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for the Linux multipathing driver";
     homepage = "http://christophe.varoqui.free.fr/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/mxu11x0/default.nix b/pkgs/os-specific/linux/mxu11x0/default.nix
index ab0b927f1bd11..730b03e93feb4 100644
--- a/pkgs/os-specific/linux/mxu11x0/default.nix
+++ b/pkgs/os-specific/linux/mxu11x0/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, kernel }:
+{ lib, stdenv, fetchurl, kernel }:
 
 stdenv.mkDerivation {
   name = "mxu11x0-1.4-${kernel.version}";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "pic" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MOXA UPort 11x0 USB to Serial Hub driver";
     homepage = "https://www.moxa.com/en/products/industrial-edge-connectivity/usb-to-serial-converters-usb-hubs/usb-to-serial-converters/uport-1000-series";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/net-tools/mptcp.nix b/pkgs/os-specific/linux/net-tools/mptcp.nix
index 6e798e6807d7d..a9f99874367c1 100644
--- a/pkgs/os-specific/linux/net-tools/mptcp.nix
+++ b/pkgs/os-specific/linux/net-tools/mptcp.nix
@@ -1,4 +1,4 @@
-{ stdenv, nettools, fetchFromGitHub  }:
+{ lib, stdenv, nettools, fetchFromGitHub  }:
 
 nettools.overrideAttrs(oa: rec {
   name = "net-tools-mptcp";
@@ -11,7 +11,7 @@ nettools.overrideAttrs(oa: rec {
     sha256 = "0i7gr1y699nc7j9qllsx8kicqkpkhw51x4chcmyl5xs06b2mdjri";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/multipath-tcp/net-tools";
     description = "A set of tools for controlling the network subsystem in Linux";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/nfs-utils/default.nix b/pkgs/os-specific/linux/nfs-utils/default.nix
index 63a1a0d8f9665..708430da397e9 100644
--- a/pkgs/os-specific/linux/nfs-utils/default.nix
+++ b/pkgs/os-specific/linux/nfs-utils/default.nix
@@ -114,7 +114,7 @@ stdenv.mkDerivation rec {
     nfs4-kerberos = nixosTests.nfs4.kerberos;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux user-space NFS utilities";
 
     longDescription = ''
diff --git a/pkgs/os-specific/linux/nmon/default.nix b/pkgs/os-specific/linux/nmon/default.nix
index 9de18401d7b2c..7ec84443cfe8f 100644
--- a/pkgs/os-specific/linux/nmon/default.nix
+++ b/pkgs/os-specific/linux/nmon/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, ncurses }:
+{ fetchurl, lib, stdenv, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "nmon";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp nmon $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AIX & Linux Performance Monitoring tool";
     homepage = "http://nmon.sourceforge.net";
     license = licenses.gpl3Plus;
diff --git a/pkgs/os-specific/linux/nss_ldap/default.nix b/pkgs/os-specific/linux/nss_ldap/default.nix
index 74369060ba9f0..0121c4a6f1c86 100644
--- a/pkgs/os-specific/linux/nss_ldap/default.nix
+++ b/pkgs/os-specific/linux/nss_ldap/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, openldap, perl}:
+{lib, stdenv, fetchurl, openldap, perl}:
 
 stdenv.mkDerivation {
   name = "nss_ldap-265";
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ openldap perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LDAP module for the Solaris Nameservice Switch (NSS)";
     license = licenses.gpl2;
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/numactl/default.nix b/pkgs/os-specific/linux/numactl/default.nix
index 6e16ecabba2d1..d796bf579f125 100644
--- a/pkgs/os-specific/linux/numactl/default.nix
+++ b/pkgs/os-specific/linux/numactl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "numactl";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
   # building ~5% slower until reboot. Ugh!
   doCheck = false; # never ever!
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library and tools for non-uniform memory access (NUMA) machines";
     homepage = "https://github.com/numactl/numactl";
     license = with licenses; [ gpl2 lgpl21 ]; # libnuma is lgpl21
diff --git a/pkgs/os-specific/linux/numad/default.nix b/pkgs/os-specific/linux/numad/default.nix
index 47af20152db9c..cab5fe15e66d7 100644
--- a/pkgs/os-specific/linux/numad/default.nix
+++ b/pkgs/os-specific/linux/numad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "numad-0.5";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A user-level daemon that monitors NUMA topology and processes resource consumption to facilitate good NUMA resource access";
     homepage = "https://fedoraproject.org/wiki/Features/numad";
     license = licenses.lgpl21;
diff --git a/pkgs/os-specific/linux/numatop/default.nix b/pkgs/os-specific/linux/numatop/default.nix
index 57ee511bbadcf..a534ebaaac308 100644
--- a/pkgs/os-specific/linux/numatop/default.nix
+++ b/pkgs/os-specific/linux/numatop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, numactl, ncurses, check }:
+{ lib, stdenv, fetchurl, pkgconfig, numactl, ncurses, check }:
 
 stdenv.mkDerivation rec {
   pname = "numatop";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   doCheck  = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for runtime memory locality characterization and analysis of processes and threads on a NUMA system";
     homepage = "https://01.org/numatop";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/numworks-udev-rules/default.nix b/pkgs/os-specific/linux/numworks-udev-rules/default.nix
index 4a123b202730b..aae7507f50cdd 100644
--- a/pkgs/os-specific/linux/numworks-udev-rules/default.nix
+++ b/pkgs/os-specific/linux/numworks-udev-rules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "numworks-udev-rules";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
     install -Dm 644 "${udevRules}" "$out/lib/udev/rules.d/50-numworks-calculator.rules"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Udev rules for Numworks calculators";
     homepage = "https://numworks.com";
     license = licenses.gpl3Plus;
diff --git a/pkgs/os-specific/linux/nvidia-x11/generic.nix b/pkgs/os-specific/linux/nvidia-x11/generic.nix
index 8a9e340a20a20..1587ad06bc30c 100644
--- a/pkgs/os-specific/linux/nvidia-x11/generic.nix
+++ b/pkgs/os-specific/linux/nvidia-x11/generic.nix
@@ -16,7 +16,7 @@
 , broken ? false
 }@args:
 
-{ stdenv, callPackage, pkgs, pkgsi686Linux, fetchurl
+{ lib, stdenv, callPackage, pkgs, pkgsi686Linux, fetchurl
 , kernel ? null, perl, nukeReferences
 , # Whether to build the libraries only (i.e. not the kernel module or
   # nvidia-settings).  Used to support 32-bit binaries on 64-bit
@@ -95,7 +95,7 @@ let
       inherit persistencedVersion settingsVersion;
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://www.nvidia.com/object/unix.html";
       description = "X.org driver and kernel module for NVIDIA graphics cards";
       license = licenses.unfreeRedistributable;
diff --git a/pkgs/os-specific/linux/nvidia-x11/persistenced.nix b/pkgs/os-specific/linux/nvidia-x11/persistenced.nix
index 5979f7e9a224b..193aa548021db 100644
--- a/pkgs/os-specific/linux/nvidia-x11/persistenced.nix
+++ b/pkgs/os-specific/linux/nvidia-x11/persistenced.nix
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE = [ "-I${libtirpc.dev}/include/tirpc" ];
   NIX_LDFLAGS = [ "-ltirpc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.nvidia.com/object/unix.html";
     description = "Settings application for NVIDIA graphics cards";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/os-specific/linux/nvidia-x11/settings.nix b/pkgs/os-specific/linux/nvidia-x11/settings.nix
index fbddd7b7fa218..4076a27ffc251 100644
--- a/pkgs/os-specific/linux/nvidia-x11/settings.nix
+++ b/pkgs/os-specific/linux/nvidia-x11/settings.nix
@@ -97,7 +97,7 @@ stdenv.mkDerivation {
     inherit libXNVCtrl;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.nvidia.com/object/unix.html";
     description = "Settings application for NVIDIA graphics cards";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/os-specific/linux/nvidiabl/default.nix b/pkgs/os-specific/linux/nvidiabl/default.nix
index f56e74eda0425..7ce7c313485d6 100644
--- a/pkgs/os-specific/linux/nvidiabl/default.nix
+++ b/pkgs/os-specific/linux/nvidiabl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 stdenv.mkDerivation rec {
   name = "nvidiabl-${version}-${kernel.version}";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "KVER=${kernel.modDirVersion}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux driver for setting the backlight brightness on laptops using NVIDIA GPU";
     homepage = "https://github.com/guillaumezin/nvidiabl";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/oci-seccomp-bpf-hook/default.nix b/pkgs/os-specific/linux/oci-seccomp-bpf-hook/default.nix
index 3247e8c4eda56..c74810d24d5a1 100644
--- a/pkgs/os-specific/linux/oci-seccomp-bpf-hook/default.nix
+++ b/pkgs/os-specific/linux/oci-seccomp-bpf-hook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , go-md2man
@@ -45,7 +45,7 @@ buildGoModule rec {
     installManPage docs/*.[1-9]
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/containers/oci-seccomp-bpf-hook";
     description = ''
       OCI hook to trace syscalls and generate a seccomp profile
diff --git a/pkgs/os-specific/linux/odp-dpdk/default.nix b/pkgs/os-specific/linux/odp-dpdk/default.nix
index 39bb2f3e411f5..621e6d1f54c33 100644
--- a/pkgs/os-specific/linux/odp-dpdk/default.nix
+++ b/pkgs/os-specific/linux/odp-dpdk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig
 , dpdk, libconfig, libpcap, numactl, openssl, zlib, libbsd, libelf, jansson
 }: let
   dpdk_18_11 = dpdk.overrideAttrs (old: rec {
@@ -50,7 +50,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open Data Plane optimized for DPDK";
     homepage = "https://www.opendataplane.org";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/ofp/default.nix b/pkgs/os-specific/linux/ofp/default.nix
index 7467f7d871370..b392bf6f0ea8b 100644
--- a/pkgs/os-specific/linux/ofp/default.nix
+++ b/pkgs/os-specific/linux/ofp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
 , openssl, libpcap, odp-dpdk, dpdk
 }:
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     "--disable-shared"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High performance TCP/IP stack";
     homepage = "http://www.openfastpath.org";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/open-iscsi/default.nix b/pkgs/os-specific/linux/open-iscsi/default.nix
index d065dea846bff..5894d4f506edf 100644
--- a/pkgs/os-specific/linux/open-iscsi/default.nix
+++ b/pkgs/os-specific/linux/open-iscsi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, automake, autoconf, libtool, gettext
+{ lib, stdenv, fetchFromGitHub, automake, autoconf, libtool, gettext
 , util-linux, openisns, openssl, kmod, perl, systemd, pkgconf
 }:
 
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     sed -i "s|/sbin/iscsiadm|$out/bin/iscsiadm|" $out/bin/iscsi_fw_login
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high performance, transport independent, multi-platform implementation of RFC3720";
     license = licenses.gpl2Plus;
     homepage = "https://www.open-iscsi.com";
diff --git a/pkgs/os-specific/linux/openrazer/driver.nix b/pkgs/os-specific/linux/openrazer/driver.nix
index ef96c7697e777..32c99a8be13a6 100644
--- a/pkgs/os-specific/linux/openrazer/driver.nix
+++ b/pkgs/os-specific/linux/openrazer/driver.nix
@@ -2,11 +2,12 @@
 , fetchFromGitHub
 , kernel
 , stdenv
+, lib
 , util-linux
 }:
 
 let
-  common = import ../../../development/python-modules/openrazer/common.nix { inherit stdenv fetchFromGitHub; };
+  common = import ../../../development/python-modules/openrazer/common.nix { inherit lib stdenv fetchFromGitHub; };
 in
 stdenv.mkDerivation (common // {
   name = "openrazer-${common.version}-${kernel.version}";
diff --git a/pkgs/os-specific/linux/openvswitch/default.nix b/pkgs/os-specific/linux/openvswitch/default.nix
index 84f8abf73b0f8..ab7e7cf62e200 100644
--- a/pkgs/os-specific/linux/openvswitch/default.nix
+++ b/pkgs/os-specific/linux/openvswitch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, pkgconfig, util-linux, which
+{ lib, stdenv, fetchurl, makeWrapper, pkgconfig, util-linux, which
 , procps, libcap_ng, openssl, python3 , perl
 , kernel ? null }:
 
@@ -44,7 +44,7 @@ in stdenv.mkDerivation rec {
   enableParallelBuilding = true;
   doCheck = false; # bash-completion test fails with "compgen: command not found"
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     description = "A multilayer virtual switch";
     longDescription =
diff --git a/pkgs/os-specific/linux/openvswitch/lts.nix b/pkgs/os-specific/linux/openvswitch/lts.nix
index 54ecefc54b2f4..d0588d4b4416f 100644
--- a/pkgs/os-specific/linux/openvswitch/lts.nix
+++ b/pkgs/os-specific/linux/openvswitch/lts.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, pkgconfig, util-linux, which
+{ lib, stdenv, fetchurl, makeWrapper, pkgconfig, util-linux, which
 , procps, libcap_ng, openssl, python2, iproute , perl
 , automake, autoconf, libtool, kernel ? null }:
 
@@ -61,7 +61,7 @@ in stdenv.mkDerivation rec {
       --replace "self.cert_dir" "root_prefix + self.cert_dir"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     description = "A multilayer virtual switch";
     longDescription =
diff --git a/pkgs/os-specific/linux/pagemon/default.nix b/pkgs/os-specific/linux/pagemon/default.nix
index 64177fa5d00bc..2ce723913578d 100644
--- a/pkgs/os-specific/linux/pagemon/default.nix
+++ b/pkgs/os-specific/linux/pagemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "pagemon";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "MANDIR=$(out)/share/man/man8"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Interactive memory/page monitor for Linux";
     longDescription = ''
diff --git a/pkgs/os-specific/linux/pam/default.nix b/pkgs/os-specific/linux/pam/default.nix
index 3faf74af64083..d42ced5ad55af 100644
--- a/pkgs/os-specific/linux/pam/default.nix
+++ b/pkgs/os-specific/linux/pam/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, fetchpatch, flex, cracklib, db4
+{ lib, stdenv, buildPackages, fetchurl, fetchpatch, flex, cracklib, db4
 , nixosTests
 }:
 
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
     inherit (nixosTests) pam-oath-login pam-u2f shadow;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.linux-pam.org/";
     description = "Pluggable Authentication Modules, a flexible mechanism for authenticating user";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/pam_ccreds/default.nix b/pkgs/os-specific/linux/pam_ccreds/default.nix
index c4abfe5c44cba..bfe9ac7c830ca 100644
--- a/pkgs/os-specific/linux/pam_ccreds/default.nix
+++ b/pkgs/os-specific/linux/pam_ccreds/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, pam, openssl, db}:
+{lib, stdenv, fetchurl, pam, openssl, db}:
 
 stdenv.mkDerivation rec {
   name = "pam_ccreds-10";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pam openssl db ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.padl.com/OSS/pam_ccreds.html";
     description = "PAM module to locally authenticate using an enterprise identity when the network is unavailable";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/pam_gnupg/default.nix b/pkgs/os-specific/linux/pam_gnupg/default.nix
index 50373fe746d62..6ffc6050055ea 100644
--- a/pkgs/os-specific/linux/pam_gnupg/default.nix
+++ b/pkgs/os-specific/linux/pam_gnupg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pam, gnupg }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pam, gnupg }:
 
 stdenv.mkDerivation rec {
   pname = "pam_gnupg";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unlock GnuPG keys on login";
     longDescription = ''
       A PAM module that hands over your login password to gpg-agent. This can
diff --git a/pkgs/os-specific/linux/pam_krb5/default.nix b/pkgs/os-specific/linux/pam_krb5/default.nix
index 7a384c793d23f..8abfe5fee9d66 100644
--- a/pkgs/os-specific/linux/pam_krb5/default.nix
+++ b/pkgs/os-specific/linux/pam_krb5/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pam, kerberos }:
+{ lib, stdenv, fetchurl, pam, kerberos }:
 
 stdenv.mkDerivation rec {
   name = "pam-krb5-4.9";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pam kerberos ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.eyrie.org/~eagle/software/pam-krb5/";
     description = "PAM module allowing PAM-aware applications to authenticate users by performing an AS exchange with a Kerberos KDC";
     longDescription = ''
diff --git a/pkgs/os-specific/linux/pam_mount/default.nix b/pkgs/os-specific/linux/pam_mount/default.nix
index ebfd896555ae5..464a2b04b2b41 100644
--- a/pkgs/os-specific/linux/pam_mount/default.nix
+++ b/pkgs/os-specific/linux/pam_mount/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig, libtool, pam, libHX, libxml2, pcre, perl, openssl, cryptsetup, util-linux }:
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig, libtool, pam, libHX, libxml2, pcre, perl, openssl, cryptsetup, util-linux }:
 
 stdenv.mkDerivation rec {
   pname = "pam_mount";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     rm -r $out/var
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PAM module to mount volumes for a user session";
     homepage = "https://pam-mount.sourceforge.net/";
     license = with licenses; [ gpl2 gpl3 lgpl21 lgpl3 ];
diff --git a/pkgs/os-specific/linux/pam_p11/default.nix b/pkgs/os-specific/linux/pam_p11/default.nix
index d5336cc9f4ce7..1ed47ba53c2a3 100644
--- a/pkgs/os-specific/linux/pam_p11/default.nix
+++ b/pkgs/os-specific/linux/pam_p11/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkg-config, openssl, libp11, pam }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config, openssl, libp11, pam }:
 
 stdenv.mkDerivation rec {
   pname = "pam_p11";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkg-config ];
   buildInputs = [ pam openssl libp11 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/OpenSC/pam_p11";
     description = "Authentication with PKCS#11 modules";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/os-specific/linux/pam_pgsql/default.nix b/pkgs/os-specific/linux/pam_pgsql/default.nix
index 6aa1c3be1e251..eece7b84c3d61 100644
--- a/pkgs/os-specific/linux/pam_pgsql/default.nix
+++ b/pkgs/os-specific/linux/pam_pgsql/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, postgresql, libgcrypt, pam }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, postgresql, libgcrypt, pam }:
 
 stdenv.mkDerivation rec {
   pname = "pam_pgsql";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ libgcrypt pam postgresql ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Support to authenticate against PostgreSQL for PAM-enabled appliations";
     homepage = "https://github.com/pam-pgsql/pam-pgsql";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/pam_u2f/default.nix b/pkgs/os-specific/linux/pam_u2f/default.nix
index d8d9a96652c43..852fb2d73ef88 100644
--- a/pkgs/os-specific/linux/pam_u2f/default.nix
+++ b/pkgs/os-specific/linux/pam_u2f/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libfido2, pam, openssl }:
+{ lib, stdenv, fetchurl, pkgconfig, libfido2, pam, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "pam_u2f";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     configureFlagsArray+=("--with-pam-dir=$out/lib/security")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://developers.yubico.com/pam-u2f/";
     description = "A PAM module for allowing authentication with a U2F device";
     license = licenses.bsd2;
diff --git a/pkgs/os-specific/linux/paxctl/default.nix b/pkgs/os-specific/linux/paxctl/default.nix
index 754f6bcac333f..da9928a66e3b4 100644
--- a/pkgs/os-specific/linux/paxctl/default.nix
+++ b/pkgs/os-specific/linux/paxctl/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, elf-header }:
+{ fetchurl, lib, stdenv, elf-header }:
 
 stdenv.mkDerivation rec {
   pname = "paxctl";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for controlling PaX flags on a per binary basis";
     homepage    = "https://pax.grsecurity.net";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/paxtest/default.nix b/pkgs/os-specific/linux/paxtest/default.nix
index 6bd59e1e7fd09..aae8c1296c630 100644
--- a/pkgs/os-specific/linux/paxtest/default.nix
+++ b/pkgs/os-specific/linux/paxtest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, paxctl }:
+{ lib, stdenv, fetchurl, paxctl }:
 
 stdenv.mkDerivation rec {
   pname = "paxtest";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   makeFlags    = [ "PAXBIN=${paxctl}/bin/paxctl" "BINDIR=$(out)/bin" "RUNDIR=$(out)/lib/paxtest" ];
   installFlags = [ "DESTDIR=\"\"" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test various memory protection measures";
     license     = licenses.gpl2;
     platforms   = platforms.linux;
diff --git a/pkgs/os-specific/linux/pcimem/default.nix b/pkgs/os-specific/linux/pcimem/default.nix
index b559bd98b9c9f..dda4d0fff0b92 100644
--- a/pkgs/os-specific/linux/pcimem/default.nix
+++ b/pkgs/os-specific/linux/pcimem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "pcimem";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -D README "$doc/doc/README"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple method of reading and writing to memory registers on a PCI card";
     homepage = "https://github.com/billfarrow/pcimem";
     license = licenses.gpl2Only;
diff --git a/pkgs/os-specific/linux/pcm/default.nix b/pkgs/os-specific/linux/pcm/default.nix
index 66f5dcf338a3a..f791661d2ef1a 100644
--- a/pkgs/os-specific/linux/pcm/default.nix
+++ b/pkgs/os-specific/linux/pcm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   version = "202011";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp pcm*.x $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Processor counter monitor";
     homepage = "https://www.intel.com/software/pcm";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/perf-tools/default.nix b/pkgs/os-specific/linux/perf-tools/default.nix
index 1a18c6ea27213..7d5d6d59ea84d 100644
--- a/pkgs/os-specific/linux/perf-tools/default.nix
+++ b/pkgs/os-specific/linux/perf-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl }:
+{ lib, stdenv, fetchFromGitHub, perl }:
 
 stdenv.mkDerivation {
   name = "perf-tools-20171219";
@@ -34,7 +34,7 @@ stdenv.mkDerivation {
       mv $d/man $out/share/
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     homepage = "https://github.com/brendangregg/perf-tools";
     description = "Performance analysis tools based on Linux perf_events (aka perf) and ftrace";
diff --git a/pkgs/os-specific/linux/phc-intel/default.nix b/pkgs/os-specific/linux/phc-intel/default.nix
index 2d5d149292cd6..4b4c86aa91642 100644
--- a/pkgs/os-specific/linux/phc-intel/default.nix
+++ b/pkgs/os-specific/linux/phc-intel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, kernel, which }:
+{ lib, stdenv, fetchurl, kernel, which }:
 
 # Don't bother with older versions, though some might even work:
 assert stdenv.lib.versionAtLeast kernel.version "4.10";
@@ -36,7 +36,7 @@ in stdenv.mkDerivation rec {
     install -m 644 *.ko $out/lib/modules/${kernel.modDirVersion}/extra/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Undervolting kernel driver for Intel processors";
     longDescription = ''
       PHC is a Linux kernel patch to undervolt processors. This can divide the
diff --git a/pkgs/os-specific/linux/piper/default.nix b/pkgs/os-specific/linux/piper/default.nix
index 641c8b8ba81f0..caa6b1848e7d0 100644
--- a/pkgs/os-specific/linux/piper/default.nix
+++ b/pkgs/os-specific/linux/piper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, meson, ninja, pkgconfig, gettext, fetchFromGitHub, python3
+{ lib, stdenv, meson, ninja, pkgconfig, gettext, fetchFromGitHub, python3
 , wrapGAppsHook, gtk3, glib, desktop-file-utils, appstream-glib, gnome3
 , gobject-introspection }:
 
@@ -28,7 +28,7 @@ python3.pkgs.buildPythonApplication rec {
     patchShebangs meson_install.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK frontend for ratbagd mouse config daemon";
     homepage    = "https://github.com/libratbag/piper";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/pktgen/default.nix b/pkgs/os-specific/linux/pktgen/default.nix
index a883935b7b954..23b9b9426df4a 100644
--- a/pkgs/os-specific/linux/pktgen/default.nix
+++ b/pkgs/os-specific/linux/pktgen/default.nix
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/include $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Traffic generator powered by DPDK";
     homepage = "http://dpdk.org/";
     license = licenses.bsdOriginal;
diff --git a/pkgs/os-specific/linux/ply/default.nix b/pkgs/os-specific/linux/ply/default.nix
index 1d98cfb0cd183..0433a7a0718c3 100644
--- a/pkgs/os-specific/linux/ply/default.nix
+++ b/pkgs/os-specific/linux/ply/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel, fetchFromGitHub, autoreconfHook, yacc, flex, p7zip, rsync }:
+{ lib, stdenv, kernel, fetchFromGitHub, autoreconfHook, yacc, flex, p7zip, rsync }:
 
 assert kernel != null -> stdenv.lib.versionAtLeast kernel.version "4.0";
 
@@ -33,7 +33,7 @@ in stdenv.mkDerivation {
     ./autogen.sh --prefix=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "dynamic Tracing in Linux";
     homepage = "https://wkz.github.io/ply/";
     license = [ licenses.gpl2 ];
diff --git a/pkgs/os-specific/linux/plymouth/default.nix b/pkgs/os-specific/linux/plymouth/default.nix
index 7a6c227f401f7..88575580e2a28 100644
--- a/pkgs/os-specific/linux/plymouth/default.nix
+++ b/pkgs/os-specific/linux/plymouth/default.nix
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     "plymouthd_confdir=$(out)/etc/plymouth"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.freedesktop.org/wiki/Software/Plymouth";
     description = "A graphical boot animation";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/policycoreutils/default.nix b/pkgs/os-specific/linux/policycoreutils/default.nix
index f9e3a7fb5d4f6..7e2ff29325a81 100644
--- a/pkgs/os-specific/linux/policycoreutils/default.nix
+++ b/pkgs/os-specific/linux/policycoreutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gettext, libsepol, libselinux, libsemanage }:
+{ lib, stdenv, fetchurl, gettext, libsepol, libselinux, libsemanage }:
 
 stdenv.mkDerivation rec {
   pname = "policycoreutils";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     "MAN5DIR=$(out)/share/man/man5"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SELinux policy core utilities";
     license = licenses.gpl2;
     inherit (libsepol.meta) homepage platforms maintainers;
diff --git a/pkgs/os-specific/linux/powertop/default.nix b/pkgs/os-specific/linux/powertop/default.nix
index 22e70fc0b6589..a8733ac1f8af2 100644
--- a/pkgs/os-specific/linux/powertop/default.nix
+++ b/pkgs/os-specific/linux/powertop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, gettext, libnl, ncurses, pciutils, pkgconfig, zlib }:
+{ lib, stdenv, fetchurl, fetchpatch, gettext, libnl, ncurses, pciutils, pkgconfig, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "powertop";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     substituteInPlace src/tuning/bluetooth.cpp --replace "/usr/bin/hcitool" "hcitool"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Analyze power consumption on Intel-based laptops";
     homepage = "https://01.org/powertop";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/prl-tools/default.nix b/pkgs/os-specific/linux/prl-tools/default.nix
index 9b0e38198a33d..14e43b09e3099 100644
--- a/pkgs/os-specific/linux/prl-tools/default.nix
+++ b/pkgs/os-specific/linux/prl-tools/default.nix
@@ -156,7 +156,7 @@ stdenv.mkDerivation rec {
   dontStrip = true;
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parallels Tools for Linux guests";
     homepage = "https://parallels.com";
     platforms = [ "i686-linux" "x86_64-linux" ];
diff --git a/pkgs/os-specific/linux/procdump/default.nix b/pkgs/os-specific/linux/procdump/default.nix
index 74ee1533e4616..75ca2cb165e02 100644
--- a/pkgs/os-specific/linux/procdump/default.nix
+++ b/pkgs/os-specific/linux/procdump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bash, coreutils, gdb, zlib }:
+{ lib, stdenv, fetchFromGitHub, bash, coreutils, gdb, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "procdump";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     runHook postInstallCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Linux version of the ProcDump Sysinternals tool";
     homepage = "https://github.com/Microsoft/ProcDump-for-Linux";
     license = licenses.mit;
diff --git a/pkgs/os-specific/linux/pscircle/default.nix b/pkgs/os-specific/linux/pscircle/default.nix
index 9dd4ba6cd3731..f6ee22ee0fc6d 100644
--- a/pkgs/os-specific/linux/pscircle/default.nix
+++ b/pkgs/os-specific/linux/pscircle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, meson, pkgconfig, ninja, cairo }:
+{ lib, stdenv, fetchFromGitLab, meson, pkgconfig, ninja, cairo }:
 
 stdenv.mkDerivation rec {
   pname = "pscircle";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       ninja
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/mildlyparallel/pscircle";
     description = "Visualize Linux processes in a form of a radial tree";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/psftools/default.nix b/pkgs/os-specific/linux/psftools/default.nix
index 5a19fbec24d52..f7bcc2fd6add6 100644
--- a/pkgs/os-specific/linux/psftools/default.nix
+++ b/pkgs/os-specific/linux/psftools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 stdenv.mkDerivation rec {
   pname = "psftools";
   version = "1.0.14";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
   };
   outputs = ["out" "man" "dev" "lib"];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.seasip.info/Unix/PSF";
     description = "Conversion tools for .PSF fonts";
     longDescription = ''
diff --git a/pkgs/os-specific/linux/psmisc/default.nix b/pkgs/os-specific/linux/psmisc/default.nix
index 4379ee3ae49fc..3e03ec4ea6726 100644
--- a/pkgs/os-specific/linux/psmisc/default.nix
+++ b/pkgs/os-specific/linux/psmisc/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitLab, autoconf, automake, gettext, ncurses}:
+{lib, stdenv, fetchFromGitLab, autoconf, automake, gettext, ncurses}:
 
 stdenv.mkDerivation rec {
   pname = "psmisc";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/psmisc/psmisc";
     description = "A set of small useful utilities that use the proc filesystem (such as fuser, killall and pstree)";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/radeontools/default.nix b/pkgs/os-specific/linux/radeontools/default.nix
index d2c3c11c93901..0d50c6b41d877 100644
--- a/pkgs/os-specific/linux/radeontools/default.nix
+++ b/pkgs/os-specific/linux/radeontools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , autoreconfHook
 , pciutils
 , pkgconfig
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ xorg.libpciaccess ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lowlevel tools to tweak register and dump state on radeon GPUs";
     homepage = "https://airlied.livejournal.com/";
     license = licenses.zlib;
diff --git a/pkgs/os-specific/linux/radeontop/default.nix b/pkgs/os-specific/linux/radeontop/default.nix
index f55b09f6991b6..f1655c94b84d9 100644
--- a/pkgs/os-specific/linux/radeontop/default.nix
+++ b/pkgs/os-specific/linux/radeontop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, gettext, makeWrapper
+{ lib, stdenv, fetchFromGitHub, pkgconfig, gettext, makeWrapper
 , ncurses, libdrm, libpciaccess, libxcb }:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Top-like tool for viewing AMD Radeon GPU utilization";
     longDescription = ''
       View GPU utilization, both for the total activity percent and individual
diff --git a/pkgs/os-specific/linux/rdma-core/default.nix b/pkgs/os-specific/linux/rdma-core/default.nix
index 339a6cbbf2909..fd7148b7eb634 100644
--- a/pkgs/os-specific/linux/rdma-core/default.nix
+++ b/pkgs/os-specific/linux/rdma-core/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, docutils
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, docutils
 , pandoc, ethtool, iproute, libnl, udev, python, perl
 , makeWrapper
 } :
@@ -43,7 +43,7 @@ in stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RDMA Core Userspace Libraries and Daemons";
     homepage = "https://github.com/linux-rdma/rdma-core";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/read-edid/default.nix b/pkgs/os-specific/linux/read-edid/default.nix
index 36020d831aca8..24ad067497663 100644
--- a/pkgs/os-specific/linux/read-edid/default.nix
+++ b/pkgs/os-specific/linux/read-edid/default.nix
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     substituteInPlace CMakeLists.txt --replace 'COPYING' 'LICENSE'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for reading and parsing EDID data from monitors";
     homepage = "http://www.polypux.org/projects/read-edid/";
     license = licenses.bsd2; # Quoted: "This is an unofficial license. Let's call it BSD-like."
diff --git a/pkgs/os-specific/linux/regionset/default.nix b/pkgs/os-specific/linux/regionset/default.nix
index 15030d1b19a28..f685eec194888 100644
--- a/pkgs/os-specific/linux/regionset/default.nix
+++ b/pkgs/os-specific/linux/regionset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let version = "0.2"; in
 stdenv.mkDerivation {
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     install -Dm644 {.,$out/share/man/man8}/regionset.8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     homepage = "http://linvdr.org/projects/regionset/";
     description = "Tool for changing the region code setting of DVD players";
diff --git a/pkgs/os-specific/linux/rewritefs/default.nix b/pkgs/os-specific/linux/rewritefs/default.nix
index a852e43b38f8f..2c50c491d43f3 100644
--- a/pkgs/os-specific/linux/rewritefs/default.nix
+++ b/pkgs/os-specific/linux/rewritefs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, fuse, pcre }: 
+{ lib, stdenv, fetchFromGitHub, pkgconfig, fuse, pcre }: 
 
 stdenv.mkDerivation {
   pname = "rewritefs";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
 
   preConfigure = "substituteInPlace Makefile --replace /usr/local $out";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''A FUSE filesystem intended to be used
       like Apache mod_rewrite'';
     homepage    = "https://github.com/sloonz/rewritefs";
diff --git a/pkgs/os-specific/linux/rfkill/udev.nix b/pkgs/os-specific/linux/rfkill/udev.nix
index a24c947673de2..e1a14a80162c2 100644
--- a/pkgs/os-specific/linux/rfkill/udev.nix
+++ b/pkgs/os-specific/linux/rfkill/udev.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll }:
+{ lib, stdenv, substituteAll }:
 
 # Provides a facility to hook into rfkill changes.
 #
@@ -47,7 +47,7 @@ in stdenv.mkDerivation {
     cp ${rfkillHook} "$out/bin/rfkill-hook.sh"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://wireless.kernel.org/en/users/Documentation/rfkill";
     description = "Rules+hook for udev to catch rfkill state changes";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/rtkit/default.nix b/pkgs/os-specific/linux/rtkit/default.nix
index b3f73e6c3bba7..8138fb9c34650 100644
--- a/pkgs/os-specific/linux/rtkit/default.nix
+++ b/pkgs/os-specific/linux/rtkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , meson, ninja, pkgconfig, unixtools
 , dbus, libcap, polkit, systemd
 }:
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     "-Dsystemd_systemunitdir=${placeholder "out"}/etc/systemd/system"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/heftig/rtkit";
     description = "A daemon that hands out real-time priority to processes";
     license = with licenses; [ gpl3 bsd0 ]; # lib is bsd license
diff --git a/pkgs/os-specific/linux/rtl8812au/default.nix b/pkgs/os-specific/linux/rtl8812au/default.nix
index 9b2bcf3b91ce9..0051e689794ce 100644
--- a/pkgs/os-specific/linux/rtl8812au/default.nix
+++ b/pkgs/os-specific/linux/rtl8812au/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel, bc, nukeReferences }:
+{ lib, stdenv, fetchFromGitHub, kernel, bc, nukeReferences }:
 
 stdenv.mkDerivation rec {
   name = "rtl8812au-${kernel.version}-${version}";
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     nuke-refs $out/lib/modules/*/kernel/net/wireless/*.ko
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Driver for Realtek 802.11ac, rtl8812au, provides the 8812au mod";
     homepage = "https://github.com/gordboy/rtl8812au-5.6.4.2";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/rtl8814au/default.nix b/pkgs/os-specific/linux/rtl8814au/default.nix
index 99d22e2f99985..a710ef34e9565 100644
--- a/pkgs/os-specific/linux/rtl8814au/default.nix
+++ b/pkgs/os-specific/linux/rtl8814au/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 stdenv.mkDerivation rec {
   name = "rtl8814au-${kernel.version}-${version}";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/lib/modules/${kernel.modDirVersion}/kernel/net/wireless/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Realtek 8814AU USB WiFi driver";
     homepage = "https://github.com/zebulon2/rtl8814au";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/rtl8821au/default.nix b/pkgs/os-specific/linux/rtl8821au/default.nix
index f3d68cf79194d..908220a1f28d0 100644
--- a/pkgs/os-specific/linux/rtl8821au/default.nix
+++ b/pkgs/os-specific/linux/rtl8821au/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel, bc, nukeReferences }:
+{ lib, stdenv, fetchFromGitHub, kernel, bc, nukeReferences }:
 
 stdenv.mkDerivation rec {
   name = "rtl8821au-${kernel.version}-${version}";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     nuke-refs $out/lib/modules/*/kernel/net/wireless/*.ko
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "rtl8821AU, rtl8812AU and rtl8811AU chipset driver with firmware";
     homepage = "https://github.com/zebulon2/rtl8812au";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/rtl8821ce/default.nix b/pkgs/os-specific/linux/rtl8821ce/default.nix
index ae6586262a5c3..81c129fae3ebe 100644
--- a/pkgs/os-specific/linux/rtl8821ce/default.nix
+++ b/pkgs/os-specific/linux/rtl8821ce/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel, bc }:
+{ lib, stdenv, fetchFromGitHub, kernel, bc }:
 stdenv.mkDerivation rec {
   name = "rtl8821ce-${kernel.version}-${version}";
   version = "5.5.2_34066.20200325";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/lib/modules/${kernel.modDirVersion}/kernel/net/wireless/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Realtek rtl8821ce driver";
     homepage = "https://github.com/tomaspinho/rtl8821ce";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/rtl8821cu/default.nix b/pkgs/os-specific/linux/rtl8821cu/default.nix
index 35dbd1a9ee100..20bb590895b93 100644
--- a/pkgs/os-specific/linux/rtl8821cu/default.nix
+++ b/pkgs/os-specific/linux/rtl8821cu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel, bc }:
+{ lib, stdenv, fetchFromGitHub, kernel, bc }:
 stdenv.mkDerivation rec {
   name = "rtl8821cu-${kernel.version}-${version}";
   version = "unstable-2020-12-21";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/lib/modules/${kernel.modDirVersion}/kernel/net/wireless/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Realtek rtl8821cu driver";
     homepage = "https://github.com/brektrou/rtl8821CU";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/rtl88x2bu/default.nix b/pkgs/os-specific/linux/rtl88x2bu/default.nix
index c2b5eb1cdb4cc..fb94b14d9eab4 100644
--- a/pkgs/os-specific/linux/rtl88x2bu/default.nix
+++ b/pkgs/os-specific/linux/rtl88x2bu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, kernel, bc }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, kernel, bc }:
 
 stdenv.mkDerivation rec {
   name = "rtl88x2bu-${kernel.version}-${version}";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/lib/modules/${kernel.modDirVersion}/kernel/net/wireless/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Realtek rtl88x2bu driver";
     homepage = "https://github.com/cilynx/rtl88x2bu";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/rtl88xxau-aircrack/default.nix b/pkgs/os-specific/linux/rtl88xxau-aircrack/default.nix
index a86d76a3be592..c37c9502d2db1 100644
--- a/pkgs/os-specific/linux/rtl88xxau-aircrack/default.nix
+++ b/pkgs/os-specific/linux/rtl88xxau-aircrack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 
 stdenv.mkDerivation rec {
   name = "rtl88xxau-aircrack-${kernel.version}-${version}";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/lib/modules/${kernel.modDirVersion}/kernel/net/wireless/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Aircrack-ng kernel module for Realtek 88XXau network cards\n(8811au, 8812au, 8814au and 8821au chipsets) with monitor mode and injection support.";
     homepage = "https://github.com/aircrack-ng/rtl8812au";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/schedtool/default.nix b/pkgs/os-specific/linux/schedtool/default.nix
index 98663a5ab41e0..98d9248e3f425 100644
--- a/pkgs/os-specific/linux/schedtool/default.nix
+++ b/pkgs/os-specific/linux/schedtool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "schedtool";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" "DESTPREFIX=" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Query or alter a process' scheduling policy under Linux";
     homepage = "https://freequaos.host.sk/schedtool/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/sd-switch/default.nix b/pkgs/os-specific/linux/sd-switch/default.nix
index 7cbad8d6df3bf..026488a24ded7 100644
--- a/pkgs/os-specific/linux/sd-switch/default.nix
+++ b/pkgs/os-specific/linux/sd-switch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, rustPlatform, pkg-config, dbus }:
+{ lib, stdenv, fetchFromGitLab, rustPlatform, pkg-config, dbus }:
 
 rustPlatform.buildRustPackage rec {
   pname = "sd-switch";
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
   nativeBuildInputs = [ pkg-config ];
   buildInputs = [ dbus ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A systemd unit switcher for Home Manager";
     homepage = "https://gitlab.com/rycee/sd-switch";
     license = licenses.gpl3Plus;
diff --git a/pkgs/os-specific/linux/sdparm/default.nix b/pkgs/os-specific/linux/sdparm/default.nix
index e0392e442bf51..08e61a98f6b9d 100644
--- a/pkgs/os-specific/linux/sdparm/default.nix
+++ b/pkgs/os-specific/linux/sdparm/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "sdparm";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1nqjc4w2w47zavcbf5xmm53x1zbwgljaw1lpajcdi537cgy32fa8";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://sg.danny.cz/sg/sdparm.html";
     description = "A utility to access SCSI device parameters";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/semodule-utils/default.nix b/pkgs/os-specific/linux/semodule-utils/default.nix
index bf1f36835b476..c1243582a5174 100644
--- a/pkgs/os-specific/linux/semodule-utils/default.nix
+++ b/pkgs/os-specific/linux/semodule-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libsepol }:
+{ lib, stdenv, fetchurl, libsepol }:
 
 stdenv.mkDerivation rec {
   pname = "semodule-utils";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "LIBSEPOLA=${stdenv.lib.getLib libsepol}/lib/libsepol.a"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SELinux policy core utilities (packaging additions)";
     license = licenses.gpl2;
     inherit (libsepol.meta) homepage platforms;
diff --git a/pkgs/os-specific/linux/sepolgen/default.nix b/pkgs/os-specific/linux/sepolgen/default.nix
index 53250b345e835..f7ef1cb9c3a74 100644
--- a/pkgs/os-specific/linux/sepolgen/default.nix
+++ b/pkgs/os-specific/linux/sepolgen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libsepol, python }:
+{ lib, stdenv, fetchurl, libsepol, python }:
 
 stdenv.mkDerivation rec {
   pname = "sepolgen";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     makeFlagsArray+=("PYTHONLIBDIR=lib/${python.libPrefix}/site-packages")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (libsepol.meta) homepage platforms maintainers;
     description = "SELinux policy generation library";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/service-wrapper/default.nix b/pkgs/os-specific/linux/service-wrapper/default.nix
index 150262158da4c..381f0699697a4 100644
--- a/pkgs/os-specific/linux/service-wrapper/default.nix
+++ b/pkgs/os-specific/linux/service-wrapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, runCommand, substituteAll, coreutils }:
+{ lib, stdenv, runCommand, substituteAll, coreutils }:
 
 let
   name = "service-wrapper-${version}";
@@ -12,7 +12,7 @@ runCommand name {
     inherit coreutils;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A convenient wrapper for the systemctl commands, borrow from Ubuntu";
     license     = licenses.gpl2Plus;
     platforms   = platforms.linux;
diff --git a/pkgs/os-specific/linux/shadow/default.nix b/pkgs/os-specific/linux/shadow/default.nix
index 59cc59d7714d4..a6d288e0e7209 100644
--- a/pkgs/os-specific/linux/shadow/default.nix
+++ b/pkgs/os-specific/linux/shadow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, nixosTests, fetchpatch, fetchFromGitHub, autoreconfHook, libxslt
+{ lib, stdenv, nixosTests, fetchpatch, fetchFromGitHub, autoreconfHook, libxslt
 , libxml2 , docbook_xml_dtd_45, docbook_xsl, itstool, flex, bison
 , pam ? null, glibcCross ? null
 }:
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
       mv $out/bin/su $su/bin
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/shadow-maint";
     description = "Suite containing authentication-related tools such as passwd and su";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/sssd/default.nix b/pkgs/os-specific/linux/sssd/default.nix
index 05866f9426923..0398757c57e9f 100644
--- a/pkgs/os-specific/linux/sssd/default.nix
+++ b/pkgs/os-specific/linux/sssd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, glibc, augeas, dnsutils, c-ares, curl,
+{ lib, stdenv, fetchurl, fetchpatch, glibc, augeas, dnsutils, c-ares, curl,
   cyrus_sasl, ding-libs, libnl, libunistring, nss, samba, nfs-utils, doxygen,
   python, python3, pam, popt, talloc, tdb, tevent, pkgconfig, ldb, openldap,
   pcre, kerberos, cifs-utils, glib, keyutils, dbus, fakeroot, libxslt, libxml2,
@@ -93,7 +93,7 @@ stdenv.mkDerivation rec {
     find "$out" -depth -type d -exec rmdir --ignore-fail-on-non-empty {} \;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System Security Services Daemon";
     homepage = "https://fedorahosted.org/sssd/";
     license = licenses.gpl3;
diff --git a/pkgs/os-specific/linux/syscall_limiter/default.nix b/pkgs/os-specific/linux/syscall_limiter/default.nix
index 0354abf46e1a6..329ec522c422e 100644
--- a/pkgs/os-specific/linux/syscall_limiter/default.nix
+++ b/pkgs/os-specific/linux/syscall_limiter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , libseccomp
 , perl
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
       --replace which ${which}/bin/which
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Start Linux programs with only selected syscalls enabled";
     homepage    = "https://github.com/vi/syscall_limiter";
     license     = licenses.mit;
diff --git a/pkgs/os-specific/linux/sysklogd/default.nix b/pkgs/os-specific/linux/sysklogd/default.nix
index f93e9012e05de..454527321fb13 100644
--- a/pkgs/os-specific/linux/sysklogd/default.nix
+++ b/pkgs/os-specific/linux/sysklogd/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "sysklogd-1.5.1";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
 
   preInstall = "mkdir -p $out/share/man/man5/ $out/share/man/man8/ $out/sbin";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A system logging daemon";
     platforms = platforms.linux;
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/syslinux/default.nix b/pkgs/os-specific/linux/syslinux/default.nix
index 559fb6219b434..cf263281da274 100644
--- a/pkgs/os-specific/linux/syslinux/default.nix
+++ b/pkgs/os-specific/linux/syslinux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchurl, fetchpatch, nasm, perl, python3, libuuid, mtools, makeWrapper }:
+{ lib, stdenv, fetchgit, fetchurl, fetchpatch, nasm, perl, python3, libuuid, mtools, makeWrapper }:
 
 stdenv.mkDerivation {
   pname = "syslinux";
@@ -91,7 +91,7 @@ stdenv.mkDerivation {
     rm -rf $out/share/syslinux/com32
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.syslinux.org/";
     description = "A lightweight bootloader";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/system76-acpi/default.nix b/pkgs/os-specific/linux/system76-acpi/default.nix
index b7c0e27669da4..f642fad69787d 100644
--- a/pkgs/os-specific/linux/system76-acpi/default.nix
+++ b/pkgs/os-specific/linux/system76-acpi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 let
   version = "1.0.1";
   sha256 = "0jmm9h607f7k20yassm6af9mh5l00yih5248wwv4i05bd68yw3p5";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     mv lib/udev/hwdb.d/* $out/lib/udev/hwdb.d
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = [ maintainers.khumba ];
     license = [ licenses.gpl2Only ];
     platforms = [ "i686-linux" "x86_64-linux" ];
diff --git a/pkgs/os-specific/linux/system76-io/default.nix b/pkgs/os-specific/linux/system76-io/default.nix
index dac1e2db1e383..fb697430f61c1 100644
--- a/pkgs/os-specific/linux/system76-io/default.nix
+++ b/pkgs/os-specific/linux/system76-io/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 let
   version = "1.0.1";
   sha256 = "0qkgkkjy1isv6ws6hrcal75dxjz98rpnvqbm7agdcc6yv0c17wwh";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     install -D system76-io.ko $out/lib/modules/${kernel.modDirVersion}/misc/system76-io.ko
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = [ maintainers.khumba ];
     license = [ licenses.gpl2Plus ];
     platforms = [ "i686-linux" "x86_64-linux" ];
diff --git a/pkgs/os-specific/linux/system76/default.nix b/pkgs/os-specific/linux/system76/default.nix
index 02eca1d5bbd57..84c153c2f82ec 100644
--- a/pkgs/os-specific/linux/system76/default.nix
+++ b/pkgs/os-specific/linux/system76/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel }:
+{ lib, stdenv, fetchFromGitHub, kernel }:
 let
   version = "1.0.9";
   sha256 = "0i4825y2vd679kdjv30ifzj1i1066d3x37z4lgk39hx16993k162";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     mv lib/udev/hwdb.d/* $out/lib/udev/hwdb.d
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = [ maintainers.khumba ];
     license = [ licenses.gpl2Plus ];
     platforms = [ "i686-linux" "x86_64-linux" ];
diff --git a/pkgs/os-specific/linux/targetcli/default.nix b/pkgs/os-specific/linux/targetcli/default.nix
index 94920c4012a40..ba1c063cc054f 100644
--- a/pkgs/os-specific/linux/targetcli/default.nix
+++ b/pkgs/os-specific/linux/targetcli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchFromGitHub }:
+{ lib, stdenv, python3, fetchFromGitHub }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "targetcli";
@@ -18,7 +18,7 @@ python3.pkgs.buildPythonApplication rec {
     install -D targetclid.8 -t $out/share/man/man8/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command shell for managing the Linux LIO kernel target";
     homepage = "https://github.com/open-iscsi/targetcli-fb";
     license = licenses.asl20;
diff --git a/pkgs/os-specific/linux/tiptop/default.nix b/pkgs/os-specific/linux/tiptop/default.nix
index 03db9e3bb0eef..c6870d2a4c447 100644
--- a/pkgs/os-specific/linux/tiptop/default.nix
+++ b/pkgs/os-specific/linux/tiptop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, libxml2, ncurses, bison, flex }:
+{ lib, stdenv, fetchurl, fetchpatch, libxml2, ncurses, bison, flex }:
 
 stdenv.mkDerivation rec {
   pname = "tiptop";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-I${libxml2.dev}/include/libxml2";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Performance monitoring tool for Linux";
     homepage = "http://tiptop.gforge.inria.fr";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/tmon/default.nix b/pkgs/os-specific/linux/tmon/default.nix
index f8438f8d40f0a..5a14d3d2ee340 100644
--- a/pkgs/os-specific/linux/tmon/default.nix
+++ b/pkgs/os-specific/linux/tmon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel, ncurses }:
+{ lib, stdenv, kernel, ncurses }:
 
 stdenv.mkDerivation {
   name = "tmon-${kernel.version}";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Monitoring and Testing Tool for Linux kernel thermal subsystem";
     homepage = "https://www.kernel.org/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/tomb/default.nix b/pkgs/os-specific/linux/tomb/default.nix
index 0c5a02061b82d..438934f07d5b5 100644
--- a/pkgs/os-specific/linux/tomb/default.nix
+++ b/pkgs/os-specific/linux/tomb/default.nix
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : $out/bin:${lib.makeBinPath [ cryptsetup gettext gnupg pinentry util-linux e2fsprogs ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "File encryption on GNU/Linux";
     homepage    = "https://www.dyne.org/software/tomb/";
     license     = licenses.gpl3;
diff --git a/pkgs/os-specific/linux/trace-cmd/default.nix b/pkgs/os-specific/linux/trace-cmd/default.nix
index ddd4117021513..27dbc6f583abe 100644
--- a/pkgs/os-specific/linux/trace-cmd/default.nix
+++ b/pkgs/os-specific/linux/trace-cmd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, asciidoc, docbook_xsl, libxslt }:
+{ lib, stdenv, fetchgit, asciidoc, docbook_xsl, libxslt }:
 stdenv.mkDerivation {
   pname = "trace-cmd";
   version = "2.9-dev";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     "BASH_COMPLETE_DIR=${placeholder "out"}/share/bash-completion/completions"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "User-space tools for the Linux kernel ftrace subsystem";
     homepage    = "https://kernelshark.org/";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/trace-cmd/kernelshark.nix b/pkgs/os-specific/linux/trace-cmd/kernelshark.nix
index 3a280b8af0bec..4db4d64bc939b 100644
--- a/pkgs/os-specific/linux/trace-cmd/kernelshark.nix
+++ b/pkgs/os-specific/linux/trace-cmd/kernelshark.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchgit, qtbase, cmake, asciidoc, docbook_xsl, json_c, mesa_glu, freeglut, trace-cmd, pkg-config }:
+{ lib, stdenv, mkDerivation, fetchgit, qtbase, cmake, asciidoc, docbook_xsl, json_c, mesa_glu, freeglut, trace-cmd, pkg-config }:
 mkDerivation {
   pname = "kernelshark";
   version = "1.1.0";
@@ -30,7 +30,7 @@ mkDerivation {
     pushd kernel-shark/build
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI for trace-cmd which is an interface for the Linux kernel ftrace subsystem";
     homepage    = "https://kernelshark.org/";
     license     = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/trezor-udev-rules/default.nix b/pkgs/os-specific/linux/trezor-udev-rules/default.nix
index c2be813737688..e5d20171c5cbe 100644
--- a/pkgs/os-specific/linux/trezor-udev-rules/default.nix
+++ b/pkgs/os-specific/linux/trezor-udev-rules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "trezor-udev-rules";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp 51-trezor.rules $out/lib/udev/rules.d/51-trezor.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Udev rules for Trezor";
     license = licenses.gpl3;
     maintainers = with maintainers; [ prusnak ];
diff --git a/pkgs/os-specific/linux/trinity/default.nix b/pkgs/os-specific/linux/trinity/default.nix
index 6d9848ab7126b..9bfe0e942eebb 100644
--- a/pkgs/os-specific/linux/trinity/default.nix
+++ b/pkgs/os-specific/linux/trinity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "trinity";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Linux System call fuzz tester";
     homepage = "https://codemonkey.org.uk/projects/trinity/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/turbostat/default.nix b/pkgs/os-specific/linux/turbostat/default.nix
index 035dddcc4ec03..fb1bcf582fbae 100644
--- a/pkgs/os-specific/linux/turbostat/default.nix
+++ b/pkgs/os-specific/linux/turbostat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel, libcap }:
+{ lib, stdenv, kernel, libcap }:
 
 stdenv.mkDerivation {
   pname = "turbostat";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
     cd tools/power/x86/turbostat
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Report processor frequency and idle statistics";
     homepage = "https://www.kernel.org/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/tuxedo-keyboard/default.nix b/pkgs/os-specific/linux/tuxedo-keyboard/default.nix
index b67bf2d3dab6f..3187ba6d4dbd6 100644
--- a/pkgs/os-specific/linux/tuxedo-keyboard/default.nix
+++ b/pkgs/os-specific/linux/tuxedo-keyboard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel, kmod }:
+{ lib, stdenv, fetchFromGitHub, kernel, kmod }:
 
 stdenv.mkDerivation rec {
   pname = "tuxedo-keyboard-${kernel.version}";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     mv src/tuxedo_keyboard.ko $out/lib/modules/${kernel.modDirVersion}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Full color keyboard driver for tuxedo computers laptops";
     homepage = "https://github.com/tuxedocomputers/tuxedo-keyboard/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/uclibc/default.nix b/pkgs/os-specific/linux/uclibc/default.nix
index 125a8608c1533..03798b9fe5c2c 100644
--- a/pkgs/os-specific/linux/uclibc/default.nix
+++ b/pkgs/os-specific/linux/uclibc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages
+{ lib, stdenv, buildPackages
 , fetchurl, linuxHeaders, libiconvReal
 , extraConfig ? ""
 }:
@@ -104,7 +104,7 @@ stdenv.mkDerivation {
     libiconv = libiconvReal;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://uclibc-ng.org";
     description = "A small implementation of the C library";
     maintainers = with maintainers; [ rasendubi ];
diff --git a/pkgs/os-specific/linux/udisks/1-default.nix b/pkgs/os-specific/linux/udisks/1-default.nix
index 725706f9b0eb1..8f48ae017f0f5 100644
--- a/pkgs/os-specific/linux/udisks/1-default.nix
+++ b/pkgs/os-specific/linux/udisks/1-default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, sg3_utils, udev, glib, dbus, dbus-glib
+{ lib, stdenv, fetchurl, pkgconfig, sg3_utils, udev, glib, dbus, dbus-glib
 , polkit, parted, lvm2, libatasmart, intltool, libuuid, mdadm
 , libxslt, docbook_xsl, util-linux, libgudev }:
 
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--localstatedir=/var" "--enable-lvm2" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.freedesktop.org/wiki/Software/udisks";
     description = "A daemon and command-line utility for querying and manipulating storage devices";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/udisks/2-default.nix b/pkgs/os-specific/linux/udisks/2-default.nix
index b47d31ab6fdc5..1152ab7ca1e0f 100644
--- a/pkgs/os-specific/linux/udisks/2-default.nix
+++ b/pkgs/os-specific/linux/udisks/2-default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, substituteAll, libtool, pkgconfig, gettext, gnused
+{ lib, stdenv, fetchFromGitHub, fetchpatch, substituteAll, libtool, pkgconfig, gettext, gnused
 , gtk-doc, acl, systemd, glib, libatasmart, polkit, coreutils, bash, which
 , expat, libxslt, docbook_xsl, util-linux, mdadm, libgudev, libblockdev, parted
 , gobject-introspection, docbook_xml_dtd_412, docbook_xml_dtd_43, autoconf, automake
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon, tools and libraries to access and manipulate disks, storage devices and technologies";
     homepage = "https://www.freedesktop.org/wiki/Software/udisks/";
     license = with licenses; [ lgpl2Plus gpl2Plus ]; # lgpl2Plus for the library, gpl2Plus for the tools & daemon
diff --git a/pkgs/os-specific/linux/undervolt/default.nix b/pkgs/os-specific/linux/undervolt/default.nix
index 2f03ee8c8201c..5f4ffb50c07bc 100644
--- a/pkgs/os-specific/linux/undervolt/default.nix
+++ b/pkgs/os-specific/linux/undervolt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   version = "0.3.0";
@@ -11,7 +11,7 @@ python3Packages.buildPythonApplication rec {
     sha256 = "1aybk8vbb4745raz7rvpkk6b98xrdiwjhkpbv3kwsgsr9sj42lp0";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/georgewhewell/undervolt/";
     description = "A program for undervolting Intel CPUs on Linux";
 
diff --git a/pkgs/os-specific/linux/untie/default.nix b/pkgs/os-specific/linux/untie/default.nix
index 9ca1c37e11b4f..947ae2ca8d8b5 100644
--- a/pkgs/os-specific/linux/untie/default.nix
+++ b/pkgs/os-specific/linux/untie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "untie";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to run processes untied from some of the namespaces";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/upower/default.nix b/pkgs/os-specific/linux/upower/default.nix
index e9d9eff007cde..3a5fb4fa26133 100644
--- a/pkgs/os-specific/linux/upower/default.nix
+++ b/pkgs/os-specific/linux/upower/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , libxslt
@@ -62,7 +62,7 @@ stdenv.mkDerivation {
     "sysconfdir=${placeholder "out"}/etc"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://upower.freedesktop.org/";
     description = "A D-Bus service for power management";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/usbip/default.nix b/pkgs/os-specific/linux/usbip/default.nix
index 9a009b74f0832..923eab71b7a85 100644
--- a/pkgs/os-specific/linux/usbip/default.nix
+++ b/pkgs/os-specific/linux/usbip/default.nix
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/torvalds/linux/tree/master/tools/usb/usbip";
     description = "allows to pass USB device from server to client over the network";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/usbtop/default.nix b/pkgs/os-specific/linux/usbtop/default.nix
index 0ff8fcf0ddf73..6948d51e5dc7e 100644
--- a/pkgs/os-specific/linux/usbtop/default.nix
+++ b/pkgs/os-specific/linux/usbtop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake
 , libpcap, boost }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ libpcap boost ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/aguinet/usbtop";
     description = "A top utility that shows an estimated instantaneous bandwidth on USB buses and devices";
     maintainers = with maintainers; [ etu ];
diff --git a/pkgs/os-specific/linux/usbutils/default.nix b/pkgs/os-specific/linux/usbutils/default.nix
index 41db602bce500..a723c18e8426b 100644
--- a/pkgs/os-specific/linux/usbutils/default.nix
+++ b/pkgs/os-specific/linux/usbutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll, autoreconfHook, pkgconfig, libusb1, hwdata , python3 }:
+{ lib, stdenv, fetchurl, substituteAll, autoreconfHook, pkgconfig, libusb1, hwdata , python3 }:
 
 stdenv.mkDerivation rec {
   name = "usbutils-012";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     moveToOutput "bin/lsusb.py" "$python"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.linux-usb.org/";
     description = "Tools for working with USB devices, such as lsusb";
     license = licenses.gpl2Plus;
diff --git a/pkgs/os-specific/linux/uvcdynctrl/default.nix b/pkgs/os-specific/linux/uvcdynctrl/default.nix
index f022023fcbb01..3d7fe1f5e150e 100644
--- a/pkgs/os-specific/linux/uvcdynctrl/default.nix
+++ b/pkgs/os-specific/linux/uvcdynctrl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, libxml2 }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, libxml2 }:
 
 stdenv.mkDerivation {
   version = "0.3.0";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple interface for devices supported by the linux UVC driver";
     homepage = "http://guvcview.sourceforge.net";
     license = licenses.gpl3Plus;
diff --git a/pkgs/os-specific/linux/v4l-utils/default.nix b/pkgs/os-specific/linux/v4l-utils/default.nix
index 2c9b395949aa5..b9cbd48944c3f 100644
--- a/pkgs/os-specific/linux/v4l-utils/default.nix
+++ b/pkgs/os-specific/linux/v4l-utils/default.nix
@@ -44,7 +44,7 @@ in stdenv.mkDerivation rec {
     patchShebangs utils/libcecutil/cec-gen.pl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "V4L utils and libv4l, provide common image formats regardless of the v4l device";
     homepage = "https://linuxtv.org/projects.php";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/os-specific/linux/v4l2loopback/default.nix b/pkgs/os-specific/linux/v4l2loopback/default.nix
index 32ae45fbb0ea2..5e0125da00a6f 100644
--- a/pkgs/os-specific/linux/v4l2loopback/default.nix
+++ b/pkgs/os-specific/linux/v4l2loopback/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, kernel, kmod }:
+{ lib, stdenv, fetchFromGitHub, kernel, kmod }:
 
 stdenv.mkDerivation rec {
   name = "v4l2loopback-${version}-${kernel.version}";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     "KERNEL_DIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A kernel module to create V4L2 loopback devices";
     homepage = "https://github.com/umlaeute/v4l2loopback";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/v86d/default.nix b/pkgs/os-specific/linux/v86d/default.nix
index ec0c318042a12..36270cdfcc0ec 100644
--- a/pkgs/os-specific/linux/v86d/default.nix
+++ b/pkgs/os-specific/linux/v86d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , kernel, klibc
 }:
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ klibc ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon to run x86 code in an emulated environment";
     homepage = "https://github.com/mjanusz/v86d";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/wireguard/default.nix b/pkgs/os-specific/linux/wireguard/default.nix
index 4ba02fa6c84b9..590e16f7993f0 100644
--- a/pkgs/os-specific/linux/wireguard/default.nix
+++ b/pkgs/os-specific/linux/wireguard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, kernel, perl, wireguard-tools, bc }:
+{ lib, stdenv, fetchzip, kernel, perl, wireguard-tools, bc }:
 
 # module requires Linux >= 3.10 https://www.wireguard.io/install/#kernel-requirements
 assert stdenv.lib.versionAtLeast kernel.version "3.10";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     inherit (wireguard-tools) tests;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (wireguard-tools.meta) homepage license maintainers;
     description = "Kernel module for the WireGuard secure network tunnel";
     downloadPage = "https://git.zx2c4.com/wireguard-linux-compat/refs/";
diff --git a/pkgs/os-specific/linux/wooting-udev-rules/default.nix b/pkgs/os-specific/linux/wooting-udev-rules/default.nix
index 0093603c250cb..75924ad02a72f 100644
--- a/pkgs/os-specific/linux/wooting-udev-rules/default.nix
+++ b/pkgs/os-specific/linux/wooting-udev-rules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv }:
+{ lib, stdenv }:
 
 stdenv.mkDerivation rec {
   pname = "wooting-udev-rules";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     install -Dpm644 $src $out/lib/udev/rules.d/70-wooting.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wooting.helpscoutdocs.com/article/34-linux-udev-rules";
     description = "udev rules that give NixOS permission to communicate with Wooting keyboards";
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/wpa_supplicant/default.nix b/pkgs/os-specific/linux/wpa_supplicant/default.nix
index 5cd440bcdfc7a..7703ffc0e4f15 100644
--- a/pkgs/os-specific/linux/wpa_supplicant/default.nix
+++ b/pkgs/os-specific/linux/wpa_supplicant/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, pkgconfig, libnl
+{ lib, stdenv, fetchurl, openssl, pkgconfig, libnl
 , dbus, readline ? null, pcsclite ? null
 }:
 
@@ -104,7 +104,7 @@ stdenv.mkDerivation rec {
     install -Dm444 wpa_supplicant.conf $out/share/doc/wpa_supplicant/wpa_supplicant.conf.example
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://hostap.epitest.fi/wpa_supplicant/";
     description = "A tool for connecting to WPA and WPA2-protected wireless networks";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/wpa_supplicant/gui.nix b/pkgs/os-specific/linux/wpa_supplicant/gui.nix
index 132cad4b6d294..ab1cece0f3392 100644
--- a/pkgs/os-specific/linux/wpa_supplicant/gui.nix
+++ b/pkgs/os-specific/linux/wpa_supplicant/gui.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchpatch, qtbase, qmake, inkscape, imagemagick, wpa_supplicant }:
+{ lib, stdenv, mkDerivation, fetchpatch, qtbase, qmake, inkscape, imagemagick, wpa_supplicant }:
 
 mkDerivation {
   name = "wpa_gui-${wpa_supplicant.version}";
@@ -32,7 +32,7 @@ mkDerivation {
     cp -av icons/hicolor $out/share/icons
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt-based GUI for wpa_supplicant";
     homepage = "https://hostap.epitest.fi/wpa_supplicant/";
     license = licenses.bsd3;
diff --git a/pkgs/os-specific/linux/x86_energy_perf_policy/default.nix b/pkgs/os-specific/linux/x86_energy_perf_policy/default.nix
index 880456afbde22..4b57ed4ceae5a 100644
--- a/pkgs/os-specific/linux/x86_energy_perf_policy/default.nix
+++ b/pkgs/os-specific/linux/x86_energy_perf_policy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel }:
+{ lib, stdenv, kernel }:
 
 stdenv.mkDerivation {
   name = "x86_energy_perf_policy-${kernel.version}";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set the energy versus performance policy preference bias on recent X86 processors";
     homepage = "https://www.kernel.org/";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/xf86-input-cmt/default.nix b/pkgs/os-specific/linux/xf86-input-cmt/default.nix
index 93fd7dd5b0e6e..e3ac4df2fd782 100644
--- a/pkgs/os-specific/linux/xf86-input-cmt/default.nix
+++ b/pkgs/os-specific/linux/xf86-input-cmt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, xorgserver, xorgproto,
+{ lib, stdenv, fetchFromGitHub, pkgconfig, xorgserver, xorgproto,
   utilmacros, libgestures, libevdevc }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "--with-sdkdir=${placeholder "out"}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chromebook touchpad driver";
     license = licenses.bsd3;
     platforms = platforms.linux;
diff --git a/pkgs/os-specific/linux/xf86-input-wacom/default.nix b/pkgs/os-specific/linux/xf86-input-wacom/default.nix
index 8a7541afa692d..bea1871b0eb86 100644
--- a/pkgs/os-specific/linux/xf86-input-wacom/default.nix
+++ b/pkgs/os-specific/linux/xf86-input-wacom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , xorgproto, libX11, libXext, libXi, libXrandr, libXrender
 , ncurses, pkgconfig, xorgserver, udev, libXinerama, pixman }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   CFLAGS = "-I${pixman}/include/pixman-1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = [ maintainers.goibhniu ];
     description = "Wacom digitizer driver for X11";
     homepage = "http://linuxwacom.sourceforge.net";
diff --git a/pkgs/os-specific/linux/xf86-video-nested/default.nix b/pkgs/os-specific/linux/xf86-video-nested/default.nix
index f86393cba84da..dbd59d530ce86 100644
--- a/pkgs/os-specific/linux/xf86-video-nested/default.nix
+++ b/pkgs/os-specific/linux/xf86-video-nested/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, xorgproto, libX11, libXext
+{ lib, stdenv, fetchgit, autoreconfHook, xorgproto, libX11, libXext
 , pixman, pkgconfig, utilmacros, xorgserver
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
 
   CFLAGS = "-I${pixman}/include/pixman-1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://cgit.freedesktop.org/xorg/driver/xf86-video-nested";
     description = "A driver to run Xorg on top of Xorg or something else";
     maintainers = [ maintainers.goibhniu ];
diff --git a/pkgs/os-specific/linux/zenmonitor/default.nix b/pkgs/os-specific/linux/zenmonitor/default.nix
index 23acaaa3e231d..4fc2a11a65fbe 100644
--- a/pkgs/os-specific/linux/zenmonitor/default.nix
+++ b/pkgs/os-specific/linux/zenmonitor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, gtk3, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, gtk3, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "zenmonitor";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Monitoring software for AMD Zen-based CPUs";
     homepage = "https://github.com/ocerman/zenmonitor";
     license = licenses.mit;
diff --git a/pkgs/os-specific/linux/zenpower/default.nix b/pkgs/os-specific/linux/zenpower/default.nix
index 43885027d9e7f..af59ec8e37bfb 100644
--- a/pkgs/os-specific/linux/zenpower/default.nix
+++ b/pkgs/os-specific/linux/zenpower/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, kernel, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, kernel, fetchFromGitHub, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "zenpower";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -D zenpower.ko -t "$out/lib/modules/${kernel.modDirVersion}/kernel/drivers/hwmon/zenpower/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux kernel driver for reading temperature, voltage(SVI2), current(SVI2) and power(SVI2) for AMD Zen family CPUs.";
     homepage = "https://github.com/ocerman/zenpower";
     license = licenses.gpl2;
diff --git a/pkgs/os-specific/linux/zenstates/default.nix b/pkgs/os-specific/linux/zenstates/default.nix
index 4ac77c00aa3b0..a56337cfef22b 100644
--- a/pkgs/os-specific/linux/zenstates/default.nix
+++ b/pkgs/os-specific/linux/zenstates/default.nix
@@ -21,7 +21,7 @@
 #     before = [ "sleep.target" ];
 #   };
 
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 stdenv.mkDerivation rec {
   pname = "zenstates";
   version = "0.0.1";
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     patchShebangs --build $out/bin/zenstates
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux utility for Ryzen processors and motherboards";
     homepage = "https://github.com/r4m0n/ZenStates-Linux";
     license = licenses.mit;
diff --git a/pkgs/os-specific/linux/zsa-udev-rules/default.nix b/pkgs/os-specific/linux/zsa-udev-rules/default.nix
index 76150affe49fc..ac69dc13b4746 100644
--- a/pkgs/os-specific/linux/zsa-udev-rules/default.nix
+++ b/pkgs/os-specific/linux/zsa-udev-rules/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "zsa-udev-rules";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     cp dist/linux64/50-wally.rules $out/lib/udev/rules.d/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "udev rules for ZSA devices";
     license = licenses.mit;
     maintainers = with maintainers; [ davidak ];
diff --git a/pkgs/os-specific/windows/pthread-w32/default.nix b/pkgs/os-specific/windows/pthread-w32/default.nix
index 257067339674c..de909828f7a24 100644
--- a/pkgs/os-specific/windows/pthread-w32/default.nix
+++ b/pkgs/os-specific/windows/pthread-w32/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation {
   pname = "pthreads-w32";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "POSIX threads library for Windows";
     homepage = "https://sourceware.org/pthreads-win32";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/servers/adguardhome/default.nix b/pkgs/servers/adguardhome/default.nix
index 0194ce6afa7ad..58996a6e85ace 100644
--- a/pkgs/servers/adguardhome/default.nix
+++ b/pkgs/servers/adguardhome/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "adguardhome";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     install -m755 -D ./AdGuardHome $out/bin/adguardhome
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AdguardTeam/AdGuardHome";
     description = "Network-wide ads & trackers blocking DNS server";
     platforms = platforms.linux;
diff --git a/pkgs/servers/adminer/default.nix b/pkgs/servers/adminer/default.nix
index 0e6cd14eef4d5..2774c8d1f2897 100644
--- a/pkgs/servers/adminer/default.nix
+++ b/pkgs/servers/adminer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, php }:
+{ lib, stdenv, fetchurl, php }:
 
 stdenv.mkDerivation rec {
   version = "4.7.8";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Database management in a single PHP file";
     homepage = "https://www.adminer.org";
     license = with licenses; [ asl20 gpl2Only ];
diff --git a/pkgs/servers/amqp/qpid-cpp/default.nix b/pkgs/servers/amqp/qpid-cpp/default.nix
index 4f7186f31404a..d65ad13011398 100644
--- a/pkgs/servers/amqp/qpid-cpp/default.nix
+++ b/pkgs/servers/amqp/qpid-cpp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, python2, boost, libuuid, ruby, buildEnv, buildPythonPackage, qpid-python }:
+{ lib, stdenv, fetchurl, cmake, python2, boost, libuuid, ruby, buildEnv, buildPythonPackage, qpid-python }:
 
 let
   pname = "qpid-cpp";
@@ -10,7 +10,7 @@ let
     sha256 = "088dx1l6myrksbhpr15bs09j6qm8vdliqwjp2ja5amym47md103r";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://qpid.apache.org";
     repositories.git = "git://git.apache.org/qpid.git";
     repositories.svn = "http://svn.apache.org/repos/asf/qpid";
diff --git a/pkgs/servers/apache-kafka/default.nix b/pkgs/servers/apache-kafka/default.nix
index 9ab14140c67f7..826e952376c73 100644
--- a/pkgs/servers/apache-kafka/default.nix
+++ b/pkgs/servers/apache-kafka/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre8, makeWrapper, bash, coreutils, gnugrep, gnused, ps,
+{ lib, stdenv, fetchurl, jre8, makeWrapper, bash, coreutils, gnugrep, gnused, ps,
   majorVersion ? "1.0" }:
 
 let
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin\/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://kafka.apache.org";
     description = "A high-throughput distributed messaging system";
     license = licenses.asl20;
diff --git a/pkgs/servers/apcupsd/default.nix b/pkgs/servers/apcupsd/default.nix
index bdbb77faf6c1d..07bfcfd267360 100644
--- a/pkgs/servers/apcupsd/default.nix
+++ b/pkgs/servers/apcupsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, systemd, util-linux, coreutils, wall, hostname, man
+{ lib, stdenv, fetchurl, pkgconfig, systemd, util-linux, coreutils, wall, hostname, man
 , enableCgiScripts ? true, gd
 }:
 
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon for controlling APC UPSes";
     homepage = "http://www.apcupsd.com/";
     license = licenses.gpl2;
diff --git a/pkgs/servers/asterisk/default.nix b/pkgs/servers/asterisk/default.nix
index 6e960bd92fe9c..26d361e97c20a 100644
--- a/pkgs/servers/asterisk/default.nix
+++ b/pkgs/servers/asterisk/default.nix
@@ -71,7 +71,7 @@ let
       ${lib.optionalString (lib.versionAtLeast version "17.0.0") "make install-headers"}
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Software implementation of a telephone private branch exchange (PBX)";
       homepage = "https://www.asterisk.org/";
       license = licenses.gpl2;
diff --git a/pkgs/servers/asterisk/sccp/default.nix b/pkgs/servers/asterisk/sccp/default.nix
index 827b26255cf0b..a830c5bdbd4a4 100644
--- a/pkgs/servers/asterisk/sccp/default.nix
+++ b/pkgs/servers/asterisk/sccp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, binutils-unwrapped, patchelf, asterisk }:
+{ lib, stdenv, fetchFromGitHub, binutils-unwrapped, patchelf, asterisk }:
 stdenv.mkDerivation rec {
   pname = "asterisk-module-sccp";
   version = "4.3.2-epsilon";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     patchelf --set-rpath "$p:${stdenv.lib.makeLibraryPath [ binutils-unwrapped ]}" "$p"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Replacement for the SCCP channel driver in Asterisk";
     license = licenses.gpl1Only;
     maintainers = with maintainers; [ das_j ];
diff --git a/pkgs/servers/atlassian/crowd.nix b/pkgs/servers/atlassian/crowd.nix
index 44d9aba582ef3..6fec1b5960e0f 100644
--- a/pkgs/servers/atlassian/crowd.nix
+++ b/pkgs/servers/atlassian/crowd.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, home ? "/var/lib/crowd"
+{ lib, stdenv, fetchurl, home ? "/var/lib/crowd"
 , port ? 8092, proxyUrl ? null, openidPassword ? "WILL_NEVER_BE_SET" }:
 
 stdenv.mkDerivation rec {
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     cp -rva . $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Single sign-on and identity management tool";
     homepage = "https://www.atlassian.com/software/crowd";
     license = licenses.unfree;
diff --git a/pkgs/servers/atlassian/jira.nix b/pkgs/servers/atlassian/jira.nix
index 66d26dbde7606..995ff86259147 100644
--- a/pkgs/servers/atlassian/jira.nix
+++ b/pkgs/servers/atlassian/jira.nix
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     cp -rva . $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Proprietary issue tracking product, also providing project management functions";
     homepage = "https://www.atlassian.com/software/jira";
     license = licenses.unfree;
diff --git a/pkgs/servers/beanstalkd/default.nix b/pkgs/servers/beanstalkd/default.nix
index d81feb3b72efc..01af8a4d5bc8c 100644
--- a/pkgs/servers/beanstalkd/default.nix
+++ b/pkgs/servers/beanstalkd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, installShellFiles }:
+{ lib, stdenv, fetchurl, installShellFiles }:
 
 stdenv.mkDerivation rec {
   version = "1.12";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     installManPage doc/beanstalkd.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://kr.github.io/beanstalkd/";
     description = "A simple, fast work queue";
     license = licenses.mit;
diff --git a/pkgs/servers/blockbook/default.nix b/pkgs/servers/blockbook/default.nix
index 5a41112699131..ceff2139414dc 100644
--- a/pkgs/servers/blockbook/default.nix
+++ b/pkgs/servers/blockbook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , packr
@@ -54,7 +54,7 @@ buildGoModule rec {
     cp -r $src/static/css/ $out/share/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Trezor address/account balance backend";
     homepage = "https://github.com/trezor/blockbook";
     license = licenses.agpl3;
diff --git a/pkgs/servers/caddy/default.nix b/pkgs/servers/caddy/default.nix
index d50a94f9d66d0..d48bcad179466 100644
--- a/pkgs/servers/caddy/default.nix
+++ b/pkgs/servers/caddy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "caddy";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests) caddy; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://caddyserver.com";
     description = "Fast, cross-platform HTTP/2 web server with automatic HTTPS";
     license = licenses.asl20;
diff --git a/pkgs/servers/clickhouse/default.nix b/pkgs/servers/clickhouse/default.nix
index da73bc3c60128..063964b2f6a66 100644
--- a/pkgs/servers/clickhouse/default.nix
+++ b/pkgs/servers/clickhouse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, cmake, libtool, lldClang, ninja
+{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, libtool, lldClang, ninja
 , boost, brotli, capnproto, cctz, clang-unwrapped, double-conversion
 , icu, jemalloc, libcpuid, libxml2, lld, llvm, lz4, libmysqlclient, openssl, perl
 , poco, protobuf, python3, rapidjson, re2, rdkafka, readline, sparsehash, unixODBC
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://clickhouse.tech/";
     description = "Column-oriented database management system";
     license = licenses.asl20;
diff --git a/pkgs/servers/cloud-print-connector/default.nix b/pkgs/servers/cloud-print-connector/default.nix
index e819931002742..8e1ef83126916 100644
--- a/pkgs/servers/cloud-print-connector/default.nix
+++ b/pkgs/servers/cloud-print-connector/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, avahi, cups, fetchpatch }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, avahi, cups, fetchpatch }:
 
 # TODO: Add a service for gcp-cups-connector and perhaps some other
 # kind of configuration for the same thing that gcp-connector-util
@@ -52,7 +52,7 @@ buildGoPackage rec {
 
   buildInputs = [ avahi cups ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Share printers from your Windows, Linux, FreeBSD or macOS computer with ChromeOS and Android devices, using the Cloud Print Connector";
     homepage = "https://github.com/google/cloud-print-connector";
     license = licenses.bsd3;
diff --git a/pkgs/servers/code-server/default.nix b/pkgs/servers/code-server/default.nix
index 60fb8ed5ea56e..60b4d57c64773 100644
--- a/pkgs/servers/code-server/default.nix
+++ b/pkgs/servers/code-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule, makeWrapper, runCommand
+{ lib, stdenv, fetchFromGitHub, buildGoModule, makeWrapper, runCommand
 , moreutils, jq, git, zip, rsync, pkgconfig, yarn, python2
 , nodejs-12_x, libsecret, xorg, ripgrep, nettools }:
 
@@ -211,7 +211,7 @@ in stdenv.mkDerivation rec {
     });
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Run VS Code on a remote server";
     longDescription = ''
       code-server is VS Code running on a remote server, accessible through the
diff --git a/pkgs/servers/computing/slurm-spank-x11/default.nix b/pkgs/servers/computing/slurm-spank-x11/default.nix
index bb7885025d191..8e64185e71c67 100644
--- a/pkgs/servers/computing/slurm-spank-x11/default.nix
+++ b/pkgs/servers/computing/slurm-spank-x11/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, slurm } :
+{ lib, stdenv, fetchFromGitHub, slurm } :
 let
   version = "0.2.5";
 in
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
       install -m 755 x11.so $out/lib
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hautreux/slurm-spank-x11";
     description = "Plugin for SLURM to allow for interactive X11 sessions";
     platforms = platforms.linux;
diff --git a/pkgs/servers/computing/slurm/default.nix b/pkgs/servers/computing/slurm/default.nix
index 9e2c482e0d96a..d5a2c030c1159 100644
--- a/pkgs/servers/computing/slurm/default.nix
+++ b/pkgs/servers/computing/slurm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libtool, curl
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libtool, curl
 , python3, munge, perl, pam, zlib, shadow, coreutils
 , ncurses, libmysqlclient, gtk2, lua, hwloc, numactl
 , readline, freeipmi, xorg, lz4, rdma-core, nixosTests
@@ -78,7 +78,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.slurm = nixosTests.slurm;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.schedmd.com/";
     description = "Simple Linux Utility for Resource Management";
     platforms = platforms.linux;
diff --git a/pkgs/servers/computing/storm/default.nix b/pkgs/servers/computing/storm/default.nix
index 541e9f6e11b5c..e961e1cf2c949 100644
--- a/pkgs/servers/computing/storm/default.nix
+++ b/pkgs/servers/computing/storm/default.nix
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://storm.apache.org";
     description = "Distributed realtime computation system";
     license = licenses.asl20;
diff --git a/pkgs/servers/computing/torque/default.nix b/pkgs/servers/computing/torque/default.nix
index de358a5d66f82..28651752dd194 100644
--- a/pkgs/servers/computing/torque/default.nix
+++ b/pkgs/servers/computing/torque/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, flex, bison, pkgconfig, groff, libxml2, util-linux
+{ lib, stdenv, fetchFromGitHub, openssl, flex, bison, pkgconfig, groff, libxml2, util-linux
 , coreutils, file, libtool, which, boost, autoreconfHook
 }:
 
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/pbs_mkdirs $out/bin/torque.setup
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.adaptivecomputing.com/products/open-source/torque";
     description = "Resource management system for submitting and controlling jobs on supercomputers, clusters, and grids";
     platforms = platforms.linux;
diff --git a/pkgs/servers/confluent-platform/default.nix b/pkgs/servers/confluent-platform/default.nix
index 52023b39812f8..e1cf49099324f 100644
--- a/pkgs/servers/confluent-platform/default.nix
+++ b/pkgs/servers/confluent-platform/default.nix
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.confluent.io/";
     description = "Confluent event streaming platform based on Apache Kafka";
     license = licenses.asl20;
diff --git a/pkgs/servers/consul/default.nix b/pkgs/servers/consul/default.nix
index 5d741cf0bbace..f319c5f3db199 100644
--- a/pkgs/servers/consul/default.nix
+++ b/pkgs/servers/consul/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "consul";
@@ -39,7 +39,7 @@ buildGoModule rec {
                        -X github.com/hashicorp/consul/version.VersionPrerelease=")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for service discovery, monitoring and configuration";
     homepage = "https://www.consul.io/";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/servers/coturn/default.nix b/pkgs/servers/coturn/default.nix
index c32ddecc7a36c..91ecfc113cd0b 100644
--- a/pkgs/servers/coturn/default.nix
+++ b/pkgs/servers/coturn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, openssl, libevent }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, openssl, libevent }:
 
 stdenv.mkDerivation rec {
   pname = "coturn";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     ./pure-configure.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://coturn.net/";
     license = with licenses; [ bsd3 ];
     description = "A TURN server";
diff --git a/pkgs/servers/dante/default.nix b/pkgs/servers/dante/default.nix
index 6be80c491fd65..99bde454659cc 100644
--- a/pkgs/servers/dante/default.nix
+++ b/pkgs/servers/dante/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pam, libkrb5, cyrus_sasl, miniupnpc }:
+{ lib, stdenv, fetchurl, pam, libkrb5, cyrus_sasl, miniupnpc }:
 
 stdenv.mkDerivation rec {
   pname = "dante";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   dontAddDisableDepTrack = stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A circuit-level SOCKS client/server that can be used to provide convenient and secure network connectivity";
     homepage    = "https://www.inet.no/dante/";
     maintainers = [ maintainers.arobyn ];
diff --git a/pkgs/servers/demoit/default.nix b/pkgs/servers/demoit/default.nix
index 9a78d5c7c18e4..0c6fe81877564 100644
--- a/pkgs/servers/demoit/default.nix
+++ b/pkgs/servers/demoit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 }:
@@ -16,7 +16,7 @@ buildGoModule {
   vendorSha256 = null;
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Live coding demos without Context Switching";
     homepage = "https://github.com/dgageot/demoit";
     license = licenses.asl20;
diff --git a/pkgs/servers/dico/default.nix b/pkgs/servers/dico/default.nix
index 69ec2e6222b7a..cf0417e332e8c 100644
--- a/pkgs/servers/dico/default.nix
+++ b/pkgs/servers/dico/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, libtool, gettext, zlib, readline, gsasl
+{ fetchurl, lib, stdenv, libtool, gettext, zlib, readline, gsasl
 , guile, python, pcre, libffi, groff }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flexible dictionary server and client implementing RFC 2229";
     homepage    = "https://www.gnu.org/software/dico/";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/servers/dict/default.nix b/pkgs/servers/dict/default.nix
index 5e4d625c187b7..4e94b69f5124f 100644
--- a/pkgs/servers/dict/default.nix
+++ b/pkgs/servers/dict/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, bison, flex, libmaa, zlib, libtool }:
+{ lib, stdenv, fetchurl, which, bison, flex, libmaa, zlib, libtool }:
 
 stdenv.mkDerivation rec {
   pname = "dictd";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     install -Dm444 -t $out/share/doc/${pname} NEWS README
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dict protocol server and client";
     homepage = "http://www.dict.org";
     license = licenses.gpl2;
diff --git a/pkgs/servers/dict/libmaa.nix b/pkgs/servers/dict/libmaa.nix
index 4ac4328c35fcf..d55f89b9477f3 100644
--- a/pkgs/servers/dict/libmaa.nix
+++ b/pkgs/servers/dict/libmaa.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libtool }:
+{ lib, stdenv, fetchurl, libtool }:
 
 stdenv.mkDerivation rec {
   version = "1.3.2";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-Wno-error=format-truncation";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dict protocol server and client";
     maintainers = [ ];
     platforms = platforms.linux;
diff --git a/pkgs/servers/diod/default.nix b/pkgs/servers/diod/default.nix
index 9e33a8c7910e3..8bab803056e95 100644
--- a/pkgs/servers/diod/default.nix
+++ b/pkgs/servers/diod/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, munge, lua,
+{ lib, stdenv, fetchurl, munge, lua,
   libcap, perl, ncurses
 }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ munge lua libcap perl ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An I/O forwarding server that implements a variant of the 9P protocol";
     maintainers = with maintainers; [ rnhmjoj ];
     platforms   = platforms.linux;
diff --git a/pkgs/servers/dns/bind/default.nix b/pkgs/servers/dns/bind/default.nix
index 858a4fcb5fa07..55bc638d2f4d6 100644
--- a/pkgs/servers/dns/bind/default.nix
+++ b/pkgs/servers/dns/bind/default.nix
@@ -74,7 +74,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests = { inherit (nixosTests) bind; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.isc.org/downloads/bind/";
     description = "Domain name server";
     license = licenses.mpl20;
diff --git a/pkgs/servers/dns/coredns/default.nix b/pkgs/servers/dns/coredns/default.nix
index ff0211d37e7c6..6973e46412bf8 100644
--- a/pkgs/servers/dns/coredns/default.nix
+++ b/pkgs/servers/dns/coredns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "coredns";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://coredns.io";
     description = "A DNS server that runs middleware";
     license = licenses.asl20;
diff --git a/pkgs/servers/dns/dnsdist/default.nix b/pkgs/servers/dns/dnsdist/default.nix
index 61fa164010e71..4bb012d729747 100644
--- a/pkgs/servers/dns/dnsdist/default.nix
+++ b/pkgs/servers/dns/dnsdist/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, systemd
+{ lib, stdenv, fetchurl, pkgconfig, systemd
 , boost, libsodium, libedit, re2
 , net-snmp, lua, protobuf, openssl, zlib, h2o
 }:
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DNS Loadbalancer";
     homepage = "https://dnsdist.org";
     license = licenses.gpl2;
diff --git a/pkgs/servers/dns/https-dns-proxy/default.nix b/pkgs/servers/dns/https-dns-proxy/default.nix
index 6f2cb5048034d..c32d3eca22637 100644
--- a/pkgs/servers/dns/https-dns-proxy/default.nix
+++ b/pkgs/servers/dns/https-dns-proxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, gtest, c-ares, curl, libev }:
+{ lib, stdenv, fetchFromGitHub, cmake, gtest, c-ares, curl, libev }:
 
 stdenv.mkDerivation rec {
   pname = "https-dns-proxy";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
   # for when that happens despite there being none as of right now
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DNS to DNS over HTTPS (DoH) proxy";
     license = licenses.mit;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/servers/dns/knot-dns/default.nix b/pkgs/servers/dns/knot-dns/default.nix
index ee37ae1f0bf14..e1bd2bb2fff3b 100644
--- a/pkgs/servers/dns/knot-dns/default.nix
+++ b/pkgs/servers/dns/knot-dns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gnutls, liburcu, lmdb, libcap_ng, libidn2, libunistring
+{ lib, stdenv, fetchurl, pkgconfig, gnutls, liburcu, lmdb, libcap_ng, libidn2, libunistring
 , systemd, nettle, libedit, zlib, libiconv, libintl, libmaxminddb, libbpf, nghttp2
 , autoreconfHook
 }:
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     rm -r "$out"/lib/*.la
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Authoritative-only DNS server from .cz domain registry";
     homepage = "https://knot-dns.cz";
     license = licenses.gpl3Plus;
diff --git a/pkgs/servers/dns/knot-resolver/default.nix b/pkgs/servers/dns/knot-resolver/default.nix
index 9e09a11e712a9..1f495622f28bc 100644
--- a/pkgs/servers/dns/knot-resolver/default.nix
+++ b/pkgs/servers/dns/knot-resolver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch
+{ lib, stdenv, fetchurl, fetchpatch
 # native deps.
 , runCommand, pkgconfig, meson, ninja, makeWrapper
 # build+runtime deps.
@@ -84,7 +84,7 @@ unwrapped = stdenv.mkDerivation rec {
     meson test --print-errorlogs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Caching validating DNS resolver, from .cz domain registry";
     homepage = "https://knot-resolver.cz";
     license = licenses.gpl3Plus;
diff --git a/pkgs/servers/dns/nsd/default.nix b/pkgs/servers/dns/nsd/default.nix
index f505bb786ee76..02a460219ec68 100644
--- a/pkgs/servers/dns/nsd/default.nix
+++ b/pkgs/servers/dns/nsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libevent, openssl, nixosTests
+{ lib, stdenv, fetchurl, libevent, openssl, nixosTests
 , bind8Stats       ? false
 , checking         ? false
 , ipv6             ? true
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     inherit (nixosTests) nsd;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.nlnetlabs.nl";
     description = "Authoritative only, high performance, simple and open source name server";
     license = licenses.bsd3;
diff --git a/pkgs/servers/dns/powerdns/default.nix b/pkgs/servers/dns/powerdns/default.nix
index 5dbc387868c41..990386f06ce91 100644
--- a/pkgs/servers/dns/powerdns/default.nix
+++ b/pkgs/servers/dns/powerdns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, nixosTests
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, nixosTests
 , boost, libyamlcpp, libsodium, sqlite, protobuf, openssl, systemd
 , mysql57, postgresql, lua, openldap, geoip, curl, unixODBC
 }:
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     nixos = nixosTests.powerdns;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Authoritative DNS server";
     homepage = "https://www.powerdns.com";
     platforms = platforms.unix;
diff --git a/pkgs/servers/domoticz/default.nix b/pkgs/servers/domoticz/default.nix
index c32f56e7c7dd2..a9f5245ff1fe6 100644
--- a/pkgs/servers/domoticz/default.nix
+++ b/pkgs/servers/domoticz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv,
+{ lib, stdenv,
   fetchzip,
   makeWrapper,
   cmake,
@@ -86,7 +86,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/domoticz --set LD_LIBRARY_PATH ${python3}/lib;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Home automation system";
     longDescription = ''
       Domoticz is a home automation system that lets you monitor and configure
diff --git a/pkgs/servers/elasticmq-server-bin/default.nix b/pkgs/servers/elasticmq-server-bin/default.nix
index 5293b18368e7b..c10ea7dd1806f 100644
--- a/pkgs/servers/elasticmq-server-bin/default.nix
+++ b/pkgs/servers/elasticmq-server-bin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jdk, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jdk, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "elasticmq-server";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --add-flags "-jar $out/share/elasticmq-server/elasticmq-server.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/softwaremill/elasticmq";
     description = "Message queueing system with Java, Scala and Amazon SQS-compatible interfaces";
     license = licenses.asl20;
diff --git a/pkgs/servers/endlessh/default.nix b/pkgs/servers/endlessh/default.nix
index 216318380fc1c..fc05ec033d4b5 100644
--- a/pkgs/servers/endlessh/default.nix
+++ b/pkgs/servers/endlessh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "endlessh";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SSH tarpit that slowly sends an endless banner";
     homepage = "https://github.com/skeeto/endlessh";
     changelog = "https://github.com/skeeto/endlessh/releases/tag/${version}";
diff --git a/pkgs/servers/exhibitor/default.nix b/pkgs/servers/exhibitor/default.nix
index 2d1ccaf6e26ce..b4869b162db9f 100644
--- a/pkgs/servers/exhibitor/default.nix
+++ b/pkgs/servers/exhibitor/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, maven, jdk, makeWrapper, stdenv, ... }:
+{ fetchFromGitHub, maven, jdk, makeWrapper, lib, stdenv, ... }:
 stdenv.mkDerivation rec {
   pname = "exhibitor";
   version = "1.5.6";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
       cd ${pomFileDir}
       mvn package --offline -Dmaven.repo.local=$(cp -dpR ${fetchedMavenDeps}/.m2 ./ && chmod +w -R .m2 && pwd)/.m2
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/soabase/exhibitor";
     description = "ZooKeeper co-process for instance monitoring, backup/recovery, cleanup and visualization";
     license = licenses.asl20;
diff --git a/pkgs/servers/fcgiwrap/default.nix b/pkgs/servers/fcgiwrap/default.nix
index a15e1c15b15b2..54b699e8a6deb 100644
--- a/pkgs/servers/fcgiwrap/default.nix
+++ b/pkgs/servers/fcgiwrap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, systemd, fcgi, autoreconfHook, pkgconfig }:
+{ lib, stdenv, fetchurl, systemd, fcgi, autoreconfHook, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "fcgiwrap";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     substituteInPlace configure.ac --replace libsystemd-daemon libsystemd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://nginx.localdomain.pl/wiki/FcgiWrap";
     description = "Simple server for running CGI applications over FastCGI";
     maintainers = with maintainers; [ lethalman ];
diff --git a/pkgs/servers/felix/default.nix b/pkgs/servers/felix/default.nix
index 486474a46b0f0..dd9d34c85fdd8 100644
--- a/pkgs/servers/felix/default.nix
+++ b/pkgs/servers/felix/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "apache-felix";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out
     cp -av * $out
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An OSGi gateway";
     homepage = "https://felix.apache.org";
     license = licenses.asl20;
diff --git a/pkgs/servers/fileshare/default.nix b/pkgs/servers/fileshare/default.nix
index 90bf2c3a57f65..e626019f09b5c 100644
--- a/pkgs/servers/fileshare/default.nix
+++ b/pkgs/servers/fileshare/default.nix
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp bin/release/fileshare $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small HTTP Server for quickly sharing files over the network";
     longDescription = "Fileshare is a simple tool for sharing the contents of a directory via a webserver and optionally allowing uploads.";
     homepage = "https://git.tkolb.de/Public/fileshare";
diff --git a/pkgs/servers/fingerd/bsd-fingerd/default.nix b/pkgs/servers/fingerd/bsd-fingerd/default.nix
index 999718160215e..eac51beadcbaf 100644
--- a/pkgs/servers/fingerd/bsd-fingerd/default.nix
+++ b/pkgs/servers/fingerd/bsd-fingerd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 # !!! Duplication: this package is almost exactly the same as `bsd-fingerd'.
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
 
   preInstall = '' mkdir -p $out/man/man8 $out/sbin '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     license = licenses.bsdOriginal;
   };
diff --git a/pkgs/servers/foundationdb/cmake.nix b/pkgs/servers/foundationdb/cmake.nix
index 1b5b63cfae1c2..2a94008a4e9ae 100644
--- a/pkgs/servers/foundationdb/cmake.nix
+++ b/pkgs/servers/foundationdb/cmake.nix
@@ -118,7 +118,7 @@ let
 
         outputs = [ "out" "dev" "lib" "pythonsrc" ];
 
-        meta = with stdenv.lib; {
+        meta = with lib; {
           description = "Open source, distributed, transactional key-value store";
           homepage    = "https://www.foundationdb.org";
           license     = licenses.asl20;
diff --git a/pkgs/servers/freeradius/default.nix b/pkgs/servers/freeradius/default.nix
index 84c92619f7357..6f932208f3c92 100644
--- a/pkgs/servers/freeradius/default.nix
+++ b/pkgs/servers/freeradius/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, autoreconfHook, talloc, finger_bsd, perl
+{ lib, stdenv, fetchurl, fetchpatch, autoreconfHook, talloc, finger_bsd, perl
 , openssl
 , linkOpenssl? true
 , openldap
@@ -98,7 +98,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "dev" "man" "doc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://freeradius.org/";
     description = "A modular, high performance free RADIUS suite";
     license = licenses.gpl2;
diff --git a/pkgs/servers/ftp/bftpd/default.nix b/pkgs/servers/ftp/bftpd/default.nix
index 538877169e1a8..e6454ced2a760 100644
--- a/pkgs/servers/ftp/bftpd/default.nix
+++ b/pkgs/servers/ftp/bftpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   pname = "bftpd";
@@ -24,7 +24,7 @@ in stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     description = "A minimal ftp server";
     downloadPage = "http://bftpd.sf.net/download.html";
diff --git a/pkgs/servers/ftp/pure-ftpd/default.nix b/pkgs/servers/ftp/pure-ftpd/default.nix
index 32e039f546b57..731d2c9e19a93 100644
--- a/pkgs/servers/ftp/pure-ftpd/default.nix
+++ b/pkgs/servers/ftp/pure-ftpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, fetchpatch }:
+{ lib, stdenv, fetchurl, openssl, fetchpatch }:
 
 stdenv.mkDerivation rec {
   name = "pure-ftpd-1.0.49";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--with-tls" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free, secure, production-quality and standard-conformant FTP server";
     homepage = "https://www.pureftpd.org";
     license = licenses.isc; # with some parts covered by BSD3(?)
diff --git a/pkgs/servers/ftp/vsftpd/default.nix b/pkgs/servers/ftp/vsftpd/default.nix
index d5766b8d19e92..1a5bd4370d72b 100644
--- a/pkgs/servers/ftp/vsftpd/default.nix
+++ b/pkgs/servers/ftp/vsftpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libcap, openssl, pam }:
+{ lib, stdenv, fetchurl, libcap, openssl, pam }:
 
 stdenv.mkDerivation rec {
   name = "vsftpd-3.0.3";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A very secure FTP daemon";
     license = licenses.gpl2;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/servers/gerbera/default.nix b/pkgs/servers/gerbera/default.nix
index c3f36a75923e5..965e1d1b08207 100644
--- a/pkgs/servers/gerbera/default.nix
+++ b/pkgs/servers/gerbera/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, pkg-config
 # required
 , libupnp, libuuid, pugixml, libiconv, sqlite, zlib, spdlog, fmt
@@ -63,7 +63,7 @@ in stdenv.mkDerivation rec {
   ++ optionals enableFFmpegThumbnailer [ pkgs.ffmpegthumbnailer ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.gerbera.io/";
     description = "UPnP Media Server for 2020";
     longDescription = ''
diff --git a/pkgs/servers/gopher/gofish/default.nix b/pkgs/servers/gopher/gofish/default.nix
index d8091c4e98d68..6468f6a9fcc3c 100644
--- a/pkgs/servers/gopher/gofish/default.nix
+++ b/pkgs/servers/gopher/gofish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
 
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     sha256 = "0br5nvlna86k4ya4q13gz0i7nlmk225lqmpfiqlkldxkr473kf0s";
   };
   	
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight Gopher server";
     homepage = "http://gofish.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/servers/gotify/default.nix b/pkgs/servers/gotify/default.nix
index a7fb1d0e7e578..7b9b8124366d0 100644
--- a/pkgs/servers/gotify/default.nix
+++ b/pkgs/servers/gotify/default.nix
@@ -50,7 +50,7 @@ buildGoModule rec {
     "-ldflags=-X main.Version=${version} -X main.Mode=prod"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple server for sending and receiving messages in real-time per WebSocket";
     homepage = "https://gotify.net";
     license = licenses.mit;
diff --git a/pkgs/servers/gotty/default.nix b/pkgs/servers/gotty/default.nix
index e7d0e6f7c65ac..c4881baeac064 100644
--- a/pkgs/servers/gotty/default.nix
+++ b/pkgs/servers/gotty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gotty";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "1vhhs7d4k1vpkf2k69ai2r3bp3zwnwa8l9q7vza0rck69g4nmz7a";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Share your terminal as a web application";
     homepage = "https://github.com/yudai/gotty";
     maintainers = with maintainers; [ ];
diff --git a/pkgs/servers/gpm/default.nix b/pkgs/servers/gpm/default.nix
index 1a5032772aba6..bde4150d15d75 100644
--- a/pkgs/servers/gpm/default.nix
+++ b/pkgs/servers/gpm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, automake, autoconf, libtool, flex, bison, texinfo, fetchpatch
+{ lib, stdenv, fetchurl, automake, autoconf, libtool, flex, bison, texinfo, fetchpatch
 
 # Optional Dependencies
 , ncurses ? null
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     ln -sv $out/lib/libgpm.so.2 $out/lib/libgpm.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.nico.schottelius.org/software/gpm/";
     description = "A daemon that provides mouse support on the Linux console";
     license = licenses.gpl2;
diff --git a/pkgs/servers/gpsd/default.nix b/pkgs/servers/gpsd/default.nix
index 7f197254878de..b7d507193055a 100644
--- a/pkgs/servers/gpsd/default.nix
+++ b/pkgs/servers/gpsd/default.nix
@@ -84,7 +84,7 @@ stdenv.mkDerivation rec {
     wrapPythonProgramsIn $out/bin "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GPS service daemon";
     longDescription = ''
       gpsd is a service daemon that monitors one or more GPSes or AIS
diff --git a/pkgs/servers/grocy/default.nix b/pkgs/servers/grocy/default.nix
index 3fd7c1c4cf708..bd9a02f7b91a7 100644
--- a/pkgs/servers/grocy/default.nix
+++ b/pkgs/servers/grocy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, nixosTests }:
+{ lib, stdenv, fetchurl, unzip, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "grocy";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     cp -R . $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     maintainers = with maintainers; [ ma27 ];
     description = "ERP beyond your fridge - grocy is a web-based self-hosted groceries & household management solution for your home";
diff --git a/pkgs/servers/h2/default.nix b/pkgs/servers/h2/default.nix
index b7f56cfe446ce..cdcd802916b5b 100644
--- a/pkgs/servers/h2/default.nix
+++ b/pkgs/servers/h2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jre, makeWrapper }:
+{ lib, stdenv, fetchzip, jre, makeWrapper }:
 stdenv.mkDerivation rec {
   pname = "h2";
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
       chmod +x $out/bin/*.sh
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Java SQL database";
     homepage = "http://www.h2database.com/html/main.html";
     license = licenses.mpl20;
diff --git a/pkgs/servers/hashi-ui/default.nix b/pkgs/servers/hashi-ui/default.nix
index 70926e37739a6..73a96d6a3c0ef 100644
--- a/pkgs/servers/hashi-ui/default.nix
+++ b/pkgs/servers/hashi-ui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "hashi-ui";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     install -m755 -D $src $out/bin/hashi-ui
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jippi/hashi-ui";
     description = "A modern user interface for hashicorp Consul & Nomad";
     platforms = [ "x86_64-linux" ];
diff --git a/pkgs/servers/hbase/default.nix b/pkgs/servers/hbase/default.nix
index e964e956c55bf..5e1d8c85a3fff 100644
--- a/pkgs/servers/hbase/default.nix
+++ b/pkgs/servers/hbase/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper }:
+{ lib, stdenv, fetchurl, makeWrapper }:
 stdenv.mkDerivation rec {
   pname = "hbase";
   version = "0.98.24";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out
     cp -R * $out
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A distributed, scalable, big data store";
     homepage = "https://hbase.apache.org";
     license = licenses.asl20;
diff --git a/pkgs/servers/headphones/default.nix b/pkgs/servers/headphones/default.nix
index 7259104d145f9..0ae4bbcb1fd6f 100644
--- a/pkgs/servers/headphones/default.nix
+++ b/pkgs/servers/headphones/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, python2, makeWrapper }:
 
 python2.pkgs.buildPythonApplication rec {
   pname = "headphones";
@@ -24,7 +24,7 @@ python2.pkgs.buildPythonApplication rec {
     makeWrapper $out/Headphones.py $out/bin/headphones
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic music downloader for SABnzbd";
     license     = licenses.gpl3;
     homepage    = "https://github.com/rembo10/headphones";
diff --git a/pkgs/servers/hitch/default.nix b/pkgs/servers/hitch/default.nix
index 1576d940a7a61..497cdb4fcf428 100644
--- a/pkgs/servers/hitch/default.nix
+++ b/pkgs/servers/hitch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, docutils, libev, openssl, pkgconfig, nixosTests }:
+{ lib, stdenv, fetchurl, docutils, libev, openssl, pkgconfig, nixosTests }:
 stdenv.mkDerivation rec {
   version = "1.7.0";
   pname = "hitch";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.hitch = nixosTests.hitch;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Libev-based high performance SSL/TLS proxy by Varnish Software";
     homepage = "https://hitch-tls.org/";
     license = licenses.bsd2;
diff --git a/pkgs/servers/http/apache-httpd/2.4.nix b/pkgs/servers/http/apache-httpd/2.4.nix
index 71f8c8054c714..e0c906fe9f11e 100644
--- a/pkgs/servers/http/apache-httpd/2.4.nix
+++ b/pkgs/servers/http/apache-httpd/2.4.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, zlib, apr, aprutil, pcre, libiconv, lynx
+{ lib, stdenv, fetchurl, perl, zlib, apr, aprutil, pcre, libiconv, lynx
 , proxySupport ? true
 , sslSupport ? true, openssl
 , http2Support ? true, nghttp2
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
     inherit apr aprutil sslSupport proxySupport ldapSupport luaSupport lua5;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Apache HTTPD, the world's most popular web server";
     homepage    = "http://httpd.apache.org/";
     license     = licenses.asl20;
diff --git a/pkgs/servers/http/apache-modules/mod_auth_mellon/default.nix b/pkgs/servers/http/apache-modules/mod_auth_mellon/default.nix
index d696ece826756..498d3bc0424a4 100644
--- a/pkgs/servers/http/apache-modules/mod_auth_mellon/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_auth_mellon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, apacheHttpd, autoconf, automake, autoreconfHook, curl, fetchFromGitHub, glib, lasso, libtool, libxml2, libxslt, openssl, pkgconfig, xmlsec }:
+{ lib, stdenv, apacheHttpd, autoconf, automake, autoreconfHook, curl, fetchFromGitHub, glib, lasso, libtool, libxml2, libxslt, openssl, pkgconfig, xmlsec }:
 
 stdenv.mkDerivation rec {
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     cp ./.libs/mod_auth_mellon.so $out/modules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/UNINETT/mod_auth_mellon";
     description = "An Apache module with a simple SAML 2.0 service provider";
     license = licenses.gpl2Plus;
diff --git a/pkgs/servers/http/apache-modules/mod_ca/default.nix b/pkgs/servers/http/apache-modules/mod_ca/default.nix
index c4551108338b2..04440666f291f 100644
--- a/pkgs/servers/http/apache-modules/mod_ca/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_ca/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, apacheHttpd, openssl, openldap, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, apacheHttpd, openssl, openldap, apr, aprutil }:
 
 stdenv.mkDerivation rec {
   pname = "mod_ca";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     "LIBEXECDIR=${placeholder ''out''}/modules"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax CA service module";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/mod_crl/default.nix b/pkgs/servers/http/apache-modules/mod_crl/default.nix
index ee7dbe3245d46..a5f06a58ad568 100644
--- a/pkgs/servers/http/apache-modules/mod_crl/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_crl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
 
 
 stdenv.mkDerivation rec {
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ mod_ca apr aprutil ];
   inherit (mod_ca) configureFlags installFlags;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax module for Certificate Revocation Lists";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/mod_csr/default.nix b/pkgs/servers/http/apache-modules/mod_csr/default.nix
index 6547d3aa2b5cb..e83ef99a2f099 100644
--- a/pkgs/servers/http/apache-modules/mod_csr/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_csr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
 
 
 stdenv.mkDerivation rec {
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ mod_ca apr aprutil ];
   inherit (mod_ca) configureFlags installFlags;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax CA service module to handle Certificate Signing Requests";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/mod_dnssd/default.nix b/pkgs/servers/http/apache-modules/mod_dnssd/default.nix
index 5831401813289..783f7bfb4b21a 100644
--- a/pkgs/servers/http/apache-modules/mod_dnssd/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_dnssd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, apacheHttpd, apr, avahi }:
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, apacheHttpd, apr, avahi }:
 
 stdenv.mkDerivation rec {
   name = "mod_dnssd-0.6";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp src/.libs/mod_dnssd.so $out/modules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://0pointer.de/lennart/projects/mod_dnssd";
     description = "Provide Zeroconf support via DNS-SD using Avahi";
     license = licenses.asl20;
diff --git a/pkgs/servers/http/apache-modules/mod_ocsp/default.nix b/pkgs/servers/http/apache-modules/mod_ocsp/default.nix
index 6ec3f246fad58..fa9309fc47200 100644
--- a/pkgs/servers/http/apache-modules/mod_ocsp/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_ocsp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
 
 stdenv.mkDerivation rec {
   pname = "mod_ocsp";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ mod_ca apr aprutil ];
   inherit (mod_ca) configureFlags installFlags;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax CA service modules of OCSP Online Certificate Validation";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/mod_pkcs12/default.nix b/pkgs/servers/http/apache-modules/mod_pkcs12/default.nix
index 1cf68f2a27688..711443230e694 100644
--- a/pkgs/servers/http/apache-modules/mod_pkcs12/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_pkcs12/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
 
 stdenv.mkDerivation rec {
   pname = "mod_pkcs12";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ mod_ca apr aprutil ];
   inherit (mod_ca) configureFlags installFlags;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax CA service modules for PKCS#12 format files";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/mod_scep/default.nix b/pkgs/servers/http/apache-modules/mod_scep/default.nix
index 1331c6da3e410..e56fa6987e153 100644
--- a/pkgs/servers/http/apache-modules/mod_scep/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_scep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
 
 stdenv.mkDerivation rec {
   pname = "mod_scep";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ mod_ca apr aprutil ];
   inherit (mod_ca) configureFlags installFlags;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax CA service modules for SCEP (Automatic ceritifcate issue/renewal)";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/mod_spkac/default.nix b/pkgs/servers/http/apache-modules/mod_spkac/default.nix
index 00f054f755ea2..dba56765538f9 100644
--- a/pkgs/servers/http/apache-modules/mod_spkac/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_spkac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
 
 stdenv.mkDerivation rec {
   pname = "mod_spkac";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ mod_ca apr aprutil ];
   inherit (mod_ca) configureFlags installFlags;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax CA service module for handling the Netscape keygen requests. ";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/mod_tile/default.nix b/pkgs/servers/http/apache-modules/mod_tile/default.nix
index 397e0dfe0bb48..31ddd18638381 100644
--- a/pkgs/servers/http/apache-modules/mod_tile/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_tile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, apacheHttpd, apr, cairo, iniparser, mapnik }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, apacheHttpd, apr, cairo, iniparser, mapnik }:
 
 stdenv.mkDerivation rec {
   pname = "mod_tile";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/nix
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/openstreetmap/mod_tile";
     description = "Efficiently render and serve OpenStreetMap tiles using Apache and Mapnik";
     license = licenses.gpl2;
diff --git a/pkgs/servers/http/apache-modules/mod_timestamp/default.nix b/pkgs/servers/http/apache-modules/mod_timestamp/default.nix
index 9cd2a822b098d..5e315fe956fca 100644
--- a/pkgs/servers/http/apache-modules/mod_timestamp/default.nix
+++ b/pkgs/servers/http/apache-modules/mod_timestamp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
+{ lib, stdenv, fetchurl, pkgconfig, mod_ca, apr, aprutil }:
 
 stdenv.mkDerivation rec {
   pname = "mod_timestamp";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ mod_ca apr aprutil ];
   inherit (mod_ca) configureFlags installFlags;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RedWax CA service module for issuing signed timestamps";
 
     homepage = "https://redwax.eu";
diff --git a/pkgs/servers/http/apache-modules/tomcat-connectors/default.nix b/pkgs/servers/http/apache-modules/tomcat-connectors/default.nix
index 0e07454bbc5ed..bea94a8885979 100644
--- a/pkgs/servers/http/apache-modules/tomcat-connectors/default.nix
+++ b/pkgs/servers/http/apache-modules/tomcat-connectors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, apacheHttpd, jdk }:
+{ lib, stdenv, fetchurl, apacheHttpd, jdk }:
 
 stdenv.mkDerivation rec {
   name = "tomcat-connectors-1.2.48";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ apacheHttpd jdk ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides web server plugins to connect web servers with Tomcat";
     homepage = "https://tomcat.apache.org/download-connectors.cgi";
     license = licenses.asl20;
diff --git a/pkgs/servers/http/apt-cacher-ng/default.nix b/pkgs/servers/http/apt-cacher-ng/default.nix
index f8c4b80020453..1f5e861e60c95 100644
--- a/pkgs/servers/http/apt-cacher-ng/default.nix
+++ b/pkgs/servers/http/apt-cacher-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , bzip2
 , cmake
 , doxygen
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake doxygen pkgconfig ];
   buildInputs = [ bzip2 fuse libevent lzma openssl systemd tcp_wrappers zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A caching proxy specialized for linux distribution files";
     homepage = "https://www.unix-ag.uni-kl.de/~bloch/acng/";
     license = licenses.gpl2;
diff --git a/pkgs/servers/http/couchdb/2.0.0.nix b/pkgs/servers/http/couchdb/2.0.0.nix
index 737947c0524b6..2881a3dc196b9 100644
--- a/pkgs/servers/http/couchdb/2.0.0.nix
+++ b/pkgs/servers/http/couchdb/2.0.0.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, erlang, icu, openssl, spidermonkey_1_8_5
+{ lib, stdenv, fetchurl, erlang, icu, openssl, spidermonkey_1_8_5
 , coreutils, bash, makeWrapper, python3 }:
 
 stdenv.mkDerivation rec {
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/couchdb --suffix PATH : ${bash}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database that uses JSON for documents, JavaScript for MapReduce queries, and regular HTTP for an API";
     homepage = "http://couchdb.apache.org";
     license = licenses.asl20;
diff --git a/pkgs/servers/http/couchdb/3.nix b/pkgs/servers/http/couchdb/3.nix
index bb856d7aa07db..94b94081d430e 100644
--- a/pkgs/servers/http/couchdb/3.nix
+++ b/pkgs/servers/http/couchdb/3.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, erlang, icu, openssl, spidermonkey_68
+{ lib, stdenv, fetchurl, erlang, icu, openssl, spidermonkey_68
 , coreutils, bash, makeWrapper, python3 }:
 
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     cp -r rel/couchdb/* $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database that uses JSON for documents, JavaScript for MapReduce queries, and regular HTTP for an API";
     homepage = "http://couchdb.apache.org";
     license = licenses.asl20;
diff --git a/pkgs/servers/http/couchdb/default.nix b/pkgs/servers/http/couchdb/default.nix
index b484cce15a26c..91b636cfdde25 100644
--- a/pkgs/servers/http/couchdb/default.nix
+++ b/pkgs/servers/http/couchdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, erlang, icu, openssl, spidermonkey_1_8_5, curl, help2man
+{ lib, stdenv, fetchurl, erlang, icu, openssl, spidermonkey_1_8_5, curl, help2man
 , sphinx, which, file, pkgconfig, getopt }:
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     "--enable-js-trunk"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A database that uses JSON for documents, JavaScript for MapReduce queries, and regular HTTP for an API";
     homepage = "http://couchdb.apache.org";
     license = licenses.asl20;
diff --git a/pkgs/servers/http/darkhttpd/default.nix b/pkgs/servers/http/darkhttpd/default.nix
index 4bcb16a04ea78..84adea1f4dc47 100644
--- a/pkgs/servers/http/darkhttpd/default.nix
+++ b/pkgs/servers/http/darkhttpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "darkhttpd";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     head -n 18 darkhttpd.c > "$out/share/licenses/darkhttpd/LICENSE"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small and secure static webserver";
     homepage    = "https://unix4lyfe.org/darkhttpd/";
     license     = licenses.bsd3;
diff --git a/pkgs/servers/http/gatling/default.nix b/pkgs/servers/http/gatling/default.nix
index 0c095c55e970e..145a045014b80 100644
--- a/pkgs/servers/http/gatling/default.nix
+++ b/pkgs/servers/http/gatling/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libowfat, libcap, zlib, openssl }:
+{ lib, stdenv, fetchurl, libowfat, libcap, zlib, openssl }:
 
 let
   version = "0.16";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     make gatling
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high performance web server";
     homepage = "http://www.fefe.de/gatling/";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/servers/http/h2o/default.nix b/pkgs/servers/http/h2o/default.nix
index f77307fd53ea4..a53be3e2aa6e7 100644
--- a/pkgs/servers/http/h2o/default.nix
+++ b/pkgs/servers/http/h2o/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgconfig, cmake, ninja
 , openssl, libuv, zlib
 }:
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig cmake ninja ];
   buildInputs = [ openssl libuv zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimized HTTP/1 and HTTP/2 server";
     homepage    = "https://h2o.examp1e.net";
     license     = licenses.mit;
diff --git a/pkgs/servers/http/hiawatha/default.nix b/pkgs/servers/http/hiawatha/default.nix
index 7def709a84082..3a4f44ebf8ca9 100644
--- a/pkgs/servers/http/hiawatha/default.nix
+++ b/pkgs/servers/http/hiawatha/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 
 , cmake
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     ( if enableToolkit   then "-DENABLE_TOOLKIT=on"     else "-DENABLE_TOOLKIT=off"     )
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.hiawatha-webserver.org";
     description = "An advanced and secure webserver";
     license = licenses.gpl2;
diff --git a/pkgs/servers/http/hyp/default.nix b/pkgs/servers/http/hyp/default.nix
index 6a16ee412f514..52f345d547719 100644
--- a/pkgs/servers/http/hyp/default.nix
+++ b/pkgs/servers/http/hyp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3Packages }:
+{ lib, stdenv, fetchurl, python3Packages }:
 
 python3Packages.buildPythonPackage rec {
   pname = "hyp-server";
@@ -9,7 +9,7 @@ python3Packages.buildPythonPackage rec {
     sha256 = "1lafjdcn9nnq6xc3hhyizfwh6l69lc7rixn6dx65aq71c913jc15";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Hyperminimal https server";
     homepage    = "https://github.com/rnhmjoj/hyp";
     license     = with licenses; [gpl3Plus mit];
diff --git a/pkgs/servers/http/jboss/default.nix b/pkgs/servers/http/jboss/default.nix
index 00ed93c860c1f..ba89d19db34b1 100644
--- a/pkgs/servers/http/jboss/default.nix
+++ b/pkgs/servers/http/jboss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, jdk }:
+{ lib, stdenv, fetchurl, unzip, jdk }:
 
 stdenv.mkDerivation {
   name = "jboss-as-7.1.1.Final";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     find $out/bin -name \*.sh -print0 | xargs -0 sed -i -e '/#!\/bin\/sh/aJAVA_HOME=${jdk}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.jboss.org/";
     description = "Open Source J2EE application server";
     license = licenses.lgpl21;
diff --git a/pkgs/servers/http/lighttpd/default.nix b/pkgs/servers/http/lighttpd/default.nix
index d90357044f54f..a3f0b045aa111 100644
--- a/pkgs/servers/http/lighttpd/default.nix
+++ b/pkgs/servers/http/lighttpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, pkgconfig, pcre, libxml2, zlib, bzip2, which, file
+{ lib, stdenv, buildPackages, fetchurl, pkgconfig, pcre, libxml2, zlib, bzip2, which, file
 , openssl, enableMagnet ? false, lua5_1 ? null
 , enableMysql ? false, libmysqlclient ? null
 , enableLdap ? false, openldap ? null
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     rm "$out/share/lighttpd/doc/config/vhosts.d/Makefile"*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight high-performance web server";
     homepage = "http://www.lighttpd.net/";
     license = stdenv.lib.licenses.bsd3;
diff --git a/pkgs/servers/http/lwan/default.nix b/pkgs/servers/http/lwan/default.nix
index fb8bc03a1d522..b1764b553694e 100644
--- a/pkgs/servers/http/lwan/default.nix
+++ b/pkgs/servers/http/lwan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, zlib, cmake, jemalloc }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, zlib, cmake, jemalloc }:
 
 stdenv.mkDerivation rec {
   pname = "lwan";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ jemalloc zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight high-performance multi-threaded web server";
     longDescription = "A lightweight and speedy web server with a low memory
       footprint (~500KiB for 10k idle connections), with minimal system calls and
diff --git a/pkgs/servers/http/micro-httpd/default.nix b/pkgs/servers/http/micro-httpd/default.nix
index d99af7a81aefc..99960d6cb7194 100644
--- a/pkgs/servers/http/micro-httpd/default.nix
+++ b/pkgs/servers/http/micro-httpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "micro-httpd-20140814";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     mkdir -p $out/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://acme.com/software/micro_httpd/";
     description = "A really small HTTP server";
     license     = licenses.bsd2;
diff --git a/pkgs/servers/http/spawn-fcgi/default.nix b/pkgs/servers/http/spawn-fcgi/default.nix
index c24b0b4c1a945..090450ba9688c 100644
--- a/pkgs/servers/http/spawn-fcgi/default.nix
+++ b/pkgs/servers/http/spawn-fcgi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchsvn, autoconf, automake }:
+{ lib, stdenv, fetchsvn, autoconf, automake }:
 
 stdenv.mkDerivation rec {
   pname = "spawn-fcgi";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://redmine.lighttpd.net/projects/spawn-fcgi";
     description = "Provides an interface to external programs that support the FastCGI interface";
     license     = licenses.bsd3;
diff --git a/pkgs/servers/http/tomcat/tomcat-native.nix b/pkgs/servers/http/tomcat/tomcat-native.nix
index 55eb277522a15..313066d30e1d9 100644
--- a/pkgs/servers/http/tomcat/tomcat-native.nix
+++ b/pkgs/servers/http/tomcat/tomcat-native.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, apr, jdk, openssl }:
+{ lib, stdenv, fetchurl, apr, jdk, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "tomcat-native";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "--with-ssl=${openssl.dev}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An optional component for use with Apache Tomcat that allows Tomcat to use certain native resources for performance, compatibility, etc";
     homepage = "https://tomcat.apache.org/native-doc/";
     license = licenses.asl20;
diff --git a/pkgs/servers/http/webfs/default.nix b/pkgs/servers/http/webfs/default.nix
index cb95673b5bb18..1281dee22be3e 100644
--- a/pkgs/servers/http/webfs/default.nix
+++ b/pkgs/servers/http/webfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl }:
+{ lib, stdenv, fetchurl, openssl }:
 let
   # Let's not pull the whole apache httpd package
   mime_file = fetchurl {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     "prefix=$(out)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP server for purely static content";
     homepage    = "http://linux.bytesex.org/misc/webfs.html";
     license     = licenses.gpl2;
diff --git a/pkgs/servers/http/yaws/default.nix b/pkgs/servers/http/yaws/default.nix
index 1d57a951dc7b2..be22ebdd36c9d 100644
--- a/pkgs/servers/http/yaws/default.nix
+++ b/pkgs/servers/http/yaws/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, erlang, pam, perl }:
+{lib, stdenv, fetchurl, erlang, pam, perl }:
 
 stdenv.mkDerivation rec {
   pname = "yaws";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     sed -i "s#which #type -P #" $out/bin/yaws
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high performance HTTP 1.1 server in Erlang";
     homepage = "http://yaws.hyber.org";
     license = licenses.bsd2;
diff --git a/pkgs/servers/hydron/default.nix b/pkgs/servers/hydron/default.nix
index 28c92d073ff34..3a67f61434834 100644
--- a/pkgs/servers/hydron/default.nix
+++ b/pkgs/servers/hydron/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, pkgconfig, ffmpeg-full, graphicsmagick
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, pkgconfig, ffmpeg-full, graphicsmagick
 , quicktemplate, go-bindata, easyjson }:
 
 buildGoPackage {
@@ -18,7 +18,7 @@ buildGoPackage {
 
   buildInputs = [ ffmpeg-full graphicsmagick quicktemplate easyjson ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bakape/hydron";
     description = "High performance media tagger and organizer";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/servers/icecream/default.nix b/pkgs/servers/icecream/default.nix
index 1800700b04086..573dcee7170e2 100644
--- a/pkgs/servers/icecream/default.nix
+++ b/pkgs/servers/icecream/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, docbook2x, libarchive, libcap_ng, lzo, zstd, docbook_xml_dtd_45 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, docbook2x, libarchive, libcap_ng, lzo, zstd, docbook_xml_dtd_45 }:
 
 stdenv.mkDerivation rec {
   pname = "icecream";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook docbook2x ];
   buildInputs = [ libarchive libcap_ng lzo zstd docbook_xml_dtd_45 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Distributed compiler with a central scheduler to share build load";
     inherit (src.meta) homepage;
     license = licenses.gpl2;
diff --git a/pkgs/servers/identd/nullidentdmod/default.nix b/pkgs/servers/identd/nullidentdmod/default.nix
index 4fdc7f6d50309..b383135f2eb52 100644
--- a/pkgs/servers/identd/nullidentdmod/default.nix
+++ b/pkgs/servers/identd/nullidentdmod/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ... }: stdenv.mkDerivation rec {
+{ lib, stdenv, fetchFromGitHub, ... }: stdenv.mkDerivation rec {
   pname = "nullidentdmod";
   version = "1.3";
 
@@ -15,7 +15,7 @@
     install -Dm755 nullidentdmod $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple identd that just replies with a random string or customized userid";
     license = licenses.gpl2;
     homepage = "http://acidhub.click/NullidentdMod";
diff --git a/pkgs/servers/identd/oidentd/default.nix b/pkgs/servers/identd/oidentd/default.nix
index 46a26a659ac1a..390b3cbc46a49 100644
--- a/pkgs/servers/identd/oidentd/default.nix
+++ b/pkgs/servers/identd/oidentd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bison, flex }:
+{ lib, stdenv, fetchurl, bison, flex }:
 
 stdenv.mkDerivation rec {
   pname = "oidentd";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     sha256 = "1d5mqlknfywbx2bgj7ap7x6qzvz257hhqcqhy6zk45dqpsirdn7a";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configurable Ident protocol server";
     homepage = "https://oidentd.janikrabe.com/";
     license = licenses.gpl2;
diff --git a/pkgs/servers/irc/atheme/default.nix b/pkgs/servers/irc/atheme/default.nix
index 06119861b9f4b..95019fb939f4b 100644
--- a/pkgs/servers/irc/atheme/default.nix
+++ b/pkgs/servers/irc/atheme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, libmowgli, pkgconfig, git, gettext, pcre, libidn, cracklib, openssl }:
+{ lib, stdenv, fetchgit, libmowgli, pkgconfig, git, gettext, pcre, libidn, cracklib, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "atheme";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     "--enable-reproducible-builds"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of services for IRC networks";
     homepage = "https://atheme.github.io/";
     license = licenses.isc;
diff --git a/pkgs/servers/irc/charybdis/default.nix b/pkgs/servers/irc/charybdis/default.nix
index ebc0b47f8b7bd..bf31633e41e3e 100644
--- a/pkgs/servers/irc/charybdis/default.nix
+++ b/pkgs/servers/irc/charybdis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, bison, flex, openssl, gnutls }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, bison, flex, openssl, gnutls }:
 
 stdenv.mkDerivation rec {
   name = "charybdis-4.1.2";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook bison flex ];
   buildInputs = [ openssl gnutls ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IRCv3 server designed to be highly scalable";
     homepage    = "https://github.com/charybdis-ircd/charybdis";
     license     = licenses.gpl2;
diff --git a/pkgs/servers/irc/robustirc-bridge/default.nix b/pkgs/servers/irc/robustirc-bridge/default.nix
index 84b80203f57cc..d0b192010c101 100644
--- a/pkgs/servers/irc/robustirc-bridge/default.nix
+++ b/pkgs/servers/irc/robustirc-bridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "robustirc-bridge";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   passthru.tests.robustirc-bridge = nixosTests.robustirc-bridge;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bridge to robustirc.net-IRC-Network";
     homepage = "https://robustirc.net/";
     license = licenses.bsd3;
diff --git a/pkgs/servers/irc/solanum/default.nix b/pkgs/servers/irc/solanum/default.nix
index 9455929e3bee9..d5ee98a18043e 100644
--- a/pkgs/servers/irc/solanum/default.nix
+++ b/pkgs/servers/irc/solanum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkg-config
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
 
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An IRCd for unified networks";
     homepage = "https://github.com/solanum-ircd/solanum";
     license = licenses.gpl2Only;
diff --git a/pkgs/servers/irker/default.nix b/pkgs/servers/irker/default.nix
index f91b5a73b7d05..8f6f31bba35dd 100644
--- a/pkgs/servers/irker/default.nix
+++ b/pkgs/servers/irker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, python, pkgconfig
+{ lib, stdenv, fetchFromGitLab, python, pkgconfig
 , xmlto, docbook2x, docbook_xsl, docbook_xml_dtd_412 }:
 
 stdenv.mkDerivation {
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     "DESTDIR=$$out"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IRC client that runs as a daemon accepting notification requests";
     homepage = "https://gitlab.com/esr/irker";
     license = licenses.bsd2;
diff --git a/pkgs/servers/isso/default.nix b/pkgs/servers/isso/default.nix
index d2387a1fa6295..4680c37c85e37 100644
--- a/pkgs/servers/isso/default.nix
+++ b/pkgs/servers/isso/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 with python3Packages; buildPythonApplication rec {
 
@@ -35,7 +35,7 @@ with python3Packages; buildPythonApplication rec {
     ${python.interpreter} setup.py nosetests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A commenting server similar to Disqus";
     homepage = "https://posativ.org/isso/";
     license = licenses.mit;
diff --git a/pkgs/servers/jackett/default.nix b/pkgs/servers/jackett/default.nix
index 61a845d75f573..9fda62a68afa3 100644
--- a/pkgs/servers/jackett/default.nix
+++ b/pkgs/servers/jackett/default.nix
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : ${stdenv.lib.makeLibraryPath [ curl icu60 openssl zlib ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "API Support for your favorite torrent trackers";
     homepage = "https://github.com/Jackett/Jackett/";
     license = licenses.gpl2;
diff --git a/pkgs/servers/jetbrains/youtrack.nix b/pkgs/servers/jetbrains/youtrack.nix
index 2f8241e7b09d1..a965a2dbfeec7 100644
--- a/pkgs/servers/jetbrains/youtrack.nix
+++ b/pkgs/servers/jetbrains/youtrack.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre, gawk }:
+{ lib, stdenv, fetchurl, makeWrapper, jre, gawk }:
 
 stdenv.mkDerivation rec {
   pname = "youtrack";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Issue tracking and project management tool for developers";
     maintainers = with maintainers; [ yorickvp ];
     # https://www.jetbrains.com/youtrack/buy/license.html
diff --git a/pkgs/servers/jicofo/default.nix b/pkgs/servers/jicofo/default.nix
index 266b94dbffa13..f706438d6c146 100644
--- a/pkgs/servers/jicofo/default.nix
+++ b/pkgs/servers/jicofo/default.nix
@@ -1,4 +1,4 @@
-{ pkgs, stdenv, fetchurl, dpkg, jre_headless, nixosTests }:
+{ pkgs, lib, stdenv, fetchurl, dpkg, jre_headless, nixosTests }:
 
 let
   pname = "jicofo";
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
     single-node-smoke-test = nixosTests.jitsi-meet;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A server side focus component used in Jitsi Meet conferences";
     longDescription = ''
       JItsi COnference FOcus is a server side focus component used in Jitsi Meet conferences.
diff --git a/pkgs/servers/jitsi-videobridge/default.nix b/pkgs/servers/jitsi-videobridge/default.nix
index 09d7af185615e..d9dd84c7cfb8d 100644
--- a/pkgs/servers/jitsi-videobridge/default.nix
+++ b/pkgs/servers/jitsi-videobridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, dpkg, jre_headless, nixosTests }:
+{ lib, stdenv, fetchurl, makeWrapper, dpkg, jre_headless, nixosTests }:
 
 let
   pname = "jitsi-videobridge2";
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
     single-host-smoke-test = nixosTests.jitsi-meet;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A WebRTC compatible video router";
     longDescription = ''
       Jitsi Videobridge is an XMPP server component that allows for multiuser video communication.
diff --git a/pkgs/servers/kapowbang/default.nix b/pkgs/servers/kapowbang/default.nix
index 27c5feb0d8d13..a0096eab026c7 100644
--- a/pkgs/servers/kapowbang/default.nix
+++ b/pkgs/servers/kapowbang/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "kapowbang";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BBVA/kapow";
     description = "Expose command-line tools over HTTP";
     license = licenses.asl20;
diff --git a/pkgs/servers/keycloak/default.nix b/pkgs/servers/keycloak/default.nix
index 6340f734d08c8..91234cdb41005 100644
--- a/pkgs/servers/keycloak/default.nix
+++ b/pkgs/servers/keycloak/default.nix
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests = nixosTests.keycloak;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://www.keycloak.org/";
     description = "Identity and access management for modern applications and services";
     license     = licenses.asl20;
diff --git a/pkgs/servers/kippo/default.nix b/pkgs/servers/kippo/default.nix
index e91c35538a255..a3c6d683a1ba9 100644
--- a/pkgs/servers/kippo/default.nix
+++ b/pkgs/servers/kippo/default.nix
@@ -25,7 +25,7 @@
 #
 # Use this package at your own risk.
 
-{stdenv, fetchurl, pythonPackages }:
+{lib, stdenv, fetchurl, pythonPackages }:
 
 let
 
@@ -48,7 +48,7 @@ let
     # details.
     postInstall = "$out/bin/twistd --help > /dev/null";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://twistedmatrix.com/";
       description = "Twisted, an event-driven networking engine written in Python";
       longDescription = ''
@@ -85,7 +85,7 @@ in stdenv.mkDerivation rec {
 
     passthru.twisted = twisted_13;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/desaster/kippo";
       description = "SSH Honeypot";
       longDescription = ''
diff --git a/pkgs/servers/ldap/389/default.nix b/pkgs/servers/ldap/389/default.nix
index 8de4c471e22a9..9b518bf80a3ec 100644
--- a/pkgs/servers/ldap/389/default.nix
+++ b/pkgs/servers/ldap/389/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, autoreconfHook, pkgconfig, doxygen, perl, pam, nspr, nss, openldap
+{ lib, stdenv, fetchurl, fetchpatch, autoreconfHook, pkgconfig, doxygen, perl, pam, nspr, nss, openldap
 , db, cyrus_sasl, svrcore, icu, net-snmp, kerberos, pcre, perlPackages, libevent, openssl, python
 }:
 
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
 
   passthru.version = version;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.port389.org/";
     description = "Enterprise-class Open Source LDAP server for Linux";
     license = licenses.gpl3Plus;
diff --git a/pkgs/servers/lidarr/default.nix b/pkgs/servers/lidarr/default.nix
index 8074329aa1df7..46c88b95c3782 100644
--- a/pkgs/servers/lidarr/default.nix
+++ b/pkgs/servers/lidarr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mono, libmediainfo, sqlite, curl, chromaprint, makeWrapper }:
+{ lib, stdenv, fetchurl, mono, libmediainfo, sqlite, curl, chromaprint, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "lidarr";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
           curl sqlite libmediainfo ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Usenet/BitTorrent music downloader";
     homepage = "https://lidarr.audio/";
     license = licenses.gpl3;
diff --git a/pkgs/servers/limesurvey/default.nix b/pkgs/servers/limesurvey/default.nix
index 023e1bbd2ccf7..261285341c42c 100644
--- a/pkgs/servers/limesurvey/default.nix
+++ b/pkgs/servers/limesurvey/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, writeText, nixosTests }:
+{ lib, stdenv, fetchFromGitHub, writeText, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "limesurvey";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     smoke-test = nixosTests.limesurvey;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source survey application";
     license = licenses.gpl2;
     homepage = "https://www.limesurvey.org";
diff --git a/pkgs/servers/livepeer/default.nix b/pkgs/servers/livepeer/default.nix
index 959e82d259b1e..6d5506ded88e1 100644
--- a/pkgs/servers/livepeer/default.nix
+++ b/pkgs/servers/livepeer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule
+{ lib, stdenv, fetchFromGitHub, buildGoModule
 , pkg-config, ffmpeg, gnutls
 }:
 
@@ -23,7 +23,7 @@ buildGoModule rec {
 
   buildInputs = [ ffmpeg gnutls ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official Go implementation of the Livepeer protocol";
     homepage = "https://livepeer.org";
     license = licenses.mit;
diff --git a/pkgs/servers/ma1sd/default.nix b/pkgs/servers/ma1sd/default.nix
index a4a95197d0dc9..055136c207197 100644
--- a/pkgs/servers/ma1sd/default.nix
+++ b/pkgs/servers/ma1sd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jre, git, gradle_5, perl, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, jre, git, gradle_5, perl, makeWrapper }:
 
 let
   name = "ma1sd-${version}";
@@ -59,7 +59,7 @@ stdenv.mkDerivation {
     makeWrapper ${jre}/bin/java $out/bin/ma1sd --add-flags "-jar $out/lib/ma1sd.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a federated matrix identity server; fork of mxisd";
     homepage = "https://github.com/ma1uta/ma1sd";
     license = licenses.agpl3;
diff --git a/pkgs/servers/mail/archiveopteryx/default.nix b/pkgs/servers/mail/archiveopteryx/default.nix
index 962d5603e4728..4cc612ef89a1d 100644
--- a/pkgs/servers/mail/archiveopteryx/default.nix
+++ b/pkgs/servers/mail/archiveopteryx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, perl, zlib, jam }:
+{ lib, stdenv, fetchurl, openssl, perl, zlib, jam }:
 stdenv.mkDerivation rec {
   version = "3.2.0";
   pname = "archiveopteryx";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     mv installroot/$out $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://archiveopteryx.org/";
     description = "An advanced PostgreSQL-based IMAP/POP server";
     license = licenses.postgresql;
diff --git a/pkgs/servers/mail/clamsmtp/default.nix b/pkgs/servers/mail/clamsmtp/default.nix
index 327e545adcea7..fc3212453d88d 100644
--- a/pkgs/servers/mail/clamsmtp/default.nix
+++ b/pkgs/servers/mail/clamsmtp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "clamsmtp-" + version;
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   patches = [ ./header-order.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SMTP filter that allows to check for viruses using the ClamAV
                    anti-virus software";
     homepage = "http://thewalter.net/stef/software/clamsmtp/";
diff --git a/pkgs/servers/mail/dkimproxy/default.nix b/pkgs/servers/mail/dkimproxy/default.nix
index 376beac7e36fc..f4905ecf4d8fb 100644
--- a/pkgs/servers/mail/dkimproxy/default.nix
+++ b/pkgs/servers/mail/dkimproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, perlPackages, fetchurl }:
+{ lib, stdenv, perlPackages, fetchurl }:
 
 let
   pkg = "dkimproxy";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ perlPackages.perl ];
   propagatedBuildInputs = with perlPackages; [ Error MailDKIM MIMETools NetServer ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SMTP-proxy that signs and/or verifies emails";
     homepage = "http://dkimproxy.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/servers/mail/dovecot/plugins/fts_xapian/default.nix b/pkgs/servers/mail/dovecot/plugins/fts_xapian/default.nix
index 8a0f2d4efab2d..0b61a779c4836 100644
--- a/pkgs/servers/mail/dovecot/plugins/fts_xapian/default.nix
+++ b/pkgs/servers/mail/dovecot/plugins/fts_xapian/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, pkg-config, dovecot, libtool, xapian, icu64, sqlite }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, pkg-config, dovecot, libtool, xapian, icu64, sqlite }:
 stdenv.mkDerivation {
   pname = "fts-xapian";
   version = "1.3.1";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     "--with-moduledir=$(out)/lib/dovecot"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/grosjo/fts-xapian";
     description = "Dovecot FTS plugin based on Xapian";
     license = licenses.lgpl21;
diff --git a/pkgs/servers/mail/dovecot/plugins/pigeonhole/default.nix b/pkgs/servers/mail/dovecot/plugins/pigeonhole/default.nix
index a65bc28ec40bc..e5a07aa3c2784 100644
--- a/pkgs/servers/mail/dovecot/plugins/pigeonhole/default.nix
+++ b/pkgs/servers/mail/dovecot/plugins/pigeonhole/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dovecot, openssl }:
+{ lib, stdenv, fetchurl, dovecot, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "dovecot-pigeonhole";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pigeonhole.dovecot.org/";
     description = "A sieve plugin for the Dovecot IMAP server";
     license = licenses.lgpl21;
diff --git a/pkgs/servers/mail/exim/default.nix b/pkgs/servers/mail/exim/default.nix
index 8bd197f46c1d3..25e1bb02dbed2 100644
--- a/pkgs/servers/mail/exim/default.nix
+++ b/pkgs/servers/mail/exim/default.nix
@@ -1,4 +1,4 @@
-{ coreutils, db, fetchurl, openssl, pcre, perl, pkgconfig, stdenv
+{ coreutils, db, fetchurl, openssl, pcre, perl, pkgconfig, lib, stdenv
 , enableLDAP ? false, openldap
 , enableMySQL ? false, libmysqlclient, zlib
 , enableAuthDovecot ? false, dovecot
@@ -99,7 +99,7 @@ stdenv.mkDerivation rec {
       done )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://exim.org/";
     description = "A mail transfer agent (MTA)";
     license = with licenses; [ gpl2Plus bsd3 ];
diff --git a/pkgs/servers/mail/mailhog/default.nix b/pkgs/servers/mail/mailhog/default.nix
index d0fded5c63b5b..f1ba497720a9d 100644
--- a/pkgs/servers/mail/mailhog/default.nix
+++ b/pkgs/servers/mail/mailhog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "MailHog";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "124216850572r1h0ii7ad6jd1cd5czcvkz7k2jzvjb4pv2kl8p3y";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web and API based SMTP testing";
     homepage = "https://github.com/mailhog/MailHog";
     changelog = "https://github.com/mailhog/MailHog/releases/tag/v${version}";
diff --git a/pkgs/servers/mail/mlmmj/default.nix b/pkgs/servers/mail/mlmmj/default.nix
index 4caa9e8bfefa1..e9d3bf9c8f323 100644
--- a/pkgs/servers/mail/mlmmj/default.nix
+++ b/pkgs/servers/mail/mlmmj/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     install -vDm 644 -t $out/share/doc/mlmmj/ $docfiles
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mlmmj.org";
     description = "Mailing List Management Made Joyful";
     maintainers = [ maintainers.edwtjo ];
diff --git a/pkgs/servers/mail/opensmtpd/default.nix b/pkgs/servers/mail/opensmtpd/default.nix
index a59e18837d7df..cd6a760b9e23c 100644
--- a/pkgs/servers/mail/opensmtpd/default.nix
+++ b/pkgs/servers/mail/opensmtpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, libtool, bison
+{ lib, stdenv, fetchurl, autoconf, automake, libtool, bison
 , libasr, libevent, zlib, libressl, db, pam, nixosTests
 }:
 
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     "localstatedir=\${TMPDIR}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.opensmtpd.org/";
     description = ''
       A free implementation of the server-side SMTP protocol as defined by
diff --git a/pkgs/servers/mail/opensmtpd/extras.nix b/pkgs/servers/mail/opensmtpd/extras.nix
index 6c29de8cddbc9..d3084ff258d67 100644
--- a/pkgs/servers/mail/opensmtpd/extras.nix
+++ b/pkgs/servers/mail/opensmtpd/extras.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, libevent, libasr,
+{ lib, stdenv, fetchurl, openssl, libevent, libasr,
   python2, pkgconfig, lua5, perl, libmysqlclient, postgresql, sqlite, hiredis,
   enablePython ? true,
   enableLua ? true,
@@ -81,7 +81,7 @@ stdenv.mkDerivation rec {
     + stdenv.lib.optionalString enableMysql
       " -L${libmysqlclient}/lib/mysql";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.opensmtpd.org/";
     description = "Extra plugins for the OpenSMTPD mail server";
     license = licenses.isc;
diff --git a/pkgs/servers/mail/postgrey/default.nix b/pkgs/servers/mail/postgrey/default.nix
index dffe0191a0a49..d0eaf40d06c70 100644
--- a/pkgs/servers/mail/postgrey/default.nix
+++ b/pkgs/servers/mail/postgrey/default.nix
@@ -15,7 +15,7 @@ in runCommand name {
     url = "https://postgrey.schweikert.ch/pub/${name}.tar.gz";
     sha256 = "1xx51xih4711vrvc6d57il9ccallbljj5zhgqdb07jzmz11rakgz";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A postfix policy server to provide greylisting";
     homepage = "https://postgrey.schweikert.ch/";
     platforms = postfix.meta.platforms;
diff --git a/pkgs/servers/mail/postsrsd/default.nix b/pkgs/servers/mail/postsrsd/default.nix
index 28d281dde158e..978a3f6216bc8 100644
--- a/pkgs/servers/mail/postsrsd/default.nix
+++ b/pkgs/servers/mail/postsrsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, help2man }:
+{ lib, stdenv, fetchFromGitHub, cmake, help2man }:
 
 stdenv.mkDerivation rec {
   pname = "postsrsd";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake help2man ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/roehling/postsrsd";
     description = "Postfix Sender Rewriting Scheme daemon";
     license = licenses.gpl2;
diff --git a/pkgs/servers/mail/rspamd/default.nix b/pkgs/servers/mail/rspamd/default.nix
index 71205ee093a46..ba69e99cc8b9a 100644
--- a/pkgs/servers/mail/rspamd/default.nix
+++ b/pkgs/servers/mail/rspamd/default.nix
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.rspamd = nixosTests.rspamd;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://rspamd.com";
     license = licenses.asl20;
     description = "Advanced spam filtering system";
diff --git a/pkgs/servers/mail/sympa/default.nix b/pkgs/servers/mail/sympa/default.nix
index 3e69274ff2d52..b3b7c742d7199 100644
--- a/pkgs/servers/mail/sympa/default.nix
+++ b/pkgs/servers/mail/sympa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, perl, fetchFromGitHub, autoreconfHook, nixosTests }:
+{ lib, stdenv, perl, fetchFromGitHub, autoreconfHook, nixosTests }:
 
 let
   dataDir = "/var/lib/sympa";
@@ -110,7 +110,7 @@ stdenv.mkDerivation rec {
     inherit (nixosTests) sympa;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source mailing list manager";
     homepage = "https://www.sympa.org";
     license = licenses.gpl2;
diff --git a/pkgs/servers/mail/system-sendmail/default.nix b/pkgs/servers/mail/system-sendmail/default.nix
index 7bd7df849244a..a8fb65c0f42eb 100644
--- a/pkgs/servers/mail/system-sendmail/default.nix
+++ b/pkgs/servers/mail/system-sendmail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, writeText, runtimeShell }:
+{ lib, stdenv, writeText, runtimeShell }:
 
 let script = writeText "script" ''
   #!${runtimeShell}
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/sendmail
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A sendmail wrapper that calls the system sendmail. Do not install as system-wide sendmail!
     '';
diff --git a/pkgs/servers/martin/default.nix b/pkgs/servers/martin/default.nix
index 2c506dca6af5d..e2ba917e5aba4 100644
--- a/pkgs/servers/martin/default.nix
+++ b/pkgs/servers/martin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, Security }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "martin";
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Blazing fast and lightweight PostGIS vector tiles server";
     homepage = "https://martin.urbica.co/";
     license = licenses.mit;
diff --git a/pkgs/servers/matrix-synapse/default.nix b/pkgs/servers/matrix-synapse/default.nix
index 112fdac53d3a2..6c6636b47ee06 100644
--- a/pkgs/servers/matrix-synapse/default.nix
+++ b/pkgs/servers/matrix-synapse/default.nix
@@ -73,7 +73,7 @@ buildPythonApplication rec {
   passthru.tools = tools;
   passthru.python = python3;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://matrix.org";
     description = "Matrix reference homeserver";
     license = licenses.asl20;
diff --git a/pkgs/servers/matterbridge/default.nix b/pkgs/servers/matterbridge/default.nix
index cab386d18f1e0..7cc1c89de6d4b 100644
--- a/pkgs/servers/matterbridge/default.nix
+++ b/pkgs/servers/matterbridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchurl }:
+{ lib, stdenv, buildGoModule, fetchurl }:
 
 buildGoModule rec {
   pname = "matterbridge";
@@ -13,7 +13,7 @@ buildGoModule rec {
     sha256 = "1s9y7m5xzmzcp8bphc1najrmci8rf8yvz8kwm2ggmchykw2q3jjg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple bridge between Mattermost, IRC, XMPP, Gitter, Slack, Discord, Telegram, Rocket.Chat, Hipchat(via xmpp), Matrix and Steam";
     homepage = "https://github.com/42wim/matterbridge";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/servers/mattermost/default.nix b/pkgs/servers/mattermost/default.nix
index 722802a019d25..f63f76efabae1 100644
--- a/pkgs/servers/mattermost/default.nix
+++ b/pkgs/servers/mattermost/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, buildGoPackage, buildEnv }:
+{ lib, stdenv, fetchurl, fetchFromGitHub, buildGoPackage, buildEnv }:
 
 let
   version = "5.25.3";
@@ -48,7 +48,7 @@ in
     name = "mattermost-${version}";
     paths = [ mattermost-server mattermost-webapp ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Open-source, self-hosted Slack-alternative";
       homepage = "https://www.mattermost.org";
       license = with licenses; [ agpl3 asl20 ];
diff --git a/pkgs/servers/mattermost/matterircd.nix b/pkgs/servers/mattermost/matterircd.nix
index ece2195d117a2..36edd851f36fe 100644
--- a/pkgs/servers/mattermost/matterircd.nix
+++ b/pkgs/servers/mattermost/matterircd.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "matterircd";
@@ -13,7 +13,7 @@ buildGoPackage rec {
 
   goPackagePath = "github.com/42wim/matterircd";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Minimal IRC server bridge to Mattermost";
     license = licenses.mit;
diff --git a/pkgs/servers/mautrix-whatsapp/default.nix b/pkgs/servers/mautrix-whatsapp/default.nix
index d6ab3ec34b869..eea8739292756 100644
--- a/pkgs/servers/mautrix-whatsapp/default.nix
+++ b/pkgs/servers/mautrix-whatsapp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, olm }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, olm }:
 
 buildGoModule rec {
   pname = "mautrix-whatsapp";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   runVend = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tulir/mautrix-whatsapp";
     description = "Matrix <-> Whatsapp hybrid puppeting/relaybot bridge";
     license = licenses.agpl3;
diff --git a/pkgs/servers/mediatomb/default.nix b/pkgs/servers/mediatomb/default.nix
index ff3d31ea2e72b..c310e17608e80 100644
--- a/pkgs/servers/mediatomb/default.nix
+++ b/pkgs/servers/mediatomb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit
+{ lib, stdenv, fetchgit
 , sqlite, expat, mp4v2, flac, spidermonkey_68, taglib, libexif, curl, ffmpeg_3, file
 , pkgconfig, autoreconfHook }:
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ sqlite expat spidermonkey_68 taglib libexif curl ffmpeg_3 file mp4v2 flac
                   pkgconfig autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mediatomb.cc";
     repositories.git = "git://mediatomb.git.sourceforge.net/gitroot/mediatomb/mediatomb";
     description = "UPnP MediaServer with a web user interface";
diff --git a/pkgs/servers/memcached/default.nix b/pkgs/servers/memcached/default.nix
index 0435d0e1d402a..9ea845338211f 100644
--- a/pkgs/servers/memcached/default.nix
+++ b/pkgs/servers/memcached/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, cyrus_sasl, libevent, nixosTests }:
+{lib, stdenv, fetchurl, cyrus_sasl, libevent, nixosTests }:
 
 stdenv.mkDerivation rec {
   version = "1.6.9";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE = [ "-Wno-error=deprecated-declarations" ]
     ++ stdenv.lib.optional stdenv.isDarwin "-Wno-error";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A distributed memory object caching system";
     repositories.git = "https://github.com/memcached/memcached.git";
     homepage = "http://memcached.org/";
diff --git a/pkgs/servers/metabase/default.nix b/pkgs/servers/metabase/default.nix
index 2c51b3399f060..b63428ba7d9d9 100644
--- a/pkgs/servers/metabase/default.nix
+++ b/pkgs/servers/metabase/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 stdenv.mkDerivation rec {
   pname = "metabase";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/metabase --add-flags "-jar $src"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The easy, open source way for everyone in your company to ask questions and learn from data";
     homepage    = "https://metabase.com";
     license     = licenses.agpl3;
diff --git a/pkgs/servers/microserver/default.nix b/pkgs/servers/microserver/default.nix
index 618b6f75e7b75..4090aebc8f004 100644
--- a/pkgs/servers/microserver/default.nix
+++ b/pkgs/servers/microserver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, darwin }:
 
 rustPlatform.buildRustPackage rec {
    pname = "microserver";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [ Security ]);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/robertohuertasm/microserver";
     description = "Simple ad-hoc server with SPA support";
     maintainers = with maintainers; [ flosse ];
diff --git a/pkgs/servers/miniflux/default.nix b/pkgs/servers/miniflux/default.nix
index 55a328b21d554..55dd3d8afc596 100644
--- a/pkgs/servers/miniflux/default.nix
+++ b/pkgs/servers/miniflux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles, nixosTests }:
 
 let
   pname = "miniflux";
@@ -31,7 +31,7 @@ in buildGoModule {
 
   passthru.tests = nixosTests.miniflux;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minimalist and opinionated feed reader";
     homepage = "https://miniflux.app/";
     license = licenses.asl20;
diff --git a/pkgs/servers/minio/default.nix b/pkgs/servers/minio/default.nix
index 32dee6460df7e..cd7e1d4141d09 100644
--- a/pkgs/servers/minio/default.nix
+++ b/pkgs/servers/minio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "minio";
@@ -33,7 +33,7 @@ buildGoModule rec {
 
   passthru.tests.minio = nixosTests.minio;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.minio.io/";
     description = "An S3-compatible object storage server";
     maintainers = with maintainers; [ eelco bachp ];
diff --git a/pkgs/servers/misc/airsonic/default.nix b/pkgs/servers/misc/airsonic/default.nix
index 852b5350bbae3..f20fed3e2df8e 100644
--- a/pkgs/servers/misc/airsonic/default.nix
+++ b/pkgs/servers/misc/airsonic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "airsonic";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     cp "$src" "$out/webapps/airsonic.war"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Personal media streamer";
     homepage = "https://airsonic.github.io";
     license = stdenv.lib.licenses.gpl3;
diff --git a/pkgs/servers/misc/oven-media-engine/default.nix b/pkgs/servers/misc/oven-media-engine/default.nix
index d6bdef6873256..f7c97abf104e6 100644
--- a/pkgs/servers/misc/oven-media-engine/default.nix
+++ b/pkgs/servers/misc/oven-media-engine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , srt
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
     install -Dm0644 ../misc/conf_examples/Logger.xml $out/share/examples/edge_conf/Logger.xml
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open-source streaming video service with sub-second latency";
     homepage    = "https://ovenmediaengine.com";
     license     = licenses.gpl2Only;
diff --git a/pkgs/servers/misc/qremotecontrol-server/default.nix b/pkgs/servers/misc/qremotecontrol-server/default.nix
index ddf69d1096896..4e752a0e2841d 100644
--- a/pkgs/servers/misc/qremotecontrol-server/default.nix
+++ b/pkgs/servers/misc/qremotecontrol-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , qmake4Hook
 , qt4
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --replace /usr $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl3;
     platforms = platforms.all;
     maintainers = with maintainers; [ fgaz ];
diff --git a/pkgs/servers/misc/subsonic/default.nix b/pkgs/servers/misc/subsonic/default.nix
index 9f7559872b9f1..4c5ea3fe6c6c4 100644
--- a/pkgs/servers/misc/subsonic/default.nix
+++ b/pkgs/servers/misc/subsonic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre }:
+{ lib, stdenv, fetchurl, jre }:
 
 stdenv.mkDerivation rec {
   pname = "subsonic";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://subsonic.org";
     description = "Personal media streamer";
     license = licenses.unfree;
diff --git a/pkgs/servers/monitoring/alertmanager-bot/default.nix b/pkgs/servers/monitoring/alertmanager-bot/default.nix
index f28ef6617c7a1..562bd1ea81594 100644
--- a/pkgs/servers/monitoring/alertmanager-bot/default.nix
+++ b/pkgs/servers/monitoring/alertmanager-bot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "alertmanager-bot";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bot for Prometheus' Alertmanager";
     homepage = "https://github.com/metalmatze/alertmanager-bot";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/cadvisor/default.nix b/pkgs/servers/monitoring/cadvisor/default.nix
index 3a9789ccf1698..04767d0f71cec 100644
--- a/pkgs/servers/monitoring/cadvisor/default.nix
+++ b/pkgs/servers/monitoring/cadvisor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "cadvisor";
@@ -26,7 +26,7 @@ buildGoModule rec {
     rm internal/container/mesos/handler_test.go
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Analyzes resource usage and performance characteristics of running docker containers";
     homepage = "https://github.com/google/cadvisor";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/consul-alerts/default.nix b/pkgs/servers/monitoring/consul-alerts/default.nix
index 9bece7cb2e0b8..896664658cf11 100644
--- a/pkgs/servers/monitoring/consul-alerts/default.nix
+++ b/pkgs/servers/monitoring/consul-alerts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "consul-alerts";
@@ -16,7 +16,7 @@ buildGoPackage rec {
     sha256 = "0836zicv76sd6ljhbbii1mrzh65pch10w3gfa128iynaviksbgn5";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extendable open source continuous integration server";
     homepage = "https://github.com/AcalephStorage/consul-alerts";
     # As per README
diff --git a/pkgs/servers/monitoring/fusion-inventory/default.nix b/pkgs/servers/monitoring/fusion-inventory/default.nix
index a7d2da6ac570f..a949287307897 100644
--- a/pkgs/servers/monitoring/fusion-inventory/default.nix
+++ b/pkgs/servers/monitoring/fusion-inventory/default.nix
@@ -73,7 +73,7 @@ perlPackages.buildPerlPackage rec {
 
   outputs = [ "out" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.fusioninventory.org";
     description = "FusionInventory unified Agent for UNIX, Linux, Windows and MacOSX";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/servers/monitoring/lcdproc/default.nix b/pkgs/servers/monitoring/lcdproc/default.nix
index e469ee6b40822..41247362799c5 100644
--- a/pkgs/servers/monitoring/lcdproc/default.nix
+++ b/pkgs/servers/monitoring/lcdproc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, makeWrapper, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, makeWrapper, pkgconfig
 , doxygen, freetype, libX11, libftdi, libusb-compat-0_1, libusb1, ncurses, perl }:
 
 stdenv.mkDerivation rec {
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
       --replace server/drivers/ $out/lib/lcdproc/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client/server suite for controlling a wide variety of LCD devices";
     homepage    = "http://lcdproc.org/";
     license     = licenses.gpl2;
diff --git a/pkgs/servers/monitoring/loki/default.nix b/pkgs/servers/monitoring/loki/default.nix
index a3e85e2b822e1..5e630623dabbe 100644
--- a/pkgs/servers/monitoring/loki/default.nix
+++ b/pkgs/servers/monitoring/loki/default.nix
@@ -28,7 +28,7 @@ buildGoModule rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Like Prometheus, but for logs";
     license = licenses.asl20;
     homepage = "https://grafana.com/oss/loki/";
diff --git a/pkgs/servers/monitoring/longview/default.nix b/pkgs/servers/monitoring/longview/default.nix
index 10f0f248a805a..96048005cb143 100644
--- a/pkgs/servers/monitoring/longview/default.nix
+++ b/pkgs/servers/monitoring/longview/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, perl, perlPackages, makeWrapper, glibc }:
+{lib, stdenv, fetchFromGitHub, perl, perlPackages, makeWrapper, glibc }:
 
 stdenv.mkDerivation rec {
   version = "1.1.5";
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
      --suffix PERL5LIB : $out --suffix INC : $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.linode.com/longview";
     description = "Collects all of your system-level metrics and sends them to Linode";
     license = licenses.gpl2Plus;
diff --git a/pkgs/servers/monitoring/munin/default.nix b/pkgs/servers/monitoring/munin/default.nix
index cfc66a9a76aa6..5168f2e7e9d63 100644
--- a/pkgs/servers/monitoring/munin/default.nix
+++ b/pkgs/servers/monitoring/munin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, which, coreutils, rrdtool, perlPackages
+{ lib, stdenv, fetchFromGitHub, makeWrapper, which, coreutils, rrdtool, perlPackages
 , python, ruby, jre, nettools, bc
 }:
 
@@ -126,7 +126,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Networked resource monitoring tool";
     longDescription = ''
       Munin is a monitoring tool that surveys all your computers and remembers
diff --git a/pkgs/servers/monitoring/nagios/plugins/check_ssl_cert.nix b/pkgs/servers/monitoring/nagios/plugins/check_ssl_cert.nix
index 35d02a5f9e2c7..90ff605b733cf 100644
--- a/pkgs/servers/monitoring/nagios/plugins/check_ssl_cert.nix
+++ b/pkgs/servers/monitoring/nagios/plugins/check_ssl_cert.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, file, openssl, makeWrapper, which, curl, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, file, openssl, makeWrapper, which, curl, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "check_ssl_cert";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ openssl file which curl ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Nagios plugin to check the CA and validity of an X.509 certificate";
     license = licenses.gpl3;
     platforms = platforms.all;
diff --git a/pkgs/servers/monitoring/net-snmp/default.nix b/pkgs/servers/monitoring/net-snmp/default.nix
index 160907d58fa69..d2f31e4c37271 100644
--- a/pkgs/servers/monitoring/net-snmp/default.nix
+++ b/pkgs/servers/monitoring/net-snmp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, autoreconfHook, removeReferencesTo
+{ lib, stdenv, fetchurl, fetchpatch, autoreconfHook, removeReferencesTo
 , file, openssl, perl, perlPackages, unzip, nettools, ncurses }:
 
 stdenv.mkDerivation rec {
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     find $lib/lib -type f -exec remove-references-to -t $dev '{}' +
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clients and server for the SNMP network monitoring protocol";
     homepage = "http://net-snmp.sourceforge.net/";
     license = licenses.bsd3;
diff --git a/pkgs/servers/monitoring/newrelic-sysmond/default.nix b/pkgs/servers/monitoring/newrelic-sysmond/default.nix
index 9413b5e73b6c4..3cdcbde161b7c 100644
--- a/pkgs/servers/monitoring/newrelic-sysmond/default.nix
+++ b/pkgs/servers/monitoring/newrelic-sysmond/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "newrelic-sysmond";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
       $out/bin/nrsysmond
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System-wide monitoring for newrelic";
     homepage = "https://newrelic.com/";
     license = licenses.unfree;
diff --git a/pkgs/servers/monitoring/plugins/esxi.nix b/pkgs/servers/monitoring/plugins/esxi.nix
index 2dc355ecac3d4..6b609d8160da6 100644
--- a/pkgs/servers/monitoring/plugins/esxi.nix
+++ b/pkgs/servers/monitoring/plugins/esxi.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 let
   bName = "check_esxi_hardware";
@@ -28,7 +28,7 @@ in python3Packages.buildPythonApplication rec {
 
   propagatedBuildInputs = with python3Packages; [ pywbem requests setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.claudiokuenzler.com/nagios-plugins/";
     license = licenses.gpl2;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/servers/monitoring/plugins/labs_consol_de.nix b/pkgs/servers/monitoring/plugins/labs_consol_de.nix
index e7a6fa6e40017..ee66cde0c5060 100644
--- a/pkgs/servers/monitoring/plugins/labs_consol_de.nix
+++ b/pkgs/servers/monitoring/plugins/labs_consol_de.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, autoreconfHook, makeWrapper
+{ lib, stdenv, fetchFromGitHub, fetchurl, autoreconfHook, makeWrapper
 , perlPackages, coreutils, gnused, gnugrep }:
 
 let
@@ -42,7 +42,7 @@ let
       done
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage    = "https://labs.consol.de/";
       license     = licenses.gpl2;
       maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/servers/monitoring/plugins/uptime.nix b/pkgs/servers/monitoring/plugins/uptime.nix
index d4861309fe581..04a3ba18aa794 100644
--- a/pkgs/servers/monitoring/plugins/uptime.nix
+++ b/pkgs/servers/monitoring/plugins/uptime.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation {
   pname = "check-uptime";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
 
   postInstall = "ln -sr $out/libexec $out/bin";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Uptime check plugin for Sensu/Nagios/others";
     homepage    = "https://github.com/madrisan/nagios-plugins-uptime";
     license     = licenses.gpl3;
diff --git a/pkgs/servers/monitoring/plugins/wmic-bin.nix b/pkgs/servers/monitoring/plugins/wmic-bin.nix
index c8f4eb77c468d..e091727e48e29 100644
--- a/pkgs/servers/monitoring/plugins/wmic-bin.nix
+++ b/pkgs/servers/monitoring/plugins/wmic-bin.nix
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     runHook postInstallCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WMI client for Linux (binary)";
     homepage    = "https://www.openvas.org";
     license     = licenses.mit;
diff --git a/pkgs/servers/monitoring/plugins/wmiplus/default.nix b/pkgs/servers/monitoring/plugins/wmiplus/default.nix
index dacd4e2c5b7bf..00474e12b9ac7 100644
--- a/pkgs/servers/monitoring/plugins/wmiplus/default.nix
+++ b/pkgs/servers/monitoring/plugins/wmiplus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, perlPackages, txt2man
+{ lib, stdenv, fetchFromGitHub, makeWrapper, perlPackages, txt2man
 , monitoring-plugins
 , wmic-bin ? null }:
 
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
     gzip $out/share/man/man1/check_wmi_plus.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A sensu/nagios plugin using WMI to query Windows hosts";
     homepage = "http://edcint.co.nz/checkwmiplus";
     license = licenses.gpl2;
diff --git a/pkgs/servers/monitoring/prometheus/alertmanager.nix b/pkgs/servers/monitoring/prometheus/alertmanager.nix
index f5c7c062c8783..a11fcf18c2534 100644
--- a/pkgs/servers/monitoring/prometheus/alertmanager.nix
+++ b/pkgs/servers/monitoring/prometheus/alertmanager.nix
@@ -1,4 +1,4 @@
-{ stdenv, go, buildGoPackage, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, go, buildGoPackage, fetchFromGitHub, installShellFiles }:
 
 buildGoPackage rec {
   pname = "alertmanager";
@@ -31,7 +31,7 @@ buildGoPackage rec {
     installShellCompletion amtool.bash
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Alert dispatcher for the Prometheus monitoring system";
     homepage = "https://github.com/prometheus/alertmanager";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/apcupsd-exporter.nix b/pkgs/servers/monitoring/prometheus/apcupsd-exporter.nix
index 33f93cd130dd4..648bb59b0d2dd 100644
--- a/pkgs/servers/monitoring/prometheus/apcupsd-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/apcupsd-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "apcupsd-exporter";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) apcupsd; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a Prometheus exporter for the apcupsd Network Information Server (NIS)";
     homepage = "https://github.com/mdlayher/apcupsd_exporter";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/aws-s3-exporter.nix b/pkgs/servers/monitoring/prometheus/aws-s3-exporter.nix
index 6f1a3f21f5b28..2548e196837a6 100644
--- a/pkgs/servers/monitoring/prometheus/aws-s3-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/aws-s3-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "aws-s3-exporter";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Exports Prometheus metrics about S3 buckets and objects";
     homepage = "https://github.com/ribbybibby/s3_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/bind-exporter.nix b/pkgs/servers/monitoring/prometheus/bind-exporter.nix
index 3913cbd5f852b..d6f0f864dec7c 100644
--- a/pkgs/servers/monitoring/prometheus/bind-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/bind-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "bind_exporter";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) bind; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for bind9 server";
     homepage = "https://github.com/digitalocean/bind_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/bird-exporter.nix b/pkgs/servers/monitoring/prometheus/bird-exporter.nix
index 39daab618b396..5670233b05473 100644
--- a/pkgs/servers/monitoring/prometheus/bird-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/bird-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "bird-exporter";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) bird; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for the bird routing daemon";
     homepage = "https://github.com/czerwonk/bird_exporter";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/blackbox-exporter.nix b/pkgs/servers/monitoring/prometheus/blackbox-exporter.nix
index e1fd31c3202f9..3140056a26967 100644
--- a/pkgs/servers/monitoring/prometheus/blackbox-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/blackbox-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "blackbox_exporter";
@@ -19,7 +19,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) blackbox; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Blackbox probing of endpoints over HTTP, HTTPS, DNS, TCP and ICMP";
     homepage = "https://github.com/prometheus/blackbox_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/collectd-exporter.nix b/pkgs/servers/monitoring/prometheus/collectd-exporter.nix
index 12f9cd3d35013..f86c3a42773c8 100644
--- a/pkgs/servers/monitoring/prometheus/collectd-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/collectd-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "collectd-exporter";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) collectd; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Relay server for exporting metrics from collectd to Prometheus";
     homepage = "https://github.com/prometheus/collectd_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/consul-exporter.nix b/pkgs/servers/monitoring/prometheus/consul-exporter.nix
index 20281313d0e2f..ab4b67402d395 100644
--- a/pkgs/servers/monitoring/prometheus/consul-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/consul-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "consul_exporter";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "16ibafcbpiplsh1awcvblzzf2cbr4baf8wiwpdpibgmcwwf9m5ya";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for Consul metrics";
     homepage = "https://github.com/prometheus/consul_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/dnsmasq-exporter.nix b/pkgs/servers/monitoring/prometheus/dnsmasq-exporter.nix
index 6f2fe462a4692..e01417186960c 100644
--- a/pkgs/servers/monitoring/prometheus/dnsmasq-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/dnsmasq-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "dnsmasq_exporter";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) dnsmasq; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "A dnsmasq exporter for Prometheus";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/dovecot-exporter.nix b/pkgs/servers/monitoring/prometheus/dovecot-exporter.nix
index 2d5f58a920be4..c0d96b08bb65a 100644
--- a/pkgs/servers/monitoring/prometheus/dovecot-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/dovecot-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "dovecot_exporter";
@@ -17,7 +17,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) dovecot; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Prometheus metrics exporter for Dovecot";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/fritzbox-exporter.nix b/pkgs/servers/monitoring/prometheus/fritzbox-exporter.nix
index 2f062cbfcfe86..bc9058e36d97c 100644
--- a/pkgs/servers/monitoring/prometheus/fritzbox-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/fritzbox-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "fritzbox-exporter";
@@ -18,7 +18,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) fritzbox; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus Exporter for FRITZ!Box (TR64 and UPnP)";
     homepage = "https://github.com/ndecker/fritzbox_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/gitlab-ci-pipelines-exporter.nix b/pkgs/servers/monitoring/prometheus/gitlab-ci-pipelines-exporter.nix
index e6dcfb4a346bc..718c8f2fcb136 100644
--- a/pkgs/servers/monitoring/prometheus/gitlab-ci-pipelines-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/gitlab-ci-pipelines-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gitlab-ci-pipelines-exporter";
@@ -17,7 +17,7 @@ buildGoPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus / OpenMetrics exporter for GitLab CI pipelines insights";
     homepage = "https://github.com/mvisonneau/gitlab-ci-pipelines-exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/haproxy-exporter.nix b/pkgs/servers/monitoring/prometheus/haproxy-exporter.nix
index aaff022df89fa..e12c76e09f047 100644
--- a/pkgs/servers/monitoring/prometheus/haproxy-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/haproxy-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "haproxy_exporter";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "0gx8pq67w71ch3g3c77xaz39msrd9graizc6d3shwabdjx35yc6q";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HAProxy Exporter for the Prometheus monitoring system";
     homepage = "https://github.com/prometheus/haproxy_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/jmx-httpserver.nix b/pkgs/servers/monitoring/prometheus/jmx-httpserver.nix
index 8cb9dbb2382cc..0c5aa7d8a438e 100644
--- a/pkgs/servers/monitoring/prometheus/jmx-httpserver.nix
+++ b/pkgs/servers/monitoring/prometheus/jmx-httpserver.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 let
   version = "0.10";
@@ -25,7 +25,7 @@ in stdenv.mkDerivation {
     makeWrapper "${jre}/bin/java" $out/bin/jmx_prometheus_httpserver --add-flags "-jar $out/libexec/$jarName"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/prometheus/jmx_exporter";
     description = "A process for exposing JMX Beans via HTTP for Prometheus consumption";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/keylight-exporter.nix b/pkgs/servers/monitoring/prometheus/keylight-exporter.nix
index f1a7d0c38e326..e7ecffee9927a 100644
--- a/pkgs/servers/monitoring/prometheus/keylight-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/keylight-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "keylight-exporter";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) keylight; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mdlayher/keylight_exporter";
     description = "Prometheus exporter for Elgato Key Light devices";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/lnd-exporter.nix b/pkgs/servers/monitoring/prometheus/lnd-exporter.nix
index cdece1212433f..1f9c38922ebcc 100644
--- a/pkgs/servers/monitoring/prometheus/lnd-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/lnd-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "lndmon";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) lnd; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Prometheus exporter for lnd (Lightning Network Daemon)";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/mail-exporter.nix b/pkgs/servers/monitoring/prometheus/mail-exporter.nix
index 95908e8b6a552..daad5dc81cd88 100644
--- a/pkgs/servers/monitoring/prometheus/mail-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/mail-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles, nixosTests }:
 
 buildGoModule {
   pname = "mailexporter";
@@ -22,7 +22,7 @@ buildGoModule {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) mail; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Export Prometheus-style metrics about mail server functionality";
     homepage = "https://github.com/cherti/mailexporter";
     license = licenses.gpl3;
diff --git a/pkgs/servers/monitoring/prometheus/mesos-exporter.nix b/pkgs/servers/monitoring/prometheus/mesos-exporter.nix
index ce04046280511..0fb7ee4fce326 100644
--- a/pkgs/servers/monitoring/prometheus/mesos-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/mesos-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "mesos_exporter";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./mesos-exporter_deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Export Mesos metrics to Prometheus";
     homepage = "https://github.com/prometheus/mesos_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/mikrotik-exporter.nix b/pkgs/servers/monitoring/prometheus/mikrotik-exporter.nix
index fe1ce5e4a9990..5044db4b1c148 100644
--- a/pkgs/servers/monitoring/prometheus/mikrotik-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/mikrotik-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "mikrotik-exporter-unstable";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) mikrotik; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Prometheus MikroTik device(s) exporter";
     license = licenses.bsd3;
diff --git a/pkgs/servers/monitoring/prometheus/minio-exporter/default.nix b/pkgs/servers/monitoring/prometheus/minio-exporter/default.nix
index c329050d4d1ae..78642821b9469 100644
--- a/pkgs/servers/monitoring/prometheus/minio-exporter/default.nix
+++ b/pkgs/servers/monitoring/prometheus/minio-exporter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, fetchpatch }:
 
 buildGoPackage rec {
   pname = "minio-exporter";
@@ -25,7 +25,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Prometheus exporter for Minio cloud storage server";
     homepage = "https://github.com/joe-pll/minio-exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/modemmanager-exporter.nix b/pkgs/servers/monitoring/prometheus/modemmanager-exporter.nix
index 34b927e0f7b4d..c23d44dca389e 100644
--- a/pkgs/servers/monitoring/prometheus/modemmanager-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/modemmanager-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "modemmanager-exporter";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) modemmanager; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mdlayher/modemmanager_exporter";
     description = "Prometheus exporter for ModemManager and its devices";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/mysqld-exporter.nix b/pkgs/servers/monitoring/prometheus/mysqld-exporter.nix
index 8787a39de32a7..ec181d2e11074 100644
--- a/pkgs/servers/monitoring/prometheus/mysqld-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/mysqld-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "mysqld_exporter";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "0nzbfzx4dzs3cagdid1fqddrqimgr8x6r8gmmxglrss05c8srgs8";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for MySQL server metrics";
     homepage = "https://github.com/prometheus/mysqld_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/nginx-exporter.nix b/pkgs/servers/monitoring/prometheus/nginx-exporter.nix
index 45612509e9484..259b4f752d37f 100644
--- a/pkgs/servers/monitoring/prometheus/nginx-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/nginx-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "nginx_exporter";
@@ -21,7 +21,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) nginx; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NGINX Prometheus Exporter for NGINX and NGINX Plus";
     homepage = "https://github.com/nginxinc/nginx-prometheus-exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/nginxlog-exporter.nix b/pkgs/servers/monitoring/prometheus/nginxlog-exporter.nix
index 771bbf39b081e..b15a54c6529ce 100644
--- a/pkgs/servers/monitoring/prometheus/nginxlog-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/nginxlog-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "nginxlog_exporter";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) nginxlog; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Export metrics from Nginx access log files to Prometheus";
     homepage = "https://github.com/martin-helmich/prometheus-nginxlog-exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/node-exporter.nix b/pkgs/servers/monitoring/prometheus/node-exporter.nix
index 38f054aeb2dd6..e2b601f56c143 100644
--- a/pkgs/servers/monitoring/prometheus/node-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/node-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "node_exporter";
@@ -25,7 +25,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) node; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for machine metrics";
     homepage = "https://github.com/prometheus/node_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/openvpn-exporter.nix b/pkgs/servers/monitoring/prometheus/openvpn-exporter.nix
index 5d62ff8c50f99..8e3daa931ee8f 100644
--- a/pkgs/servers/monitoring/prometheus/openvpn-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/openvpn-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "openvpn_exporter-unstable";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./openvpn-exporter-deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Prometheus exporter for OpenVPN";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/process-exporter.nix b/pkgs/servers/monitoring/prometheus/process-exporter.nix
index 53497b685b879..5a3c232ac85cd 100644
--- a/pkgs/servers/monitoring/prometheus/process-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/process-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "process-exporter";
@@ -19,7 +19,7 @@ buildGoPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter that mines /proc to report on selected processes";
     homepage = "https://github.com/ncabatoff/process-exporter";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/prom2json.nix b/pkgs/servers/monitoring/prometheus/prom2json.nix
index 101a53e7bb3ad..b333faf0bbdc9 100644
--- a/pkgs/servers/monitoring/prometheus/prom2json.nix
+++ b/pkgs/servers/monitoring/prometheus/prom2json.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "prom2json";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./prom2json_deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to scrape a Prometheus client and dump the result as JSON";
     homepage = "https://github.com/prometheus/prom2json";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/promscale.nix b/pkgs/servers/monitoring/prometheus/promscale.nix
index 081c7c8352e6c..f4a9070fd84aa 100644
--- a/pkgs/servers/monitoring/prometheus/promscale.nix
+++ b/pkgs/servers/monitoring/prometheus/promscale.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 }:
@@ -20,7 +20,7 @@ buildGoModule rec {
 
   doCheck = false; # Requires access to a docker daemon
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open-source analytical platform for Prometheus metrics";
     homepage = "https://github.com/timescale/promscale";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/pushgateway.nix b/pkgs/servers/monitoring/prometheus/pushgateway.nix
index d2d59c5e5deda..29897267b6e16 100644
--- a/pkgs/servers/monitoring/prometheus/pushgateway.nix
+++ b/pkgs/servers/monitoring/prometheus/pushgateway.nix
@@ -1,4 +1,4 @@
-{ stdenv, go, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, go, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "pushgateway";
@@ -39,7 +39,7 @@ buildGoPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows ephemeral and batch jobs to expose metrics to Prometheus";
     homepage = "https://github.com/prometheus/pushgateway";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/rabbitmq-exporter.nix b/pkgs/servers/monitoring/prometheus/rabbitmq-exporter.nix
index 07dadd7a6350b..41069dabc6ffe 100644
--- a/pkgs/servers/monitoring/prometheus/rabbitmq-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/rabbitmq-exporter.nix
@@ -1,5 +1,5 @@
 # This file was generated by https://github.com/kamilchm/go2nix v2.0-dev
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage {
   pname = "rabbitmq_exporter";
@@ -16,7 +16,7 @@ buildGoPackage {
 
   goDeps = ./rabbitmq-exporter_deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for RabbitMQ";
     homepage = "https://github.com/kbudde/rabbitmq_exporter";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/redis-exporter.nix b/pkgs/servers/monitoring/prometheus/redis-exporter.nix
index 9082fd81c6326..945f403041c61 100644
--- a/pkgs/servers/monitoring/prometheus/redis-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/redis-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "redis_exporter";
@@ -24,7 +24,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) redis; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for Redis metrics";
     inherit (src.meta) homepage;
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/smokeping-prober.nix b/pkgs/servers/monitoring/prometheus/smokeping-prober.nix
index 5e29e28e86cf6..f440be3f57a45 100644
--- a/pkgs/servers/monitoring/prometheus/smokeping-prober.nix
+++ b/pkgs/servers/monitoring/prometheus/smokeping-prober.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 let
   inherit (stdenv) lib;
@@ -33,7 +33,7 @@ buildGoModule rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) smokeping; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter for sending continual ICMP/UDP pings";
     homepage = "https://github.com/SuperQ/smokeping_prober";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/snmp-exporter.nix b/pkgs/servers/monitoring/prometheus/snmp-exporter.nix
index b6fafe5eaa43f..a71b03a2b41d6 100644
--- a/pkgs/servers/monitoring/prometheus/snmp-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/snmp-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, net-snmp, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, net-snmp, nixosTests }:
 
 buildGoPackage rec {
   pname = "snmp_exporter";
@@ -19,7 +19,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) snmp; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SNMP Exporter for Prometheus";
     homepage = "https://github.com/prometheus/snmp_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/sql-exporter.nix b/pkgs/servers/monitoring/prometheus/sql-exporter.nix
index c689cc1ed7930..d6c69a6089bf8 100644
--- a/pkgs/servers/monitoring/prometheus/sql-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/sql-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "sql_exporter";
@@ -13,7 +13,7 @@ buildGoModule rec {
     sha256 = "125brlxgwhkn3z5v0522gpm0sk6v905ghh05c4c3wf1hlm7bhnrc";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flexible SQL exporter for Prometheus";
     homepage = "https://github.com/justwatchcom/sql_exporter";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/statsd-exporter.nix b/pkgs/servers/monitoring/prometheus/statsd-exporter.nix
index cc6b55cac220b..a2b0f73904b9a 100644
--- a/pkgs/servers/monitoring/prometheus/statsd-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/statsd-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "statsd_exporter";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "0bgi00005j41p650rb6n1iz2w9m4p22d1w91f2hwlh5bqxf55al3";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Receives StatsD-style metrics and exports them to Prometheus";
     homepage = "https://github.com/prometheus/statsd_exporter";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/prometheus/surfboard-exporter.nix b/pkgs/servers/monitoring/prometheus/surfboard-exporter.nix
index d6f4bea153133..50915bf65f871 100644
--- a/pkgs/servers/monitoring/prometheus/surfboard-exporter.nix
+++ b/pkgs/servers/monitoring/prometheus/surfboard-exporter.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, nixosTests }:
 
 buildGoPackage rec {
   pname = "surfboard_exporter";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   passthru.tests = { inherit (nixosTests.prometheus-exporters) surfboard; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Arris Surfboard signal metrics exporter";
     homepage = "https://github.com/ipstatic/surfboard_exporter";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/prometheus/unifi-exporter/default.nix b/pkgs/servers/monitoring/prometheus/unifi-exporter/default.nix
index b4f58d789f6f1..669cf8ffaeaef 100644
--- a/pkgs/servers/monitoring/prometheus/unifi-exporter/default.nix
+++ b/pkgs/servers/monitoring/prometheus/unifi-exporter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "unifi-exporter";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "08zqvwvdqnc301f8jfh7bdvc138szw6xszx884b2v8w2x38w3rmn";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prometheus exporter that exposes metrics from a Ubiquiti UniFi Controller and UniFi devices";
     homepage = "https://github.com/mdlayher/unifi_exporter";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/riemann/default.nix b/pkgs/servers/monitoring/riemann/default.nix
index d993e1a08a903..03609e4d25a10 100644
--- a/pkgs/servers/monitoring/riemann/default.nix
+++ b/pkgs/servers/monitoring/riemann/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 stdenv.mkDerivation rec {
   pname = "riemann";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     wrapProgram "$out/bin/riemann" --prefix PATH : "${jre}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://riemann.io/";
     description = "A network monitoring system";
     license = licenses.epl10;
diff --git a/pkgs/servers/monitoring/seyren/default.nix b/pkgs/servers/monitoring/seyren/default.nix
index e926d797f9f9f..1d26afad3d8be 100644
--- a/pkgs/servers/monitoring/seyren/default.nix
+++ b/pkgs/servers/monitoring/seyren/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre }:
+{ lib, stdenv, fetchurl, makeWrapper, jre }:
 
 stdenv.mkDerivation rec {
   pname = "seyren";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     makeWrapper "${jre}/bin/java" "$out"/bin/seyren --add-flags "-jar $src"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An alerting dashboard for Graphite";
     homepage = "https://github.com/scobal/seyren";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/thanos/default.nix b/pkgs/servers/monitoring/thanos/default.nix
index f6415ca89852c..9955b4a83330c 100644
--- a/pkgs/servers/monitoring/thanos/default.nix
+++ b/pkgs/servers/monitoring/thanos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 buildGoModule rec {
   pname = "thanos";
   version = "0.17.2";
@@ -25,7 +25,7 @@ buildGoModule rec {
        -X ${t}.BuildDate=unknown
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Highly available Prometheus setup with long term storage capabilities";
     homepage = "https://github.com/thanos-io/thanos";
     license = licenses.asl20;
diff --git a/pkgs/servers/monitoring/uchiwa/default.nix b/pkgs/servers/monitoring/uchiwa/default.nix
index 9f0be68e168b6..121b31e46eb8c 100644
--- a/pkgs/servers/monitoring/uchiwa/default.nix
+++ b/pkgs/servers/monitoring/uchiwa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildBowerComponents, buildGoPackage, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, buildBowerComponents, buildGoPackage, makeWrapper }:
 
 let
   inherit (import ./src.nix) version sha256;
@@ -43,7 +43,7 @@ in stdenv.mkDerivation {
     ln -s ${frontend.out}/bower_components $out/public/bower_components
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Dashboard for the sensu monitoring framework";
     homepage    = "http://sensuapp.org/";
     license     = licenses.mit;
diff --git a/pkgs/servers/monitoring/unifi-poller/default.nix b/pkgs/servers/monitoring/unifi-poller/default.nix
index 7ddc53f38e8f6..0343384a6795b 100644
--- a/pkgs/servers/monitoring/unifi-poller/default.nix
+++ b/pkgs/servers/monitoring/unifi-poller/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "unifi-poller";
@@ -21,7 +21,7 @@ buildGoModule rec {
       -X github.com/prometheus/common/version.Version=${version}-0
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collect ALL UniFi Controller, Site, Device & Client Data - Export to InfluxDB or Prometheus";
     homepage = "https://github.com/unifi-poller/unifi-poller";
     license = licenses.mit;
diff --git a/pkgs/servers/monitoring/zabbix/agent.nix b/pkgs/servers/monitoring/zabbix/agent.nix
index 184d7e6aea7a1..aadbd879f5e68 100644
--- a/pkgs/servers/monitoring/zabbix/agent.nix
+++ b/pkgs/servers/monitoring/zabbix/agent.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libiconv, openssl, pcre }:
+{ lib, stdenv, fetchurl, pkgconfig, libiconv, openssl, pcre }:
 
 import ./versions.nix ({ version, sha256 }:
   stdenv.mkDerivation {
@@ -28,7 +28,7 @@ import ./versions.nix ({ version, sha256 }:
       cp conf/zabbix_agentd/*.conf $out/etc/zabbix_agentd.conf.d/
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "An enterprise-class open source distributed monitoring solution (client-side agent)";
       homepage = "https://www.zabbix.com/";
       license = licenses.gpl2;
diff --git a/pkgs/servers/monitoring/zabbix/proxy.nix b/pkgs/servers/monitoring/zabbix/proxy.nix
index 4179cf52c7a9c..190bfbcb81bf2 100644
--- a/pkgs/servers/monitoring/zabbix/proxy.nix
+++ b/pkgs/servers/monitoring/zabbix/proxy.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libevent, libiconv, openssl, pcre, zlib
+{ lib, stdenv, fetchurl, pkgconfig, libevent, libiconv, openssl, pcre, zlib
 , odbcSupport ? true, unixODBC
 , snmpSupport ? true, net-snmp
 , sshSupport ? true, libssh2
@@ -72,7 +72,7 @@ in
         cp -prvd database/postgresql/schema.sql $out/share/zabbix/database/postgresql/
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "An enterprise-class open source distributed monitoring solution (client-server proxy)";
         homepage = "https://www.zabbix.com/";
         license = licenses.gpl2;
diff --git a/pkgs/servers/monitoring/zabbix/server.nix b/pkgs/servers/monitoring/zabbix/server.nix
index 9d0e1c199d321..b82c3ce9ee830 100644
--- a/pkgs/servers/monitoring/zabbix/server.nix
+++ b/pkgs/servers/monitoring/zabbix/server.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig, curl, libevent, libiconv, libxml2, openssl, pcre, zlib
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig, curl, libevent, libiconv, libxml2, openssl, pcre, zlib
 , jabberSupport ? true, iksemel
 , ldapSupport ? true, openldap
 , odbcSupport ? true, unixODBC
@@ -83,7 +83,7 @@ in
         cp -prvd database/postgresql/*.sql $out/share/zabbix/database/postgresql/
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "An enterprise-class open source distributed monitoring solution";
         homepage = "https://www.zabbix.com/";
         license = licenses.gpl2;
diff --git a/pkgs/servers/monitoring/zabbix/web.nix b/pkgs/servers/monitoring/zabbix/web.nix
index f677fe5c0af35..16e5be4045aa7 100644
--- a/pkgs/servers/monitoring/zabbix/web.nix
+++ b/pkgs/servers/monitoring/zabbix/web.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, writeText }:
+{ lib, stdenv, fetchurl, writeText }:
 
 import ./versions.nix ({ version, sha256 }:
   stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ import ./versions.nix ({ version, sha256 }:
       cp ${phpConfig} $out/share/zabbix/conf/zabbix.conf.php
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "An enterprise-class open source distributed monitoring solution (web frontend)";
       homepage = "https://www.zabbix.com/";
       license = licenses.gpl2;
diff --git a/pkgs/servers/monitoring/zipkin/default.nix b/pkgs/servers/monitoring/zipkin/default.nix
index c9b2e36d87307..e84c422ea6463 100644
--- a/pkgs/servers/monitoring/zipkin/default.nix
+++ b/pkgs/servers/monitoring/zipkin/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, makeWrapper, jre}:
+{lib, stdenv, fetchurl, makeWrapper, jre}:
 stdenv.mkDerivation rec {
   version = "1.28.1";
   pname = "zipkin-server";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     makeWrapper ${jre}/bin/java $out/bin/zipkin-server \
       --add-flags "-cp $out/share/java/zipkin-server-${version}-exec.jar org.springframework.boot.loader.JarLauncher"
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Zipkin distributed tracing system";
     homepage = "https://zipkin.io/";
     license = licenses.asl20;
diff --git a/pkgs/servers/mpd/clientlib.nix b/pkgs/servers/mpd/clientlib.nix
index 3016b7dba835b..b180e62ce18a6 100644
--- a/pkgs/servers/mpd/clientlib.nix
+++ b/pkgs/servers/mpd/clientlib.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, fixDarwinDylibNames }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, fixDarwinDylibNames }:
 
 stdenv.mkDerivation rec {
   version = "2.19";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson ninja ]
   ++ stdenv.lib.optional stdenv.isDarwin fixDarwinDylibNames;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client library for MPD (music player daemon)";
     homepage = "https://www.musicpd.org/libs/libmpdclient/";
     license = licenses.gpl2;
diff --git a/pkgs/servers/mpd/default.nix b/pkgs/servers/mpd/default.nix
index 6b7cdc6a3a2de..8c50c0b10ae2d 100644
--- a/pkgs/servers/mpd/default.nix
+++ b/pkgs/servers/mpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkg-config, glib, systemd, boost, darwin
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkg-config, glib, systemd, boost, darwin
 # Inputs
 , curl, libmms, libnfs, liburing, samba
 # Archive support
@@ -171,7 +171,7 @@ let
 
       passthru.tests.nixos = nixosTests.mpd;
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "A flexible, powerful daemon for playing music";
         homepage    = "https://www.musicpd.org/";
         license     = licenses.gpl2;
diff --git a/pkgs/servers/mqtt/mosquitto/default.nix b/pkgs/servers/mqtt/mosquitto/default.nix
index e956e3b7cfd43..05ce1105d18d1 100644
--- a/pkgs/servers/mqtt/mosquitto/default.nix
+++ b/pkgs/servers/mqtt/mosquitto/default.nix
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     "-DWITH_WEBSOCKETS=ON"
   ] ++ lib.optional withSystemd "-DWITH_SYSTEMD=ON";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source MQTT v3.1/3.1.1 broker";
     homepage = "https://mosquitto.org/";
     license = licenses.epl10;
diff --git a/pkgs/servers/mtprotoproxy/default.nix b/pkgs/servers/mtprotoproxy/default.nix
index e8782050eeeaa..bd4ad80e317f8 100644
--- a/pkgs/servers/mtprotoproxy/default.nix
+++ b/pkgs/servers/mtprotoproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python, pyaes, pycrypto, uvloop, wrapPython }:
+{ lib, stdenv, fetchFromGitHub, python, pyaes, pycrypto, uvloop, wrapPython }:
 
 stdenv.mkDerivation rec {
   pname = "mtprotoproxy";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Async MTProto proxy for Telegram";
     license     = licenses.mit;
     homepage    = "https://github.com/alexbers/mtprotoproxy";
diff --git a/pkgs/servers/mxisd/default.nix b/pkgs/servers/mxisd/default.nix
index 6e9ab2ca99a21..b2ea542080917 100644
--- a/pkgs/servers/mxisd/default.nix
+++ b/pkgs/servers/mxisd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jre, git, gradle, perl, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, jre, git, gradle, perl, makeWrapper }:
 
 let
   name = "mxisd-${version}";
@@ -59,7 +59,7 @@ stdenv.mkDerivation {
     makeWrapper ${jre}/bin/java $out/bin/mxisd --add-flags "-jar $out/lib/mxisd.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a federated matrix identity server";
     homepage = "https://github.com/kamax-matrix/mxisd";
     license = licenses.agpl3;
diff --git a/pkgs/servers/nas/default.nix b/pkgs/servers/nas/default.nix
index 2e8b8b14d44f3..319bee115c281 100644
--- a/pkgs/servers/nas/default.nix
+++ b/pkgs/servers/nas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, imake, bison, flex, gccmakedep
+{ lib, stdenv, fetchurl, imake, bison, flex, gccmakedep
 , xorgproto, libXau, libXt, libXext, libXaw, libXpm, xorgcffiles }:
 
 let
@@ -25,7 +25,7 @@ in stdenv.mkDerivation {
     rm -r $out/nix
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A network transparent, client/server audio transport system";
     homepage = "http://radscan.com/nas.html";
     license = licenses.mit;
diff --git a/pkgs/servers/neard/default.nix b/pkgs/servers/neard/default.nix
index 3b360e308b571..ad3a68b46eb33 100644
--- a/pkgs/servers/neard/default.nix
+++ b/pkgs/servers/neard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig, systemd, glib, dbus, libnl, pythonPackages }:
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig, systemd, glib, dbus, libnl, pythonPackages }:
 
 stdenv.mkDerivation rec {
   name = "neard-0.16";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     wrapPythonProgramsIn $out/lib/neard "$out $pythonPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Near Field Communication manager";
     homepage    = "https://01.org/linux-nfc";
     license     = licenses.gpl2;
diff --git a/pkgs/servers/nextcloud/default.nix b/pkgs/servers/nextcloud/default.nix
index a1c38cdbe28d7..75fa1ff08244c 100644
--- a/pkgs/servers/nextcloud/default.nix
+++ b/pkgs/servers/nextcloud/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nixosTests }:
+{ lib, stdenv, fetchurl, nixosTests }:
 
 let
   generic = {
@@ -20,7 +20,7 @@ let
       cp -R . $out/
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Sharing solution for files, calendars, contacts and more";
       homepage = "https://nextcloud.com";
       maintainers = with maintainers; [ schneefux bachp globin fpletz ma27 ];
diff --git a/pkgs/servers/nfs-ganesha/default.nix b/pkgs/servers/nfs-ganesha/default.nix
index 7ec56b023e591..b5fefc963f078 100644
--- a/pkgs/servers/nfs-ganesha/default.nix
+++ b/pkgs/servers/nfs-ganesha/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config
 , krb5, xfsprogs, jemalloc, dbus, libcap
 , ntirpc, liburcu, bison, flex, nfs-utils
 } :
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     nfs-utils
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NFS server that runs in user space";
     homepage = "https://github.com/nfs-ganesha/nfs-ganesha/wiki";
     maintainers = [ maintainers.markuskowa ];
diff --git a/pkgs/servers/nginx-sso/default.nix b/pkgs/servers/nginx-sso/default.nix
index dffe48db58a3d..0029d9ad55eea 100644
--- a/pkgs/servers/nginx-sso/default.nix
+++ b/pkgs/servers/nginx-sso/default.nix
@@ -1,4 +1,4 @@
-{ buildGoPackage, fetchFromGitHub, stdenv, nixosTests }:
+{ buildGoPackage, fetchFromGitHub, lib, stdenv, nixosTests }:
 
 buildGoPackage rec {
   pname = "nginx-sso";
@@ -23,7 +23,7 @@ buildGoPackage rec {
     inherit (nixosTests) nginx-sso;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SSO authentication provider for the auth_request nginx module";
     homepage = "https://github.com/Luzifer/nginx-sso";
     license = licenses.asl20;
diff --git a/pkgs/servers/nosql/aerospike/default.nix b/pkgs/servers/nosql/aerospike/default.nix
index 73a07ec057eb8..33347a73a20ce 100644
--- a/pkgs/servers/nosql/aerospike/default.nix
+++ b/pkgs/servers/nosql/aerospike/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, openssl, zlib }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, openssl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "aerospike-server";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     cp -dpR modules/lua-core/src        $out/share/udf/lua
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flash-optimized, in-memory, NoSQL database";
     homepage = "http://aerospike.com/";
     license = licenses.agpl3;
diff --git a/pkgs/servers/nosql/cassandra/generic.nix b/pkgs/servers/nosql/cassandra/generic.nix
index 487dbdf07e017..696334e85616d 100644
--- a/pkgs/servers/nosql/cassandra/generic.nix
+++ b/pkgs/servers/nosql/cassandra/generic.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python, makeWrapper, gawk, bash, getopt, procps
+{ lib, stdenv, fetchurl, python, makeWrapper, gawk, bash, getopt, procps
 , which, jre, coreutils, nixosTests
 # generation is the attribute version suffix such as 3_11 in pkgs.cassandra_3_11
 , generation
@@ -98,7 +98,7 @@ stdenv.mkDerivation rec {
       };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cassandra.apache.org/";
     description = "A massively scalable open source NoSQL database";
     platforms = platforms.unix;
diff --git a/pkgs/servers/nosql/neo4j/default.nix b/pkgs/servers/nosql/neo4j/default.nix
index 743553f5f6167..74e7cd463b785 100644
--- a/pkgs/servers/nosql/neo4j/default.nix
+++ b/pkgs/servers/nosql/neo4j/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre8, which, gawk }:
+{ lib, stdenv, fetchurl, makeWrapper, jre8, which, gawk }:
 
 with stdenv.lib;
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A highly scalable, robust (fully ACID) native graph database";
     homepage = "http://www.neo4j.org/";
     license = licenses.gpl3;
diff --git a/pkgs/servers/nosql/redis/default.nix b/pkgs/servers/nosql/redis/default.nix
index 507416be73394..45dd26fb8f0e4 100644
--- a/pkgs/servers/nosql/redis/default.nix
+++ b/pkgs/servers/nosql/redis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, lua, pkgconfig, systemd, jemalloc, nixosTests
+{ lib, stdenv, fetchurl, lua, pkgconfig, systemd, jemalloc, nixosTests
 , tlsSupport ? true, openssl
 }:
 
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.redis = nixosTests.redis;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://redis.io";
     description = "An open source, advanced key-value store";
     license = licenses.bsd3;
diff --git a/pkgs/servers/nzbhydra2/default.nix b/pkgs/servers/nzbhydra2/default.nix
index 3ba758c108857..aab3952e9ed9a 100644
--- a/pkgs/servers/nzbhydra2/default.nix
+++ b/pkgs/servers/nzbhydra2/default.nix
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" ${jre}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Usenet meta search";
     homepage = "https://github.com/theotherp/nzbhydra2";
     license = licenses.asl20;
diff --git a/pkgs/servers/openafs/1.8/default.nix b/pkgs/servers/openafs/1.8/default.nix
index c26f8d3a23c50..de780e9fb9649 100644
--- a/pkgs/servers/openafs/1.8/default.nix
+++ b/pkgs/servers/openafs/1.8/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, which, autoconf, automake, flex
+{ lib, stdenv, buildPackages, fetchurl, which, autoconf, automake, flex
 , yacc , glibc, perl, kerberos, libxslt, docbook_xsl, file
 , docbook_xml_dtd_43, libtool_2
 , withDevdoc ? false, doxygen, dblatex # Extra developer documentation
@@ -94,7 +94,7 @@ in stdenv.mkDerivation {
     rm -rf "$(pwd)" && mkdir "$(pwd)"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     outputsToInstall = [ "out" "doc" "man" ];
     description = "Open AFS client";
     homepage = "https://www.openafs.org";
diff --git a/pkgs/servers/openafs/1.8/module.nix b/pkgs/servers/openafs/1.8/module.nix
index 722e514ea0164..97e20238a7c38 100644
--- a/pkgs/servers/openafs/1.8/module.nix
+++ b/pkgs/servers/openafs/1.8/module.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, autoconf, automake, flex, yacc
+{ lib, stdenv, fetchurl, which, autoconf, automake, flex, yacc
 , kernel, glibc, perl, libtool_2, kerberos, fetchpatch }:
 
 with (import ./srcs.nix {
@@ -69,7 +69,7 @@ in stdenv.mkDerivation {
     xz -f ${modDestDir}/libafs.ko
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open AFS client kernel module";
     homepage = "https://www.openafs.org";
     license = licenses.ipl10;
diff --git a/pkgs/servers/openafs/1.9/default.nix b/pkgs/servers/openafs/1.9/default.nix
index c26f8d3a23c50..de780e9fb9649 100644
--- a/pkgs/servers/openafs/1.9/default.nix
+++ b/pkgs/servers/openafs/1.9/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, which, autoconf, automake, flex
+{ lib, stdenv, buildPackages, fetchurl, which, autoconf, automake, flex
 , yacc , glibc, perl, kerberos, libxslt, docbook_xsl, file
 , docbook_xml_dtd_43, libtool_2
 , withDevdoc ? false, doxygen, dblatex # Extra developer documentation
@@ -94,7 +94,7 @@ in stdenv.mkDerivation {
     rm -rf "$(pwd)" && mkdir "$(pwd)"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     outputsToInstall = [ "out" "doc" "man" ];
     description = "Open AFS client";
     homepage = "https://www.openafs.org";
diff --git a/pkgs/servers/openafs/1.9/module.nix b/pkgs/servers/openafs/1.9/module.nix
index 547134726221f..5ed09a21742d8 100644
--- a/pkgs/servers/openafs/1.9/module.nix
+++ b/pkgs/servers/openafs/1.9/module.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, autoconf, automake, flex, yacc
+{ lib, stdenv, fetchurl, which, autoconf, automake, flex, yacc
 , kernel, glibc, perl, libtool_2, kerberos, fetchpatch }:
 
 with (import ./srcs.nix {
@@ -52,7 +52,7 @@ in stdenv.mkDerivation {
     xz -f ${modDestDir}/libafs.ko
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open AFS client kernel module";
     homepage = "https://www.openafs.org";
     license = licenses.ipl10;
diff --git a/pkgs/servers/openbgpd/default.nix b/pkgs/servers/openbgpd/default.nix
index 02c1c607eab86..58f799c97ba40 100644
--- a/pkgs/servers/openbgpd/default.nix
+++ b/pkgs/servers/openbgpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, m4, yacc }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, m4, yacc }:
 
 let
   openbsd_version =
@@ -35,7 +35,7 @@ in stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "A free implementation of the Border Gateway Protocol, Version 4. It allows ordinary machines to be used as routers exchanging routes with other systems speaking the BGP protocol";
     license = licenses.isc;
diff --git a/pkgs/servers/p910nd/default.nix b/pkgs/servers/p910nd/default.nix
index f209a2d2aa6e5..e5e4df1a292b8 100644
--- a/pkgs/servers/p910nd/default.nix
+++ b/pkgs/servers/p910nd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "p910nd";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     mv $out/etc $out/share/doc/examples
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small printer daemon passing jobs directly to the printer";
     longDescription = ''
       p910nd is a small printer daemon intended for diskless platforms that
diff --git a/pkgs/servers/plex/raw.nix b/pkgs/servers/plex/raw.nix
index 3bc3c69569386..89158838527ef 100644
--- a/pkgs/servers/plex/raw.nix
+++ b/pkgs/servers/plex/raw.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , dpkg
 , writeScript
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://plex.tv/";
     license = licenses.unfree;
     platforms = [ "x86_64-linux" "aarch64-linux" ];
diff --git a/pkgs/servers/polipo/default.nix b/pkgs/servers/polipo/default.nix
index 444705d85d018..10c58cfb9588a 100644
--- a/pkgs/servers/polipo/default.nix
+++ b/pkgs/servers/polipo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, texinfo }:
+{ lib, stdenv, fetchurl, texinfo }:
 
 stdenv.mkDerivation rec {
   pname = "polipo";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ texinfo ];
   makeFlags = [ "PREFIX=$(out)" "LOCAL_ROOT=$(out)/share/polipo/www" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.pps.jussieu.fr/~jch/software/polipo/";
     description = "A small and fast caching web proxy";
     license = licenses.mit;
diff --git a/pkgs/servers/pounce/default.nix b/pkgs/servers/pounce/default.nix
index 4a55a2c65620c..65b1cbc7ddfc2 100644
--- a/pkgs/servers/pounce/default.nix
+++ b/pkgs/servers/pounce/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, libressl, fetchzip, fetchpatch, pkg-config }:
+{ lib, stdenv, libressl, fetchzip, fetchpatch, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "pounce";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "PREFIX=$(out)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://code.causal.agency/june/pounce";
     description = "Simple multi-client TLS-only IRC bouncer";
     license = licenses.gpl3;
diff --git a/pkgs/servers/pulseaudio/hsphfpd.nix b/pkgs/servers/pulseaudio/hsphfpd.nix
index 9a235434ce323..bcb3934fb7b74 100644
--- a/pkgs/servers/pulseaudio/hsphfpd.nix
+++ b/pkgs/servers/pulseaudio/hsphfpd.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, perlPackages }:
 
 let
   perlLibs = with perlPackages; [ NetDBus XMLTwig XMLParser ];
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bluetooth HSP/HFP daemon";
     homepage = "https://github.com/pali/hsphfpd-prototype";
     license = licenses.artistic1;
diff --git a/pkgs/servers/quagga/default.nix b/pkgs/servers/quagga/default.nix
index 5bff70878d3b7..b74950d627ca5 100644
--- a/pkgs/servers/quagga/default.nix
+++ b/pkgs/servers/quagga/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libcap, libnl, readline, net-snmp, less, perl, texinfo,
+{ lib, stdenv, fetchurl, libcap, libnl, readline, net-snmp, less, perl, texinfo,
   pkgconfig, c-ares }:
 
 stdenv.mkDerivation rec {
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quagga BGP/OSPF/ISIS/RIP/RIPNG routing daemon suite";
     longDescription = ''
       GNU Quagga is free software which manages TCP/IP based routing protocols.
diff --git a/pkgs/servers/radarr/default.nix b/pkgs/servers/radarr/default.nix
index e39e0bf76470a..231b390f326bf 100644
--- a/pkgs/servers/radarr/default.nix
+++ b/pkgs/servers/radarr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mono, libmediainfo, sqlite, curl, makeWrapper }:
+{ lib, stdenv, fetchurl, mono, libmediainfo, sqlite, curl, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "radarr";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
           curl sqlite libmediainfo ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Usenet/BitTorrent movie downloader";
     homepage = "https://radarr.video/";
     license = licenses.gpl3;
diff --git a/pkgs/servers/radicale/1.x.nix b/pkgs/servers/radicale/1.x.nix
index 96c94c2bc6b2b..6ca821214856a 100644
--- a/pkgs/servers/radicale/1.x.nix
+++ b/pkgs/servers/radicale/1.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages }:
+{ lib, stdenv, fetchurl, pythonPackages }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "radicale";
@@ -17,7 +17,7 @@ pythonPackages.buildPythonApplication rec {
 
   doCheck = !pythonPackages.isPy3k;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.radicale.org/";
     description = "CalDAV CardDAV server";
     longDescription = ''
diff --git a/pkgs/servers/radicale/2.x.nix b/pkgs/servers/radicale/2.x.nix
index 8d36717ec69b1..918dad537a532 100644
--- a/pkgs/servers/radicale/2.x.nix
+++ b/pkgs/servers/radicale/2.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "Radicale";
@@ -30,7 +30,7 @@ python3.pkgs.buildPythonApplication rec {
     pytest
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.radicale.org/2.x.nix";
     description = "CalDAV CardDAV server";
     longDescription = ''
diff --git a/pkgs/servers/rainloop/default.nix b/pkgs/servers/rainloop/default.nix
index 42c68d5608edb..0c149149e1593 100644
--- a/pkgs/servers/rainloop/default.nix
+++ b/pkgs/servers/rainloop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, pkgs, dataPath ? "/var/lib/rainloop" }: let
+{ lib, stdenv, fetchurl, unzip, pkgs, dataPath ? "/var/lib/rainloop" }: let
   common = { edition, sha256 }:
     stdenv.mkDerivation (rec {
       pname = "rainloop${stdenv.lib.optionalString (edition != "") "-${edition}"}";
@@ -38,7 +38,7 @@
         chmod 700 $out/data
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "Simple, modern & fast web-based email client";
         homepage = "https://www.rainloop.net";
         downloadPage = "https://github.com/RainLoop/rainloop-webmail/releases";
diff --git a/pkgs/servers/rippled/default.nix b/pkgs/servers/rippled/default.nix
index 24a4c50813ecd..22223f2a27e66 100644
--- a/pkgs/servers/rippled/default.nix
+++ b/pkgs/servers/rippled/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchgit, fetchurl, runCommand, git, cmake, pkg-config
+{ lib, stdenv, fetchFromGitHub, fetchgit, fetchurl, runCommand, git, cmake, pkg-config
 , openssl,  zlib, boost, grpc, c-ares, abseil-cpp, protobuf3_8, libnsl }:
 
 let
@@ -157,7 +157,7 @@ in stdenv.mkDerivation rec {
     ./rippled --unittest
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ripple P2P payment network reference server";
     homepage = "https://github.com/ripple/rippled";
     maintainers = with maintainers; [ ehmry offline RaghavSood ];
diff --git a/pkgs/servers/routinator/default.nix b/pkgs/servers/routinator/default.nix
index 7cb28c49a50e2..e62ad97538063 100644
--- a/pkgs/servers/routinator/default.nix
+++ b/pkgs/servers/routinator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "routinator";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0fcp4b2b0mjddj4blr20gvp1ih3ldzzr04rm1m06i8d2lnl68i79";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An RPKI Validator written in Rust";
     homepage = "https://github.com/NLnetLabs/routinator";
     license = licenses.bsd3;
diff --git a/pkgs/servers/rpcbind/default.nix b/pkgs/servers/rpcbind/default.nix
index 52197a6afaac0..ad18c42858b4c 100644
--- a/pkgs/servers/rpcbind/default.nix
+++ b/pkgs/servers/rpcbind/default.nix
@@ -1,4 +1,4 @@
-{ fetchgit, stdenv, pkgconfig, libnsl, libtirpc, autoreconfHook
+{ fetchgit, lib, stdenv, pkgconfig, libnsl, libtirpc, autoreconfHook
 , useSystemd ? true, systemd }:
 
 stdenv.mkDerivation {
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
 
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ONC RPC portmapper";
     license = licenses.bsd3;
     platforms = platforms.unix;
diff --git a/pkgs/servers/rtsp-simple-server/default.nix b/pkgs/servers/rtsp-simple-server/default.nix
index 94a15d35489fa..d3ec7dc75ee61 100644
--- a/pkgs/servers/rtsp-simple-server/default.nix
+++ b/pkgs/servers/rtsp-simple-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildGoModule
 }:
@@ -23,7 +23,7 @@ buildGoModule rec {
     "-ldflags=-X main.Version=${version}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Ready-to-use RTSP server and RTSP proxy that allows to read and publish video and audio streams"
     ;
diff --git a/pkgs/servers/sabnzbd/default.nix b/pkgs/servers/sabnzbd/default.nix
index f2cbb2f820cfb..d72caf54fc4cb 100644
--- a/pkgs/servers/sabnzbd/default.nix
+++ b/pkgs/servers/sabnzbd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3
 , par2cmdline
@@ -41,7 +41,7 @@ in stdenv.mkDerivation rec {
     wrapProgram $out/bin/sabnzbd --set PATH ${path}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Usenet NZB downloader, par2 repairer and auto extracting server";
     homepage = "https://sabnzbd.org";
     license = licenses.gpl2Plus;
diff --git a/pkgs/servers/samba/4.x.nix b/pkgs/servers/samba/4.x.nix
index 164604242d867..a665de00cceda 100644
--- a/pkgs/servers/samba/4.x.nix
+++ b/pkgs/servers/samba/4.x.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , python
 , pkgconfig
@@ -153,7 +153,7 @@ stdenv.mkDerivation rec {
     tests.samba = nixosTests.samba;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.samba.org";
     description = "The standard Windows interoperability suite of programs for Linux and Unix";
     license = licenses.gpl3;
diff --git a/pkgs/servers/scylladb/default.nix b/pkgs/servers/scylladb/default.nix
index a2671e17cb7ae..522d40e070ac7 100644
--- a/pkgs/servers/scylladb/default.nix
+++ b/pkgs/servers/scylladb/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   fetchgit,
   python3Packages,
   pkgconfig,
@@ -91,7 +91,7 @@ gcc8Stdenv.mkDerivation {
 
   requiredSystemFeatures = [ "big-parallel" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NoSQL data store using the seastar framework, compatible with Apache Cassandra";
     homepage = "https://scylladb.com";
     license = licenses.agpl3;
diff --git a/pkgs/servers/search/elasticsearch/plugins.nix b/pkgs/servers/search/elasticsearch/plugins.nix
index 846fb33000bbe..c51b0d2098452 100644
--- a/pkgs/servers/search/elasticsearch/plugins.nix
+++ b/pkgs/servers/search/elasticsearch/plugins.nix
@@ -40,7 +40,7 @@ in {
         else if version == "6.8.3" then "0vbaqyj0lfy3ijl1c9h92b0nh605h5mjs57bk2zhycdvbw5sx2lv"
         else throw "unsupported version ${version} for plugin ${pluginName}";
     };
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/elastic/elasticsearch/tree/master/plugins/analysis-icu";
       description = "The ICU Analysis plugin integrates the Lucene ICU module into elasticsearch";
       license = licenses.asl20;
diff --git a/pkgs/servers/search/groonga/default.nix b/pkgs/servers/search/groonga/default.nix
index 501533bda54f5..8f7e63665b860 100644
--- a/pkgs/servers/search/groonga/default.nix
+++ b/pkgs/servers/search/groonga/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mecab, kytea, libedit, pkgconfig
+{ lib, stdenv, fetchurl, mecab, kytea, libedit, pkgconfig
 , suggestSupport ? false, zeromq, libevent, msgpack
 , lz4Support  ? false, lz4
 , zlibSupport ? false, zlib
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
   doInstallCheck    = true;
   installCheckPhase = "$out/bin/groonga --version";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://groonga.org/";
     description = "An open-source fulltext search engine and column store";
     license     = licenses.lgpl21;
diff --git a/pkgs/servers/search/meilisearch/default.nix b/pkgs/servers/search/meilisearch/default.nix
index d6bee327412d4..569da6b5b971b 100644
--- a/pkgs/servers/search/meilisearch/default.nix
+++ b/pkgs/servers/search/meilisearch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , IOKit
@@ -20,7 +20,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ IOKit Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ultra relevant and instant full-text search API";
     homepage = "https://meilisearch.com/";
     license = licenses.mit;
diff --git a/pkgs/servers/search/solr/default.nix b/pkgs/servers/search/solr/default.nix
index b5390d1537d27..52bb37a818635 100644
--- a/pkgs/servers/search/solr/default.nix
+++ b/pkgs/servers/search/solr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper, nixosTests }:
+{ lib, stdenv, fetchurl, jre, makeWrapper, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "solr";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     inherit (nixosTests) solr;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://lucene.apache.org/solr/";
     description = "Open source enterprise search platform from the Apache Lucene project";
     license = licenses.asl20;
diff --git a/pkgs/servers/serf/default.nix b/pkgs/servers/serf/default.nix
index 8129cb5ad8e3e..04cd93c5306e6 100644
--- a/pkgs/servers/serf/default.nix
+++ b/pkgs/servers/serf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "serf";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "1arakjvhyasrk52vhxas2ghlrby3i3wj59r7sjrkbpln2cdbqnlx";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for service orchestration and management";
     homepage = "https://www.serf.io/";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/servers/serviio/default.nix b/pkgs/servers/serviio/default.nix
index 769ed5e727281..f3c8fc2311ccf 100644
--- a/pkgs/servers/serviio/default.nix
+++ b/pkgs/servers/serviio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "serviio";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp -R config legal lib library plugins LICENCE.txt NOTICE.txt README.txt RELEASE_NOTES.txt $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://serviio.org";
     description = "UPnP Media Streaming Server";
     longDescription = ''
diff --git a/pkgs/servers/shairplay/default.nix b/pkgs/servers/shairplay/default.nix
index 1c726c477648d..655e60060cba0 100644
--- a/pkgs/servers/shairplay/default.nix
+++ b/pkgs/servers/shairplay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , avahi, libao }:
 
 stdenv.mkDerivation rec {
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
       $out/bin/shairplay
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Apple AirPlay and RAOP protocol server";
     license     = licenses.mit;
diff --git a/pkgs/servers/shairport-sync/default.nix b/pkgs/servers/shairport-sync/default.nix
index a20579371516b..108721fceb0e2 100644
--- a/pkgs/servers/shairport-sync/default.nix
+++ b/pkgs/servers/shairport-sync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, openssl, avahi, alsaLib
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, openssl, avahi, alsaLib
 , libdaemon, popt, pkgconfig, libconfig, libpulseaudio, soxr }:
 
 stdenv.mkDerivation rec {
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     "--sysconfdir=/etc"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Airtunes server and emulator with multi-room capabilities";
     license = licenses.mit;
diff --git a/pkgs/servers/shellinabox/default.nix b/pkgs/servers/shellinabox/default.nix
index 279cfa3300be6..0240cd5a862cd 100644
--- a/pkgs/servers/shellinabox/default.nix
+++ b/pkgs/servers/shellinabox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pam, openssl, openssh, shadow, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pam, openssl, openssh, shadow, makeWrapper }:
 
 stdenv.mkDerivation rec {
   version = "2.20";
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     cp shellinabox/* $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/shellinabox/shellinabox";
     description = "Web based AJAX terminal emulator";
     license = licenses.gpl2;
diff --git a/pkgs/servers/sickbeard/default.nix b/pkgs/servers/sickbeard/default.nix
index 6cca58a175e8d..10a5018d7814c 100644
--- a/pkgs/servers/sickbeard/default.nix
+++ b/pkgs/servers/sickbeard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, python2, makeWrapper }:
 
 let
   pythonEnv = python2.withPackages(ps: with ps; [ cheetah ]);
@@ -26,7 +26,7 @@ in stdenv.mkDerivation {
     makeWrapper $out/SickBeard.py $out/bin/sickbeard
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PVR & episode guide that downloads and manages all your TV shows";
     license     = licenses.gpl3;
     homepage    = "https://github.com/midgetspy/Sick-Beard";
diff --git a/pkgs/servers/sickbeard/sickgear.nix b/pkgs/servers/sickbeard/sickgear.nix
index 433cd97f9a7bc..48efe71476143 100644
--- a/pkgs/servers/sickbeard/sickgear.nix
+++ b/pkgs/servers/sickbeard/sickgear.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, python2, makeWrapper }:
 
 let
   pythonEnv = python2.withPackages(ps: with ps; [ cheetah ]);
@@ -26,7 +26,7 @@ in stdenv.mkDerivation rec {
     makeWrapper $out/SickBeard.py $out/bin/sickgear
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The most reliable stable TV fork of the great Sick-Beard to fully automate TV enjoyment with innovation";
     license     = licenses.gpl3;
     homepage    = "https://github.com/SickGear/SickGear";
diff --git a/pkgs/servers/sickbeard/sickrage.nix b/pkgs/servers/sickbeard/sickrage.nix
index 9ff44fade8228..6b7d3e7b1ca4a 100644
--- a/pkgs/servers/sickbeard/sickrage.nix
+++ b/pkgs/servers/sickbeard/sickrage.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, python2, makeWrapper }:
 
 python2.pkgs.buildPythonApplication rec {
   pname = "sickrage";
@@ -24,7 +24,7 @@ python2.pkgs.buildPythonApplication rec {
     makeWrapper $out/SickBeard.py $out/bin/sickrage
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatic Video Library Manager for TV Shows";
     longDescription = "It watches for new episodes of your favorite shows, and when they are posted it does its magic.";
     license     = licenses.gpl3;
diff --git a/pkgs/servers/simplehttp2server/default.nix b/pkgs/servers/simplehttp2server/default.nix
index 58b04b316b347..bc56053515bf3 100644
--- a/pkgs/servers/simplehttp2server/default.nix
+++ b/pkgs/servers/simplehttp2server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "simplehttp2server";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
      homepage = "https://github.com/GoogleChromeLabs/simplehttp2server";
      description = "HTTP/2 server for development purposes";
      license = licenses.asl20;
diff --git a/pkgs/servers/sks/default.nix b/pkgs/servers/sks/default.nix
index f6f914b7cbd52..8e0ce6bedac58 100644
--- a/pkgs/servers/sks/default.nix
+++ b/pkgs/servers/sks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromBitbucket, ocaml, zlib, db, perl, camlp4 }:
+{ lib, stdenv, fetchFromBitbucket, ocaml, zlib, db, perl, camlp4 }:
 
 stdenv.mkDerivation rec {
   pname = "sks";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
   # Copy the web examples for the NixOS module
   postInstall = "cp -R sampleWeb $webSamples";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An easily deployable & decentralized OpenPGP keyserver";
     longDescription = ''
       SKS is an OpenPGP keyserver whose goal is to provide easy to deploy,
diff --git a/pkgs/servers/slimserver/default.nix b/pkgs/servers/slimserver/default.nix
index d045543813c5f..6b83df2496cd5 100644
--- a/pkgs/servers/slimserver/default.nix
+++ b/pkgs/servers/slimserver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper
+{ lib, stdenv, fetchurl, makeWrapper
 , perlPackages, flac, faad2, sox, lame, monkeysAudio, wavpack }:
 
 perlPackages.buildPerlPackage rec {
@@ -93,7 +93,7 @@ perlPackages.buildPerlPackage rec {
 
   outputs = [ "out" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Logitech/slimserver";
     description = "Server for Logitech Squeezebox players. This server is also called Logitech Media Server";
     # the firmware is not under a free license!
diff --git a/pkgs/servers/smcroute/default.nix b/pkgs/servers/smcroute/default.nix
index b881c6007309d..3a332876ffd1a 100644
--- a/pkgs/servers/smcroute/default.nix
+++ b/pkgs/servers/smcroute/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libcap }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libcap }:
 
 stdenv.mkDerivation rec {
   pname = "smcroute";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "--with-systemd=\$(out)/lib/systemd/system"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Static multicast routing daemon";
     homepage = "https://troglobit.com/smcroute.html";
     license = licenses.gpl2Plus;
diff --git a/pkgs/servers/softether/4.25.nix b/pkgs/servers/softether/4.25.nix
index 65e21010e7570..f22bd0859adaa 100644
--- a/pkgs/servers/softether/4.25.nix
+++ b/pkgs/servers/softether/4.25.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , openssl, readline, ncurses, zlib
 , dataDir ? "/var/lib/softether" }:
 
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
           Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Open-Source Free Cross-platform Multi-protocol VPN Program";
     homepage = "https://www.softether.org/";
     license = licenses.gpl2;
diff --git a/pkgs/servers/softether/4.29.nix b/pkgs/servers/softether/4.29.nix
index b1ef8643aa36e..83eb3b05b37fd 100644
--- a/pkgs/servers/softether/4.29.nix
+++ b/pkgs/servers/softether/4.29.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , openssl, readline, ncurses, zlib
 , dataDir ? "/var/lib/softether" }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
           Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Open-Source Free Cross-platform Multi-protocol VPN Program";
     homepage = "https://www.softether.org/";
     license = licenses.asl20;
diff --git a/pkgs/servers/sozu/default.nix b/pkgs/servers/sozu/default.nix
index 137d5b24d18bb..c3c839fcc29ee 100644
--- a/pkgs/servers/sozu/default.nix
+++ b/pkgs/servers/sozu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, darwin }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "sozu";
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
   buildInputs =
     stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Open Source HTTP Reverse Proxy built in Rust for Immutable Infrastructures";
     homepage = "https://www.sozu.io";
diff --git a/pkgs/servers/sql/cockroachdb/default.nix b/pkgs/servers/sql/cockroachdb/default.nix
index ee156e37173ac..05d41afa28bdd 100644
--- a/pkgs/servers/sql/cockroachdb/default.nix
+++ b/pkgs/servers/sql/cockroachdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchurl
+{ lib, stdenv, buildGoPackage, fetchurl
 , cmake, xz, which, autoconf
 , ncurses6, libedit, libunwind
 , installShellFiles
@@ -60,7 +60,7 @@ buildGoPackage rec {
     find $out -type f -exec ${removeReferencesTo}/bin/remove-references-to -t ${go} '{}' +
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://www.cockroachlabs.com";
     description = "A scalable, survivable, strongly-consistent SQL database";
     license     = licenses.bsl11;
diff --git a/pkgs/servers/sql/mariadb/galera/default.nix b/pkgs/servers/sql/mariadb/galera/default.nix
index 14ab75d159b21..7d1c49815e44c 100644
--- a/pkgs/servers/sql/mariadb/galera/default.nix
+++ b/pkgs/servers/sql/mariadb/galera/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildEnv
+{ lib, stdenv, fetchFromGitHub, buildEnv
 , asio, boost, check, openssl, scons
 }:
 
@@ -50,7 +50,7 @@ in stdenv.mkDerivation rec {
     install -m 444 "www.evanjones.ca/LICENSE"         "$out/$GALERA_LICENSE_DIR/LICENSE.crc32c"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Galera 3 wsrep provider library";
     homepage = "https://galeracluster.com/";
     license = licenses.lgpl2;
diff --git a/pkgs/servers/sql/monetdb/default.nix b/pkgs/servers/sql/monetdb/default.nix
index 04617943e2690..ca284330b30a8 100644
--- a/pkgs/servers/sql/monetdb/default.nix
+++ b/pkgs/servers/sql/monetdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, python3
+{ lib, stdenv, fetchurl, cmake, python3
 , bison, openssl, readline, bzip2
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake python3 ];
   buildInputs = [ bison openssl readline bzip2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source database system";
     homepage = "https://www.monetdb.org/";
     license = licenses.mpl20;
diff --git a/pkgs/servers/sql/mysql/5.7.x.nix b/pkgs/servers/sql/mysql/5.7.x.nix
index 8b489816a50a1..bfdacf3444eac 100644
--- a/pkgs/servers/sql/mysql/5.7.x.nix
+++ b/pkgs/servers/sql/mysql/5.7.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, bison, pkgconfig
+{ lib, stdenv, fetchurl, cmake, bison, pkgconfig
 , boost, libedit, libevent, lz4, ncurses, openssl, protobuf, readline, zlib, perl
 , cctools, CoreServices, developer_cmds
 , libtirpc, rpcsvc-proto
@@ -75,7 +75,7 @@ self = stdenv.mkDerivation rec {
     mysqlVersion = "5.7";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.mysql.com/";
     description = "The world's most popular open source database";
     platforms = platforms.unix;
diff --git a/pkgs/servers/sql/percona/5.6.x.nix b/pkgs/servers/sql/percona/5.6.x.nix
index 3089a0d5c99b7..905a8424e8efe 100644
--- a/pkgs/servers/sql/percona/5.6.x.nix
+++ b/pkgs/servers/sql/percona/5.6.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, bison, ncurses, openssl, zlib, libaio, perl }:
+{ lib, stdenv, fetchurl, cmake, bison, ncurses, openssl, zlib, libaio, perl }:
 
 stdenv.mkDerivation rec {
   pname = "percona-server";
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
 
   passthru.mysqlVersion = "5.6";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.percona.com";
     description = "a free, fully compatible, enhanced, open source drop-in replacement for MySQL that provides superior performance, scalability and instrumentation";
     platforms = platforms.linux;
diff --git a/pkgs/servers/sql/pgbouncer/default.nix b/pkgs/servers/sql/pgbouncer/default.nix
index d72a32746dbab..9fa596292a6ee 100644
--- a/pkgs/servers/sql/pgbouncer/default.nix
+++ b/pkgs/servers/sql/pgbouncer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, libevent, c-ares, pkg-config }:
+{ lib, stdenv, fetchurl, openssl, libevent, c-ares, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "pgbouncer";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libevent openssl c-ares ];
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pgbouncer.github.io";
     description = "Lightweight connection pooler for PostgreSQL";
     license = licenses.isc;
diff --git a/pkgs/servers/sql/pgpool/default.nix b/pkgs/servers/sql/pgpool/default.nix
index 7c2f3521a085f..ad32904ce8a59 100644
--- a/pkgs/servers/sql/pgpool/default.nix
+++ b/pkgs/servers/sql/pgpool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, postgresql, openssl, pam ? null, libmemcached ? null }:
+{ lib, stdenv, fetchurl, postgresql, openssl, pam ? null, libmemcached ? null }:
 
 stdenv.mkDerivation rec {
   pname = "pgpool-II";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pgpool.net/mediawiki/index.php";
     description = "A middleware that works between postgresql servers and postgresql clients";
     license = licenses.free;
diff --git a/pkgs/servers/sql/postgresql/ext/age.nix b/pkgs/servers/sql/postgresql/ext/age.nix
index 09021317cd13b..1017611aeaa9d 100644
--- a/pkgs/servers/sql/postgresql/ext/age.nix
+++ b/pkgs/servers/sql/postgresql/ext/age.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bison, flex, postgresql }:
+{ lib, stdenv, fetchFromGitHub, bison, flex, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "age";
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A graph database extension for PostgreSQL";
     homepage = "https://github.com/bitnine-oss/AgensGraph-Extension";
     changelog = "https://github.com/bitnine-oss/AgensGraph-Extension/releases/tag/v${version}";
diff --git a/pkgs/servers/sql/postgresql/ext/cstore_fdw.nix b/pkgs/servers/sql/postgresql/ext/cstore_fdw.nix
index 5525fc9f9655f..d88d693f073d4 100644
--- a/pkgs/servers/sql/postgresql/ext/cstore_fdw.nix
+++ b/pkgs/servers/sql/postgresql/ext/cstore_fdw.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, protobufc }:
+{ lib, stdenv, fetchFromGitHub, postgresql, protobufc }:
 
 stdenv.mkDerivation rec {
   pname = "cstore_fdw";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Columnar storage for PostgreSQL";
     homepage    = "https://www.citusdata.com/";
     maintainers = with maintainers; [ thoughtpolice ];
diff --git a/pkgs/servers/sql/postgresql/ext/periods.nix b/pkgs/servers/sql/postgresql/ext/periods.nix
index c2277019f89b5..4d1d3326457f0 100644
--- a/pkgs/servers/sql/postgresql/ext/periods.nix
+++ b/pkgs/servers/sql/postgresql/ext/periods.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "periods";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/share/postgresql/extension *.control
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PostgreSQL extension implementing SQL standard functionality for PERIODs and SYSTEM VERSIONING";
     homepage = "https://github.com/xocolatl/periods";
     maintainers = with maintainers; [ ivan ];
diff --git a/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix b/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix
index 14cdb3ba8f802..99a81f875484f 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_auto_failover.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, openssl, zlib, readline }:
+{ lib, stdenv, fetchFromGitHub, postgresql, openssl, zlib, readline }:
 
 stdenv.mkDerivation rec {
   pname = "pg_auto_failover";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/share/postgresql/extension src/monitor/pgautofailover.control
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PostgreSQL extension and service for automated failover and high-availability";
     homepage = "https://github.com/citusdata/pg_auto_failover";
     maintainers = [ maintainers.marsam ];
diff --git a/pkgs/servers/sql/postgresql/ext/pg_bigm.nix b/pkgs/servers/sql/postgresql/ext/pg_bigm.nix
index 055d1de3c788f..a1077a42ac225 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_bigm.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_bigm.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, postgresql }:
+{ lib, stdenv, fetchurl, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pg_bigm";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Text similarity measurement and index searching based on bigrams";
     homepage = "https://pgbigm.osdn.jp/";
     maintainers = [ maintainers.marsam ];
diff --git a/pkgs/servers/sql/postgresql/ext/pg_cron.nix b/pkgs/servers/sql/postgresql/ext/pg_cron.nix
index 1d791c3a07255..c1aefa1770ff0 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_cron.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_cron.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pg_cron";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Run Cron jobs through PostgreSQL";
     homepage    = "https://github.com/citusdata/pg_cron";
     maintainers = with maintainers; [ thoughtpolice ];
diff --git a/pkgs/servers/sql/postgresql/ext/pg_ed25519.nix b/pkgs/servers/sql/postgresql/ext/pg_ed25519.nix
index 95d45b2663d93..d3ff2a56e3a83 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_ed25519.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_ed25519.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, postgresql }:
+{ lib, stdenv, fetchurl, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pg_ed25519";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PostgreSQL extension for signing and verifying ed25519 signatures";
     homepage = "https://gitlab.com/dwagin/pg_ed25519";
     maintainers = [ maintainers.renzo ];
diff --git a/pkgs/servers/sql/postgresql/ext/pg_hll.nix b/pkgs/servers/sql/postgresql/ext/pg_hll.nix
index ab80cd1748c54..4689f176188c8 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_hll.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_hll.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pg_hll";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HyperLogLog for PostgreSQL";
     homepage    = "https://github.com/citusdata/postgresql-hll";
     changelog   = "https://github.com/citusdata/postgresql-hll/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/servers/sql/postgresql/ext/pg_partman.nix b/pkgs/servers/sql/postgresql/ext/pg_partman.nix
index 9a289919558c1..d0bc8435c3e3b 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_partman.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_partman.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pg_partman";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp *.control     $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Partition management extension for PostgreSQL";
     homepage    = "https://github.com/pgpartman/pg_partman";
     maintainers = with maintainers; [ ggpeti ];
diff --git a/pkgs/servers/sql/postgresql/ext/pg_repack.nix b/pkgs/servers/sql/postgresql/ext/pg_repack.nix
index f197bef5463c0..ecc4000f5f6b1 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_repack.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_repack.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, openssl, zlib, readline }:
+{ lib, stdenv, fetchFromGitHub, postgresql, openssl, zlib, readline }:
 
 stdenv.mkDerivation rec {
   pname = "pg_repack";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D lib/{pg_repack--${version}.sql,pg_repack.control} -t $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reorganize tables in PostgreSQL databases with minimal locks";
     longDescription = ''
       pg_repack is a PostgreSQL extension which lets you remove bloat from tables and indexes, and optionally restore
diff --git a/pkgs/servers/sql/postgresql/ext/pg_safeupdate.nix b/pkgs/servers/sql/postgresql/ext/pg_safeupdate.nix
index b835141e2ca7e..b2a58b6bc3e4d 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_safeupdate.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_safeupdate.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pg-safeupdate";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -D safeupdate.so -t $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple extension to PostgreSQL that requires criteria for UPDATE and DELETE";
     homepage    = "https://github.com/eradman/pg-safeupdate";
     platforms   = postgresql.meta.platforms;
diff --git a/pkgs/servers/sql/postgresql/ext/pg_topn.nix b/pkgs/servers/sql/postgresql/ext/pg_topn.nix
index 03d571c03ba6b..eb0965a337817 100644
--- a/pkgs/servers/sql/postgresql/ext/pg_topn.nix
+++ b/pkgs/servers/sql/postgresql/ext/pg_topn.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pg_topn";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Efficient querying of 'top values' for PostgreSQL";
     homepage    = "https://github.com/citusdata/postgresql-topn";
     changelog   = "https://github.com/citusdata/postgresql-topn/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/servers/sql/postgresql/ext/pgjwt.nix b/pkgs/servers/sql/postgresql/ext/pgjwt.nix
index 9576c41861180..b89ac17250085 100644
--- a/pkgs/servers/sql/postgresql/ext/pgjwt.nix
+++ b/pkgs/servers/sql/postgresql/ext/pgjwt.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation {
   pname = "pgjwt";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     cp pg*sql *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PostgreSQL implementation of JSON Web Tokens";
     longDescription = ''
       sign() and verify() functions to create and verify JSON Web Tokens.
diff --git a/pkgs/servers/sql/postgresql/ext/pgroonga.nix b/pkgs/servers/sql/postgresql/ext/pgroonga.nix
index 05fc6c5ca6a99..50fb383dabb82 100644
--- a/pkgs/servers/sql/postgresql/ext/pgroonga.nix
+++ b/pkgs/servers/sql/postgresql/ext/pgroonga.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, postgresql, msgpack, groonga }:
+{ lib, stdenv, fetchurl, pkgconfig, postgresql, msgpack, groonga }:
 
 stdenv.mkDerivation rec {
   pname = "pgroonga";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D ./{pgroonga-*.sql,pgroonga.control} -t $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PostgreSQL extension to use Groonga as the index";
     longDescription = ''
       PGroonga is a PostgreSQL extension to use Groonga as the index.
diff --git a/pkgs/servers/sql/postgresql/ext/pgrouting.nix b/pkgs/servers/sql/postgresql/ext/pgrouting.nix
index 9863b2276d118..c51ef153444f8 100644
--- a/pkgs/servers/sql/postgresql/ext/pgrouting.nix
+++ b/pkgs/servers/sql/postgresql/ext/pgrouting.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, perl, cmake, boost }:
+{ lib, stdenv, fetchFromGitHub, postgresql, perl, cmake, boost }:
 
 stdenv.mkDerivation rec {
   pname = "pgrouting";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -D sql/common/pgrouting.control    -t $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PostgreSQL/PostGIS extension that provides geospatial routing functionality";
     homepage    = "https://pgrouting.org/";
     changelog   = "https://github.com/pgRouting/pgrouting/releases/tag/v${version}";
diff --git a/pkgs/servers/sql/postgresql/ext/pgtap.nix b/pkgs/servers/sql/postgresql/ext/pgtap.nix
index 69f46ba3e9058..396e743e70b46 100644
--- a/pkgs/servers/sql/postgresql/ext/pgtap.nix
+++ b/pkgs/servers/sql/postgresql/ext/pgtap.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, perl, perlPackages, which }:
+{ lib, stdenv, fetchFromGitHub, postgresql, perl, perlPackages, which }:
 
 stdenv.mkDerivation rec {
   pname = "pgtap";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -D {sql/pgtap--${version}.sql,pgtap.control} -t $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A unit testing framework for PostgreSQL";
     longDescription = ''
       pgTAP is a unit testing framework for PostgreSQL written in PL/pgSQL and PL/SQL.
diff --git a/pkgs/servers/sql/postgresql/ext/pipelinedb.nix b/pkgs/servers/sql/postgresql/ext/pipelinedb.nix
index 3bca35095c4cb..d909761cb5ea1 100644
--- a/pkgs/servers/sql/postgresql/ext/pipelinedb.nix
+++ b/pkgs/servers/sql/postgresql/ext/pipelinedb.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, zeromq, openssl }:
+{ lib, stdenv, fetchFromGitHub, postgresql, zeromq, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "pipelinedb";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/share/postgresql/extension {pipelinedb-*.sql,pipelinedb.control}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-performance time-series aggregation for PostgreSQL";
     homepage = "https://www.pipelinedb.com/";
     license = licenses.asl20;
diff --git a/pkgs/servers/sql/postgresql/ext/plpgsql_check.nix b/pkgs/servers/sql/postgresql/ext/plpgsql_check.nix
index 665cb1dc06938..5ce32177d51be 100644
--- a/pkgs/servers/sql/postgresql/ext/plpgsql_check.nix
+++ b/pkgs/servers/sql/postgresql/ext/plpgsql_check.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "plpgsql_check";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/share/postgresql/extension *.control
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linter tool for language PL/pgSQL";
     homepage = "https://github.com/okbob/plpgsql_check";
     platforms = postgresql.meta.platforms;
diff --git a/pkgs/servers/sql/postgresql/ext/plv8.nix b/pkgs/servers/sql/postgresql/ext/plv8.nix
index 8186e9128d9bc..a546c3a687f43 100644
--- a/pkgs/servers/sql/postgresql/ext/plv8.nix
+++ b/pkgs/servers/sql/postgresql/ext/plv8.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, v8, perl, postgresql }:
+{ lib, stdenv, fetchFromGitHub, v8, perl, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "plv8";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     install -D {plls,plcoffee,plv8}{--${version}.sql,.control} -t $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "V8 Engine Javascript Procedural Language add-on for PostgreSQL";
     homepage = "https://plv8.github.io/";
     maintainers = with maintainers; [ volth marsam ];
diff --git a/pkgs/servers/sql/postgresql/ext/postgis.nix b/pkgs/servers/sql/postgresql/ext/postgis.nix
index fdf4b40d3b068..e9c9a24ae3674 100644
--- a/pkgs/servers/sql/postgresql/ext/postgis.nix
+++ b/pkgs/servers/sql/postgresql/ext/postgis.nix
@@ -1,5 +1,5 @@
 { fetchurl
-, stdenv
+, lib, stdenv
 , perl
 , libxml2
 , postgresql
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.postgis = nixosTests.postgis;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Geographic Objects for PostgreSQL";
     homepage = "https://postgis.net/";
     changelog = "https://git.osgeo.org/gitea/postgis/postgis/raw/tag/${version}/NEWS";
diff --git a/pkgs/servers/sql/postgresql/ext/repmgr.nix b/pkgs/servers/sql/postgresql/ext/repmgr.nix
index a2e319170bd46..ceb9cc9d8af24 100644
--- a/pkgs/servers/sql/postgresql/ext/repmgr.nix
+++ b/pkgs/servers/sql/postgresql/ext/repmgr.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , postgresql
 , openssl
 , zlib
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     cp *.control  $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://repmgr.org/";
     description = "Replication manager for PostgreSQL cluster";
     license = licenses.postgresql;
diff --git a/pkgs/servers/sql/postgresql/ext/smlar.nix b/pkgs/servers/sql/postgresql/ext/smlar.nix
index adefe085a0bb2..fdb2f7395c833 100644
--- a/pkgs/servers/sql/postgresql/ext/smlar.nix
+++ b/pkgs/servers/sql/postgresql/ext/smlar.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, postgresql }:
+{ lib, stdenv, fetchgit, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "smlar-unstable";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/share/postgresql/extension *.control
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compute similary of any one-dimensional arrays";
     homepage = "http://sigaev.ru/git/gitweb.cgi?p=smlar.git";
     platforms = postgresql.meta.platforms;
diff --git a/pkgs/servers/sql/postgresql/ext/tds_fdw.nix b/pkgs/servers/sql/postgresql/ext/tds_fdw.nix
index 478b27b74f16b..19331f350c550 100644
--- a/pkgs/servers/sql/postgresql/ext/tds_fdw.nix
+++ b/pkgs/servers/sql/postgresql/ext/tds_fdw.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql, freetds }:
+{ lib, stdenv, fetchFromGitHub, postgresql, freetds }:
 
 stdenv.mkDerivation rec {
   pname = "tds_fdw";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D tds_fdw.control             -t $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PostgreSQL foreign data wrapper to connect to TDS databases (Sybase and Microsoft SQL Server)";
     homepage    = "https://github.com/tds-fdw/tds_fdw";
     maintainers = [ maintainers.steve-chavez ];
diff --git a/pkgs/servers/sql/postgresql/ext/temporal_tables.nix b/pkgs/servers/sql/postgresql/ext/temporal_tables.nix
index eaf63fcba6e92..a2c3fe0e390dd 100644
--- a/pkgs/servers/sql/postgresql/ext/temporal_tables.nix
+++ b/pkgs/servers/sql/postgresql/ext/temporal_tables.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, postgresql }:
+{ lib, stdenv, fetchFromGitHub, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "temporal_tables";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp *.control $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Temporal Tables PostgreSQL Extension ";
     homepage    = "https://github.com/mlt/temporal_tables";
     maintainers = with maintainers; [ ggpeti ];
diff --git a/pkgs/servers/sql/postgresql/ext/timescaledb.nix b/pkgs/servers/sql/postgresql/ext/timescaledb.nix
index 55d2cd81a2177..abde49542f1ae 100644
--- a/pkgs/servers/sql/postgresql/ext/timescaledb.nix
+++ b/pkgs/servers/sql/postgresql/ext/timescaledb.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, postgresql, openssl }:
+{ lib, stdenv, fetchFromGitHub, cmake, postgresql, openssl }:
 
 # # To enable on NixOS:
 # config.services.postgresql = {
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scales PostgreSQL for time-series data via automatic partitioning across time and space";
     homepage    = "https://www.timescale.com/";
     maintainers = with maintainers; [ volth marsam ];
diff --git a/pkgs/servers/sql/postgresql/ext/tsearch_extras.nix b/pkgs/servers/sql/postgresql/ext/tsearch_extras.nix
index f05fa6312d8fe..f94bb69871cb2 100644
--- a/pkgs/servers/sql/postgresql/ext/tsearch_extras.nix
+++ b/pkgs/servers/sql/postgresql/ext/tsearch_extras.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, postgresql }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, postgresql }:
 
 stdenv.mkDerivation {
   pname = "tsearch-extras";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     install -D ./{tsearch_extras--1.0.sql,tsearch_extras.control} -t $out/share/postgresql/extension
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a few PostgreSQL functions for a lower-level data full text search";
     homepage = "https://github.com/zulip/tsearch_extras/";
     license = licenses.postgresql;
diff --git a/pkgs/servers/sql/sqlite/jdbc/default.nix b/pkgs/servers/sql/sqlite/jdbc/default.nix
index f5444bb068368..01a9d5fa2e234 100644
--- a/pkgs/servers/sql/sqlite/jdbc/default.nix
+++ b/pkgs/servers/sql/sqlite/jdbc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchMavenArtifact }:
+{ lib, stdenv, fetchMavenArtifact }:
 
 stdenv.mkDerivation rec {
   pname = "sqlite-jdbc";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -m444 -D ${src}/share/java/*${pname}-${version}.jar "$out/share/java/${pname}-${version}.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/xerial/sqlite-jdbc";
     description = "Library for accessing and creating SQLite database files in Java";
     license = licenses.asl20;
diff --git a/pkgs/servers/sql/virtuoso/6.x.nix b/pkgs/servers/sql/virtuoso/6.x.nix
index efd8cd02a15bf..4737c0a389420 100644
--- a/pkgs/servers/sql/virtuoso/6.x.nix
+++ b/pkgs/servers/sql/virtuoso/6.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxml2, openssl, readline, gawk }:
+{ lib, stdenv, fetchurl, libxml2, openssl, readline, gawk }:
 
 stdenv.mkDerivation rec {
   name = "virtuoso-opensource-6.1.6";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SQL/RDF database used by, e.g., KDE-nepomuk";
     homepage = "http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/";
     platforms = platforms.linux;
diff --git a/pkgs/servers/sql/virtuoso/7.x.nix b/pkgs/servers/sql/virtuoso/7.x.nix
index bca1aae82e512..a27cd249f1ce3 100644
--- a/pkgs/servers/sql/virtuoso/7.x.nix
+++ b/pkgs/servers/sql/virtuoso/7.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxml2, openssl, readline, gawk }:
+{ lib, stdenv, fetchurl, libxml2, openssl, readline, gawk }:
 
 stdenv.mkDerivation rec {
   name = "virtuoso-opensource-7.2.4.2";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     find $out -name "*.a" -delete -o -name "*.jar" -delete -o -type d -empty -delete
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SQL/RDF database used by, e.g., KDE-nepomuk";
     homepage = "http://virtuoso.openlinksw.com/dataspace/dav/wiki/Main/";
     #configure: The current version [...] can only be built on 64bit platforms
diff --git a/pkgs/servers/squid/default.nix b/pkgs/servers/squid/default.nix
index ad7d534103cfd..09507aaef2a0f 100644
--- a/pkgs/servers/squid/default.nix
+++ b/pkgs/servers/squid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, openldap, pam, db, cyrus_sasl, libcap
+{ lib, stdenv, fetchurl, perl, openldap, pam, db, cyrus_sasl, libcap
 , expat, libxml2, openssl, pkgconfig
 }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     "--enable-x-accelerator-vary"
   ] ++ stdenv.lib.optional (stdenv.isLinux && !stdenv.hostPlatform.isMusl) "--enable-linux-netfilter";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A caching proxy for the Web supporting HTTP, HTTPS, FTP, and more";
     homepage = "http://www.squid-cache.org";
     license = licenses.gpl2;
diff --git a/pkgs/servers/sslh/default.nix b/pkgs/servers/sslh/default.nix
index 578d280afd9a8..e7637e26f14a5 100644
--- a/pkgs/servers/sslh/default.nix
+++ b/pkgs/servers/sslh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libcap, libconfig, perl, tcp_wrappers, pcre, nixosTests }:
+{ lib, stdenv, fetchurl, libcap, libconfig, perl, tcp_wrappers, pcre, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "sslh";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     inherit (nixosTests) sslh;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Applicative Protocol Multiplexer (e.g. share SSH and HTTPS on the same port)";
     license = licenses.gpl2Plus;
     homepage = "https://www.rutschle.net/tech/sslh/README.html";
diff --git a/pkgs/servers/tacacsplus/default.nix b/pkgs/servers/tacacsplus/default.nix
index 296b79f0a4441..9acba46310258 100644
--- a/pkgs/servers/tacacsplus/default.nix
+++ b/pkgs/servers/tacacsplus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, tcp_wrappers, flex, bison, perl, libnsl }:
+{ lib, stdenv, fetchurl, tcp_wrappers, flex, bison, perl, libnsl }:
 
 stdenv.mkDerivation rec {
   pname = "tacacsplus";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ flex bison ];
   buildInputs = [ tcp_wrappers perl libnsl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A protocol for authentication, authorization and accounting (AAA) services for routers and network devices";
     homepage = "http://www.shrubbery.net/tac_plus/";
     license = licenses.free;
diff --git a/pkgs/servers/tarssh/default.nix b/pkgs/servers/tarssh/default.nix
index 4e9ef3e0b5883..bb353dda92895 100644
--- a/pkgs/servers/tarssh/default.nix
+++ b/pkgs/servers/tarssh/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, rustPlatform, stdenv }:
+{ fetchFromGitHub, rustPlatform, lib, stdenv }:
 
 with rustPlatform;
 
@@ -15,7 +15,7 @@ buildRustPackage rec {
 
   cargoSha256 = "1f3anrh2y8yg7l4nilwk0a7c7kq5yvg07cqh75igjdb5a7p9di0j";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple SSH tarpit inspired by endlessh";
     homepage = "https://github.com/Freaky/tarssh";
     license = [ licenses.mit ];
diff --git a/pkgs/servers/tegola/default.nix b/pkgs/servers/tegola/default.nix
index ec049c6b01014..c18bf17a7c7c7 100644
--- a/pkgs/servers/tegola/default.nix
+++ b/pkgs/servers/tegola/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "tegola";
@@ -17,7 +17,7 @@ buildGoPackage rec {
 
   excludedPackages = [ "example" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.tegola.io/";
     description = "Mapbox Vector Tile server";
     maintainers = with maintainers; [ ingenieroariel ];
diff --git a/pkgs/servers/tmate-ssh-server/default.nix b/pkgs/servers/tmate-ssh-server/default.nix
index afbaea648f02a..6fe5bc201f9b7 100644
--- a/pkgs/servers/tmate-ssh-server/default.nix
+++ b/pkgs/servers/tmate-ssh-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, cmake, libtool, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, cmake, libtool, pkgconfig
 , zlib, openssl, libevent, ncurses, ruby, msgpack, libssh }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libtool zlib openssl libevent ncurses ruby msgpack libssh ];
   nativeBuildInputs = [ autoreconfHook cmake pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://tmate.io/";
     description = "tmate SSH Server";
     license     = licenses.mit;
diff --git a/pkgs/servers/traefik/default.nix b/pkgs/servers/traefik/default.nix
index 9c576dd2bdfd9..4ef454d6b5610 100644
--- a/pkgs/servers/traefik/default.nix
+++ b/pkgs/servers/traefik/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, buildGoModule, go-bindata, nixosTests }:
+{ lib, stdenv, fetchzip, buildGoModule, go-bindata, nixosTests }:
 
 buildGoModule rec {
   pname = "traefik";
@@ -30,7 +30,7 @@ buildGoModule rec {
       -X github.com/traefik/traefik/v2/pkg/version.Codename=$CODENAME")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://traefik.io";
     description = "A modern reverse proxy";
     license = licenses.mit;
diff --git a/pkgs/servers/trezord/default.nix b/pkgs/servers/trezord/default.nix
index b89abfc6153bc..03ff9f32fa510 100644
--- a/pkgs/servers/trezord/default.nix
+++ b/pkgs/servers/trezord/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , trezor-udev-rules
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   propagatedBuildInputs = [ trezor-udev-rules ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Trezor Communication Daemon aka Trezor Bridge";
     homepage = "https://trezor.io";
     license = licenses.lgpl3;
diff --git a/pkgs/servers/trickster/trickster.nix b/pkgs/servers/trickster/trickster.nix
index cb8c87aa611a4..b99375dbb3d02 100644
--- a/pkgs/servers/trickster/trickster.nix
+++ b/pkgs/servers/trickster/trickster.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "trickster";
@@ -17,7 +17,7 @@ buildGoPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reverse proxy cache for the Prometheus HTTP APIv1";
     homepage = "https://github.com/Comcast/trickster";
     license = licenses.asl20;
diff --git a/pkgs/servers/tt-rss/default.nix b/pkgs/servers/tt-rss/default.nix
index 4478c4ab8d7d3..95b895b281bbc 100644
--- a/pkgs/servers/tt-rss/default.nix
+++ b/pkgs/servers/tt-rss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "tt-rss";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     cp -ra * $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web-based news feed (RSS/Atom) aggregator";
     license = licenses.gpl2Plus;
     homepage = "https://tt-rss.org";
diff --git a/pkgs/servers/tt-rss/plugin-auth-ldap/default.nix b/pkgs/servers/tt-rss/plugin-auth-ldap/default.nix
index 14e6eaa77ae33..d48db311ea10b 100644
--- a/pkgs/servers/tt-rss/plugin-auth-ldap/default.nix
+++ b/pkgs/servers/tt-rss/plugin-auth-ldap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "tt-rss-plugin-auth-ldap";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     install -D plugins/auth_ldap/init.php $out/auth_ldap/init.php
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin for TT-RSS to authenticate users via ldap";
     license = licenses.asl20;
     homepage = "https://github.com/hydrian/TTRSS-Auth-LDAP";
diff --git a/pkgs/servers/tt-rss/plugin-ff-instagram/default.nix b/pkgs/servers/tt-rss/plugin-ff-instagram/default.nix
index fd6ca9909470a..375726a4692ef 100644
--- a/pkgs/servers/tt-rss/plugin-ff-instagram/default.nix
+++ b/pkgs/servers/tt-rss/plugin-ff-instagram/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ... }: stdenv.mkDerivation {
+{ lib, stdenv, fetchFromGitHub, ... }: stdenv.mkDerivation {
   pname = "tt-rss-plugin-ff-instagram";
   version = "git-2019-01-10"; # No release, see https://github.com/wltb/ff_instagram/issues/6
 
@@ -15,7 +15,7 @@
     cp *.php $out/ff_instagram
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin for Tiny Tiny RSS that allows to fetch posts from Instagram user sites";
     longDescription = ''
       Plugin for Tiny Tiny RSS that allows to fetch posts from Instagram user sites.
diff --git a/pkgs/servers/tt-rss/plugin-tumblr-gdpr/default.nix b/pkgs/servers/tt-rss/plugin-tumblr-gdpr/default.nix
index a6f47c1ccbf90..987a6d8aaa671 100644
--- a/pkgs/servers/tt-rss/plugin-tumblr-gdpr/default.nix
+++ b/pkgs/servers/tt-rss/plugin-tumblr-gdpr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ... }: stdenv.mkDerivation rec {
+{ lib, stdenv, fetchFromGitHub, ... }: stdenv.mkDerivation rec {
   pname = "tt-rss-plugin-tumblr-gdpr";
   version = "2.1";
 
@@ -15,7 +15,7 @@
     cp init.php $out/tumblr_gdpr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin for TT-RSS to workaround GDPR in Europe";
     longDescription = ''
       Plugin for TT-RSS to workaround GDPR in Europe.
diff --git a/pkgs/servers/tt-rss/theme-feedly/default.nix b/pkgs/servers/tt-rss/theme-feedly/default.nix
index 1f47f5b2226b1..41f47ca4a4ec5 100644
--- a/pkgs/servers/tt-rss/theme-feedly/default.nix
+++ b/pkgs/servers/tt-rss/theme-feedly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }: stdenv.mkDerivation rec {
+{ lib, stdenv, fetchFromGitHub }: stdenv.mkDerivation rec {
   pname = "tt-rss-theme-feedly";
   version = "2.5.0";
 
@@ -17,7 +17,7 @@
     cp -ra feedly *.css $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Feedly theme for Tiny Tiny RSS";
     license = licenses.wtfpl;
     homepage = "https://github.com/levito/tt-rss-feedly-theme";
diff --git a/pkgs/servers/tvheadend/default.nix b/pkgs/servers/tvheadend/default.nix
index 9c857f95a456c..0276f5aca0a68 100644
--- a/pkgs/servers/tvheadend/default.nix
+++ b/pkgs/servers/tvheadend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper, pkgconfig
 , avahi, dbus, gettext, git, gnutar, gzip, bzip2, ffmpeg_3, libiconv, openssl, python
 , v4l-utils, which, zlib }:
 
@@ -68,7 +68,7 @@ in stdenv.mkDerivation {
       --prefix PATH : ${stdenv.lib.makeBinPath [ bzip2 ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TV streaming server";
     longDescription = ''
         Tvheadend is a TV streaming server and recorder for Linux, FreeBSD and Android
diff --git a/pkgs/servers/u9fs/default.nix b/pkgs/servers/u9fs/default.nix
index 97745b77ad2fd..60dde01e9c638 100644
--- a/pkgs/servers/u9fs/default.nix
+++ b/pkgs/servers/u9fs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchhg }:
+{ lib, stdenv, fetchhg }:
 
 stdenv.mkDerivation {
   pname = "u9fs";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
       cp u9fs $out/bin
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Serve 9P from Unix";
     homepage = "http://plan9.bell-labs.com/magic/man2html/4/u9fs";
     license = licenses.free;
diff --git a/pkgs/servers/uhub/default.nix b/pkgs/servers/uhub/default.nix
index 9f4f34e30e8af..34e2b1bae7d5f 100644
--- a/pkgs/servers/uhub/default.nix
+++ b/pkgs/servers/uhub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchFromGitHub, cmake, openssl, sqlite, pkg-config, systemd
+{ lib, stdenv, fetchpatch, fetchFromGitHub, cmake, openssl, sqlite, pkg-config, systemd
 , tlsSupport ? false }:
 
 assert tlsSupport -> openssl != null;
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     (if tlsSupport then "-DSSL_SUPPORT=ON" else "-DSSL_SUPPORT=OFF")
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High performance peer-to-peer hub for the ADC network";
     homepage = "https://www.uhub.org/";
     license = licenses.gpl3;
diff --git a/pkgs/servers/unifi/default.nix b/pkgs/servers/unifi/default.nix
index b354fd994c97f..c8b610c4d17f8 100644
--- a/pkgs/servers/unifi/default.nix
+++ b/pkgs/servers/unifi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, dpkg, fetchurl }:
+{ lib, stdenv, dpkg, fetchurl }:
 
 let
   generic = { version, sha256, suffix ? "" }:
@@ -29,7 +29,7 @@ let
       runHook postInstall
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "http://www.ubnt.com/";
       description = "Controller for Ubiquiti UniFi access points";
       license = licenses.unfree;
diff --git a/pkgs/servers/unpfs/default.nix b/pkgs/servers/unpfs/default.nix
index 9b67a901693dd..818e92f059656 100644
--- a/pkgs/servers/unpfs/default.nix
+++ b/pkgs/servers/unpfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "unpfs";
@@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec {
     install -D -m 0444 ../../LICEN* -t "$out/share/doc/${pname}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "9P2000.L server implementation in Rust";
     homepage = "https://github.com/pfpacket/rust-9p";
     license = licenses.bsd3;
diff --git a/pkgs/servers/ursadb/default.nix b/pkgs/servers/ursadb/default.nix
index 6a3a1cff5b565..f86599adccbd4 100644
--- a/pkgs/servers/ursadb/default.nix
+++ b/pkgs/servers/ursadb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, zeromq, cppzmq }:
+{ lib, stdenv, fetchurl, cmake, zeromq, cppzmq }:
 
 stdenv.mkDerivation {
   name = "ursadb";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     cppzmq
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/CERT-Polska/ursadb";
     description = "Trigram database written in C++, suited for malware indexing";
     license = licenses.bsd3;
diff --git a/pkgs/servers/urserver/default.nix b/pkgs/servers/urserver/default.nix
index 3f665a32ebda8..2d2e83fe01b20 100644
--- a/pkgs/servers/urserver/default.nix
+++ b/pkgs/servers/urserver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , autoPatchelfHook
 , bluez
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     cp -r manager $out/bin/manager
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.unifiedremote.com/";
     description = "The one-and-only remote for your computer";
     license = licenses.unfree;
diff --git a/pkgs/servers/uwsgi/default.nix b/pkgs/servers/uwsgi/default.nix
index 449b97c58e778..14876e47df3fa 100644
--- a/pkgs/servers/uwsgi/default.nix
+++ b/pkgs/servers/uwsgi/default.nix
@@ -117,7 +117,7 @@ stdenv.mkDerivation rec {
     ${lib.concatMapStringsSep "\n" (x: x.install or "") needed}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://uwsgi-docs.readthedocs.org/en/latest/";
     description = "A fast, self-healing and developer/sysadmin-friendly application container server coded in pure C";
     license = licenses.gpl2;
diff --git a/pkgs/servers/varnish/default.nix b/pkgs/servers/varnish/default.nix
index 27e0edfcc2b22..0326c8988f49b 100644
--- a/pkgs/servers/varnish/default.nix
+++ b/pkgs/servers/varnish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pcre, libxslt, groff, ncurses, pkgconfig, readline, libedit
+{ lib, stdenv, fetchurl, pcre, libxslt, groff, ncurses, pkgconfig, readline, libedit
 , python3, makeWrapper }:
 
 let
@@ -30,7 +30,7 @@ let
 
       outputs = [ "out" "dev" "man" ];
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "Web application accelerator also known as a caching HTTP reverse proxy";
         homepage = "https://www.varnish-cache.org";
         license = licenses.bsd2;
diff --git a/pkgs/servers/varnish/digest.nix b/pkgs/servers/varnish/digest.nix
index 8d69451f8b5ef..b6ec11e4e8df8 100644
--- a/pkgs/servers/varnish/digest.nix
+++ b/pkgs/servers/varnish/digest.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, varnish, libmhash, docutils }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, varnish, libmhash, docutils }:
 
 stdenv.mkDerivation rec {
   version = "1.0.2";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Digest and HMAC vmod";
     homepage = "https://github.com/varnish/libvmod-digest";
     inherit (varnish.meta) license platforms maintainers;
diff --git a/pkgs/servers/varnish/dynamic.nix b/pkgs/servers/varnish/dynamic.nix
index c43f00b7a6bba..a9900424b966f 100644
--- a/pkgs/servers/varnish/dynamic.nix
+++ b/pkgs/servers/varnish/dynamic.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, varnish, docutils }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, varnish, docutils }:
 
 stdenv.mkDerivation rec {
   version = "0.4";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   '';
   configureFlags = [ "VMOD_DIR=$(out)/lib/varnish/vmods" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynamic director similar to the DNS director from Varnish 3";
     homepage = "https://github.com/nigoroll/libvmod-dynamic";
     inherit (varnish.meta) license platforms maintainers;
diff --git a/pkgs/servers/varnish/modules.nix b/pkgs/servers/varnish/modules.nix
index 69ee7028de87d..f39afd9c87ca9 100644
--- a/pkgs/servers/varnish/modules.nix
+++ b/pkgs/servers/varnish/modules.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, varnish, docutils, removeReferencesTo }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, varnish, docutils, removeReferencesTo }:
 
 stdenv.mkDerivation rec {
   version = "0.15.0";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   postInstall = "find $out -type f -exec remove-references-to -t ${varnish.dev} '{}' +"; # varnish.dev captured only as __FILE__ in assert messages
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of Varnish Cache modules (vmods) by Varnish Software";
     homepage = "https://github.com/varnish/varnish-modules";
     inherit (varnish.meta) license platforms maintainers;
diff --git a/pkgs/servers/web-apps/dokuwiki/default.nix b/pkgs/servers/web-apps/dokuwiki/default.nix
index 2cb20e4932f56..1f11734692818 100644
--- a/pkgs/servers/web-apps/dokuwiki/default.nix
+++ b/pkgs/servers/web-apps/dokuwiki/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, writeText }:
+{ lib, stdenv, fetchFromGitHub, writeText }:
 
 stdenv.mkDerivation rec {
   pname = "dokuwiki";
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     cp ${phpPluginsLocalConfig} $out/share/dokuwiki/conf/plugins.local.php
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple to use and highly versatile Open Source wiki software that doesn't require a database";
     license = licenses.gpl2;
     homepage = "https://www.dokuwiki.org";
diff --git a/pkgs/servers/web-apps/engelsystem/default.nix b/pkgs/servers/web-apps/engelsystem/default.nix
index 92d50ff67c8ea..22abbdac08ce1 100644
--- a/pkgs/servers/web-apps/engelsystem/default.nix
+++ b/pkgs/servers/web-apps/engelsystem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, php, writeText, nixosTests }:
+{ lib, stdenv, fetchzip, php, writeText, nixosTests }:
 
 let
   phpExt = php.withExtensions
@@ -39,7 +39,7 @@ in stdenv.mkDerivation rec {
 
   passthru.tests = nixosTests.engelsystem;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Coordinate your volunteers in teams, assign them to work shifts or let them decide for themselves when and where they want to help with what";
     license = licenses.gpl2;
diff --git a/pkgs/servers/web-apps/fileshelter/default.nix b/pkgs/servers/web-apps/fileshelter/default.nix
index 928d80b1297af..76b468d35d778 100644
--- a/pkgs/servers/web-apps/fileshelter/default.nix
+++ b/pkgs/servers/web-apps/fileshelter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, libzip, boost, wt4, libconfig, pkgconfig } :
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, libzip, boost, wt4, libconfig, pkgconfig } :
 
 stdenv.mkDerivation rec {
   pname = "fileshelter";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     ln -s ${wt4}/share/Wt/resources $out/share/fileshelter/docroot/resources
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/epoupon/fileshelter";
     description = "FileShelter is a 'one-click' file sharing web application";
     maintainers = [ maintainers.willibutz ];
diff --git a/pkgs/servers/web-apps/hedgedoc/default.nix b/pkgs/servers/web-apps/hedgedoc/default.nix
index 9fdaafbd24abc..76c0d0ce72c76 100644
--- a/pkgs/servers/web-apps/hedgedoc/default.nix
+++ b/pkgs/servers/web-apps/hedgedoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, makeWrapper
+{ lib, stdenv, fetchFromGitHub, fetchpatch, makeWrapper
 , which, nodejs, mkYarnPackage, python2, nixosTests }:
 
 mkYarnPackage rec {
@@ -61,7 +61,7 @@ mkYarnPackage rec {
 
   passthru.tests = { inherit (nixosTests) hedgedoc; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Realtime collaborative markdown notes on all platforms";
     license = licenses.agpl3;
     homepage = "https://hedgedoc.org";
diff --git a/pkgs/servers/web-apps/jirafeau/default.nix b/pkgs/servers/web-apps/jirafeau/default.nix
index b9e31c6d094af..6091eb498208d 100644
--- a/pkgs/servers/web-apps/jirafeau/default.nix
+++ b/pkgs/servers/web-apps/jirafeau/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, writeText }:
+{ lib, stdenv, fetchFromGitLab, writeText }:
 let
   localConfig = writeText "config.local.php" ''
     <?php
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp ${localConfig} $out/lib/config.local.php
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Website permitting upload of a file in a simple way and giving a unique link to it";
     license = licenses.agpl3;
     homepage = "https://gitlab.com/mojo42/Jirafeau";
diff --git a/pkgs/servers/web-apps/jitsi-meet/default.nix b/pkgs/servers/web-apps/jitsi-meet/default.nix
index 4c85f949aec27..4b33048e92386 100644
--- a/pkgs/servers/web-apps/jitsi-meet/default.nix
+++ b/pkgs/servers/web-apps/jitsi-meet/default.nix
@@ -1,4 +1,4 @@
-{ pkgs, stdenv, fetchurl, nixosTests }:
+{ pkgs, lib, stdenv, fetchurl, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "jitsi-meet";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     single-host-smoke-test = nixosTests.jitsi-meet;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Secure, Simple and Scalable Video Conferences";
     longDescription = ''
       Jitsi Meet is an open-source (Apache) WebRTC JavaScript application that uses Jitsi Videobridge
diff --git a/pkgs/servers/web-apps/matomo/default.nix b/pkgs/servers/web-apps/matomo/default.nix
index eca43dc6f13fd..ffa4f55fa77a3 100644
--- a/pkgs/servers/web-apps/matomo/default.nix
+++ b/pkgs/servers/web-apps/matomo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, php }:
+{ lib, stdenv, fetchurl, makeWrapper, php }:
 
 let
   versions = {
@@ -97,7 +97,7 @@ let
           popd > /dev/null
         '';
 
-        meta = with stdenv.lib; {
+        meta = with lib; {
           description = "A real-time web analytics application";
           license = licenses.gpl3Plus;
           homepage = "https://matomo.org/";
diff --git a/pkgs/servers/web-apps/mediawiki/default.nix b/pkgs/servers/web-apps/mediawiki/default.nix
index 78f01f19faaf8..ddd2ecf813275 100644
--- a/pkgs/servers/web-apps/mediawiki/default.nix
+++ b/pkgs/servers/web-apps/mediawiki/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, writeText }:
+{ lib, stdenv, fetchurl, makeWrapper, writeText }:
 
 stdenv.mkDerivation rec {
   pname = "mediawiki";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The collaborative editing software that runs Wikipedia";
     license = licenses.gpl2Plus;
     homepage = "https://www.mediawiki.org/";
diff --git a/pkgs/servers/web-apps/moodle/default.nix b/pkgs/servers/web-apps/moodle/default.nix
index da84481c9353f..6b22c29c128c9 100644
--- a/pkgs/servers/web-apps/moodle/default.nix
+++ b/pkgs/servers/web-apps/moodle/default.nix
@@ -52,7 +52,7 @@ in stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Free and open-source learning management system (LMS) written in PHP";
     license = licenses.gpl3Plus;
diff --git a/pkgs/servers/web-apps/morty/default.nix b/pkgs/servers/web-apps/morty/default.nix
index 3d43862cbe0eb..6b17476623b9e 100644
--- a/pkgs/servers/web-apps/morty/default.nix
+++ b/pkgs/servers/web-apps/morty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchgit }:
+{ lib, stdenv, buildGoPackage, fetchgit }:
 
 buildGoPackage rec {
   pname = "morty";
@@ -14,7 +14,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/asciimoo/morty";
     maintainers = with maintainers; [ leenaars ];
     license = licenses.agpl3;
diff --git a/pkgs/servers/web-apps/pgpkeyserver-lite/default.nix b/pkgs/servers/web-apps/pgpkeyserver-lite/default.nix
index f983885706111..0930b3a4978d1 100644
--- a/pkgs/servers/web-apps/pgpkeyserver-lite/default.nix
+++ b/pkgs/servers/web-apps/pgpkeyserver-lite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "pgpkeyserver-lite";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     cp -R 404.html assets favicon.ico index.html robots.txt $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mattrude/pgpkeyserver-lite";
     description = "A lightweight static front-end for a sks keyserver";
     license = licenses.gpl3;
diff --git a/pkgs/servers/web-apps/restya-board/default.nix b/pkgs/servers/web-apps/restya-board/default.nix
index 89e22b23361e6..934ef81ac90e2 100644
--- a/pkgs/servers/web-apps/restya-board/default.nix
+++ b/pkgs/servers/web-apps/restya-board/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 let
 
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     unzip -d $out/client/apps ${togetherjs}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web-based kanban board";
     license = licenses.osl3;
     homepage = "https://restya.com";
diff --git a/pkgs/servers/web-apps/selfoss/default.nix b/pkgs/servers/web-apps/selfoss/default.nix
index e54f9d74c1d29..383c57ee9382a 100644
--- a/pkgs/servers/web-apps/selfoss/default.nix
+++ b/pkgs/servers/web-apps/selfoss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "selfoss";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp -ra * $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web-based news feed (RSS/Atom) aggregator";
     homepage = "https://selfoss.aditu.de";
     license = licenses.gpl3;
diff --git a/pkgs/servers/web-apps/shaarli/default.nix b/pkgs/servers/web-apps/shaarli/default.nix
index a4374b833908a..2e3386de64403 100644
--- a/pkgs/servers/web-apps/shaarli/default.nix
+++ b/pkgs/servers/web-apps/shaarli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "shaarli";
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     cp -R ./* $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The personal, minimalist, super-fast, database free, bookmarking service";
     license = licenses.gpl3Plus;
     homepage = "https://github.com/shaarli/Shaarli";
diff --git a/pkgs/servers/web-apps/shiori/default.nix b/pkgs/servers/web-apps/shiori/default.nix
index 45b93bf1ad5f9..7100c70c0ed8a 100644
--- a/pkgs/servers/web-apps/shiori/default.nix
+++ b/pkgs/servers/web-apps/shiori/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "shiori";
@@ -15,7 +15,7 @@ buildGoModule rec {
     sha256 = "13and7gh2882khqppwz3wwq44p7az4bfdfjvlnqcpqyi8xa28pmq";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple bookmark manager built with Go";
     homepage = "https://github.com/go-shiori/shiori";
     license = licenses.mit;
diff --git a/pkgs/servers/web-apps/wallabag/default.nix b/pkgs/servers/web-apps/wallabag/default.nix
index 48afdc5c01daa..6417064663a1b 100644
--- a/pkgs/servers/web-apps/wallabag/default.nix
+++ b/pkgs/servers/web-apps/wallabag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "wallabag";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     cp -R * $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web page archiver";
     longDescription = ''
       wallabag is a self hostable application for saving web pages.
diff --git a/pkgs/servers/web-apps/wordpress/default.nix b/pkgs/servers/web-apps/wordpress/default.nix
index af2a41202671f..0fae5ac2287e7 100644
--- a/pkgs/servers/web-apps/wordpress/default.nix
+++ b/pkgs/servers/web-apps/wordpress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nixosTests }:
+{ lib, stdenv, fetchurl, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "wordpress";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     inherit (nixosTests) wordpress;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wordpress.org";
     description = "WordPress is open source software you can use to create a beautiful website, blog, or app";
     license = [ licenses.gpl2 ];
diff --git a/pkgs/servers/webmetro/default.nix b/pkgs/servers/webmetro/default.nix
index 4be6ef6827477..316e3a524972d 100644
--- a/pkgs/servers/webmetro/default.nix
+++ b/pkgs/servers/webmetro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "webmetro";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0xifc3jwj0c6ynx0gzm5zlnfcq023fjpjmdg9x0vs1fh3b42pdsy";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple relay server for broadcasting a WebM stream";
     longDescription = ''
     Webmetro is a simple relay server for broadcasting a WebM stream
diff --git a/pkgs/servers/wsdd/default.nix b/pkgs/servers/wsdd/default.nix
index 45006cc59e3c5..8fdd9a93a2395 100644
--- a/pkgs/servers/wsdd/default.nix
+++ b/pkgs/servers/wsdd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, nixosTests, python3, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, nixosTests, python3, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "wsdd";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     tests.samba-wsdd = nixosTests.samba-wsdd;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/christgau/wsdd";
     description = "A Web Service Discovery (WSD) host daemon for SMB/Samba";
     maintainers = with maintainers; [ izorkin ];
diff --git a/pkgs/servers/x11/quartz-wm/default.nix b/pkgs/servers/x11/quartz-wm/default.nix
index 84904d48b1ee4..0d7d6df87bc0d 100644
--- a/pkgs/servers/x11/quartz-wm/default.nix
+++ b/pkgs/servers/x11/quartz-wm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xorg, pixman, pkgconfig, AppKit, Foundation, Xplugin }:
+{ lib, stdenv, fetchurl, xorg, pixman, pkgconfig, AppKit, Foundation, Xplugin }:
 
 let version = "1.3.1";
 in stdenv.mkDerivation {
@@ -22,7 +22,7 @@ in stdenv.mkDerivation {
     pkgconfig
     AppKit Xplugin Foundation
   ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.apsl20;
     platforms = platforms.darwin;
     maintainers = with maintainers; [ matthewbauer ];
diff --git a/pkgs/servers/x11/xorg/xcb-util-xrm.nix b/pkgs/servers/x11/xorg/xcb-util-xrm.nix
index e868dbab7f608..cc8bf7dfa106d 100644
--- a/pkgs/servers/x11/xorg/xcb-util-xrm.nix
+++ b/pkgs/servers/x11/xorg/xcb-util-xrm.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, m4, libxcb, xcbutil, libX11 }:
+{ lib, stdenv, fetchurl, pkgconfig, m4, libxcb, xcbutil, libX11 }:
 
 stdenv.mkDerivation rec {
   version = "1.3";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libxcb xcbutil ];
   checkInputs = [ libX11 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XCB utility functions for the X resource manager";
     homepage = "https://github.com/Airblader/xcb-util-xrm";
     license = licenses.mit; # X11 variant
diff --git a/pkgs/servers/x11/xquartz/default.nix b/pkgs/servers/x11/xquartz/default.nix
index cd5fac60abe4c..96269b1a4f37b 100644
--- a/pkgs/servers/x11/xquartz/default.nix
+++ b/pkgs/servers/x11/xquartz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildEnv, makeFontsConf, gnused, writeScript, xorg, bashInteractive, xterm, makeWrapper, ruby
+{ lib, stdenv, buildEnv, makeFontsConf, gnused, writeScript, xorg, bashInteractive, xterm, makeWrapper, ruby
 , quartz-wm, fontconfig, xlsfonts, xfontsel
 , ttf_bitstream_vera, freefont_ttf, liberation_ttf
 , shell ? "${bashInteractive}/bin/bash"
@@ -184,7 +184,7 @@ in stdenv.mkDerivation {
       --replace "@FONTCONFIG_FILE@" "$fontsConfPath"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms   = platforms.darwin;
     maintainers = with maintainers; [ cstrahan ];
     license     = licenses.mit;
diff --git a/pkgs/servers/xandikos/default.nix b/pkgs/servers/xandikos/default.nix
index 515282c1dbcf3..b8eb29d87b2d7 100644
--- a/pkgs/servers/xandikos/default.nix
+++ b/pkgs/servers/xandikos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3Packages
 , installShellFiles
@@ -31,7 +31,7 @@ python3Packages.buildPythonApplication rec {
     installManPage xandikos.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight CalDAV/CardDAV server";
     homepage = "https://github.com/jelmer/xandikos";
     license = licenses.gpl3Plus;
diff --git a/pkgs/servers/xmpp/biboumi/default.nix b/pkgs/servers/xmpp/biboumi/default.nix
index 1547d71791d87..deaa7ca18f074 100644
--- a/pkgs/servers/xmpp/biboumi/default.nix
+++ b/pkgs/servers/xmpp/biboumi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchgit, cmake, libuuid, expat, sqlite, libidn,
+{ lib, stdenv, fetchurl, fetchgit, cmake, libuuid, expat, sqlite, libidn,
   libiconv, botan2, systemd, pkgconfig, udns, pandoc, coreutils } :
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern XMPP IRC gateway";
     platforms = platforms.unix;
     homepage = "https://lab.louiz.org/louiz/biboumi";
diff --git a/pkgs/servers/xmpp/ejabberd/default.nix b/pkgs/servers/xmpp/ejabberd/default.nix
index f6a8f658039b1..1efadd5915eb8 100644
--- a/pkgs/servers/xmpp/ejabberd/default.nix
+++ b/pkgs/servers/xmpp/ejabberd/default.nix
@@ -110,7 +110,7 @@ in stdenv.mkDerivation rec {
     wrapProgram $out/lib/eimp-*/priv/bin/eimp --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [ libpng libjpeg libwebp ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open-source XMPP application server written in Erlang";
     license = licenses.gpl2;
     homepage = "https://www.ejabberd.im";
diff --git a/pkgs/servers/xmpp/pyIRCt/default.nix b/pkgs/servers/xmpp/pyIRCt/default.nix
index 7db8ec3b60499..ebb817f1645ce 100644
--- a/pkgs/servers/xmpp/pyIRCt/default.nix
+++ b/pkgs/servers/xmpp/pyIRCt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xmpppy, pythonIRClib, python, pythonPackages, runtimeShell } :
+{ lib, stdenv, fetchurl, xmpppy, pythonIRClib, python, pythonPackages, runtimeShell } :
 
 stdenv.mkDerivation rec {
   pname = "pyIRCt";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IRC transport module for XMPP";
     platforms = platforms.unix;
     license = licenses.gpl2;
diff --git a/pkgs/servers/xmpp/pyMAILt/default.nix b/pkgs/servers/xmpp/pyMAILt/default.nix
index 0c85f322f4873..68349214359e8 100644
--- a/pkgs/servers/xmpp/pyMAILt/default.nix
+++ b/pkgs/servers/xmpp/pyMAILt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python, xmpppy, pythonPackages, fetchcvs, runtimeShell } :
+{ lib, stdenv, python, xmpppy, pythonPackages, fetchcvs, runtimeShell } :
 
 stdenv.mkDerivation rec {
   pname = "pyMAILt";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Email transport module for XMPP";
     platforms = platforms.unix;
     license = licenses.gpl2;
diff --git a/pkgs/servers/zoneminder/default.nix b/pkgs/servers/zoneminder/default.nix
index 89d4aac340cdb..babcd8e6374bc 100644
--- a/pkgs/servers/zoneminder/default.nix
+++ b/pkgs/servers/zoneminder/default.nix
@@ -194,7 +194,7 @@ in stdenv.mkDerivation rec {
     ln -s $out/share/zoneminder/www $out/share/zoneminder/www/zm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Video surveillance software system";
     homepage = "https://zoneminder.com";
     license = licenses.gpl3;
diff --git a/pkgs/servers/zookeeper/default.nix b/pkgs/servers/zookeeper/default.nix
index 5777532d94746..526a8d2956b34 100644
--- a/pkgs/servers/zookeeper/default.nix
+++ b/pkgs/servers/zookeeper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper, bash, coreutils, runtimeShell }:
+{ lib, stdenv, fetchurl, jre, makeWrapper, bash, coreutils, runtimeShell }:
 
 stdenv.mkDerivation rec {
   pname = "zookeeper";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     chmod -x $out/bin/zkEnv.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zookeeper.apache.org";
     description = "Apache Zookeeper";
     license = licenses.asl20;
diff --git a/pkgs/shells/any-nix-shell/default.nix b/pkgs/shells/any-nix-shell/default.nix
index cfd000d84c66a..3a9f0a0bfbd12 100644
--- a/pkgs/shells/any-nix-shell/default.nix
+++ b/pkgs/shells/any-nix-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "any-nix-shell";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/any-nix-shell --prefix PATH ":" $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "fish and zsh support for nix-shell";
     license = licenses.mit;
     homepage = "https://github.com/haslersn/any-nix-shell";
diff --git a/pkgs/shells/bash/4.4.nix b/pkgs/shells/bash/4.4.nix
index d06157fa77cc1..afdfb816c9557 100644
--- a/pkgs/shells/bash/4.4.nix
+++ b/pkgs/shells/bash/4.4.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages
+{ lib, stdenv, buildPackages
 , fetchurl, binutils ? null, bison, autoconf, util-linux
 
 # patch for cygwin requires readline support
@@ -111,7 +111,7 @@ stdenv.mkDerivation rec {
       rm -rf "$out/share" "$out/bin/bashbug"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/bash/";
     description =
       "GNU Bourne-Again Shell, the de facto standard shell on Linux" +
diff --git a/pkgs/shells/bash/5.1.nix b/pkgs/shells/bash/5.1.nix
index 8950e5f5b1cfa..fd8c0c32cd618 100644
--- a/pkgs/shells/bash/5.1.nix
+++ b/pkgs/shells/bash/5.1.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPackages
 , fetchurl
 , binutils ? null
@@ -102,7 +102,7 @@ stdenv.mkDerivation rec {
       rm -rf "$out/share" "$out/bin/bashbug"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/bash/";
     description =
       "GNU Bourne-Again Shell, the de facto standard shell on Linux" +
diff --git a/pkgs/shells/bash/bash-completion/default.nix b/pkgs/shells/bash/bash-completion/default.nix
index 4599b0a22838d..22a7ead545dd5 100644
--- a/pkgs/shells/bash/bash-completion/default.nix
+++ b/pkgs/shells/bash/bash-completion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , fetchpatch
 , autoreconfHook
 , perl
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     sed -i -e 's/readlink -f/readlink/g' bash_completion completions/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/scop/bash-completion";
     description = "Programmable completion for the bash shell";
     license = licenses.gpl2Plus;
diff --git a/pkgs/shells/bash/nix-bash-completions/default.nix b/pkgs/shells/bash/nix-bash-completions/default.nix
index 5dfd673a62984..2034eed1f5dab 100644
--- a/pkgs/shells/bash/nix-bash-completions/default.nix
+++ b/pkgs/shells/bash/nix-bash-completions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   version = "0.6.8";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hedning/nix-bash-completions";
     description = "Bash completions for Nix, NixOS, and NixOps";
     license = licenses.bsd3;
diff --git a/pkgs/shells/dash/default.nix b/pkgs/shells/dash/default.nix
index bc270daf09cf2..2c6e9cc0e6814 100644
--- a/pkgs/shells/dash/default.nix
+++ b/pkgs/shells/dash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, autoreconfHook, fetchurl }:
+{ lib, stdenv, buildPackages, autoreconfHook, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "dash";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   depsBuildBuild = [ buildPackages.stdenv.cc ];
   nativeBuildInputs = stdenv.lib.optional stdenv.isDarwin autoreconfHook;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gondor.apana.org.au/~herbert/dash/";
     description = "A POSIX-compliant implementation of /bin/sh that aims to be as small as possible";
     platforms = platforms.unix;
diff --git a/pkgs/shells/dgsh/default.nix b/pkgs/shells/dgsh/default.nix
index 0314180e2d55a..28e5b15b3e764 100644
--- a/pkgs/shells/dgsh/default.nix
+++ b/pkgs/shells/dgsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, pkgconfig,
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, pkgconfig,
   libtool, check, bison, git, gperf,
   perl, texinfo, help2man, gettext, ncurses
 }:
@@ -35,7 +35,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Directed Graph Shell";
     homepage = "http://www.dmst.aueb.gr/dds/sw/dgsh";
     license = with licenses; asl20;
diff --git a/pkgs/shells/elvish/default.nix b/pkgs/shells/elvish/default.nix
index 2cb45f33f7bc7..938029e9af97c 100644
--- a/pkgs/shells/elvish/default.nix
+++ b/pkgs/shells/elvish/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "elvish";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A friendly and expressive command shell";
     longDescription = ''
       Elvish is a friendly interactive shell and an expressive programming
diff --git a/pkgs/shells/es/default.nix b/pkgs/shells/es/default.nix
index 992fdc93dcb32..7b2251a3f4407 100644
--- a/pkgs/shells/es/default.nix
+++ b/pkgs/shells/es/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, readline, yacc }:
+{ lib, stdenv, fetchurl, readline, yacc }:
 
 let
   version = "0.9.1";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
 
   configureFlags = [ "--with-readline" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An extensible shell with higher order functions";
     longDescription =
       ''
diff --git a/pkgs/shells/ion/default.nix b/pkgs/shells/ion/default.nix
index c2cc626bd3c93..d1b499a9160cf 100644
--- a/pkgs/shells/ion/default.nix
+++ b/pkgs/shells/ion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "ion";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1ph3r3vspy700mb8pica8478v9arqz07k2nzpbrdkdkqgfcwlgcg";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modern system shell with simple (and powerful) syntax";
     homepage = "https://gitlab.redox-os.org/redox-os/ion";
     license = licenses.mit;
diff --git a/pkgs/shells/jush/default.nix b/pkgs/shells/jush/default.nix
index 9894c90bb69e2..f6d07814ce129 100644
--- a/pkgs/shells/jush/default.nix
+++ b/pkgs/shells/jush/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, editline }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, editline }:
 
 stdenv.mkDerivation rec {
   pname = "jush";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   passthru.shellPath = "/bin/jush";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "just a useless shell";
     homepage = "https://github.com/troglobit/jush";
     license = licenses.isc;
diff --git a/pkgs/shells/ksh/default.nix b/pkgs/shells/ksh/default.nix
index e27732226f55f..822f1dc3491b1 100644
--- a/pkgs/shells/ksh/default.nix
+++ b/pkgs/shells/ksh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, meson, ninja, fetchFromGitHub, which, python, fetchpatch
+{ lib, stdenv, meson, ninja, fetchFromGitHub, which, python, fetchpatch
 , libiconv }:
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libiconv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "KornShell Command And Programming Language";
     longDescription = ''
       The KornShell language was designed and developed by David G. Korn at
diff --git a/pkgs/shells/liquidprompt/default.nix b/pkgs/shells/liquidprompt/default.nix
index 9893624eaf86a..4463d70cf5262 100644
--- a/pkgs/shells/liquidprompt/default.nix
+++ b/pkgs/shells/liquidprompt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "liquidprompt";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       $out/share/zsh/plugins/liquidprompt/liquidprompt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full-featured & carefully designed adaptive prompt for Bash & Zsh";
     homepage = "https://github.com/nojhan/liquidprompt";
     license = licenses.agpl3;
diff --git a/pkgs/shells/mksh/default.nix b/pkgs/shells/mksh/default.nix
index c19406e5f55c3..7022f6b37e319 100644
--- a/pkgs/shells/mksh/default.nix
+++ b/pkgs/shells/mksh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "mksh";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     install -D -m 644 dot.mkshrc $out/share/mksh/mkshrc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MirBSD Korn Shell";
     longDescription = ''
       The MirBSD Korn Shell is a DFSG-free and OSD-compliant (and OSI
diff --git a/pkgs/shells/mrsh/default.nix b/pkgs/shells/mrsh/default.nix
index c72f23c143b01..c457b72953b47 100644
--- a/pkgs/shells/mrsh/default.nix
+++ b/pkgs/shells/mrsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, readline }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, readline }:
 
 stdenv.mkDerivation rec {
   pname   = "mrsh";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal POSIX shell";
     homepage = "https://mrsh.sh";
     license = licenses.mit;
diff --git a/pkgs/shells/oksh/default.nix b/pkgs/shells/oksh/default.nix
index 7ec70e53bd288..8c2998ab54cc1 100644
--- a/pkgs/shells/oksh/default.nix
+++ b/pkgs/shells/oksh/default.nix
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
     sha256 = "0lny550qfanysc4pqs0mxxx8zyz6plv9ll8y05gz0xmq9vx5384r";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Portable OpenBSD ksh, based on the Public Domain Korn Shell (pdksh)";
     homepage = "https://github.com/ibara/oksh";
     license = licenses.publicDomain;
diff --git a/pkgs/shells/pash/default.nix b/pkgs/shells/pash/default.nix
index c646c1c3f9bd3..06ca242079875 100644
--- a/pkgs/shells/pash/default.nix
+++ b/pkgs/shells/pash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildDotnetPackage }:
+{ lib, stdenv, fetchFromGitHub, buildDotnetPackage }:
 
 buildDotnetPackage {
   baseName = "pash";
@@ -15,7 +15,7 @@ buildDotnetPackage {
 
   outputFiles = [ "Source/PashConsole/bin/Release/*" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An open source implementation of Windows PowerShell";
     homepage = "https://github.com/Pash-Project/Pash";
     maintainers = [ maintainers.fornever maintainers.vrthra ];
diff --git a/pkgs/shells/rc/default.nix b/pkgs/shells/rc/default.nix
index cd5ed860b2e66..a71d5ba289717 100644
--- a/pkgs/shells/rc/default.nix
+++ b/pkgs/shells/rc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook
+{ lib, stdenv, fetchurl, autoreconfHook
 , ncurses #acinclude.m4 wants headers for tgetent().
 , historySupport ? false
 , readline ? null
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     shellPath = "/bin/rc";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Plan 9 shell";
     longDescription = "Byron Rakitzis' UNIX reimplementation of Tom Duff's Plan 9 shell.";
     homepage = "http://tobold.org/article/rc";
diff --git a/pkgs/shells/tcsh/default.nix b/pkgs/shells/tcsh/default.nix
index d6527ef24b5b9..468d17b60b7e1 100644
--- a/pkgs/shells/tcsh/default.nix
+++ b/pkgs/shells/tcsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch
+{ lib, stdenv, fetchurl, fetchpatch
 , ncurses
 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       sha256 = "1qc6ydxhdfizsbkaxhpn3wib8sfphrw10xnnsxx2prvzg9g2zp67";
     });
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An enhanced version of the Berkeley UNIX C shell (csh)";
     longDescription = ''
       tcsh is an enhanced but completely compatible version of the
diff --git a/pkgs/shells/xonsh/default.nix b/pkgs/shells/xonsh/default.nix
index 711d7060fa55d..53bd137ddfae8 100644
--- a/pkgs/shells/xonsh/default.nix
+++ b/pkgs/shells/xonsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3Packages
 , glibcLocales
@@ -43,7 +43,7 @@ python3Packages.buildPythonApplication rec {
 
   propagatedBuildInputs = with python3Packages; [ ply prompt_toolkit pygments ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python-ish, BASHwards-compatible shell";
     homepage = "https://xon.sh/";
     changelog = "https://github.com/xonsh/xonsh/releases/tag/${version}";
diff --git a/pkgs/shells/zsh/fzf-zsh/default.nix b/pkgs/shells/zsh/fzf-zsh/default.nix
index 075707f425c4c..ac5cab94d4cb6 100644
--- a/pkgs/shells/zsh/fzf-zsh/default.nix
+++ b/pkgs/shells/zsh/fzf-zsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fzf }:
+{ lib, stdenv, fetchFromGitHub, fzf }:
 
 stdenv.mkDerivation rec {
   pname = "fzf-zsh-unstable";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     install -Dm0644 fzf-zsh.plugin.zsh $out/share/zsh/plugins/fzf-zsh/fzf-zsh.plugin.zsh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/wyntau/fzf-zsh";
     description = "wrap fzf to use in oh-my-zsh";
     license = licenses.mit;
diff --git a/pkgs/shells/zsh/gradle-completion/default.nix b/pkgs/shells/zsh/gradle-completion/default.nix
index 72667d862a893..bf5969d1300a5 100644
--- a/pkgs/shells/zsh/gradle-completion/default.nix
+++ b/pkgs/shells/zsh/gradle-completion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "gradle-completion";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gradle tab completion for bash and zsh";
     homepage = "https://github.com/gradle/gradle-completion";
     license = licenses.mit;
diff --git a/pkgs/shells/zsh/grml-zsh-config/default.nix b/pkgs/shells/zsh/grml-zsh-config/default.nix
index 756c01d6e3467..2018163054794 100644
--- a/pkgs/shells/zsh/grml-zsh-config/default.nix
+++ b/pkgs/shells/zsh/grml-zsh-config/default.nix
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     ln -s grmlzshrc.5.gz $out/share/man/man5/grml-zsh-config.5.gz
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "grml's zsh setup";
     homepage = "https://grml.org/zsh/";
     license = licenses.gpl2;
diff --git a/pkgs/shells/zsh/lambda-mod-zsh-theme/default.nix b/pkgs/shells/zsh/lambda-mod-zsh-theme/default.nix
index 37614dac0a325..d9a846c9e06f7 100644
--- a/pkgs/shells/zsh/lambda-mod-zsh-theme/default.nix
+++ b/pkgs/shells/zsh/lambda-mod-zsh-theme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "lambda-mod-zsh-theme-unstable";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     install -Dm0644 lambda-mod.zsh-theme $out/share/zsh/themes/lambda-mod.zsh-theme
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A ZSH theme optimized for people who use Git & Unicode-compatible fonts and terminals";
     homepage = "https://github.com/halfo/lambda-mod-zsh-theme/";
     license = licenses.mit;
diff --git a/pkgs/shells/zsh/nix-zsh-completions/default.nix b/pkgs/shells/zsh/nix-zsh-completions/default.nix
index 623d562b16e04..c48bf209d0f9f 100644
--- a/pkgs/shells/zsh/nix-zsh-completions/default.nix
+++ b/pkgs/shells/zsh/nix-zsh-completions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 let
   version = "0.4.4";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     cp *.zsh $out/share/zsh/plugins/nix
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/spwhitt/nix-zsh-completions";
     description = "ZSH completions for Nix, NixOS, and NixOps";
     license = licenses.bsd3;
diff --git a/pkgs/shells/zsh/oh-my-zsh/default.nix b/pkgs/shells/zsh/oh-my-zsh/default.nix
index 429d1c55c8b28..1b3a4c21cf32e 100644
--- a/pkgs/shells/zsh/oh-my-zsh/default.nix
+++ b/pkgs/shells/zsh/oh-my-zsh/default.nix
@@ -1,7 +1,7 @@
 # This script was inspired by the ArchLinux User Repository package:
 #
 #   https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=oh-my-zsh-git
-{ stdenv, fetchFromGitHub, nixosTests, writeScript, common-updater-scripts, git
+{ lib, stdenv, fetchFromGitHub, nixosTests, writeScript, common-updater-scripts, git
 , nix, nixfmt, jq, coreutils, gnused, curl, cacert }:
 
 stdenv.mkDerivation rec {
@@ -102,7 +102,7 @@ stdenv.mkDerivation rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A framework for managing your zsh configuration";
     longDescription = ''
       Oh My Zsh is a framework for managing your zsh configuration.
diff --git a/pkgs/shells/zsh/spaceship-prompt/default.nix b/pkgs/shells/zsh/spaceship-prompt/default.nix
index 7db8cdb334920..8f4b9bf0875cb 100644
--- a/pkgs/shells/zsh/spaceship-prompt/default.nix
+++ b/pkgs/shells/zsh/spaceship-prompt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "spaceship-prompt";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     ln -s "$out/lib/spaceship-prompt/spaceship.zsh" "$out/share/zsh/site-functions/prompt_spaceship_setup"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Zsh prompt for Astronauts";
     homepage = "https://github.com/denysdovhan/spaceship-prompt/";
     license = licenses.mit;
diff --git a/pkgs/shells/zsh/zsh-autosuggestions/default.nix b/pkgs/shells/zsh/zsh-autosuggestions/default.nix
index 58e560d2fa4dc..3f5cadfccb1d0 100644
--- a/pkgs/shells/zsh/zsh-autosuggestions/default.nix
+++ b/pkgs/shells/zsh/zsh-autosuggestions/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zsh }:
+{ lib, stdenv, fetchFromGitHub, zsh }:
 
 # To make use of this derivation, use the `programs.zsh.enableAutoSuggestions` option
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
       $out/share/zsh-autosuggestions/zsh-autosuggestions.zsh
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fish shell autosuggestions for Zsh";
     homepage = "https://github.com/zsh-users/zsh-autosuggestions";
     license = licenses.mit;
diff --git a/pkgs/shells/zsh/zsh-command-time/default.nix b/pkgs/shells/zsh/zsh-command-time/default.nix
index 3ef210a028186..9696e441cf5ab 100644
--- a/pkgs/shells/zsh/zsh-command-time/default.nix
+++ b/pkgs/shells/zsh/zsh-command-time/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 # To make use of this plugin, need to add
 #   programs.zsh.interactiveShellInit = ''
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     install -Dm0444 $src/command-time.plugin.zsh --target-directory=$out/share/zsh/plugins/command-time
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Plugin that output time: xx after long commands";
     homepage = "https://github.com/popstas/zsh-command-time";
     license = licenses.mit;
diff --git a/pkgs/shells/zsh/zsh-deer/default.nix b/pkgs/shells/zsh/zsh-deer/default.nix
index 735d6a2b7619c..895ca621cfedd 100644
--- a/pkgs/shells/zsh/zsh-deer/default.nix
+++ b/pkgs/shells/zsh/zsh-deer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl }:
+{ lib, stdenv, fetchFromGitHub, perl }:
 
 let
   version = "1.4";
@@ -25,7 +25,7 @@ in stdenv.mkDerivation {
     cp deer $out/share/zsh/site-functions/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ranger-like file navigation for zsh";
     homepage = "https://github.com/Vifon/deer";
     license = licenses.gpl3Plus;
diff --git a/pkgs/shells/zsh/zsh-nix-shell/default.nix b/pkgs/shells/zsh/zsh-nix-shell/default.nix
index 6db78f1c0f567..20017414cf7d4 100644
--- a/pkgs/shells/zsh/zsh-nix-shell/default.nix
+++ b/pkgs/shells/zsh/zsh-nix-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgs }:
+{ lib, stdenv, fetchFromGitHub, pkgs }:
 
 # To make use of this derivation, use
 # `programs.zsh.interactiveShellInit = "source ${pkgs.zsh-nix-shell}/share/zsh-nix-shell/nix-shell.plugin.zsh";`
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D scripts/* --target-directory=$out/share/zsh-nix-shell/scripts
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "zsh plugin that lets you use zsh in nix-shell shell";
     homepage = src.meta.homepage;
     license = licenses.bsd3;
diff --git a/pkgs/shells/zsh/zsh-prezto/default.nix b/pkgs/shells/zsh/zsh-prezto/default.nix
index dffecf617b17a..138de38786be1 100644
--- a/pkgs/shells/zsh/zsh-prezto/default.nix
+++ b/pkgs/shells/zsh/zsh-prezto/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "zsh-prezto";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out
     cp ./* $out/ -R
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prezto is the configuration framework for Zsh; it enriches the command line interface environment with sane defaults, aliases, functions, auto completion, and prompt themes";
     homepage = "https://github.com/sorin-ionescu/prezto";
     license = licenses.mit;
diff --git a/pkgs/shells/zsh/zsh-syntax-highlighting/default.nix b/pkgs/shells/zsh/zsh-syntax-highlighting/default.nix
index 906352b8b3e03..09d6eb3cf9633 100644
--- a/pkgs/shells/zsh/zsh-syntax-highlighting/default.nix
+++ b/pkgs/shells/zsh/zsh-syntax-highlighting/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zsh }:
+{ lib, stdenv, fetchFromGitHub, zsh }:
 
 # To make use of this derivation, use the `programs.zsh.enableSyntaxHighlighting` option
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fish shell like syntax highlighting for Zsh";
     homepage = "https://github.com/zsh-users/zsh-syntax-highlighting";
     license = licenses.bsd3;
diff --git a/pkgs/shells/zsh/zsh-you-should-use/default.nix b/pkgs/shells/zsh/zsh-you-should-use/default.nix
index 603757c3332be..8019e75a8594b 100644
--- a/pkgs/shells/zsh/zsh-you-should-use/default.nix
+++ b/pkgs/shells/zsh/zsh-you-should-use/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "zsh-you-should-use";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -D you-should-use.plugin.zsh $out/share/zsh/plugins/you-should-use/you-should-use.plugin.zsh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/MichaelAquilina/zsh-you-should-use";
     license = licenses.gpl3;
     description = "ZSH plugin that reminds you to use existing aliases for commands you just typed";
diff --git a/pkgs/tools/X11/alttab/default.nix b/pkgs/tools/X11/alttab/default.nix
index 7917ad5215eb1..4c9c0b66a5059 100644
--- a/pkgs/tools/X11/alttab/default.nix
+++ b/pkgs/tools/X11/alttab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, pkgconfig, ronn, libpng, uthash
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, pkgconfig, ronn, libpng, uthash
 , xorg }:
 
 stdenv.mkDerivation rec {
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sagb/alttab";
     description = "X11 window switcher designed for minimalistic window managers or standalone X11 session";
     license = licenses.gpl3;
diff --git a/pkgs/tools/X11/bgs/default.nix b/pkgs/tools/X11/bgs/default.nix
index 66d845b0587fa..9db666672d48b 100644
--- a/pkgs/tools/X11/bgs/default.nix
+++ b/pkgs/tools/X11/bgs/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, pkgconfig, libX11, libXinerama, imlib2}:
+{lib, stdenv, fetchurl, pkgconfig, libX11, libXinerama, imlib2}:
 
 stdenv.mkDerivation rec {
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = ''sed -i "s@PREFIX = /usr/local@PREFIX = $out@g" config.mk'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extremely fast and small background setter for X";
     license = licenses.mit;
     platforms = platforms.linux;
diff --git a/pkgs/tools/X11/bumblebee/default.nix b/pkgs/tools/X11/bumblebee/default.nix
index 8540cf6975dcd..8bd65ec2fc2ce 100644
--- a/pkgs/tools/X11/bumblebee/default.nix
+++ b/pkgs/tools/X11/bumblebee/default.nix
@@ -133,7 +133,7 @@ in stdenv.mkDerivation rec {
       --prefix PATH : "${virtualgl}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Bumblebee-Project/Bumblebee";
     description = "Daemon for managing Optimus videocards (power-on/off, spawns xservers)";
     platforms = platforms.linux;
diff --git a/pkgs/tools/X11/ckbcomp/default.nix b/pkgs/tools/X11/ckbcomp/default.nix
index 275fe38611def..8bb2cddc08012 100644
--- a/pkgs/tools/X11/ckbcomp/default.nix
+++ b/pkgs/tools/X11/ckbcomp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, perl, xkeyboard_config }:
+{ lib, stdenv, fetchFromGitLab, perl, xkeyboard_config }:
 
 stdenv.mkDerivation rec {
   pname = "ckbcomp";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     install -Dm0444 -t $out/share/man/man1 man/ckbcomp.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compiles a XKB keyboard description to a keymap suitable for loadkeys";
     homepage = "https://salsa.debian.org/installer-team/console-setup";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/X11/devour/default.nix b/pkgs/tools/X11/devour/default.nix
index 4f39c0a989041..016ffa6215dbd 100644
--- a/pkgs/tools/X11/devour/default.nix
+++ b/pkgs/tools/X11/devour/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11 }:
+{ lib, stdenv, fetchFromGitHub, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "devour";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libX11 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Devour hides your current window when launching an external program";
     longDescription = "Devour hides your current window before launching an external program and unhides it after quitting";
     homepage = "https://github.com/salman-abedin/devour";
diff --git a/pkgs/tools/X11/dex/default.nix b/pkgs/tools/X11/dex/default.nix
index 22d6c1bfdecac..dd1953d783a01 100644
--- a/pkgs/tools/X11/dex/default.nix
+++ b/pkgs/tools/X11/dex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 stdenv.mkDerivation rec {
   program = "dex";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ python3.pkgs.sphinx ];
   makeFlags = [ "PREFIX=$(out)" "VERSION=$(version)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program to generate and execute DesktopEntry files of the Application type";
     homepage = "https://github.com/jceb/dex";
     platforms = platforms.linux;
diff --git a/pkgs/tools/X11/dispad/default.nix b/pkgs/tools/X11/dispad/default.nix
index fccb28489efda..fbb7b117d2982 100644
--- a/pkgs/tools/X11/dispad/default.nix
+++ b/pkgs/tools/X11/dispad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, libXi, libconfuse }:
+{ lib, stdenv, fetchFromGitHub, libX11, libXi, libconfuse }:
 
 stdenv.mkDerivation rec {
   pname = "dispad";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libX11 libXi libconfuse ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small daemon for disabling trackpads while typing";
     homepage = "https://github.com/BlueDragonX/dispad";
     license = licenses.gpl2;
diff --git a/pkgs/tools/X11/dragon-drop/default.nix b/pkgs/tools/X11/dragon-drop/default.nix
index 86c867b16ba8a..632fc844e5eda 100644
--- a/pkgs/tools/X11/dragon-drop/default.nix
+++ b/pkgs/tools/X11/dragon-drop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gtk, pkgconfig, fetchFromGitHub }:
+{ lib, stdenv, gtk, pkgconfig, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "dragon-drop";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -D dragon -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple drag-and-drop source/sink for X";
     homepage = "https://github.com/mwh/dragon";
     maintainers = with maintainers; [ jb55 markus1189 ];
diff --git a/pkgs/tools/X11/ffcast/default.nix b/pkgs/tools/X11/ffcast/default.nix
index 1378d5e6b9825..3f6122e4093d7 100644
--- a/pkgs/tools/X11/ffcast/default.nix
+++ b/pkgs/tools/X11/ffcast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, perl, libX11 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, perl, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "ffcast";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     make install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Run commands on rectangular screen regions";
     homepage = "https://github.com/lolilolicon/FFcast";
     license = licenses.gpl3;
diff --git a/pkgs/tools/X11/find-cursor/default.nix b/pkgs/tools/X11/find-cursor/default.nix
index 13f274577887c..9e3b779d686b5 100644
--- a/pkgs/tools/X11/find-cursor/default.nix
+++ b/pkgs/tools/X11/find-cursor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, libXdamage, libXrender, libXcomposite, libXext, installShellFiles, git }:
+{ lib, stdenv, fetchFromGitHub, libX11, libXdamage, libXrender, libXcomposite, libXext, installShellFiles, git }:
 
 stdenv.mkDerivation rec {
   pname = "find-cursor";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   preInstall = "mkdir -p $out/share/man/man1";
   installFlags = "PREFIX=${placeholder "out"}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple XLib program to highlight the cursor position";
     homepage = "https://github.com/arp242/find-cursor";
     license = licenses.mit;
diff --git a/pkgs/tools/X11/go-sct/default.nix b/pkgs/tools/X11/go-sct/default.nix
index 01d82b4a112c7..b52183e2dd283 100644
--- a/pkgs/tools/X11/go-sct/default.nix
+++ b/pkgs/tools/X11/go-sct/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, xorg, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, xorg, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "go-sct";
@@ -18,7 +18,7 @@ buildGoPackage rec {
 
   buildInputs = [ xorg.libX11 xorg.libXrandr ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Color temperature setting library and CLI that operates in a similar way to f.lux and Redshift";
     license = licenses.mit;
     maintainers = with maintainers; [ rvolosatovs cstrahan ];
diff --git a/pkgs/tools/X11/grobi/default.nix b/pkgs/tools/X11/grobi/default.nix
index 9d10dd4788185..1ebd8ccc4e4c5 100644
--- a/pkgs/tools/X11/grobi/default.nix
+++ b/pkgs/tools/X11/grobi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule, fetchpatch }:
 
 buildGoModule rec {
   version = "0.6.0";
@@ -21,7 +21,7 @@ buildGoModule rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/fd0/grobi";
     description = "Automatically configure monitors/outputs for Xorg via RANDR";
     license = with licenses; [ bsd2 ];
diff --git a/pkgs/tools/X11/hsetroot/default.nix b/pkgs/tools/X11/hsetroot/default.nix
index 0d42687bf0b06..69842a7bd59ce 100644
--- a/pkgs/tools/X11/hsetroot/default.nix
+++ b/pkgs/tools/X11/hsetroot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , imlib2
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows you to compose wallpapers ('root pixmaps') for X";
     homepage = "https://github.com/himdel/hsetroot";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/X11/imwheel/default.nix b/pkgs/tools/X11/imwheel/default.nix
index efed00f963975..27a545a95cdb3 100644
--- a/pkgs/tools/X11/imwheel/default.nix
+++ b/pkgs/tools/X11/imwheel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXext, libXi, libXmu, libXt, libXtst }:
+{ lib, stdenv, fetchurl, libX11, libXext, libXi, libXmu, libXt, libXtst }:
 
 stdenv.mkDerivation rec {
   name = "imwheel-1.0.0pre12";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "ETCDIR=${placeholder "out"}/etc"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://imwheel.sourceforge.net/";
     description = "Mouse wheel configuration tool for XFree86/Xorg";
     maintainers = with maintainers; [ jhillyerd ];
diff --git a/pkgs/tools/X11/keynav/default.nix b/pkgs/tools/X11/keynav/default.nix
index 64684cf73df2c..d737ba56ed86b 100644
--- a/pkgs/tools/X11/keynav/default.nix
+++ b/pkgs/tools/X11/keynav/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libX11, xorgproto, libXtst, libXi, libXext
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libX11, xorgproto, libXtst, libXi, libXext
 , libXinerama, libXrandr, glib, cairo, xdotool }:
 
 let release = "20180821"; in
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
       cp keynavrc $out/share/keynav/doc
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate X11 mouse clicks from keyboard";
     homepage = "https://www.semicomplete.com/projects/keynav/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/X11/ksuperkey/default.nix b/pkgs/tools/X11/ksuperkey/default.nix
index d5c2232dce118..aed85f978cd5b 100644
--- a/pkgs/tools/X11/ksuperkey/default.nix
+++ b/pkgs/tools/X11/ksuperkey/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, libXtst, pkgconfig, xorgproto, libXi }:
+{ lib, stdenv, fetchFromGitHub, libX11, libXtst, pkgconfig, xorgproto, libXi }:
 
 stdenv.mkDerivation rec {
   pname = "ksuperkey";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libX11 libXtst xorgproto libXi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to be able to bind the super key as a key rather than a modifier";
     homepage = "https://github.com/hanschen/ksuperkey";
     license = licenses.gpl3;
diff --git a/pkgs/tools/X11/libstrangle/default.nix b/pkgs/tools/X11/libstrangle/default.nix
index d24654ce3ad7a..1f0a7a8e3a6af 100644
--- a/pkgs/tools/X11/libstrangle/default.nix
+++ b/pkgs/tools/X11/libstrangle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "libstrangle";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     substituteAllInPlace src/strangle.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/milaq/libstrangle";
     description = "Frame rate limiter for Linux/OpenGL";
     license = licenses.gpl3;
diff --git a/pkgs/tools/X11/ncview/default.nix b/pkgs/tools/X11/ncview/default.nix
index 1f793aa6c4c97..c22c6c0eb38ab 100644
--- a/pkgs/tools/X11/ncview/default.nix
+++ b/pkgs/tools/X11/ncview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , netcdf, xlibsWrapper, xorg, udunits, expat
 }:
 
@@ -16,7 +16,7 @@ in stdenv.mkDerivation {
 
   buildInputs = [ netcdf xlibsWrapper xorg.libXaw udunits expat ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Visual browser for netCDF format files";
     homepage    = "http://meteora.ucsd.edu/~pierce/ncview_home_page.html";
     license = licenses.gpl3;
diff --git a/pkgs/tools/X11/numlockx/default.nix b/pkgs/tools/X11/numlockx/default.nix
index b59e9dc30ac86..5cd23a81f308e 100644
--- a/pkgs/tools/X11/numlockx/default.nix
+++ b/pkgs/tools/X11/numlockx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, libXext, autoconf }:
+{ lib, stdenv, fetchFromGitHub, libX11, libXext, autoconf }:
 
 stdenv.mkDerivation rec {
   version = "1.2";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libX11 libXext autoconf ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows to start X with NumLock turned on";
     license = licenses.mit;
     platforms = platforms.all;
diff --git a/pkgs/tools/X11/primus/lib.nix b/pkgs/tools/X11/primus/lib.nix
index f4c2c9efc49ee..d2f779ddd724f 100644
--- a/pkgs/tools/X11/primus/lib.nix
+++ b/pkgs/tools/X11/primus/lib.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , libX11, libGL, mesa
 , nvidia_x11 ? null
 , libglvnd
@@ -42,7 +42,7 @@ in stdenv.mkDerivation {
 
   passthru.glvnd = if nvidia_x11 != null && nvidia_x11.useGLVND then nvidia_x11 else null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Low-overhead client-side GPU offloading";
     homepage = "https://github.com/amonakov/primus";
     platforms = [ "i686-linux" "x86_64-linux" ];
diff --git a/pkgs/tools/X11/run-scaled/default.nix b/pkgs/tools/X11/run-scaled/default.nix
index aae09d49b3d4a..6b2f400c29513 100644
--- a/pkgs/tools/X11/run-scaled/default.nix
+++ b/pkgs/tools/X11/run-scaled/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, bc, xorgserver, xpra, xrandr }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, bc, xorgserver, xpra, xrandr }:
 
 stdenv.mkDerivation {
   version = "git-2018-06-03";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
       ${stdenv.lib.makeBinPath [ bc xorgserver xpra xrandr ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Run an X application scaled via xpra";
     homepage = "https://github.com/kaueraal/run_scaled";
     maintainers = [ maintainers.snaar ];
diff --git a/pkgs/tools/X11/sct/default.nix b/pkgs/tools/X11/sct/default.nix
index 3f6291417e590..0d74206155ab6 100644
--- a/pkgs/tools/X11/sct/default.nix
+++ b/pkgs/tools/X11/sct/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXrandr }:
+{ lib, stdenv, fetchurl, libX11, libXrandr }:
 
 stdenv.mkDerivation rec {
   name = "sct";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "install -Dt $out/bin sct";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.tedunangst.com/flak/post/sct-set-color-temperature";
     description = "A minimal utility to set display colour temperature";
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/tools/X11/setroot/default.nix b/pkgs/tools/X11/setroot/default.nix
index 56c356b20d5b2..a59e2a0d0dbb5 100644
--- a/pkgs/tools/X11/setroot/default.nix
+++ b/pkgs/tools/X11/setroot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, imlib2
+{ lib, stdenv, fetchFromGitHub, libX11, imlib2
 , enableXinerama ? true, libXinerama ? null
 }:
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "DESTDIR=$(out)" "PREFIX=" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple X background setter inspired by imlibsetroot and feh";
     homepage = "https://github.com/ttzhou/setroot";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/X11/srandrd/default.nix b/pkgs/tools/X11/srandrd/default.nix
index 6d5fa0f3d980e..4c79e11765cb2 100644
--- a/pkgs/tools/X11/srandrd/default.nix
+++ b/pkgs/tools/X11/srandrd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , libX11
 , libXrandr
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jceb/srandrd";
     description = "Simple randr daemon";
     license = licenses.mit;
diff --git a/pkgs/tools/X11/vdpauinfo/default.nix b/pkgs/tools/X11/vdpauinfo/default.nix
index 741043a9e5386..73f94768bcd9b 100644
--- a/pkgs/tools/X11/vdpauinfo/default.nix
+++ b/pkgs/tools/X11/vdpauinfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libvdpau }:
+{ lib, stdenv, fetchurl, pkgconfig, libvdpau }:
 
 stdenv.mkDerivation rec {
   pname = "vdpauinfo";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libvdpau ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://people.freedesktop.org/~aplattner/vdpau/";
     description = "Tool to query the Video Decode and Presentation API for Unix (VDPAU) abilities of the system";
     license = licenses.mit; # expat version
diff --git a/pkgs/tools/X11/virtualgl/lib.nix b/pkgs/tools/X11/virtualgl/lib.nix
index cf5f198245437..362a86fff37c0 100644
--- a/pkgs/tools/X11/virtualgl/lib.nix
+++ b/pkgs/tools/X11/virtualgl/lib.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake
+{ lib, stdenv, fetchurl, cmake
 , libGL, libGLU, libX11, libXv, libXtst, libjpeg_turbo, fltk
 , xorg
 , opencl-headers, opencl-clhpp, ocl-icd
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
       --replace "LD_PRELOAD=libgefaker" "LD_PRELOAD=$out/lib/libgefaker"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.virtualgl.org/";
     description = "X11 GL rendering in a remote computer with full 3D hw acceleration";
     license = licenses.wxWindows;
diff --git a/pkgs/tools/X11/wmutils-core/default.nix b/pkgs/tools/X11/wmutils-core/default.nix
index fdf805f809924..c8f3bd52c3e9b 100644
--- a/pkgs/tools/X11/wmutils-core/default.nix
+++ b/pkgs/tools/X11/wmutils-core/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxcb }:
+{ lib, stdenv, fetchurl, libxcb }:
 
 stdenv.mkDerivation rec {
   pname = "wmutils-core";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of window manipulation tools";
     homepage = "https://github.com/wmutils/core";
     license = licenses.isc;
diff --git a/pkgs/tools/X11/wmutils-libwm/default.nix b/pkgs/tools/X11/wmutils-libwm/default.nix
index 72022621afedc..6d2787a96cd31 100644
--- a/pkgs/tools/X11/wmutils-libwm/default.nix
+++ b/pkgs/tools/X11/wmutils-libwm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libxcb }:
+{ lib, stdenv, fetchFromGitHub, libxcb }:
 
 stdenv.mkDerivation rec {
   pname = "wmutils-libwm";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small library for X window manipulation";
     homepage = "https://github.com/wmutils/libwm";
     license = licenses.isc;
diff --git a/pkgs/tools/X11/wmutils-opt/default.nix b/pkgs/tools/X11/wmutils-opt/default.nix
index 39f26b95cdbcc..0d847262ea587 100644
--- a/pkgs/tools/X11/wmutils-opt/default.nix
+++ b/pkgs/tools/X11/wmutils-opt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libxcb }:
+{ lib, stdenv, fetchFromGitHub, libxcb }:
 
 stdenv.mkDerivation rec {
   pname = "wmutils-opt";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optional addons to wmutils";
     homepage = "https://github.com/wmutils/opt";
     license = licenses.isc;
diff --git a/pkgs/tools/X11/wpgtk/default.nix b/pkgs/tools/X11/wpgtk/default.nix
index 84d1f379e8aa5..f2864ca2eb5ab 100644
--- a/pkgs/tools/X11/wpgtk/default.nix
+++ b/pkgs/tools/X11/wpgtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, libxslt,
+{ lib, stdenv, python3Packages, fetchFromGitHub, libxslt,
   gobject-introspection, gtk3, wrapGAppsHook, gnome3 }:
 
 python3Packages.buildPythonApplication rec {
@@ -34,7 +34,7 @@ python3Packages.buildPythonApplication rec {
   # No test exist
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Template based wallpaper/colorscheme generator and manager";
     longDescription = ''
      In short, wpgtk is a colorscheme/wallpaper manager with a template system attached which lets you create templates from any textfile and will replace keywords on it on the fly, allowing for great styling and theming possibilities.
diff --git a/pkgs/tools/X11/x11spice/default.nix b/pkgs/tools/X11/x11spice/default.nix
index 33bc9110848ed..7f3bfbf75a438 100644
--- a/pkgs/tools/X11/x11spice/default.nix
+++ b/pkgs/tools/X11/x11spice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitLab, autoreconfHook, pkgconfig
 , xorg, gtk2, spice, spice-protocol
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = "-lpthread";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enable a running X11 desktop to be available via a Spice server";
     homepage = "https://gitlab.freedesktop.org/spice/x11spice";
     platforms = platforms.linux;
diff --git a/pkgs/tools/X11/x11vnc/default.nix b/pkgs/tools/X11/x11vnc/default.nix
index 5ed827b5a546c..7264311d2dd56 100644
--- a/pkgs/tools/X11/x11vnc/default.nix
+++ b/pkgs/tools/X11/x11vnc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch,
+{ lib, stdenv, fetchFromGitHub, fetchpatch,
   openssl, zlib, libjpeg, xorg, coreutils, libvncserver,
   autoreconfHook, pkgconfig }:
 
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     configureFlags="--mandir=$out/share/man"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A VNC server connected to a real X11 screen";
     homepage = "https://github.com/LibVNC/x11vnc/";
     platforms = platforms.linux;
diff --git a/pkgs/tools/X11/x2vnc/default.nix b/pkgs/tools/X11/x2vnc/default.nix
index 65d45e23396e3..10519128a9d81 100644
--- a/pkgs/tools/X11/x2vnc/default.nix
+++ b/pkgs/tools/X11/x2vnc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xorg }:
+{ lib, stdenv, fetchurl, xorg }:
 
 stdenv.mkDerivation {
   name = "x2vnc-1.7.2";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fredrik.hubbe.net/x2vnc.html";
     description = "A program to control a remote VNC server";
     platforms = platforms.unix;
diff --git a/pkgs/tools/X11/x2x/default.nix b/pkgs/tools/X11/x2x/default.nix
index deada6ae2d1cc..01169e68f6e8f 100644
--- a/pkgs/tools/X11/x2x/default.nix
+++ b/pkgs/tools/X11/x2x/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, imake, libX11, libXtst, libXext, gccmakedep }:
+{ lib, stdenv, fetchurl, imake, libX11, libXtst, libXext, gccmakedep }:
 
 stdenv.mkDerivation {
   name = "x2x-1.27";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     install -D x2x.1 $out/man/man1/x2x.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows the keyboard, mouse on one X display to be used to control another X display";
     homepage = "https://github.com/dottedmag/x2x";
     license = licenses.bsd3;
diff --git a/pkgs/tools/X11/xcalib/default.nix b/pkgs/tools/X11/xcalib/default.nix
index 4e400ee8a247d..78804d0279172 100644
--- a/pkgs/tools/X11/xcalib/default.nix
+++ b/pkgs/tools/X11/xcalib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11, libXxf86vm, libXext, libXrandr }:
+{ lib, stdenv, fetchFromGitHub, libX11, libXxf86vm, libXext, libXrandr }:
 
 stdenv.mkDerivation rec {
   name = "xcalib-0.10";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp xcalib $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "A tiny monitor calibration loader for X and MS-Windows";
     license = licenses.gpl2;
diff --git a/pkgs/tools/X11/xcape/default.nix b/pkgs/tools/X11/xcape/default.nix
index eefaad82b1a71..ab9e0c345429d 100644
--- a/pkgs/tools/X11/xcape/default.nix
+++ b/pkgs/tools/X11/xcape/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libX11, libXtst, xorgproto,
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libX11, libXtst, xorgproto,
 libXi }:
 
 stdenv.mkDerivation rec {
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   postInstall = "install -Dm444 --target-directory $out/share/doc README.md";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility to configure modifier keys to act as other keys";
     longDescription = ''
       xcape allows you to use a modifier key as another key when
diff --git a/pkgs/tools/X11/xcwd/default.nix b/pkgs/tools/X11/xcwd/default.nix
index c0e8cf5d35b37..fa4ec15b81606 100644
--- a/pkgs/tools/X11/xcwd/default.nix
+++ b/pkgs/tools/X11/xcwd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libX11 }:
+{ lib, stdenv, fetchFromGitHub, libX11 }:
 
 stdenv.mkDerivation {
   version = "2019-05-09";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     install -D xcwd "$out/bin/xcwd"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A simple tool which print the current working directory of the currently focused window
     '';
diff --git a/pkgs/tools/X11/xdg-user-dirs/default.nix b/pkgs/tools/X11/xdg-user-dirs/default.nix
index 9ad3db80805f0..6d0c46e52e926 100644
--- a/pkgs/tools/X11/xdg-user-dirs/default.nix
+++ b/pkgs/tools/X11/xdg-user-dirs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxslt, docbook_xsl, makeWrapper }:
+{ lib, stdenv, fetchurl, libxslt, docbook_xsl, makeWrapper }:
 
 stdenv.mkDerivation rec {
   name = "xdg-user-dirs-0.17";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
       --suffix XDG_CONFIG_DIRS : "$out/etc/xdg"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://freedesktop.org/wiki/Software/xdg-user-dirs";
     description = "A tool to help manage well known user directories like the desktop folder and the music folder";
     license = licenses.gpl2;
diff --git a/pkgs/tools/X11/xdg-utils/default.nix b/pkgs/tools/X11/xdg-utils/default.nix
index 85d87d9e36d60..5f0e0ef19d6c7 100644
--- a/pkgs/tools/X11/xdg-utils/default.nix
+++ b/pkgs/tools/X11/xdg-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub
+{ lib, stdenv, fetchurl, fetchFromGitHub
 , file, libxslt, docbook_xml_dtd_412, docbook_xsl, xmlto
 , w3m, gnugrep, gnused, coreutils, xset, perlPackages
 , mimiSupport ? false, gawk ? null }:
@@ -59,7 +59,7 @@ stdenv.mkDerivation rec {
     sed 's|\bwhich\b|type -P|g' -i "$out"/bin/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.freedesktop.org/wiki/Software/xdg-utils/";
     description = "A set of command line tools that assist applications with a variety of desktop integration tasks";
     license = if mimiSupport then licenses.gpl2 else licenses.free;
diff --git a/pkgs/tools/X11/xgeometry-select/default.nix b/pkgs/tools/X11/xgeometry-select/default.nix
index ed3b460dcb615..b954205990b92 100644
--- a/pkgs/tools/X11/xgeometry-select/default.nix
+++ b/pkgs/tools/X11/xgeometry-select/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11 }:
+{ lib, stdenv, fetchurl, libX11 }:
 
 stdenv.mkDerivation rec {
   name     = "${baseName}-${version}";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     mv -v ${baseName} $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Select a region with mouse and prints geometry information (x/y/w/h)";
     homepage    = "https://bbs.archlinux.org/viewtopic.php?pid=660837";
     maintainers = with maintainers; [ obadz ];
diff --git a/pkgs/tools/X11/xkb-switch-i3/default.nix b/pkgs/tools/X11/xkb-switch-i3/default.nix
index 9485cb62b2bf9..fcb71b5d6d1f9 100644
--- a/pkgs/tools/X11/xkb-switch-i3/default.nix
+++ b/pkgs/tools/X11/xkb-switch-i3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , cmake
 , fetchFromGitHub
 , i3
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkg-config ];
   buildInputs = [ i3 jsoncpp libsigcxx libX11 libxkbfile ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switch your X keyboard layouts from the command line(i3 edition)";
     homepage = "https://github.com/Zebradil/xkb-switch-i3";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/X11/xkb-switch/default.nix b/pkgs/tools/X11/xkb-switch/default.nix
index 3b69ec8805498..65426a049feae 100644
--- a/pkgs/tools/X11/xkb-switch/default.nix
+++ b/pkgs/tools/X11/xkb-switch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libX11, libxkbfile }:
+{ lib, stdenv, fetchFromGitHub, cmake, libX11, libxkbfile }:
 
 stdenv.mkDerivation rec {
   pname = "xkb-switch";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ libX11 libxkbfile ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Switch your X keyboard layouts from the command line";
     homepage = "https://github.com/ierton/xkb-switch";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/X11/xkbset/default.nix b/pkgs/tools/X11/xkbset/default.nix
index e6f6622f85acd..132b7a1112205 100644
--- a/pkgs/tools/X11/xkbset/default.nix
+++ b/pkgs/tools/X11/xkbset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, libX11 }:
+{ lib, stdenv, fetchurl, perl, libX11 }:
 
 stdenv.mkDerivation rec {
   name = "xkbset-0.5";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     rm -f $out/bin/xkbset-gui
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://faculty.missouri.edu/~stephen/software/#xkbset";
     description = "Program to help manage many of XKB features of X window";
     maintainers = with maintainers; [ drets ];
diff --git a/pkgs/tools/X11/xlayoutdisplay/default.nix b/pkgs/tools/X11/xlayoutdisplay/default.nix
index 9ca3f24b618a1..16565296e1e66 100644
--- a/pkgs/tools/X11/xlayoutdisplay/default.nix
+++ b/pkgs/tools/X11/xlayoutdisplay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xorg, boost, cmake, gtest }:
+{ lib, stdenv, fetchFromGitHub, xorg, boost, cmake, gtest }:
 
 stdenv.mkDerivation rec {
   pname = "xlayoutdisplay";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     substituteInPlace CMakeLists.txt --replace "set(Boost_USE_STATIC_LIBS ON)" ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Detects and arranges linux display outputs, using XRandR for detection and xrandr for arrangement";
     homepage = "https://github.com/alex-courtis/xlayoutdisplay";
     maintainers = with maintainers; [ dtzWill ];
diff --git a/pkgs/tools/X11/xmagnify/default.nix b/pkgs/tools/X11/xmagnify/default.nix
index 710c9b83dbd03..797d624323bf0 100644
--- a/pkgs/tools/X11/xmagnify/default.nix
+++ b/pkgs/tools/X11/xmagnify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, libX11, xorgproto }:
+{ lib, stdenv, fetchFromGitLab, libX11, xorgproto }:
 
 stdenv.mkDerivation {
   name = "xmagnify-0.1.0";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ libX11 xorgproto ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiny screen magnifier for X11";
     homepage = "https://gitlab.com/amiloradovsky/magnify";
     license = licenses.mit;  # or GPL2+, optionally
diff --git a/pkgs/tools/X11/xmousepasteblock/default.nix b/pkgs/tools/X11/xmousepasteblock/default.nix
index 094b26d1f55cf..7402f19c2c8a3 100644
--- a/pkgs/tools/X11/xmousepasteblock/default.nix
+++ b/pkgs/tools/X11/xmousepasteblock/default.nix
@@ -1,4 +1,4 @@
-{ xorg, stdenv, libev, fetchFromGitHub, pkgconfig }:
+{ xorg, lib, stdenv, libev, fetchFromGitHub, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "xmousepasteblock";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   makeFlags = "PREFIX=$(out)";
   buildInputs = with xorg; [ libX11 libXext libXi libev ];
   nativeBuildInputs = [ pkgconfig ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Middle mouse button primary X selection/clipboard paste disabler";
     homepage = "https://github.com/milaq/XMousePasteBlock";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/tools/X11/xob/default.nix b/pkgs/tools/X11/xob/default.nix
index cf74fa3d867b4..2c1ae4bdf61c2 100644
--- a/pkgs/tools/X11/xob/default.nix
+++ b/pkgs/tools/X11/xob/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, xorg, libconfig }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, xorg, libconfig }:
 
 stdenv.mkDerivation rec {
   pname = "xob";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight overlay bar for the X Window System";
     longDescription = ''
       A lightweight configurable overlay volume/backlight/progress/anything bar
diff --git a/pkgs/tools/X11/xosview2/default.nix b/pkgs/tools/X11/xosview2/default.nix
index 5dfe74fd37345..fbee1e0ef6472 100644
--- a/pkgs/tools/X11/xosview2/default.nix
+++ b/pkgs/tools/X11/xosview2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11 }:
+{ lib, stdenv, fetchurl, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "xosview2";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libX11 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight program that gathers information from your operating system and displays it in graphical form";
     longDescription = ''
       xosview is a lightweight program that gathers information from your
diff --git a/pkgs/tools/X11/xpra/libfakeXinerama.nix b/pkgs/tools/X11/xpra/libfakeXinerama.nix
index e43043d78f2e6..bad43c39eef4f 100644
--- a/pkgs/tools/X11/xpra/libfakeXinerama.nix
+++ b/pkgs/tools/X11/xpra/libfakeXinerama.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXinerama }:
+{ lib, stdenv, fetchurl, libX11, libXinerama }:
 
 stdenv.mkDerivation  rec {
   pname = "libfakeXinerama";
@@ -23,7 +23,7 @@ stdenv.mkDerivation  rec {
     ln -s libXinerama.so.1 $out/lib/libXinerama.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://xpra.org/";
     description = "fakeXinerama for Xpra";
     platforms = platforms.linux;
diff --git a/pkgs/tools/X11/xrectsel/default.nix b/pkgs/tools/X11/xrectsel/default.nix
index e2f9fdf4a4356..0189e52ede9f9 100644
--- a/pkgs/tools/X11/xrectsel/default.nix
+++ b/pkgs/tools/X11/xrectsel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, libX11 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "xrectsel";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     make install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Print the geometry of a rectangular screen region";
     homepage = "https://github.com/lolilolicon/xrectsel";
     license = licenses.gpl3;
diff --git a/pkgs/tools/X11/xsettingsd/default.nix b/pkgs/tools/X11/xsettingsd/default.nix
index 10abd957e397a..55262125fadb6 100644
--- a/pkgs/tools/X11/xsettingsd/default.nix
+++ b/pkgs/tools/X11/xsettingsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, scons, pkgconfig, libX11 }:
+{ lib, stdenv, fetchFromGitHub, scons, pkgconfig, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "xsettingsd";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     install -D -t "$out"/usr/share/man/man1 xsettingsd.1 dump_xsettings.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides settings to X11 applications via the XSETTINGS specification";
     homepage = "https://github.com/derat/xsettingsd";
     license = licenses.bsd3;
diff --git a/pkgs/tools/X11/xtrace/default.nix b/pkgs/tools/X11/xtrace/default.nix
index aae31d649f44f..dfd834e67b808 100644
--- a/pkgs/tools/X11/xtrace/default.nix
+++ b/pkgs/tools/X11/xtrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoreconfHook, fetchFromGitLab, libX11, xauth, makeWrapper }:
+{ lib, stdenv, autoreconfHook, fetchFromGitLab, libX11, xauth, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "xtrace";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
         --prefix PATH ':' "${xauth}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://salsa.debian.org/debian/xtrace";
     description = "Tool to trace X11 protocol connections";
     license = licenses.gpl2;
diff --git a/pkgs/tools/X11/xtruss/default.nix b/pkgs/tools/X11/xtruss/default.nix
index 7d490571f4820..1af1ec925e530 100644
--- a/pkgs/tools/X11/xtruss/default.nix
+++ b/pkgs/tools/X11/xtruss/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "xtruss";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1mm8k92zc318jk71wlf2r4rb723nd9lalhjl0pf48raiajb5ifgd";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "easy-to-use X protocol tracing program";
     homepage = "https://www.chiark.greenend.org.uk/~sgtatham/xtruss";
     license = licenses.mit;
diff --git a/pkgs/tools/X11/xvkbd/default.nix b/pkgs/tools/X11/xvkbd/default.nix
index 6c61133077e4e..05936d1d1f3da 100644
--- a/pkgs/tools/X11/xvkbd/default.nix
+++ b/pkgs/tools/X11/xvkbd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, imake, libXt, libXaw, libXtst
+{ lib, stdenv, fetchurl, imake, libXt, libXaw, libXtst
 , libXi, libXpm, xorgproto, gccmakedep, Xaw3d }:
 
 stdenv.mkDerivation {
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     "MANPATH=$(out)/man"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Virtual keyboard for X window system";
     longDescription = ''
       xvkbd is a virtual (graphical) keyboard program for X Window System which provides
diff --git a/pkgs/tools/X11/xwallpaper/default.nix b/pkgs/tools/X11/xwallpaper/default.nix
index aab4d1180e0e5..55c5f86361578 100644
--- a/pkgs/tools/X11/xwallpaper/default.nix
+++ b/pkgs/tools/X11/xwallpaper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , autoreconfHook
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkg-config autoreconfHook ];
   buildInputs = [ pixman xcbutilimage xcbutil libseccomp libjpeg libpng libXpm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/stoeckmann/xwallpaper";
     description = "Utility for setting wallpapers in X";
     license = licenses.isc;
diff --git a/pkgs/tools/X11/xwinwrap/default.nix b/pkgs/tools/X11/xwinwrap/default.nix
index 89b2fdd3dcf17..00ee7413189a3 100644
--- a/pkgs/tools/X11/xwinwrap/default.nix
+++ b/pkgs/tools/X11/xwinwrap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchbzr, xlibsWrapper }:
+{ lib, stdenv, fetchbzr, xlibsWrapper }:
 
 let
   version = "4";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
     mv */xwinwrap $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility that allows you to use an animated X window as the wallpaper";
     longDescription = ''
       XWinWrap is a small utility written a loooong time ago that allowed you to
diff --git a/pkgs/tools/admin/acme.sh/default.nix b/pkgs/tools/admin/acme.sh/default.nix
index 8fb14ed2ead73..9b4b09c248483 100644
--- a/pkgs/tools/admin/acme.sh/default.nix
+++ b/pkgs/tools/admin/acme.sh/default.nix
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
       }"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pure Unix shell script implementing ACME client protocol";
     homepage = "https://acme.sh/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/admin/adtool/default.nix b/pkgs/tools/admin/adtool/default.nix
index f239b18aec9fa..d7f6ffadaca92 100644
--- a/pkgs/tools/admin/adtool/default.nix
+++ b/pkgs/tools/admin/adtool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openldap }:
+{ lib, stdenv, fetchurl, openldap }:
 
 stdenv.mkDerivation rec {
   pname = "adtool";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
   # It requires an LDAP server for tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Active Directory administration utility for Unix";
     homepage = "https://gp2x.org/adtool";
     license = licenses.gpl2;
diff --git a/pkgs/tools/admin/aws-nuke/default.nix b/pkgs/tools/admin/aws-nuke/default.nix
index ee29c7402e790..32c006d7a5ff7 100644
--- a/pkgs/tools/admin/aws-nuke/default.nix
+++ b/pkgs/tools/admin/aws-nuke/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 }:
@@ -27,7 +27,7 @@ buildGoModule rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Nuke a whole AWS account and delete all its resources";
     homepage = "https://github.com/rebuy-de/aws-nuke";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/aws-rotate-key/default.nix b/pkgs/tools/admin/aws-rotate-key/default.nix
index 9c2f747e15583..4b26e3a743447 100644
--- a/pkgs/tools/admin/aws-rotate-key/default.nix
+++ b/pkgs/tools/admin/aws-rotate-key/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "aws-rotate-key";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easily rotate your AWS key";
     homepage = "https://github.com/Fullscreen/aws-rotate-key";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/awslogs/default.nix b/pkgs/tools/admin/awslogs/default.nix
index 4a33d74207655..f71422f77a259 100644
--- a/pkgs/tools/admin/awslogs/default.nix
+++ b/pkgs/tools/admin/awslogs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "awslogs";
@@ -17,7 +17,7 @@ python3Packages.buildPythonApplication rec {
     boto3 termcolor dateutil docutils setuptools
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jorgebastida/awslogs";
     description = "AWS CloudWatch logs for Humans";
     maintainers = with maintainers; [ dbrock ];
diff --git a/pkgs/tools/admin/bash-my-aws/default.nix b/pkgs/tools/admin/bash-my-aws/default.nix
index b99f031f41654..5214cfeee2a6e 100644
--- a/pkgs/tools/admin/bash-my-aws/default.nix
+++ b/pkgs/tools/admin/bash-my-aws/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , awscli
 , jq
 , fetchgit
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bash-my-aws.org";
     description = "CLI commands for AWS";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/berglas/default.nix b/pkgs/tools/admin/berglas/default.nix
index 050ad9db75db0..ca588db01a595 100644
--- a/pkgs/tools/admin/berglas/default.nix
+++ b/pkgs/tools/admin/berglas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "berglas";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for managing secrets on Google Cloud";
     homepage = "https://github.com/GoogleCloudPlatform/berglas";
     license = licenses.asl20;
diff --git a/pkgs/tools/admin/bubblewrap/default.nix b/pkgs/tools/admin/bubblewrap/default.nix
index b98cadd57d116..6441b0782d507 100644
--- a/pkgs/tools/admin/bubblewrap/default.nix
+++ b/pkgs/tools/admin/bubblewrap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libxslt, docbook_xsl, libcap }:
+{ lib, stdenv, fetchurl, libxslt, docbook_xsl, libcap }:
 
 stdenv.mkDerivation rec {
   pname = "bubblewrap";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ libxslt docbook_xsl ];
   buildInputs = [ libcap ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unprivileged sandboxing tool";
     homepage = "https://github.com/containers/bubblewrap";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/admin/certigo/default.nix b/pkgs/tools/admin/certigo/default.nix
index e363df04556e9..ff66e926d4b5b 100644
--- a/pkgs/tools/admin/certigo/default.nix
+++ b/pkgs/tools/admin/certigo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "certigo";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility to examine and validate certificates in a variety of formats";
     homepage = "https://github.com/square/certigo";
     license = licenses.asl20;
diff --git a/pkgs/tools/admin/chkcrontab/default.nix b/pkgs/tools/admin/chkcrontab/default.nix
index 73076b65c5871..6404eb92a26eb 100644
--- a/pkgs/tools/admin/chkcrontab/default.nix
+++ b/pkgs/tools/admin/chkcrontab/default.nix
@@ -1,4 +1,4 @@
-{ python, stdenv }:
+{ python, lib, stdenv }:
 
 with python.pkgs;
 
@@ -11,7 +11,7 @@ buildPythonApplication rec {
     sha256 = "0gmxavjkjkvjysgf9cf5fcpk589gb75n1mn20iki82wifi1pk1jn";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to detect crontab errors";
     license = licenses.asl20;
     maintainers = with maintainers; [ SuperSandro2000 ];
diff --git a/pkgs/tools/admin/credhub-cli/default.nix b/pkgs/tools/admin/credhub-cli/default.nix
index f3cc5141618b9..2a1ceb531a50a 100644
--- a/pkgs/tools/admin/credhub-cli/default.nix
+++ b/pkgs/tools/admin/credhub-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "credhub-cli";
@@ -35,7 +35,7 @@ buildGoModule rec {
     export HOME=$TMPDIR
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Provides a command line interface to interact with CredHub servers";
     homepage = "https://github.com/cloudfoundry-incubator/credhub-cli";
     maintainers = with maintainers; [ ris ];
diff --git a/pkgs/tools/admin/dehydrated/default.nix b/pkgs/tools/admin/dehydrated/default.nix
index e6b909a0a5bdc..5ec710dde434f 100644
--- a/pkgs/tools/admin/dehydrated/default.nix
+++ b/pkgs/tools/admin/dehydrated/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, coreutils, curl, diffutils, gawk, gnugrep, gnused, openssl, makeWrapper, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, coreutils, curl, diffutils, gawk, gnugrep, gnused, openssl, makeWrapper, fetchFromGitHub, installShellFiles }:
 stdenv.mkDerivation rec {
   pname = "dehydrated";
   version = "0.7.0";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     wrapProgram "$out/bin/dehydrated" --prefix PATH : "${stdenv.lib.makeBinPath [ openssl coreutils gnused gnugrep diffutils curl gawk ]}"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Letsencrypt/acme client implemented as a shell-script";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/docker-credential-gcr/default.nix b/pkgs/tools/admin/docker-credential-gcr/default.nix
index d45a57c32211a..2ca0f2c4d0841 100644
--- a/pkgs/tools/admin/docker-credential-gcr/default.nix
+++ b/pkgs/tools/admin/docker-credential-gcr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "docker-credential-gcr";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "0m7jx669yf27z2g9gw9vwncpwldrcb3ldlf1xhvbwbijnc2jk866";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Docker credential helper for GCR (https://gcr.io) users";
     longDescription = ''
       docker-credential-gcr is Google Container Registry's Docker credential
diff --git a/pkgs/tools/admin/docker-credential-helpers/default.nix b/pkgs/tools/admin/docker-credential-helpers/default.nix
index 38762b6fd29cd..ef8df0d47265b 100644
--- a/pkgs/tools/admin/docker-credential-helpers/default.nix
+++ b/pkgs/tools/admin/docker-credential-helpers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, pkg-config, libsecret }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, pkg-config, libsecret }:
 
 buildGoPackage rec {
   pname = "docker-credential-helpers";
@@ -39,7 +39,7 @@ buildGoPackage rec {
       install -Dm755 -t $out/bin bin/docker-credential-secretservice
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Suite of programs to use native stores to keep Docker credentials safe";
     homepage = "https://github.com/docker/docker-credential-helpers";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/fastlane/default.nix b/pkgs/tools/admin/fastlane/default.nix
index 1093ab9df0287..245c1dfef8cb6 100644
--- a/pkgs/tools/admin/fastlane/default.nix
+++ b/pkgs/tools/admin/fastlane/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bundlerEnv, ruby, bundlerUpdateScript, makeWrapper }:
+{ lib, stdenv, bundlerEnv, ruby, bundlerUpdateScript, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "fastlane";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   passthru.updateScript = bundlerUpdateScript "fastlane";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description     = "A tool to automate building and releasing iOS and Android apps";
     longDescription = "fastlane is a tool for iOS and Android developers to automate tedious tasks like generating screenshots, dealing with provisioning profiles, and releasing your application.";
     homepage        = "https://github.com/fastlane/fastlane";
diff --git a/pkgs/tools/admin/google-cloud-sdk/default.nix b/pkgs/tools/admin/google-cloud-sdk/default.nix
index b2148fafe282e..6d86d52ae1e5a 100644
--- a/pkgs/tools/admin/google-cloud-sdk/default.nix
+++ b/pkgs/tools/admin/google-cloud-sdk/default.nix
@@ -93,7 +93,7 @@ in stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for the google cloud platform";
     longDescription = "The Google Cloud SDK. This package has the programs: gcloud, gsutil, and bq";
     # This package contains vendored dependencies. All have free licenses.
diff --git a/pkgs/tools/admin/gtk-vnc/default.nix b/pkgs/tools/admin/gtk-vnc/default.nix
index afaa237d342c7..152025d41c900 100644
--- a/pkgs/tools/admin/gtk-vnc/default.nix
+++ b/pkgs/tools/admin/gtk-vnc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , meson
@@ -68,7 +68,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK VNC widget";
     homepage = "https://wiki.gnome.org/Projects/gtk-vnc";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/admin/iamy/default.nix b/pkgs/tools/admin/iamy/default.nix
index 1a668777e2e61..e7481e16948f7 100644
--- a/pkgs/tools/admin/iamy/default.nix
+++ b/pkgs/tools/admin/iamy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "iamy";
@@ -19,7 +19,7 @@ buildGoModule rec {
     -X main.Version=v${version} -s -w
   ''];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cli tool for importing and exporting AWS IAM configuration to YAML files";
     homepage = "https://github.com/99designs/iamy";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/lxd/default.nix b/pkgs/tools/admin/lxd/default.nix
index 5462393517b82..5c97d110f9ae4 100644
--- a/pkgs/tools/admin/lxd/default.nix
+++ b/pkgs/tools/admin/lxd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, hwdata, pkgconfig, lxc, buildGoPackage, fetchurl
+{ lib, stdenv, hwdata, pkgconfig, lxc, buildGoPackage, fetchurl
 , makeWrapper, acl, rsync, gnutar, xz, btrfs-progs, gzip, dnsmasq
 , squashfsTools, iproute, iptables, ebtables, iptables-nftables-compat, libcap
 , libco-canonical, dqlite, raft-canonical, sqlite-replication, udev
@@ -62,7 +62,7 @@ buildGoPackage rec {
   buildInputs = [ lxc acl libcap libco-canonical.dev dqlite.dev
                   raft-canonical.dev sqlite-replication udev.dev ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon based on liblxc offering a REST API to manage containers";
     homepage = "https://linuxcontainers.org/lxd/";
     license = licenses.asl20;
diff --git a/pkgs/tools/admin/nomachine-client/default.nix b/pkgs/tools/admin/nomachine-client/default.nix
index 50083535a2da6..6727a89787888 100644
--- a/pkgs/tools/admin/nomachine-client/default.nix
+++ b/pkgs/tools/admin/nomachine-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, file, fetchurl, makeWrapper,
+{ lib, stdenv, file, fetchurl, makeWrapper,
   autoPatchelfHook, jsoncpp, libpulseaudio }:
 let
   versionMajor = "6.12";
@@ -81,7 +81,7 @@ in
     dontBuild = true;
     dontStrip = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "NoMachine remote desktop client (nxplayer)";
       homepage = "https://www.nomachine.com/";
       license = {
diff --git a/pkgs/tools/admin/procs/default.nix b/pkgs/tools/admin/procs/default.nix
index 2c11b6f4523b6..f331c137107ce 100644
--- a/pkgs/tools/admin/procs/default.nix
+++ b/pkgs/tools/admin/procs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "procs";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modern replacement for ps written in Rust";
     homepage = "https://github.com/dalance/procs";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/s3bro/default.nix b/pkgs/tools/admin/s3bro/default.nix
index 154b4aae96656..bf807d1499756 100644
--- a/pkgs/tools/admin/s3bro/default.nix
+++ b/pkgs/tools/admin/s3bro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonPackage rec {
   pname = "s3bro";
@@ -14,7 +14,7 @@ python3Packages.buildPythonPackage rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A handy s3 cli tool";
     homepage = "https://github.com/rsavordelli/s3bro";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/scaleway-cli/default.nix b/pkgs/tools/admin/scaleway-cli/default.nix
index a174937e5a127..0aeccb755a1bb 100644
--- a/pkgs/tools/admin/scaleway-cli/default.nix
+++ b/pkgs/tools/admin/scaleway-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage }:
 
 buildGoPackage rec {
   pname = "scaleway-cli";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "14likzp3hl04nq9nmpmh9m5zqjyspy5cyk20dkh03c1nhkd4vcnx";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interact with Scaleway API from the command line";
     homepage = "https://github.com/scaleway/scaleway-cli";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/sewer/default.nix b/pkgs/tools/admin/sewer/default.nix
index 471a8788a95ed..42288bafe015c 100644
--- a/pkgs/tools/admin/sewer/default.nix
+++ b/pkgs/tools/admin/sewer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "sewer";
@@ -11,7 +11,7 @@ python3Packages.buildPythonApplication rec {
 
   propagatedBuildInputs = with python3Packages; [ pyopenssl requests tldextract ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/komuw/sewer";
     description = "ACME client";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/simp_le/default.nix b/pkgs/tools/admin/simp_le/default.nix
index 6ff547ab5322e..fc064641943ad 100644
--- a/pkgs/tools/admin/simp_le/default.nix
+++ b/pkgs/tools/admin/simp_le/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, bash }:
+{ lib, stdenv, python3Packages, bash }:
 
 python3Packages.buildPythonApplication rec {
   pname = "simp_le-client";
@@ -22,7 +22,7 @@ python3Packages.buildPythonApplication rec {
 
   propagatedBuildInputs = with python3Packages; [ acme setuptools_scm josepy idna ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/zenhack/simp_le";
     description = "Simple Let's Encrypt client";
     license = licenses.gpl3;
diff --git a/pkgs/tools/admin/ssh-import-id/default.nix b/pkgs/tools/admin/ssh-import-id/default.nix
index 77d30e56d5fc3..6c8520648ec67 100644
--- a/pkgs/tools/admin/ssh-import-id/default.nix
+++ b/pkgs/tools/admin/ssh-import-id/default.nix
@@ -1,5 +1,5 @@
 { buildPythonPackage
-, stdenv
+, lib, stdenv
 , fetchgit
 , requests
 , makeWrapper
@@ -27,7 +27,7 @@ buildPythonPackage rec {
   # handlers require main bin, main bin requires handlers
   makeWrapperArgs = [ "--prefix" ":" "$out/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Retrieves an SSH public key and installs it locally";
     license = licenses.gpl3;
     maintainers = with maintainers; [ mkg20001 ];
diff --git a/pkgs/tools/admin/ssl-cert-check/default.nix b/pkgs/tools/admin/ssl-cert-check/default.nix
index b94d77bdf7061..f29ced9ebfd8b 100644
--- a/pkgs/tools/admin/ssl-cert-check/default.nix
+++ b/pkgs/tools/admin/ssl-cert-check/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , makeWrapper
 , openssl
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
       --set PATH "${stdenv.lib.makeBinPath buildInputs}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a Bourne shell script that can be used to report on expiring SSL certificates";
     homepage = "https://github.com/Matty9191/ssl-cert-check";
     license = licenses.gpl2;
diff --git a/pkgs/tools/admin/ssmsh/default.nix b/pkgs/tools/admin/ssmsh/default.nix
index 1d4275c65cbdb..6b0d038090158 100644
--- a/pkgs/tools/admin/ssmsh/default.nix
+++ b/pkgs/tools/admin/ssmsh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "ssmsh";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-w -s -X main.Version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bwhaley/ssmsh";
     description = "An interactive shell for AWS Parameter Store";
     license = licenses.mit;
diff --git a/pkgs/tools/admin/stripe-cli/default.nix b/pkgs/tools/admin/stripe-cli/default.nix
index f675e7518f580..c410bd81e89a3 100644
--- a/pkgs/tools/admin/stripe-cli/default.nix
+++ b/pkgs/tools/admin/stripe-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "stripe-cli";
@@ -17,7 +17,7 @@ buildGoModule rec {
     "cmd/stripe"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://stripe.com/docs/stripe-cli";
     description = "A command-line tool for Stripe";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/tools/admin/virtscreen/default.nix b/pkgs/tools/admin/virtscreen/default.nix
index 3c5fb64f7224e..ebfd6c21772ff 100644
--- a/pkgs/tools/admin/virtscreen/default.nix
+++ b/pkgs/tools/admin/virtscreen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, x11vnc, xrandr, libGL }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, x11vnc, xrandr, libGL }:
 
 python3Packages.buildPythonApplication rec {
   pname = "virtscreen";
@@ -30,7 +30,7 @@ python3Packages.buildPythonApplication rec {
       --replace "'GL'" "'${libGL}/lib/libGL${ext}'" \
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Make your iPad/tablet/computer as a secondary monitor on Linux";
     homepage = "https://github.com/kbumsik/VirtScreen";
     license = licenses.gpl3;
diff --git a/pkgs/tools/archivers/arc_unpacker/default.nix b/pkgs/tools/archivers/arc_unpacker/default.nix
index 76eb9a7fccbc7..dcd5243d7135e 100644
--- a/pkgs/tools/archivers/arc_unpacker/default.nix
+++ b/pkgs/tools/archivers/arc_unpacker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, makeWrapper, boost, libpng, libjpeg, zlib
+{ lib, stdenv, fetchFromGitHub, cmake, makeWrapper, boost, libpng, libjpeg, zlib
 , openssl, libwebp, catch }:
 
 stdenv.mkDerivation rec {
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to extract files from visual novel archives";
     homepage = "https://github.com/vn-tools/arc_unpacker";
     license = licenses.gpl3;
diff --git a/pkgs/tools/archivers/bomutils/default.nix b/pkgs/tools/archivers/bomutils/default.nix
index fc68184be3193..9ace81a5ec2c7 100644
--- a/pkgs/tools/archivers/bomutils/default.nix
+++ b/pkgs/tools/archivers/bomutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }:
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hogliux/bomutils";
     description = "Open source tools to create bill-of-materials files used in macOS installers";
     platforms = platforms.all;
diff --git a/pkgs/tools/archivers/cabextract/default.nix b/pkgs/tools/archivers/cabextract/default.nix
index 14c4ede50041e..3ed07544bb2be 100644
--- a/pkgs/tools/archivers/cabextract/default.nix
+++ b/pkgs/tools/archivers/cabextract/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "cabextract-1.9.1";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "19qwhl2r8ip95q4vxzxg2kp4p125hjmc9762sns1dwwf7ikm7hmg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.cabextract.org.uk/";
     description = "Free Software for extracting Microsoft cabinet files";
     platforms = platforms.all;
diff --git a/pkgs/tools/archivers/cpio/default.nix b/pkgs/tools/archivers/cpio/default.nix
index a196ddcaa3062..5b88e10b1c37a 100644
--- a/pkgs/tools/archivers/cpio/default.nix
+++ b/pkgs/tools/archivers/cpio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   version = "2.13";
@@ -17,7 +17,7 @@ in stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/cpio/";
     description = "A program to create or extract from cpio archives";
     license = licenses.gpl3;
diff --git a/pkgs/tools/archivers/cromfs/default.nix b/pkgs/tools/archivers/cromfs/default.nix
index e0eb11aa9a6f7..145a66a31315c 100644
--- a/pkgs/tools/archivers/cromfs/default.nix
+++ b/pkgs/tools/archivers/cromfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, fuse, perl }:
+{ lib, stdenv, fetchurl, pkgconfig, fuse, perl }:
 
 stdenv.mkDerivation rec {
   name = "cromfs-1.5.10.2";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ fuse perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE Compressed ROM filesystem with lzma";
     homepage = "https://bisqwit.iki.fi/source/cromfs.html";
     license = licenses.gpl3;
diff --git a/pkgs/tools/archivers/ctrtool/default.nix b/pkgs/tools/archivers/ctrtool/default.nix
index 4b8eb4dfab2e3..4743f7ded3e81 100644
--- a/pkgs/tools/archivers/ctrtool/default.nix
+++ b/pkgs/tools/archivers/ctrtool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "ctrtool";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp ctrtool${stdenv.hostPlatform.extensions.executable} $out/bin/
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     description = "A tool to extract data from a 3ds rom";
     platforms = platforms.linux;
diff --git a/pkgs/tools/archivers/fsarchiver/default.nix b/pkgs/tools/archivers/fsarchiver/default.nix
index 721accd93f030..5196ccf668f2b 100644
--- a/pkgs/tools/archivers/fsarchiver/default.nix
+++ b/pkgs/tools/archivers/fsarchiver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , zlib, bzip2, lzma, lzo, lz4, zstd, xz
 , libgcrypt, e2fsprogs, util-linux, libgpgerror }:
 
@@ -25,7 +25,7 @@ in stdenv.mkDerivation {
     libgcrypt e2fsprogs util-linux libgpgerror
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "File system archiver for linux";
     longDescription = ''
       FSArchiver is a system tool that allows you to save the contents of a
diff --git a/pkgs/tools/archivers/innoextract/default.nix b/pkgs/tools/archivers/innoextract/default.nix
index 4f6137a421146..d5d35a38251f4 100644
--- a/pkgs/tools/archivers/innoextract/default.nix
+++ b/pkgs/tools/archivers/innoextract/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, makeWrapper, python
+{ lib, stdenv, fetchurl, cmake, makeWrapper, python
 , boost, lzma
 , withGog ? false, unar ? null }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ unar ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to unpack installers created by Inno Setup";
     homepage = "https://constexpr.org/innoextract/";
     license = licenses.zlib;
diff --git a/pkgs/tools/archivers/maxcso/default.nix b/pkgs/tools/archivers/maxcso/default.nix
index 333b0dcabc3d5..ed81a1825257c 100644
--- a/pkgs/tools/archivers/maxcso/default.nix
+++ b/pkgs/tools/archivers/maxcso/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libuv, lz4, zlib }:
+{ lib, stdenv, fetchFromGitHub, libuv, lz4, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "maxcso";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/unknownbrackets/maxcso";
     description =
       "A fast ISO to CSO compression program for use with PSP and PS2 emulators, which uses multiple algorithms for best compression ratio";
diff --git a/pkgs/tools/archivers/pax/default.nix b/pkgs/tools/archivers/pax/default.nix
index aa457b976d0d2..d554ea4dade37 100644
--- a/pkgs/tools/archivers/pax/default.nix
+++ b/pkgs/tools/archivers/pax/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "pax";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -Dm444 mans/pax{,cpio,tar}.1 -t $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "POSIX standard archive tool from MirBSD";
     homepage = "https://www.mirbsd.org/pax.htm";
     license = licenses.bsd3;
diff --git a/pkgs/tools/archivers/rpmextract/default.nix b/pkgs/tools/archivers/rpmextract/default.nix
index 59ff67e3eefbc..d4bbbe77a2d8a 100644
--- a/pkgs/tools/archivers/rpmextract/default.nix
+++ b/pkgs/tools/archivers/rpmextract/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rpm, cpio, substituteAll }:
+{ lib, stdenv, rpm, cpio, substituteAll }:
 
 stdenv.mkDerivation {
   name = "rpmextract";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     inherit (stdenv) shell;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Script to extract RPM archives";
     platforms = platforms.all;
     license = licenses.gpl2;
diff --git a/pkgs/tools/archivers/sharutils/default.nix b/pkgs/tools/archivers/sharutils/default.nix
index aefe4f87eb4a5..c785211e682f9 100644
--- a/pkgs/tools/archivers/sharutils/default.nix
+++ b/pkgs/tools/archivers/sharutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gettext, coreutils }:
+{ lib, stdenv, fetchurl, gettext, coreutils }:
 
 stdenv.mkDerivation rec {
   name = "sharutils-4.15.2";
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for remote synchronization and `shell archives'";
     longDescription =
       '' GNU shar makes so-called shell archives out of many files, preparing
diff --git a/pkgs/tools/archivers/snzip/default.nix b/pkgs/tools/archivers/snzip/default.nix
index 031cac64b759a..1f4a0f12ff2f4 100644
--- a/pkgs/tools/archivers/snzip/default.nix
+++ b/pkgs/tools/archivers/snzip/default.nix
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   # run. That's why we generate it.
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A compression/decompression tool based on snappy";
     homepage = "https://github.com/kubo/snzip";
     maintainers = with maintainers; [ doronbehar ];
diff --git a/pkgs/tools/archivers/unar/default.nix b/pkgs/tools/archivers/unar/default.nix
index 6e75ee720e806..d0d0ef90e68dd 100644
--- a/pkgs/tools/archivers/unar/default.nix
+++ b/pkgs/tools/archivers/unar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, installShellFiles, gnustep, bzip2, zlib, icu, openssl, wavpack }:
+{ lib, stdenv, fetchFromGitHub, installShellFiles, gnustep, bzip2, zlib, icu, openssl, wavpack }:
 
 stdenv.mkDerivation rec {
   pname = "unar";
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://theunarchiver.com";
     description = "An archive unpacker program";
     longDescription = ''
diff --git a/pkgs/tools/archivers/undmg/default.nix b/pkgs/tools/archivers/undmg/default.nix
index 0eaabdb627da7..0bbf725d191b4 100644
--- a/pkgs/tools/archivers/undmg/default.nix
+++ b/pkgs/tools/archivers/undmg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib, bzip2, lzfse, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, zlib, bzip2, lzfse, pkg-config }:
 
 stdenv.mkDerivation rec {
   version = "1.1.0";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/matthewbauer/undmg";
     description = "Extract a DMG file";
     license = licenses.gpl3;
diff --git a/pkgs/tools/archivers/unp/default.nix b/pkgs/tools/archivers/unp/default.nix
index afe00972141cc..34f8cb1c40e6d 100644
--- a/pkgs/tools/archivers/unp/default.nix
+++ b/pkgs/tools/archivers/unp/default.nix
@@ -34,7 +34,7 @@ in stdenv.mkDerivation {
     --prefix PATH : ${lib.makeBinPath runtime_bins}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tool for unpacking archives easily";
     homepage = "https://packages.qa.debian.org/u/unp.html";
     license = with licenses; [ gpl2 ];
diff --git a/pkgs/tools/archivers/unrar/default.nix b/pkgs/tools/archivers/unrar/default.nix
index 9396267b3a108..b06242a98c042 100644
--- a/pkgs/tools/archivers/unrar/default.nix
+++ b/pkgs/tools/archivers/unrar/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "unrar";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
 
   setupHook = ./setup-hook.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for RAR archives";
     homepage = "https://www.rarlab.com/";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/tools/archivers/unshield/default.nix b/pkgs/tools/archivers/unshield/default.nix
index dbcb2b24f100b..2c58b546b63c2 100644
--- a/pkgs/tools/archivers/unshield/default.nix
+++ b/pkgs/tools/archivers/unshield/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, zlib, openssl }:
+{ lib, stdenv, fetchFromGitHub, cmake, zlib, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "unshield";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ zlib openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool and library to extract CAB files from InstallShield installers";
     homepage = "https://github.com/twogood/unshield";
     license = licenses.mit;
diff --git a/pkgs/tools/archivers/wimlib/default.nix b/pkgs/tools/archivers/wimlib/default.nix
index 51f75ee923d35..16e93470e892e 100644
--- a/pkgs/tools/archivers/wimlib/default.nix
+++ b/pkgs/tools/archivers/wimlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper
+{ lib, stdenv, fetchurl, makeWrapper
 , pkgconfig, openssl, fuse, libxml2
 , cabextract ? null
 , cdrkit ? null
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     patchShebangs tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wimlib.net";
     description = "A library and program to extract, create, and modify WIM files";
     platforms = platforms.unix;
diff --git a/pkgs/tools/archivers/zip/default.nix b/pkgs/tools/archivers/zip/default.nix
index 173f48121090c..74f1982a425e0 100644
--- a/pkgs/tools/archivers/zip/default.nix
+++ b/pkgs/tools/archivers/zip/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, enableNLS ? false, libnatspec ? null, libiconv }:
+{ lib, stdenv, fetchurl, enableNLS ? false, libnatspec ? null, libiconv }:
 
 assert enableNLS -> libnatspec != null;
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
   buildInputs = stdenv.lib.optional enableNLS libnatspec
     ++ stdenv.lib.optional stdenv.isCygwin libiconv;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compressor/archiver for creating and modifying zipfiles";
     homepage = "http://www.info-zip.org";
     license = licenses.bsdOriginal;
diff --git a/pkgs/tools/archivers/zpaq/default.nix b/pkgs/tools/archivers/zpaq/default.nix
index dbdcdf5cada8c..7c9f9ac7d6328 100644
--- a/pkgs/tools/archivers/zpaq/default.nix
+++ b/pkgs/tools/archivers/zpaq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl, unzip }:
+{ lib, stdenv, fetchFromGitHub, perl, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "zpaq";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Incremental journaling backup utility and archiver";
     homepage = "http://mattmahoney.net/dc/zpaq.html";
     license = licenses.gpl3Plus ;
diff --git a/pkgs/tools/archivers/zpaq/zpaqd.nix b/pkgs/tools/archivers/zpaq/zpaqd.nix
index 611654331c3b1..6abad5a17be4f 100644
--- a/pkgs/tools/archivers/zpaq/zpaqd.nix
+++ b/pkgs/tools/archivers/zpaq/zpaqd.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 let
   # Generated upstream information
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
     cp readme_zpaqd.txt "$out/share/doc/zpaq"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ZPAQ archive (de)compressor and algorithm development tool";
     license = licenses.gpl3Plus ;
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/tools/audio/abcm2ps/default.nix b/pkgs/tools/audio/abcm2ps/default.nix
index 139d684fb6714..5ecc1d1331c92 100644
--- a/pkgs/tools/audio/abcm2ps/default.nix
+++ b/pkgs/tools/audio/abcm2ps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, which, docutils, freetype, pango }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, which, docutils, freetype, pango }:
 
 stdenv.mkDerivation rec {
   pname = "abcm2ps";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ freetype pango ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://moinejf.free.fr/";
     license = licenses.gpl3;
     description = "A command line program which converts ABC to music sheet in PostScript or SVG format";
diff --git a/pkgs/tools/audio/abcmidi/default.nix b/pkgs/tools/audio/abcmidi/default.nix
index e33ff98587bf6..b3f45410f4291 100644
--- a/pkgs/tools/audio/abcmidi/default.nix
+++ b/pkgs/tools/audio/abcmidi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "abcMIDI";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   # There is also a file called "makefile" which seems to be preferred by the standard build phase
   makefile = "Makefile";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://abc.sourceforge.net/abcMIDI/";
     downloadPage = "https://ifdo.ca/~seymour/runabc/top.html";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/audio/accuraterip-checksum/default.nix b/pkgs/tools/audio/accuraterip-checksum/default.nix
index efd4402564706..161e9848bea6f 100644
--- a/pkgs/tools/audio/accuraterip-checksum/default.nix
+++ b/pkgs/tools/audio/accuraterip-checksum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libsndfile }:
+{ lib, stdenv, fetchFromGitHub, libsndfile }:
 
 stdenv.mkDerivation rec {
   pname = "accuraterip-checksum";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Program for computing the AccurateRip checksum of singletrack WAV files";
     homepage = "https://github.com/leo-bogert/accuraterip-checksum";
     license = licenses.gpl3;
diff --git a/pkgs/tools/audio/acoustid-fingerprinter/default.nix b/pkgs/tools/audio/acoustid-fingerprinter/default.nix
index 23ea1c44dc3f6..3c8f43772b55e 100644
--- a/pkgs/tools/audio/acoustid-fingerprinter/default.nix
+++ b/pkgs/tools/audio/acoustid-fingerprinter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, cmake, pkg-config, qt4, taglib, chromaprint, ffmpeg }:
+{ lib, stdenv, fetchurl, fetchpatch, cmake, pkg-config, qt4, taglib, chromaprint, ffmpeg }:
 
 stdenv.mkDerivation rec {
   pname = "acoustid-fingerprinter";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     ./ffmpeg.patch
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://acoustid.org/fingerprinter";
     description = "Audio fingerprinting tool using chromaprint";
     license = stdenv.lib.licenses.gpl2Plus;
diff --git a/pkgs/tools/audio/alsaequal/default.nix b/pkgs/tools/audio/alsaequal/default.nix
index 9498baca991b1..12d590c4c7628 100644
--- a/pkgs/tools/audio/alsaequal/default.nix
+++ b/pkgs/tools/audio/alsaequal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , alsaLib, caps
 }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/lib/alsa-lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Real-time adjustable equalizer plugin for ALSA";
     homepage = "https://thedigitalmachine.net/alsaequal.html";
     license = licenses.gpl2;
diff --git a/pkgs/tools/audio/audiowaveform/default.nix b/pkgs/tools/audio/audiowaveform/default.nix
index 9d674dcfe436b..e120f6fcbf0e3 100644
--- a/pkgs/tools/audio/audiowaveform/default.nix
+++ b/pkgs/tools/audio/audiowaveform/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, gtest, boost, gd, libsndfile, libmad, libid3tag }:
+{ lib, stdenv, fetchFromGitHub, cmake, gtest, boost, gd, libsndfile, libmad, libid3tag }:
 
 stdenv.mkDerivation rec {
   pname = "audiowaveform";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   # One test is failing, see PR #101947
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C++ program to generate waveform data and render waveform images from audio files";
     longDescription = ''
       audiowaveform is a C++ command-line application that generates waveform data from either MP3, WAV, FLAC, or Ogg Vorbis format audio files.
diff --git a/pkgs/tools/audio/beets/plugins/check.nix b/pkgs/tools/audio/beets/plugins/check.nix
index 241dcdad45213..545e6d7cf2c7b 100644
--- a/pkgs/tools/audio/beets/plugins/check.nix
+++ b/pkgs/tools/audio/beets/plugins/check.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, beets, pythonPackages, flac, liboggz, mp3val }:
+{ lib, stdenv, fetchFromGitHub, beets, pythonPackages, flac, liboggz, mp3val }:
 
 pythonPackages.buildPythonApplication rec {
   name = "beets-check";
@@ -26,7 +26,7 @@ pythonPackages.buildPythonApplication rec {
 
   checkPhase = "nosetests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Beets plugin to Verify and store checksums in your library";
     homepage = "https://github.com/geigerzaehler/beets-check";
     license = licenses.mit;
diff --git a/pkgs/tools/audio/bpm-tools/default.nix b/pkgs/tools/audio/bpm-tools/default.nix
index 6207cbeb9fe6c..afd5785f3cffb 100644
--- a/pkgs/tools/audio/bpm-tools/default.nix
+++ b/pkgs/tools/audio/bpm-tools/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   fetchurl,
   gnuplot,
   sox,
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/bpm-graph --prefix PATH : "${path}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.pogo.org.uk/~mark/bpm-tools/";
     description = "Automatically calculate BPM (tempo) of music files";
     license = licenses.gpl2;
diff --git a/pkgs/tools/audio/dir2opus/default.nix b/pkgs/tools/audio/dir2opus/default.nix
index 8720065470313..d23c334ad62fc 100644
--- a/pkgs/tools/audio/dir2opus/default.nix
+++ b/pkgs/tools/audio/dir2opus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python, mutagen, wrapPython, opusTools, mpg123 }:
+{ lib, stdenv, fetchurl, python, mutagen, wrapPython, opusTools, mpg123 }:
 
 let version = "0.12.2"; in
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   postFixup = "wrapPythonPrograms";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ehmry/dir2opus";
     maintainers = [ maintainers.ehmry ];
     license = licenses.gpl2;
diff --git a/pkgs/tools/audio/essentia-extractor/default.nix b/pkgs/tools/audio/essentia-extractor/default.nix
index 0d2bb17a75d4d..a02cca6a3d653 100644
--- a/pkgs/tools/audio/essentia-extractor/default.nix
+++ b/pkgs/tools/audio/essentia-extractor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 let
   arch_table = {
     "x86_64-linux" = "linux-x86_64";
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
     cp streaming_extractor_music $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://acousticbrainz.org/download";
     description = "AcousticBrainz audio feature extractor";
     license = licenses.agpl3Plus;
diff --git a/pkgs/tools/audio/ezstream/default.nix b/pkgs/tools/audio/ezstream/default.nix
index 499f9842852f2..0befbaceb0181 100644
--- a/pkgs/tools/audio/ezstream/default.nix
+++ b/pkgs/tools/audio/ezstream/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libiconv, libshout, taglib, libxml2, pkgconfig }:
+{ lib, stdenv, fetchurl, libiconv, libshout, taglib, libxml2, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "ezstream";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line source client for Icecast media streaming servers";
     longDescription = ''
       Ezstream is a command line source client for Icecast media
diff --git a/pkgs/tools/audio/glyr/default.nix b/pkgs/tools/audio/glyr/default.nix
index 41490381487e1..c50913eb22a9c 100644
--- a/pkgs/tools/audio/glyr/default.nix
+++ b/pkgs/tools/audio/glyr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake
+{ lib, stdenv, fetchFromGitHub, cmake
 , curl, glib, sqlite, pkgconfig }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkgconfig ];
   buildInputs = [ sqlite glib curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.lgpl3;
     description = "A music related metadata searchengine";
     homepage = "https://github.com/sahib/glyr";
diff --git a/pkgs/tools/audio/kaldi/default.nix b/pkgs/tools/audio/kaldi/default.nix
index fa291a05078e9..2d61a984a00d4 100644
--- a/pkgs/tools/audio/kaldi/default.nix
+++ b/pkgs/tools/audio/kaldi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , openblas
 , blas
 , lapack
@@ -78,7 +78,7 @@ stdenv.mkDerivation {
     cp -r ../egs $out/share/kaldi
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Speech Recognition Toolkit";
     homepage = "https://kaldi-asr.org";
     license = licenses.mit;
diff --git a/pkgs/tools/audio/liquidsoap/full.nix b/pkgs/tools/audio/liquidsoap/full.nix
index a228c23651db4..84750bb2358d2 100644
--- a/pkgs/tools/audio/liquidsoap/full.nix
+++ b/pkgs/tools/audio/liquidsoap/full.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, fetchurl, which, pkgconfig
+{ lib, stdenv, makeWrapper, fetchurl, which, pkgconfig
 , ocamlPackages
 , libao, portaudio, alsaLib, libpulseaudio, libjack2
 , libsamplerate, libmad, taglib, lame, libogg
@@ -64,7 +64,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "format" "fortify" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Swiss-army knife for multimedia streaming";
     homepage = "https://www.liquidsoap.info/";
     maintainers = with maintainers; [ ehmry ];
diff --git a/pkgs/tools/audio/midicsv/default.nix b/pkgs/tools/audio/midicsv/default.nix
index e5f3f6124b9b2..f02f6ed956d6e 100644
--- a/pkgs/tools/audio/midicsv/default.nix
+++ b/pkgs/tools/audio/midicsv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "midicsv-1.1";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
     substituteInPlace Makefile --replace /usr/local $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Losslessly translate MIDI to CSV and back";
     homepage = "http://www.fourmilab.ch/webtools/midicsv/";
     license = licenses.publicDomain;
diff --git a/pkgs/tools/audio/mididings/default.nix b/pkgs/tools/audio/mididings/default.nix
index addb95b9f1bdd..ccaa014123126 100644
--- a/pkgs/tools/audio/mididings/default.nix
+++ b/pkgs/tools/audio/mididings/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonPackages, fetchFromGitHub, pkg-config, glib, alsaLib, libjack2  }:
+{ lib, stdenv, pythonPackages, fetchFromGitHub, pkg-config, glib, alsaLib, libjack2  }:
 
 pythonPackages.buildPythonApplication {
   version = "2015-11-17";
@@ -28,7 +28,7 @@ pythonPackages.buildPythonApplication {
       --replace boost_python "boost_python${major pythonPackages.python.version}${minor pythonPackages.python.version}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A MIDI router and processor based on Python, supporting ALSA and JACK MIDI";
     homepage = "http://das.nasophon.de/mididings";
     license = licenses.gpl2;
diff --git a/pkgs/tools/audio/mp3cat/default.nix b/pkgs/tools/audio/mp3cat/default.nix
index e7a1d004a0192..dbcc458164de6 100644
--- a/pkgs/tools/audio/mp3cat/default.nix
+++ b/pkgs/tools/audio/mp3cat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "mp3cat";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "install_bin"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line program which concatenates MP3 files";
     longDescription = ''
       A command line program which concatenates MP3 files, mp3cat
diff --git a/pkgs/tools/audio/mpd-mpris/default.nix b/pkgs/tools/audio/mpd-mpris/default.nix
index c66a12dadd3ae..801058e0496bf 100644
--- a/pkgs/tools/audio/mpd-mpris/default.nix
+++ b/pkgs/tools/audio/mpd-mpris/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "mpd-mpris";
@@ -24,7 +24,7 @@ buildGoModule rec {
     cp mpd-mpris.service $out/lib/systemd/user
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of the MPRIS protocol for MPD";
     homepage = "https://github.com/natsukagami/mpd-mpris";
     license = licenses.mit;
diff --git a/pkgs/tools/audio/mpdas/default.nix b/pkgs/tools/audio/mpdas/default.nix
index 507e62b0dae97..d4be0550e1847 100644
--- a/pkgs/tools/audio/mpdas/default.nix
+++ b/pkgs/tools/audio/mpdas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, mpd_clientlib, curl }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, mpd_clientlib, curl }:
 
 stdenv.mkDerivation rec {
   pname = "mpdas";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "CONFIG=/etc" "DESTDIR=" "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Music Player Daemon AudioScrobbler";
     homepage = "https://50hz.ws/mpdas/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/audio/mpdcron/default.nix b/pkgs/tools/audio/mpdcron/default.nix
index c083c60a96253..13303ef58e19b 100644
--- a/pkgs/tools/audio/mpdcron/default.nix
+++ b/pkgs/tools/audio/mpdcron/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig, glib, libdaemon
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig, glib, libdaemon
 , mpd_clientlib, curl, sqlite, bundlerEnv, libnotify, pandoc }:
 
 let
@@ -17,7 +17,7 @@ in stdenv.mkDerivation {
     sha256 = "0vdksf6lcgmizqr5mqp0bbci259k0dj7gpmhx32md41jlmw5skaw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cron like daemon for mpd";
     homepage    = "http://alip.github.io/mpdcron/";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/audio/mpdris2/default.nix b/pkgs/tools/audio/mpdris2/default.nix
index 029dcd127f130..30b0d90f56232 100644
--- a/pkgs/tools/audio/mpdris2/default.nix
+++ b/pkgs/tools/audio/mpdris2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoreconfHook
 , fetchFromGitHub
 , glib
@@ -45,7 +45,7 @@ python3.pkgs.buildPythonApplication rec {
     pygobject3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MPRIS 2 support for mpd";
     homepage = "https://github.com/eonpatapon/mpDris2/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/audio/mpris-scrobbler/default.nix b/pkgs/tools/audio/mpris-scrobbler/default.nix
index b768e0166435e..911dbf7520299 100644
--- a/pkgs/tools/audio/mpris-scrobbler/default.nix
+++ b/pkgs/tools/audio/mpris-scrobbler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , curl
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minimalistic scrobbler for libre.fm & last.fm";
     homepage    = "https://github.com/mariusor/mpris-scrobbler";
     license     = licenses.mit;
diff --git a/pkgs/tools/audio/opl3bankeditor/default.nix b/pkgs/tools/audio/opl3bankeditor/default.nix
index 381591edb0218..c79204cffa2a7 100644
--- a/pkgs/tools/audio/opl3bankeditor/default.nix
+++ b/pkgs/tools/audio/opl3bankeditor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, qttools, alsaLib }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, qttools, alsaLib }:
 
 mkDerivation rec {
   version = "1.5.1";
@@ -17,7 +17,7 @@ mkDerivation rec {
   ];
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small cross-platform editor of the OPL3 FM banks of different formats";
     homepage = src.meta.homepage;
     license = licenses.gpl3;
diff --git a/pkgs/tools/audio/pa-applet/default.nix b/pkgs/tools/audio/pa-applet/default.nix
index 69e5976e6d5ea..89761cd0d4b98 100644
--- a/pkgs/tools/audio/pa-applet/default.nix
+++ b/pkgs/tools/audio/pa-applet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, libpulseaudio, pkgconfig, gtk3, glibc, autoconf, automake, libnotify, libX11, xf86inputevdev }:
+{ lib, stdenv, fetchgit, libpulseaudio, pkgconfig, gtk3, glibc, autoconf, automake, libnotify, libX11, xf86inputevdev }:
 
 stdenv.mkDerivation {
   name = "pa-applet-2012-04-11";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
   postInstall = ''
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "";
     license = licenses.gpl2;
     maintainers = with maintainers; [ domenkozar ];
diff --git a/pkgs/tools/audio/pasystray/default.nix b/pkgs/tools/audio/pasystray/default.nix
index d80f1af4182ab..ba61c4ad9f9eb 100644
--- a/pkgs/tools/audio/pasystray/default.nix
+++ b/pkgs/tools/audio/pasystray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchFromGitHub, pkgconfig, autoreconfHook, wrapGAppsHook
+{ lib, stdenv, fetchpatch, fetchFromGitHub, pkgconfig, autoreconfHook, wrapGAppsHook
 , gnome3, avahi, gtk3, libayatana-appindicator-gtk3, libnotify, libpulseaudio
 , xlibsWrapper, gsettings-desktop-schemas
 }:
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     gsettings-desktop-schemas
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PulseAudio system tray";
     homepage = "https://github.com/christophgysin/pasystray";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/tools/audio/playerctl/default.nix b/pkgs/tools/audio/playerctl/default.nix
index 7ef9557b42aa0..7c583f4f1f9ff 100644
--- a/pkgs/tools/audio/playerctl/default.nix
+++ b/pkgs/tools/audio/playerctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, meson, ninja, fetchFromGitHub, glib, pkgconfig, gtk-doc, docbook_xsl, gobject-introspection }:
+{ lib, stdenv, meson, ninja, fetchFromGitHub, glib, pkgconfig, gtk-doc, docbook_xsl, gobject-introspection }:
 
 stdenv.mkDerivation rec {
   pname = "playerctl";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   mesonFlags = [ "-Dbash-completions=true" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line utility and library for controlling media players that implement MPRIS";
     homepage = "https://github.com/acrisci/playerctl";
     license = licenses.lgpl3;
diff --git a/pkgs/tools/audio/pnmixer/default.nix b/pkgs/tools/audio/pnmixer/default.nix
index c1e40ae5dbb91..f16a7764e6c89 100644
--- a/pkgs/tools/audio/pnmixer/default.nix
+++ b/pkgs/tools/audio/pnmixer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, gettext, alsaLib, gtk3, glib, libnotify, libX11, pcre }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, gettext, alsaLib, gtk3, glib, libnotify, libX11, pcre }:
 
 stdenv.mkDerivation rec {
   pname = "pnmixer";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ alsaLib gtk3 glib libnotify libX11 pcre ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nicklan/pnmixer";
     description = "ALSA volume mixer for the system tray";
     license = licenses.gpl3;
diff --git a/pkgs/tools/audio/pulsemixer/default.nix b/pkgs/tools/audio/pulsemixer/default.nix
index b735c40031f6a..e6fc0c03e8989 100644
--- a/pkgs/tools/audio/pulsemixer/default.nix
+++ b/pkgs/tools/audio/pulsemixer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, libpulseaudio }:
+{ lib, stdenv, fetchFromGitHub, python3, libpulseaudio }:
 
 stdenv.mkDerivation rec {
   pname = "pulsemixer";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
       --replace "libpulse.so.0" "$libpulseaudio/lib/libpulse.so.0"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cli and curses mixer for pulseaudio";
     homepage = "https://github.com/GeorgeFilipkin/pulsemixer";
     license = licenses.mit;
diff --git a/pkgs/tools/audio/trx/default.nix b/pkgs/tools/audio/trx/default.nix
index 6a23b6caead48..c7445f03fd379 100644
--- a/pkgs/tools/audio/trx/default.nix
+++ b/pkgs/tools/audio/trx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, libopus, ortp, bctoolbox }:
+{ lib, stdenv, fetchurl, alsaLib, libopus, ortp, bctoolbox }:
 
 stdenv.mkDerivation rec {
   pname = "trx";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ alsaLib libopus ortp bctoolbox ];
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple toolset for broadcasting live audio using RTP/UDP and Opus";
     homepage = "http://www.pogo.org.uk/~mark/trx/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/audio/video2midi/default.nix b/pkgs/tools/audio/video2midi/default.nix
index cf9297119e9f5..3ce76fb61fae3 100644
--- a/pkgs/tools/audio/video2midi/default.nix
+++ b/pkgs/tools/audio/video2midi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, opencv3 }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, opencv3 }:
 
 let
   opencv3_ = pythonPackages.toPythonModule (opencv3.override {
@@ -25,7 +25,7 @@ in pythonPackages.buildPythonApplication rec {
     install -Dm755 v2m.py $out/bin/v2m.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Youtube synthesia video to midi conversion tool";
     homepage = src.meta.homepage;
     license = licenses.gpl3;
diff --git a/pkgs/tools/audio/volctl/default.nix b/pkgs/tools/audio/volctl/default.nix
index 1965fb083169a..06b6079bde244 100644
--- a/pkgs/tools/audio/volctl/default.nix
+++ b/pkgs/tools/audio/volctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, wrapGAppsHook, gobject-introspection, libpulseaudio, glib, gtk3, pango, xorg }:
+{ lib, stdenv, python3Packages, fetchFromGitHub, wrapGAppsHook, gobject-introspection, libpulseaudio, glib, gtk3, pango, xorg }:
 
 python3Packages.buildPythonApplication rec {
   pname = "volctl";
@@ -46,7 +46,7 @@ python3Packages.buildPythonApplication rec {
     gappsWrapperArgs+=(--prefix LD_LIBRARY_PATH : "${libpulseaudio}/lib")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PulseAudio enabled volume control featuring per-app sliders";
     homepage = "https://buzz.github.io/volctl/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/audio/volumeicon/default.nix b/pkgs/tools/audio/volumeicon/default.nix
index 50290881dc77e..3628433121e2f 100644
--- a/pkgs/tools/audio/volumeicon/default.nix
+++ b/pkgs/tools/audio/volumeicon/default.nix
@@ -1,4 +1,4 @@
-{ pkgs, fetchurl, stdenv, gtk3, pkgconfig, intltool, alsaLib }:
+{ pkgs, fetchurl, lib, stdenv, gtk3, pkgconfig, intltool, alsaLib }:
 
 stdenv.mkDerivation {
   pname = "volumeicon";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ gtk3 intltool alsaLib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight volume control that sits in your systray";
     homepage = "http://softwarebakery.com/maato/volumeicon.html";
     platforms = pkgs.lib.platforms.linux;
diff --git a/pkgs/tools/backup/automysqlbackup/default.nix b/pkgs/tools/backup/automysqlbackup/default.nix
index acdf31e47d8c4..b3b6e40997cc6 100644
--- a/pkgs/tools/backup/automysqlbackup/default.nix
+++ b/pkgs/tools/backup/automysqlbackup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, mysql, mailutils, pbzip2, pigz, bzip2, gzip }:
+{ lib, stdenv, fetchurl, makeWrapper, mysql, mailutils, pbzip2, pigz, bzip2, gzip }:
 
 stdenv.mkDerivation rec {
   pname = "automysqlbackup";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/automysqlbackup --prefix PATH : ${stdenv.lib.makeBinPath [ mysql mailutils pbzip2 pigz bzip2 gzip ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A script to run daily, weekly and monthly backups for your MySQL database";
     homepage = "https://sourceforge.net/projects/automysqlbackup/";
     platforms = platforms.linux;
diff --git a/pkgs/tools/backup/bacula/default.nix b/pkgs/tools/backup/bacula/default.nix
index 823fd000aee34..624e9ed62d397 100644
--- a/pkgs/tools/backup/bacula/default.nix
+++ b/pkgs/tools/backup/bacula/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, sqlite, postgresql, zlib, acl, ncurses, openssl, readline
+{ lib, stdenv, fetchurl, sqlite, postgresql, zlib, acl, ncurses, openssl, readline
 , CoreFoundation, IOKit
 }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     ln -s $out/sbin/* $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enterprise ready, Network Backup Tool";
     homepage    = "http://bacula.org/";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/backup/bareos/default.nix b/pkgs/tools/backup/bareos/default.nix
index 53de4853c6275..90fb2f4c4a49c 100644
--- a/pkgs/tools/backup/bareos/default.nix
+++ b/pkgs/tools/backup/bareos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, nettools, gettext, flex
+{ lib, stdenv, fetchFromGitHub, pkgconfig, nettools, gettext, flex
 , readline ? null, openssl ? null, python2 ? null, ncurses ? null, rocksdb
 , sqlite ? null, postgresql ? null, libmysqlclient ? null, zlib ? null, lzo ? null
 , jansson ? null, acl ? null, glusterfs ? null, libceph ? null, libcap ? null
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
     "sbindir=\${out}/bin"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.bareos.org/";
     description = "A fork of the bacula project";
     license = licenses.agpl3;
diff --git a/pkgs/tools/backup/bdsync/default.nix b/pkgs/tools/backup/bdsync/default.nix
index be2e9d0e6f212..0112ad4c9a193 100644
--- a/pkgs/tools/backup/bdsync/default.nix
+++ b/pkgs/tools/backup/bdsync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , openssl
 , pandoc
 , which
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     install -Dm644 bdsync.1 -t $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast block device synchronizing tool";
     homepage = "https://github.com/TargetHolding/bdsync";
     license = licenses.gpl2;
diff --git a/pkgs/tools/backup/borg/default.nix b/pkgs/tools/backup/borg/default.nix
index f7d9896431cae..121900f76f51e 100644
--- a/pkgs/tools/backup/borg/default.nix
+++ b/pkgs/tools/backup/borg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, acl, libb2, lz4, zstd, openssl, openssh }:
+{ lib, stdenv, python3, acl, libb2, lz4, zstd, openssl, openssh }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "borgbackup";
@@ -61,7 +61,7 @@ python3.pkgs.buildPythonApplication rec {
   # 64 failures, needs pytest-benchmark
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Deduplicating archiver with compression and encryption";
     homepage = "https://www.borgbackup.org";
     license = licenses.bsd3;
diff --git a/pkgs/tools/backup/btrbk/default.nix b/pkgs/tools/backup/btrbk/default.nix
index 6e450b11aa2b8..db6946e880575 100644
--- a/pkgs/tools/backup/btrbk/default.nix
+++ b/pkgs/tools/backup/btrbk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, coreutils, bash, btrfs-progs, openssh, perl, perlPackages
+{ lib, stdenv, fetchurl, coreutils, bash, btrfs-progs, openssh, perl, perlPackages
 , util-linux, asciidoc, asciidoctor, mbuffer, makeWrapper }:
 
 stdenv.mkDerivation rec {
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ':' "${stdenv.lib.makeBinPath [ btrfs-progs bash mbuffer openssh ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A backup tool for btrfs subvolumes";
     homepage = "https://digint.ch/btrbk";
     license = licenses.gpl3;
diff --git a/pkgs/tools/backup/burp/default.nix b/pkgs/tools/backup/burp/default.nix
index d9b4df98790e6..0da366b58eb1d 100644
--- a/pkgs/tools/backup/burp/default.nix
+++ b/pkgs/tools/backup/burp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , acl, librsync, ncurses, openssl, zlib, uthash }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "localstatedir=/tmp" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BURP - BackUp and Restore Program";
     homepage    = "https://burp.grke.org";
     license     = licenses.agpl3;
diff --git a/pkgs/tools/backup/dedup/default.nix b/pkgs/tools/backup/dedup/default.nix
index db9a05fcfde68..db7d24b7d85df 100644
--- a/pkgs/tools/backup/dedup/default.nix
+++ b/pkgs/tools/backup/dedup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, lz4, snappy, libsodium
+{ lib, stdenv, fetchurl, lz4, snappy, libsodium
 # For testing
 , coreutils, gawk
 }:
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
   checkInputs = [ coreutils gawk ];
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Data deduplication program";
     homepage = "https://git.2f30.org/dedup/file/README.html";
     license = with licenses; [ bsd0 isc ];
diff --git a/pkgs/tools/backup/dirvish/default.nix b/pkgs/tools/backup/dirvish/default.nix
index c762da1a5fcb2..701ac2333de98 100644
--- a/pkgs/tools/backup/dirvish/default.nix
+++ b/pkgs/tools/backup/dirvish/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, makeWrapper, perl, perlPackages }:
+{ fetchurl, lib, stdenv, makeWrapper, perl, perlPackages }:
 
 stdenv.mkDerivation rec {
   name = "dirvish-1.2.1";
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, disk based, rotating network backup system";
     homepage = "http://dirvish.org/";
     license = stdenv.lib.licenses.osl2;
diff --git a/pkgs/tools/backup/diskrsync/default.nix b/pkgs/tools/backup/diskrsync/default.nix
index 1057eb71dd600..d70efa1d2248f 100644
--- a/pkgs/tools/backup/diskrsync/default.nix
+++ b/pkgs/tools/backup/diskrsync/default.nix
@@ -1,4 +1,4 @@
-{ buildGoPackage, fetchFromGitHub, stdenv, openssh, makeWrapper }:
+{ buildGoPackage, fetchFromGitHub, lib, stdenv, openssh, makeWrapper }:
 
 buildGoPackage rec {
   pname = "diskrsync";
@@ -20,7 +20,7 @@ buildGoPackage rec {
     wrapProgram "$out/bin/diskrsync" --argv0 diskrsync --prefix PATH : ${openssh}/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rsync for block devices and disk images";
     homepage = "https://github.com/dop251/diskrsync";
     license = licenses.mit;
diff --git a/pkgs/tools/backup/dump/default.nix b/pkgs/tools/backup/dump/default.nix
index 38564e109d1ce..8299b7653f01f 100644
--- a/pkgs/tools/backup/dump/default.nix
+++ b/pkgs/tools/backup/dump/default.nix
@@ -1,7 +1,7 @@
 # Tested with simple dump and restore -i, but complains that
 # /nix/store/.../etc/dumpdates doesn't exist.
 
-{ stdenv, fetchurl, pkgconfig,
+{ lib, stdenv, fetchurl, pkgconfig,
   e2fsprogs, ncurses, readline }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ e2fsprogs pkgconfig ncurses readline ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://dump.sourceforge.io/";
     description = "Linux Ext2 filesystem dump/restore utilities";
     license = licenses.bsd3;
diff --git a/pkgs/tools/backup/duplicati/default.nix b/pkgs/tools/backup/duplicati/default.nix
index 63f35538796ac..502c8c713536f 100644
--- a/pkgs/tools/backup/duplicati/default.nix
+++ b/pkgs/tools/backup/duplicati/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, mono, sqlite, makeWrapper }:
+{ lib, stdenv, fetchzip, mono, sqlite, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "duplicati";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
           sqlite ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A free backup client that securely stores encrypted, incremental, compressed backups on cloud storage services and remote file servers";
     homepage = "https://www.duplicati.com/";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/backup/duplicity/default.nix b/pkgs/tools/backup/duplicity/default.nix
index 712d1d6f86e33..284cf50132f34 100644
--- a/pkgs/tools/backup/duplicity/default.nix
+++ b/pkgs/tools/backup/duplicity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchpatch
 , fetchurl
 , pythonPackages
@@ -112,7 +112,7 @@ pythonPackages.buildPythonApplication rec {
   # > OSError: out of pty devices
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Encrypted bandwidth-efficient backup using the rsync algorithm";
     homepage = "https://www.nongnu.org/duplicity";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/backup/duply/default.nix b/pkgs/tools/backup/duply/default.nix
index 7808a0925b15f..61e97b66e1833 100644
--- a/pkgs/tools/backup/duply/default.nix
+++ b/pkgs/tools/backup/duply/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, coreutils, python2, duplicity, gawk, gnupg, bash
+{ lib, stdenv, fetchurl, coreutils, python2, duplicity, gawk, gnupg, bash
 , gnugrep, txt2man, makeWrapper, which
 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     "$out/bin/duply" txt2man > "$out/share/man/man1/duply.1"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shell front end for the duplicity backup tool";
     longDescription = ''
       Duply is a shell front end for the duplicity backup tool
diff --git a/pkgs/tools/backup/easysnap/default.nix b/pkgs/tools/backup/easysnap/default.nix
index 5c2ad1a50a7bc..815dedc998d52 100644
--- a/pkgs/tools/backup/easysnap/default.nix
+++ b/pkgs/tools/backup/easysnap/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, zfs }:
+{lib, stdenv, fetchFromGitHub, zfs }:
 
 stdenv.mkDerivation {
   pname = "easysnap";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/sjau/easysnap";
     description = "Customizable ZFS Snapshotting tool with zfs send/recv pulling";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/backup/flockit/default.nix b/pkgs/tools/backup/flockit/default.nix
index 53baa6a6d9344..cd17f8e2438c4 100644
--- a/pkgs/tools/backup/flockit/default.nix
+++ b/pkgs/tools/backup/flockit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, runtimeShell }:
+{ lib, stdenv, fetchFromGitHub, runtimeShell }:
 
 stdenv.mkDerivation {
   pname = "flockit";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/flockit
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LD_PRELOAD shim to add file locking to programs that don't do it (I'm looking at you, rsync!)";
     longDescription = ''
       This library and tool exists solely because rsync doesn't have file locking.
diff --git a/pkgs/tools/backup/grab-site/default.nix b/pkgs/tools/backup/grab-site/default.nix
index 7ef1f110b6960..2ef3b5f54209a 100644
--- a/pkgs/tools/backup/grab-site/default.nix
+++ b/pkgs/tools/backup/grab-site/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python37, fetchFromGitHub }:
+{ lib, stdenv, python37, fetchFromGitHub }:
 let
   python = python37.override {
     self = python;
@@ -40,7 +40,7 @@ with python.pkgs; buildPythonApplication rec {
     bash ./tests/offline-tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Crawler for web archiving with WARC output";
     homepage = "https://github.com/ArchiveTeam/grab-site";
     license = licenses.mit;
diff --git a/pkgs/tools/backup/hpe-ltfs/default.nix b/pkgs/tools/backup/hpe-ltfs/default.nix
index e34155bb23897..346cb6521bafd 100644
--- a/pkgs/tools/backup/hpe-ltfs/default.nix
+++ b/pkgs/tools/backup/hpe-ltfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fuse, icu, pkgconfig, libxml2, libuuid }:
+{ lib, stdenv, fetchFromGitHub, fuse, icu, pkgconfig, libxml2, libuuid }:
 
 stdenv.mkDerivation rec {
   version = "3.4.2_Z7550-02501";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     fuse icu libxml2 libuuid
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HPE's implementation of the open-source tape filesystem standard ltfs";
     homepage = "https://support.hpe.com/hpesc/public/km/product/1009214665/Product";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/backup/httrack/default.nix b/pkgs/tools/backup/httrack/default.nix
index 9a77153e2ff3f..f611a953f3a86 100644
--- a/pkgs/tools/backup/httrack/default.nix
+++ b/pkgs/tools/backup/httrack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, openssl, libiconv }:
+{ lib, stdenv, fetchurl, zlib, openssl, libiconv }:
 
 stdenv.mkDerivation rec {
   version = "3.49.2";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easy-to-use offline browser / website mirroring utility";
     homepage    = "http://www.httrack.com";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/backup/httrack/qt.nix b/pkgs/tools/backup/httrack/qt.nix
index 782377d351d21..000f11a5a00e0 100644
--- a/pkgs/tools/backup/httrack/qt.nix
+++ b/pkgs/tools/backup/httrack/qt.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchurl, cmake, pkgconfig, makeWrapper
+{ mkDerivation, lib, stdenv, fetchurl, cmake, pkgconfig, makeWrapper
 , httrack, qtbase, qtmultimedia }:
 
 mkDerivation rec {
@@ -28,7 +28,7 @@ mkDerivation rec {
       --replace /usr/share/httraqt/ $out/share/httraqt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easy-to-use offline browser / website mirroring utility - QT frontend";
     homepage    = "http://www.httrack.com";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/backup/lvmsync/default.nix b/pkgs/tools/backup/lvmsync/default.nix
index 75962c98f8b64..c289c3938ab7c 100644
--- a/pkgs/tools/backup/lvmsync/default.nix
+++ b/pkgs/tools/backup/lvmsync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bundlerEnv, ruby, bundlerUpdateScript, makeWrapper }:
+{ lib, stdenv, bundlerEnv, ruby, bundlerUpdateScript, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "lvmsync";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   passthru.updateScript = bundlerUpdateScript "lvmsync";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimised synchronisation of LVM snapshots over a network";
     homepage = "https://theshed.hezmatt.org/lvmsync/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/backup/monolith/default.nix b/pkgs/tools/backup/monolith/default.nix
index 4d17209be8937..f88ee31711f63 100644
--- a/pkgs/tools/backup/monolith/default.nix
+++ b/pkgs/tools/backup/monolith/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , pkg-config
@@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec {
 
   checkFlagsArray = [ "--skip=tests::cli" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bundle any web page into a single HTML file";
     homepage = "https://github.com/Y2Z/monolith";
     license = licenses.unlicense;
diff --git a/pkgs/tools/backup/mydumper/default.nix b/pkgs/tools/backup/mydumper/default.nix
index 611e543ca6ce7..7549ac73292dd 100644
--- a/pkgs/tools/backup/mydumper/default.nix
+++ b/pkgs/tools/backup/mydumper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , glib, zlib, pcre, libmysqlclient, libressl }:
 
 let inherit (stdenv.lib) getDev; in
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DMYSQL_INCLUDE_DIR=${getDev libmysqlclient}/include/mysql" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''High-perfomance MySQL backup tool'';
     homepage = "https://github.com/maxbube/mydumper";
     license = licenses.gpl3;
diff --git a/pkgs/tools/backup/ori/default.nix b/pkgs/tools/backup/ori/default.nix
index 9f00a7f2133a7..79eb57c2bbe27 100644
--- a/pkgs/tools/backup/ori/default.nix
+++ b/pkgs/tools/backup/ori/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, boost, pkgconfig, scons, util-linux, fuse, libevent, openssl, zlib }:
+{ lib, stdenv, fetchurl, boost, pkgconfig, scons, util-linux, fuse, libevent, openssl, zlib }:
 
 stdenv.mkDerivation {
   version = "0.8.1";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   installPhase = ":";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A secure distributed file system";
     homepage = "http://ori.scs.stanford.edu/";
     license = licenses.mit;
diff --git a/pkgs/tools/backup/percona-xtrabackup/generic.nix b/pkgs/tools/backup/percona-xtrabackup/generic.nix
index 9339e8155eabf..7d8c3627f6758 100644
--- a/pkgs/tools/backup/percona-xtrabackup/generic.nix
+++ b/pkgs/tools/backup/percona-xtrabackup/generic.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bison, boost, cmake, makeWrapper, pkgconfig
+{ lib, stdenv, fetchFromGitHub, bison, boost, cmake, makeWrapper, pkgconfig
 , curl, cyrus_sasl, libaio, libedit, libev, libevent, libgcrypt, libgpgerror, lz4
 , ncurses, numactl, openssl, protobuf, valgrind, xxd, zlib
 , perlPackages
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     rm -r "$out"/lib/plugin/debug
   '' + extraPostInstall;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Non-blocking backup tool for MySQL";
     homepage = "http://www.percona.com/software/percona-xtrabackup";
     license = licenses.lgpl2;
diff --git a/pkgs/tools/backup/rdedup/default.nix b/pkgs/tools/backup/rdedup/default.nix
index 83b14d87db7bf..05b35e004a293 100644
--- a/pkgs/tools/backup/rdedup/default.nix
+++ b/pkgs/tools/backup/rdedup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, libsodium
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, libsodium
 , llvmPackages, clang, lzma
 , Security }:
 
@@ -27,7 +27,7 @@ rustPlatform.buildRustPackage rec {
     export LIBCLANG_PATH="${llvmPackages.libclang}/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Data deduplication with compression and public key encryption";
     homepage = "https://github.com/dpc/rdedup";
     license = licenses.mpl20;
diff --git a/pkgs/tools/backup/rsnapshot/default.nix b/pkgs/tools/backup/rsnapshot/default.nix
index 0503dc3b65729..1f65bd6ae5a48 100644
--- a/pkgs/tools/backup/rsnapshot/default.nix
+++ b/pkgs/tools/backup/rsnapshot/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, perl, openssh, rsync, logger }:
+{ fetchurl, lib, stdenv, perl, openssh, rsync, logger }:
 
 stdenv.mkDerivation rec {
   name = "rsnapshot-1.4.3";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       "/usr/bin/pod2man" "${perl}/bin/pod2man"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A filesystem snapshot utility for making backups of local and remote systems";
     homepage = "https://rsnapshot.org/";
     license = stdenv.lib.licenses.gpl2Plus;
diff --git a/pkgs/tools/backup/s3ql/default.nix b/pkgs/tools/backup/s3ql/default.nix
index 7e4cc66278cbb..74b90236c4e96 100644
--- a/pkgs/tools/backup/s3ql/default.nix
+++ b/pkgs/tools/backup/s3ql/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, sqlite, which }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, sqlite, which }:
 
 python3Packages.buildPythonApplication rec {
   pname = "s3ql";
@@ -27,7 +27,7 @@ python3Packages.buildPythonApplication rec {
     pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full-featured file system for online data storage";
     homepage = "https://github.com/s3ql/s3ql/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/backup/ugarit-manifest-maker/default.nix b/pkgs/tools/backup/ugarit-manifest-maker/default.nix
index f763296e1d6e5..99ddd62e6ae21 100644
--- a/pkgs/tools/backup/ugarit-manifest-maker/default.nix
+++ b/pkgs/tools/backup/ugarit-manifest-maker/default.nix
@@ -1,4 +1,4 @@
-{ pkgs, stdenv, eggDerivation, fetchegg }:
+{ pkgs, lib, stdenv, eggDerivation, fetchegg }:
 let
   eggs = import ./eggs.nix { inherit eggDerivation fetchegg; };
 in with pkgs; eggDerivation rec {
@@ -21,7 +21,7 @@ in with pkgs; eggDerivation rec {
     numbers
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.kitten-technologies.co.uk/project/ugarit-manifest-maker/";
     description = "A tool for generating import manifests for Ugarit";
     license = licenses.bsd3;
diff --git a/pkgs/tools/backup/ugarit/default.nix b/pkgs/tools/backup/ugarit/default.nix
index bc69662dc2bda..938c24f38ce16 100644
--- a/pkgs/tools/backup/ugarit/default.nix
+++ b/pkgs/tools/backup/ugarit/default.nix
@@ -1,4 +1,4 @@
-{ pkgs, stdenv, eggDerivation, fetchegg }:
+{ pkgs, lib, stdenv, eggDerivation, fetchegg }:
 let
   eggs = import ./eggs.nix { inherit eggDerivation fetchegg; };
 in with pkgs; eggDerivation rec {
@@ -31,7 +31,7 @@ in with pkgs; eggDerivation rec {
     z3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.kitten-technologies.co.uk/project/ugarit/";
     description = "A backup/archival system based around content-addressible storage";
     license = licenses.bsd3;
diff --git a/pkgs/tools/backup/zfs-prune-snapshots/default.nix b/pkgs/tools/backup/zfs-prune-snapshots/default.nix
index 434c86b343a89..f8a3adfecda67 100644
--- a/pkgs/tools/backup/zfs-prune-snapshots/default.nix
+++ b/pkgs/tools/backup/zfs-prune-snapshots/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, go-md2man }:
+{ lib, stdenv, fetchFromGitHub, go-md2man }:
 
 stdenv.mkDerivation rec {
   version = "1.1.0";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -m 644 -D man/zfs-prune-snapshots.1 $out/share/man/man1/zfs-prune-snapshots.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Remove snapshots from one or more zpools that match given criteria";
     homepage = "https://github.com/bahamas10/zfs-prune-snapshots";
     license = licenses.mit;
diff --git a/pkgs/tools/backup/zfs-replicate/default.nix b/pkgs/tools/backup/zfs-replicate/default.nix
index 782133fd8d7bb..02e3c19f00462 100644
--- a/pkgs/tools/backup/zfs-replicate/default.nix
+++ b/pkgs/tools/backup/zfs-replicate/default.nix
@@ -1,5 +1,5 @@
 { buildPythonApplication, click, fetchPypi, hypothesis, mypy, pytest
-, pytestcov, pytestrunner, stdenv, stringcase
+, pytestcov, pytestrunner, lib, stdenv, stringcase
 }:
 
 buildPythonApplication rec {
@@ -33,7 +33,7 @@ buildPythonApplication rec {
     pytest --doctest-modules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/alunduil/zfs-replicate";
     description = "ZFS Snapshot Replication";
     license = licenses.bsd2;
diff --git a/pkgs/tools/backup/zfsnap/default.nix b/pkgs/tools/backup/zfsnap/default.nix
index 89d7414246c44..36e369b4f30ae 100644
--- a/pkgs/tools/backup/zfsnap/default.nix
+++ b/pkgs/tools/backup/zfsnap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, coreutils, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, coreutils, installShellFiles }:
 
 stdenv.mkDerivation rec {
   version = "2.0.0-beta3";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     installShellCompletion completion/*.{bash,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A portable, performant script to make rolling ZFS snapshots easy";
     homepage = "https://github.com/zfsnap/zfsnap";
     license = licenses.bsd3;
diff --git a/pkgs/tools/backup/znapzend/default.nix b/pkgs/tools/backup/znapzend/default.nix
index 5ca460beb3bec..1e4e84b445bd1 100644
--- a/pkgs/tools/backup/znapzend/default.nix
+++ b/pkgs/tools/backup/znapzend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, perl, perlPackages, wget, autoconf, automake, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, perl, perlPackages, wget, autoconf, automake, autoreconfHook }:
 
 let
   # when upgrade znapzend, check versions of Perl libs here: https://github.com/oetiker/znapzend/blob/master/cpanfile
@@ -77,7 +77,7 @@ stdenv.mkDerivation {
       "
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High performance open source ZFS backup with mbuffer and ssh support";
     homepage    = "http://www.znapzend.org";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/bluetooth/bluez-tools/default.nix b/pkgs/tools/bluetooth/bluez-tools/default.nix
index 47aaadc9ccf0e..bf3d73c657a19 100644
--- a/pkgs/tools/bluetooth/bluez-tools/default.nix
+++ b/pkgs/tools/bluetooth/bluez-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoreconfHook, readline
+{ lib, stdenv, autoreconfHook, readline
 , fetchFromGitHub, glib, pkgconfig }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ readline glib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line bluetooth manager for Bluez5";
     license = licenses.gpl2;
     maintainers = [ maintainers.dasuxullebt ];
diff --git a/pkgs/tools/bluetooth/obex-data-server/default.nix b/pkgs/tools/bluetooth/obex-data-server/default.nix
index f95869e789cb4..93cb3a1c84428 100644
--- a/pkgs/tools/bluetooth/obex-data-server/default.nix
+++ b/pkgs/tools/bluetooth/obex-data-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libusb-compat-0_1, glib, dbus-glib, bluez, openobex, dbus }:
+{ lib, stdenv, fetchurl, pkgconfig, libusb-compat-0_1, glib, dbus-glib, bluez, openobex, dbus }:
 
 stdenv.mkDerivation rec {
   name = "obex-data-server-0.4.6";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   export PKG_CONFIG_PATH="${dbus.dev}/lib/pkgconfig:$PKG_CONFIG_PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://wiki.muiline.com/obex-data-server";
     platforms = platforms.linux;
     license = licenses.gpl2;
diff --git a/pkgs/tools/bluetooth/obexd/default.nix b/pkgs/tools/bluetooth/obexd/default.nix
index c235c99d762c7..dc6ced6814cb7 100644
--- a/pkgs/tools/bluetooth/obexd/default.nix
+++ b/pkgs/tools/bluetooth/obexd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, glib, dbus, openobex, bluez, libical }:
+{ lib, stdenv, fetchurl, pkgconfig, glib, dbus, openobex, bluez, libical }:
 
 stdenv.mkDerivation rec {
   name = "obexd-0.48";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.bluez.org/";
     platforms = platforms.linux;
     license = licenses.gpl3;
diff --git a/pkgs/tools/bluetooth/obexfs/default.nix b/pkgs/tools/bluetooth/obexfs/default.nix
index 1c24697c6898a..914032e1ee169 100644
--- a/pkgs/tools/bluetooth/obexfs/default.nix
+++ b/pkgs/tools/bluetooth/obexfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, bluez, fuse, obexftp }:
+{ lib, stdenv, fetchurl, pkgconfig, bluez, fuse, obexftp }:
 
 stdenv.mkDerivation rec {
   name = "obexfs-0.12";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ fuse obexftp bluez ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://dev.zuckschwerdt.org/openobex/wiki/ObexFs";
     description = "A tool to mount OBEX-based devices (such as Bluetooth phones)";
     platforms = platforms.linux;
diff --git a/pkgs/tools/bluetooth/obexftp/default.nix b/pkgs/tools/bluetooth/obexftp/default.nix
index 69779557300d6..d0cc7c321640a 100644
--- a/pkgs/tools/bluetooth/obexftp/default.nix
+++ b/pkgs/tools/bluetooth/obexftp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, openobex, bluez, cmake }:
+{ lib, stdenv, fetchurl, pkgconfig, openobex, bluez, cmake }:
    
 stdenv.mkDerivation rec {
   name = "obexftp-0.24.2";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     sed -i 's,^Requires: bluetooth,Requires:,' $out/lib/pkgconfig/obexftp.pc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://dev.zuckschwerdt.org/openobex/wiki/ObexFtp";
     description = "A library and tool to access files on OBEX-based devices (such as Bluetooth phones)";
     platforms = platforms.linux;
diff --git a/pkgs/tools/bluetooth/openobex/default.nix b/pkgs/tools/bluetooth/openobex/default.nix
index 7ac0234852c1a..27dac53e6b38d 100644
--- a/pkgs/tools/bluetooth/openobex/default.nix
+++ b/pkgs/tools/bluetooth/openobex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, bluez, libusb-compat-0_1, cmake }:
+{ lib, stdenv, fetchurl, pkgconfig, bluez, libusb-compat-0_1, cmake }:
    
 stdenv.mkDerivation rec {
   name = "openobex-1.7.2";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     sed -i "/if ( PKGCONFIG_UDEV_FOUND )/,/endif ( PKGCONFIG_UDEV_FOUND )/d" udev/CMakeLists.txt
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://dev.zuckschwerdt.org/openobex/";
     description = "An open source implementation of the Object Exchange (OBEX) protocol";
     platforms = platforms.linux;
diff --git a/pkgs/tools/bootloaders/refind/default.nix b/pkgs/tools/bootloaders/refind/default.nix
index 76786c26d8185..9c36e55b8f248 100644
--- a/pkgs/tools/bootloaders/refind/default.nix
+++ b/pkgs/tools/bootloaders/refind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnu-efi }:
+{ lib, stdenv, fetchurl, gnu-efi }:
 
 let
   archids = {
@@ -104,7 +104,7 @@ stdenv.mkDerivation rec {
     sed -i 's,`which \(.*\)`,`type -p \1`,g' $out/bin/refind-mkfont
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A graphical {,U}EFI boot manager";
     longDescription = ''
       rEFInd is a graphical boot manager for EFI- and UEFI-based
diff --git a/pkgs/tools/cd-dvd/bashburn/default.nix b/pkgs/tools/cd-dvd/bashburn/default.nix
index 0acf55da7fe25..d9664f1072fbd 100644
--- a/pkgs/tools/cd-dvd/bashburn/default.nix
+++ b/pkgs/tools/cd-dvd/bashburn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, util-linux
+{ lib, stdenv, fetchurl, util-linux
 , cdparanoia, cdrdao, dvdplusrwtools, flac, lame, mpg123, normalize
 , vorbis-tools, xorriso }:
 
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     sh Install.sh --prefix $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bash script CD Burner Writer";
     longDescription = ''
       It might not be the best looking application out there, but it works.
diff --git a/pkgs/tools/cd-dvd/bchunk/default.nix b/pkgs/tools/cd-dvd/bchunk/default.nix
index df63ced882fe7..d5c3a30e7aea1 100644
--- a/pkgs/tools/cd-dvd/bchunk/default.nix
+++ b/pkgs/tools/cd-dvd/bchunk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "bchunk";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     install -Dt $out/share/man/man1 bchunk.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://he.fi/bchunk/";
     description = "A program that converts CD images in BIN/CUE format into a set of ISO and CDR tracks";
     platforms = platforms.unix;
diff --git a/pkgs/tools/cd-dvd/brasero/default.nix b/pkgs/tools/cd-dvd/brasero/default.nix
index c9c71a99deb8b..727c092e3aac8 100644
--- a/pkgs/tools/cd-dvd/brasero/default.nix
+++ b/pkgs/tools/cd-dvd/brasero/default.nix
@@ -39,7 +39,7 @@ in stdenv.mkDerivation rec {
     gappsWrapperArgs+=(--prefix PATH : "${binpath}")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Gnome CD/DVD Burner";
     homepage = "https://wiki.gnome.org/Apps/Brasero";
     maintainers = [ maintainers.bdimcheff ];
diff --git a/pkgs/tools/cd-dvd/ccd2iso/default.nix b/pkgs/tools/cd-dvd/ccd2iso/default.nix
index a6ba7fd332f3a..10f8d9701d406 100644
--- a/pkgs/tools/cd-dvd/ccd2iso/default.nix
+++ b/pkgs/tools/cd-dvd/ccd2iso/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "ccd2iso-0.3";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "1z000zi7hpr2h9cabj6hzf3n6a6gd6glmm8nn36v4b8i4vzbhx7q";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CloneCD to ISO converter";
     homepage = "https://sourceforge.net/projects/ccd2iso/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/cd-dvd/cdi2iso/default.nix b/pkgs/tools/cd-dvd/cdi2iso/default.nix
index 9d7336663a8e5..9df7ab7657f12 100644
--- a/pkgs/tools/cd-dvd/cdi2iso/default.nix
+++ b/pkgs/tools/cd-dvd/cdi2iso/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "cdi2iso";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     cp cdi2iso $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A very simple utility for converting DiscJuggler images to the standard ISO-9660 format";
     homepage = "https://sourceforge.net/projects/cdi2iso.berlios";
     license = licenses.gpl2;
diff --git a/pkgs/tools/cd-dvd/cdimgtools/default.nix b/pkgs/tools/cd-dvd/cdimgtools/default.nix
index fde9eb1a33208..5f8d6016aa219 100644
--- a/pkgs/tools/cd-dvd/cdimgtools/default.nix
+++ b/pkgs/tools/cd-dvd/cdimgtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromRepoOrCz, autoreconfHook, makeWrapper, libdvdcss, libdvdread, perl, perlPackages, asciidoc, xmlto, sourceHighlight, docbook_xsl, docbook_xml_dtd_45 }:
+{ lib, stdenv, fetchFromRepoOrCz, autoreconfHook, makeWrapper, libdvdcss, libdvdread, perl, perlPackages, asciidoc, xmlto, sourceHighlight, docbook_xsl, docbook_xml_dtd_45 }:
 
 stdenv.mkDerivation {
   pname = "cdimgtools";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
 
   installTargets = [ "install" "install-doc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://repo.or.cz/cdimgtools.git/blob_plain/refs/heads/release:/README.html";
     description = "Tools to inspect and manipulate CD/DVD optical disc images";
     license = licenses.gpl2;
diff --git a/pkgs/tools/cd-dvd/cdrdao/default.nix b/pkgs/tools/cd-dvd/cdrdao/default.nix
index d0d12c34c0591..85bebad2723ac 100644
--- a/pkgs/tools/cd-dvd/cdrdao/default.nix
+++ b/pkgs/tools/cd-dvd/cdrdao/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, libvorbis, libmad, pkgconfig, libao}:
+{lib, stdenv, fetchurl, libvorbis, libmad, pkgconfig, libao}:
 
 stdenv.mkDerivation {
   name = "cdrdao-1.2.3";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
   # Needed on gcc >= 6.
   NIX_CFLAGS_COMPILE = "-Wno-narrowing";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for recording audio or data CD-Rs in disk-at-once (DAO) mode";
     homepage = "http://cdrdao.sourceforge.net/";
     platforms = platforms.linux;
diff --git a/pkgs/tools/cd-dvd/cdrtools/default.nix b/pkgs/tools/cd-dvd/cdrtools/default.nix
index f4f07143a207e..bca1a1c689c3c 100644
--- a/pkgs/tools/cd-dvd/cdrtools/default.nix
+++ b/pkgs/tools/cd-dvd/cdrtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, m4, acl, libcap, Carbon, IOKit }:
+{ lib, stdenv, fetchurl, m4, acl, libcap, Carbon, IOKit }:
 
 stdenv.mkDerivation rec {
   pname = "cdrtools";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = false; # parallel building fails on some linux machines
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://cdrtools.sourceforge.net/private/cdrecord.html";
     description = "Highly portable CD/DVD/BluRay command line recording software";
     license = with licenses; [ cddl gpl2 lgpl21 ];
diff --git a/pkgs/tools/cd-dvd/cuetools/default.nix b/pkgs/tools/cd-dvd/cuetools/default.nix
index ebc631521773a..a6cf5506138b0 100644
--- a/pkgs/tools/cd-dvd/cuetools/default.nix
+++ b/pkgs/tools/cd-dvd/cuetools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, autoreconfHook
 , bison, flac, flex, id3v2, vorbis-tools
 }:
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     ln -s $out/bin/cuetag.sh $out/bin/cuetag
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of utilities for working with cue files and toc files";
     homepage = "https://github.com/svend/cuetools";
     license = licenses.gpl2;
diff --git a/pkgs/tools/cd-dvd/dvd+rw-tools/default.nix b/pkgs/tools/cd-dvd/dvd+rw-tools/default.nix
index 40925a14537a4..d396bf030ca63 100644
--- a/pkgs/tools/cd-dvd/dvd+rw-tools/default.nix
+++ b/pkgs/tools/cd-dvd/dvd+rw-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, cdrtools, m4 }:
+{ lib, stdenv, fetchurl, fetchpatch, cdrtools, m4 }:
 
 stdenv.mkDerivation rec {
   pname = "dvd+rw-tools";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fy.chalmers.se/~appro/linux/DVD+RW/tools";
     description = "Tools for mastering Blu-ray and DVD+-RW/+-R media";
     platforms = platforms.linux;
diff --git a/pkgs/tools/cd-dvd/dvd-vr/default.nix b/pkgs/tools/cd-dvd/dvd-vr/default.nix
index aef0c3a636f9d..4375aebe2990a 100644
--- a/pkgs/tools/cd-dvd/dvd-vr/default.nix
+++ b/pkgs/tools/cd-dvd/dvd-vr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "dvd-vr";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
   };
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.pixelbeat.org/programs/dvd-vr/";
     downloadPage = "https://www.pixelbeat.org/programs/dvd-vr/";
     description = "A utility to identify and optionally copy recordings from a DVD-VR format disc";
diff --git a/pkgs/tools/cd-dvd/dvdisaster/default.nix b/pkgs/tools/cd-dvd/dvdisaster/default.nix
index 5a3828d801315..1087bb94b4326 100644
--- a/pkgs/tools/cd-dvd/dvdisaster/default.nix
+++ b/pkgs/tools/cd-dvd/dvdisaster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gettext, which
+{ lib, stdenv, fetchurl, pkgconfig, gettext, which
 , glib, gtk2
 , enableSoftening ? true
 }:
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://dvdisaster.net/";
     description = "Data loss/scratch/aging protection for CD/DVD media";
     longDescription = ''
diff --git a/pkgs/tools/cd-dvd/ecm-tools/default.nix b/pkgs/tools/cd-dvd/ecm-tools/default.nix
index 2ebf8e6555171..18ef6f02d80c4 100644
--- a/pkgs/tools/cd-dvd/ecm-tools/default.nix
+++ b/pkgs/tools/cd-dvd/ecm-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "ecm-tools";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     (cd $out/bin; ln -s bin2ecm ecm2bin)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility to uncompress ECM files to BIN CD format";
     homepage = "https://github.com/alucryd/ecm-tools";
     license = licenses.gpl3;
diff --git a/pkgs/tools/cd-dvd/isolyzer/default.nix b/pkgs/tools/cd-dvd/isolyzer/default.nix
index 1fd704d90f195..477fa337da84b 100644
--- a/pkgs/tools/cd-dvd/isolyzer/default.nix
+++ b/pkgs/tools/cd-dvd/isolyzer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python3
 , fetchFromGitHub
 }:
@@ -16,7 +16,7 @@ python3.pkgs.buildPythonApplication rec {
 
   propagatedBuildInputs = with python3.pkgs; [ setuptools six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/KBNLresearch/isolyzer";
     description = "Verify size of ISO 9660 image against Volume Descriptor fields";
     license = licenses.asl20;
diff --git a/pkgs/tools/cd-dvd/isomd5sum/default.nix b/pkgs/tools/cd-dvd/isomd5sum/default.nix
index 0c30f0fe98012..2ca14cc4d6039 100644
--- a/pkgs/tools/cd-dvd/isomd5sum/default.nix
+++ b/pkgs/tools/cd-dvd/isomd5sum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , python3
 , popt
 }:
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
   # we don't install python stuff as it borks up directories
   installTargets = [ "install-bin" "install-devel" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rhinstaller/isomd5sum";
     description = "Utilities for working with md5sum implanted in ISO images";
     platforms = platforms.linux;
diff --git a/pkgs/tools/cd-dvd/lsdvd/default.nix b/pkgs/tools/cd-dvd/lsdvd/default.nix
index 39d0ab5fc2d65..7847720dc6d50 100644
--- a/pkgs/tools/cd-dvd/lsdvd/default.nix
+++ b/pkgs/tools/cd-dvd/lsdvd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libdvdread, pkgconfig }:
+{ lib, stdenv, fetchurl, libdvdread, pkgconfig }:
 
 let
   version = "0.17";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   buildInputs = [ libdvdread ];
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/lsdvd/";
     description = "Display information about audio, video, and subtitle tracks on a DVD";
     license = licenses.gpl2;
diff --git a/pkgs/tools/cd-dvd/mdf2iso/default.nix b/pkgs/tools/cd-dvd/mdf2iso/default.nix
index dbad9d362478f..e737e38d1bd66 100644
--- a/pkgs/tools/cd-dvd/mdf2iso/default.nix
+++ b/pkgs/tools/cd-dvd/mdf2iso/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchgit}:
+{lib, stdenv, fetchgit}:
 
 stdenv.mkDerivation rec {
   pname = "mdf2iso";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     sha256 = "0xg43jlvrk8adfjgbjir15nxwcj0nhz4gxpqx7jdfvhg0kwliq0n";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small utility that converts MDF images to ISO format";
     homepage = src.url;
     license = licenses.gpl2;
diff --git a/pkgs/tools/cd-dvd/mkcue/default.nix b/pkgs/tools/cd-dvd/mkcue/default.nix
index 357992d729168..596164f13ffa6 100644
--- a/pkgs/tools/cd-dvd/mkcue/default.nix
+++ b/pkgs/tools/cd-dvd/mkcue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "mkcue";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   preInstall = "mkdir -pv $out/bin";
   postInstall = "chmod -v +w $out/bin/mkcue";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generates CUE sheets from a CD TOC";
     license = licenses.lgpl2Plus;
     platforms = platforms.linux;
diff --git a/pkgs/tools/cd-dvd/nrg2iso/default.nix b/pkgs/tools/cd-dvd/nrg2iso/default.nix
index 082dada85fdef..e57948a80dd62 100644
--- a/pkgs/tools/cd-dvd/nrg2iso/default.nix
+++ b/pkgs/tools/cd-dvd/nrg2iso/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "nrg2iso";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     cp -v nrg2iso $out/bin/nrg2iso
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A linux utils for converting CD (or DVD) image generated by Nero Burning Rom to ISO format";
     homepage = "http://gregory.kokanosky.free.fr/v4/linux/nrg2iso.en.html";
     license = licenses.gpl2;
diff --git a/pkgs/tools/cd-dvd/sacd/default.nix b/pkgs/tools/cd-dvd/sacd/default.nix
index a3ce3d3618248..23bf808c50fe6 100644
--- a/pkgs/tools/cd-dvd/sacd/default.nix
+++ b/pkgs/tools/cd-dvd/sacd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 }:
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     "PREFIX=$(out)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts SACD image files, Philips DSDIFF and Sony DSF files to 24-bit high resolution wave files. Handles both DST and DSD streams. ";
     longDescription = ''
       Super Audio CD decoder. Converts SACD image files, Philips DSDIFF and Sony DSF files to 24-bit high resolution wave files.
diff --git a/pkgs/tools/cd-dvd/srt-to-vtt-cl/default.nix b/pkgs/tools/cd-dvd/srt-to-vtt-cl/default.nix
index 8efc50c449354..70fcedde858af 100644
--- a/pkgs/tools/cd-dvd/srt-to-vtt-cl/default.nix
+++ b/pkgs/tools/cd-dvd/srt-to-vtt-cl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll }:
+{ lib, stdenv, fetchFromGitHub, substituteAll }:
 
 stdenv.mkDerivation rec {
   pname = "srt-to-vtt-cl";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp bin/$(uname -s)/$(uname -m)/srt-vtt $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert SRT files to VTT";
     license = licenses.mit;
     maintainers = with maintainers; [ ericdallo ];
diff --git a/pkgs/tools/cd-dvd/unetbootin/default.nix b/pkgs/tools/cd-dvd/unetbootin/default.nix
index b935bc02d1508..5ccb4b49d7e89 100644
--- a/pkgs/tools/cd-dvd/unetbootin/default.nix
+++ b/pkgs/tools/cd-dvd/unetbootin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, qt4, util-linux, coreutils, which, qmake4Hook
+{ lib, stdenv, fetchFromGitHub, makeWrapper, qt4, util-linux, coreutils, which, qmake4Hook
 , p7zip, mtools, syslinux }:
 
 stdenv.mkDerivation rec {
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://unetbootin.sourceforge.net/";
     description = "A tool to create bootable live USB drives from ISO images";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/tools/cd-dvd/xorriso/default.nix b/pkgs/tools/cd-dvd/xorriso/default.nix
index b3f268214db36..b40808a5a8cc8 100644
--- a/pkgs/tools/cd-dvd/xorriso/default.nix
+++ b/pkgs/tools/cd-dvd/xorriso/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, libcdio, zlib, bzip2, readline, acl, attr, libiconv }:
+{ fetchurl, lib, stdenv, libcdio, zlib, bzip2, readline, acl, attr, libiconv }:
 
 stdenv.mkDerivation rec {
   name = "xorriso-${version}";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libcdio zlib bzip2 readline libiconv ]
     ++ stdenv.lib.optionals stdenv.isLinux [ acl attr ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ISO 9660 Rock Ridge file system manipulator";
 
     longDescription =
diff --git a/pkgs/tools/compression/advancecomp/default.nix b/pkgs/tools/compression/advancecomp/default.nix
index e648aa6feb648..b0e7f9e8f6b51 100644
--- a/pkgs/tools/compression/advancecomp/default.nix
+++ b/pkgs/tools/compression/advancecomp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , autoreconfHook
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     echo "${version}" >.version
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''A set of tools to optimize deflate-compressed files'';
     license = licenses.gpl3 ;
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/tools/compression/brotli/default.nix b/pkgs/tools/compression/brotli/default.nix
index 62873569aae16..1c80c70b7c1df 100644
--- a/pkgs/tools/compression/brotli/default.nix
+++ b/pkgs/tools/compression/brotli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, fetchpatch
+{ lib, stdenv, fetchFromGitHub, cmake, fetchpatch
 , staticOnly ? stdenv.hostPlatform.isStatic
 }:
 
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     cp ../docs/*.3 $out/share/man/man3/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
 
     description = "A generic-purpose lossless compression algorithm and tool";
diff --git a/pkgs/tools/compression/bsc/default.nix b/pkgs/tools/compression/bsc/default.nix
index 384cbfc3839bf..1f15b3d2f87b4 100644
--- a/pkgs/tools/compression/bsc/default.nix
+++ b/pkgs/tools/compression/bsc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openmp ? null }:
+{ lib, stdenv, fetchurl, openmp ? null }:
 
 stdenv.mkDerivation rec {
   pname = "bsc";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     makeFlagsArray+=("PREFIX=$out")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High performance block-sorting data compression library";
     homepage = "http://libbsc.com/";
     # Later commits changed the licence to Apache2 (no release yet, though)
diff --git a/pkgs/tools/compression/bzip2/1_1.nix b/pkgs/tools/compression/bzip2/1_1.nix
index 3f6105ca507be..7557c5843ccc9 100644
--- a/pkgs/tools/compression/bzip2/1_1.nix
+++ b/pkgs/tools/compression/bzip2/1_1.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , meson
 , python3
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-quality data compression program";
     license = licenses.bsdOriginal;
     platforms = platforms.all;
diff --git a/pkgs/tools/compression/bzip2/default.nix b/pkgs/tools/compression/bzip2/default.nix
index 96d560145df73..7b97c66b3b903 100644
--- a/pkgs/tools/compression/bzip2/default.nix
+++ b/pkgs/tools/compression/bzip2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , linkStatic ? with stdenv.hostPlatform; isStatic || isCygwin
 , autoreconfHook
 }:
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-quality data compression program";
     license = licenses.bsdOriginal;
     platforms = platforms.all;
diff --git a/pkgs/tools/compression/dejsonlz4/default.nix b/pkgs/tools/compression/dejsonlz4/default.nix
index 7520fc824c01b..9e6f95aecb8e6 100644
--- a/pkgs/tools/compression/dejsonlz4/default.nix
+++ b/pkgs/tools/compression/dejsonlz4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 stdenv.mkDerivation rec {
     pname = "dejsonlz4";
     version = "1.1";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       cp dejsonlz4 $out/bin/
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Decompress Mozilla Firefox bookmarks backup files";
       homepage = "https://github.com/avih/dejsonlz4";
       license = licenses.bsd2;
diff --git a/pkgs/tools/compression/dtrx/default.nix b/pkgs/tools/compression/dtrx/default.nix
index 81a446066d971..0abea9b128548 100644
--- a/pkgs/tools/compression/dtrx/default.nix
+++ b/pkgs/tools/compression/dtrx/default.nix
@@ -24,7 +24,7 @@ in pythonPackages.buildPythonApplication rec {
     wrapProgram "$out/bin/dtrx" --prefix PATH : "${archivers}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Do The Right Extraction: A tool for taking the hassle out of extracting archives";
     homepage = "https://brettcsmith.org/2007/dtrx/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/compression/flips/default.nix b/pkgs/tools/compression/flips/default.nix
index 76676624fc321..e99f3fec163ef 100644
--- a/pkgs/tools/compression/flips/default.nix
+++ b/pkgs/tools/compression/flips/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gtk3, libdivsufsort, pkg-config, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, gtk3, libdivsufsort, pkg-config, wrapGAppsHook }:
 
 stdenv.mkDerivation {
   pname = "flips";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
   buildPhase = "./make.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A patcher for IPS and BPS files";
     homepage = "https://github.com/Alcaro/Flips";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/compression/hactool/default.nix b/pkgs/tools/compression/hactool/default.nix
index d34ca73556bb3..2cce7bb8b9298 100644
--- a/pkgs/tools/compression/hactool/default.nix
+++ b/pkgs/tools/compression/hactool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "hactool";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -D hactool $out/bin/hactool
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/SciresM/hactool";
     description = "A tool to manipulate common file formats for the Nintendo Switch";
     longDescription = "A tool to view information about, decrypt, and extract common file formats for the Nintendo Switch, especially Nintendo Content Archives";
diff --git a/pkgs/tools/compression/lbzip2/default.nix b/pkgs/tools/compression/lbzip2/default.nix
index 99d41c06ec647..4072dd43aef19 100644
--- a/pkgs/tools/compression/lbzip2/default.nix
+++ b/pkgs/tools/compression/lbzip2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnulib, perl, autoconf, automake }:
+{ lib, stdenv, fetchFromGitHub, gnulib, perl, autoconf, automake }:
 
 stdenv.mkDerivation rec {
   version = "2.5";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     ./build-aux/autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kjn/lbzip2"; # Formerly http://lbzip2.org/
     description = "Parallel bzip2 compression utility";
     license = licenses.gpl3;
diff --git a/pkgs/tools/compression/lz4/default.nix b/pkgs/tools/compression/lz4/default.nix
index 7fceb3854ebcd..0805045518436 100644
--- a/pkgs/tools/compression/lz4/default.nix
+++ b/pkgs/tools/compression/lz4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, valgrind, fetchpatch
+{ lib, stdenv, fetchFromGitHub, valgrind, fetchpatch
 , enableStatic ? stdenv.hostPlatform.isStatic
 , enableShared ? !stdenv.hostPlatform.isStatic
 }:
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
       moveToOutput bin "$bin"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extremely fast compression algorithm";
     longDescription = ''
       Very fast lossless compression algorithm, providing compression speed
diff --git a/pkgs/tools/compression/lzbench/default.nix b/pkgs/tools/compression/lzbench/default.nix
index 3609e53304466..93ccc67f7d142 100644
--- a/pkgs/tools/compression/lzbench/default.nix
+++ b/pkgs/tools/compression/lzbench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "lzbench";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp lzbench $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "In-memory benchmark of open-source LZ77/LZSS/LZMA compressors";
     license = licenses.free;
diff --git a/pkgs/tools/compression/lzfse/default.nix b/pkgs/tools/compression/lzfse/default.nix
index bd97620dba661..13764971bb516 100644
--- a/pkgs/tools/compression/lzfse/default.nix
+++ b/pkgs/tools/compression/lzfse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "lzfse";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/lzfse/lzfse";
     description = "a reference C implementation of the LZFSE compressor";
     longDescription = ''
diff --git a/pkgs/tools/compression/lzham/default.nix b/pkgs/tools/compression/lzham/default.nix
index e3d48702da880..7f4273163a3ec 100644
--- a/pkgs/tools/compression/lzham/default.nix
+++ b/pkgs/tools/compression/lzham/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake } :
+{ lib, stdenv, fetchFromGitHub, cmake } :
 
 stdenv.mkDerivation {
   name = "lzham-1.0";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     cp ../bin_linux/lzhamtest $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lossless data compression codec with LZMA-like ratios but 1.5x-8x faster decompression speed";
     homepage = "https://github.com/richgel999/lzham_codec";
     license = with licenses; [ mit ];
diff --git a/pkgs/tools/compression/lzop/default.nix b/pkgs/tools/compression/lzop/default.nix
index 48645942038ff..be31048c21867 100644
--- a/pkgs/tools/compression/lzop/default.nix
+++ b/pkgs/tools/compression/lzop/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, lzo}:
+{lib, stdenv, fetchurl, lzo}:
 
 stdenv.mkDerivation rec {
   name = "lzop-1.04";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ lzo ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.lzop.org";
     description = "Fast file compressor";
     license = licenses.gpl2;
diff --git a/pkgs/tools/compression/pbzip2/default.nix b/pkgs/tools/compression/pbzip2/default.nix
index 1c78d27654d27..599c096adefa2 100644
--- a/pkgs/tools/compression/pbzip2/default.nix
+++ b/pkgs/tools/compression/pbzip2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bzip2 }:
+{ lib, stdenv, fetchurl, bzip2 }:
 
 let major = "1.1";
     version = "${major}.13";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-Wno-error=reserved-user-defined-literal";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://compression.ca/pbzip2/";
     description = "A parallel implementation of bzip2 for multi-core machines";
     license = licenses.bsd2;
diff --git a/pkgs/tools/compression/pigz/default.nix b/pkgs/tools/compression/pigz/default.nix
index 07c7bf95607dd..9178e3ad58755 100644
--- a/pkgs/tools/compression/pigz/default.nix
+++ b/pkgs/tools/compression/pigz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, util-linux }:
+{ lib, stdenv, fetchurl, zlib, util-linux }:
 
 let name = "pigz";
     version = "2.4";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
       install -Dm755 pigz.pdf "$out/share/doc/pigz/pigz.pdf"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.zlib.net/pigz/";
     description = "A parallel implementation of gzip for multi-core machines";
     license = licenses.zlib;
diff --git a/pkgs/tools/compression/upx/default.nix b/pkgs/tools/compression/upx/default.nix
index 06dcaa26077a5..10e02626c0178 100644
--- a/pkgs/tools/compression/upx/default.nix
+++ b/pkgs/tools/compression/upx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ucl, zlib, perl }:
+{ lib, stdenv, fetchurl, ucl, zlib, perl }:
 
 stdenv.mkDerivation rec {
   pname = "upx";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     cp src/upx.out $out/bin/upx
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://upx.github.io/";
     description = "The Ultimate Packer for eXecutables";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/compression/xdelta/default.nix b/pkgs/tools/compression/xdelta/default.nix
index 2420f3fab61cf..b599ee2920f1b 100644
--- a/pkgs/tools/compression/xdelta/default.nix
+++ b/pkgs/tools/compression/xdelta/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, autoreconfHook
 , lzmaSupport ? true, xz ? null
 }:
 
@@ -47,7 +47,7 @@ in stdenv.mkDerivation rec {
     install -D -m644 xdelta3.1 $out/share/man/man1/xdelta3.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Binary differential compression in VCDIFF (RFC 3284) format";
     longDescription = ''
       xdelta is a command line program for delta encoding, which generates two
diff --git a/pkgs/tools/compression/xdelta/unstable.nix b/pkgs/tools/compression/xdelta/unstable.nix
index ae4a5ebac3ec6..25cd3ed311ad5 100644
--- a/pkgs/tools/compression/xdelta/unstable.nix
+++ b/pkgs/tools/compression/xdelta/unstable.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, autoreconfHook
 , lzmaSupport ? true, xz ? null
 }:
 
@@ -51,7 +51,7 @@ in stdenv.mkDerivation rec {
     install -D -m644 xdelta3.1 $out/share/man/man1/xdelta3.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Binary differential compression in VCDIFF (RFC 3284) format";
     longDescription = ''
       xdelta is a command line program for delta encoding, which generates two
diff --git a/pkgs/tools/compression/xz/default.nix b/pkgs/tools/compression/xz/default.nix
index 161619a048362..fa4a012433399 100644
--- a/pkgs/tools/compression/xz/default.nix
+++ b/pkgs/tools/compression/xz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , enableStatic ? stdenv.hostPlatform.isStatic
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   postInstall = "rm -rf $out/share/doc";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tukaani.org/xz/";
     description = "A general-purpose data compression software, successor of LZMA";
 
diff --git a/pkgs/tools/compression/zdelta/default.nix b/pkgs/tools/compression/zdelta/default.nix
index b59e7d5708bac..b3932ec3da8eb 100644
--- a/pkgs/tools/compression/zdelta/default.nix
+++ b/pkgs/tools/compression/zdelta/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   name = "zdelta-2.1";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "0k6y0r9kv5qiglnr2j4a0yvfynjkvm0pyv8ly28j0pr3w6rbxrh3";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
 	  homepage = "http://cis.poly.edu/zdelta";
     platforms = platforms.linux;
     license = licenses.zlib;
diff --git a/pkgs/tools/compression/zopfli/default.nix b/pkgs/tools/compression/zopfli/default.nix
index e897336392fdb..753368b70b978 100644
--- a/pkgs/tools/compression/zopfli/default.nix
+++ b/pkgs/tools/compression/zopfli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, cmake }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "zopfli";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp $src/src/zopfli/*.h $dev/include/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Very good, but slow, deflate or zlib compression";
     longDescription = ''
diff --git a/pkgs/tools/compression/zstd/default.nix b/pkgs/tools/compression/zstd/default.nix
index b7e068330a13d..eb4144443aec3 100644
--- a/pkgs/tools/compression/zstd/default.nix
+++ b/pkgs/tools/compression/zstd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, bash, gnugrep
+{ lib, stdenv, fetchFromGitHub, cmake, bash, gnugrep
 , fixDarwinDylibNames
 , file
 , legacySupport ? false
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
     ++ stdenv.lib.optional stdenv.hostPlatform.isUnix "man"
     ++ [ "out" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Zstandard real-time compression algorithm";
     longDescription = ''
       Zstd, short for Zstandard, is a fast lossless compression algorithm,
diff --git a/pkgs/tools/filesystems/aefs/default.nix b/pkgs/tools/filesystems/aefs/default.nix
index ea94c26248e94..ed47b8f885bd4 100644
--- a/pkgs/tools/filesystems/aefs/default.nix
+++ b/pkgs/tools/filesystems/aefs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fuse }:
+{ lib, stdenv, fetchurl, fuse }:
 
 stdenv.mkDerivation rec {
   name = "aefs-0.4pre259-8843b7c";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ fuse ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/edolstra/aefs";
     description = "A cryptographic filesystem implemented in userspace using FUSE";
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/afpfs-ng/default.nix b/pkgs/tools/filesystems/afpfs-ng/default.nix
index 3340bdba0e6d8..9c4268e402dad 100644
--- a/pkgs/tools/filesystems/afpfs-ng/default.nix
+++ b/pkgs/tools/filesystems/afpfs-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fuse, readline, libgcrypt, gmp }:
+{ lib, stdenv, fetchFromGitHub, fuse, readline, libgcrypt, gmp }:
 
 stdenv.mkDerivation {
   pname = "afpfs-ng";
@@ -13,7 +13,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ fuse readline libgcrypt gmp ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/simonvetter/afpfs-ng";
     description = "A client implementation of the Apple Filing Protocol";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/android-file-transfer/default.nix b/pkgs/tools/filesystems/android-file-transfer/default.nix
index b52099bdeab85..59add4b4c21c0 100644
--- a/pkgs/tools/filesystems/android-file-transfer/default.nix
+++ b/pkgs/tools/filesystems/android-file-transfer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, fuse, readline, pkgconfig, qtbase, qttools }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, fuse, readline, pkgconfig, qtbase, qttools }:
 
 mkDerivation rec {
   pname = "android-file-transfer";
@@ -14,7 +14,7 @@ mkDerivation rec {
   nativeBuildInputs = [ cmake readline pkgconfig ];
   buildInputs = [ fuse qtbase qttools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reliable MTP client with minimalistic UI";
     homepage = "https://whoozle.github.io/android-file-transfer-linux/";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/tools/filesystems/apfs-fuse/default.nix b/pkgs/tools/filesystems/apfs-fuse/default.nix
index 32cde83d749a2..adf845f943ea1 100644
--- a/pkgs/tools/filesystems/apfs-fuse/default.nix
+++ b/pkgs/tools/filesystems/apfs-fuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fuse3, bzip2, zlib, attr, cmake }:
+{ lib, stdenv, fetchFromGitHub, fuse3, bzip2, zlib, attr, cmake }:
 
 stdenv.mkDerivation {
   pname = "apfs-fuse-unstable";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     ln -s $out/bin/apfs-fuse $out/bin/mount.fuse.apfs-fuse
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/sgan81/apfs-fuse";
     description = "FUSE driver for APFS (Apple File System)";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/bashmount/default.nix b/pkgs/tools/filesystems/bashmount/default.nix
index bab8df1280dd8..ef7bfd492e37a 100644
--- a/pkgs/tools/filesystems/bashmount/default.nix
+++ b/pkgs/tools/filesystems/bashmount/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub}:
+{lib, stdenv, fetchFromGitHub}:
 
 stdenv.mkDerivation rec {
   pname = "bashmount";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     cp NEWS    $out/share/doc/bashmount
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jamielinux/bashmount";
     description = "A menu-driven bash script for the management of removable media with udisks";
     maintainers = [ maintainers.koral ];
diff --git a/pkgs/tools/filesystems/bcache-tools/default.nix b/pkgs/tools/filesystems/bcache-tools/default.nix
index 6e39ff1745885..f9c2b470026f8 100644
--- a/pkgs/tools/filesystems/bcache-tools/default.nix
+++ b/pkgs/tools/filesystems/bcache-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, util-linux, bash }:
+{ lib, stdenv, fetchurl, pkgconfig, util-linux, bash }:
 
 stdenv.mkDerivation rec {
   pname = "bcache-tools";
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/sbin" "$out/lib/udev/rules.d" "$out/share/man/man8"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "User-space tools required for bcache (Linux block layer cache)";
     longDescription = ''
       Bcache is a Linux kernel block layer cache. It allows one or more fast
diff --git a/pkgs/tools/filesystems/bcachefs-tools/default.nix b/pkgs/tools/filesystems/bcachefs-tools/default.nix
index 5b2a4e3224213..869d2782855c0 100644
--- a/pkgs/tools/filesystems/bcachefs-tools/default.nix
+++ b/pkgs/tools/filesystems/bcachefs-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, attr, libuuid, libscrypt, libsodium, keyutils
+{ lib, stdenv, fetchFromGitHub, pkgconfig, attr, libuuid, libscrypt, libsodium, keyutils
 , liburcu, zlib, libaio, udev, zstd, lz4, valgrind, python3Packages
 , fuseSupport ? false, fuse3 ? null }:
 
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
 
   installFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for managing bcachefs filesystems";
     homepage = "https://bcachefs.org/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/bees/default.nix b/pkgs/tools/filesystems/bees/default.nix
index bdca893a136cf..bbad83f017688 100644
--- a/pkgs/tools/filesystems/bees/default.nix
+++ b/pkgs/tools/filesystems/bees/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, runCommand, fetchFromGitHub, bash, btrfs-progs, coreutils, python3Packages, util-linux }:
+{ lib, stdenv, runCommand, fetchFromGitHub, bash, btrfs-progs, coreutils, python3Packages, util-linux }:
 
 let
 
@@ -43,7 +43,7 @@ let
       "SYSTEMD_SYSTEM_UNIT_DIR=$(out)/etc/systemd/system"
     ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/Zygo/bees";
       description = "Block-oriented BTRFS deduplication service";
       license = licenses.gpl3;
diff --git a/pkgs/tools/filesystems/blobfuse/default.nix b/pkgs/tools/filesystems/blobfuse/default.nix
index 3c6f622832935..2156758f68e19 100644
--- a/pkgs/tools/filesystems/blobfuse/default.nix
+++ b/pkgs/tools/filesystems/blobfuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, curl, gnutls, libgcrypt, libuuid, fuse }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, curl, gnutls, libgcrypt, libuuid, fuse }:
 
 stdenv.mkDerivation rec {
   pname = "blobfuse";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ curl gnutls libgcrypt libuuid fuse ];
   nativeBuildInputs = [ cmake pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mount an Azure Blob storage as filesystem through FUSE";
     license = licenses.mit;
     maintainers = with maintainers; [ jbgi ];
diff --git a/pkgs/tools/filesystems/boxfs/default.nix b/pkgs/tools/filesystems/boxfs/default.nix
index 5dba4b4bbf1ae..4ccec06050d43 100644
--- a/pkgs/tools/filesystems/boxfs/default.nix
+++ b/pkgs/tools/filesystems/boxfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, curl, fuse, libxml2, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, curl, fuse, libxml2, pkgconfig }:
 
 let
   srcs = {
@@ -44,7 +44,7 @@ in stdenv.mkDerivation {
     install boxfs boxfs-init $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE file system for box.com accounts";
     longDescription = ''
       Store files on box.com (an account is required). The first time you run
diff --git a/pkgs/tools/filesystems/btrfs-progs/default.nix b/pkgs/tools/filesystems/btrfs-progs/default.nix
index 03db1d913e2b8..469a499b55491 100644
--- a/pkgs/tools/filesystems/btrfs-progs/default.nix
+++ b/pkgs/tools/filesystems/btrfs-progs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, attr, acl, zlib, libuuid, e2fsprogs, lzo
+{ lib, stdenv, fetchurl, pkgconfig, attr, acl, zlib, libuuid, e2fsprogs, lzo
 , asciidoc, xmlto, docbook_xml_dtd_45, docbook_xsl, libxslt, zstd, python3
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = stdenv.lib.optional stdenv.hostPlatform.isMusl "--disable-backtrace";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for the btrfs filesystem";
     homepage = "https://btrfs.wiki.kernel.org/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/catcli/default.nix b/pkgs/tools/filesystems/catcli/default.nix
index 25de04467ef97..f5dbabaf5834b 100644
--- a/pkgs/tools/filesystems/catcli/default.nix
+++ b/pkgs/tools/filesystems/catcli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonApplication
 , docopt, anytree
@@ -20,7 +20,7 @@ buildPythonApplication rec {
 
   postPatch = '' patchShebangs . '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The command line catalog tool for your offline data";
     homepage = "https://github.com/deadc0de6/catcli";
     license = licenses.gpl3;
diff --git a/pkgs/tools/filesystems/convoy/default.nix b/pkgs/tools/filesystems/convoy/default.nix
index 3372ec835304c..4c493ea225276 100644
--- a/pkgs/tools/filesystems/convoy/default.nix
+++ b/pkgs/tools/filesystems/convoy/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by go2nix.
-{ stdenv, buildGoPackage, fetchFromGitHub, lvm2 }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, lvm2 }:
 
 buildGoPackage rec {
   pname = "convoy";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   buildInputs = [lvm2];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rancher/convoy";
     description = "A Docker volume plugin, managing persistent container volumes";
     license = licenses.asl20;
diff --git a/pkgs/tools/filesystems/cpcfs/default.nix b/pkgs/tools/filesystems/cpcfs/default.nix
index 1c639dfc29ec8..2aa63208e0086 100644
--- a/pkgs/tools/filesystems/cpcfs/default.nix
+++ b/pkgs/tools/filesystems/cpcfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, ncurses, readline, ronn }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, ncurses, readline, ronn }:
 
 stdenv.mkDerivation rec {
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manipulating CPC dsk images and files";
     homepage = "https://github.com/derikz/cpcfs/" ;
     license = licenses.bsd2;
diff --git a/pkgs/tools/filesystems/cryfs/default.nix b/pkgs/tools/filesystems/cryfs/default.nix
index ef95bad0c2412..5573acc1a8cf8 100644
--- a/pkgs/tools/filesystems/cryfs/default.nix
+++ b/pkgs/tools/filesystems/cryfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , cmake, pkgconfig, python, gtest
 , boost, cryptopp, curl, fuse, openssl
 }:
@@ -66,7 +66,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cryptographic filesystem for the cloud";
     homepage    = "https://www.cryfs.org";
     license     = licenses.lgpl3;
diff --git a/pkgs/tools/filesystems/curlftpfs/default.nix b/pkgs/tools/filesystems/curlftpfs/default.nix
index a0306693b28e9..3e59a286be32b 100644
--- a/pkgs/tools/filesystems/curlftpfs/default.nix
+++ b/pkgs/tools/filesystems/curlftpfs/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, fuse, curl, pkgconfig, glib, zlib}:
+{lib, stdenv, fetchurl, fuse, curl, pkgconfig, glib, zlib}:
 
 stdenv.mkDerivation {
   name = "curlftpfs-0.9.2";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
 
   doCheck = false; # fails, doesn't work well too, btw
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Filesystem for accessing FTP hosts based on FUSE and libcurl";
     homepage = "http://curlftpfs.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/darling-dmg/default.nix b/pkgs/tools/filesystems/darling-dmg/default.nix
index 42853eb8ff97a..b5addf833c1b9 100644
--- a/pkgs/tools/filesystems/darling-dmg/default.nix
+++ b/pkgs/tools/filesystems/darling-dmg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, fuse, zlib, bzip2, openssl, libxml2, icu, lzfse }:
+{ lib, stdenv, fetchFromGitHub, cmake, fuse, zlib, bzip2, openssl, libxml2, icu, lzfse }:
 
 stdenv.mkDerivation rec {
   pname = "darling-dmg";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     "-llzfse"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.darlinghq.org/";
     description = "Darling lets you open macOS dmgs on Linux";
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/dislocker/default.nix b/pkgs/tools/filesystems/dislocker/default.nix
index e1f28a0f2792b..e65e4665bd562 100644
--- a/pkgs/tools/filesystems/dislocker/default.nix
+++ b/pkgs/tools/filesystems/dislocker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , mbedtls
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ fuse mbedtls ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Read BitLocker encrypted partitions in Linux";
     homepage    = "https://github.com/aorimn/dislocker";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/disorderfs/default.nix b/pkgs/tools/filesystems/disorderfs/default.nix
index 5137719790afd..849360f537414 100644
--- a/pkgs/tools/filesystems/disorderfs/default.nix
+++ b/pkgs/tools/filesystems/disorderfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, fuse, attr, asciidoc }:
+{ lib, stdenv, fetchurl, pkgconfig, fuse, attr, asciidoc }:
 
 stdenv.mkDerivation rec {
   pname = "disorderfs";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An overlay FUSE filesystem that introduces non-determinism into filesystem metadata";
     license = licenses.gpl3;
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/duff/default.nix b/pkgs/tools/filesystems/duff/default.nix
index 48511b97c04e4..f980c76133326 100644
--- a/pkgs/tools/filesystems/duff/default.nix
+++ b/pkgs/tools/filesystems/duff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, gettext }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, gettext }:
 
 stdenv.mkDerivation {
   pname = "duff";
@@ -27,7 +27,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quickly find duplicate files";
     longDescription = ''
       Duff is a Unix command-line utility for quickly finding duplicates in
diff --git a/pkgs/tools/filesystems/duperemove/default.nix b/pkgs/tools/filesystems/duperemove/default.nix
index 3d70f2f73c7f3..62df5ee07c683 100644
--- a/pkgs/tools/filesystems/duperemove/default.nix
+++ b/pkgs/tools/filesystems/duperemove/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libgcrypt
+{ lib, stdenv, fetchFromGitHub, libgcrypt
 , pkgconfig, glib, linuxHeaders ? stdenv.cc.libc.linuxHeaders, sqlite }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple tool for finding duplicated extents and submitting them for deduplication";
     homepage = "https://github.com/markfasheh/duperemove";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/e2fsprogs/default.nix b/pkgs/tools/filesystems/e2fsprogs/default.nix
index f26a41ce14265..d48c92ebfc36d 100644
--- a/pkgs/tools/filesystems/e2fsprogs/default.nix
+++ b/pkgs/tools/filesystems/e2fsprogs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchurl, fetchpatch, pkgconfig, libuuid, gettext, texinfo
+{ lib, stdenv, buildPackages, fetchurl, fetchpatch, pkgconfig, libuuid, gettext, texinfo
 , shared ? !stdenv.hostPlatform.isStatic
 }:
 
@@ -65,7 +65,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://e2fsprogs.sourceforge.net/";
     description = "Tools for creating and checking ext2/ext3/ext4 filesystems";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/encfs/default.nix b/pkgs/tools/filesystems/encfs/default.nix
index 57affc2603e50..4d28fc6a9e866 100644
--- a/pkgs/tools/filesystems/encfs/default.nix
+++ b/pkgs/tools/filesystems/encfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, pkgconfig, perl
 , gettext, fuse, openssl, tinyxml2
 }:
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
       "-DINSTALL_LIBENCFS=ON"
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An encrypted filesystem in user-space via FUSE";
     homepage = "https://vgough.github.io/encfs";
     license = with licenses; [ gpl3 lgpl3 ];
diff --git a/pkgs/tools/filesystems/exfat/default.nix b/pkgs/tools/filesystems/exfat/default.nix
index 24db663aee02c..2d6eaf8e97850 100644
--- a/pkgs/tools/filesystems/exfat/default.nix
+++ b/pkgs/tools/filesystems/exfat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, fuse }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, fuse }:
 
 stdenv.mkDerivation rec {
   pname = "exfat";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ fuse ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free exFAT file system implementation";
     inherit (src.meta) homepage;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/filesystems/ext4magic/default.nix b/pkgs/tools/filesystems/ext4magic/default.nix
index 19e0e4ee63ec4..a5f15c5fb2ea2 100644
--- a/pkgs/tools/filesystems/ext4magic/default.nix
+++ b/pkgs/tools/filesystems/ext4magic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, file, libuuid, e2fsprogs, zlib, bzip2 }:
+{ lib, stdenv, fetchurl, fetchpatch, file, libuuid, e2fsprogs, zlib, bzip2 }:
 
 stdenv.mkDerivation rec {
   version = "0.3.2";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ file libuuid e2fsprogs zlib bzip2 ];
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recover / undelete files from ext3 or ext4 partitions";
     longDescription = ''
       ext4magic can recover/undelete files from ext3 or ext4 partitions
diff --git a/pkgs/tools/filesystems/extundelete/default.nix b/pkgs/tools/filesystems/extundelete/default.nix
index 447f7a656d127..5992fd6a78e4b 100644
--- a/pkgs/tools/filesystems/extundelete/default.nix
+++ b/pkgs/tools/filesystems/extundelete/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, e2fsprogs }:
+{ lib, stdenv, fetchurl, e2fsprogs }:
 
 stdenv.mkDerivation {
   version = "0.2.4";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
       --replace "inode.i_dir_acl" "inode.i_size_high"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility that can recover deleted files from an ext3 or ext4 partition";
     homepage = "http://extundelete.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/f2fs-tools/default.nix b/pkgs/tools/filesystems/f2fs-tools/default.nix
index af30751b885b1..35a087dbd7b9b 100644
--- a/pkgs/tools/filesystems/f2fs-tools/default.nix
+++ b/pkgs/tools/filesystems/f2fs-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, libselinux, libuuid, pkgconfig }:
+{ lib, stdenv, fetchgit, autoreconfHook, libselinux, libuuid, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "f2fs-tools";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   patches = [ ./f2fs-tools-cross-fix.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://git.kernel.org/cgit/linux/kernel/git/jaegeuk/f2fs-tools.git/";
     description = "Userland tools for the f2fs filesystem";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/fatresize/default.nix b/pkgs/tools/filesystems/fatresize/default.nix
index c8366a96f0750..8f258a79f7dea 100644
--- a/pkgs/tools/filesystems/fatresize/default.nix
+++ b/pkgs/tools/filesystems/fatresize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, parted, util-linux, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, parted, util-linux, pkg-config }:
 
 stdenv.mkDerivation rec {
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   propagatedBuildInputs = [ parted util-linux ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The FAT16/FAT32 non-destructive resizer";
     homepage = "https://github.com/ya-mouse/fatresize";
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/fatsort/default.nix b/pkgs/tools/filesystems/fatsort/default.nix
index 90ab3a6df415f..ec7563dfc4945 100644
--- a/pkgs/tools/filesystems/fatsort/default.nix
+++ b/pkgs/tools/filesystems/fatsort/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, help2man}:
+{lib, stdenv, fetchurl, help2man}:
 
 stdenv.mkDerivation rec {
   version = "1.6.3.622";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fatsort.sourceforge.net/";
     description = "Sorts FAT partition table, for devices that don't do sorting of files";
     maintainers = [ maintainers.kovirobi ];
diff --git a/pkgs/tools/filesystems/file-rename/default.nix b/pkgs/tools/filesystems/file-rename/default.nix
index 588295f779122..6ddf5d7886335 100644
--- a/pkgs/tools/filesystems/file-rename/default.nix
+++ b/pkgs/tools/filesystems/file-rename/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, makeWrapper }:
+{ lib, stdenv, fetchurl, perlPackages, makeWrapper }:
 
 perlPackages.buildPerlPackage {
   pname = "File-Rename";
@@ -24,7 +24,7 @@ perlPackages.buildPerlPackage {
 
   doCheck = !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Perl extension for renaming multiple files";
     license = licenses.artistic1;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/tools/filesystems/fuse-7z-ng/default.nix b/pkgs/tools/filesystems/fuse-7z-ng/default.nix
index a8eb1118f4d36..b9edd4799bc84 100644
--- a/pkgs/tools/filesystems/fuse-7z-ng/default.nix
+++ b/pkgs/tools/filesystems/fuse-7z-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fuse, p7zip, autoconf, automake, pkgconfig, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, fuse, p7zip, autoconf, automake, pkgconfig, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "fuse-7z-ng";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp TODO README NEWS COPYING ChangeLog AUTHORS $out/share/doc/${pname}/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     inherit (src.homepage);
     description = "A FUSE-based filesystem that uses the p7zip library";
diff --git a/pkgs/tools/filesystems/fuse-overlayfs/default.nix b/pkgs/tools/filesystems/fuse-overlayfs/default.nix
index 4aafe8d6d6282..25e2cc29bd756 100644
--- a/pkgs/tools/filesystems/fuse-overlayfs/default.nix
+++ b/pkgs/tools/filesystems/fuse-overlayfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkg-config, fuse3, nixosTests }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config, fuse3, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "fuse-overlayfs";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests = { inherit (nixosTests) podman; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE implementation for overlayfs";
     longDescription = "An implementation of overlay+shiftfs in FUSE for rootless containers.";
     license = licenses.gpl3;
diff --git a/pkgs/tools/filesystems/fuseiso/default.nix b/pkgs/tools/filesystems/fuseiso/default.nix
index 0a4472d7123df..f8c4ead50f21d 100644
--- a/pkgs/tools/filesystems/fuseiso/default.nix
+++ b/pkgs/tools/filesystems/fuseiso/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, autoreconfHook, pkgconfig, fuse, glib, zlib }:
+{ lib, stdenv, fetchurl, fetchpatch, autoreconfHook, pkgconfig, fuse, glib, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "fuseiso";
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     install -Dm444 -t $out/share/doc/${pname} NEWS README
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE module to mount ISO filesystem images";
     homepage = "https://sourceforge.net/projects/fuseiso";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/genext2fs/default.nix b/pkgs/tools/filesystems/genext2fs/default.nix
index 8d0c0325aa9d8..b4980e83bee5b 100644
--- a/pkgs/tools/filesystems/genext2fs/default.nix
+++ b/pkgs/tools/filesystems/genext2fs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "genext2fs-1.4.1";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     sed -e 's@4 [*] (EXT2_TIND_BLOCK+1)@-1+&@' -i genext2fs.c
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://genext2fs.sourceforge.net/";
     description = "A tool to generate ext2 filesystem images without requiring root privileges";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/genimage/default.nix b/pkgs/tools/filesystems/genimage/default.nix
index c3b867fbb601d..23c38e6a6d360 100644
--- a/pkgs/tools/filesystems/genimage/default.nix
+++ b/pkgs/tools/filesystems/genimage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libconfuse, gettext }:
+{ lib, stdenv, fetchurl, pkgconfig, libconfuse, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "genimage";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp -v README "$docdir"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://git.pengutronix.de/cgit/genimage";
     description = "Generate filesystem images from directory trees";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/filesystems/genromfs/default.nix b/pkgs/tools/filesystems/genromfs/default.nix
index 4adf124d529ff..205d84791ec96 100644
--- a/pkgs/tools/filesystems/genromfs/default.nix
+++ b/pkgs/tools/filesystems/genromfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "0.5.2";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
       --replace "gcc" "cc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://romfs.sourceforge.net/";
     description = "Tool for creating romfs file system images";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/glusterfs/default.nix b/pkgs/tools/filesystems/glusterfs/default.nix
index a4e6bc1182be6..d23faf16886f6 100644
--- a/pkgs/tools/filesystems/glusterfs/default.nix
+++ b/pkgs/tools/filesystems/glusterfs/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, fuse, bison, flex_2_5_35, openssl, python3, ncurses, readline,
+{lib, stdenv, fetchFromGitHub, fuse, bison, flex_2_5_35, openssl, python3, ncurses, readline,
  autoconf, automake, libtool, pkgconfig, zlib, libaio, libxml2, acl, sqlite,
  liburcu, attr, makeWrapper, coreutils, gnused, gnugrep, which,
  openssh, gawk, findutils, util-linux, lvm2, btrfs-progs, e2fsprogs, xfsprogs, systemd,
@@ -180,7 +180,7 @@ in stdenv.mkDerivation rec {
     rm -r $out/bin/conf.py
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Distributed storage system";
     homepage = "https://www.gluster.org";
     license = licenses.lgpl3Plus; # dual licese: choice of lgpl3Plus or gpl2
diff --git a/pkgs/tools/filesystems/gocryptfs/default.nix b/pkgs/tools/filesystems/gocryptfs/default.nix
index bed971229cd68..318e39e8322e9 100644
--- a/pkgs/tools/filesystems/gocryptfs/default.nix
+++ b/pkgs/tools/filesystems/gocryptfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , openssl
@@ -41,7 +41,7 @@ buildGoModule rec {
     popd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Encrypted overlay filesystem written in Go";
     license = licenses.mit;
     homepage = "https://nuetzlich.net/gocryptfs/";
diff --git a/pkgs/tools/filesystems/gpart/default.nix b/pkgs/tools/filesystems/gpart/default.nix
index 59b4785888b27..eafbe066ac94e 100644
--- a/pkgs/tools/filesystems/gpart/default.nix
+++ b/pkgs/tools/filesystems/gpart/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "gpart";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Guess PC-type hard disk partitions";
     longDescription = ''
diff --git a/pkgs/tools/filesystems/grive2/default.nix b/pkgs/tools/filesystems/grive2/default.nix
index 01b63003d62d1..7392b4748407f 100644
--- a/pkgs/tools/filesystems/grive2/default.nix
+++ b/pkgs/tools/filesystems/grive2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, yajl, cmake, libgcrypt, curl, expat, boost, libiberty }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, yajl, cmake, libgcrypt, curl, expat, boost, libiberty }:
 
 stdenv.mkDerivation rec {
   version = "0.5.1";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libgcrypt yajl curl expat stdenv boost libiberty ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A console Google Drive client";
     homepage = "https://github.com/vitalif/grive2";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/hubicfuse/default.nix b/pkgs/tools/filesystems/hubicfuse/default.nix
index 5bb8b4e91e2b1..5bd140e6cdfcd 100644
--- a/pkgs/tools/filesystems/hubicfuse/default.nix
+++ b/pkgs/tools/filesystems/hubicfuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, curl, openssl, fuse, libxml2, json_c, file }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, curl, openssl, fuse, libxml2, json_c, file }:
 
 stdenv.mkDerivation rec {
   pname = "hubicfuse";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     ln -sf $out/bin/hubicfuse $out/sbin/mount.hubicfuse
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/TurboGit/hubicfuse";
     description = "FUSE-based filesystem to access hubic cloud storage";
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/idsk/default.nix b/pkgs/tools/filesystems/idsk/default.nix
index a8e2cc3f09743..12a0af7ea4d3e 100644
--- a/pkgs/tools/filesystems/idsk/default.nix
+++ b/pkgs/tools/filesystems/idsk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     cp iDSK $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manipulating CPC dsk images and files";
     homepage = "https://github.com/cpcsdk/idsk" ;
     license = licenses.mit;
diff --git a/pkgs/tools/filesystems/ifuse/default.nix b/pkgs/tools/filesystems/ifuse/default.nix
index 96a8c1d630d9c..b262080d1826c 100644
--- a/pkgs/tools/filesystems/ifuse/default.nix
+++ b/pkgs/tools/filesystems/ifuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, usbmuxd, fuse, libimobiledevice }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, usbmuxd, fuse, libimobiledevice }:
 
 stdenv.mkDerivation rec {
   pname = "ifuse";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook pkgconfig fuse usbmuxd libimobiledevice ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/libimobiledevice/ifuse";
     description = "A fuse filesystem implementation to access the contents of iOS devices";
     longDescription = ''
diff --git a/pkgs/tools/filesystems/jfsutils/default.nix b/pkgs/tools/filesystems/jfsutils/default.nix
index 954393e45897d..fadc639fbf633 100644
--- a/pkgs/tools/filesystems/jfsutils/default.nix
+++ b/pkgs/tools/filesystems/jfsutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, libuuid, autoreconfHook }:
+{ lib, stdenv, fetchurl, fetchpatch, libuuid, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   name = "jfsutils-1.1.15";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ libuuid ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IBM JFS utilities";
     homepage = "http://jfs.sourceforge.net";
     license = licenses.gpl3;
diff --git a/pkgs/tools/filesystems/jmtpfs/default.nix b/pkgs/tools/filesystems/jmtpfs/default.nix
index 56afb8f0f55db..fe45c9539888a 100644
--- a/pkgs/tools/filesystems/jmtpfs/default.nix
+++ b/pkgs/tools/filesystems/jmtpfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, file, fuse, libmtp }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, file, fuse, libmtp }:
 
 let version = "0.5"; in
 stdenv.mkDerivation {
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ file fuse libmtp ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A FUSE filesystem for MTP devices like Android phones";
     homepage = "https://github.com/JasonFerrara/jmtpfs";
     license = licenses.gpl3;
diff --git a/pkgs/tools/filesystems/lizardfs/default.nix b/pkgs/tools/filesystems/lizardfs/default.nix
index e0bb39a6f0bc3..785a9225cf32f 100644
--- a/pkgs/tools/filesystems/lizardfs/default.nix
+++ b/pkgs/tools/filesystems/lizardfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , cmake
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     zlib boost judy pam spdlog fmt python3 systemdMinimal
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://lizardfs.com";
     description = "A highly reliable, scalable and efficient distributed file system";
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/mergerfs/tools.nix b/pkgs/tools/filesystems/mergerfs/tools.nix
index 44337cf11619c..2b3f6a8b3cbf2 100644
--- a/pkgs/tools/filesystems/mergerfs/tools.nix
+++ b/pkgs/tools/filesystems/mergerfs/tools.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, coreutils, makeWrapper
+{ lib, stdenv, fetchFromGitHub, coreutils, makeWrapper
 , rsync, python3, pythonPackages }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/mergerfs.mktrash --prefix PATH : ${makeBinPath [ pythonPackages.xattr ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optional tools to help manage data in a mergerfs pool";
     homepage = "https://github.com/trapexit/mergerfs-tools";
     license = licenses.isc;
diff --git a/pkgs/tools/filesystems/mkspiffs/default.nix b/pkgs/tools/filesystems/mkspiffs/default.nix
index 086791de787a2..30312ec7dc7bf 100644
--- a/pkgs/tools/filesystems/mkspiffs/default.nix
+++ b/pkgs/tools/filesystems/mkspiffs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, git }:
+{ lib, stdenv, fetchFromGitHub, git }:
 
 # Changing the variables CPPFLAGS and BUILD_CONFIG_NAME can be done by
 # overriding the same-named attributes. See ./presets.nix for examples.
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp mkspiffs $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to build and unpack SPIFFS images";
     license = licenses.mit;
     homepage = "https://github.com/igrr/mkspiffs";
diff --git a/pkgs/tools/filesystems/moosefs/default.nix b/pkgs/tools/filesystems/moosefs/default.nix
index 48c005e1caaf9..0d0f13b7c2bfd 100644
--- a/pkgs/tools/filesystems/moosefs/default.nix
+++ b/pkgs/tools/filesystems/moosefs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , makeWrapper
 , python
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/sbin/mfscgiserv --replace "datapath=\"$out" "datapath=\""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://moosefs.com";
     description = "Open Source, Petabyte, Fault-Tolerant, Highly Performing, Scalable Network Distributed File System";
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/mp3fs/default.nix b/pkgs/tools/filesystems/mp3fs/default.nix
index 9675f44583a31..12b64573c40de 100644
--- a/pkgs/tools/filesystems/mp3fs/default.nix
+++ b/pkgs/tools/filesystems/mp3fs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, flac, fuse, lame, libid3tag, pkgconfig }:
+{ lib, stdenv, fetchurl, flac, fuse, lame, libid3tag, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "mp3fs";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE file system that transparently transcodes to MP3";
     longDescription = ''
       A read-only FUSE filesystem which transcodes between audio formats
diff --git a/pkgs/tools/filesystems/mtools/default.nix b/pkgs/tools/filesystems/mtools/default.nix
index 5f78b3c379d2d..b2cac0f759060 100644
--- a/pkgs/tools/filesystems/mtools/default.nix
+++ b/pkgs/tools/filesystems/mtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "mtools";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/mtools/";
     description = "Utilities to access MS-DOS disks";
     platforms = platforms.unix;
diff --git a/pkgs/tools/filesystems/mtpfs/default.nix b/pkgs/tools/filesystems/mtpfs/default.nix
index bede0e5fca01a..295b7a0e5e504 100644
--- a/pkgs/tools/filesystems/mtpfs/default.nix
+++ b/pkgs/tools/filesystems/mtpfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, fuse, libmtp, glib, libmad, libid3tag }:
+{ lib, stdenv, fetchurl, pkgconfig, fuse, libmtp, glib, libmad, libid3tag }:
 
 stdenv.mkDerivation rec {
   name = "mtpfs-1.1";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     sha256 = "07acrqb17kpif2xcsqfqh5j4axvsa4rnh6xwnpqab5b9w5ykbbqv";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cjd/mtpfs";
     description = "FUSE Filesystem providing access to MTP devices";
     platforms = platforms.all;
diff --git a/pkgs/tools/filesystems/nilfs-utils/default.nix b/pkgs/tools/filesystems/nilfs-utils/default.nix
index dd8116ff40130..72d07ed192206 100644
--- a/pkgs/tools/filesystems/nilfs-utils/default.nix
+++ b/pkgs/tools/filesystems/nilfs-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, libuuid, libselinux }:
+{ lib, stdenv, fetchurl, fetchpatch, libuuid, libselinux }:
 let
   sourceInfo = rec {
     version = "2.2.7";
@@ -52,7 +52,7 @@ stdenv.mkDerivation {
     find . -name .libs | xargs rm -rf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NILFS utilities";
     maintainers = [ maintainers.raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/nixpart/0.4/blivet.nix b/pkgs/tools/filesystems/nixpart/0.4/blivet.nix
index 15d6686fbc33a..17a324525f8fe 100644
--- a/pkgs/tools/filesystems/nixpart/0.4/blivet.nix
+++ b/pkgs/tools/filesystems/nixpart/0.4/blivet.nix
@@ -1,6 +1,6 @@
 # FIXME: Unify with pkgs/development/python-modules/blivet/default.nix.
 
-{ stdenv, fetchurl, buildPythonApplication, pykickstart, pyparted, pyblock
+{ lib, stdenv, fetchurl, buildPythonApplication, pykickstart, pyparted, pyblock
 , libselinux, cryptsetup, multipath_tools, lsof, util-linux
 , useNixUdev ? true, systemd ? null
 # useNixUdev is here for bw compatibility
@@ -41,7 +41,7 @@ buildPythonApplication rec {
   # tests are currently _heavily_ broken upstream
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fedoraproject.org/wiki/Blivet";
     description = "Module for management of a system's storage configuration";
     license = with licenses; [ gpl2Plus lgpl21Plus ];
diff --git a/pkgs/tools/filesystems/nixpart/0.4/default.nix b/pkgs/tools/filesystems/nixpart/0.4/default.nix
index 703d918f92a98..3ad9de468b4a0 100644
--- a/pkgs/tools/filesystems/nixpart/0.4/default.nix
+++ b/pkgs/tools/filesystems/nixpart/0.4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python, buildPythonApplication
+{ lib, stdenv, fetchurl, python, buildPythonApplication
 , libselinux
 # Propagated to blivet
 , useNixUdev ? true
@@ -67,7 +67,7 @@ in buildPythonApplication rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NixOS storage manager/partitioner";
     homepage = "https://github.com/NixOS/nixpart";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/filesystems/ntfs-3g/default.nix b/pkgs/tools/filesystems/ntfs-3g/default.nix
index 2065e31e97a08..30c7aa7ba3641 100644
--- a/pkgs/tools/filesystems/ntfs-3g/default.nix
+++ b/pkgs/tools/filesystems/ntfs-3g/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, util-linux, libuuid
+{lib, stdenv, fetchurl, util-linux, libuuid
 , crypto ? false, libgcrypt, gnutls, pkgconfig}:
 
 stdenv.mkDerivation rec {
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
       ln -sv mount.ntfs-3g $out/sbin/mount.ntfs
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.tuxera.com/community/open-source-ntfs-3g/";
     description = "FUSE-based NTFS driver with full write support";
     maintainers = with maintainers; [ dezgeg ];
diff --git a/pkgs/tools/filesystems/orangefs/default.nix b/pkgs/tools/filesystems/orangefs/default.nix
index 8c1378d97bc42..1b10941f13922 100644
--- a/pkgs/tools/filesystems/orangefs/default.nix
+++ b/pkgs/tools/filesystems/orangefs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bison, flex, autoreconfHook
+{ lib, stdenv, fetchurl, bison, flex, autoreconfHook
 , openssl, db, attr, perl, tcsh
 } :
 
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     sed -i 's:openssl:${openssl}/bin/openssl:' $out/bin/pvfs2-gen-keys.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scale-out network file system for use on high-end computing systems";
     homepage = "http://www.orangefs.org/";
     license = with licenses;  [ asl20 bsd3 gpl2 lgpl21 lgpl21Plus openldap ];
diff --git a/pkgs/tools/filesystems/rar2fs/default.nix b/pkgs/tools/filesystems/rar2fs/default.nix
index 889f075645a3f..a3056a80aa1fb 100644
--- a/pkgs/tools/filesystems/rar2fs/default.nix
+++ b/pkgs/tools/filesystems/rar2fs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , fuse
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     "--disable-static-unrar"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE file system for reading RAR archives";
     homepage = "https://hasse69.github.io/rar2fs/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/filesystems/rdfind/default.nix b/pkgs/tools/filesystems/rdfind/default.nix
index 54cb54b1df4b6..62d602f068080 100644
--- a/pkgs/tools/filesystems/rdfind/default.nix
+++ b/pkgs/tools/filesystems/rdfind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nettle }:
+{ lib, stdenv, fetchurl, nettle }:
 
 stdenv.mkDerivation rec {
   pname = "rdfind";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ nettle ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://rdfind.pauldreik.se/";
     description = "Removes or hardlinks duplicate files very swiftly";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/tools/filesystems/reiser4progs/default.nix b/pkgs/tools/filesystems/reiser4progs/default.nix
index 158097d381297..46c0120f64c4c 100644
--- a/pkgs/tools/filesystems/reiser4progs/default.nix
+++ b/pkgs/tools/filesystems/reiser4progs/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, libaal}:
+{lib, stdenv, fetchurl, libaal}:
 
 let version = "2.0.1"; in
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     substituteInPlace Makefile --replace ./run-ldconfig true
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     homepage = "https://sourceforge.net/projects/reiser4/";
     description = "Reiser4 utilities";
diff --git a/pkgs/tools/filesystems/rmount/default.nix b/pkgs/tools/filesystems/rmount/default.nix
index 529fc0244916a..fb1e1a5539a28 100644
--- a/pkgs/tools/filesystems/rmount/default.nix
+++ b/pkgs/tools/filesystems/rmount/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, nmap, jq, cifs-utils, sshfs, fetchFromGitHub, makeWrapper }:
+{ lib, stdenv, nmap, jq, cifs-utils, sshfs, fetchFromGitHub, makeWrapper }:
 
 stdenv.mkDerivation rec {
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/rmount --prefix PATH : ${stdenv.lib.makeBinPath [ nmap jq cifs-utils sshfs ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Luis-Hebendanz/rmount";
     description = "Remote mount utility which parses a json file";
     license = licenses.mit;
diff --git a/pkgs/tools/filesystems/romdirfs/default.nix b/pkgs/tools/filesystems/romdirfs/default.nix
index 0408899034806..12b6978af6233 100644
--- a/pkgs/tools/filesystems/romdirfs/default.nix
+++ b/pkgs/tools/filesystems/romdirfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, fuse }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, fuse }:
 
 stdenv.mkDerivation rec {
   pname = "romdirfs";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkgconfig ];
   buildInputs = [ fuse ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE for access Playstation 2 IOP IOPRP images and BIOS dumps";
     homepage = "https://github.com/mlafeldt/romdirfs";
     license = licenses.gpl3;
diff --git a/pkgs/tools/filesystems/s3backer/default.nix b/pkgs/tools/filesystems/s3backer/default.nix
index 1906f68053549..b617414aac844 100644
--- a/pkgs/tools/filesystems/s3backer/default.nix
+++ b/pkgs/tools/filesystems/s3backer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook, pkgconfig
 , fuse, curl, expat }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/archiecobbs/s3backer";
     description = "FUSE-based single file backing store via Amazon S3";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/filesystems/s3fs/default.nix b/pkgs/tools/filesystems/s3fs/default.nix
index 3e91a1b0c4759..487ecf63c9386 100644
--- a/pkgs/tools/filesystems/s3fs/default.nix
+++ b/pkgs/tools/filesystems/s3fs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, curl, openssl, libxml2, fuse, osxfuse }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, curl, openssl, libxml2, fuse, osxfuse }:
 
 stdenv.mkDerivation rec {
   pname = "s3fs-fuse";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     ln -s $out/bin/s3fs $out/bin/mount.s3fs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mount an S3 bucket as filesystem through FUSE";
     license = licenses.gpl2;
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/filesystems/sandboxfs/default.nix b/pkgs/tools/filesystems/sandboxfs/default.nix
index 85677a53f43d4..8777fa50a5d87 100644
--- a/pkgs/tools/filesystems/sandboxfs/default.nix
+++ b/pkgs/tools/filesystems/sandboxfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , fuse
@@ -28,7 +28,7 @@ rustPlatform.buildRustPackage rec {
 
   postInstall = "installManPage man/sandboxfs.1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A virtual file system for sandboxing";
     homepage = "https://github.com/bazelbuild/sandboxfs";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/tools/filesystems/sasquatch/default.nix b/pkgs/tools/filesystems/sasquatch/default.nix
index d4c7d9b766748..011387e7a4de5 100644
--- a/pkgs/tools/filesystems/sasquatch/default.nix
+++ b/pkgs/tools/filesystems/sasquatch/default.nix
@@ -4,7 +4,7 @@
 , lz4Support ? false
 , lzma
 , lzo
-, stdenv
+, lib, stdenv
 , xz
 , zlib
 }:
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
   makeFlags = [ "XZ_SUPPORT=1" ]
     ++ stdenv.lib.optional lz4Support "LZ4_SUPPORT=1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/devttys0/sasquatch";
     description = "Set of patches to the standard unsquashfs utility (part of squashfs-tools) that attempts to add support for as many hacked-up vendor-specific SquashFS implementations as possible";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/filesystems/securefs/default.nix b/pkgs/tools/filesystems/securefs/default.nix
index a83f6ba515c6e..235d8a53fe721 100644
--- a/pkgs/tools/filesystems/securefs/default.nix
+++ b/pkgs/tools/filesystems/securefs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake
 , fuse }:
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ fuse ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Transparent encryption filesystem";
     longDescription = ''
diff --git a/pkgs/tools/filesystems/simg2img/default.nix b/pkgs/tools/filesystems/simg2img/default.nix
index 6782987c027f1..d0d7304c9d200 100644
--- a/pkgs/tools/filesystems/simg2img/default.nix
+++ b/pkgs/tools/filesystems/simg2img/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib }:
+{ lib, stdenv, fetchFromGitHub, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "simg2img";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to convert Android sparse images to raw images";
     homepage = "https://github.com/anestisb/android-simg2img";
     license = licenses.asl20;
diff --git a/pkgs/tools/filesystems/smbnetfs/default.nix b/pkgs/tools/filesystems/smbnetfs/default.nix
index 04c7d7c9d2a97..7967be7010657 100644
--- a/pkgs/tools/filesystems/smbnetfs/default.nix
+++ b/pkgs/tools/filesystems/smbnetfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fuse, samba, pkgconfig, glib, autoconf, attr, libsecret }:
+{ lib, stdenv, fetchurl, fuse, samba, pkgconfig, glib, autoconf, attr, libsecret }:
 
 stdenv.mkDerivation rec {
   pname = "smbnetfs";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     substituteInPlace src/function.c --replace "attr/xattr.h" "sys/xattr.h"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A FUSE FS for mounting Samba shares";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/sshfs-fuse/default.nix b/pkgs/tools/filesystems/sshfs-fuse/default.nix
index 3922851af3310..bec84b3810e59 100644
--- a/pkgs/tools/filesystems/sshfs-fuse/default.nix
+++ b/pkgs/tools/filesystems/sshfs-fuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, pkg-config, ninja, docutils, makeWrapper
 , fuse3, glib
 , which, python3Packages
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     python3 -m pytest test/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "FUSE-based filesystem that allows remote filesystems to be mounted over SSH";
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/tmsu/default.nix b/pkgs/tools/filesystems/tmsu/default.nix
index 5efa218ed081b..7129de950136b 100644
--- a/pkgs/tools/filesystems/tmsu/default.nix
+++ b/pkgs/tools/filesystems/tmsu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, fuse, installShellFiles }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, fuse, installShellFiles }:
 
 buildGoPackage rec {
   pname = "tmsu";
@@ -30,7 +30,7 @@ buildGoPackage rec {
     installShellCompletion --zsh src/misc/zsh/_tmsu
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://www.tmsu.org";
     description = "A tool for tagging your files using a virtual filesystem";
     maintainers = with maintainers; [ pSub ];
diff --git a/pkgs/tools/filesystems/u3-tool/default.nix b/pkgs/tools/filesystems/u3-tool/default.nix
index f18eb9e82271b..6abab83b0fd0a 100644
--- a/pkgs/tools/filesystems/u3-tool/default.nix
+++ b/pkgs/tools/filesystems/u3-tool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "u3-tool";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
     sha256 = "1p9c9kibd1pdbdfa0nd0i3n7bvzi3xg0chm38jg3xfl8gsn0390f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for controlling the special features of a 'U3 smart drive' USB Flash disk";
     homepage = "https://sourceforge.net/projects/u3-tool/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/ubidump/default.nix b/pkgs/tools/filesystems/ubidump/default.nix
index 4feca6a040b40..2787b87964fd1 100644
--- a/pkgs/tools/filesystems/ubidump/default.nix
+++ b/pkgs/tools/filesystems/ubidump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, python3, makeWrapper }:
 
 python3.pkgs.buildPythonApplication rec {
 
@@ -30,7 +30,7 @@ python3.pkgs.buildPythonApplication rec {
     $out/bin/ubidump -h  > /dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "View or extract the contents of UBIFS images";
     homepage = "https://github.com/nlitsme/ubidump";
     license = licenses.mit;
diff --git a/pkgs/tools/filesystems/udftools/default.nix b/pkgs/tools/filesystems/udftools/default.nix
index 0f52635efc60d..ec3fd6efefae4 100644
--- a/pkgs/tools/filesystems/udftools/default.nix
+++ b/pkgs/tools/filesystems/udftools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, readline, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, ncurses, readline, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "udftools";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     sed -i -e "s@/usr/sbin/pktsetup@$out/sbin/pktsetup@" $out/lib/udev/rules.d/80-pktsetup.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "UDF tools";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/filesystems/unionfs-fuse/default.nix b/pkgs/tools/filesystems/unionfs-fuse/default.nix
index 13ea14e5e36d6..77f45d06c91ca 100644
--- a/pkgs/tools/filesystems/unionfs-fuse/default.nix
+++ b/pkgs/tools/filesystems/unionfs-fuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, fuse }:
+{ lib, stdenv, fetchFromGitHub, cmake, fuse }:
 
 stdenv.mkDerivation rec {
   pname = "unionfs-fuse";
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/sbin/mount.unionfs-fuse --replace unionfs $out/bin/unionfs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE UnionFS implementation";
     homepage = "https://github.com/rpodgorny/unionfs-fuse";
     license = licenses.bsd3;
diff --git a/pkgs/tools/filesystems/vmfs-tools/default.nix b/pkgs/tools/filesystems/vmfs-tools/default.nix
index f473fa04334aa..2d4f3b22a7718 100644
--- a/pkgs/tools/filesystems/vmfs-tools/default.nix
+++ b/pkgs/tools/filesystems/vmfs-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , asciidoc
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     install -Dm444 -t $out/share/doc/${pname} AUTHORS LICENSE README TODO
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FUSE-based VMFS (vmware) file system tools";
     maintainers = with maintainers; [ peterhoeg ];
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/wdfs/default.nix b/pkgs/tools/filesystems/wdfs/default.nix
index af1caecfd7486..d32138f184bee 100644
--- a/pkgs/tools/filesystems/wdfs/default.nix
+++ b/pkgs/tools/filesystems/wdfs/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, glib, neon, fuse, pkgconfig}:
+{lib, stdenv, fetchurl, glib, neon, fuse, pkgconfig}:
 
 stdenv.mkDerivation {
   name = "wdfs-fuse-1.4.2";
@@ -9,7 +9,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [fuse glib neon];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://noedler.de/projekte/wdfs/";
     license = licenses.gpl2;
     description = "User-space filesystem that allows to mount a webdav share";
diff --git a/pkgs/tools/filesystems/wiimms-iso-tools/default.nix b/pkgs/tools/filesystems/wiimms-iso-tools/default.nix
index cb09fdcf131a5..70c4450140987 100644
--- a/pkgs/tools/filesystems/wiimms-iso-tools/default.nix
+++ b/pkgs/tools/filesystems/wiimms-iso-tools/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, zlib, ncurses, fuse}:
+{lib, stdenv, fetchurl, zlib, ncurses, fuse}:
 
 stdenv.mkDerivation rec {
   name = "wiimms-iso-tools";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     ./install.sh --no-sudo
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wit.wiimm.de";
     description = "A set of command line tools to manipulate Wii and GameCube ISO images and WBFS containers";
     license = licenses.gpl2;
diff --git a/pkgs/tools/filesystems/xfsprogs/default.nix b/pkgs/tools/filesystems/xfsprogs/default.nix
index 2b0e6048741b3..3e3c26329c4f0 100644
--- a/pkgs/tools/filesystems/xfsprogs/default.nix
+++ b/pkgs/tools/filesystems/xfsprogs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchpatch, fetchurl, autoconf, automake, gettext, libtool, pkgconfig
+{ lib, stdenv, buildPackages, fetchpatch, fetchurl, autoconf, automake, gettext, libtool, pkgconfig
 , icu, libuuid, readline, inih
 }:
 
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     find . -type d -name .libs | xargs rm -rf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://xfs.org/";
     description = "SGI XFS utilities";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/filesystems/zfstools/default.nix b/pkgs/tools/filesystems/zfstools/default.nix
index 476d806531279..ecc4b11848673 100644
--- a/pkgs/tools/filesystems/zfstools/default.nix
+++ b/pkgs/tools/filesystems/zfstools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ruby, zfs }:
+{ lib, stdenv, fetchFromGitHub, ruby, zfs }:
 
 let version = "0.3.6"; in
 stdenv.mkDerivation rec {
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     sed -e 's|cmd.*=.*"zfs |cmd = "${zfs}/sbin/zfs |g' -i $out/lib/zfstools/{dataset,snapshot}.rb
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     inherit (src.meta) homepage;
     description = "OpenSolaris-compatible auto-snapshotting script for ZFS";
diff --git a/pkgs/tools/graphics/amber/default.nix b/pkgs/tools/graphics/amber/default.nix
index 1b8c90c8fb70a..f5156dd08abfc 100644
--- a/pkgs/tools/graphics/amber/default.nix
+++ b/pkgs/tools/graphics/amber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , pkg-config
@@ -86,7 +86,7 @@ stdenv.mkDerivation rec {
     install -Dm755 -t $out/bin amber image_diff
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-API shader test framework";
     homepage = "https://github.com/google/amber";
     license = licenses.asl20;
diff --git a/pkgs/tools/graphics/appleseed/default.nix b/pkgs/tools/graphics/appleseed/default.nix
index 578ee093c05e8..a0d659efb3e86 100644
--- a/pkgs/tools/graphics/appleseed/default.nix
+++ b/pkgs/tools/graphics/appleseed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, boost165, pkg-config, guile,
+{ lib, stdenv, fetchFromGitHub, cmake, boost165, pkg-config, guile,
 eigen, libpng, python, libGLU, qt4, openexr, openimageio,
 opencolorio, xercesc, ilmbase, osl, seexpr, makeWrapper
 }:
@@ -48,7 +48,7 @@ in stdenv.mkDerivation rec {
       "-DUSE_SSE42=ON"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source, physically-based global illumination rendering engine";
     homepage = "https://appleseedhq.net/";
     maintainers = with maintainers; [ hodapp ];
diff --git a/pkgs/tools/graphics/argyllcms/default.nix b/pkgs/tools/graphics/argyllcms/default.nix
index 115a9a3e4a56c..727aa1dc56e3a 100644
--- a/pkgs/tools/graphics/argyllcms/default.nix
+++ b/pkgs/tools/graphics/argyllcms/default.nix
@@ -114,7 +114,7 @@ stdenv.mkDerivation rec {
     mv $out/ref $out/share/argyllcms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.argyllcms.com";
     description = "Color management system (compatible with ICC)";
     license = licenses.gpl3;
diff --git a/pkgs/tools/graphics/asymptote/default.nix b/pkgs/tools/graphics/asymptote/default.nix
index 6b8c6870a668a..a7c6d6eb4394e 100644
--- a/pkgs/tools/graphics/asymptote/default.nix
+++ b/pkgs/tools/graphics/asymptote/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchurl, fetchpatch
 , autoreconfHook, bison, glm, yacc, flex
 , freeglut, ghostscriptX, imagemagick, fftw
 , boehmgc, libGLU, libGL, mesa, ncurses, readline, gsl, libsigsegv
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =  "A tool for programming graphics intended to replace Metapost";
     license = licenses.gpl3Plus;
     maintainers = [ maintainers.raskin maintainers.peti ];
diff --git a/pkgs/tools/graphics/barcode/default.nix b/pkgs/tools/graphics/barcode/default.nix
index 48558d022597d..2906304a6d2aa 100644
--- a/pkgs/tools/graphics/barcode/default.nix
+++ b/pkgs/tools/graphics/barcode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "0.99";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNU barcode generator";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux; # Maybe other non-darwin Unix
diff --git a/pkgs/tools/graphics/blockhash/default.nix b/pkgs/tools/graphics/blockhash/default.nix
index b4f99a9192cdd..3ea88053d9e3c 100644
--- a/pkgs/tools/graphics/blockhash/default.nix
+++ b/pkgs/tools/graphics/blockhash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python, pkgconfig, imagemagick, wafHook }:
+{ lib, stdenv, fetchFromGitHub, python, pkgconfig, imagemagick, wafHook }:
 
 stdenv.mkDerivation rec {
   pname = "blockhash";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ python pkgconfig wafHook ];
   buildInputs = [ imagemagick ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://blockhash.io/";
     description = ''
       This is a perceptual image hash calculation tool based on algorithm
diff --git a/pkgs/tools/graphics/blur-effect/default.nix b/pkgs/tools/graphics/blur-effect/default.nix
index b22a2e8970b62..7ccda815e1ca5 100644
--- a/pkgs/tools/graphics/blur-effect/default.nix
+++ b/pkgs/tools/graphics/blur-effect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, cmake, gdk-pixbuf, libGL, mesa }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, cmake, gdk-pixbuf, libGL, mesa }:
 
 stdenv.mkDerivation rec {
   pname = "blur-effect";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     mesa
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sonald/blur-effect";
     description = "Off-screen image blurring utility using OpenGL ES 3.0";
     license = licenses.gpl3;
diff --git a/pkgs/tools/graphics/cfdg/default.nix b/pkgs/tools/graphics/cfdg/default.nix
index 2cbf43407ffe7..9295bbe28d56e 100644
--- a/pkgs/tools/graphics/cfdg/default.nix
+++ b/pkgs/tools/graphics/cfdg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpng, bison, flex, ffmpeg_3, icu }:
+{ lib, stdenv, fetchFromGitHub, libpng, bison, flex, ffmpeg_3, icu }:
 
 stdenv.mkDerivation rec {
   pname = "cfdg";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     cp *.txt $out/share/doc/${pname}-${version}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Context-free design grammar - a tool for graphics generation";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/graphics/cuneiform/default.nix b/pkgs/tools/graphics/cuneiform/default.nix
index 5213245b7d4bf..ac6481cc62516 100644
--- a/pkgs/tools/graphics/cuneiform/default.nix
+++ b/pkgs/tools/graphics/cuneiform/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, imagemagick }:
+{ lib, stdenv, fetchurl, cmake, imagemagick }:
 
 stdenv.mkDerivation {
   pname = "cuneiform";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-language OCR system";
     homepage = "https://launchpad.net/cuneiform-linux";
     license = licenses.bsd3;
diff --git a/pkgs/tools/graphics/directx-shader-compiler/default.nix b/pkgs/tools/graphics/directx-shader-compiler/default.nix
index 4e74d2c443f11..6bab32ff27fa0 100644
--- a/pkgs/tools/graphics/directx-shader-compiler/default.nix
+++ b/pkgs/tools/graphics/directx-shader-compiler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, python3, git }:
+{ lib, stdenv, fetchFromGitHub, cmake, python3, git }:
 
 stdenv.mkDerivation rec {
   pname = "directx-shader-compiler";
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     cp -r $src/include/dxc $dev/include/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A compiler to compile HLSL programs into DXIL and SPIR-V";
     homepage = "https://github.com/microsoft/DirectXShaderCompiler";
     platforms = with platforms; linux ++ darwin;
diff --git a/pkgs/tools/graphics/ditaa/default.nix b/pkgs/tools/graphics/ditaa/default.nix
index 89a18ae1fe2a3..79a24ed3841c1 100644
--- a/pkgs/tools/graphics/ditaa/default.nix
+++ b/pkgs/tools/graphics/ditaa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre }:
+{ lib, stdenv, fetchurl, jre }:
 
 stdenv.mkDerivation rec {
   name = "ditaa-0.11.0";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     chmod a+x "$out/bin/ditaa"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert ascii art diagrams into proper bitmap graphics";
     homepage = "https://github.com/stathissideris/ditaa";
     license = licenses.lgpl3;
diff --git a/pkgs/tools/graphics/dpic/default.nix b/pkgs/tools/graphics/dpic/default.nix
index ea65f3dbb55c1..c0dc7661715dc 100644
--- a/pkgs/tools/graphics/dpic/default.nix
+++ b/pkgs/tools/graphics/dpic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "dpic";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   # The prefix passed to configure is not used.
   makeFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of the pic little language for creating drawings";
     homepage = "https://ece.uwaterloo.ca/~aplevich/dpic/";
     license = licenses.bsd2;
diff --git a/pkgs/tools/graphics/editres/default.nix b/pkgs/tools/graphics/editres/default.nix
index 1dc4891d6423e..2c9eadea8bfbf 100644
--- a/pkgs/tools/graphics/editres/default.nix
+++ b/pkgs/tools/graphics/editres/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libXt, libXaw, libXres, utilmacros }:
+{ lib, stdenv, fetchurl, pkgconfig, libXt, libXaw, libXres, utilmacros }:
 
 stdenv.mkDerivation rec {
   name = "editres-1.0.7";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://cgit.freedesktop.org/xorg/app/editres/";
     description = "A dynamic resource editor for X Toolkit applications";
     license = licenses.mit;
diff --git a/pkgs/tools/graphics/enblend-enfuse/default.nix b/pkgs/tools/graphics/enblend-enfuse/default.nix
index 89c861267f0b2..d071b2441672d 100644
--- a/pkgs/tools/graphics/enblend-enfuse/default.nix
+++ b/pkgs/tools/graphics/enblend-enfuse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , boost, freeglut, glew, gsl, lcms2, libpng, libtiff, libGLU, libGL, vigra
 , help2man, pkgconfig, perl, texlive }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://enblend.sourceforge.net/";
     description = "Blends away the seams in a panoramic image mosaic using a multiresolution spline";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/eplot/default.nix b/pkgs/tools/graphics/eplot/default.nix
index de729e38662d1..b4dd9cd36d8df 100644
--- a/pkgs/tools/graphics/eplot/default.nix
+++ b/pkgs/tools/graphics/eplot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnuplot, ruby }:
+{ lib, stdenv, fetchurl, gnuplot, ruby }:
 
 stdenv.mkDerivation {
   name = "eplot-2.07";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
     sed -i -e "s|gnuplot -persist|${gnuplot}/bin/gnuplot -persist|" "$out/bin/eplot"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create plots quickly with gnuplot";
     longDescription = ''
       eplot ("easy gnuplot") is a ruby script which allows to pipe data easily
diff --git a/pkgs/tools/graphics/epstool/default.nix b/pkgs/tools/graphics/epstool/default.nix
index aed49158599ab..8052434ff0b85 100644
--- a/pkgs/tools/graphics/epstool/default.nix
+++ b/pkgs/tools/graphics/epstool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "3.08";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   patches = [ ./gcc43.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility to create or extract preview images in EPS files, fix bounding boxes and convert to bitmaps";
     homepage = "http://pages.cs.wisc.edu/~ghost/gsview/epstool.htm";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/exif/default.nix b/pkgs/tools/graphics/exif/default.nix
index 68007ec3a6b22..33a085724ec54 100644
--- a/pkgs/tools/graphics/exif/default.nix
+++ b/pkgs/tools/graphics/exif/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libexif, popt, libintl }:
+{ lib, stdenv, fetchurl, pkgconfig, libexif, popt, libintl }:
 
 stdenv.mkDerivation rec {
   name = "exif-0.6.21";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libexif popt libintl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://libexif.github.io";
     description = "A utility to read and manipulate EXIF data in digital photographs";
     platforms = platforms.unix;
diff --git a/pkgs/tools/graphics/exifprobe/default.nix b/pkgs/tools/graphics/exifprobe/default.nix
index 93a9be58b72af..7331ac69185ae 100644
--- a/pkgs/tools/graphics/exifprobe/default.nix
+++ b/pkgs/tools/graphics/exifprobe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "exifprobe";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     rm -r $out/usr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for reading EXIF data from image files produced by digital cameras";
     homepage = "https://github.com/hfiguiere/exifprobe";
     license = licenses.bsd2;
diff --git a/pkgs/tools/graphics/facedetect/default.nix b/pkgs/tools/graphics/facedetect/default.nix
index 690c7336b6955..257de05a898ab 100644
--- a/pkgs/tools/graphics/facedetect/default.nix
+++ b/pkgs/tools/graphics/facedetect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages }:
+{ lib, stdenv, fetchFromGitHub, python2Packages }:
 
 stdenv.mkDerivation rec {
   pname = "facedetect";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.thregr.org/~wavexx/software/facedetect/";
     description = "A simple face detector for batch processing";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/graphics/fbv/default.nix b/pkgs/tools/graphics/fbv/default.nix
index 561c007ff161c..6f6e0aeca2cc1 100644
--- a/pkgs/tools/graphics/fbv/default.nix
+++ b/pkgs/tools/graphics/fbv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, getopt, libjpeg, libpng12, libungif }:
+{ lib, stdenv, fetchurl, getopt, libjpeg, libpng12, libungif }:
 
 stdenv.mkDerivation rec {
   name = "fbv-1.0b";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/{bin,man/man1}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "View pictures on a linux framebuffer device";
     homepage = "http://s-tech.elsat.net.pl/fbv/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/feedgnuplot/default.nix b/pkgs/tools/graphics/feedgnuplot/default.nix
index ef699b5437a02..1fe254d77857f 100644
--- a/pkgs/tools/graphics/feedgnuplot/default.nix
+++ b/pkgs/tools/graphics/feedgnuplot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, gawk
+{ lib, stdenv, fetchFromGitHub, makeWrapper, gawk
 , makeFontsConf, freefont_ttf, gnuplot, perl, perlPackages
 }:
 
@@ -46,7 +46,7 @@ perlPackages.buildPerlPackage rec {
         completions/zsh/_feedgnuplot
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "General purpose pipe-oriented plotting tool";
     homepage = "https://github.com/dkogan/feedgnuplot/";
     license = with licenses; [ artistic1 gpl1Plus ];
diff --git a/pkgs/tools/graphics/fgallery/default.nix b/pkgs/tools/graphics/fgallery/default.nix
index cc387e29412bb..9694fb728f8c2 100644
--- a/pkgs/tools/graphics/fgallery/default.nix
+++ b/pkgs/tools/graphics/fgallery/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, makeWrapper, perlPackages
+{ lib, stdenv, fetchurl, unzip, makeWrapper, perlPackages
 , coreutils, zip, imagemagick, pngcrush, lcms2
 , facedetect, fbida }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
                      [ coreutils zip imagemagick pngcrush lcms2 facedetect fbida ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Static photo gallery generator";
     homepage = "http://www.thregr.org/~wavexx/software/fgallery/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/flam3/default.nix b/pkgs/tools/graphics/flam3/default.nix
index 29560cfe6e550..58aefd1d58524 100644
--- a/pkgs/tools/graphics/flam3/default.nix
+++ b/pkgs/tools/graphics/flam3/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, zlib, libpng, libxml2, libjpeg }:
+{lib, stdenv, fetchFromGitHub, zlib, libpng, libxml2, libjpeg }:
 
 stdenv.mkDerivation rec {
   pname = "flam3";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ zlib libpng libxml2 libjpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cosmic recursive fractal flames";
     homepage = "https://flam3.com/";
     maintainers = [ maintainers.nand0p ];
diff --git a/pkgs/tools/graphics/ggobi/default.nix b/pkgs/tools/graphics/ggobi/default.nix
index 82ee194ad1218..bce1564946c7b 100644
--- a/pkgs/tools/graphics/ggobi/default.nix
+++ b/pkgs/tools/graphics/ggobi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxml2, gtk2 }:
+{ lib, stdenv, fetchurl, pkgconfig, libxml2, gtk2 }:
 
 stdenv.mkDerivation rec {
   version = "2.1.11";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Visualization program for exploring high-dimensional data";
     homepage = "http://www.ggobi.org/";
     license = licenses.cpl10;
diff --git a/pkgs/tools/graphics/gifski/default.nix b/pkgs/tools/graphics/gifski/default.nix
index aa247a4c9177f..38f83c076ff80 100644
--- a/pkgs/tools/graphics/gifski/default.nix
+++ b/pkgs/tools/graphics/gifski/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, pkgconfig }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, pkgconfig }:
 
 rustPlatform.buildRustPackage rec {
   pname = "gifski";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GIF encoder based on libimagequant (pngquant)";
     homepage = "https://gif.ski/";
     license = licenses.agpl3;
diff --git a/pkgs/tools/graphics/glee/default.nix b/pkgs/tools/graphics/glee/default.nix
index 58fcfbfd9acaa..fad37d1e08eb6 100644
--- a/pkgs/tools/graphics/glee/default.nix
+++ b/pkgs/tools/graphics/glee/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchgit, cmake, libGLU, libGL, xorg }:
+{lib, stdenv, fetchgit, cmake, libGLU, libGL, xorg }:
 
 stdenv.mkDerivation rec {
   pname = "glee";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     sed -i 's/readme/Readme/' cmake_install.cmake
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GL Easy Extension Library";
     homepage = "https://sourceforge.net/p/glee/glee/";
     maintainers = with maintainers; [ nand0p ];
diff --git a/pkgs/tools/graphics/glmark2/default.nix b/pkgs/tools/graphics/glmark2/default.nix
index deea9e10a1a06..e2acd81b9b004 100644
--- a/pkgs/tools/graphics/glmark2/default.nix
+++ b/pkgs/tools/graphics/glmark2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libjpeg, libpng, xorg, libX11, libGL, libdrm,
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libjpeg, libpng, xorg, libX11, libGL, libdrm,
   python27, wayland, udev, mesa, wafHook }:
 
 stdenv.mkDerivation {
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   wafConfigureFlags = ["--with-flavors=x11-gl,x11-glesv2,drm-gl,drm-glesv2,wayland-gl,wayland-glesv2"];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenGL (ES) 2.0 benchmark";
     homepage = "https://github.com/glmark2/glmark2";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/graphics/glxinfo/default.nix b/pkgs/tools/graphics/glxinfo/default.nix
index 6518a74512bae..0dcf30fda1566 100644
--- a/pkgs/tools/graphics/glxinfo/default.nix
+++ b/pkgs/tools/graphics/glxinfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libGL, libX11 }:
+{ lib, stdenv, fetchurl, libGL, libX11 }:
 
 stdenv.mkDerivation rec {
   pname = "glxinfo";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     install -Dm 555 -t $out/bin glx{info,gears} es2{_info,gears} eglinfo
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test utilities for OpenGL";
     homepage = "https://www.mesa3d.org/";
     license = licenses.mit;
diff --git a/pkgs/tools/graphics/gmic/default.nix b/pkgs/tools/graphics/gmic/default.nix
index e8e9472cabdfd..07d4d1dd303a3 100644
--- a/pkgs/tools/graphics/gmic/default.nix
+++ b/pkgs/tools/graphics/gmic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , cmake
 , ninja
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     "-DENABLE_DYNAMIC_LINKING=ON"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open and full-featured framework for image processing";
     homepage = "https://gmic.eu/";
     license = licenses.cecill20;
diff --git a/pkgs/tools/graphics/graph-easy/default.nix b/pkgs/tools/graphics/graph-easy/default.nix
index 009a86094ec56..4ae68207aaec2 100644
--- a/pkgs/tools/graphics/graph-easy/default.nix
+++ b/pkgs/tools/graphics/graph-easy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, perlPackages, fetchurl }:
+{ lib, stdenv, perlPackages, fetchurl }:
 
 perlPackages.buildPerlPackage {
   pname = "Graph-Easy";
@@ -8,7 +8,7 @@ perlPackages.buildPerlPackage {
     sha256 = "d4a2c10aebef663b598ea37f3aa3e3b752acf1fbbb961232c3dbe1155008d1fa";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Render/convert graphs in/from various formats";
     license = licenses.gpl1;
     platforms = platforms.unix;
diff --git a/pkgs/tools/graphics/graphviz/base.nix b/pkgs/tools/graphics/graphviz/base.nix
index cdec842700522..a3cdf9c6fc8ea 100644
--- a/pkgs/tools/graphics/graphviz/base.nix
+++ b/pkgs/tools/graphics/graphviz/base.nix
@@ -1,6 +1,6 @@
 { rev, sha256, version }:
 
-{ stdenv, fetchFromGitLab, autoreconfHook, pkgconfig, cairo, expat, flex
+{ lib, stdenv, fetchFromGitLab, autoreconfHook, pkgconfig, cairo, expat, flex
 , fontconfig, gd, gettext, gts, libdevil, libjpeg, libpng, libtool, pango
 , yacc, fetchpatch, xorg ? null, ApplicationServices ? null }:
 
@@ -81,7 +81,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://graphviz.org";
     description = "Graph visualization tools";
     license = licenses.epl10;
diff --git a/pkgs/tools/graphics/grim/default.nix b/pkgs/tools/graphics/grim/default.nix
index a357277ed12e8..cca74cea569a9 100644
--- a/pkgs/tools/graphics/grim/default.nix
+++ b/pkgs/tools/graphics/grim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cairo, libjpeg, meson, ninja, wayland, pkgconfig, scdoc, wayland-protocols }:
+{ lib, stdenv, fetchFromGitHub, cairo, libjpeg, meson, ninja, wayland, pkgconfig, scdoc, wayland-protocols }:
 
 stdenv.mkDerivation rec {
   pname = "grim";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     wayland-protocols
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Grab images from a Wayland compositor";
     homepage = "https://github.com/emersion/grim";
     license = licenses.mit;
diff --git a/pkgs/tools/graphics/gromit-mpx/default.nix b/pkgs/tools/graphics/gromit-mpx/default.nix
index 7c55b6558a488..710ed04006c4e 100644
--- a/pkgs/tools/graphics/gromit-mpx/default.nix
+++ b/pkgs/tools/graphics/gromit-mpx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config
 , gtk, glib, pcre, libappindicator, libpthreadstubs, libXdmcp
 , libxkbcommon, epoxy, at-spi2-core, dbus, libdbusmenu
 , wrapGAppsHook
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     dbus libdbusmenu
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop annotation tool";
 
     longDescription = ''
diff --git a/pkgs/tools/graphics/ibniz/default.nix b/pkgs/tools/graphics/ibniz/default.nix
index 564685c1ceaf2..227ab5d082dc7 100644
--- a/pkgs/tools/graphics/ibniz/default.nix
+++ b/pkgs/tools/graphics/ibniz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL }:
+{ lib, stdenv, fetchurl, SDL }:
 
 stdenv.mkDerivation rec {
   pname = "ibniz";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp ibniz $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Virtual machine designed for extremely compact low-level audiovisual programs";
     homepage = "http://www.pelulamu.net/ibniz/";
     license = licenses.zlib;
diff --git a/pkgs/tools/graphics/imageworsener/default.nix b/pkgs/tools/graphics/imageworsener/default.nix
index 3eade7ee76b9c..120643ddde051 100644
--- a/pkgs/tools/graphics/imageworsener/default.nix
+++ b/pkgs/tools/graphics/imageworsener/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , zlib
 , libpng
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A raster image scaling and processing utility";
     homepage = "https://entropymine.com/imageworsener/";
     changelog = "https://github.com/jsummers/${pname}/blob/${version}/changelog.txt";
diff --git a/pkgs/tools/graphics/imgur-screenshot/default.nix b/pkgs/tools/graphics/imgur-screenshot/default.nix
index 1a211ebd857f1..db96299abe13f 100644
--- a/pkgs/tools/graphics/imgur-screenshot/default.nix
+++ b/pkgs/tools/graphics/imgur-screenshot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, curl, jq, gnugrep, libnotify, scrot, which, xclip }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, curl, jq, gnugrep, libnotify, scrot, which, xclip }:
 
 let deps = stdenv.lib.makeBinPath [ curl jq gnugrep libnotify scrot which xclip ];
 in stdenv.mkDerivation rec {
@@ -19,7 +19,7 @@ in stdenv.mkDerivation rec {
     wrapProgram $out/bin/imgur-screenshot --prefix PATH ':' ${deps}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for easy screencapping and uploading to imgur";
     homepage = "https://github.com/jomo/imgur-screenshot/";
     platforms = platforms.linux;
diff --git a/pkgs/tools/graphics/imgurbash2/default.nix b/pkgs/tools/graphics/imgurbash2/default.nix
index ea3b1ed9b02de..84e25150fab08 100644
--- a/pkgs/tools/graphics/imgurbash2/default.nix
+++ b/pkgs/tools/graphics/imgurbash2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bash, curl, xsel }:
+{ lib, stdenv, fetchFromGitHub, bash, curl, xsel }:
 
 stdenv.mkDerivation rec {
   pname = "imgurbash2";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/imgurbash2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A shell script that uploads images to imgur";
     license = licenses.mit;
     platforms = platforms.linux;
diff --git a/pkgs/tools/graphics/jhead/default.nix b/pkgs/tools/graphics/jhead/default.nix
index 1d3696a8cd249..ab5fd4f5401d1 100644
--- a/pkgs/tools/graphics/jhead/default.nix
+++ b/pkgs/tools/graphics/jhead/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, libjpeg }:
+{ lib, stdenv, fetchurl, fetchpatch, libjpeg }:
 
 stdenv.mkDerivation rec {
   pname = "jhead";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     cp -v *.txt $out/share/doc/${pname}-${version}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.sentex.net/~mwandel/jhead/";
     description = "Exif Jpeg header manipulation tool";
     license = licenses.publicDomain;
diff --git a/pkgs/tools/graphics/lepton/default.nix b/pkgs/tools/graphics/lepton/default.nix
index cbb48fe372809..1835b9fec2132 100644
--- a/pkgs/tools/graphics/lepton/default.nix
+++ b/pkgs/tools/graphics/lepton/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, git, glibc }:
+{ lib, stdenv, fetchFromGitHub, cmake, git, glibc }:
 
 stdenv.mkDerivation rec {
   version = "2019-08-20";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake git ];
   buildInputs = stdenv.lib.optionals stdenv.isLinux [ glibc.static ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dropbox/lepton";
     description = "A tool to losslessly compress JPEGs";
     license = licenses.asl20;
diff --git a/pkgs/tools/graphics/logstalgia/default.nix b/pkgs/tools/graphics/logstalgia/default.nix
index 83178824eab62..d4abee146b8e6 100644
--- a/pkgs/tools/graphics/logstalgia/default.nix
+++ b/pkgs/tools/graphics/logstalgia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, SDL2, ftgl, pkgconfig, libpng, libjpeg, pcre, SDL2_image, glew
+{ lib, stdenv, fetchurl, SDL2, ftgl, pkgconfig, libpng, libjpeg, pcre, SDL2_image, glew
 , libGLU, libGL, boost, glm, freetype }:
 
 stdenv.mkDerivation rec {
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ glew SDL2 ftgl libpng libjpeg pcre SDL2_image libGLU libGL boost
                   glm freetype ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://logstalgia.io/";
     description = "Website traffic visualization tool";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/graphics/luxcorerender/default.nix b/pkgs/tools/graphics/luxcorerender/default.nix
index edce992a6037b..af71990e459c8 100644
--- a/pkgs/tools/graphics/luxcorerender/default.nix
+++ b/pkgs/tools/graphics/luxcorerender/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, boost165, pkg-config, python36
+{ lib, stdenv, fetchFromGitHub, cmake, boost165, pkg-config, python36
 , tbb, openimageio, libjpeg, libpng, zlib, libtiff, ilmbase
 , freetype, openexr, libXdmcp, libxkbcommon, epoxy, at-spi2-core
 , dbus, doxygen, qt5, c-blosc, libGLU, gnome3, dconf, gtk3, pcre
@@ -76,7 +76,7 @@ in stdenv.mkDerivation {
       --prefix GIO_EXTRA_MODULES : "${stdenv.lib.getLib dconf}/lib/gio/modules"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source, physically based, unbiased rendering engine";
     homepage = "https://luxcorerender.org/";
     maintainers = with maintainers; [ hodapp ];
diff --git a/pkgs/tools/graphics/maim/default.nix b/pkgs/tools/graphics/maim/default.nix
index 29c9144f89fed..99bbd4b13daef 100644
--- a/pkgs/tools/graphics/maim/default.nix
+++ b/pkgs/tools/graphics/maim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , zlib, libpng, libjpeg, libGLU, libGL, glm
 , libX11, libXext, libXfixes, libXrandr, libXcomposite, slop, icu
 }:
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "A command-line screenshot utility";
     longDescription = ''
diff --git a/pkgs/tools/graphics/mesa-demos/default.nix b/pkgs/tools/graphics/mesa-demos/default.nix
index 12e751e0f0875..14b7a038a1302 100644
--- a/pkgs/tools/graphics/mesa-demos/default.nix
+++ b/pkgs/tools/graphics/mesa-demos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, freeglut, glew, libGL, libGLU, libX11, libXext, mesa, pkg-config, wayland }:
+{ lib, stdenv, fetchurl, freeglut, glew, libGL, libGLU, libX11, libXext, mesa, pkg-config, wayland }:
 
 stdenv.mkDerivation rec {
   pname = "mesa-demos";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of demos and test programs for OpenGL and Mesa";
     homepage = "https://www.mesa3d.org/";
     license = licenses.mit;
diff --git a/pkgs/tools/graphics/nifskope/default.nix b/pkgs/tools/graphics/nifskope/default.nix
index 68cf812d052a1..d91f163c50b87 100644
--- a/pkgs/tools/graphics/nifskope/default.nix
+++ b/pkgs/tools/graphics/nifskope/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qmake, qtbase, qttools, substituteAll, libGLU, wrapQtAppsHook, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, qmake, qtbase, qttools, substituteAll, libGLU, wrapQtAppsHook, fetchpatch }:
 
 stdenv.mkDerivation {
   pname = "nifskope";
@@ -59,7 +59,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://niftools.sourceforge.net/wiki/NifSkope";
     description = "A tool for analyzing and editing NetImmerse/Gamebryo '*.nif' files";
     maintainers = with maintainers; [ eelco ma27 ];
diff --git a/pkgs/tools/graphics/nip2/default.nix b/pkgs/tools/graphics/nip2/default.nix
index ac4d8441bf591..4217352565096 100644
--- a/pkgs/tools/graphics/nip2/default.nix
+++ b/pkgs/tools/graphics/nip2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, glib, libxml2, flex, bison, vips, gnome2,
+{ lib, stdenv, fetchurl, pkgconfig, glib, libxml2, flex, bison, vips, gnome2,
 fftw, gsl, goffice, libgsf }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     gnome2.gtk fftw gsl goffice libgsf
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/libvips/nip2";
     description = "Graphical user interface for VIPS image processing system";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/graphics/optar/default.nix b/pkgs/tools/graphics/optar/default.nix
index 3061a5cebaf9b..688d1c4962946 100644
--- a/pkgs/tools/graphics/optar/default.nix
+++ b/pkgs/tools/graphics/optar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, imagemagick, libpng }:
+{ lib, stdenv, fetchurl, imagemagick, libpng }:
 
 stdenv.mkDerivation {
   pname = "optar";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     mkdir -p $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OPTical ARchiver - it's a codec for encoding data on paper";
     homepage = "http://ronja.twibright.com/optar/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/optipng/default.nix b/pkgs/tools/graphics/optipng/default.nix
index 571e89297c789..772e7d192d1cb 100644
--- a/pkgs/tools/graphics/optipng/default.nix
+++ b/pkgs/tools/graphics/optipng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpng
+{ lib, stdenv, fetchurl, libpng
 , static ? stdenv.hostPlatform.isStatic
 }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     mv "$out"/bin/optipng{,.exe}
   '' else null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://optipng.sourceforge.net/";
     description = "A PNG optimizer";
     license = licenses.zlib;
diff --git a/pkgs/tools/graphics/oxipng/default.nix b/pkgs/tools/graphics/oxipng/default.nix
index 1c89a1574c54e..98ece65eb1674 100644
--- a/pkgs/tools/graphics/oxipng/default.nix
+++ b/pkgs/tools/graphics/oxipng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchCrate, rustPlatform }:
+{ lib, stdenv, fetchCrate, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   version = "4.0.2";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck = !stdenv.isAarch64 && !stdenv.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/shssoichiro/oxipng";
     description = "A multithreaded lossless PNG compression optimizer";
     license = licenses.mit;
diff --git a/pkgs/tools/graphics/pdf2svg/default.nix b/pkgs/tools/graphics/pdf2svg/default.nix
index b1463544bbd70..f96f690a1cca4 100644
--- a/pkgs/tools/graphics/pdf2svg/default.nix
+++ b/pkgs/tools/graphics/pdf2svg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , cairo, gtk2, poppler }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ cairo poppler gtk2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PDF converter to SVG format";
     homepage = "http://www.cityinthesky.co.uk/opensource/pdf2svg";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/pdfread/default.nix b/pkgs/tools/graphics/pdfread/default.nix
index 80f7404bc94f1..912aa07ea8d46 100644
--- a/pkgs/tools/graphics/pdfread/default.nix
+++ b/pkgs/tools/graphics/pdfread/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip, python, makeWrapper, ghostscript, pngnq, pillow, djvulibre
+{lib, stdenv, fetchurl, unzip, python, makeWrapper, ghostscript, pngnq, pillow, djvulibre
 , optipng, unrar}:
 
 stdenv.mkDerivation {
@@ -42,7 +42,7 @@ stdenv.mkDerivation {
       --prefix PATH : ${stdenv.lib.makeBinPath [ ghostscript pngnq djvulibre unrar optipng ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PDF/DJVU to ebook format converter";
     homepage = "https://www.mobileread.com/forums/showthread.php?t=21906";
     license = licenses.mit;
diff --git a/pkgs/tools/graphics/pdfredacttools/default.nix b/pkgs/tools/graphics/pdfredacttools/default.nix
index 28b13c782b915..31a327331d7f5 100644
--- a/pkgs/tools/graphics/pdfredacttools/default.nix
+++ b/pkgs/tools/graphics/pdfredacttools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages, imagemagick, exiftool, file, ghostscript }:
+{ lib, stdenv, fetchFromGitHub, python2Packages, imagemagick, exiftool, file, ghostscript }:
 
 python2Packages.buildPythonApplication rec {
   pname = "pdf-redact-tools";
@@ -19,7 +19,7 @@ python2Packages.buildPythonApplication rec {
 
   propagatedBuildInputs = [ imagemagick exiftool ghostscript ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Redact and strip metadata from documents before publishing";
     longDescription = ''
 	PDF Redact Tools helps with securely redacting and stripping metadata
diff --git a/pkgs/tools/graphics/pdftag/default.nix b/pkgs/tools/graphics/pdftag/default.nix
index 7e02293631884..2d2fe74d7848d 100644
--- a/pkgs/tools/graphics/pdftag/default.nix
+++ b/pkgs/tools/graphics/pdftag/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, meson, vala, ninja
+{ lib, stdenv, fetchFromGitHub, pkgconfig, meson, vala, ninja
 , gtk3, poppler, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig meson ninja wrapGAppsHook vala ];
   buildInputs = [ gtk3 poppler ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Edit metadata found in PDFs";
     license = licenses.gpl3;
     maintainers = with maintainers; [ leenaars ];
diff --git a/pkgs/tools/graphics/perceptualdiff/default.nix b/pkgs/tools/graphics/perceptualdiff/default.nix
index dc5acc9433f6c..2227ff4029944 100644
--- a/pkgs/tools/graphics/perceptualdiff/default.nix
+++ b/pkgs/tools/graphics/perceptualdiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, freeimage }:
+{ lib, stdenv, fetchFromGitHub, cmake, freeimage }:
 
 stdenv.mkDerivation rec {
   pname = "perceptualdiff";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ freeimage ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program that compares two images using a perceptually based image metric";
     homepage = "https://github.com/myint/perceptualdiff";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/pfstools/default.nix b/pkgs/tools/graphics/pfstools/default.nix
index f570251374cf7..c22746c521465 100644
--- a/pkgs/tools/graphics/pfstools/default.nix
+++ b/pkgs/tools/graphics/pfstools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, cmake, pkgconfig, darwin
+{ lib, stdenv, mkDerivation, fetchurl, cmake, pkgconfig, darwin
 , openexr, zlib, imagemagick, libGLU, libGL, freeglut, fftwFloat
 , fftw, gsl, libexif, perl, opencv2, qtbase, netpbm
 }:
@@ -37,7 +37,7 @@ mkDerivation rec {
 
   patches = [ ./threads.patch ./pfstools.patch ./pfsalign.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pfstools.sourceforge.net/";
     description = "Toolkit for manipulation of HDR images";
     platforms = platforms.linux;
diff --git a/pkgs/tools/graphics/ploticus/default.nix b/pkgs/tools/graphics/ploticus/default.nix
index 409a91dba0d57..23d6919f78e0b 100644
--- a/pkgs/tools/graphics/ploticus/default.nix
+++ b/pkgs/tools/graphics/ploticus/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, zlib, libX11, libpng}:
+{lib, stdenv, fetchurl, zlib, libX11, libpng}:
 
 stdenv.mkDerivation {
   name = "ploticus-2.42";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     ln -sf pl.1 "$out"/man/man1/ploticus.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A non-interactive software package for producing plots and charts";
     longDescription = ''Ploticus is a free, GPL'd, non-interactive
       software package for producing plots, charts, and graphics from
diff --git a/pkgs/tools/graphics/pngnq/default.nix b/pkgs/tools/graphics/pngnq/default.nix
index ca1edda454e97..462dd2bf7e4a6 100644
--- a/pkgs/tools/graphics/pngnq/default.nix
+++ b/pkgs/tools/graphics/pngnq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libpng, zlib }:
+{ lib, stdenv, fetchurl, pkgconfig, libpng, zlib }:
 
 stdenv.mkDerivation rec {
   name = "pngnq-1.1";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     sed -i '/png.h/a \#include <zlib.h>' src/rwpng.c
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pngnq.sourceforge.net/";
     description = "A PNG quantizer";
     license = licenses.bsd3;
diff --git a/pkgs/tools/graphics/pngquant/default.nix b/pkgs/tools/graphics/pngquant/default.nix
index 2c9e3b272e705..64e6077062e28 100644
--- a/pkgs/tools/graphics/pngquant/default.nix
+++ b/pkgs/tools/graphics/pngquant/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libpng, zlib, lcms2 }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libpng, zlib, lcms2 }:
 
 stdenv.mkDerivation rec {
   pname = "pngquant";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libpng zlib lcms2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pngquant.org/";
     description = "A tool to convert 24/32-bit RGBA PNGs to 8-bit palette with alpha channel preserved";
     platforms = platforms.unix;
diff --git a/pkgs/tools/graphics/povray/default.nix b/pkgs/tools/graphics/povray/default.nix
index 94ce3e7f06b10..735bba8bd4f44 100644
--- a/pkgs/tools/graphics/povray/default.nix
+++ b/pkgs/tools/graphics/povray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, boost
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, boost
 , zlib, libpng, libjpeg, libtiff, xlibsWrapper, SDL
 }:
 
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.povray.org/";
     description = "Persistence of Vision Raytracer";
     license = licenses.free;
diff --git a/pkgs/tools/graphics/pstoedit/default.nix b/pkgs/tools/graphics/pstoedit/default.nix
index ec06088ae52f2..47c3bc25b2e83 100644
--- a/pkgs/tools/graphics/pstoedit/default.nix
+++ b/pkgs/tools/graphics/pstoedit/default.nix
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     substituteInPlace config/pstoedit.pc.in --replace '@LIBPNG_LDFLAGS@' ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Translates PostScript and PDF graphics into other vector formats";
     homepage = "https://sourceforge.net/projects/pstoedit/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/qrcode/default.nix b/pkgs/tools/graphics/qrcode/default.nix
index 909f0e3972680..82c0332689b52 100644
--- a/pkgs/tools/graphics/qrcode/default.nix
+++ b/pkgs/tools/graphics/qrcode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "qrcode-git";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp DOCUMENTATION LICENCE "$out/share/doc/qrcode"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''A small QR-code tool'';
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/tools/graphics/rocket/default.nix b/pkgs/tools/graphics/rocket/default.nix
index 683a2c73f454a..ec32d6c7140f4 100644
--- a/pkgs/tools/graphics/rocket/default.nix
+++ b/pkgs/tools/graphics/rocket/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, qmake, qtbase }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, qmake, qtbase }:
 
 mkDerivation {
   pname = "rocket";
@@ -21,7 +21,7 @@ mkDerivation {
     cp -r editor/editor $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for synchronizing music and visuals in demoscene productions";
     homepage = "https://github.com/rocket/rocket";
     license = licenses.zlib;
diff --git a/pkgs/tools/graphics/scanbd/default.nix b/pkgs/tools/graphics/scanbd/default.nix
index 14f925a4fd2dc..0ad03e23b3917 100644
--- a/pkgs/tools/graphics/scanbd/default.nix
+++ b/pkgs/tools/graphics/scanbd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig
+{ lib, stdenv, fetchurl, pkgconfig
 , dbus, libconfuse, libjpeg, sane-backends, systemd }:
 
 stdenv.mkDerivation rec {
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scanner button daemon";
     longDescription = ''
       scanbd polls a scanner's buttons, looking for button presses, function
diff --git a/pkgs/tools/graphics/scrot/default.nix b/pkgs/tools/graphics/scrot/default.nix
index df6fb7bcda890..2fd56d0737d42 100644
--- a/pkgs/tools/graphics/scrot/default.nix
+++ b/pkgs/tools/graphics/scrot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, giblib, xlibsWrapper, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, giblib, xlibsWrapper, autoreconfHook
 , autoconf-archive, libXfixes, libXcursor, libXcomposite }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook autoconf-archive ];
   buildInputs = [ giblib xlibsWrapper libXfixes libXcursor libXcomposite ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/resurrecting-open-source-projects/scrot";
     description = "A command-line screen capture utility";
     platforms = platforms.linux;
diff --git a/pkgs/tools/graphics/sng/default.nix b/pkgs/tools/graphics/sng/default.nix
index 45f5a6f2c235f..cec0b21cce243 100644
--- a/pkgs/tools/graphics/sng/default.nix
+++ b/pkgs/tools/graphics/sng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpng, netpbm }:
+{ lib, stdenv, fetchurl, libpng, netpbm }:
 
 stdenv.mkDerivation rec {
   pname = "sng";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     "--with-rgbtxt=${netpbm.out}/share/netpbm/misc/rgb.txt"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minilanguage designed to represent the entire contents of a PNG file in an editable form";
     homepage = "http://sng.sourceforge.net/";
     license = licenses.zlib;
diff --git a/pkgs/tools/graphics/spirv-cross/default.nix b/pkgs/tools/graphics/spirv-cross/default.nix
index 76d554457d915..95e4d83645e08 100644
--- a/pkgs/tools/graphics/spirv-cross/default.nix
+++ b/pkgs/tools/graphics/spirv-cross/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, python3 }:
+{ lib, stdenv, fetchFromGitHub, cmake, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "spirv-cross";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake python3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool designed for parsing and converting SPIR-V to other shader languages";
     homepage = "https://github.com/KhronosGroup/SPIRV-Cross";
     platforms = platforms.linux;
diff --git a/pkgs/tools/graphics/structure-synth/default.nix b/pkgs/tools/graphics/structure-synth/default.nix
index 73dd9c04be992..ec2cb359a5e01 100644
--- a/pkgs/tools/graphics/structure-synth/default.nix
+++ b/pkgs/tools/graphics/structure-synth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qt4, qmake4Hook, unzip, libGLU, makeWrapper }:
+{ lib, stdenv, fetchurl, qt4, qmake4Hook, unzip, libGLU, makeWrapper }:
 
 stdenv.mkDerivation {
 
@@ -37,7 +37,7 @@ stdenv.mkDerivation {
     wrapProgram "$out/bin/structure-synth" --run "cd $out/share"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Application for generating 3D structures by specifying a design grammar";
     homepage = "http://structuresynth.sourceforge.net";
     maintainers = with maintainers; [ hodapp ];
diff --git a/pkgs/tools/graphics/svgcleaner/default.nix b/pkgs/tools/graphics/svgcleaner/default.nix
index 201b43f4f448e..653e585c6ed6f 100644
--- a/pkgs/tools/graphics/svgcleaner/default.nix
+++ b/pkgs/tools/graphics/svgcleaner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "svgcleaner";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1xhwlsq9b6cnafbapm5jf48zqdx5k2vxlr701lh5f8nqvd7nxi6g";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for tidying and optimizing SVGs";
     homepage = "https://github.com/RazrFalcon/svgcleaner";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/twilight/default.nix b/pkgs/tools/graphics/twilight/default.nix
index 42a86187a72d3..2716c5e7c650f 100644
--- a/pkgs/tools/graphics/twilight/default.nix
+++ b/pkgs/tools/graphics/twilight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , libGL, libGLU, freeglut, libX11 }:
 
 let
@@ -20,7 +20,7 @@ in stdenv.mkDerivation rec {
     install -Dm755 twilight $out/bin/twilight
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Redo of IRIX twilight backdrop in old school OpenGL";
     homepage = src.meta.homepage;
     license = licenses.mit;
diff --git a/pkgs/tools/graphics/unpaper/default.nix b/pkgs/tools/graphics/unpaper/default.nix
index f3e6f0d8b96fd..a42f8bb45ee55 100644
--- a/pkgs/tools/graphics/unpaper/default.nix
+++ b/pkgs/tools/graphics/unpaper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libav, libxslt }:
+{ lib, stdenv, fetchurl, pkgconfig, libav, libxslt }:
 
 stdenv.mkDerivation rec {
   pname = "unpaper";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libav libxslt ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.flameeyes.eu/projects/unpaper";
     description = "Post-processing tool for scanned sheets of paper";
     license = licenses.gpl2;
diff --git a/pkgs/tools/graphics/vips/default.nix b/pkgs/tools/graphics/vips/default.nix
index 2e745fc1a7c9d..4ea4e49cdbe99 100644
--- a/pkgs/tools/graphics/vips/default.nix
+++ b/pkgs/tools/graphics/vips/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pkgconfig
 , glib
 , libxml2
@@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
     NOCONFIGURE=1 ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://libvips.github.io/libvips/";
     description = "Image processing system for large images";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/graphics/vulkan-extension-layer/default.nix b/pkgs/tools/graphics/vulkan-extension-layer/default.nix
index 3a7473530d60f..f2ea439e0c97e 100644
--- a/pkgs/tools/graphics/vulkan-extension-layer/default.nix
+++ b/pkgs/tools/graphics/vulkan-extension-layer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, writeText, vulkan-headers, jq }:
+{ lib, stdenv, fetchFromGitHub, cmake, writeText, vulkan-headers, jq }:
 
 stdenv.mkDerivation rec {
   pname = "vulkan-extension-layer";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Layers providing Vulkan features when native support is unavailable";
     homepage = "https://github.com/KhronosGroup/Vulkan-ExtensionLayer/";
     platforms = platforms.linux;
diff --git a/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix b/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix
index e8ecfe73d1414..389fae9a6393c 100644
--- a/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix
+++ b/pkgs/tools/graphics/vulkan-tools-lunarg/default.nix
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     export XDG_CONFIG_DIRS=@out@/etc''${XDG_CONFIG_DIRS:+:''${XDG_CONFIG_DIRS}}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LunarG Vulkan Tools and Utilities";
     longDescription = ''
       Tools to aid in Vulkan development including useful layers, trace and
diff --git a/pkgs/tools/graphics/vulkan-tools/default.nix b/pkgs/tools/graphics/vulkan-tools/default.nix
index 3f5a98271573c..87e7b861554b8 100644
--- a/pkgs/tools/graphics/vulkan-tools/default.nix
+++ b/pkgs/tools/graphics/vulkan-tools/default.nix
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     "-DCMAKE_INSTALL_RPATH=${libraryPath}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Khronos official Vulkan Tools and Utilities";
     longDescription = ''
       This project provides Vulkan tools and utilities that can assist
diff --git a/pkgs/tools/graphics/xcur2png/default.nix b/pkgs/tools/graphics/xcur2png/default.nix
index f917328460c2a..694dba091760d 100644
--- a/pkgs/tools/graphics/xcur2png/default.nix
+++ b/pkgs/tools/graphics/xcur2png/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libpng, xorg }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libpng, xorg }:
 
 stdenv.mkDerivation rec {
   pname = "xcur2png";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     xorg.xorgproto
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/eworm-de/xcur2png/releases";
     description = "Convert X cursors to PNG images";
     license = licenses.gpl3;
diff --git a/pkgs/tools/graphics/yafaray-core/default.nix b/pkgs/tools/graphics/yafaray-core/default.nix
index 3e2f9484b1930..f0dd183dc2c68 100644
--- a/pkgs/tools/graphics/yafaray-core/default.nix
+++ b/pkgs/tools/graphics/yafaray-core/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, opencv, zlib
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, opencv, zlib
 , libxml2, freetype, libjpeg, libtiff, swig, openexr
 , ilmbase, boost165
 , withPython ? true, python3
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       swig openexr ilmbase
     ] ++ stdenv.lib.optional withPython python3;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A free, open source raytracer";
       homepage = "http://www.yafaray.org";
       maintainers = with maintainers; [ hodapp ];
diff --git a/pkgs/tools/graphics/yaxg/default.nix b/pkgs/tools/graphics/yaxg/default.nix
index 467210b27b35b..ff7e26064ae91 100644
--- a/pkgs/tools/graphics/yaxg/default.nix
+++ b/pkgs/tools/graphics/yaxg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper,
+{ lib, stdenv, fetchFromGitHub, makeWrapper,
   maim, slop, ffmpeg_3, byzanz, libnotify, xdpyinfo }:
 
 stdenv.mkDerivation rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/yaxg --prefix PATH : ${ stdenv.lib.makeBinPath [ maim slop ffmpeg_3 byzanz libnotify xdpyinfo ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Yet Another X Grabber script";
     longDescription = ''
diff --git a/pkgs/tools/inputmethods/anthy/default.nix b/pkgs/tools/inputmethods/anthy/default.nix
index 9214edfefb05d..f337d4648d573 100644
--- a/pkgs/tools/inputmethods/anthy/default.nix
+++ b/pkgs/tools/inputmethods/anthy/default.nix
@@ -1,9 +1,9 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "anthy-9100h";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Hiragana text to Kana Kanji mixed text Japanese input method";
     homepage    = "https://anthy.osdn.jp/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/tools/inputmethods/evdevremapkeys/default.nix b/pkgs/tools/inputmethods/evdevremapkeys/default.nix
index d70bf80d1ce2c..99f7231c58a4f 100644
--- a/pkgs/tools/inputmethods/evdevremapkeys/default.nix
+++ b/pkgs/tools/inputmethods/evdevremapkeys/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonPackage rec {
   pname = "evdevremapkeys";
@@ -23,7 +23,7 @@ python3Packages.buildPythonPackage rec {
 
   pythonImportsCheck = [ "evdevremapkeys" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/philipl/evdevremapkeys";
     description = "Daemon to remap events on linux input devices";
     license = licenses.mit;
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-anthy/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-anthy/default.nix
index d8438abe61175..3fe5a59175f2e 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-anthy/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-anthy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, fcitx, anthy, gettext, pkg-config }:
+{ lib, stdenv, fetchurl, cmake, fcitx, anthy, gettext, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-anthy";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     description   = "Fcitx Wrapper for anthy";
     license       = licenses.gpl2Plus;
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-chewing/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-chewing/default.nix
index c934724ff48e7..defbe616ab22f 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-chewing/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-chewing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, fcitx, gettext, libchewing, pkg-config }:
+{ lib, stdenv, fetchurl, cmake, fcitx, gettext, libchewing, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-chewing";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     homepage      = "https://github.com/fcitx/fcitx-chewing";
     downloadPage  = "http://download.fcitx-im.org/fcitx-chewing/";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-cloudpinyin/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-cloudpinyin/default.nix
index 813b995da512f..d84407e982b08 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-cloudpinyin/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-cloudpinyin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkg-config, fcitx, gettext, curl }:
+{ lib, stdenv, fetchurl, cmake, pkg-config, fcitx, gettext, curl }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-cloudpinyin";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     description  = "A standalone module for fcitx that uses web API to provide better pinyin result";
     homepage     = "https://github.com/fcitx/fcitx-cloudpinyin";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-hangul/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-hangul/default.nix
index d6424bdee3095..d99a0228e2262 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-hangul/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-hangul/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, fcitx, libhangul, gettext, pkg-config }:
+{ lib, stdenv, fetchurl, cmake, fcitx, libhangul, gettext, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-hangul";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     homepage      = "https://github.com/fcitx/fcitx-hangul";
     downloadPage  = "http://download.fcitx-im.org/fcitx-hangul/";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-libpinyin/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-libpinyin/default.nix
index e9f7511abdb91..2af4061ae0463 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-libpinyin/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-libpinyin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkg-config, fcitx, gettext, libpinyin, glib, pcre, dbus, qtwebengine, qtbase, fcitx-qt5 }:
+{ lib, stdenv, fetchurl, cmake, pkg-config, fcitx, gettext, libpinyin, glib, pcre, dbus, qtwebengine, qtbase, fcitx-qt5 }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-libpinyin";
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
       cp -rv ${store_path} $NIX_BUILD_TOP/$name/data/${ZHUYIN_DATA_FILE_NAME}
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     description  = "Fcitx Wrapper for libpinyin, Library to deal with pinyin";
     homepage     = "https://github.com/fcitx/fcitx-libpinyin";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-m17n/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-m17n/default.nix
index ed0aa2e79d5e6..31a7355598840 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-m17n/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-m17n/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, fcitx, gettext, m17n_lib, m17n_db, pkg-config }:
+{ lib, stdenv, fetchurl, cmake, fcitx, gettext, m17n_lib, m17n_db, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-m17n";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     --replace ${fcitx} $out
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     homepage      = "https://github.com/fcitx/fcitx-m17n";
     downloadPage  = "http://download.fcitx-im.org/fcitx-table-other/";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-rime/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-rime/default.nix
index d96cc266237a3..42c02fe003d7e 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-rime/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-rime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkg-config, fcitx, librime, brise, hicolor-icon-theme }:
+{ lib, stdenv, fetchurl, cmake, pkg-config, fcitx, librime, brise, hicolor-icon-theme }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-rime";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
        --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     homepage      = "https://github.com/fcitx/fcitx-rime";
     downloadPage  = "https://download.fcitx-im.org/fcitx-rime/";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-skk/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-skk/default.nix
index 187587fbfb49e..5bbcf83cb48fb 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-skk/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-skk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, fcitx, libskk, skk-dicts }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, fcitx, libskk, skk-dicts }:
 
 stdenv.mkDerivation {
   pname = "fcitx-skk";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     description   = "A SKK style input method engine for fcitx";
     longDescription = ''
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-extra/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-extra/default.nix
index 3ec639a05cc60..399d426dc3e82 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-extra/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-extra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, fcitx, gettext }:
+{ lib, stdenv, fetchurl, cmake, fcitx, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-table-extra";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     homepage      = "https://github.com/fcitx/fcitx-table-extra";
     downloadPage  = "http://download.fcitx-im.org/fcitx-table-extra/";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-other/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-other/default.nix
index 970c57a3f4a5a..410569b7afbd4 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-other/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-table-other/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, fcitx, gettext }:
+{ lib, stdenv, fetchurl, cmake, fcitx, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-table-other";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     homepage      = "https://github.com/fcitx/fcitx-table-other";
     downloadPage  = "http://download.fcitx-im.org/fcitx-table-other/";
diff --git a/pkgs/tools/inputmethods/fcitx-engines/fcitx-unikey/default.nix b/pkgs/tools/inputmethods/fcitx-engines/fcitx-unikey/default.nix
index 91702b5091350..5422efb9d38df 100644
--- a/pkgs/tools/inputmethods/fcitx-engines/fcitx-unikey/default.nix
+++ b/pkgs/tools/inputmethods/fcitx-engines/fcitx-unikey/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, fcitx, gettext, pkg-config }:
+{ lib, stdenv, fetchurl, cmake, fcitx, gettext, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "fcitx-unikey";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       --replace ${fcitx} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isFcitxEngine = true;
     homepage      = "https://github.com/fcitx/fcitx-unikey";
     downloadPage  = "http://download.fcitx-im.org/fcitx-table-other/";
diff --git a/pkgs/tools/inputmethods/fcitx/fcitx-configtool.nix b/pkgs/tools/inputmethods/fcitx/fcitx-configtool.nix
index 1fd6f2daf2eb9..6e0c48d0610c6 100644
--- a/pkgs/tools/inputmethods/fcitx/fcitx-configtool.nix
+++ b/pkgs/tools/inputmethods/fcitx/fcitx-configtool.nix
@@ -1,9 +1,9 @@
-{ stdenv, fetchurl, makeWrapper, pkg-config, cmake, fcitx, gtk3, isocodes, gnome3 }:
+{ lib, stdenv, fetchurl, makeWrapper, pkg-config, cmake, fcitx, gtk3, isocodes, gnome3 }:
 
 stdenv.mkDerivation rec {
   name = "fcitx-configtool-0.4.10";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK-based config tool for Fcitx";
     license     = licenses.gpl2;
     platforms   = platforms.linux;
diff --git a/pkgs/tools/inputmethods/fcitx/unwrapped.nix b/pkgs/tools/inputmethods/fcitx/unwrapped.nix
index 99a92a95060a6..180dc302ca0c4 100644
--- a/pkgs/tools/inputmethods/fcitx/unwrapped.nix
+++ b/pkgs/tools/inputmethods/fcitx/unwrapped.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, cmake, intltool, gettext
+{ lib, stdenv, fetchurl, pkgconfig, cmake, intltool, gettext
 , libxml2, enchant2, isocodes, icu, libpthreadstubs
 , pango, cairo, libxkbfile, libXau, libXdmcp, libxkbcommon
 , dbus, gtk2, gtk3, qt4, extra-cmake-modules
@@ -90,7 +90,7 @@ stdenv.mkDerivation rec {
     "-DXKB_RULES_XML_FILE='${xkeyboard_config}/share/X11/xkb/rules/evdev.xml'"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/fcitx/fcitx";
     description = "A Flexible Input Method Framework";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/inputmethods/hime/default.nix b/pkgs/tools/inputmethods/hime/default.nix
index 4d2b44456ae73..894e8768c2825 100644
--- a/pkgs/tools/inputmethods/hime/default.nix
+++ b/pkgs/tools/inputmethods/hime/default.nix
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
   configureFlags = [ "--disable-lib64" "--disable-qt5-immodule" ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://hime-ime.github.io/";
     downloadPage = "https://github.com/hime-ime/hime/downloads";
     description = "A useful input method engine for Asia region";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-anthy/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-anthy/default.nix
index 34d918cb7da76..ecc142ac16cef 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-anthy/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-anthy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gettext
 , pkgconfig
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/share/ibus/component/anthy.xml --replace \$\{exec_prefix\} $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description = "IBus interface to the anthy input method";
     homepage = "https://github.com/fujiwarat/ibus-anthy";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-bamboo/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-bamboo/default.nix
index 18e878b47b5c6..61ea12ff59b28 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-bamboo/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-bamboo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gettext
 , xorg
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
   ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description = "A Vietnamese IME for IBus";
     homepage = "https://github.com/BambooEngine/ibus-bamboo";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix
index f6ceece34e19b..531aeb3d6643f 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-hangul/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , substituteAll
 , appstream-glib
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     ]))
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description = "Ibus Hangul engine";
     homepage = "https://github.com/choehwanjin/ibus-hangul";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-kkc/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-kkc/default.nix
index 0b16b54ad48b6..cdebf64d8629b 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-kkc/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-kkc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , vala, intltool, pkgconfig
 , libkkc, ibus, skk-dicts
 , gtk3
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     ln -s ${skk-dicts}/share $out/share/skk
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description  = "libkkc (Japanese Kana Kanji input method) engine for ibus";
     homepage     = "https://github.com/ueno/ibus-kkc";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-libpinyin/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-libpinyin/default.nix
index 2c1d558f04d39..18cd2ec4ed833 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-libpinyin/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-libpinyin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , gettext
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     db
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description = "IBus interface to the libpinyin input method";
     license = licenses.gpl2;
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-libthai/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-libthai/default.nix
index 9c5f2cefb5172..1bb2479b49977 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-libthai/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-libthai/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, pkg-config, ibus, gtk3, libthai }:
+{ lib, stdenv, fetchurl, makeWrapper, pkg-config, ibus, gtk3, libthai }:
 
 stdenv.mkDerivation rec {
   pname = "ibus-libthai";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ gtk3 ibus libthai ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     homepage = "https://linux.thai.net/projects/ibus-libthai";
     description = "Thai input method engine for IBus";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-m17n/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-m17n/default.nix
index 35e02d52b486f..252fc2b286b65 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-m17n/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-m17n/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkgconfig
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
     "--with-gtk=3.0"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description = "m17n engine for ibus";
     homepage = "https://github.com/ibus/ibus-m17n";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-mozc/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-mozc/default.nix
index 695a45d81ffc6..8964b18098971 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-mozc/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-mozc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which, ninja, python, pkgconfig, protobuf
+{ lib, stdenv, fetchFromGitHub, which, ninja, python, pkgconfig, protobuf
 , ibus, gtk2, zinnia, qt5, libxcb, tegaki-zinnia-japanese, python3Packages }:
 
 let
@@ -12,7 +12,7 @@ in stdenv.mkDerivation rec {
   name = "ibus-mozc-${version}";
   version = "2.23.4206.102";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description  = "Japanese input method from Google";
     homepage     = "https://github.com/google/mozc";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-rime/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-rime/default.nix
index 03a801abbeb01..d444d44f23372 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-rime/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-rime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, gdk-pixbuf, glib, ibus, libnotify
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, gdk-pixbuf, glib, ibus, libnotify
 , librime, brise }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
        --replace '/usr' $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description = "Rime input method engine for IBus";
     homepage = "https://rime.im/";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-table-chinese/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-table-chinese/default.nix
index 402013d8c5d4c..40c33aff40118 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-table-chinese/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-table-chinese/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchFromGitHub, pkg-config, ibus, ibus-table, python3, cmake }:
+{ lib, stdenv, fetchgit, fetchFromGitHub, pkg-config, ibus, ibus-table, python3, cmake }:
 
 let
   src = fetchFromGitHub {
@@ -54,7 +54,7 @@ in stdenv.mkDerivation {
   nativeBuildInputs = [ cmake pkg-config ];
   buildInputs = [ ibus ibus-table python3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description  = "Chinese tables for IBus-Table";
     homepage     = "https://github.com/definite/ibus-table-chinese";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-table-others/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-table-others/default.nix
index b74378f079345..0c7670fd250c4 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-table-others/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-table-others/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ibus, ibus-table, pkgconfig, python3 }:
+{ lib, stdenv, fetchurl, ibus, ibus-table, pkgconfig, python3 }:
 
 stdenv.mkDerivation rec {
   pname = "ibus-table-others";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     rm -rf $HOME
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description  = "Various table-based input methods for IBus";
     homepage     = "https://github.com/moebiuscurve/ibus-table-others";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-table/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-table/default.nix
index 831161df2b7bf..f923c630d177f 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-table/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-table/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook, docbook2x, pkgconfig
 , gtk3, dconf, gobject-introspection
 , ibus, python3, wrapGAppsHook }:
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
       --replace "docbook2man" "docbook2man --sgml"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description  = "An IBus framework for table-based input methods";
     homepage     = "https://github.com/kaio/ibus-table/wiki";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-typing-booster/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-typing-booster/default.nix
index cc0d12745b125..a8336e1d79507 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-typing-booster/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-typing-booster/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, python3, ibus, pkgconfig, gtk3, m17n_lib
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, python3, ibus, pkgconfig, gtk3, m17n_lib
 , wrapGAppsHook, gobject-introspection
 }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     gappsWrapperArgs+=(--prefix LD_LIBRARY_PATH : "${m17n_lib}/lib")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mike-fabian.github.io/ibus-typing-booster/";
     license = licenses.gpl3Plus;
     description = "A typing booster engine for the IBus platform";
diff --git a/pkgs/tools/inputmethods/ibus-engines/ibus-uniemoji/default.nix b/pkgs/tools/inputmethods/ibus-engines/ibus-uniemoji/default.nix
index 435d1154d4ad6..38f746e3ceeb8 100644
--- a/pkgs/tools/inputmethods/ibus-engines/ibus-uniemoji/default.nix
+++ b/pkgs/tools/inputmethods/ibus-engines/ibus-uniemoji/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gobject-introspection
 , wrapGAppsHook
@@ -51,7 +51,7 @@ in stdenv.mkDerivation rec {
     wrapGApp $out/share/ibus-uniemoji/uniemoji.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     isIbusEngine = true;
     description = "Input method (ibus) for entering unicode symbols and emoji by name";
     homepage = "https://github.com/salty-horse/ibus-uniemoji";
diff --git a/pkgs/tools/inputmethods/ibus/ibus-qt.nix b/pkgs/tools/inputmethods/ibus/ibus-qt.nix
index 709462c5e9699..4f6a4e1bef3e3 100644
--- a/pkgs/tools/inputmethods/ibus/ibus-qt.nix
+++ b/pkgs/tools/inputmethods/ibus/ibus-qt.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ibus, cmake, pkg-config, qt4, icu, doxygen }:
+{ lib, stdenv, fetchurl, ibus, cmake, pkg-config, qt4, icu, doxygen }:
 
 stdenv.mkDerivation rec {
   pname = "ibus-qt";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   cmakeFlags = [ "-DQT_PLUGINS_DIR=lib/qt4/plugins" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://github.com/ibus/ibus-qt/";
     description = "Qt4 interface to the ibus input method";
     platforms   = platforms.linux;
diff --git a/pkgs/tools/inputmethods/interception-tools/caps2esc.nix b/pkgs/tools/inputmethods/interception-tools/caps2esc.nix
index 7e6206eb1f37d..ab4242295a0f8 100644
--- a/pkgs/tools/inputmethods/interception-tools/caps2esc.nix
+++ b/pkgs/tools/inputmethods/interception-tools/caps2esc.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, cmake }:
+{ lib, stdenv, fetchFromGitLab, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "caps2esc";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/interception/linux/plugins/caps2esc";
     description = "Transforming the most useless key ever into the most useful one";
     license = licenses.mit;
diff --git a/pkgs/tools/inputmethods/keyfuzz/default.nix b/pkgs/tools/inputmethods/keyfuzz/default.nix
index 0b2883f70a456..8980abba2f628 100644
--- a/pkgs/tools/inputmethods/keyfuzz/default.nix
+++ b/pkgs/tools/inputmethods/keyfuzz/default.nix
@@ -1,10 +1,10 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   pname = "keyfuzz";
   version = "0.2";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manipulate the scancode/keycode translation tables of keyboard drivers";
     homepage    = "http://0pointer.de/lennart/projects/keyfuzz/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/tools/inputmethods/libinput-gestures/default.nix b/pkgs/tools/inputmethods/libinput-gestures/default.nix
index b816a6898ab3f..1d0ea40e34f41 100644
--- a/pkgs/tools/inputmethods/libinput-gestures/default.nix
+++ b/pkgs/tools/inputmethods/libinput-gestures/default.nix
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
       wrapProgram "$out/bin/libinput-gestures" --prefix PATH : "${lib.makeBinPath ([coreutils] ++ extraUtilsPath)}"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bulletmark/libinput-gestures";
     description = "Gesture mapper for libinput";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/inputmethods/libkkc/default.nix b/pkgs/tools/inputmethods/libkkc/default.nix
index 1e24d5d969f9e..c8cb927b6ab2e 100644
--- a/pkgs/tools/inputmethods/libkkc/default.nix
+++ b/pkgs/tools/inputmethods/libkkc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , vala, gobject-introspection, intltool, python2Packages, glib
 , pkgconfig
 , libgee, json-glib, marisa, libkkc-data
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     ln -s ${libkkc-data}/lib/libkkc/models $out/share/libkkc/models
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Japanese Kana Kanji conversion input method library";
     homepage    = "https://github.com/ueno/libkkc";
     license     = licenses.gpl3Plus;
diff --git a/pkgs/tools/inputmethods/nabi/default.nix b/pkgs/tools/inputmethods/nabi/default.nix
index ef316ec55a0af..167dd7b030da8 100644
--- a/pkgs/tools/inputmethods/nabi/default.nix
+++ b/pkgs/tools/inputmethods/nabi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk2, libhangul }:
+{ lib, stdenv, fetchurl, pkgconfig, gtk2, libhangul }:
 
 stdenv.mkDerivation {
   name = "nabi-1.0.0";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ gtk2 libhangul ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Easy Hangul XIM";
     homepage = "https://github.com/choehwanjin/nabi";
     license = licenses.gpl2;
diff --git a/pkgs/tools/inputmethods/netevent/default.nix b/pkgs/tools/inputmethods/netevent/default.nix
index f845111f4b94f..b7c0e4d47020e 100644
--- a/pkgs/tools/inputmethods/netevent/default.nix
+++ b/pkgs/tools/inputmethods/netevent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, docutils, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, docutils, installShellFiles }:
 
 stdenv.mkDerivation {
   pname = "netevent";
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     cp doc/netevent.rst $doc/share/doc/netevent/netevent.rst
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Share linux event devices with other machines";
     homepage = "https://github.com/Blub/netevent";
     license = licenses.gpl2Only;
diff --git a/pkgs/tools/inputmethods/tegaki-zinnia-japanese/default.nix b/pkgs/tools/inputmethods/tegaki-zinnia-japanese/default.nix
index 4295e2b3fdd88..6829de9241b44 100644
--- a/pkgs/tools/inputmethods/tegaki-zinnia-japanese/default.nix
+++ b/pkgs/tools/inputmethods/tegaki-zinnia-japanese/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 stdenv.mkDerivation {
   pname = "tegaki-zinnia-japanese";
@@ -9,7 +9,7 @@ stdenv.mkDerivation {
     sha256 = "1nmg9acxhcqly9gwkyb9m0hpy76fll91ywk4b1q4xms0ajxip1h7";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Japanese handwriting model for the Zinnia engine";
     homepage = "http://tegaki.org/";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/inputmethods/triggerhappy/default.nix b/pkgs/tools/inputmethods/triggerhappy/default.nix
index 22987fe639f60..b89f205a06484 100644
--- a/pkgs/tools/inputmethods/triggerhappy/default.nix
+++ b/pkgs/tools/inputmethods/triggerhappy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, perl, systemd }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, perl, systemd }:
 
 stdenv.mkDerivation rec {
   pname = "triggerhappy";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -D -m 644 -t "$out/etc/triggerhappy/triggers.d" "triggerhappy.conf.examples"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight hotkey daemon";
     longDescription = ''
       Triggerhappy is a hotkey daemon developed with small and embedded systems in
diff --git a/pkgs/tools/inputmethods/uim/default.nix b/pkgs/tools/inputmethods/uim/default.nix
index 7fe00bd4dfce3..f7ee905b9eee3 100644
--- a/pkgs/tools/inputmethods/uim/default.nix
+++ b/pkgs/tools/inputmethods/uim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, shared-mime-info
+{ lib, stdenv, fetchFromGitHub, shared-mime-info
 , autoconf, automake, intltool, libtool, pkgconfig, cmake
 , ruby, librsvg
 , ncurses, m17n_lib, m17n_db, expat
@@ -135,7 +135,7 @@ stdenv.mkDerivation rec {
 
   dontUseCmakeConfigure = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = src.meta.homepage;
     description = "A multilingual input method framework";
     license     = licenses.bsd3;
diff --git a/pkgs/tools/inputmethods/zinnia/default.nix b/pkgs/tools/inputmethods/zinnia/default.nix
index b1516aa56ab05..8070dbc66ba89 100644
--- a/pkgs/tools/inputmethods/zinnia/default.nix
+++ b/pkgs/tools/inputmethods/zinnia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "zinnia";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     sourceRoot=$(echo */zinnia)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Online hand recognition system with machine learning";
     homepage = "http://taku910.github.io/zinnia/";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/0x0/default.nix b/pkgs/tools/misc/0x0/default.nix
index d78846922c6e6..1fc081d71abf0 100644
--- a/pkgs/tools/misc/0x0/default.nix
+++ b/pkgs/tools/misc/0x0/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, xsel, curl, fetchFromGitLab, makeWrapper}:
+{ lib, stdenv, xsel, curl, fetchFromGitLab, makeWrapper}:
 
 stdenv.mkDerivation {
   pname = "0x0";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
       --prefix PATH : '${stdenv.lib.makeBinPath [ curl xsel ]}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A client for 0x0.st";
     homepage = "https://gitlab.com/somasis/scripts/";
     maintainers = [ maintainers.ar1a ];
diff --git a/pkgs/tools/misc/3mux/default.nix b/pkgs/tools/misc/3mux/default.nix
index 945ebea0cb894..3f1e981fd0e32 100644
--- a/pkgs/tools/misc/3mux/default.nix
+++ b/pkgs/tools/misc/3mux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "3mux";
@@ -13,7 +13,7 @@ buildGoModule rec {
 
   vendorSha256 = "sha256-rcbnyScD2GU1DLY6dTEPgFNXZfgkxXPn5lt6HRqa0d8=";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal multiplexer inspired by i3";
     longDescription = ''
       3mux is a terminal multiplexer with out-of-the-box support for search,
diff --git a/pkgs/tools/misc/adafruit-ampy/default.nix b/pkgs/tools/misc/adafruit-ampy/default.nix
index 31ef3e2487bec..f514973763931 100644
--- a/pkgs/tools/misc/adafruit-ampy/default.nix
+++ b/pkgs/tools/misc/adafruit-ampy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3 }:
+{ lib, stdenv, python3 }:
 
 with python3.pkgs;
 
@@ -17,7 +17,7 @@ buildPythonApplication rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pycampers/ampy";
     license = licenses.mit;
     description = "Utility to interact with a MicroPython board over a serial connection";
diff --git a/pkgs/tools/misc/aescrypt/default.nix b/pkgs/tools/misc/aescrypt/default.nix
index 42941c263e6d0..05ee0145636fe 100644
--- a/pkgs/tools/misc/aescrypt/default.nix
+++ b/pkgs/tools/misc/aescrypt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libiconv }:
+{ lib, stdenv, fetchurl, libiconv }:
 
 stdenv.mkDerivation rec {
   version = "3.14";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libiconv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Encrypt files with Advanced Encryption Standard (AES)";
     homepage    = "https://www.aescrypt.com/";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/misc/agedu/default.nix b/pkgs/tools/misc/agedu/default.nix
index 3cdfa36337f8f..2146d0c24914d 100644
--- a/pkgs/tools/misc/agedu/default.nix
+++ b/pkgs/tools/misc/agedu/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchgit, autoreconfHook, halibut}:
+{lib, stdenv, fetchgit, autoreconfHook, halibut}:
 let
   date = "20200705";
   rev = "2a7d4a2";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   nativeBuildInputs = [autoreconfHook halibut];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Unix utility for tracking down wasted disk space";
     longDescription = ''
        Most Unix file systems, in their default mode, helpfully record when a
diff --git a/pkgs/tools/misc/alarm-clock-applet/default.nix b/pkgs/tools/misc/alarm-clock-applet/default.nix
index 3102dd635ca2e..6ad9341b85e39 100644
--- a/pkgs/tools/misc/alarm-clock-applet/default.nix
+++ b/pkgs/tools/misc/alarm-clock-applet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgconfig
 , autoconf
 , automake111x
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://alarm-clock.pseudoberries.com/";
     description = "A fully-featured alarm clock for your GNOME panel or equivalent";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/apparix/default.nix b/pkgs/tools/misc/apparix/default.nix
index 155fa8190d9f8..7d8de2c143675 100644
--- a/pkgs/tools/misc/apparix/default.nix
+++ b/pkgs/tools/misc/apparix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "apparix-11-062";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://micans.org/apparix";
     description = "Add directory bookmarks, distant listing, and distant editing to the command line";
     maintainers = with maintainers; [ lethalman ];
diff --git a/pkgs/tools/misc/apt-offline/default.nix b/pkgs/tools/misc/apt-offline/default.nix
index 7e29c63347ddd..5c17b7f2d1313 100644
--- a/pkgs/tools/misc/apt-offline/default.nix
+++ b/pkgs/tools/misc/apt-offline/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   version = "1.8.1";
@@ -16,7 +16,7 @@ python3Packages.buildPythonApplication rec {
   # Requires python-qt4 (feel free to get it working).
   preFixup = ''rm "$out/bin/apt-offline-gui"'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Offline APT package manager";
     license = licenses.gpl3;
     maintainers = [ ];
diff --git a/pkgs/tools/misc/aptly/default.nix b/pkgs/tools/misc/aptly/default.nix
index 6af3238dbd771..2ee81460b2833 100644
--- a/pkgs/tools/misc/aptly/default.nix
+++ b/pkgs/tools/misc/aptly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, installShellFiles, makeWrapper, gnupg, bzip2, xz, graphviz }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, installShellFiles, makeWrapper, gnupg, bzip2, xz, graphviz }:
 
 let
 
@@ -37,7 +37,7 @@ buildGoPackage {
       --prefix PATH ":" "${stdenv.lib.makeBinPath [ gnupg bzip2 xz graphviz ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.aptly.info";
     description = "Debian repository management tool";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/archi/default.nix b/pkgs/tools/misc/archi/default.nix
index 41562ccbf7110..554700dad93fc 100644
--- a/pkgs/tools/misc/archi/default.nix
+++ b/pkgs/tools/misc/archi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchzip
 , autoPatchelfHook
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
         mv Archi.app "$out/Applications/"
       '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ArchiMate modelling toolkit";
     longDescription = ''
       Archi is an open source modelling toolkit to create ArchiMate
diff --git a/pkgs/tools/misc/arp-scan/default.nix b/pkgs/tools/misc/arp-scan/default.nix
index 9a3164db5d7ca..f4786a57bd75f 100644
--- a/pkgs/tools/misc/arp-scan/default.nix
+++ b/pkgs/tools/misc/arp-scan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, libpcap, makeWrapper, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, libpcap, makeWrapper, perlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "arp-scan";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     done;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ARP scanning and fingerprinting tool";
     longDescription = ''
       Arp-scan is a command-line tool that uses the ARP protocol to discover
diff --git a/pkgs/tools/misc/asciinema-scenario/default.nix b/pkgs/tools/misc/asciinema-scenario/default.nix
index cff96a4ec86cf..25bac97684382 100644
--- a/pkgs/tools/misc/asciinema-scenario/default.nix
+++ b/pkgs/tools/misc/asciinema-scenario/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchCrate
 }:
@@ -14,7 +14,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "109ij5h31bhn44l0wywgpnnlfjgyairxr5l19s6bz47sbka0xyxk";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create asciinema videos from a text file";
     homepage = "https://github.com/garbas/asciinema-scenario/";
     maintainers = with maintainers; [ garbas ];
diff --git a/pkgs/tools/misc/aspcud/default.nix b/pkgs/tools/misc/aspcud/default.nix
index a42e6c4a428ef..4c5622fab09c4 100644
--- a/pkgs/tools/misc/aspcud/default.nix
+++ b/pkgs/tools/misc/aspcud/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip
+{ lib, stdenv, fetchzip
 , boost, clasp, cmake, gringo, re2c
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     "-DASPCUD_CLASP_PATH=${clasp}/bin/clasp"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Solver for package problems in CUDF format using ASP";
     homepage = "https://potassco.org/aspcud/";
     platforms = platforms.all;
diff --git a/pkgs/tools/misc/autojump/default.nix b/pkgs/tools/misc/autojump/default.nix
index c1a55256b35a0..47c4cbcb4e744 100644
--- a/pkgs/tools/misc/autojump/default.nix
+++ b/pkgs/tools/misc/autojump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, bash }:
+{ lib, stdenv, fetchFromGitHub, python3, bash }:
 
 stdenv.mkDerivation rec {
   pname = "autojump";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     install -Dt "$out/share/zsh/site-functions/" -m444 "$out/share/autojump/autojump.zsh"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A `cd' command that learns";
     longDescription = ''
       One of the most used shell commands is “cd”.  A quick survey
diff --git a/pkgs/tools/misc/automirror/default.nix b/pkgs/tools/misc/automirror/default.nix
index dde9c2d02d3ad..cc10c93b3f654 100644
--- a/pkgs/tools/misc/automirror/default.nix
+++ b/pkgs/tools/misc/automirror/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, git, ronn}:
+{lib, stdenv, fetchFromGitHub, git, ronn}:
 
 stdenv.mkDerivation rec {
   pname = "automirror";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/schlomo/automirror";
     description = "Automatic Display Mirror";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/autorandr/default.nix b/pkgs/tools/misc/autorandr/default.nix
index 376b661816698..1d4a3a2b6ec99 100644
--- a/pkgs/tools/misc/autorandr/default.nix
+++ b/pkgs/tools/misc/autorandr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python3Packages
 , fetchFromGitHub
 , systemd
@@ -56,7 +56,7 @@ in
       sha256 = "0rmnqk2bi6bbd2if1rll37mlzlqxzmnazfffdhcpzskxwyaj4yn5";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/phillipberndt/autorandr/";
       description = "Automatically select a display configuration based on connected devices";
       license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/autorevision/default.nix b/pkgs/tools/misc/autorevision/default.nix
index abaca62c400c1..61bd5b5fc652d 100644
--- a/pkgs/tools/misc/autorevision/default.nix
+++ b/pkgs/tools/misc/autorevision/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, asciidoc, libxml2, docbook_xml_dtd_45, libxslt
+{ lib, stdenv, fetchurl, asciidoc, libxml2, docbook_xml_dtd_45, libxslt
 , docbook_xsl, diffutils, coreutils, gnugrep, gnused
 }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
         -i "$out/bin/autorevision"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extracts revision metadata from your VCS repository";
     homepage = "https://autorevision.github.io/";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/azure-vhd-utils/default.nix b/pkgs/tools/misc/azure-vhd-utils/default.nix
index bfb622ee74190..cb38f2705b12a 100644
--- a/pkgs/tools/misc/azure-vhd-utils/default.nix
+++ b/pkgs/tools/misc/azure-vhd-utils/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by go2nix.
-{ stdenv, buildGoPackage, fetchgit }:
+{ lib, stdenv, buildGoPackage, fetchgit }:
 
 buildGoPackage rec {
   pname = "azure-vhd-utils";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Microsoft/azure-vhd-utils";
     description = "Read, inspect and upload VHD files for Azure";
     longDescription = "Go package to read Virtual Hard Disk (VHD) file, a CLI interface to upload local VHD to Azure storage and to inspect a local VHD";
diff --git a/pkgs/tools/misc/bandwidth/default.nix b/pkgs/tools/misc/bandwidth/default.nix
index 024454a3472db..677a9ddef5140 100644
--- a/pkgs/tools/misc/bandwidth/default.nix
+++ b/pkgs/tools/misc/bandwidth/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nasm }:
+{ lib, stdenv, fetchurl, nasm }:
 
 let
   inherit (stdenv.hostPlatform.parsed.cpu) bits;
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     cp ${arch} $out/bin/bandwidth
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zsmith.co/bandwidth.html";
     description = "Artificial benchmark for identifying weaknesses in the memory subsystem";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/bash_unit/default.nix b/pkgs/tools/misc/bash_unit/default.nix
index abfe4078870e1..2fd93cb33b97b 100644
--- a/pkgs/tools/misc/bash_unit/default.nix
+++ b/pkgs/tools/misc/bash_unit/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp bash_unit $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bash unit testing enterprise edition framework for professionals";
     maintainers = with maintainers; [ pamplemousse ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/misc/bashcards/default.nix b/pkgs/tools/misc/bashcards/default.nix
index 3e91b9741c633..30a442ef56233 100644
--- a/pkgs/tools/misc/bashcards/default.nix
+++ b/pkgs/tools/misc/bashcards/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp bashcards $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Practice flashcards in bash";
     homepage = "https://github.com/rpearce/bashcards/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/bashplotlib/default.nix b/pkgs/tools/misc/bashplotlib/default.nix
index 3e8ae31835a6b..cc3476f598b7d 100644
--- a/pkgs/tools/misc/bashplotlib/default.nix
+++ b/pkgs/tools/misc/bashplotlib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 python3Packages.buildPythonApplication {
   pname = "bashplotlib";
@@ -14,7 +14,7 @@ python3Packages.buildPythonApplication {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/glamp/bashplotlib";
     description = "Plotting in the terminal";
     maintainers = with maintainers; [ dtzWill ];
diff --git a/pkgs/tools/misc/bat-extras/default.nix b/pkgs/tools/misc/bat-extras/default.nix
index 36adc09cdba10..a2ec5afd965ae 100644
--- a/pkgs/tools/misc/bat-extras/default.nix
+++ b/pkgs/tools/misc/bat-extras/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, callPackage, fetchFromGitHub, bash, makeWrapper, bat
+{ lib, stdenv, callPackage, fetchFromGitHub, bash, makeWrapper, bat
 # batdiff, batgrep, and batwatch
 , coreutils
 , less
@@ -76,7 +76,7 @@ let
     # The per-script derivations will go ahead and patch the files they actually install.
     dontPatchShebangs = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Bash scripts that integrate bat with various command line tools";
       homepage    = "https://github.com/eth-p/bat-extras";
       license     = with licenses; [ mit ];
diff --git a/pkgs/tools/misc/bat/default.nix b/pkgs/tools/misc/bat/default.nix
index 5c60305a2e749..ac043ca7fea02 100644
--- a/pkgs/tools/misc/bat/default.nix
+++ b/pkgs/tools/misc/bat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , nixosTests
 , rustPlatform
 , fetchFromGitHub
@@ -41,7 +41,7 @@ rustPlatform.buildRustPackage rec {
 
   passthru.tests = { inherit (nixosTests) bat; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cat(1) clone with syntax highlighting and Git integration";
     homepage = "https://github.com/sharkdp/bat";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/tools/misc/bbe/default.nix b/pkgs/tools/misc/bbe/default.nix
index b0af13160d218..fb62b8be8947d 100644
--- a/pkgs/tools/misc/bbe/default.nix
+++ b/pkgs/tools/misc/bbe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv , fetchurl, autoreconfHook }:
+{ lib, stdenv , fetchurl, autoreconfHook }:
 stdenv.mkDerivation rec {
   pname = "bbe";
   version = "0.2.2";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "doc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A sed-like editor for binary files";
     homepage = "http://bbe-.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/bcunit/default.nix b/pkgs/tools/misc/bcunit/default.nix
index 95a9d6f98f8c8..bc3bbc8276dd7 100644
--- a/pkgs/tools/misc/bcunit/default.nix
+++ b/pkgs/tools/misc/bcunit/default.nix
@@ -1,6 +1,6 @@
 { cmake
 , fetchFromGitLab
-, stdenv
+, lib, stdenv
 }:
 
 stdenv.mkDerivation rec {
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     sha256 = "1237hpmkls2igp60gdfkbknxpgwvxn1vmv2m41vyl25xw1d3g35w";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     description = "A fork of CUnit test framework";
     homepage = "https://gitlab.linphone.org/BC/public/bcunit";
diff --git a/pkgs/tools/misc/bdf2psf/default.nix b/pkgs/tools/misc/bdf2psf/default.nix
index d7faaf4602038..ff14f2d1a4e29 100644
--- a/pkgs/tools/misc/bdf2psf/default.nix
+++ b/pkgs/tools/misc/bdf2psf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, dpkg }:
+{ lib, stdenv, fetchurl, perl, dpkg }:
 
 stdenv.mkDerivation rec {
   pname = "bdf2psf";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     mv usr $out
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BDF to PSF converter";
     homepage = "https://packages.debian.org/sid/bdf2psf";
     longDescription = ''
diff --git a/pkgs/tools/misc/bdf2sfd/default.nix b/pkgs/tools/misc/bdf2sfd/default.nix
index 728967ec3da82..1d8bd38c1e181 100644
--- a/pkgs/tools/misc/bdf2sfd/default.nix
+++ b/pkgs/tools/misc/bdf2sfd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "bdf2sfd";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BDF to SFD converter";
     homepage = "https://github.com/fcambus/bdf2sfd";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/betterdiscordctl/default.nix b/pkgs/tools/misc/betterdiscordctl/default.nix
index 9d6159bda50e0..c0822b9e10160 100644
--- a/pkgs/tools/misc/betterdiscordctl/default.nix
+++ b/pkgs/tools/misc/betterdiscordctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "betterdiscordctl";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     install -Dm644 README.md $out/share/doc/betterdiscordctl/README.md
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bb010g/betterdiscordctl";
     description = "A utility for managing BetterDiscord on Linux";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/bfr/default.nix b/pkgs/tools/misc/bfr/default.nix
index 4ec7364184289..2b84412f3b275 100644
--- a/pkgs/tools/misc/bfr/default.nix
+++ b/pkgs/tools/misc/bfr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   name = "bfr-1.6";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A general-purpose command-line pipe buffer";
     license = stdenv.lib.licenses.gpl2;
     maintainers = with maintainers; [ pSub ];
diff --git a/pkgs/tools/misc/bibtex2html/default.nix b/pkgs/tools/misc/bibtex2html/default.nix
index 6ca528e2b1a27..0add7340ed5ad 100644
--- a/pkgs/tools/misc/bibtex2html/default.nix
+++ b/pkgs/tools/misc/bibtex2html/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocaml, perl }:
+{ lib, stdenv, fetchurl, ocaml, perl }:
 
 stdenv.mkDerivation {
   pname = "bibtex2html";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ ocaml perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of tools for translating from BibTeX to HTML";
     homepage = "https://www.lri.fr/~filliatr/bibtex2html/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/bibtool/default.nix b/pkgs/tools/misc/bibtool/default.nix
index 041dabeee775e..df27f244fca8c 100644
--- a/pkgs/tools/misc/bibtool/default.nix
+++ b/pkgs/tools/misc/bibtool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   pname = "bibtool";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   doCheck = true;
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for manipulating BibTeX bibliographies";
     homepage = "http://www.gerd-neugebauer.de/software/TeX/BibTool/index.en.html";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/bibutils/default.nix b/pkgs/tools/misc/bibutils/default.nix
index bd744bcfb6fb2..cf42e56b5717e 100644
--- a/pkgs/tools/misc/bibutils/default.nix
+++ b/pkgs/tools/misc/bibutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "bibutils";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   doCheck = true;
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bibliography format interconversion";
     longDescription = "The bibutils program set interconverts between various bibliography formats using a common MODS-format XML intermediate. For example, one can convert RIS-format files to Bibtex by doing two transformations: RIS->MODS->Bibtex. By using a common intermediate for N formats, only 2N programs are required and not N²-N. These programs operate on the command line and are styled after standard UNIX-like filters.";
     homepage = "https://sourceforge.net/p/bibutils/home/Bibutils/";
diff --git a/pkgs/tools/misc/birdfont/default.nix b/pkgs/tools/misc/birdfont/default.nix
index c3361739f0bb0..cdce76a324c29 100644
--- a/pkgs/tools/misc/birdfont/default.nix
+++ b/pkgs/tools/misc/birdfont/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, python3, xmlbird,
+{ lib, stdenv, fetchurl, pkgconfig, python3, xmlbird,
 cairo, gdk-pixbuf, libgee, glib, gtk3, webkitgtk, libnotify, sqlite, vala_0_44,
 gobject-introspection, gsettings-desktop-schemas, wrapGAppsHook }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "./install.py";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Font editor which can generate fonts in TTF, EOT, SVG and BIRDFONT format";
     homepage = "https://birdfont.org";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/birdfont/xmlbird.nix b/pkgs/tools/misc/birdfont/xmlbird.nix
index 2d0d43871e83b..3f103024d897c 100644
--- a/pkgs/tools/misc/birdfont/xmlbird.nix
+++ b/pkgs/tools/misc/birdfont/xmlbird.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3, pkgconfig, vala, glib, gobject-introspection }:
+{ lib, stdenv, fetchurl, python3, pkgconfig, vala, glib, gobject-introspection }:
 
 stdenv.mkDerivation rec {
   pname = "xmlbird";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "./install.py";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XML parser for Vala and C programs";
     homepage = "https://birdfont.org/xmlbird.php";
     license = licenses.lgpl3;
diff --git a/pkgs/tools/misc/bmap-tools/default.nix b/pkgs/tools/misc/bmap-tools/default.nix
index afb41d8b6ea93..ed42f31f26b3e 100644
--- a/pkgs/tools/misc/bmap-tools/default.nix
+++ b/pkgs/tools/misc/bmap-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages }:
+{ lib, stdenv, fetchFromGitHub, python2Packages }:
 
 python2Packages.buildPythonApplication rec {
   pname = "bmap-tools";
@@ -14,7 +14,7 @@ python2Packages.buildPythonApplication rec {
   # tests fail only on hydra.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "bmap-related tools";
     homepage = "https://github.com/intel/bmap-tools";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/bmon/default.nix b/pkgs/tools/misc/bmon/default.nix
index a98b2075ada63..af7e3a3d64299 100644
--- a/pkgs/tools/misc/bmon/default.nix
+++ b/pkgs/tools/misc/bmon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, ncurses, libconfuse
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, ncurses, libconfuse
 , libnl }:
 
 stdenv.mkDerivation rec {
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     export PKG_CONFIG="$(command -v "$PKG_CONFIG")"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network bandwidth monitor";
     homepage = "https://github.com/tgraf/bmon";
     # Licensed unter BSD and MIT
diff --git a/pkgs/tools/misc/bonfire/default.nix b/pkgs/tools/misc/bonfire/default.nix
index 85d54c1673604..cda58e80d87c6 100644
--- a/pkgs/tools/misc/bonfire/default.nix
+++ b/pkgs/tools/misc/bonfire/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 with python3Packages;
 
@@ -38,7 +38,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ arrow click keyring parsedatetime requests six termcolor ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pypi.python.org/pypi/bonfire";
     description = "CLI Graylog Client with Follow Mode";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/broadlink-cli/default.nix b/pkgs/tools/misc/broadlink-cli/default.nix
index 96b13c060e4ba..53925b8759167 100644
--- a/pkgs/tools/misc/broadlink-cli/default.nix
+++ b/pkgs/tools/misc/broadlink-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 python3Packages.buildPythonApplication {
   pname = "broadlink-cli";
@@ -29,7 +29,7 @@ python3Packages.buildPythonApplication {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for interfacing with Broadlink RM2/3 (Pro) remote controls, A1 sensor platforms and SP2/3 smartplugs";
     maintainers = with maintainers; [ peterhoeg ];
     inherit (python3Packages.broadlink.meta) homepage license;
diff --git a/pkgs/tools/misc/broot/default.nix b/pkgs/tools/misc/broot/default.nix
index e4561c3822805..afda7dd7abc9b 100644
--- a/pkgs/tools/misc/broot/default.nix
+++ b/pkgs/tools/misc/broot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchCrate
 , installShellFiles
@@ -68,7 +68,7 @@ rustPlatform.buildRustPackage rec {
     installManPage man/broot.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interactive tree view, a fuzzy search, a balanced BFS descent and customizable commands";
     homepage = "https://dystroy.org/broot/";
     maintainers = with maintainers; [ danieldk ];
diff --git a/pkgs/tools/misc/buildtorrent/default.nix b/pkgs/tools/misc/buildtorrent/default.nix
index d3d3651c2b057..ce357a1d491e1 100644
--- a/pkgs/tools/misc/buildtorrent/default.nix
+++ b/pkgs/tools/misc/buildtorrent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "buildtorrent";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "sha256-6OJ2R72ziHOsVw1GwalompKwG7Z/WQidHN0IeE9wUtA=";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple commandline torrent creator";
     homepage = "https://mathr.co.uk/blog/torrent.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/byobu/default.nix b/pkgs/tools/misc/byobu/default.nix
index 695ae54d876e9..2008cf7b20790 100644
--- a/pkgs/tools/misc/byobu/default.nix
+++ b/pkgs/tools/misc/byobu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper
+{ lib, stdenv, fetchurl, makeWrapper
 , ncurses, python3, perl, textual-window-manager
 , gettext, vim, bc, screen }:
 
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/byobu/";
     description = "Text-based window manager and terminal multiplexer";
 
diff --git a/pkgs/tools/misc/capture/default.nix b/pkgs/tools/misc/capture/default.nix
index e92898ccc4d62..f6762af11aa24 100644
--- a/pkgs/tools/misc/capture/default.nix
+++ b/pkgs/tools/misc/capture/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, slop, ffmpeg_3, fetchFromGitHub, makeWrapper}:
+{ lib, stdenv, slop, ffmpeg_3, fetchFromGitHub, makeWrapper}:
 
 stdenv.mkDerivation {
   pname = "capture-unstable";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
       --prefix PATH : '${stdenv.lib.makeBinPath [ slop ffmpeg_3 ]}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A no bullshit screen capture tool";
     homepage = "https://github.com/buhman/capture";
     maintainers = [ maintainers.ar1a ];
diff --git a/pkgs/tools/misc/ccze/default.nix b/pkgs/tools/misc/ccze/default.nix
index 409297de9f750..140e09c010a25 100644
--- a/pkgs/tools/misc/ccze/default.nix
+++ b/pkgs/tools/misc/ccze/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, ncurses, pcre }:
+{ lib, stdenv, fetchurl, autoconf, ncurses, pcre }:
 
 stdenv.mkDerivation rec {
   name = "ccze-0.2.1-2";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = '' autoheader && autoconf '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, modular log colorizer";
     longDescription = ''
       Fast log colorizer written in C, intended to be a drop-in replacement
diff --git a/pkgs/tools/misc/chafa/default.nix b/pkgs/tools/misc/chafa/default.nix
index 5ed477c93a2f8..8097744692bcc 100644
--- a/pkgs/tools/misc/chafa/default.nix
+++ b/pkgs/tools/misc/chafa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig, which, libxslt, libxml2, docbook_xml_dtd_412, docbook_xsl, glib, imagemagick, darwin }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig, which, libxslt, libxml2, docbook_xml_dtd_412, docbook_xsl, glib, imagemagick, darwin }:
 
 
 stdenv.mkDerivation rec {
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
                      "--with-xml-catalog=${docbook_xml_dtd_412}/xml/dtd/docbook/catalog.xml"
                    ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal graphics for the 21st century";
     homepage = "https://hpjansson.org/chafa/";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/tools/misc/chelf/default.nix b/pkgs/tools/misc/chelf/default.nix
index 96949dd5da57e..25344d8658e82 100644
--- a/pkgs/tools/misc/chelf/default.nix
+++ b/pkgs/tools/misc/chelf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "chelf";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     mv chelf $out/bin/chelf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "change or display the stack size of an ELF binary";
     homepage = "https://github.com/Gottox/chelf";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/chezmoi/default.nix b/pkgs/tools/misc/chezmoi/default.nix
index 0722fca4370be..6fab09aaeafe2 100644
--- a/pkgs/tools/misc/chezmoi/default.nix
+++ b/pkgs/tools/misc/chezmoi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles }:
 
 buildGoModule rec {
   pname = "chezmoi";
@@ -29,7 +29,7 @@ buildGoModule rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.chezmoi.io/";
     description = "Manage your dotfiles across multiple machines, securely";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/chrome-export/default.nix b/pkgs/tools/misc/chrome-export/default.nix
index 8639f6f6f7947..d3f4878ee6918 100644
--- a/pkgs/tools/misc/chrome-export/default.nix
+++ b/pkgs/tools/misc/chrome-export/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , python3
 }:
 
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     bash test/run_tests $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scripts to save Google Chrome's bookmarks and history as HTML bookmarks files";
     homepage = "https://github.com/bdesham/chrome-export";
     license = [ licenses.isc ];
diff --git a/pkgs/tools/misc/cht.sh/default.nix b/pkgs/tools/misc/cht.sh/default.nix
index ceef26b577d62..12730d262234d 100644
--- a/pkgs/tools/misc/cht.sh/default.nix
+++ b/pkgs/tools/misc/cht.sh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , unstableGitUpdater
 , makeWrapper
@@ -38,7 +38,7 @@ stdenv.mkDerivation {
 
   passthru.updateScript = unstableGitUpdater { };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI client for cheat.sh, a community driven cheat sheet";
     license = licenses.mit;
     maintainers = with maintainers; [ fgaz evanjs ];
diff --git a/pkgs/tools/misc/ckb-next/default.nix b/pkgs/tools/misc/ckb-next/default.nix
index 8189a07c214b4..fefb797dbd03c 100644
--- a/pkgs/tools/misc/ckb-next/default.nix
+++ b/pkgs/tools/misc/ckb-next/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, substituteAll, udev
+{ lib, stdenv, mkDerivation, fetchFromGitHub, substituteAll, udev
 , pkgconfig, qtbase, cmake, zlib, kmod }:
 
 mkDerivation rec {
@@ -39,7 +39,7 @@ mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Driver and configuration tool for Corsair keyboards and mice";
     homepage = "https://github.com/ckb-next/ckb-next";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/clac/default.nix b/pkgs/tools/misc/clac/default.nix
index 8d6e464e9bb05..4f26b2036a7de 100644
--- a/pkgs/tools/misc/clac/default.nix
+++ b/pkgs/tools/misc/clac/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "clac";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp README* LICENSE "$out/share/doc/${pname}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     description = "Interactive stack-based calculator";
     homepage = "https://github.com/soveran/clac";
diff --git a/pkgs/tools/misc/clasp/default.nix b/pkgs/tools/misc/clasp/default.nix
index 2748c0126cde8..4fc0d2c2f8cb8 100644
--- a/pkgs/tools/misc/clasp/default.nix
+++ b/pkgs/tools/misc/clasp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 let
   version = "3.1.4";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     cp bin/clasp $out/bin/clasp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Answer set solver for (extended) normal and disjunctive logic programs";
     homepage = "http://potassco.sourceforge.net/";
     platforms = platforms.all;
diff --git a/pkgs/tools/misc/claws/default.nix b/pkgs/tools/misc/claws/default.nix
index 10347e6e794d9..20c8cc7af8f55 100644
--- a/pkgs/tools/misc/claws/default.nix
+++ b/pkgs/tools/misc/claws/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "claws";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "0nl7xvdivnabqr98mh3m1pwqznprsaqpagny6zcwwmz480x4pmfz";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/thehowl/claws";
     description = "Interactive command line client for testing websocket servers";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/clex/default.nix b/pkgs/tools/misc/clex/default.nix
index af21e971fe070..a2ac0df9801dd 100644
--- a/pkgs/tools/misc/clex/default.nix
+++ b/pkgs/tools/misc/clex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "clex";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "File manager with full-screen terminal interface";
     longDescription = ''
       CLEX (pronounced KLEKS) displays directory contents including the file
diff --git a/pkgs/tools/misc/clipnotify/default.nix b/pkgs/tools/misc/clipnotify/default.nix
index 91c428def280c..5cb3a5114d8ad 100644
--- a/pkgs/tools/misc/clipnotify/default.nix
+++ b/pkgs/tools/misc/clipnotify/default.nix
@@ -1,4 +1,4 @@
-{ libX11, libXfixes, stdenv, fetchFromGitHub }:
+{ libX11, libXfixes, lib, stdenv, fetchFromGitHub }:
 stdenv.mkDerivation rec {
   pname = "clipnotify";
   version = "git-2018-02-20";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp clipnotify $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Notify on new X clipboard events";
     inherit (src.meta) homepage;
     maintainers = with maintainers; [ jb55 ];
diff --git a/pkgs/tools/misc/clipster/default.nix b/pkgs/tools/misc/clipster/default.nix
index bb14830bf063b..7da185050fb1a 100644
--- a/pkgs/tools/misc/clipster/default.nix
+++ b/pkgs/tools/misc/clipster/default.nix
@@ -1,4 +1,4 @@
-{fetchFromGitHub , stdenv, python3, gtk3, libwnck3,
+{fetchFromGitHub , lib, stdenv, python3, gtk3, libwnck3,
  gobject-introspection, wrapGAppsHook }:
 
 stdenv.mkDerivation  rec {
@@ -22,7 +22,7 @@ stdenv.mkDerivation  rec {
     cp clipster $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "lightweight python clipboard manager";
     longDescription = ''
       Clipster was designed to try to add a good selection of useful features, while avoiding bad design decisions or becoming excessively large.
diff --git a/pkgs/tools/misc/cloud-sql-proxy/default.nix b/pkgs/tools/misc/cloud-sql-proxy/default.nix
index 16263e2b6c35c..11bfdc508ebc8 100644
--- a/pkgs/tools/misc/cloud-sql-proxy/default.nix
+++ b/pkgs/tools/misc/cloud-sql-proxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchgit }:
+{ lib, stdenv, buildGoPackage, fetchgit }:
 
 buildGoPackage rec {
   pname = "cloud-sql-proxy";
@@ -18,7 +18,7 @@ buildGoPackage rec {
 
   buildFlagsArray = [ "-ldflags=" "-X main.versionString=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An authenticating proxy for Second Generation Google Cloud SQL databases";
     homepage = "https://${goPackagePath}";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/cloud-utils/default.nix b/pkgs/tools/misc/cloud-utils/default.nix
index 1bd3def87c415..290bb92faa1c6 100644
--- a/pkgs/tools/misc/cloud-utils/default.nix
+++ b/pkgs/tools/misc/cloud-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper
+{ lib, stdenv, fetchurl, makeWrapper
 , gawk, gnused, util-linux, file
 , wget, python3, qemu-utils, euca2ools
 , e2fsprogs, cdrkit
@@ -48,7 +48,7 @@ in stdenv.mkDerivation rec {
 
   dontBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.unix;
     license = licenses.gpl3;
   };
diff --git a/pkgs/tools/misc/clpeak/default.nix b/pkgs/tools/misc/clpeak/default.nix
index b021703b804a0..e8b2ab68f316a 100644
--- a/pkgs/tools/misc/clpeak/default.nix
+++ b/pkgs/tools/misc/clpeak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, ocl-icd, opencl-clhpp }:
+{ lib, stdenv, fetchFromGitHub, cmake, ocl-icd, opencl-clhpp }:
 
 stdenv.mkDerivation rec {
   pname = "clpeak";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ocl-icd opencl-clhpp ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool which profiles OpenCL devices to find their peak capacities";
     homepage = "https://github.com/krrishnarraj/clpeak/";
     license = licenses.unlicense;
diff --git a/pkgs/tools/misc/code-minimap/default.nix b/pkgs/tools/misc/code-minimap/default.nix
index 8c43e2b903cae..0ccfe42464587 100644
--- a/pkgs/tools/misc/code-minimap/default.nix
+++ b/pkgs/tools/misc/code-minimap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 }:
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1rxrdavj07i7qa5rf1i3aj7zdcp7c6lrg8yiy75r6lm4g98izzww";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high performance code minimap render";
     homepage = "https://github.com/wfxr/code-minimap";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/tools/misc/codebraid/default.nix b/pkgs/tools/misc/codebraid/default.nix
index 79ed7dd01fca5..a855dac5f124b 100644
--- a/pkgs/tools/misc/codebraid/default.nix
+++ b/pkgs/tools/misc/codebraid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 python3Packages.buildPythonApplication rec {
   pname = "codebraid";
@@ -16,7 +16,7 @@ python3Packages.buildPythonApplication rec {
   checkPhase = ''
     $out/bin/codebraid --help > /dev/null
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gpoore/codebraid";
     description = ''
       Live code in Pandoc Markdown.
diff --git a/pkgs/tools/misc/colord-gtk/default.nix b/pkgs/tools/misc/colord-gtk/default.nix
index b2113f8304cf6..403b3df075374 100644
--- a/pkgs/tools/misc/colord-gtk/default.nix
+++ b/pkgs/tools/misc/colord-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , colord
 , gettext
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
     gtk3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.freedesktop.org/software/colord/intro.html";
     license = licenses.lgpl21Plus;
     platforms = platforms.linux;
diff --git a/pkgs/tools/misc/colord/default.nix b/pkgs/tools/misc/colord/default.nix
index 1db776c8ff0d3..8a8d110f4e984 100644
--- a/pkgs/tools/misc/colord/default.nix
+++ b/pkgs/tools/misc/colord/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , nixosTests
 , bash-completion
@@ -104,7 +104,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System service to manage, install and generate color profiles to accurately color manage input and output devices";
     homepage = "https://www.freedesktop.org/software/colord/";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/misc/colorpicker/default.nix b/pkgs/tools/misc/colorpicker/default.nix
index 3de5d33617c74..d2d0915a46fe7 100644
--- a/pkgs/tools/misc/colorpicker/default.nix
+++ b/pkgs/tools/misc/colorpicker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, gtk2 }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, gtk2 }:
 
 stdenv.mkDerivation rec {
   pname = "colorpicker";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -Dt $out/bin colorpicker
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Click on a pixel on your screen and print its color value in RGB";
     homepage = "https://github.com/Ancurio/colorpicker";
     maintainers = with maintainers; [ jb55 ];
diff --git a/pkgs/tools/misc/contacts/default.nix b/pkgs/tools/misc/contacts/default.nix
index b58e0c6e31e15..40b8289e68b71 100644
--- a/pkgs/tools/misc/contacts/default.nix
+++ b/pkgs/tools/misc/contacts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xcbuildHook, Foundation, AddressBook }:
+{ lib, stdenv, fetchurl, xcbuildHook, Foundation, AddressBook }:
 
 stdenv.mkDerivation {
   version = "1.1a-3";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     cp Products/Default/contacts $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Access contacts from the Mac address book from command-line";
     homepage    = "http://www.gnufoo.org/contacts/contacts.html";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/misc/convbin/default.nix b/pkgs/tools/misc/convbin/default.nix
index 0abf10710caa7..92890c056b157 100644
--- a/pkgs/tools/misc/convbin/default.nix
+++ b/pkgs/tools/misc/convbin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     install -Dm755 bin/convbin $out/bin/convbin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts files to other formats";
     longDescription = ''
       This program is used to convert files to other formats,
diff --git a/pkgs/tools/misc/convfont/default.nix b/pkgs/tools/misc/convfont/default.nix
index 0cc181082a4fc..aeecb05321276 100644
--- a/pkgs/tools/misc/convfont/default.nix
+++ b/pkgs/tools/misc/convfont/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }:
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -Dm755 convfont $out/bin/convfont
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts font for use with FontLibC";
     homepage = "https://github.com/drdnar/convfont";
     license = licenses.wtfpl;
diff --git a/pkgs/tools/misc/convimg/default.nix b/pkgs/tools/misc/convimg/default.nix
index f9de88cb01e5a..8caf4cb706f92 100644
--- a/pkgs/tools/misc/convimg/default.nix
+++ b/pkgs/tools/misc/convimg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     install -Dm755 bin/convimg $out/bin/convimg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Image palette quantization";
     longDescription = ''
       This program is used to convert images to other formats,
diff --git a/pkgs/tools/misc/convmv/default.nix b/pkgs/tools/misc/convmv/default.nix
index 56b9d5c849a5b..b9b775a1bff9c 100644
--- a/pkgs/tools/misc/convmv/default.nix
+++ b/pkgs/tools/misc/convmv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   name = "convmv-2.05";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts filenames from one encoding to another";
     platforms = platforms.linux ++ platforms.freebsd ++ platforms.cygwin;
     maintainers = [ ];
diff --git a/pkgs/tools/misc/cowsay/default.nix b/pkgs/tools/misc/cowsay/default.nix
index 972b2997d8104..d353115f24eaa 100644
--- a/pkgs/tools/misc/cowsay/default.nix
+++ b/pkgs/tools/misc/cowsay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   version = "3.03+dfsg2";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     install -m644 cows/* -t $out/share/cows/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program which generates ASCII pictures of a cow with a message";
     homepage = "https://en.wikipedia.org/wiki/Cowsay";
     license = licenses.gpl1;
diff --git a/pkgs/tools/misc/cp437/default.nix b/pkgs/tools/misc/cp437/default.nix
index 70ca44bd06a2e..ac9282ae43447 100644
--- a/pkgs/tools/misc/cp437/default.nix
+++ b/pkgs/tools/misc/cp437/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 let version = "0.6";
 in
 stdenv.mkDerivation {
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     install -Dm755 cp437 -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Emulates an old-style "code page 437" / "IBM-PC" character
       set terminal on a modern UTF-8 terminal emulator
diff --git a/pkgs/tools/misc/cpulimit/default.nix b/pkgs/tools/misc/cpulimit/default.nix
index 13c29d6ab9360..27e661e269704 100644
--- a/pkgs/tools/misc/cpulimit/default.nix
+++ b/pkgs/tools/misc/cpulimit/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "cpulimit";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://limitcpu.sourceforge.net/";
     description = "A tool to throttle the CPU usage of programs";
     platforms = with platforms; linux ++ freebsd;
diff --git a/pkgs/tools/misc/cpuminer-multi/default.nix b/pkgs/tools/misc/cpuminer-multi/default.nix
index 2856bc2f1e0c4..d99662d8ff3ee 100644
--- a/pkgs/tools/misc/cpuminer-multi/default.nix
+++ b/pkgs/tools/misc/cpuminer-multi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, curl, jansson, autoconf, automake
+{ lib, stdenv, fetchFromGitHub, curl, jansson, autoconf, automake
 , aesni ? stdenv.hostPlatform.aesSupport }:
 
 let
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
 
   configureFlags = [ (if aesni then "--enable-aes-ni" else "--disable-aes-ni") ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-algo CPUMiner";
     homepage = "https://github.com/wolf9466/cpuminer-multi";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/cpuminer/default.nix b/pkgs/tools/misc/cpuminer/default.nix
index d48dc5ec1c9f9..27bf0ec5374bb 100644
--- a/pkgs/tools/misc/cpuminer/default.nix
+++ b/pkgs/tools/misc/cpuminer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , curl
 , jansson
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "CFLAGS=-O3" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pooler/cpuminer";
     description = "CPU miner for Litecoin and Bitcoin";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/crex/default.nix b/pkgs/tools/misc/crex/default.nix
index 72e8521fec1a9..14d462e8e6e42 100644
--- a/pkgs/tools/misc/crex/default.nix
+++ b/pkgs/tools/misc/crex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "crex";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Explore, test, and check regular expressions in the terminal";
     homepage = "https://octobanana.com/software/crex";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/crudini/default.nix b/pkgs/tools/misc/crudini/default.nix
index 1a49446e9c01e..a4b499a632354 100644
--- a/pkgs/tools/misc/crudini/default.nix
+++ b/pkgs/tools/misc/crudini/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, help2man, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, help2man, installShellFiles }:
 
 python3Packages.buildPythonApplication rec {
   pname = "crudini";
@@ -40,7 +40,7 @@ python3Packages.buildPythonApplication rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility for manipulating ini files ";
     homepage = "https://www.pixelbeat.org/programs/crudini/";
     license = licenses.gpl2Only;
diff --git a/pkgs/tools/misc/csv2latex/default.nix b/pkgs/tools/misc/csv2latex/default.nix
index da22258296771..035d2cb9702da 100644
--- a/pkgs/tools/misc/csv2latex/default.nix
+++ b/pkgs/tools/misc/csv2latex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "csv2latex";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   make PREFIX=$out install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line CSV to LaTeX file converter";
     homepage = "http://brouits.free.fr/csv2latex/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/dashing/default.nix b/pkgs/tools/misc/dashing/default.nix
index 11523ae3758d5..546daef5ecbd5 100644
--- a/pkgs/tools/misc/dashing/default.nix
+++ b/pkgs/tools/misc/dashing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "dashing";
@@ -17,7 +17,7 @@ buildGoPackage rec {
 
   buildFlagsArray = [ "-ldflags=-X main.version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Dash Generator Script for Any HTML";
     homepage    = "https://github.com/technosophos/dashing";
     license     = licenses.mit;
diff --git a/pkgs/tools/misc/datamash/default.nix b/pkgs/tools/misc/datamash/default.nix
index 8e9782506fb9d..25f814e5f3c89 100644
--- a/pkgs/tools/misc/datamash/default.nix
+++ b/pkgs/tools/misc/datamash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "datamash";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1cxdlhgz3wzjqlq8bgwad93fgqymk2abbldfzw1ffnhcp4mmjjjp";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line program which performs basic numeric,textual and statistical operations on input textual data files";
     homepage = "https://www.gnu.org/software/datamash/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/dateutils/default.nix b/pkgs/tools/misc/dateutils/default.nix
index eae2241c3b4e0..9ef68a590c275 100644
--- a/pkgs/tools/misc/dateutils/default.nix
+++ b/pkgs/tools/misc/dateutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, tzdata, fetchpatch }:
+{ lib, stdenv, fetchurl, autoreconfHook, tzdata, fetchpatch }:
 
 stdenv.mkDerivation rec {
   version = "0.4.7";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A bunch of tools that revolve around fiddling with dates and times in the command line";
     homepage = "http://www.fresse.org/dateutils/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/ddccontrol/default.nix b/pkgs/tools/misc/ddccontrol/default.nix
index cfc48af5be547..c57f0570d1eba 100644
--- a/pkgs/tools/misc/ddccontrol/default.nix
+++ b/pkgs/tools/misc/ddccontrol/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, intltool, libxml2
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, intltool, libxml2
 , pciutils, pkgconfig, gtk2, ddccontrol-db
 , makeDesktopItem
 }:
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     categories = "Settings;HardwareSettings;";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program used to control monitor parameters by software";
     homepage = "https://github.com/ddccontrol/ddccontrol";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/ddcutil/default.nix b/pkgs/tools/misc/ddcutil/default.nix
index 0a2664d6a7754..4a3e8aa9e3458 100644
--- a/pkgs/tools/misc/ddcutil/default.nix
+++ b/pkgs/tools/misc/ddcutil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , glib, i2c-tools, udev, libgudev, libusb1, libdrm, xorg }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     glib libusb1 libdrm xorg.libXrandr
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://www.ddcutil.com/";
     description = "Query and change Linux monitor settings using DDC/CI and USB";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/misc/debian-devscripts/default.nix b/pkgs/tools/misc/debian-devscripts/default.nix
index 35db9ef7db368..9b97886682fd9 100644
--- a/pkgs/tools/misc/debian-devscripts/default.nix
+++ b/pkgs/tools/misc/debian-devscripts/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip, xz, dpkg
+{lib, stdenv, fetchurl, unzip, xz, dpkg
 , libxslt, docbook_xsl, makeWrapper
 , python3Packages
 , perlPackages, curl, gnupg, diffutils
@@ -57,7 +57,7 @@ in stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''Debian package maintenance scripts'';
     license = licenses.free; # Mix of public domain, Artistic+GPL, GPL1+, GPL2+, GPL3+, and GPL2-only... TODO
     maintainers = with maintainers; [raskin];
diff --git a/pkgs/tools/misc/debianutils/default.nix b/pkgs/tools/misc/debianutils/default.nix
index 42deec9dc5d20..d9fc2a4071246 100644
--- a/pkgs/tools/misc/debianutils/default.nix
+++ b/pkgs/tools/misc/debianutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "debianutils";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1pjh2s5f8qp8jaky2x08yvf125np0s48zb2z6f3h6x4vf20hws1v";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Miscellaneous utilities specific to Debian";
     longDescription = ''
        This package provides a number of small utilities which are used primarily by the installation scripts of Debian packages, although you may use them directly.
diff --git a/pkgs/tools/misc/debootstrap/default.nix b/pkgs/tools/misc/debootstrap/default.nix
index 4d4afb0b995f5..f0e6a8ec4055d 100644
--- a/pkgs/tools/misc/debootstrap/default.nix
+++ b/pkgs/tools/misc/debootstrap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg, gawk, perl, wget, coreutils, util-linux
+{ lib, stdenv, fetchurl, dpkg, gawk, perl, wget, coreutils, util-linux
 , gnugrep, gnutar, gnused, gzip, makeWrapper }:
 # USAGE like this: debootstrap sid /tmp/target-chroot-directory
 # There is also cdebootstrap now. Is that easier to maintain?
@@ -57,7 +57,7 @@ in stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to create a Debian system in a chroot";
     homepage = "https://wiki.debian.org/Debootstrap";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/detox/default.nix b/pkgs/tools/misc/detox/default.nix
index 85bed63c7f9dd..6aa66b349dc7c 100644
--- a/pkgs/tools/misc/detox/default.nix
+++ b/pkgs/tools/misc/detox/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, flex}:
+{lib, stdenv, fetchurl, flex}:
 
 stdenv.mkDerivation {
   name = "detox-1.2.0";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     install -m644 safe.tbl $out/share/detox/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://detox.sourceforge.net/";
     description = "Utility designed to clean up filenames";
     longDescription = ''
diff --git a/pkgs/tools/misc/diffoscope/default.nix b/pkgs/tools/misc/diffoscope/default.nix
index b910f3f9699e0..2d7715274bed9 100644
--- a/pkgs/tools/misc/diffoscope/default.nix
+++ b/pkgs/tools/misc/diffoscope/default.nix
@@ -68,7 +68,7 @@ python3Packages.buildPythonApplication rec {
     cp doc/diffoscope.1 $out/share/man/man1/diffoscope.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Perform in-depth comparison of files, archives, and directories";
     longDescription = ''
       diffoscope will try to get to the bottom of what makes files or directories
diff --git a/pkgs/tools/misc/direnv/default.nix b/pkgs/tools/misc/direnv/default.nix
index d76f50eeae067..c3317ec0b3075 100644
--- a/pkgs/tools/misc/direnv/default.nix
+++ b/pkgs/tools/misc/direnv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule, bash, fish, zsh }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule, bash, fish, zsh }:
 
 buildGoModule rec {
   pname = "direnv";
@@ -34,7 +34,7 @@ buildGoModule rec {
     make test-go test-bash test-fish test-zsh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A shell extension that manages your environment";
     longDescription = ''
       Once hooked into your shell direnv is looking for an .envrc file in your
diff --git a/pkgs/tools/misc/diskonaut/default.nix b/pkgs/tools/misc/diskonaut/default.nix
index 20b955f877e64..6c295eb00e824 100644
--- a/pkgs/tools/misc/diskonaut/default.nix
+++ b/pkgs/tools/misc/diskonaut/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "diskonaut";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0y86ikf235lp5j85fgzawgp4vx66rmzqd6p5n8iy3mqwn3c1ggb8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal disk space navigator";
     homepage = "https://github.com/imsnif/diskonaut";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/diskscan/default.nix b/pkgs/tools/misc/diskscan/default.nix
index 204b7b4cf8dd1..1e7bbd6bfcec4 100644
--- a/pkgs/tools/misc/diskscan/default.nix
+++ b/pkgs/tools/misc/diskscan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, ncurses, zlib }:
+{ lib, stdenv, fetchFromGitHub, cmake, ncurses, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "diskscan";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/baruch/diskscan";
     description = "Scan HDD/SSD for failed and near failed sectors";
     platforms = with platforms; linux;
diff --git a/pkgs/tools/misc/diskus/default.nix b/pkgs/tools/misc/diskus/default.nix
index b3fbc6377ab59..bf61a844196a5 100644
--- a/pkgs/tools/misc/diskus/default.nix
+++ b/pkgs/tools/misc/diskus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "diskus";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0bivmjn7h4lfp5azbc6q0xiqq3fk68jdd4kwrwgbxiljg4xd2qy8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal, fast alternative to 'du -sh'";
     homepage = "https://github.com/sharkdp/diskus";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/tools/misc/docbook2mdoc/default.nix b/pkgs/tools/misc/docbook2mdoc/default.nix
index 2237d009d43cf..9a4352d32679d 100644
--- a/pkgs/tools/misc/docbook2mdoc/default.nix
+++ b/pkgs/tools/misc/docbook2mdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, expat }:
+{ lib, stdenv, fetchurl, expat }:
 
 stdenv.mkDerivation rec {
   pname = "docbook2mdoc";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mdocml.bsd.lv/";
     description = "converter from DocBook V4.x and v5.x XML into mdoc";
     license = licenses.isc;
diff --git a/pkgs/tools/misc/docker-ls/default.nix b/pkgs/tools/misc/docker-ls/default.nix
index e53f020fc6bd5..df9755f863da6 100644
--- a/pkgs/tools/misc/docker-ls/default.nix
+++ b/pkgs/tools/misc/docker-ls/default.nix
@@ -1,4 +1,4 @@
-{ buildGoModule, fetchFromGitHub, stdenv, docker }:
+{ buildGoModule, fetchFromGitHub, lib, stdenv, docker }:
 
 buildGoModule rec {
   pname = "docker-ls";
@@ -13,7 +13,7 @@ buildGoModule rec {
 
   vendorSha256 = "sha256-UulcjQOLEIP++eoYQTEIbCJW51jyE312dMxB8+AKcdU=";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for browsing and manipulating docker registries";
     longDescription = ''
       Docker-ls is a set of CLI tools for browsing and manipulating docker registries.
diff --git a/pkgs/tools/misc/docui/default.nix b/pkgs/tools/misc/docui/default.nix
index 73aa8984a49b2..e4934853e825e 100644
--- a/pkgs/tools/misc/docui/default.nix
+++ b/pkgs/tools/misc/docui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "docui";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TUI Client for Docker";
     homepage = "https://github.com/skanehira/docui";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/doitlive/default.nix b/pkgs/tools/misc/doitlive/default.nix
index 3c0406a4ea0ed..313dc9935faf0 100644
--- a/pkgs/tools/misc/doitlive/default.nix
+++ b/pkgs/tools/misc/doitlive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "doitlive";
@@ -14,7 +14,7 @@ python3Packages.buildPythonApplication rec {
   # disable tests (too many failures)
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for live presentations in the terminal";
     homepage = "https://pypi.python.org/pypi/doitlive";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/duc/default.nix b/pkgs/tools/misc/duc/default.nix
index 74dd2a34cc440..f24f62cb5f44a 100644
--- a/pkgs/tools/misc/duc/default.nix
+++ b/pkgs/tools/misc/duc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , tokyocabinet, ncurses
 , cairo ? null, pango ? null
 , enableCairo ? stdenv.isLinux
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   configureFlags =
     stdenv.lib.optionals (!enableCairo) [ "--disable-x11" "--disable-cairo" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://duc.zevv.nl/";
     description = "Collection of tools for inspecting and visualizing disk usage";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/dumptorrent/default.nix b/pkgs/tools/misc/dumptorrent/default.nix
index 146ab54dd62ff..73dac5280bf4d 100644
--- a/pkgs/tools/misc/dumptorrent/default.nix
+++ b/pkgs/tools/misc/dumptorrent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
     pname = "dumptorrent";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       cp ./dumptorrent $out/bin
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Dump .torrent file information";
       homepage = "https://sourceforge.net/projects/dumptorrent/";
       license = licenses.gpl2;
diff --git a/pkgs/tools/misc/dupd/default.nix b/pkgs/tools/misc/dupd/default.nix
index 4c8f5e2e2b1e7..87b39b3b70403 100644
--- a/pkgs/tools/misc/dupd/default.nix
+++ b/pkgs/tools/misc/dupd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl, which
+{ lib, stdenv, fetchFromGitHub, perl, which
 , openssl, sqlite }:
 
 # Instead of writing directly into $HOME, we change the default db location
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI utility to find duplicate files";
     homepage = "http://www.virkki.com/dupd";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/dust/default.nix b/pkgs/tools/misc/dust/default.nix
index 238ff73ba3873..d8c828c222871 100644
--- a/pkgs/tools/misc/dust/default.nix
+++ b/pkgs/tools/misc/dust/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "du-dust";
@@ -20,7 +20,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "du + rust = dust. Like du but more intuitive";
     homepage = "https://github.com/bootandy/dust";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/dvtm/dvtm.nix b/pkgs/tools/misc/dvtm/dvtm.nix
index 5bb8efb5540c6..d8bb54cb4cb6d 100644
--- a/pkgs/tools/misc/dvtm/dvtm.nix
+++ b/pkgs/tools/misc/dvtm/dvtm.nix
@@ -1,4 +1,4 @@
-{ stdenv, ncurses, customConfig ? null, name, src, patches ? [] }:
+{ lib, stdenv, ncurses, customConfig ? null, name, src, patches ? [] }:
 stdenv.mkDerivation {
 
   inherit name src patches;
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynamic virtual terminal manager";
     homepage = "http://www.brain-dump.org/projects/dvtm";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/dylibbundler/default.nix b/pkgs/tools/misc/dylibbundler/default.nix
index c4209442de8db..7bf93bf88e7c3 100644
--- a/pkgs/tools/misc/dylibbundler/default.nix
+++ b/pkgs/tools/misc/dylibbundler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   name = "dylibbundler";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small command-line program that aims to make bundling .dylibs as easy as possible";
     homepage    = "https://github.com/auriamg/macdylibbundler";
     license     = licenses.mit;
diff --git a/pkgs/tools/misc/dynamic-colors/default.nix b/pkgs/tools/misc/dynamic-colors/default.nix
index 6cb01f14a2c0b..c0ff0fec328a2 100644
--- a/pkgs/tools/misc/dynamic-colors/default.nix
+++ b/pkgs/tools/misc/dynamic-colors/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "dynamic-colors";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       --replace /usr/share/dynamic-colors $out/share/dynamic-colors
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Change terminal colors on the fly";
     homepage    = "https://github.com/peterhoeg/dynamic-colors";
     license     = licenses.mit;
diff --git a/pkgs/tools/misc/ent/default.nix b/pkgs/tools/misc/ent/default.nix
index 4ecb8fe488a22..0fa265c2db6cf 100644
--- a/pkgs/tools/misc/ent/default.nix
+++ b/pkgs/tools/misc/ent/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip}:
+{lib, stdenv, fetchurl, unzip}:
 
 stdenv.mkDerivation {
   name = "ent-1.1";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     cp ent $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pseudorandom Number Sequence Test Program";
     homepage = "http://www.fourmilab.ch/random/";
     platforms = platforms.all;
diff --git a/pkgs/tools/misc/entr/default.nix b/pkgs/tools/misc/entr/default.nix
index 9bd9c2104f38d..29474a471c3a0 100644
--- a/pkgs/tools/misc/entr/default.nix
+++ b/pkgs/tools/misc/entr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, coreutils, ncurses }:
+{ lib, stdenv, fetchurl, coreutils, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "entr";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   checkTarget = "test";
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://entrproject.org/";
     description = "Run arbitrary commands when files change";
     license = licenses.isc;
diff --git a/pkgs/tools/misc/envchain/default.nix b/pkgs/tools/misc/envchain/default.nix
index 1bafa4688ae85..54ae0155b3117 100644
--- a/pkgs/tools/misc/envchain/default.nix
+++ b/pkgs/tools/misc/envchain/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libedit, libsecret, ncurses, pkg-config, readline, Security }:
+{ lib, stdenv, fetchFromGitHub, libedit, libsecret, ncurses, pkg-config, readline, Security }:
 
 stdenv.mkDerivation rec {
   pname = "envchain";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set environment variables with macOS keychain or D-Bus secret service";
     homepage = "https://github.com/sorah/envchain";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/esptool-ck/default.nix b/pkgs/tools/misc/esptool-ck/default.nix
index a57a042a0c17f..0b4e8cecaf642 100644
--- a/pkgs/tools/misc/esptool-ck/default.nix
+++ b/pkgs/tools/misc/esptool-ck/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "esptool-ck";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp esptool $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ESP8266/ESP32 build helper tool";
     homepage = "https://github.com/igrr/esptool-ck";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/esptool/default.nix b/pkgs/tools/misc/esptool/default.nix
index d1d6bc1cb101c..89be1da8cc98c 100644
--- a/pkgs/tools/misc/esptool/default.nix
+++ b/pkgs/tools/misc/esptool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, openssl }:
+{ lib, stdenv, fetchFromGitHub, python3, openssl }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "esptool";
@@ -28,7 +28,7 @@ python3.pkgs.buildPythonApplication rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ESP8266 and ESP32 serial bootloader utility";
     homepage = "https://github.com/espressif/esptool";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/etcher/default.nix b/pkgs/tools/misc/etcher/default.nix
index 6634d2d23ca2e..8e5c5d918cc69 100644
--- a/pkgs/tools/misc/etcher/default.nix
+++ b/pkgs/tools/misc/etcher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , gcc-unwrapped
 , dpkg
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [ gcc-unwrapped.lib ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flash OS images to SD cards and USB drives, safely and easily";
     homepage = "https://etcher.io/";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/ethminer/default.nix b/pkgs/tools/misc/ethminer/default.nix
index f84b0096d0446..7d2cb5c7ff2ca 100644
--- a/pkgs/tools/misc/ethminer/default.nix
+++ b/pkgs/tools/misc/ethminer/default.nix
@@ -1,4 +1,5 @@
 {
+  lib,
   clangStdenv,
   fetchFromGitHub,
   opencl-headers,
@@ -69,7 +70,7 @@ in stdenv.mkDerivation rec {
     wrapProgram $out/bin/ethminer --prefix LD_LIBRARY_PATH : /run/opengl-driver/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ethereum miner with OpenCL, CUDA and stratum support";
     homepage = "https://github.com/ethereum-mining/ethminer";
     platforms = [ "x86_64-linux" ];
diff --git a/pkgs/tools/misc/ethtool/default.nix b/pkgs/tools/misc/ethtool/default.nix
index b1b9956404a9d..4b6d7cc9332e4 100644
--- a/pkgs/tools/misc/ethtool/default.nix
+++ b/pkgs/tools/misc/ethtool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "ethtool";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0srbqp4a3x9ryrbm5q854375y04ni8j0bmsrl89nmsyn4x4ixy12";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for controlling network drivers and hardware";
     homepage = "https://www.kernel.org/pub/software/network/ethtool/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/eva/default.nix b/pkgs/tools/misc/eva/default.nix
index a409133433083..65da084f84190 100644
--- a/pkgs/tools/misc/eva/default.nix
+++ b/pkgs/tools/misc/eva/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, fetchpatch }:
 
 rustPlatform.buildRustPackage rec {
   pname = "eva";
@@ -29,7 +29,7 @@ rustPlatform.buildRustPackage rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A calculator REPL, similar to bc";
     homepage = "https://github.com/NerdyPepper/eva";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/exa/default.nix b/pkgs/tools/misc/exa/default.nix
index fd6baadb685c3..44c821f542d74 100644
--- a/pkgs/tools/misc/exa/default.nix
+++ b/pkgs/tools/misc/exa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, rustPlatform, cmake, perl, pkgconfig, zlib
+{ lib, stdenv, fetchFromGitHub, fetchpatch, rustPlatform, cmake, perl, pkgconfig, zlib
 , darwin, libiconv, installShellFiles
 }:
 
@@ -45,7 +45,7 @@ buildRustPackage rec {
   # Some tests fail, but Travis ensures a proper build
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Replacement for 'ls' written in Rust";
     longDescription = ''
       exa is a modern replacement for ls. It uses colours for information by
diff --git a/pkgs/tools/misc/expect/default.nix b/pkgs/tools/misc/expect/default.nix
index cbb8c337ff87d..2c5548abd8399 100644
--- a/pkgs/tools/misc/expect/default.nix
+++ b/pkgs/tools/misc/expect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, tcl, makeWrapper, autoreconfHook }:
+{ lib, stdenv, fetchurl, tcl, makeWrapper, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   version = "5.45.4";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for automating interactive applications";
     homepage = "http://expect.sourceforge.net/";
     license = "Expect";
diff --git a/pkgs/tools/misc/fbcat/default.nix b/pkgs/tools/misc/fbcat/default.nix
index 4f640f13a27fe..8769f65f68c4e 100644
--- a/pkgs/tools/misc/fbcat/default.nix
+++ b/pkgs/tools/misc/fbcat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub } :
+{ lib, stdenv, fetchFromGitHub } :
 
 stdenv.mkDerivation rec {
   pname = "fbcat";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     install -d $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://jwilk.net/software/fbcat";
     description = "Framebuffer screenshot tool";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/fdupes/default.nix b/pkgs/tools/misc/fdupes/default.nix
index 7203d6b57fcd2..42c1c3a37df44 100644
--- a/pkgs/tools/misc/fdupes/default.nix
+++ b/pkgs/tools/misc/fdupes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, ncurses, pcre2 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, ncurses, pcre2 }:
 
 stdenv.mkDerivation rec {
   pname = "fdupes";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ ncurses pcre2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Identifies duplicate files residing within specified directories";
     longDescription = ''
       fdupes searches the given path for duplicate files.
diff --git a/pkgs/tools/misc/ffsend/default.nix b/pkgs/tools/misc/ffsend/default.nix
index a8c7fce68cc89..f3f7afd30f683 100644
--- a/pkgs/tools/misc/ffsend/default.nix
+++ b/pkgs/tools/misc/ffsend/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, rustPlatform, cmake, pkgconfig, openssl
+{ lib, stdenv, fetchFromGitLab, rustPlatform, cmake, pkgconfig, openssl
 , darwin, installShellFiles
 
 , x11Support ? stdenv.isLinux || stdenv.hostPlatform.isBSD
@@ -45,7 +45,7 @@ buildRustPackage rec {
   '';
   # There's also .elv and .ps1 completion files but I don't know where to install those
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Easily and securely share files from the command line. A fully featured Firefox Send client";
     longDescription = ''
       Easily and securely share files and directories from the command line through a safe, private
diff --git a/pkgs/tools/misc/file/default.nix b/pkgs/tools/misc/file/default.nix
index 8e284b25c08d2..6867038c6450c 100644
--- a/pkgs/tools/misc/file/default.nix
+++ b/pkgs/tools/misc/file/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, file, zlib, libgnurx }:
+{ lib, stdenv, fetchurl, file, zlib, libgnurx }:
 
 stdenv.mkDerivation rec {
   pname = "file";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = stdenv.lib.optional stdenv.hostPlatform.isWindows "FILE_COMPILE=file";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://darwinsys.com/file";
     description = "A program that shows the type of files";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/filebench/default.nix b/pkgs/tools/misc/filebench/default.nix
index 4cd572ac99204..ca62c8c4a1a8f 100644
--- a/pkgs/tools/misc/filebench/default.nix
+++ b/pkgs/tools/misc/filebench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, bison, flex }:
+{ lib, stdenv, fetchurl, autoreconfHook, bison, flex }:
 
 stdenv.mkDerivation rec {
   pname = "filebench";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook bison flex ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "File system and storage benchmark that can generate both micro and macro workloads";
     homepage = "https://sourceforge.net/projects/filebench/";
     license = licenses.cddl;
diff --git a/pkgs/tools/misc/fltrdr/default.nix b/pkgs/tools/misc/fltrdr/default.nix
index 5d753d2d68c66..3e51a4c8bbc22 100644
--- a/pkgs/tools/misc/fltrdr/default.nix
+++ b/pkgs/tools/misc/fltrdr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , icu, openssl
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ icu openssl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://octobanana.com/software/fltrdr";
     description = "A TUI text reader for the terminal";
 
@@ -38,4 +38,3 @@ stdenv.mkDerivation rec {
     maintainers = [ maintainers.matthiasbeyer ];
   };
 }
-
diff --git a/pkgs/tools/misc/fluent-bit/default.nix b/pkgs/tools/misc/fluent-bit/default.nix
index 60860c197e882..aa9f175e90047 100644
--- a/pkgs/tools/misc/fluent-bit/default.nix
+++ b/pkgs/tools/misc/fluent-bit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, flex, bison }:
+{ lib, stdenv, fetchFromGitHub, cmake, flex, bison }:
 
 stdenv.mkDerivation rec {
   pname = "fluent-bit";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
       --replace /lib/systemd $out/lib/systemd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Log forwarder and processor, part of Fluentd ecosystem";
     homepage = "https://fluentbit.io";
     maintainers = with maintainers; [
diff --git a/pkgs/tools/misc/foma/default.nix b/pkgs/tools/misc/foma/default.nix
index d5fed006173f9..2bde606adbe6a 100644
--- a/pkgs/tools/misc/foma/default.nix
+++ b/pkgs/tools/misc/foma/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zlib, flex, bison, readline }:
+{ lib, stdenv, fetchFromGitHub, zlib, flex, bison, readline }:
 
 stdenv.mkDerivation rec {
   pname = "foma";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --replace '/usr/local' '$(out)'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A multi-purpose finite-state toolkit designed for applications ranging from natural language processing to research in automata theory";
     homepage = "https://github.com/mhulden/foma";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/fortune/default.nix b/pkgs/tools/misc/fortune/default.nix
index bc23d9dd84623..cbb5eae848776 100644
--- a/pkgs/tools/misc/fortune/default.nix
+++ b/pkgs/tools/misc/fortune/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, recode, perl }:
+{ lib, stdenv, fetchurl, cmake, recode, perl }:
 
 stdenv.mkDerivation rec {
   pname = "fortune-mod";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     --
   '') ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program that displays a pseudorandom message from a database of quotations";
     license = licenses.bsdOriginal;
     platforms = platforms.unix;
diff --git a/pkgs/tools/misc/fpart/default.nix b/pkgs/tools/misc/fpart/default.nix
index e673c73d0961a..bdb762c98a600 100644
--- a/pkgs/tools/misc/fpart/default.nix
+++ b/pkgs/tools/misc/fpart/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, fts }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, fts }:
 
 stdenv.mkDerivation rec {
   pname = "fpart";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
         -i "$out/bin/fpsync"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Split file trees into bags (called \"partitions\")";
     longDescription = ''
       Fpart is a tool that helps you sort file trees and pack them into bags
diff --git a/pkgs/tools/misc/fselect/default.nix b/pkgs/tools/misc/fselect/default.nix
index 587483f4ac41d..1076c44a1bb37 100644
--- a/pkgs/tools/misc/fselect/default.nix
+++ b/pkgs/tools/misc/fselect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles }:
 
 rustPlatform.buildRustPackage rec {
   pname = "fselect";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
     installManPage docs/fselect.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Find files with SQL-like queries";
     homepage = "https://github.com/jhspetersson/fselect";
     license = with licenses; [ asl20 mit ];
diff --git a/pkgs/tools/misc/fsmark/default.nix b/pkgs/tools/misc/fsmark/default.nix
index 7bfa24e3a0820..1a21156e64033 100644
--- a/pkgs/tools/misc/fsmark/default.nix
+++ b/pkgs/tools/misc/fsmark/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "fsmark";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp fs_mark $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Synchronous write workload file system benchmark";
     homepage = "https://sourceforge.net/projects/fsmark/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/fsmon/default.nix b/pkgs/tools/misc/fsmon/default.nix
index a3e3eddcda9ea..c845c3de8e95b 100644
--- a/pkgs/tools/misc/fsmon/default.nix
+++ b/pkgs/tools/misc/fsmon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "fsmon";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     make install PREFIX=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "FileSystem Monitor utility";
     homepage = "https://github.com/nowsecure/fsmon";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/fsql/default.nix b/pkgs/tools/misc/fsql/default.nix
index fa64d74286582..8e113ee871a16 100644
--- a/pkgs/tools/misc/fsql/default.nix
+++ b/pkgs/tools/misc/fsql/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "fsql";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "1accpxryk4744ydfrqc3la5k376ji11yr84n66dz5cx0f3n71vmz";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Search through your filesystem with SQL-esque queries";
     homepage = "https://github.com/kshvmdn/fsql";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/fwup/default.nix b/pkgs/tools/misc/fwup/default.nix
index bf6c125ac7590..b3864aff44bca 100644
--- a/pkgs/tools/misc/fwup/default.nix
+++ b/pkgs/tools/misc/fwup/default.nix
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     ];
   propagatedBuildInputs = [ zip unzip mtools dosfstools coreutils ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configurable embedded Linux firmware update creator and runner";
     homepage = "https://github.com/fhunleth/fwup";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/fx_cast/default.nix b/pkgs/tools/misc/fx_cast/default.nix
index d24ff0e05161b..581ef0aa838df 100644
--- a/pkgs/tools/misc/fx_cast/default.nix
+++ b/pkgs/tools/misc/fx_cast/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg }:
+{ lib, stdenv, fetchurl, dpkg }:
 
 stdenv.mkDerivation rec {
   pname = "fx_cast_bridge";
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
 
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Implementation of the Chrome Sender API (Chromecast) within Firefox";
     homepage = "https://hensm.github.io/fx_cast/";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/fxlinuxprintutil/default.nix b/pkgs/tools/misc/fxlinuxprintutil/default.nix
index 112f6a9f2328e..b97e082128aca 100644
--- a/pkgs/tools/misc/fxlinuxprintutil/default.nix
+++ b/pkgs/tools/misc/fxlinuxprintutil/default.nix
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/fxlputil --prefix PATH : ${lib.makeBinPath [ tcl tk ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optional configuration tool for fxlinuxprint";
     homepage = "https://onlinesupport.fujixerox.com";
     license = licenses.unfree;
diff --git a/pkgs/tools/misc/fzy/default.nix b/pkgs/tools/misc/fzy/default.nix
index 90042d632b79e..f726adb0d4629 100644
--- a/pkgs/tools/misc/fzy/default.nix
+++ b/pkgs/tools/misc/fzy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "fzy";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A better fuzzy finder";
     homepage = "https://github.com/jhawthorn/fzy";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/g933-utils/default.nix b/pkgs/tools/misc/g933-utils/default.nix
index 3da98301346fc..67e3b3b6ea38c 100644
--- a/pkgs/tools/misc/g933-utils/default.nix
+++ b/pkgs/tools/misc/g933-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, udev, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, udev, pkgconfig }:
 
 rustPlatform.buildRustPackage rec {
   pname = "g933-utils";
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ udev ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An application to configure Logitech wireless G933/G533 headsets";
     homepage = "https://github.com/ashkitten/g933-utils";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/gammy/default.nix b/pkgs/tools/misc/gammy/default.nix
index 2fd99fd4a3abe..cb8f491069a85 100644
--- a/pkgs/tools/misc/gammy/default.nix
+++ b/pkgs/tools/misc/gammy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, qmake, libXxf86vm, wrapQtAppsHook }:
+{ lib, stdenv, fetchFromGitHub, qmake, libXxf86vm, wrapQtAppsHook }:
 
 let
   pname = "gammy";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ libXxf86vm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI tool for manual- of auto-adjusting of brightness/temperature";
     homepage = "https://github.com/Fushko/gammy";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/geekbench/default.nix b/pkgs/tools/misc/geekbench/default.nix
index a33ae0ed33052..1e1c06a3a0282 100644
--- a/pkgs/tools/misc/geekbench/default.nix
+++ b/pkgs/tools/misc/geekbench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, ocl-icd, vulkan-loader, linuxPackages }:
+{ lib, stdenv, fetchurl, makeWrapper, ocl-icd, vulkan-loader, linuxPackages }:
 
 stdenv.mkDerivation rec {
   pname = "geekbench";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform benchmark";
     homepage = "https://geekbench.com/";
     license = licenses.unfree;
diff --git a/pkgs/tools/misc/geteltorito/default.nix b/pkgs/tools/misc/geteltorito/default.nix
index cee93ae29910f..be2de1167e3c7 100644
--- a/pkgs/tools/misc/geteltorito/default.nix
+++ b/pkgs/tools/misc/geteltorito/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, perl, ronn, fetchurl }:
+{ lib, stdenv, perl, ronn, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "geteltorito";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     install -vD geteltorito $out/bin/geteltorito
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extract the initial/default boot image from a CD image if existent";
     homepage = "https://userpages.uni-koblenz.de/~krienke/ftp/noarch/geteltorito/";
     maintainers = [ maintainers.Profpatsch ];
diff --git a/pkgs/tools/misc/gh-ost/default.nix b/pkgs/tools/misc/gh-ost/default.nix
index 82ff74a041926..6096dac962219 100644
--- a/pkgs/tools/misc/gh-ost/default.nix
+++ b/pkgs/tools/misc/gh-ost/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gh-ost";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.AppVersion=${version} -X main.BuildDescribe=${src.rev}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Triggerless online schema migration solution for MySQL";
     homepage = "https://github.com/github/gh-ost";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/gif-for-cli/default.nix b/pkgs/tools/misc/gif-for-cli/default.nix
index 52d3e043ce9cb..e82cafdd64cd0 100644
--- a/pkgs/tools/misc/gif-for-cli/default.nix
+++ b/pkgs/tools/misc/gif-for-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, ffmpeg, zlib, libjpeg }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, ffmpeg, zlib, libjpeg }:
 
 python3Packages.buildPythonApplication {
   pname = "gif-for-cli";
@@ -15,7 +15,7 @@ python3Packages.buildPythonApplication {
   buildInputs = [ zlib libjpeg ];
   propagatedBuildInputs = with python3Packages; [ ffmpeg pillow requests x256 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Render gifs as ASCII art in your cli";
     longDescription = "Takes in a GIF, short video, or a query to the Tenor GIF API and converts it to animated ASCII art.";
     homepage = "https://github.com/google/gif-for-cli";
diff --git a/pkgs/tools/misc/git-fire/default.nix b/pkgs/tools/misc/git-fire/default.nix
index 0b5deccaa904c..bba1bd65a54db 100644
--- a/pkgs/tools/misc/git-fire/default.nix
+++ b/pkgs/tools/misc/git-fire/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   name = "git-fire-unstable-2017-08-27";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     install -D -m755 $src/git-fire $out/bin/git-fire
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Push ALL changes in a git repository
     '';
diff --git a/pkgs/tools/misc/git-town/default.nix b/pkgs/tools/misc/git-town/default.nix
index ab9f1907a8e2a..cf3a6aba19f01 100644
--- a/pkgs/tools/misc/git-town/default.nix
+++ b/pkgs/tools/misc/git-town/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "git-town";
@@ -14,7 +14,7 @@ buildGoPackage rec {
 
   buildFlagsArray = [ "-ldflags=-X github.com/git-town/git-town/src/cmd.version=v${version} -X github.com/git-town/git-town/src/cmd.buildDate=nix" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generic, high-level git support for git-flow workflows";
     homepage = "https://www.git-town.com/";
     maintainers = [ maintainers.allonsy maintainers.blaggacao ];
diff --git a/pkgs/tools/misc/gnuvd/default.nix b/pkgs/tools/misc/gnuvd/default.nix
index 0c49296227043..eef1533587be5 100644
--- a/pkgs/tools/misc/gnuvd/default.nix
+++ b/pkgs/tools/misc/gnuvd/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "gnuvd-1.0.12";
@@ -8,7 +8,7 @@ stdenv.mkDerivation {
     sha256 = "0mpy76a0pxy62zjiihlzmvl4752hiwxhfs8rm1v5zgdr78acxyxz";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line dutch dictionary application";
     homepage = "https://www.djcbsoftware.nl/code/gnuvd/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/go.rice/default.nix b/pkgs/tools/misc/go.rice/default.nix
index 33e6975bb02d2..26b082e43b39c 100644
--- a/pkgs/tools/misc/go.rice/default.nix
+++ b/pkgs/tools/misc/go.rice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "go.rice";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   subPackages = [ "." "rice" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/GeertJohan/go.rice";
     description = "A Go package that makes working with resources such as html, js, css, images, templates very easy";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/gparted/default.nix b/pkgs/tools/misc/gparted/default.nix
index 7d610416da47b..b8d227df5e0fe 100644
--- a/pkgs/tools/misc/gparted/default.nix
+++ b/pkgs/tools/misc/gparted/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, gettext, makeWrapper, coreutils, gnused, gnome3
+{ lib, stdenv, fetchurl, intltool, gettext, makeWrapper, coreutils, gnused, gnome3
 , gnugrep, parted, glib, libuuid, pkgconfig, gtkmm3, libxml2
 , gpart, hdparm, procps, util-linux, polkit, wrapGAppsHook, substituteAll
 }:
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
       $out/share/polkit-1/actions/org.gnome.gparted.policy
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Graphical disk partitioning tool";
     longDescription = ''
       GNOME Partition Editor for creating, reorganizing, and deleting disk
diff --git a/pkgs/tools/misc/graylog/default.nix b/pkgs/tools/misc/graylog/default.nix
index f6a48364bfda2..5be309be582fb 100644
--- a/pkgs/tools/misc/graylog/default.nix
+++ b/pkgs/tools/misc/graylog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre_headless, nixosTests }:
+{ lib, stdenv, fetchurl, makeWrapper, jre_headless, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "graylog";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/graylogctl $makeWrapperArgs
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source log management solution";
     homepage    = "https://www.graylog.org/";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/misc/grc/default.nix b/pkgs/tools/misc/grc/default.nix
index 1900764604b5c..3188dcdafbf3a 100644
--- a/pkgs/tools/misc/grc/default.nix
+++ b/pkgs/tools/misc/grc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "grc";
@@ -28,7 +28,7 @@ python3Packages.buildPythonApplication rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Yet another colouriser for beautifying your logfiles or output of commands";
     homepage    = "http://korpus.juls.savba.sk/~garabik/software/grc.html";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/misc/grex/default.nix b/pkgs/tools/misc/grex/default.nix
index c4f1c8ea9c778..31306fd7aa423 100644
--- a/pkgs/tools/misc/grex/default.nix
+++ b/pkgs/tools/misc/grex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , rustPlatform
@@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec {
     $out/bin/grex --help > /dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line tool for generating regular expressions from user-provided test cases";
     homepage = "https://github.com/pemistahl/grex";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/gringo/default.nix b/pkgs/tools/misc/gringo/default.nix
index 05e5e9b64cf0c..9df59b1c127e6 100644
--- a/pkgs/tools/misc/gringo/default.nix
+++ b/pkgs/tools/misc/gringo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl,
+{ lib, stdenv, fetchurl,
   bison, re2c, sconsPackages,
   libcxx
 }:
@@ -49,7 +49,7 @@ stdenv.mkDerivation {
     cp build/release/gringo $out/bin/gringo
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts input programs with first-order variables to equivalent ground programs";
     homepage = "http://potassco.sourceforge.net/";
     platforms = platforms.all;
diff --git a/pkgs/tools/misc/grub/2.0x.nix b/pkgs/tools/misc/grub/2.0x.nix
index 63cdb61dd336b..207396fb08957 100644
--- a/pkgs/tools/misc/grub/2.0x.nix
+++ b/pkgs/tools/misc/grub/2.0x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, flex, bison, python3, autoconf, automake, gnulib, libtool
+{ lib, stdenv, fetchgit, flex, bison, python3, autoconf, automake, gnulib, libtool
 , gettext, ncurses, libusb-compat-0_1, freetype, qemu, lvm2, unifont, pkgconfig
 , fuse # only needed for grub-mount
 , zfs ? null
@@ -110,7 +110,7 @@ stdenv.mkDerivation rec {
     sed -i $out/lib/grub/*/modinfo.sh -e "/grub_target_cppflags=/ s|'.*'|' '|"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNU GRUB, the Grand Unified Boot Loader (2.x beta)";
 
     longDescription =
diff --git a/pkgs/tools/misc/grub/default.nix b/pkgs/tools/misc/grub/default.nix
index e657431429cce..a7233d5c4b1f3 100644
--- a/pkgs/tools/misc/grub/default.nix
+++ b/pkgs/tools/misc/grub/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, texinfo, buggyBiosCDSupport ? true }:
+{ lib, stdenv, fetchurl, autoreconfHook, texinfo, buggyBiosCDSupport ? true }:
 
 stdenv.mkDerivation {
   name = "grub-0.97-73";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
 
   passthru.grubTarget = "";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/grub";
     description = "GRand Unified Bootloader";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/grub/pvgrub_image/default.nix b/pkgs/tools/misc/grub/pvgrub_image/default.nix
index 6b796dedb0ade..ec5d0ff12955c 100644
--- a/pkgs/tools/misc/grub/pvgrub_image/default.nix
+++ b/pkgs/tools/misc/grub/pvgrub_image/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, grub2_xen }:
+{ lib, stdenv, grub2_xen }:
 
 with stdenv.lib;
 let
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     cp "grub-${efiSystemsBuild.${stdenv.hostPlatform.system}.target}-xen.bin" $out/lib/grub-xen/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PvGrub image for use for booting PV Xen guests";
 
     longDescription =
diff --git a/pkgs/tools/misc/grub/trusted.nix b/pkgs/tools/misc/grub/trusted.nix
index f14758a3ae75e..7a2454cd7b58a 100644
--- a/pkgs/tools/misc/grub/trusted.nix
+++ b/pkgs/tools/misc/grub/trusted.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchgit, autogen, flex, bison, python, autoconf, automake
+{ lib, stdenv, fetchurl, fetchgit, autogen, flex, bison, python, autoconf, automake
 , gettext, ncurses, libusb-compat-0_1, freetype, qemu, lvm2
 , for_HP_laptop ? false
 }:
@@ -91,7 +91,7 @@ stdenv.mkDerivation rec {
   doCheck = false;
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GRUB 2.0 extended with TCG (TPM) support for integrity measured boot process (trusted boot)";
     homepage = "https://github.com/Sirrix-AG/TrustedGRUB2";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/grub4dos/default.nix b/pkgs/tools/misc/grub4dos/default.nix
index 24548b4d209b5..6ffddd4f98a0c 100644
--- a/pkgs/tools/misc/grub4dos/default.nix
+++ b/pkgs/tools/misc/grub4dos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nasm }:
+{ lib, stdenv, fetchFromGitHub, nasm }:
 
 let arch =
   if stdenv.isi686 then "i386"
@@ -33,7 +33,7 @@ in stdenv.mkDerivation {
   # make[2]: *** No rule to make target 'pre_stage2_fullsize', needed by 'all-am'.  Stop.
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://grub4dos.chenall.net/";
     description = "GRUB for DOS is the dos extension of GRUB";
     maintainers = with maintainers; [ abbradar ];
diff --git a/pkgs/tools/misc/gti/default.nix b/pkgs/tools/misc/gti/default.nix
index 9c2e65676c2dd..83452394f1545 100644
--- a/pkgs/tools/misc/gti/default.nix
+++ b/pkgs/tools/misc/gti/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "gti";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp gti.6 $out/share/man/man6
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://r-wos.org/hacks/gti";
     license = licenses.mit;
     description = "Humorous typo-based git runner; drives a car over the terminal";
diff --git a/pkgs/tools/misc/h/default.nix b/pkgs/tools/misc/h/default.nix
index 9a80945097b7d..3f5878472a79d 100644
--- a/pkgs/tools/misc/h/default.nix
+++ b/pkgs/tools/misc/h/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, ruby }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, ruby }:
 
 stdenv.mkDerivation rec {
   pname = "h";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     cp up $out/bin/up
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "faster shell navigation of projects";
     homepage = "https://github.com/zimbatm/h";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/hackertyper/default.nix b/pkgs/tools/misc/hackertyper/default.nix
index 4b5973e7eecae..d72dd1798d5a1 100644
--- a/pkgs/tools/misc/hackertyper/default.nix
+++ b/pkgs/tools/misc/hackertyper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation {
   pname = "hackertyper";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     $out/bin/hackertyper -v
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A C rewrite of hackertyper.net";
     homepage = "https://github.com/Hurricane996/Hackertyper";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/hakuneko/default.nix b/pkgs/tools/misc/hakuneko/default.nix
index 6389d41cdfedd..0a1d070d77eaf 100644
--- a/pkgs/tools/misc/hakuneko/default.nix
+++ b/pkgs/tools/misc/hakuneko/default.nix
@@ -70,7 +70,7 @@ stdenv.mkDerivation rec {
       "''${gappsWrapperArgs[@]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manga & Anime Downloader";
     homepage = "https://sourceforge.net/projects/hakuneko/";
     license = licenses.unlicense;
diff --git a/pkgs/tools/misc/hashit/default.nix b/pkgs/tools/misc/hashit/default.nix
index e33201c706bac..36b1770791b40 100644
--- a/pkgs/tools/misc/hashit/default.nix
+++ b/pkgs/tools/misc/hashit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nix-update-script, meson, ninja, pkgconfig, vala, pantheon, python3, libgee, gtk3, desktop-file-utils, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, nix-update-script, meson, ninja, pkgconfig, vala, pantheon, python3, libgee, gtk3, desktop-file-utils, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "hashit";
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple app for checking usual checksums - Designed for elementary OS";
     homepage = "https://github.com/artemanufrij/hashit";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/hdaps-gl/default.nix b/pkgs/tools/misc/hdaps-gl/default.nix
index 79f4d067b108b..41de7ef5d28b0 100644
--- a/pkgs/tools/misc/hdaps-gl/default.nix
+++ b/pkgs/tools/misc/hdaps-gl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, freeglut, libGL, libGLU }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, freeglut, libGL, libGLU }:
 
 let version = "0.0.7"; in
 stdenv.mkDerivation {
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
       nativeBuildInputs = [ autoreconfHook ];
       buildInputs = [ freeglut libGL libGLU ];
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
             description = "GL-based laptop model that rotates in real-time via hdaps";
             homepage = "https://github.com/linux-thinkpad/hdaps-gl";
             license = licenses.gpl2;
diff --git a/pkgs/tools/misc/hddtemp/default.nix b/pkgs/tools/misc/hddtemp/default.nix
index 1f3fbd2381ff1..de57b25399049 100644
--- a/pkgs/tools/misc/hddtemp/default.nix
+++ b/pkgs/tools/misc/hddtemp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "hddtemp-0.3_beta15";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
       ./configure --prefix=$out --with-db-path=$out/nix-support/hddtemp.db
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for displaying hard disk temperature";
     homepage = "https://savannah.nongnu.org/projects/hddtemp/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/hdf4/default.nix b/pkgs/tools/misc/hdf4/default.nix
index b5269a15867a0..caf7ceb49ee2b 100644
--- a/pkgs/tools/misc/hdf4/default.nix
+++ b/pkgs/tools/misc/hdf4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchpatch
 , fetchurl
 , fixDarwinDylibNames
@@ -109,7 +109,7 @@ stdenv.mkDerivation rec {
     moveToOutput bin "$bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Data model, library, and file format for storing and managing data";
     homepage = "https://support.hdfgroup.org/products/hdf4/";
     maintainers = with maintainers; [ knedlsepp ];
diff --git a/pkgs/tools/misc/hdl-dump/default.nix b/pkgs/tools/misc/hdl-dump/default.nix
index 96e81fe8bd4c0..6a6af1391bda5 100644
--- a/pkgs/tools/misc/hdl-dump/default.nix
+++ b/pkgs/tools/misc/hdl-dump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , upx
 }:
@@ -25,7 +25,7 @@ in stdenv.mkDerivation {
     install -Dm755 hdl_dump -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AKuHAK/hdl-dump";
     description = "PlayStation 2 HDLoader image dump/install utility";
     platforms = platforms.linux;
diff --git a/pkgs/tools/misc/heatseeker/default.nix b/pkgs/tools/misc/heatseeker/default.nix
index 207788ed61d6a..13933c6c28a67 100644
--- a/pkgs/tools/misc/heatseeker/default.nix
+++ b/pkgs/tools/misc/heatseeker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, coreutils }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, coreutils }:
 
 rustPlatform.buildRustPackage rec {
   pname = "heatseeker";
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
   # which we can also make use of
   TRAVIS = "true";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A general-purpose fuzzy selector";
     homepage = "https://github.com/rschmitt/heatseeker";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/hebcal/default.nix b/pkgs/tools/misc/hebcal/default.nix
index 049a79fa7574e..e7a9ccd6358e0 100644
--- a/pkgs/tools/misc/hebcal/default.nix
+++ b/pkgs/tools/misc/hebcal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   version = "4.22";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://hebcal.github.io";
     description = "A perpetual Jewish Calendar";
     longDescription = "Hebcal is a program which prints out the days in the Jewish calendar for a given Gregorian year. Hebcal is fairly flexible in terms of which events in the Jewish calendar it displays.";
diff --git a/pkgs/tools/misc/heimdall/default.nix b/pkgs/tools/misc/heimdall/default.nix
index 252572dee652f..bbc07141e1ada 100644
--- a/pkgs/tools/misc/heimdall/default.nix
+++ b/pkgs/tools/misc/heimdall/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, cmake, zlib, libusb1
+{ lib, stdenv, mkDerivation, fetchFromGitHub, cmake, zlib, libusb1
 , enableGUI ? false, qtbase ? null
 }:
 
@@ -39,7 +39,7 @@ mkDerivation {
     install -m644 ../OSX/README.txt $out/share/doc/heimdall/README.osx
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://www.glassechidna.com.au/products/heimdall/";
     description = "A cross-platform tool suite to flash firmware onto Samsung Galaxy S devices";
     license     = licenses.mit;
diff --git a/pkgs/tools/misc/hexyl/default.nix b/pkgs/tools/misc/hexyl/default.nix
index d9bed8c607d09..e75d01057314e 100644
--- a/pkgs/tools/misc/hexyl/default.nix
+++ b/pkgs/tools/misc/hexyl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname   = "hexyl";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1am9vs7l2wzgwqakrsl27x1y7jpn9xaqa4kr48wwqzka401h6j4m";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     changelog = "https://github.com/sharkdp/hexyl/releases/tag/v${version}";
     description = "A command-line hex viewer";
     longDescription = ''
diff --git a/pkgs/tools/misc/hhpc/default.nix b/pkgs/tools/misc/hhpc/default.nix
index 4b1b0d0c7623d..78e45aa4cd098 100644
--- a/pkgs/tools/misc/hhpc/default.nix
+++ b/pkgs/tools/misc/hhpc/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, xorg, pkgconfig}:
+{lib, stdenv, fetchFromGitHub, xorg, pkgconfig}:
 
 stdenv.mkDerivation rec {
   pname = "hhpc";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       cp hhpc $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Hides the mouse pointer in X11";
     maintainers = with maintainers; [ nico202 ];
     platforms = platforms.unix;
diff --git a/pkgs/tools/misc/hid-listen/default.nix b/pkgs/tools/misc/hid-listen/default.nix
index afc7c5741fd48..1f69a3fe749bf 100644
--- a/pkgs/tools/misc/hid-listen/default.nix
+++ b/pkgs/tools/misc/hid-listen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 stdenv.mkDerivation rec {
   pname = "hid-listen";
   version = "1.01";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     mv ./hid_listen $out/bin/hid_listen
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool thats prints debugging information from usb HID devices";
     homepage = "https://www.pjrc.com/teensy/hid_listen.html";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/hpcg/default.nix b/pkgs/tools/misc/hpcg/default.nix
index 6274178c266a0..29799641880c6 100644
--- a/pkgs/tools/misc/hpcg/default.nix
+++ b/pkgs/tools/misc/hpcg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openmpi } :
+{ lib, stdenv, fetchurl, openmpi } :
 
 stdenv.mkDerivation rec {
   pname = "hpcg";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp bin/hpcg.dat $out/share/hpcg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HPC conjugate gradient benchmark";
     homepage = "https://www.hpcg-benchmark.org";
     platforms = platforms.linux;
diff --git a/pkgs/tools/misc/hpl/default.nix b/pkgs/tools/misc/hpl/default.nix
index d688f3adf30ed..c9a81ebb8a1bc 100644
--- a/pkgs/tools/misc/hpl/default.nix
+++ b/pkgs/tools/misc/hpl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, blas, lapack, mpi } :
+{ lib, stdenv, fetchurl, blas, lapack, mpi } :
 
 assert (!blas.isILP64) && (!lapack.isILP64);
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ blas lapack mpi ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Portable Implementation of the Linpack Benchmark for Distributed-Memory Computers";
     homepage = "http://www.netlib.org/benchmark/hpl/";
     platforms = platforms.unix;
diff --git a/pkgs/tools/misc/hyperfine/default.nix b/pkgs/tools/misc/hyperfine/default.nix
index cd581045cc59b..fe39230a21451 100644
--- a/pkgs/tools/misc/hyperfine/default.nix
+++ b/pkgs/tools/misc/hyperfine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchCrate, rustPlatform, installShellFiles
+{ lib, stdenv, fetchCrate, rustPlatform, installShellFiles
 , Security
 }:
 
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
       --zsh $releaseDir/build/hyperfine-*/out/_hyperfine
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line benchmarking tool";
     homepage    = "https://github.com/sharkdp/hyperfine";
     license     = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/tools/misc/hyperledger-fabric/default.nix b/pkgs/tools/misc/hyperledger-fabric/default.nix
index e782d793dab86..13a88dcba3038 100644
--- a/pkgs/tools/misc/hyperledger-fabric/default.nix
+++ b/pkgs/tools/misc/hyperledger-fabric/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "hyperledger-fabric";
@@ -26,7 +26,7 @@ buildGoPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An implementation of blockchain technology, leveraging familiar and proven technologies";
     homepage = "https://wiki.hyperledger.org/projects/Fabric";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/i3minator/default.nix b/pkgs/tools/misc/i3minator/default.nix
index ad9c41d47052b..f749ea677bc0c 100644
--- a/pkgs/tools/misc/i3minator/default.nix
+++ b/pkgs/tools/misc/i3minator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, glibcLocales }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, glibcLocales }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "i3minator";
@@ -18,7 +18,7 @@ pythonPackages.buildPythonApplication rec {
   # No tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "i3 project manager similar to tmuxinator";
     longDescription = ''
       A simple "workspace manager" for i3. It allows to quickly
diff --git a/pkgs/tools/misc/ical2org/default.nix b/pkgs/tools/misc/ical2org/default.nix
index bcba352d6d361..58afffcd70616 100644
--- a/pkgs/tools/misc/ical2org/default.nix
+++ b/pkgs/tools/misc/ical2org/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage}:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage}:
 
 buildGoPackage rec {
   pname = "ical2org";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert an iCal file to org agenda format, optionally deduplicating entries";
     homepage = "https://github.com/rjhorniii/ical2org";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/ideviceinstaller/default.nix b/pkgs/tools/misc/ideviceinstaller/default.nix
index 3dd5365803628..9d1857c1136b9 100644
--- a/pkgs/tools/misc/ideviceinstaller/default.nix
+++ b/pkgs/tools/misc/ideviceinstaller/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, usbmuxd, libzip, libimobiledevice }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, usbmuxd, libzip, libimobiledevice }:
 
 stdenv.mkDerivation rec {
   pname = "ideviceinstaller";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook pkgconfig usbmuxd libimobiledevice libzip ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/libimobiledevice/ideviceinstaller";
     description = "List/modify installed apps of iOS devices";
     longDescription = ''
diff --git a/pkgs/tools/misc/idevicerestore/default.nix b/pkgs/tools/misc/idevicerestore/default.nix
index cbb0e1058ab76..5072d2d9b989f 100644
--- a/pkgs/tools/misc/idevicerestore/default.nix
+++ b/pkgs/tools/misc/idevicerestore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , curl
 , libimobiledevice
 , libirecovery
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     # because they are inherited `libimobiledevice`.
   ] ++ stdenv.lib.optionals stdenv.isDarwin [ IOKit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/libimobiledevice/idevicerestore";
     description = "Restore/upgrade firmware of iOS devices";
     longDescription = ''
diff --git a/pkgs/tools/misc/ili2c/default.nix b/pkgs/tools/misc/ili2c/default.nix
index 2bda116e66ce2..c2f4c991a708f 100644
--- a/pkgs/tools/misc/ili2c/default.nix
+++ b/pkgs/tools/misc/ili2c/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jdk8, ant, makeWrapper, jre8 }:
+{ lib, stdenv, fetchFromGitHub, jdk8, ant, makeWrapper, jre8 }:
 
 let jdk = jdk8; jre = jre8; in
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
         --add-flags "-jar $out/share/${pname}/ili2c.jar"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The INTERLIS Compiler";
     longDescription = ''
       Checks the syntactical correctness of an INTERLIS data model.
diff --git a/pkgs/tools/misc/ink/default.nix b/pkgs/tools/misc/ink/default.nix
index 266298d9ec2ce..8037d54131065 100644
--- a/pkgs/tools/misc/ink/default.nix
+++ b/pkgs/tools/misc/ink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libinklevel }:
+{ lib, stdenv, fetchurl, libinklevel }:
 
 stdenv.mkDerivation rec {
   pname = "ink";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line tool for checking the ink level of your locally connected printer";
     longDescription = ''
       Ink is a command line tool for checking the ink level of your locally connected printer on a system which runs Linux or FreeBSD. Canon BJNP network printers are supported too.
diff --git a/pkgs/tools/misc/intermodal/default.nix b/pkgs/tools/misc/intermodal/default.nix
index c96aa90cb233d..ca1c58d465a2f 100644
--- a/pkgs/tools/misc/intermodal/default.nix
+++ b/pkgs/tools/misc/intermodal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "intermodal";
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
   # include_hidden test tries to use `chflags` on darwin
   checkFlagsArray = stdenv.lib.optionals stdenv.isDarwin [ "--skip=subcommand::torrent::create::tests::include_hidden" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "User-friendly and featureful command-line BitTorrent metainfo utility";
     homepage = "https://github.com/casey/intermodal";
     license = licenses.cc0;
diff --git a/pkgs/tools/misc/ipad_charge/default.nix b/pkgs/tools/misc/ipad_charge/default.nix
index 981d9f2dc6cfe..d92961be9c5ad 100644
--- a/pkgs/tools/misc/ipad_charge/default.nix
+++ b/pkgs/tools/misc/ipad_charge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libusb1 }:
+{ lib, stdenv, fetchFromGitHub, libusb1 }:
 
 stdenv.mkDerivation rec {
   pname = "ipad_charge";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/{bin,lib/udev/rules.d}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Apple device USB charging utility for Linux";
     longDescription = ''
diff --git a/pkgs/tools/misc/ipbt/default.nix b/pkgs/tools/misc/ipbt/default.nix
index e523dd198d42d..8ee6bb5addb97 100644
--- a/pkgs/tools/misc/ipbt/default.nix
+++ b/pkgs/tools/misc/ipbt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, ncurses }:
+{ lib, stdenv, fetchurl, perl, ncurses }:
 
 stdenv.mkDerivation rec {
   version = "20190601.d1519e0";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ perl ];
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-tech ttyrec player for Unix";
     homepage = "https://www.chiark.greenend.org.uk/~sgtatham/ipbt/";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/ix/default.nix b/pkgs/tools/misc/ix/default.nix
index cedaa13b74a03..bf298090f3fa8 100644
--- a/pkgs/tools/misc/ix/default.nix
+++ b/pkgs/tools/misc/ix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, curl }:
+{ lib, stdenv, fetchurl, makeWrapper, curl }:
 
 stdenv.mkDerivation {
   pname = "ix";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     wrapProgram $out/bin/ix --prefix PATH : "${stdenv.lib.makeBinPath [ curl ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ix.io";
     description = "Command line pastebin";
     maintainers = with maintainers; [ asymmetric ];
diff --git a/pkgs/tools/misc/jdiskreport/default.nix b/pkgs/tools/misc/jdiskreport/default.nix
index ae70e0f3e6133..117199617e149 100644
--- a/pkgs/tools/misc/jdiskreport/default.nix
+++ b/pkgs/tools/misc/jdiskreport/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, jre, makeDesktopItem, copyDesktopItems }:
+{ lib, stdenv, fetchurl, unzip, jre, makeDesktopItem, copyDesktopItems }:
 
 let
   desktopItem = makeDesktopItem {
@@ -44,7 +44,7 @@ stdenv.mkDerivation {
 
   desktopItems = [ desktopItem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.jgoodies.com/freeware/jdiskreport/";
     description = "A graphical utility to visualize disk usage";
     license = licenses.unfreeRedistributable; #TODO freedist, libs under BSD-3
diff --git a/pkgs/tools/misc/jdupes/default.nix b/pkgs/tools/misc/jdupes/default.nix
index a22fcc77dd96d..c55c0879e5d86 100644
--- a/pkgs/tools/misc/jdupes/default.nix
+++ b/pkgs/tools/misc/jdupes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "jdupes";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     install -Dm444 -t $out/share/doc/jdupes CHANGES LICENSE README.md
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A powerful duplicate file finder and an enhanced fork of 'fdupes'";
     longDescription = ''
       jdupes is a program for identifying and taking actions upon
diff --git a/pkgs/tools/misc/jugglinglab/default.nix b/pkgs/tools/misc/jugglinglab/default.nix
index 1b5f11440fa04..f9038da04b577 100644
--- a/pkgs/tools/misc/jugglinglab/default.nix
+++ b/pkgs/tools/misc/jugglinglab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jre, makeWrapper, ant, jdk }:
+{ lib, stdenv, fetchFromGitHub, jre, makeWrapper, ant, jdk }:
 stdenv.mkDerivation rec {
   version = "1.2.1";
   name = "jugglinglab";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       --add-flags "-jar $out/lib/JugglingLab.jar"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
       description = "A program to visualize different juggling pattens";
       license = licenses.gpl2;
       maintainers = with maintainers; [ wnklmnn ];
diff --git a/pkgs/tools/misc/kanshi/default.nix b/pkgs/tools/misc/kanshi/default.nix
index 0cb20315f66c9..90ee2a3446b57 100644
--- a/pkgs/tools/misc/kanshi/default.nix
+++ b/pkgs/tools/misc/kanshi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkg-config, scdoc, wayland }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkg-config, scdoc, wayland }:
 
 stdenv.mkDerivation rec {
   pname = "kanshi";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson ninja pkg-config scdoc ];
   buildInputs = [ wayland ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynamic display configuration tool";
     longDescription = ''
       kanshi allows you to define output profiles that are automatically enabled
diff --git a/pkgs/tools/misc/kargo/default.nix b/pkgs/tools/misc/kargo/default.nix
index ac40eb762d50a..00bf94034273e 100644
--- a/pkgs/tools/misc/kargo/default.nix
+++ b/pkgs/tools/misc/kargo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python3Packages }:
+{ lib, stdenv, fetchurl, python3Packages }:
 
 with python3Packages;
 
@@ -28,7 +28,7 @@ buildPythonApplication rec {
     HOME=$TMPDIR $out/bin/kargo -v
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kubespray/kargo-cli";
     description = "A tool helps to deploy a kubernetes cluster with Ansible";
     platforms = platforms.linux;
diff --git a/pkgs/tools/misc/kermit/default.nix b/pkgs/tools/misc/kermit/default.nix
index 2155b8676becc..1a561f0bef470 100644
--- a/pkgs/tools/misc/kermit/default.nix
+++ b/pkgs/tools/misc/kermit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, glibc }:
+{ lib, stdenv, fetchurl, ncurses, glibc }:
 
 stdenv.mkDerivation {
   name = "kermit-9.0.302";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     make -f makefile install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.kermitproject.org/ck90.html";
     description = "Portable Scriptable Network and Serial Communication Software";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/kisslicer/default.nix b/pkgs/tools/misc/kisslicer/default.nix
index c6ec5f3103fe3..bd112e4b8765d 100644
--- a/pkgs/tools/misc/kisslicer/default.nix
+++ b/pkgs/tools/misc/kisslicer/default.nix
@@ -2,7 +2,7 @@
 , libX11
 , libGLU, libGL
 , makeWrapper
-, stdenv
+, lib, stdenv
 }:
 
 let
@@ -48,7 +48,7 @@ stdenv.mkDerivation {
       --run "mkdir -p ${inidir}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert STL files into Gcode";
     homepage = "http://www.kisslicer.com";
     license = licenses.unfree;
diff --git a/pkgs/tools/misc/kodi-cli/default.nix b/pkgs/tools/misc/kodi-cli/default.nix
index 37eed61008b4d..517e195040f5a 100644
--- a/pkgs/tools/misc/kodi-cli/default.nix
+++ b/pkgs/tools/misc/kodi-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, curl, bash, jq, youtube-dl, gnome3 }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, curl, bash, jq, youtube-dl, gnome3 }:
 
 stdenv.mkDerivation rec {
   pname = "kodi-cli";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/playlist_to_kodi --prefix PATH : ${stdenv.lib.makeBinPath [ curl bash gnome3.zenity jq youtube-dl ]}
   '';
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nawar/kodi-cli";
     description = "Kodi/XBMC bash script to send Kodi commands using JSON RPC. It also allows sending YouTube videos to Kodi";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/kt/default.nix b/pkgs/tools/misc/kt/default.nix
index 9664759cf5a43..8d70b35584e7d 100644
--- a/pkgs/tools/misc/kt/default.nix
+++ b/pkgs/tools/misc/kt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage }:
 
 buildGoPackage rec {
   pname = "kt";
@@ -13,7 +13,7 @@ buildGoPackage rec {
 
   goPackagePath = "github.com/fgeller/kt";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kafka command line tool";
     homepage = "https://github.com/fgeller/kt";
     maintainers = with maintainers; [ utdemir ];
diff --git a/pkgs/tools/misc/latex2html/default.nix b/pkgs/tools/misc/latex2html/default.nix
index 33ecdb8cd8e58..6f532533f99d0 100644
--- a/pkgs/tools/misc/latex2html/default.nix
+++ b/pkgs/tools/misc/latex2html/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchFromGitHub, makeWrapper
 , ghostscript, netpbm, perl }:
 # TODO: withTex
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LaTeX-to-HTML translator";
     longDescription = ''
       A Perl program that translates LaTeX into HTML (HyperText Markup
diff --git a/pkgs/tools/misc/lazydocker/default.nix b/pkgs/tools/misc/lazydocker/default.nix
index 5c70c7fba7d1d..ea66a04a40df1 100644
--- a/pkgs/tools/misc/lazydocker/default.nix
+++ b/pkgs/tools/misc/lazydocker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "lazydocker";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   subPackages = [ "." ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple terminal UI for both docker and docker-compose";
     homepage = "https://github.com/jesseduffield/lazydocker";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/lcdf-typetools/default.nix b/pkgs/tools/misc/lcdf-typetools/default.nix
index 44f6768fd3bcc..3c4fd39713b48 100644
--- a/pkgs/tools/misc/lcdf-typetools/default.nix
+++ b/pkgs/tools/misc/lcdf-typetools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "lcdf-typetools";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--without-kpathsea" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for manipulating OpenType, PostScript Type 1, and Multiple Master fonts";
     homepage = "https://www.lcdf.org/type";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/ldapvi/default.nix b/pkgs/tools/misc/ldapvi/default.nix
index 52e6b0c6a30a9..9c062cf418d95 100644
--- a/pkgs/tools/misc/ldapvi/default.nix
+++ b/pkgs/tools/misc/ldapvi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, openldap, openssl, popt, glib, ncurses, readline, pkgconfig, cyrus_sasl, autoconf, automake }:
+{ lib, stdenv, fetchgit, openldap, openssl, popt, glib, ncurses, readline, pkgconfig, cyrus_sasl, autoconf, automake }:
 
 stdenv.mkDerivation {
   pname = "ldapvi";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interactive LDAP client for Unix terminals";
     longDescription = ''
       ldapvi is an interactive LDAP client for Unix terminals. Using it, you
diff --git a/pkgs/tools/misc/ldmtool/default.nix b/pkgs/tools/misc/ldmtool/default.nix
index 9c9751d35c321..4a965cbe165db 100644
--- a/pkgs/tools/misc/ldmtool/default.nix
+++ b/pkgs/tools/misc/ldmtool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, gtk-doc, pkgconfig, libuuid,
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, gtk-doc, pkgconfig, libuuid,
   libtool, readline, gobject-introspection, json-glib, lvm2, libxslt, docbook_xsl
 , fetchpatch }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     libtool readline gobject-introspection json-glib libuuid
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool and library for managing Microsoft Windows Dynamic Disks";
     homepage = "https://github.com/mdbooth/libldm";
     maintainers = with maintainers; [ jensbin ];
diff --git a/pkgs/tools/misc/less/default.nix b/pkgs/tools/misc/less/default.nix
index 4ffbf8634a8e9..5fa4b339b1ee3 100644
--- a/pkgs/tools/misc/less/default.nix
+++ b/pkgs/tools/misc/less/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, lessSecure ? false }:
+{ lib, stdenv, fetchurl, ncurses, lessSecure ? false }:
 
 stdenv.mkDerivation rec {
   pname = "less";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.greenwoodsoftware.com/less/";
     description = "A more advanced file pager than ‘more’";
     platforms = platforms.unix;
diff --git a/pkgs/tools/misc/lesspipe/default.nix b/pkgs/tools/misc/lesspipe/default.nix
index 8a13ef5dfd8a8..5c8a13e3c202a 100644
--- a/pkgs/tools/misc/lesspipe/default.nix
+++ b/pkgs/tools/misc/lesspipe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, substituteAll, perl, file, ncurses }:
+{ lib, stdenv, fetchFromGitHub, substituteAll, perl, file, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "lesspipe";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A preprocessor for less";
     longDescription = ''
       Usually lesspipe.sh is called as an input filter to less. With the help
diff --git a/pkgs/tools/misc/libbitcoin/libbitcoin-client.nix b/pkgs/tools/misc/libbitcoin/libbitcoin-client.nix
index bad820c150694..71a9233fab533 100644
--- a/pkgs/tools/misc/libbitcoin/libbitcoin-client.nix
+++ b/pkgs/tools/misc/libbitcoin/libbitcoin-client.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
 , boost, libbitcoin, libbitcoin-protocol }:
 
 let
@@ -26,7 +26,7 @@ in stdenv.mkDerivation {
     "--with-boost-libdir=${boost.out}/lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bitcoin client query library";
     homepage = "https://github.com/libbitcoin/libbitcoin-client";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/misc/libbitcoin/libbitcoin-explorer.nix b/pkgs/tools/misc/libbitcoin/libbitcoin-explorer.nix
index 93d8ceed2b47b..fe7290f801b50 100644
--- a/pkgs/tools/misc/libbitcoin/libbitcoin-explorer.nix
+++ b/pkgs/tools/misc/libbitcoin/libbitcoin-explorer.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
 , boost, libbitcoin-client, libbitcoin-network }:
 
 let
@@ -27,7 +27,7 @@ in stdenv.mkDerivation {
     "--with-bash-completiondir=$out/share/bash-completion/completions"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bitcoin command line tool";
     homepage = "https://github.com/libbitcoin/libbitcoin-explorer";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/misc/libbitcoin/libbitcoin-network.nix b/pkgs/tools/misc/libbitcoin/libbitcoin-network.nix
index fc660687ffc37..42f3669cad0aa 100644
--- a/pkgs/tools/misc/libbitcoin/libbitcoin-network.nix
+++ b/pkgs/tools/misc/libbitcoin/libbitcoin-network.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
 , boost, libbitcoin, zeromq }:
 
 let
@@ -26,7 +26,7 @@ in stdenv.mkDerivation {
     "--with-boost-libdir=${boost.out}/lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bitcoin P2P Network Library";
     homepage = "https://libbitcoin.org/";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/misc/libbitcoin/libbitcoin-protocol.nix b/pkgs/tools/misc/libbitcoin/libbitcoin-protocol.nix
index a5467fdcbd7a9..469e7e83085a3 100644
--- a/pkgs/tools/misc/libbitcoin/libbitcoin-protocol.nix
+++ b/pkgs/tools/misc/libbitcoin/libbitcoin-protocol.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
 , boost, libbitcoin, secp256k1, zeromq }:
 
 let
@@ -27,7 +27,7 @@ in stdenv.mkDerivation {
     "--with-boost-libdir=${boost.out}/lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bitcoin Blockchain Query Protocol";
     homepage = "https://libbitcoin.org/";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/misc/libbitcoin/libbitcoin.nix b/pkgs/tools/misc/libbitcoin/libbitcoin.nix
index e68635585d0f4..5198676cb75c8 100644
--- a/pkgs/tools/misc/libbitcoin/libbitcoin.nix
+++ b/pkgs/tools/misc/libbitcoin/libbitcoin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
 , boost, secp256k1 }:
 
 let
@@ -27,7 +27,7 @@ in stdenv.mkDerivation {
     "--with-boost-libdir=${boost.out}/lib"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C++ library for building bitcoin applications";
     homepage = "https://libbitcoin.org/";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/misc/libcpuid/default.nix b/pkgs/tools/misc/libcpuid/default.nix
index 873399c185bf9..cb02d87e22adf 100644
--- a/pkgs/tools/misc/libcpuid/default.nix
+++ b/pkgs/tools/misc/libcpuid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "libcpuid";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://libcpuid.sourceforge.net/";
     description = "A small C library for x86 CPU detection and feature extraction";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/lice/default.nix b/pkgs/tools/misc/lice/default.nix
index 2d96819e87784..f7a8c68ed0620 100644
--- a/pkgs/tools/misc/lice/default.nix
+++ b/pkgs/tools/misc/lice/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonPackage rec {
 
@@ -13,7 +13,7 @@ python3Packages.buildPythonPackage rec {
     fetchSubmodules = true;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Print license based on selection and user options";
     homepage = "https://github.com/licenses/lice";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/linuxquota/default.nix b/pkgs/tools/misc/linuxquota/default.nix
index b6b722379da88..58c6c1d535158 100644
--- a/pkgs/tools/misc/linuxquota/default.nix
+++ b/pkgs/tools/misc/linuxquota/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, e2fsprogs, openldap, pkgconfig }:
+{ lib, stdenv, fetchurl, e2fsprogs, openldap, pkgconfig }:
 
 stdenv.mkDerivation rec {
   version = "4.05";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ e2fsprogs openldap ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools to manage kernel-level quotas in Linux";
     homepage = "https://sourceforge.net/projects/linuxquota/";
     license = licenses.gpl2; # With some files being BSD as an exception
diff --git a/pkgs/tools/misc/lnav/default.nix b/pkgs/tools/misc/lnav/default.nix
index 9e5fad2698863..4d9364ff23e4d 100644
--- a/pkgs/tools/misc/lnav/default.nix
+++ b/pkgs/tools/misc/lnav/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pcre-cpp, sqlite, ncurses
+{ lib, stdenv, fetchFromGitHub, pcre-cpp, sqlite, ncurses
 , readline, zlib, bzip2, autoconf, automake, curl }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tstack/lnav";
     description = "The Logfile Navigator";
     longDescription = ''
diff --git a/pkgs/tools/misc/lnch/default.nix b/pkgs/tools/misc/lnch/default.nix
index 51b9b94ef70d6..377ba05eba69c 100644
--- a/pkgs/tools/misc/lnch/default.nix
+++ b/pkgs/tools/misc/lnch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage }:
 
 buildGoPackage rec {
   pname = "lnch";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "0skzrjnbxq1yj7y64cq7angp4wqnrgw1xp9v8vw9zp8f8zwmpy0y";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/oem/lnch";
     description = "A small go app that launches a process and moves it out of the process group";
     license = licenses.publicDomain; # really I don't know
diff --git a/pkgs/tools/misc/logstash/6.x.nix b/pkgs/tools/misc/logstash/6.x.nix
index b8008864bccfd..6735b5fd09628 100644
--- a/pkgs/tools/misc/logstash/6.x.nix
+++ b/pkgs/tools/misc/logstash/6.x.nix
@@ -1,6 +1,6 @@
 { elk6Version
 , enableUnfree ? true
-, stdenv
+, lib, stdenv
 , fetchurl
 , makeWrapper
 , jre
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A data pipeline that helps you process logs and other event data from a variety of systems";
     homepage    = "https://www.elastic.co/products/logstash";
     license     = if enableUnfree then licenses.elastic else licenses.asl20;
diff --git a/pkgs/tools/misc/logstash/7.x.nix b/pkgs/tools/misc/logstash/7.x.nix
index cd554167dda88..df661988877d3 100644
--- a/pkgs/tools/misc/logstash/7.x.nix
+++ b/pkgs/tools/misc/logstash/7.x.nix
@@ -1,6 +1,6 @@
 { elk7Version
 , enableUnfree ? true
-, stdenv
+, lib, stdenv
 , fetchurl
 , makeWrapper
 , jre
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Logstash is a data pipeline that helps you process logs and other event data from a variety of systems";
     homepage    = "https://www.elastic.co/products/logstash";
     license     = if enableUnfree then licenses.elastic else licenses.asl20;
diff --git a/pkgs/tools/misc/logtop/default.nix b/pkgs/tools/misc/logtop/default.nix
index a7b2f6282fd99..855a85f53aac5 100644
--- a/pkgs/tools/misc/logtop/default.nix
+++ b/pkgs/tools/misc/logtop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, uthash, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, ncurses, uthash, pkg-config }:
 
 stdenv.mkDerivation {
   name = "logtop-0.7";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     substituteInPlace Makefile --replace /usr ""
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Displays a real-time count of strings received from stdin";
     longDescription = ''
       logtop displays a real-time count of strings received from stdin.
diff --git a/pkgs/tools/misc/lokalise2-cli/default.nix b/pkgs/tools/misc/lokalise2-cli/default.nix
index ccf7a05907d1e..1b2fa9bda86b5 100644
--- a/pkgs/tools/misc/lokalise2-cli/default.nix
+++ b/pkgs/tools/misc/lokalise2-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "lokalise2-cli";
@@ -19,7 +19,7 @@ buildGoModule rec {
     mv $out/bin/lokalise-cli-2-go $out/bin/lokalise2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Translation platform for developers. Upload language files, translate, integrate via API";
     homepage = "https://lokalise.com";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/loop/default.nix b/pkgs/tools/misc/loop/default.nix
index 3cc0466d80adc..b7bd7678535c1 100644
--- a/pkgs/tools/misc/loop/default.nix
+++ b/pkgs/tools/misc/loop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage {
   pname = "loop";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage {
 
   cargoSha256 = "0a3l580ca23vx8isd1qff870ci3p7wf4qrm53jl7nhfjh7rg5a4w";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "UNIX's missing `loop` command";
     homepage = "https://github.com/Miserlou/Loop";
     maintainers = with maintainers; [ koral ];
diff --git a/pkgs/tools/misc/lorri/default.nix b/pkgs/tools/misc/lorri/default.nix
index 99ac31f6a0b94..d191a82853fc4 100644
--- a/pkgs/tools/misc/lorri/default.nix
+++ b/pkgs/tools/misc/lorri/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , pkgs
 , fetchFromGitHub
 , rustPlatform
@@ -23,7 +23,7 @@ in (rustPlatform.buildRustPackage rec {
   pname = "lorri";
   inherit version;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Your project's nix-env";
     homepage = "https://github.com/target/lorri";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/lottieconverter/default.nix b/pkgs/tools/misc/lottieconverter/default.nix
index bf2a68df702ad..aae27cb652eb7 100644
--- a/pkgs/tools/misc/lottieconverter/default.nix
+++ b/pkgs/tools/misc/lottieconverter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpng, rlottie, zlib }:
+{ lib, stdenv, fetchFromGitHub, libpng, rlottie, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "LottieConverter";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sot-tech/LottieConverter/";
     description = "Lottie converter utility";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/tools/misc/lrzsz/default.nix b/pkgs/tools/misc/lrzsz/default.nix
index 112a14f55f241..55c11b00c93c1 100644
--- a/pkgs/tools/misc/lrzsz/default.nix
+++ b/pkgs/tools/misc/lrzsz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "lrzsz-0.12.20";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--program-transform-name=s/^l//" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ohse.de/uwe/software/lrzsz.html";
     description = "Communication package providing the XMODEM, YMODEM ZMODEM file transfer protocols";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/lsd/default.nix b/pkgs/tools/misc/lsd/default.nix
index 706b66d998c36..239c9651b86de 100644
--- a/pkgs/tools/misc/lsd/default.nix
+++ b/pkgs/tools/misc/lsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , nixosTests
 , fetchFromGitHub
 , rustPlatform
@@ -28,7 +28,7 @@ rustPlatform.buildRustPackage rec {
 
   passthru.tests = { inherit (nixosTests) lsd; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Peltoche/lsd";
     description = "The next gen ls command";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/ltunify/default.nix b/pkgs/tools/misc/ltunify/default.nix
index e345f86e0212d..b97a0e42ee000 100644
--- a/pkgs/tools/misc/ltunify/default.nix
+++ b/pkgs/tools/misc/ltunify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 # Although we copy in the udev rules here, you probably just want to use logitech-udev-rules instead of
 # adding this to services.udev.packages on NixOS
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "DESTDIR=$(out)" "bindir=/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for working with Logitech Unifying receivers and devices";
     homepage = "https://lekensteyn.nl/logitech-unifying.html";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/makebootfat/default.nix b/pkgs/tools/misc/makebootfat/default.nix
index dc66976720d0c..1f512d04a2254 100644
--- a/pkgs/tools/misc/makebootfat/default.nix
+++ b/pkgs/tools/misc/makebootfat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "makebootfat-1.4";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "0v0g1xax0y6hmw2x10nfhchp9n7vqyvgc33gcxqax8jdq2pxm1q2";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create bootable USB disks using the FAT filesystem and syslinux";
     homepage = "http://advancemame.sourceforge.net/boot-readme.html";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/man-db/default.nix b/pkgs/tools/misc/man-db/default.nix
index 68e1aaa4d6134..2816392e18ca8 100644
--- a/pkgs/tools/misc/man-db/default.nix
+++ b/pkgs/tools/misc/man-db/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libpipeline, db, groff, libiconv, makeWrapper, buildPackages }:
+{ lib, stdenv, fetchurl, pkgconfig, libpipeline, db, groff, libiconv, makeWrapper, buildPackages }:
 
 stdenv.mkDerivation rec {
   name = "man-db-2.9.3";
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
 
   doCheck = !stdenv.hostPlatform.isMusl /* iconv binary */ && !stdenv.hostPlatform.isDarwin;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://man-db.nongnu.org";
     description = "An implementation of the standard Unix documentation system accessed using the man command";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/mandoc/default.nix b/pkgs/tools/misc/mandoc/default.nix
index 82fc1dee00c3e..da756f764d400 100644
--- a/pkgs/tools/misc/mandoc/default.nix
+++ b/pkgs/tools/misc/mandoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib }:
+{ lib, stdenv, fetchurl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "mandoc";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     echo $configureLocal > configure.local
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mandoc.bsd.lv/";
     description = "suite of tools compiling mdoc and man";
     downloadPage = "http://mandoc.bsd.lv/snapshots/";
diff --git a/pkgs/tools/misc/marlin-calc/default.nix b/pkgs/tools/misc/marlin-calc/default.nix
index c7222f696c99e..0e75af62231c4 100644
--- a/pkgs/tools/misc/marlin-calc/default.nix
+++ b/pkgs/tools/misc/marlin-calc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "marlin-calc";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     install -Dm0755 {,$out/bin/}marlin-calc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/eyal0/Marlin";
     description = "Marlin 3D printer timing simulator";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/mc/default.nix b/pkgs/tools/misc/mc/default.nix
index fb279f313b4d5..8dd6bd0195b28 100644
--- a/pkgs/tools/misc/mc/default.nix
+++ b/pkgs/tools/misc/mc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , glib
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     sed -i -e "s!PKG_CONFIG_PATH=''${PKG_CONFIG_PATH}!PKG_CONFIG_PATH=$(echo "$PKG_CONFIG_PATH" | sed -e 's/./0/g')!" $out/bin/mc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "File Manager and User Shell for the GNU Project";
     downloadPage = "https://www.midnight-commander.org/downloads/";
     homepage = "https://www.midnight-commander.org";
diff --git a/pkgs/tools/misc/mcfly/default.nix b/pkgs/tools/misc/mcfly/default.nix
index 68a2b877c912e..4fee29216fd9d 100644
--- a/pkgs/tools/misc/mcfly/default.nix
+++ b/pkgs/tools/misc/mcfly/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "mcfly";
@@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1c8qjkpc8wi095zzmgd05721kdf1knh9la91l081mvwa3inwk6ax";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cantino/mcfly";
     description = "An upgraded ctrl-r for Bash whose history results make sense for what you're working on right now";
     changelog = "https://github.com/cantino/mcfly/blob/v${version}/CHANGELOG.txt";
diff --git a/pkgs/tools/misc/me_cleaner/default.nix b/pkgs/tools/misc/me_cleaner/default.nix
index d224ad1dcc5d5..19f43f2c8c5f9 100644
--- a/pkgs/tools/misc/me_cleaner/default.nix
+++ b/pkgs/tools/misc/me_cleaner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub }:
 
 buildPythonPackage rec {
   pname = "me_cleaner";
@@ -11,7 +11,7 @@ buildPythonPackage rec {
     sha256 = "1bdj2clm13ir441vn7sv860xsc5gh71ja5lc2wn0gggnff0adxj4";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Tool for partial deblobbing of Intel ME/TXE firmware images";
     longDescription = ''
diff --git a/pkgs/tools/misc/mht2htm/default.nix b/pkgs/tools/misc/mht2htm/default.nix
index 31f645e48ceb8..e417c0e665dbc 100644
--- a/pkgs/tools/misc/mht2htm/default.nix
+++ b/pkgs/tools/misc/mht2htm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, fpc, lazarus }:
+{ lib, stdenv, fetchurl, unzip, fpc, lazarus }:
 
 let
   date = "07.apr.2016";
@@ -33,7 +33,7 @@ in stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert .mht files to .html";
     homepage    = "http://pgm.bpalanka.com/mht2htm.html";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/misc/microplane/default.nix b/pkgs/tools/misc/microplane/default.nix
index f50a3c6ad8e25..a0ac411f98e10 100644
--- a/pkgs/tools/misc/microplane/default.nix
+++ b/pkgs/tools/misc/microplane/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "microplane";
@@ -31,7 +31,7 @@ buildGoPackage rec {
     ln -s $out/bin/microplane $out/bin/mp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CLI tool to make git changes across many repos";
     homepage = "https://github.com/Clever/microplane";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/mimeo/default.nix b/pkgs/tools/misc/mimeo/default.nix
index 55cc9717688a6..6c332198fa75e 100644
--- a/pkgs/tools/misc/mimeo/default.nix
+++ b/pkgs/tools/misc/mimeo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, desktop-file-utils, file, python3Packages }:
+{ lib, stdenv, fetchurl, desktop-file-utils, file, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "mimeo";
@@ -23,7 +23,7 @@ python3Packages.buildPythonApplication rec {
 
   installPhase = "install -Dm755 Mimeo.py $out/bin/mimeo";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open files by MIME-type or file name using regular expressions";
     homepage = "http://xyne.archlinux.ca/projects/mimeo/";
     license = [ licenses.gpl2 ];
diff --git a/pkgs/tools/misc/minicom/default.nix b/pkgs/tools/misc/minicom/default.nix
index 35c04faf45921..b52d2d26baa05 100644
--- a/pkgs/tools/misc/minicom/default.nix
+++ b/pkgs/tools/misc/minicom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, makeWrapper, pkgconfig
+{ lib, stdenv, fetchgit, autoreconfHook, makeWrapper, pkgconfig
 , lrzsz, ncurses, libiconv }:
 
 stdenv.mkDerivation {
@@ -38,7 +38,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modem control and terminal emulation program";
     homepage = "https://salsa.debian.org/minicom-team/minicom";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/miniserve/default.nix b/pkgs/tools/misc/miniserve/default.nix
index 93338ddf27be8..aa549f5691a90 100644
--- a/pkgs/tools/misc/miniserve/default.nix
+++ b/pkgs/tools/misc/miniserve/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , pkg-config
@@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec {
   nativeBuildInputs = [ pkg-config zlib ];
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "For when you really just want to serve some files over HTTP right now!";
     homepage = "https://github.com/svenstaro/miniserve";
     license = with licenses; [ mit ];
diff --git a/pkgs/tools/misc/ministat/default.nix b/pkgs/tools/misc/ministat/default.nix
index dfc2e2c624edd..68670599c1ee6 100644
--- a/pkgs/tools/misc/ministat/default.nix
+++ b/pkgs/tools/misc/ministat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit }:
+{ lib, stdenv, fetchgit }:
 
 stdenv.mkDerivation rec {
   pname = "ministat";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp ministat.1 $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple tool for statistical comparison of data sets";
     homepage = "https://git.decadent.org.uk/gitweb/?p=ministat.git";
     license = licenses.beerware;
diff --git a/pkgs/tools/misc/mlocate/default.nix b/pkgs/tools/misc/mlocate/default.nix
index d3f406c535526..d28828f2a4f64 100644
--- a/pkgs/tools/misc/mlocate/default.nix
+++ b/pkgs/tools/misc/mlocate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, config }:
+{ lib, stdenv, fetchurl, config }:
 
 let
   dbfile = stdenv.lib.attrByPath [ "locate" "dbfile" ] "/var/cache/locatedb" config;
@@ -14,7 +14,7 @@ in stdenv.mkDerivation rec {
   buildInputs = [ ];
   makeFlags = [ "dbfile=${dbfile}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Merging locate is an utility to index and quickly search for files";
     homepage = "https://pagure.io/mlocate";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/mmake/default.nix b/pkgs/tools/misc/mmake/default.nix
index a761530a0a00d..5dcbcb065ecca 100644
--- a/pkgs/tools/misc/mmake/default.nix
+++ b/pkgs/tools/misc/mmake/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "mmake";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tj/mmake";
     description = "A small program  which wraps make to provide additional functionality";
     longDescription = ''
diff --git a/pkgs/tools/misc/mongodb-compass/default.nix b/pkgs/tools/misc/mongodb-compass/default.nix
index 28a1339e9a376..3774a77f5a446 100644
--- a/pkgs/tools/misc/mongodb-compass/default.nix
+++ b/pkgs/tools/misc/mongodb-compass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg
+{ lib, stdenv, fetchurl, dpkg
 , alsaLib, at-spi2-atk, at-spi2-core, atk, cairo, cups, curl, dbus, expat, fontconfig, freetype, glib
 , gnome2, gdk-pixbuf, gtk3, pango, libnotify, libsecret, libuuid, libxcb, nspr, nss, systemd, xorg, wrapGAppsHook }:
 
@@ -92,7 +92,7 @@ in stdenv.mkDerivation {
     wrapGAppsHook $out/bin/mongodb-compass
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The GUI for MongoDB";
     homepage = "https://www.mongodb.com/products/compass";
     license = licenses.unfree;
diff --git a/pkgs/tools/misc/most/default.nix b/pkgs/tools/misc/most/default.nix
index 7adac5ee2ee6d..de2118083d984 100644
--- a/pkgs/tools/misc/most/default.nix
+++ b/pkgs/tools/misc/most/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, slang, ncurses }:
+{ lib, stdenv, fetchurl, slang, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "most";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ slang ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A terminal pager similar to 'more' and 'less'";
     longDescription = ''
       MOST is a powerful paging program for Unix, VMS, MSDOS, and win32
diff --git a/pkgs/tools/misc/mpdscribble/default.nix b/pkgs/tools/misc/mpdscribble/default.nix
index b3665bb6dcf1b..4e033a44cfd5f 100644
--- a/pkgs/tools/misc/mpdscribble/default.nix
+++ b/pkgs/tools/misc/mpdscribble/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, ninja, pkgconfig, boost, libgcrypt, systemd, mpd_clientlib, curl }:
+{ lib, stdenv, fetchurl, meson, ninja, pkgconfig, boost, libgcrypt, systemd, mpd_clientlib, curl }:
 
 stdenv.mkDerivation rec {
   pname = "mpdscribble";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson ninja pkgconfig ];
   buildInputs = [ mpd_clientlib curl boost libgcrypt systemd ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Music Player Daemon (MPD) client which submits information about tracks being played to a scrobbler (e.g. last.fm)";
     homepage = "https://www.musicpd.org/clients/mpdscribble/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/ms-sys/default.nix b/pkgs/tools/misc/ms-sys/default.nix
index 315dbce74070e..0df6de82bd2f5 100644
--- a/pkgs/tools/misc/ms-sys/default.nix
+++ b/pkgs/tools/misc/ms-sys/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gettext }:
+{ lib, stdenv, fetchurl, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "ms-sys";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A program for writing Microsoft-compatible boot records";
     homepage = "http://ms-sys.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/mstflint/default.nix b/pkgs/tools/misc/mstflint/default.nix
index be3993d81ecf2..70bace74b1e9a 100644
--- a/pkgs/tools/misc/mstflint/default.nix
+++ b/pkgs/tools/misc/mstflint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoreconfHook, fetchFromGitHub, zlib, libibmad, openssl }:
+{ lib, stdenv, autoreconfHook, fetchFromGitHub, zlib, libibmad, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "mstflint";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   dontDisableStatic = true;  # the build fails without this. should probably be reported upstream
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source version of Mellanox Firmware Tools (MFT)";
     homepage = "https://github.com/Mellanox/mstflint";
     license = with licenses; [ gpl2 bsd2 ];
diff --git a/pkgs/tools/misc/mtm/default.nix b/pkgs/tools/misc/mtm/default.nix
index 5b45c0b712bfe..bc8ac50d1aeb5 100644
--- a/pkgs/tools/misc/mtm/default.nix
+++ b/pkgs/tools/misc/mtm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "mtm";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Perhaps the smallest useful terminal multiplexer in the world";
     homepage = "https://github.com/deadpixi/mtm";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/mysqltuner/default.nix b/pkgs/tools/misc/mysqltuner/default.nix
index 2f7889111b0ef..6297e6131222e 100644
--- a/pkgs/tools/misc/mysqltuner/default.nix
+++ b/pkgs/tools/misc/mysqltuner/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl }:
+{ lib, stdenv, fetchFromGitHub, perl }:
 
 stdenv.mkDerivation rec {
   pname = "mysqltuner";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -m0755 mysqltuner.pl $out/bin/mysqltuner
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Make recommendations for increased performance and stability of MariaDB/MySQL";
     homepage = "http://mysqltuner.com";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/nagstamon/default.nix b/pkgs/tools/misc/nagstamon/default.nix
index 9b063947a4491..7f3c3ed4d5605 100644
--- a/pkgs/tools/misc/nagstamon/default.nix
+++ b/pkgs/tools/misc/nagstamon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages }:
+{ lib, stdenv, fetchurl, pythonPackages }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "nagstamon";
@@ -15,7 +15,7 @@ pythonPackages.buildPythonApplication rec {
   propagatedBuildInputs = with pythonPackages; [ configparser pyqt5 psutil requests
      beautifulsoup4 keyring requests-kerberos kerberos lxml ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A status monitor for the desktop";
     homepage = "https://nagstamon.ifw-dresden.de/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/nbench/default.nix b/pkgs/tools/misc/nbench/default.nix
index 950f3883f8f46..adca412daf84f 100644
--- a/pkgs/tools/misc/nbench/default.nix
+++ b/pkgs/tools/misc/nbench/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "nbench-byte";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp NNET.DAT $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.math.utah.edu/~mayer/linux/bmark.html";
     description = "A synthetic computing benchmark program";
     platforms = platforms.linux;
diff --git a/pkgs/tools/misc/ncdu/default.nix b/pkgs/tools/misc/ncdu/default.nix
index 2d56ab9c09bd4..3510be4ed775d 100644
--- a/pkgs/tools/misc/ncdu/default.nix
+++ b/pkgs/tools/misc/ncdu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "ncdu";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Disk usage analyzer with an ncurses interface";
     homepage = "https://dev.yorhel.nl/ncdu";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/neofetch/default.nix b/pkgs/tools/misc/neofetch/default.nix
index f08e3828325aa..1ed201802d53c 100644
--- a/pkgs/tools/misc/neofetch/default.nix
+++ b/pkgs/tools/misc/neofetch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "neofetch";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "SYSCONFDIR=${placeholder "out"}/etc"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast, highly customizable system info script";
     homepage = "https://github.com/dylanaraps/neofetch";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/nginx-config-formatter/default.nix b/pkgs/tools/misc/nginx-config-formatter/default.nix
index c9726d7e04031..fb5412a5866b1 100644
--- a/pkgs/tools/misc/nginx-config-formatter/default.nix
+++ b/pkgs/tools/misc/nginx-config-formatter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 stdenv.mkDerivation {
   version = "2019-02-13";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     install -m 0755 $src/nginxfmt.py $out/bin/nginxfmt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "nginx config file formatter";
     maintainers = with maintainers; [ Baughn ];
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/nix-direnv/default.nix b/pkgs/tools/misc/nix-direnv/default.nix
index 392de7d1bd94f..95175f81c8ef9 100644
--- a/pkgs/tools/misc/nix-direnv/default.nix
+++ b/pkgs/tools/misc/nix-direnv/default.nix
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast, persistent use_nix implementation for direnv";
     homepage    = "https://github.com/nix-community/nix-direnv";
     license     = licenses.mit;
diff --git a/pkgs/tools/misc/nms/default.nix b/pkgs/tools/misc/nms/default.nix
index 0005ffe824b0c..8edddc4238dfc 100644
--- a/pkgs/tools/misc/nms/default.nix
+++ b/pkgs/tools/misc/nms/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "nms";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildFlags = [ "nms" "sneakers" ];
   installFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bartobri/no-more-secrets";
     description = ''
       A command line tool that recreates the famous data decryption
diff --git a/pkgs/tools/misc/nncp/default.nix b/pkgs/tools/misc/nncp/default.nix
index 3322ed0c8a460..4469f130b5892 100644
--- a/pkgs/tools/misc/nncp/default.nix
+++ b/pkgs/tools/misc/nncp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , go
 , fetchurl
 , curl
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     '';
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Secure UUCP-like store-and-forward exchanging";
     longDescription = ''
       This utilities are intended to help build up small size (dozens of
diff --git a/pkgs/tools/misc/noteshrink/default.nix b/pkgs/tools/misc/noteshrink/default.nix
index b934b12887031..2d6f23de46879 100644
--- a/pkgs/tools/misc/noteshrink/default.nix
+++ b/pkgs/tools/misc/noteshrink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, imagemagick }:
+{ lib, stdenv, fetchFromGitHub, python3, imagemagick }:
 
 with python3.pkgs;
 
@@ -15,7 +15,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ numpy scipy imagemagick pillow ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert scans of handwritten notes to beautiful, compact PDFs";
     homepage    = "https://mzucker.github.io/2016/09/20/noteshrink.html";
     license     = licenses.mit;
diff --git a/pkgs/tools/misc/notify-desktop/default.nix b/pkgs/tools/misc/notify-desktop/default.nix
index 61aa2c41c4fc0..03e7fbb5c020a 100644
--- a/pkgs/tools/misc/notify-desktop/default.nix
+++ b/pkgs/tools/misc/notify-desktop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, dbus, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, dbus, pkgconfig }:
 
 stdenv.mkDerivation {
   pname = "notify-desktop";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     install -m 755 bin/notify-desktop $out/bin/notify-desktop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Little application that lets you send desktop notifications with one command";
     longDescription = ''
       It's basically clone of notify-send from libnotify,
diff --git a/pkgs/tools/misc/ntfy/default.nix b/pkgs/tools/misc/ntfy/default.nix
index 593a8cfc637d5..9f28d99ba0f3f 100644
--- a/pkgs/tools/misc/ntfy/default.nix
+++ b/pkgs/tools/misc/ntfy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 python3Packages.buildPythonApplication rec {
   pname = "ntfy";
@@ -28,7 +28,7 @@ python3Packages.buildPythonApplication rec {
     HOME=$(mktemp -d) ${python3Packages.python.interpreter} setup.py test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility for sending notifications, on demand and when commands finish";
     homepage = "http://ntfy.rtfd.org/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/nvimpager/default.nix b/pkgs/tools/misc/nvimpager/default.nix
index 2c10c9fbfbb57..61f9e7262c92b 100644
--- a/pkgs/tools/misc/nvimpager/default.nix
+++ b/pkgs/tools/misc/nvimpager/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 , ncurses, neovim, procps
 , pandoc, lua51Packages, util-linux
 }:
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
   checkInputs = [ lua51Packages.busted util-linux neovim ];
   checkPhase = ''script -c "busted --lpath './?.lua' test"'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Use neovim as pager";
     longDescription = ''
       Use neovim as a pager to view manpages, diffs, etc with nvim's syntax
diff --git a/pkgs/tools/misc/nyancat/default.nix b/pkgs/tools/misc/nyancat/default.nix
index d4092c237df79..3aca7cc1729cc 100644
--- a/pkgs/tools/misc/nyancat/default.nix
+++ b/pkgs/tools/misc/nyancat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "nyancat";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Nyancat in your terminal, rendered through ANSI escape sequences";
     homepage = "https://nyancat.dakko.us";
     license = licenses.ncsa;
diff --git a/pkgs/tools/misc/odroid-xu3-bootloader/default.nix b/pkgs/tools/misc/odroid-xu3-bootloader/default.nix
index 3896ca77a1668..052c46cef8cb6 100644
--- a/pkgs/tools/misc/odroid-xu3-bootloader/default.nix
+++ b/pkgs/tools/misc/odroid-xu3-bootloader/default.nix
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
       $out/bin/sd_fuse-xu3
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     license = licenses.unfreeRedistributableFirmware;
     description = "Secure boot enabled boot loader for ODROID-XU{3,4}";
diff --git a/pkgs/tools/misc/odyssey/default.nix b/pkgs/tools/misc/odyssey/default.nix
index f736184ea50ea..788f300673585 100644
--- a/pkgs/tools/misc/odyssey/default.nix
+++ b/pkgs/tools/misc/odyssey/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, openssl }:
+{ lib, stdenv, fetchFromGitHub, cmake, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "odyssey";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -Dm755 -t $out/bin sources/odyssey
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scalable PostgreSQL connection pooler";
     homepage = "https://github.com/yandex/odyssey";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/onefetch/default.nix b/pkgs/tools/misc/onefetch/default.nix
index 165a49fad038c..7a010eb5e68af 100644
--- a/pkgs/tools/misc/onefetch/default.nix
+++ b/pkgs/tools/misc/onefetch/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, rustPlatform, stdenv, fetchpatch
+{ fetchFromGitHub, rustPlatform, lib, stdenv, fetchpatch
 , CoreFoundation, libiconv, libresolv, Security }:
 
 rustPlatform.buildRustPackage rec {
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
   buildInputs = with stdenv;
     lib.optionals isDarwin [ CoreFoundation libiconv libresolv Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Git repository summary on your terminal";
     homepage = "https://github.com/o2sh/onefetch";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/opencorsairlink/default.nix b/pkgs/tools/misc/opencorsairlink/default.nix
index 11df20b3b827c..62772021bacaf 100644
--- a/pkgs/tools/misc/opencorsairlink/default.nix
+++ b/pkgs/tools/misc/opencorsairlink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libusb1, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, libusb1, pkgconfig }:
 
 stdenv.mkDerivation rec {
   name = "OpenCorsairLink-${version}";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     sha256 = "1nizicl0mc9pslc6065mnrs0fnn8sh7ca8iiw7w9ix57zrhabpld";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Linux and Mac OS support for the CorsairLink Devices ";
     homepage = "https://github.com/audiohacked/OpenCorsairLink";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/opentsdb/default.nix b/pkgs/tools/misc/opentsdb/default.nix
index ed80f620318a3..bbfecd58686c7 100644
--- a/pkgs/tools/misc/opentsdb/default.nix
+++ b/pkgs/tools/misc/opentsdb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoconf, automake, curl, fetchurl, jdk8, makeWrapper, nettools
+{ lib, stdenv, autoconf, automake, curl, fetchurl, jdk8, makeWrapper, nettools
 , python, git
 }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       --set JAVA "${jre}/bin/java"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Time series database with millisecond precision";
     homepage = "http://opentsdb.net";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/tools/misc/oppai-ng/default.nix b/pkgs/tools/misc/oppai-ng/default.nix
index e44999d1c3487..922ef65be24bc 100644
--- a/pkgs/tools/misc/oppai-ng/default.nix
+++ b/pkgs/tools/misc/oppai-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     install -D liboppai.so $out/lib/liboppai.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Difficulty and pp calculator for osu!";
     homepage = "https://github.com/Francesco149/oppai-ng";
     license = licenses.unlicense;
diff --git a/pkgs/tools/misc/os-prober/default.nix b/pkgs/tools/misc/os-prober/default.nix
index 9b2afed0a9a10..4914572f15635 100644
--- a/pkgs/tools/misc/os-prober/default.nix
+++ b/pkgs/tools/misc/os-prober/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, makeWrapper, nixosTests,
+{ lib, stdenv, fetchFromGitLab, makeWrapper, nixosTests,
 # optional dependencies, the command(s) they provide
 coreutils,  # mktemp
 grub2,      # grub-mount and grub-probe
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
   passthru.tests = {
     os-prober = nixosTests.os-prober;
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility to detect other OSs on a set of drives";
     homepage = "http://packages.debian.org/source/sid/os-prober";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/osinfo-db-tools/default.nix b/pkgs/tools/misc/osinfo-db-tools/default.nix
index c0921a496cc2c..298a7da6e2a33 100644
--- a/pkgs/tools/misc/osinfo-db-tools/default.nix
+++ b/pkgs/tools/misc/osinfo-db-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, meson, ninja, gettext, glib, libxml2, perl, python3
+{ lib, stdenv, fetchurl, pkgconfig, meson, ninja, gettext, glib, libxml2, perl, python3
 , libxslt, libarchive, bzip2, lzma, json-glib, libsoup
 }:
 
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson ninja pkgconfig gettext perl python3 ];
   buildInputs = [ glib json-glib libxml2 libxslt libarchive bzip2 lzma libsoup ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for managing the osinfo database";
     homepage = "https://libosinfo.org/";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/misc/osm2pgsql/default.nix b/pkgs/tools/misc/osm2pgsql/default.nix
index 0d5adcdb52430..184ebc19bf24f 100644
--- a/pkgs/tools/misc/osm2pgsql/default.nix
+++ b/pkgs/tools/misc/osm2pgsql/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , expat
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-DACCEPT_USE_OF_DEPRECATED_PROJ_API_H";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenStreetMap data to PostgreSQL converter";
     homepage = "https://osm2pgsql.org";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/ostree/default.nix b/pkgs/tools/misc/ostree/default.nix
index e2cda521f08fa..c1716fef5db96 100644
--- a/pkgs/tools/misc/ostree/default.nix
+++ b/pkgs/tools/misc/ostree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , substituteAll
@@ -135,7 +135,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Git for operating system binaries";
     homepage = "https://ostree.readthedocs.io/en/latest/";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/misc/otfcc/default.nix b/pkgs/tools/misc/otfcc/default.nix
index dc7e3effe0a1c..c4a9c5a278e60 100644
--- a/pkgs/tools/misc/otfcc/default.nix
+++ b/pkgs/tools/misc/otfcc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, premake5 }:
+{ lib, stdenv, fetchFromGitHub, premake5 }:
 
 stdenv.mkDerivation rec {
   pname = "otfcc";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimized OpenType builder and inspector";
     homepage = "https://github.com/caryll/otfcc";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/ovh-ttyrec/default.nix b/pkgs/tools/misc/ovh-ttyrec/default.nix
index 5601509726a30..fc2c2c3d67a3b 100644
--- a/pkgs/tools/misc/ovh-ttyrec/default.nix
+++ b/pkgs/tools/misc/ovh-ttyrec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, zstd }:
+{ lib, stdenv, fetchFromGitHub, zstd }:
 
 stdenv.mkDerivation rec {
   pname = "ovh-ttyrec";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     cp docs/*.1 $out/man
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ovh/ovh-ttyrec/";
     description = "Terminal interaction recorder and player";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/pandoc-lua-filters/default.nix b/pkgs/tools/misc/pandoc-lua-filters/default.nix
index b7c081c1ddd03..6eb3359b3b5ec 100644
--- a/pkgs/tools/misc/pandoc-lua-filters/default.nix
+++ b/pkgs/tools/misc/pandoc-lua-filters/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of lua filters for pandoc";
     homepage = "https://github.com/pandoc/lua-filters";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/paps/default.nix b/pkgs/tools/misc/paps/default.nix
index 8084f49f1b38d..3a8040bd5f13a 100644
--- a/pkgs/tools/misc/paps/default.nix
+++ b/pkgs/tools/misc/paps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoconf, automake, pkgconfig, intltool, pango }:
 
 stdenv.mkDerivation rec {
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pango to PostScript converter";
     homepage = "https://github.com/dov/paps";
     license = licenses.lgpl2;
diff --git a/pkgs/tools/misc/parallel/default.nix b/pkgs/tools/misc/parallel/default.nix
index 45439afe3d11b..9cc4926443b56 100644
--- a/pkgs/tools/misc/parallel/default.nix
+++ b/pkgs/tools/misc/parallel/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, perl, makeWrapper, procps, coreutils }:
+{ fetchurl, lib, stdenv, perl, makeWrapper, procps, coreutils }:
 
 stdenv.mkDerivation rec {
   name = "parallel-20200922";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shell tool for executing jobs in parallel";
     longDescription =
       '' GNU Parallel is a shell tool for executing jobs in parallel.  A job
diff --git a/pkgs/tools/misc/parcellite/default.nix b/pkgs/tools/misc/parcellite/default.nix
index 97c67f59b0843..861d83bcfcea5 100644
--- a/pkgs/tools/misc/parcellite/default.nix
+++ b/pkgs/tools/misc/parcellite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, autoreconfHook
 , gtk2, hicolor-icon-theme, intltool, pkgconfig
 , which, wrapGAppsHook, xdotool }:
 
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     gappsWrapperArgs+=(--prefix PATH : "${which}/bin:${xdotool}/bin")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight GTK clipboard manager";
     homepage = "https://github.com/rickyrockrat/parcellite";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/pastebinit/default.nix b/pkgs/tools/misc/pastebinit/default.nix
index 9b4202504a0f1..4b28f49acaa25 100644
--- a/pkgs/tools/misc/pastebinit/default.nix
+++ b/pkgs/tools/misc/pastebinit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , python3
@@ -42,7 +42,7 @@ stdenv.mkDerivation rec {
     substituteInPlace $out/bin/pastebinit --replace "'/etc/pastebin.d" "'$out/etc/pastebin.d"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/pastebinit";
     description = "A software that lets you send anything you want directly to a pastebin from the command line";
     maintainers = with maintainers; [ lethalman raboof ];
diff --git a/pkgs/tools/misc/pazi/default.nix b/pkgs/tools/misc/pazi/default.nix
index cc7e7b043e0ee..0375b8e148401 100644
--- a/pkgs/tools/misc/pazi/default.nix
+++ b/pkgs/tools/misc/pazi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "pazi";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0sja0q9i0b1zb3a0a6z561yg9lqykylwr3iwin4r6cmi7j2sw5j6";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An autojump \"zap to directory\" helper";
     homepage = "https://github.com/euank/pazi";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/pb_cli/default.nix b/pkgs/tools/misc/pb_cli/default.nix
index 858422b853286..9d33f088af0d3 100644
--- a/pkgs/tools/misc/pb_cli/default.nix
+++ b/pkgs/tools/misc/pb_cli/default.nix
@@ -1,5 +1,5 @@
 { screenshots ? true, video ? false, clipboard ? true
-, stdenv, jq, curl, fetchFromGitHub, makeWrapper, maim ? null, xclip ? null, capture ? null }:
+, lib, stdenv, jq, curl, fetchFromGitHub, makeWrapper, maim ? null, xclip ? null, capture ? null }:
 
 assert screenshots -> maim != null;
 assert video -> capture != null;
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : '${stdenv.lib.makeBinPath liveDeps}'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A no bullshit 0x0.st client";
     homepage = "https://github.com/ptpb/pb_cli";
     maintainers = [ maintainers.ar1a ];
diff --git a/pkgs/tools/misc/pdd/default.nix b/pkgs/tools/misc/pdd/default.nix
index 37f9e2f4ce5b3..b339f94deb186 100644
--- a/pkgs/tools/misc/pdd/default.nix
+++ b/pkgs/tools/misc/pdd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonApplication, dateutil }:
+{ lib, stdenv, fetchFromGitHub, buildPythonApplication, dateutil }:
 
 buildPythonApplication rec {
   pname = "pdd";
@@ -17,7 +17,7 @@ buildPythonApplication rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jarun/pdd";
     description = "Tiny date, time diff calculator";
     longDescription = ''
diff --git a/pkgs/tools/misc/pdf-parser/default.nix b/pkgs/tools/misc/pdf-parser/default.nix
index 3fee457f6f541..ceb8b4d68d995 100644
--- a/pkgs/tools/misc/pdf-parser/default.nix
+++ b/pkgs/tools/misc/pdf-parser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchzip }:
+{ lib, stdenv, python3Packages, fetchzip }:
 
 python3Packages.buildPythonApplication {
   pname = "pdf-parser";
@@ -20,7 +20,7 @@ python3Packages.buildPythonApplication {
       --replace '/usr/bin/python' '${python3Packages.python}/bin/python'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parse a PDF document";
     longDescription = ''
       This tool will parse a PDF document to identify the fundamental elements used in the analyzed file.
diff --git a/pkgs/tools/misc/pfsshell/default.nix b/pkgs/tools/misc/pfsshell/default.nix
index e941cbd84c796..10cde1385bb21 100644
--- a/pkgs/tools/misc/pfsshell/default.nix
+++ b/pkgs/tools/misc/pfsshell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja }:
 
 stdenv.mkDerivation rec {
   version = "1.1.1";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   #   cc1: error: '-Wformat-security' ignored without '-Wformat' [-Werror=format-security]
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "PFS (PlayStation File System) shell for POSIX-based systems";
     platforms = platforms.unix;
diff --git a/pkgs/tools/misc/pg_top/default.nix b/pkgs/tools/misc/pg_top/default.nix
index ca3318d45c672..a5d1baf1fd185 100644
--- a/pkgs/tools/misc/pg_top/default.nix
+++ b/pkgs/tools/misc/pg_top/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, postgresql }:
+{ lib, stdenv, fetchurl, ncurses, postgresql }:
 
 stdenv.mkDerivation rec {
   name = "pg_top-3.7.0";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ncurses postgresql ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 'top' like tool for PostgreSQL";
     longDescription = '' 
       pg_top allows you to: 
diff --git a/pkgs/tools/misc/pgcenter/default.nix b/pkgs/tools/misc/pgcenter/default.nix
index 601694ebc37df..5a59e3030e64a 100644
--- a/pkgs/tools/misc/pgcenter/default.nix
+++ b/pkgs/tools/misc/pgcenter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "pgcenter";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pgcenter.org/";
     description = "Command-line admin tool for observing and troubleshooting PostgreSQL";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/pgmetrics/default.nix b/pkgs/tools/misc/pgmetrics/default.nix
index e516847767274..377c0eed24b73 100644
--- a/pkgs/tools/misc/pgmetrics/default.nix
+++ b/pkgs/tools/misc/pgmetrics/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "pgmetrics";
@@ -17,7 +17,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pgmetrics.io/";
     description = "Collect and display information and stats from a running PostgreSQL server";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/phoronix-test-suite/default.nix b/pkgs/tools/misc/phoronix-test-suite/default.nix
index 520794c565695..8cb8d67c733a3 100644
--- a/pkgs/tools/misc/phoronix-test-suite/default.nix
+++ b/pkgs/tools/misc/phoronix-test-suite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, php, which, gnused, makeWrapper, gnumake, gcc, callPackage }:
+{ lib, stdenv, fetchurl, php, which, gnused, makeWrapper, gnumake, gcc, callPackage }:
 
 stdenv.mkDerivation rec {
   pname = "phoronix-test-suite";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     simple-execution = callPackage ./tests.nix { };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open-Source, Automated Benchmarking";
     homepage = "https://www.phoronix-test-suite.com/";
     maintainers = with maintainers; [ davidak ];
diff --git a/pkgs/tools/misc/phraseapp-client/default.nix b/pkgs/tools/misc/phraseapp-client/default.nix
index b99aadf9337f0..27c486f4bea36 100644
--- a/pkgs/tools/misc/phraseapp-client/default.nix
+++ b/pkgs/tools/misc/phraseapp-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "phraseapp-client";
@@ -18,7 +18,7 @@ buildGoPackage rec {
     ln -s $out/bin/phraseapp-client $out/bin/phraseapp
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://docs.phraseapp.com";
     description = "PhraseApp API v2 Command Line Client";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/pick/default.nix b/pkgs/tools/misc/pick/default.nix
index ceb2bace7db98..ac446e7f341e2 100644
--- a/pkgs/tools/misc/pick/default.nix
+++ b/pkgs/tools/misc/pick/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, ncurses, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, ncurses, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "pick";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Fuzzy text selection utility";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/picocom/default.nix b/pkgs/tools/misc/picocom/default.nix
index 1db8d00a90218..47126bac304d0 100644
--- a/pkgs/tools/misc/picocom/default.nix
+++ b/pkgs/tools/misc/picocom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , installShellFiles
 , lrzsz
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     installShellCompletion --bash bash_completion/picocom
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Minimal dumb-terminal emulation program";
     homepage = "https://github.com/npat-efault/picocom/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/pistol/default.nix b/pkgs/tools/misc/pistol/default.nix
index fa3a9d01f3124..874bbdbaf7018 100644
--- a/pkgs/tools/misc/pistol/default.nix
+++ b/pkgs/tools/misc/pistol/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , file
@@ -27,7 +27,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.Version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "General purpose file previewer designed for Ranger, Lf to make scope.sh redundant";
     homepage = "https://github.com/doronbehar/pistol";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/pkgdiff/default.nix b/pkgs/tools/misc/pkgdiff/default.nix
index 04d0c95b81a42..2f68e9505edb2 100644
--- a/pkgs/tools/misc/pkgdiff/default.nix
+++ b/pkgs/tools/misc/pkgdiff/default.nix
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/pkgdiff --prefix PATH : ${lib.makeBinPath [ wdiff ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for visualizing changes in Linux software packages";
     homepage = "https://lvc.github.io/pkgdiff/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/plantuml-server/default.nix b/pkgs/tools/misc/plantuml-server/default.nix
index 11db08dd97350..ad0ffa810cd78 100644
--- a/pkgs/tools/misc/plantuml-server/default.nix
+++ b/pkgs/tools/misc/plantuml-server/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, maven, jdk }:
+{ lib, stdenv, fetchFromGitHub, maven, jdk }:
 
 let
   version = "1.2020.14";
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     cp "target/plantuml.war" "$out/webapps/plantuml.war"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A web application to generate UML diagrams on-the-fly.";
     homepage = "https://plantuml.com/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/plantuml/default.nix b/pkgs/tools/misc/plantuml/default.nix
index 742e62230d289..e366673d77373 100644
--- a/pkgs/tools/misc/plantuml/default.nix
+++ b/pkgs/tools/misc/plantuml/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, jre, graphviz }:
+{ lib, stdenv, fetchurl, makeWrapper, jre, graphviz }:
 
 stdenv.mkDerivation rec {
   version = "1.2020.22";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     $out/bin/plantuml -help
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Draw UML diagrams using a simple and human readable text description";
     homepage = "http://plantuml.sourceforge.net/";
     # "plantuml -license" says GPLv3 or later
diff --git a/pkgs/tools/misc/plotinus/default.nix b/pkgs/tools/misc/plotinus/default.nix
index 6440ed533f60d..c7aff75dca51e 100644
--- a/pkgs/tools/misc/plotinus/default.nix
+++ b/pkgs/tools/misc/plotinus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gettext
 , libxml2
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     gtk3
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A searchable command palette in every modern GTK application";
     homepage = "https://github.com/p-e-w/plotinus";
     maintainers = with maintainers; [ samdroid-apps ];
diff --git a/pkgs/tools/misc/pod2mdoc/default.nix b/pkgs/tools/misc/pod2mdoc/default.nix
index 7571002512601..4e919e2848926 100644
--- a/pkgs/tools/misc/pod2mdoc/default.nix
+++ b/pkgs/tools/misc/pod2mdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "pod2mdoc";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     install -m 0444 pod2mdoc.1 $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mdocml.bsd.lv/";
     description = "converter from POD into mdoc";
     license = licenses.isc;
diff --git a/pkgs/tools/misc/powerline-go/default.nix b/pkgs/tools/misc/powerline-go/default.nix
index 16734e3dd3a8f..2b46e25c67e84 100644
--- a/pkgs/tools/misc/powerline-go/default.nix
+++ b/pkgs/tools/misc/powerline-go/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "powerline-go";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Powerline like prompt for Bash, ZSH and Fish";
     license = licenses.gpl3;
     platforms = platforms.unix;
diff --git a/pkgs/tools/misc/profile-sync-daemon/default.nix b/pkgs/tools/misc/profile-sync-daemon/default.nix
index b4497c4d7c877..0c8bb068ca6e2 100644
--- a/pkgs/tools/misc/profile-sync-daemon/default.nix
+++ b/pkgs/tools/misc/profile-sync-daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, util-linux, coreutils}:
+{ lib, stdenv, fetchurl, util-linux, coreutils}:
 
 stdenv.mkDerivation rec {
   version = "6.42";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Syncs browser profile dirs to RAM";
     longDescription = ''
       Profile-sync-daemon (psd) is a tiny pseudo-daemon designed to manage your
diff --git a/pkgs/tools/misc/progress/default.nix b/pkgs/tools/misc/progress/default.nix
index a43101f607d57..dbf844a4f9d87 100644
--- a/pkgs/tools/misc/progress/default.nix
+++ b/pkgs/tools/misc/progress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, ncurses, which }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, ncurses, which }:
 
 stdenv.mkDerivation rec {
   pname = "progress";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Xfennec/progress";
     description = "Tool that shows the progress of coreutils programs";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/pspg/default.nix b/pkgs/tools/misc/pspg/default.nix
index a2048132e078f..1ec6864fe6c8c 100644
--- a/pkgs/tools/misc/pspg/default.nix
+++ b/pkgs/tools/misc/pspg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gnugrep, ncurses, pkgconfig, readline, postgresql }:
+{ lib, stdenv, fetchFromGitHub, gnugrep, ncurses, pkgconfig, readline, postgresql }:
 
 stdenv.mkDerivation rec {
   pname = "pspg";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/okbob/pspg";
     description = "Postgres Pager";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/pubs/default.nix b/pkgs/tools/misc/pubs/default.nix
index 158b56e2a5d9c..24367189ff072 100644
--- a/pkgs/tools/misc/pubs/default.nix
+++ b/pkgs/tools/misc/pubs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "pubs";
@@ -25,7 +25,7 @@ python3Packages.buildPythonApplication rec {
     rm tests/test_git.py
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line bibliography manager";
     homepage = "https://github.com/pubs/pubs";
     license = licenses.lgpl3;
diff --git a/pkgs/tools/misc/rargs/default.nix b/pkgs/tools/misc/rargs/default.nix
index 6ebbeb39c6e07..c8eea974750c2 100644
--- a/pkgs/tools/misc/rargs/default.nix
+++ b/pkgs/tools/misc/rargs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname   = "rargs";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck=false;  # `rargs`'s test depends on the deprecated `assert_cli` crate, which in turn is not in Nixpkgs
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "xargs + awk with pattern matching support";
     homepage    = "https://github.com/lolabout/rargs";
     license     = with licenses; [ mit ];
diff --git a/pkgs/tools/misc/rcm/default.nix b/pkgs/tools/misc/rcm/default.nix
index 570b55c9acf34..dc166f3d0b4d0 100644
--- a/pkgs/tools/misc/rcm/default.nix
+++ b/pkgs/tools/misc/rcm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "rcm";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Management Suite for Dotfiles";
     homepage = "https://github.com/thoughtbot/rcm";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/recoverjpeg/default.nix b/pkgs/tools/misc/recoverjpeg/default.nix
index bf75213acdf62..c71bd42c94c08 100644
--- a/pkgs/tools/misc/recoverjpeg/default.nix
+++ b/pkgs/tools/misc/recoverjpeg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, python2, exif, imagemagick }:
+{ lib, stdenv, fetchurl, makeWrapper, python2, exif, imagemagick }:
 
 stdenv.mkDerivation rec {
   pname = "recoverjpeg";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ exif imagemagick ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://rfc1149.net/devel/recoverjpeg.html";
     description = "Recover lost JPEGs and MOV files on a bogus memory card or disk";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/rename/default.nix b/pkgs/tools/misc/rename/default.nix
index e32b016016bdd..63ceca8d93491 100644
--- a/pkgs/tools/misc/rename/default.nix
+++ b/pkgs/tools/misc/rename/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, perlPackages }:
 
 perlPackages.buildPerlPackage {
   pname = "rename";
@@ -10,7 +10,7 @@ perlPackages.buildPerlPackage {
     rev = "d46f1d0ced25dc5849acb5d5974a3e2e9d97d536";
     sha256 = "0qahs1cqfaci2hdf1xncrz4k0z5skkfr43apnm3kybs7za33apzw";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rename files according to a Perl rewrite expression";
     homepage = "https://github.com/pstray/rename";
     maintainers = with maintainers; [ mkg ];
diff --git a/pkgs/tools/misc/reredirect/default.nix b/pkgs/tools/misc/reredirect/default.nix
index 15045d4bd8ad1..eb1c90324e01b 100644
--- a/pkgs/tools/misc/reredirect/default.nix
+++ b/pkgs/tools/misc/reredirect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "reredirect";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       --replace "reredirect" "${placeholder "out"}/bin/reredirect"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to dynamicly redirect outputs of a running process";
     homepage = "https://github.com/jerome-pouiller/reredirect";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/riemann-c-client/default.nix b/pkgs/tools/misc/riemann-c-client/default.nix
index 48e0f7757aebe..ca8fe489c16b5 100644
--- a/pkgs/tools/misc/riemann-c-client/default.nix
+++ b/pkgs/tools/misc/riemann-c-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, file , protobufc }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, file , protobufc }:
 
 stdenv.mkDerivation rec {
   name = "riemann-c-client-1.10.4";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     make lib/riemann/proto/riemann.pb-c.h
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/algernon/riemann-c-client";
     description = "A C client library for the Riemann monitoring system";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/rkflashtool/default.nix b/pkgs/tools/misc/rkflashtool/default.nix
index 94d6ca95748f2..b96d9be8a4ddc 100644
--- a/pkgs/tools/misc/rkflashtool/default.nix
+++ b/pkgs/tools/misc/rkflashtool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libusb1 }:
+{ lib, stdenv, fetchurl, libusb1 }:
 
 stdenv.mkDerivation rec {
   name = "rkflashtool-5.1";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     cp rkunpack rkcrc rkflashtool rkparameters rkparametersblock rkunsign rkmisc $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/rkflashtool/";
     description = "Tools for flashing Rockchip devices";
     platforms = platforms.linux;
diff --git a/pkgs/tools/misc/rockbox-utility/default.nix b/pkgs/tools/misc/rockbox-utility/default.nix
index 6be32e214784d..1a13a1d2ed9fe 100644
--- a/pkgs/tools/misc/rockbox-utility/default.nix
+++ b/pkgs/tools/misc/rockbox-utility/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, cryptopp
+{ lib, stdenv, fetchurl, pkgconfig, cryptopp
 , libusb1, qtbase, qttools, makeWrapper
 , qmake, withEspeak ? false, espeak ? null
 , qt5 }:
@@ -47,7 +47,7 @@ stdenv.mkDerivation  rec {
   # may clobber the files read by the parallel `make build/rcc/qrc_rbutilqt-lang.cpp`.
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source firmware for mp3 players";
     homepage = "https://www.rockbox.org";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/roundup/default.nix b/pkgs/tools/misc/roundup/default.nix
index 8d0c62889f998..fd2272e6cd560 100644
--- a/pkgs/tools/misc/roundup/default.nix
+++ b/pkgs/tools/misc/roundup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ronn, shocco }:
+{ lib, stdenv, fetchFromGitHub, ronn, shocco }:
 
 stdenv.mkDerivation rec {
   pname = "roundup";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A unit testing tool for running test plans which are written in any POSIX shell";
     homepage = "http://bmizerany.github.io/roundup/";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/routino/default.nix b/pkgs/tools/misc/routino/default.nix
index 8d9487344608b..d75e51d4ed83c 100644
--- a/pkgs/tools/misc/routino/default.nix
+++ b/pkgs/tools/misc/routino/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, perl, zlib, bzip2 }:
+{ lib, stdenv, fetchurl, fetchpatch, perl, zlib, bzip2 }:
 
 stdenv.mkDerivation rec {
   pname = "routino";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.routino.org/";
     description = "OpenStreetMap Routing Software";
     license = licenses.agpl3;
diff --git a/pkgs/tools/misc/rpcsvc-proto/default.nix b/pkgs/tools/misc/rpcsvc-proto/default.nix
index 925dfde13a36b..400a63f7dfe37 100644
--- a/pkgs/tools/misc/rpcsvc-proto/default.nix
+++ b/pkgs/tools/misc/rpcsvc-proto/default.nix
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       --replace '$(top_builddir)/rpcgen/rpcgen' '${buildPackages.rpcsvc-proto}/bin/rpcgen'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/thkukuk/rpcsvc-proto";
     description = "This package contains rpcsvc proto.x files from glibc, which are missing in libtirpc";
     longDescription = ''
diff --git a/pkgs/tools/misc/rpm-ostree/default.nix b/pkgs/tools/misc/rpm-ostree/default.nix
index abca71febb939..63c0f90079b04 100644
--- a/pkgs/tools/misc/rpm-ostree/default.nix
+++ b/pkgs/tools/misc/rpm-ostree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , ostree
 , rpm
@@ -114,7 +114,7 @@ stdenv.mkDerivation rec {
     env NOCONFIGURE=1 ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A hybrid image/package system. It uses OSTree as an image format, and uses RPM as a component model";
     homepage = "https://coreos.github.io/rpm-ostree/";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/misc/rrdtool/default.nix b/pkgs/tools/misc/rrdtool/default.nix
index 10ff6db63f15b..88db9409316bb 100644
--- a/pkgs/tools/misc/rrdtool/default.nix
+++ b/pkgs/tools/misc/rrdtool/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, gettext, perl, pkgconfig, libxml2, pango, cairo, groff
+{ fetchurl, lib, stdenv, gettext, perl, pkgconfig, libxml2, pango, cairo, groff
 , tcl-8_5, darwin }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     mv $out/lib/perl/5* $out/${perl.libPrefix}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://oss.oetiker.ch/rrdtool/";
     description = "High performance logging in Round Robin Databases";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/rw/default.nix b/pkgs/tools/misc/rw/default.nix
index b36eff12a2fc9..408723f058dc6 100644
--- a/pkgs/tools/misc/rw/default.nix
+++ b/pkgs/tools/misc/rw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "rw";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sortix.org/rw";
     description = "Block device and byte copying program similar to dd";
     longDescription = ''
diff --git a/pkgs/tools/misc/sam-ba/default.nix b/pkgs/tools/misc/sam-ba/default.nix
index 67c751a57791c..5d27af2050f62 100644
--- a/pkgs/tools/misc/sam-ba/default.nix
+++ b/pkgs/tools/misc/sam-ba/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, libX11, libXScrnSaver, libXext, libXft, libXrender
+{ lib, stdenv, fetchzip, libX11, libXScrnSaver, libXext, libXft, libXrender
 , freetype, zlib, fontconfig
 }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
   # Do our own thing
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Programming tools for Atmel SAM3/7/9 ARM-based microcontrollers";
     longDescription = ''
       Atmel SAM-BA software provides an open set of tools for programming the
diff --git a/pkgs/tools/misc/scanmem/default.nix b/pkgs/tools/misc/scanmem/default.nix
index 58350f7a638da..bd6b8dbb1d147 100644
--- a/pkgs/tools/misc/scanmem/default.nix
+++ b/pkgs/tools/misc/scanmem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, autoconf, automake, intltool, libtool, fetchFromGitHub, readline }:
+{ lib, stdenv, autoconf, automake, intltool, libtool, fetchFromGitHub, readline }:
 
 stdenv.mkDerivation rec {
   version = "0.17";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   preConfigure = ''
     ./autogen.sh
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/scanmem/scanmem";
     description = "Memory scanner for finding and poking addresses in executing processes";
     maintainers = [ maintainers.chattered ];
diff --git a/pkgs/tools/misc/screen/default.nix b/pkgs/tools/misc/screen/default.nix
index 9bc219289c449..aef209022ff01 100644
--- a/pkgs/tools/misc/screen/default.nix
+++ b/pkgs/tools/misc/screen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, ncurses, utmp, pam ? null }:
+{ lib, stdenv, fetchurl, fetchpatch, ncurses, utmp, pam ? null }:
 
 stdenv.mkDerivation rec {
   pname = "screen";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/screen/";
     description = "A window manager that multiplexes a physical terminal";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/sd-mux-ctrl/default.nix b/pkgs/tools/misc/sd-mux-ctrl/default.nix
index b87a83fcdf94d..487307d3224eb 100644
--- a/pkgs/tools/misc/sd-mux-ctrl/default.nix
+++ b/pkgs/tools/misc/sd-mux-ctrl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, cmake, pkgconfig, libftdi1, popt}:
+{ lib, stdenv, fetchgit, cmake, pkgconfig, libftdi1, popt}:
 
 stdenv.mkDerivation rec {
   pname = "sd-mux-ctrl-unstable";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -D -m 644 ../doc/man/sd-mux-ctrl.1 $out/share/man/man1/sd-mux-ctrl.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for controlling multiple sd-mux devices";
     homepage = "https://wiki.tizen.org/SD_MUX";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/sdl-jstest/default.nix b/pkgs/tools/misc/sdl-jstest/default.nix
index 13b143559e98c..c299a140b0790 100644
--- a/pkgs/tools/misc/sdl-jstest/default.nix
+++ b/pkgs/tools/misc/sdl-jstest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, cmake, pkg-config, SDL, SDL2, ncurses, docbook_xsl, git }:
+{ lib, stdenv, fetchgit, cmake, pkg-config, SDL, SDL2, ncurses, docbook_xsl, git }:
 
 stdenv.mkDerivation {
   pname = "sdl-jstest";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   buildInputs = [ SDL SDL2 ncurses ];
   nativeBuildInputs = [ cmake pkg-config docbook_xsl git ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Grumbel/sdl-jstest";
     description = "Simple SDL joystick test application for the console";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/shadowenv/default.nix b/pkgs/tools/misc/shadowenv/default.nix
index 9becd52273e6b..b3ab2002ca64f 100644
--- a/pkgs/tools/misc/shadowenv/default.nix
+++ b/pkgs/tools/misc/shadowenv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, installShellFiles, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, installShellFiles, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "shadowenv";
@@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion --zsh sh/completions/_shadowenv
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://shopify.github.io/shadowenv/";
     description = "reversible directory-local environment variable manipulations";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/shelldap/default.nix b/pkgs/tools/misc/shelldap/default.nix
index bfa8ea16ed365..41e4207d6c98a 100644
--- a/pkgs/tools/misc/shelldap/default.nix
+++ b/pkgs/tools/misc/shelldap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages }:
+{ lib, stdenv, fetchurl, perlPackages }:
 perlPackages.buildPerlPackage rec {
   pname = "shelldap";
   version = "1.4.0";
@@ -16,7 +16,7 @@ perlPackages.buildPerlPackage rec {
     runHook preInstall
   '';
   outputs = [ "out" ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://bitbucket.org/mahlon/shelldap/";
     description = "A handy shell-like interface for browsing LDAP servers and editing their content";
     license = with licenses; [ bsd3 ];
diff --git a/pkgs/tools/misc/shunit2/default.nix b/pkgs/tools/misc/shunit2/default.nix
index e08a5b576d3fa..1895acacac270 100644
--- a/pkgs/tools/misc/shunit2/default.nix
+++ b/pkgs/tools/misc/shunit2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "shunit2";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     $out/bin/shunit2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kward/shunit2";
     description = "A xUnit based unit test framework for Bourne based shell scripts";
     maintainers = with maintainers; [ cdepillabout utdemir ];
diff --git a/pkgs/tools/misc/skim/default.nix b/pkgs/tools/misc/skim/default.nix
index 996e6b4490e10..3a49876a8600a 100644
--- a/pkgs/tools/misc/skim/default.nix
+++ b/pkgs/tools/misc/skim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchCrate, rustPlatform }:
+{ lib, stdenv, fetchCrate, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "skim";
@@ -32,7 +32,7 @@ rustPlatform.buildRustPackage rec {
     chmod +x $out/bin/sk-share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line fuzzy finder written in Rust";
     homepage = "https://github.com/lotabout/skim";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/sl/default.nix b/pkgs/tools/misc/sl/default.nix
index 902617665d889..dc55a8e783b94 100644
--- a/pkgs/tools/misc/sl/default.nix
+++ b/pkgs/tools/misc/sl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "sl";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Steam Locomotive runs across your terminal when you type 'sl'";
     homepage = "http://www.tkl.iis.u-tokyo.ac.jp/~toyoda/index_e.html";
     license = rec {
diff --git a/pkgs/tools/misc/slop/default.nix b/pkgs/tools/misc/slop/default.nix
index 36f40dca6cb14..32d55a3733ce4 100644
--- a/pkgs/tools/misc/slop/default.nix
+++ b/pkgs/tools/misc/slop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig
 , glew, glm, libGLU, libGL, libX11, libXext, libXrender, icu
 , cppcheck
 }:
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Queries a selection from the user and prints to stdout";
     platforms = stdenv.lib.platforms.linux;
diff --git a/pkgs/tools/misc/slurp/default.nix b/pkgs/tools/misc/slurp/default.nix
index 32263bad4a1d4..190f637936ded 100644
--- a/pkgs/tools/misc/slurp/default.nix
+++ b/pkgs/tools/misc/slurp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkg-config
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkg-config
 , cairo, libxkbcommon, wayland, wayland-protocols
 , buildDocs ? true, scdoc
 }:
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   mesonFlags = stdenv.lib.optional buildDocs "-Dman-pages=enabled";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Select a region in a Wayland compositor";
     homepage = "https://github.com/emersion/slurp";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/smc/default.nix b/pkgs/tools/misc/smc/default.nix
index 87bda5d78b432..5b0342621e803 100644
--- a/pkgs/tools/misc/smc/default.nix
+++ b/pkgs/tools/misc/smc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, runtimeShell }:
+{ lib, stdenv, fetchurl, jre, runtimeShell }:
 
 stdenv.mkDerivation {
   name = "smc-6.6.3";
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
     chmod a+x "$out/bin/smc"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate state machine code from text input (state diagram)";
     longDescription = ''
       SMC (State Machine Compiler) takes a text input file describing states,
diff --git a/pkgs/tools/misc/smenu/default.nix b/pkgs/tools/misc/smenu/default.nix
index 362c4f6c9145e..5da7f19b06091 100644
--- a/pkgs/tools/misc/smenu/default.nix
+++ b/pkgs/tools/misc/smenu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   version = "0.9.16";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage        = "https://github.com/p-gen/smenu";
     description     = "Terminal selection utility";
     longDescription = ''
diff --git a/pkgs/tools/misc/snapper/default.nix b/pkgs/tools/misc/snapper/default.nix
index 3843f16f6a864..c249419d589c9 100644
--- a/pkgs/tools/misc/snapper/default.nix
+++ b/pkgs/tools/misc/snapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook, pkgconfig, docbook_xsl, libxslt, docbook_xml_dtd_45
 , acl, attr, boost, btrfs-progs, dbus, diffutils, e2fsprogs, libxml2
 , lvm2, pam, python, util-linux, fetchpatch, json_c, nixosTests
@@ -66,7 +66,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for Linux filesystem snapshot management";
     homepage = "http://snapper.io";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/snore/default.nix b/pkgs/tools/misc/snore/default.nix
index f6f177811b025..5efeafcd26f61 100644
--- a/pkgs/tools/misc/snore/default.nix
+++ b/pkgs/tools/misc/snore/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   version = "0.1";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "sleep with feedback";
     homepage = "https://github.com/clamiax/snore";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/somafm-cli/default.nix b/pkgs/tools/misc/somafm-cli/default.nix
index 3ce3f62a9e2b4..b0aebd6224ed4 100644
--- a/pkgs/tools/misc/somafm-cli/default.nix
+++ b/pkgs/tools/misc/somafm-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , makeWrapper
 , curl
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/somafm --prefix PATH ":" "${stdenv.lib.makeBinPath [ curl jq mpv ]}";
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Listen to SomaFM in your terminal via pure bash";
     homepage = "https://github.com/rockymadden/somafm-cli";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/starship/default.nix b/pkgs/tools/misc/starship/default.nix
index 4062699bc231a..50d99db5322ca 100644
--- a/pkgs/tools/misc/starship/default.nix
+++ b/pkgs/tools/misc/starship/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , pkg-config
@@ -44,7 +44,7 @@ rustPlatform.buildRustPackage rec {
     "--skip=shows_pinned_in_project_below_root_with_global_json"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A minimal, blazing fast, and extremely customizable prompt for any shell";
     homepage = "https://starship.rs";
     license = licenses.isc;
diff --git a/pkgs/tools/misc/staruml/default.nix b/pkgs/tools/misc/staruml/default.nix
index d0266cf30e287..b6a78f85a35d3 100644
--- a/pkgs/tools/misc/staruml/default.nix
+++ b/pkgs/tools/misc/staruml/default.nix
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A sophisticated software modeler";
     homepage = "https://staruml.io/";
     license = licenses.unfree;
diff --git a/pkgs/tools/misc/statserial/default.nix b/pkgs/tools/misc/statserial/default.nix
index 448323f434618..1ca0771914b27 100644
--- a/pkgs/tools/misc/statserial/default.nix
+++ b/pkgs/tools/misc/statserial/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, glibc }:
+{ lib, stdenv, fetchurl, ncurses, glibc }:
 
 stdenv.mkDerivation rec {
   pname = "statserial";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
   cp statserial.1 $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sites.google.com/site/tranter/software";
     description = "Display serial port modem status lines";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/subberthehut/default.nix b/pkgs/tools/misc/subberthehut/default.nix
index e4fa57e30ac5f..86b2941eed1bd 100644
--- a/pkgs/tools/misc/subberthehut/default.nix
+++ b/pkgs/tools/misc/subberthehut/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, xmlrpc_c, glib, zlib }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, xmlrpc_c, glib, zlib }:
 stdenv.mkDerivation rec {
   pname = "subberthehut";
   version = "20";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -Dm644 bash_completion $out/share/bash-completion/completions/subberthehut
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mus65/subberthehut";
     description = "An OpenSubtitles.org downloader";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/svtplay-dl/default.nix b/pkgs/tools/misc/svtplay-dl/default.nix
index d06bb8b134db5..ae8679c03ad58 100644
--- a/pkgs/tools/misc/svtplay-dl/default.nix
+++ b/pkgs/tools/misc/svtplay-dl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, python3Packages, perl, zip
+{ lib, stdenv, fetchFromGitHub, makeWrapper, python3Packages, perl, zip
 , gitMinimal, ffmpeg }:
 
 let
@@ -42,7 +42,7 @@ in stdenv.mkDerivation rec {
     sh scripts/run-tests.sh -2
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/spaam/svtplay-dl";
     description = "Command-line tool to download videos from svtplay.se and other sites";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/swaglyrics/default.nix b/pkgs/tools/misc/swaglyrics/default.nix
index 048dac85fdb23..6831a05a3edce 100644
--- a/pkgs/tools/misc/swaglyrics/default.nix
+++ b/pkgs/tools/misc/swaglyrics/default.nix
@@ -35,7 +35,7 @@ python3.pkgs.buildPythonApplication rec {
     [ blinker swspotify pytestCheckHook flask mock flask_testing ]
     ++ [ ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lyrics fetcher for currently playing Spotify song";
     homepage = "https://github.com/SwagLyrics/SwagLyrics-For-Spotify";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/sweep-visualizer/default.nix b/pkgs/tools/misc/sweep-visualizer/default.nix
index fdd3c5f628d09..12168bd07f068 100644
--- a/pkgs/tools/misc/sweep-visualizer/default.nix
+++ b/pkgs/tools/misc/sweep-visualizer/default.nix
@@ -49,7 +49,7 @@
       wrapProgram "$out/bin/sweep_visualizer" --prefix LD_LIBRARY_PATH : ${runtimeLibs}
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://support.scanse.io/hc/en-us/articles/115006008948-Visualizer-Overview";
       description = "A minimal desktop application for interfacing with the Sweep device";
       license = licenses.unfree;
diff --git a/pkgs/tools/misc/systrayhelper/default.nix b/pkgs/tools/misc/systrayhelper/default.nix
index aae69d8ad3941..d7d699d2ba4a7 100644
--- a/pkgs/tools/misc/systrayhelper/default.nix
+++ b/pkgs/tools/misc/systrayhelper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, libappindicator-gtk3, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, pkgconfig, libappindicator-gtk3, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "systrayhelper";
@@ -27,7 +27,7 @@ buildGoPackage rec {
   nativeBuildInputs = [ pkgconfig libappindicator-gtk3 ];
   buildInputs = [ libappindicator-gtk3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A systray utility written in go, using json over stdio for control and events";
     homepage    = "https://github.com/ssbc/systrayhelper";
     maintainers = with maintainers; [ cryptix ];
diff --git a/pkgs/tools/misc/t1utils/default.nix b/pkgs/tools/misc/t1utils/default.nix
index fd4ca5f92d539..690fbe8abcb3a 100644
--- a/pkgs/tools/misc/t1utils/default.nix
+++ b/pkgs/tools/misc/t1utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "t1utils-1.41";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "09rlc837dr69hyiiicha3il37mchsvz84qw8hnvb60lrh9zdsppw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of simple Type 1 font manipulation programs";
     longDescription = ''
       t1utils is a collection of simple type-1 font manipulation programs.
diff --git a/pkgs/tools/misc/tab-rs/default.nix b/pkgs/tools/misc/tab-rs/default.nix
index e3bd9792c45cd..b3d2e1a77a711 100644
--- a/pkgs/tools/misc/tab-rs/default.nix
+++ b/pkgs/tools/misc/tab-rs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, IOKit }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, IOKit }:
 
 rustPlatform.buildRustPackage rec {
   pname = "tab-rs";
@@ -18,7 +18,7 @@ rustPlatform.buildRustPackage rec {
   # many tests are failing
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Intuitive, config-driven terminal multiplexer designed for software & systems engineers";
     homepage = "https://github.com/austinjones/tab-rs";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/tealdeer/default.nix b/pkgs/tools/misc/tealdeer/default.nix
index 4f0677846eaf3..358c322956381 100644
--- a/pkgs/tools/misc/tealdeer/default.nix
+++ b/pkgs/tools/misc/tealdeer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , pkg-config
@@ -35,7 +35,7 @@ rustPlatform.buildRustPackage rec {
   # and i can't disable just this one
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A very fast implementation of tldr in Rust";
     homepage = "https://github.com/dbrgn/tealdeer";
     maintainers = with maintainers; [ davidak ];
diff --git a/pkgs/tools/misc/teleconsole/default.nix b/pkgs/tools/misc/teleconsole/default.nix
index 47a792a3f92b8..63277c90d47a5 100644
--- a/pkgs/tools/misc/teleconsole/default.nix
+++ b/pkgs/tools/misc/teleconsole/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "teleconsole";
@@ -27,7 +27,7 @@ buildGoPackage rec {
   CGO_ENABLED = 1;
   buildFlags = [ "-ldflags" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.teleconsole.com/";
     description = "Share your terminal session with people you trust";
     license = licenses.asl20;
diff --git a/pkgs/tools/misc/tensorman/default.nix b/pkgs/tools/misc/tensorman/default.nix
index 85091a41b126c..835409be65767 100644
--- a/pkgs/tools/misc/tensorman/default.nix
+++ b/pkgs/tools/misc/tensorman/default.nix
@@ -1,4 +1,4 @@
-{ pkgconfig, stdenv, rustPlatform, rustc, cargo, docker, openssl, fetchFromGitHub }:
+{ pkgconfig, lib, stdenv, rustPlatform, rustc, cargo, docker, openssl, fetchFromGitHub }:
 
 rustPlatform.buildRustPackage rec {
   pname = "tensorman";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
   buildInputs = [ openssl ];
   cargoSha256 = "0vckay4jhg02xg68mvh7ys0yjj0p30m6wsjriqc8k24wjsrhiw9k";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility for easy management of Tensorflow containers";
     homepage = "https://github.com/pop-os/tensorman/";
     license = stdenv.lib.licenses.gpl3;
diff --git a/pkgs/tools/misc/texi2mdoc/default.nix b/pkgs/tools/misc/texi2mdoc/default.nix
index 6c090c0b4b363..2b73c4f34dbbc 100644
--- a/pkgs/tools/misc/texi2mdoc/default.nix
+++ b/pkgs/tools/misc/texi2mdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "texi2mdoc";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mdocml.bsd.lv/";
     description = "converter from Texinfo into mdoc";
     license = licenses.isc;
diff --git a/pkgs/tools/misc/thefuck/default.nix b/pkgs/tools/misc/thefuck/default.nix
index d923a3f449188..bf87505ab1358 100644
--- a/pkgs/tools/misc/thefuck/default.nix
+++ b/pkgs/tools/misc/thefuck/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildPythonApplication
+{ lib, stdenv, fetchFromGitHub, buildPythonApplication
 , colorama, decorator, psutil, pyte, six
 , pytest, pytest-mock
 }:
@@ -28,7 +28,7 @@ buildPythonApplication rec {
 
   doCheck = false; # The above is only enough for tests to pass outside the sandbox.
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/nvbn/thefuck";
     description = "Magnificent app which corrects your previous console command";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/thin-provisioning-tools/default.nix b/pkgs/tools/misc/thin-provisioning-tools/default.nix
index 3eccb48836181..794e0d4e25781 100644
--- a/pkgs/tools/misc/thin-provisioning-tools/default.nix
+++ b/pkgs/tools/misc/thin-provisioning-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, expat, libaio, boost, binutils }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, expat, libaio, boost, binutils }:
 
 stdenv.mkDerivation rec {
   pname = "thin-provisioning-tools";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jthornber/thin-provisioning-tools/";
     description = "A suite of tools for manipulating the metadata of the dm-thin device-mapper target";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/timidity/default.nix b/pkgs/tools/misc/timidity/default.nix
index f33520aee0a8c..c6c4886a3b4ad 100644
--- a/pkgs/tools/misc/timidity/default.nix
+++ b/pkgs/tools/misc/timidity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, alsaLib, libjack2, ncurses, pkgconfig }:
+{ lib, stdenv, fetchurl, alsaLib, libjack2, ncurses, pkgconfig }:
 
 stdenv.mkDerivation {
   name = "timidity-2.15.0";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
     tar --strip-components=1 -xf $instruments -C $out/share/timidity/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/timidity/";
     license = licenses.gpl2;
     description = "A software MIDI renderer";
diff --git a/pkgs/tools/misc/tio/default.nix b/pkgs/tools/misc/tio/default.nix
index bab0098ecaa48..a25b821c7e3dc 100644
--- a/pkgs/tools/misc/tio/default.nix
+++ b/pkgs/tools/misc/tio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, autoreconfHook }:
+{ lib, stdenv, fetchzip, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "tio";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Serial console TTY";
     homepage = "https://tio.github.io/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/tldr/default.nix b/pkgs/tools/misc/tldr/default.nix
index 66d763fd304ed..e4f43b5007cf7 100644
--- a/pkgs/tools/misc/tldr/default.nix
+++ b/pkgs/tools/misc/tldr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, curl, libzip, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, curl, libzip, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "tldr";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simplified and community-driven man pages";
     longDescription = ''
       tldr pages gives common use cases for commands, so you don't need to hunt
diff --git a/pkgs/tools/misc/tmate/default.nix b/pkgs/tools/misc/tmate/default.nix
index e1bdb6b811fde..5f1b8d236460e 100644
--- a/pkgs/tools/misc/tmate/default.nix
+++ b/pkgs/tools/misc/tmate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, cmake, libtool, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, cmake, libtool, pkgconfig
 , zlib, openssl, libevent, ncurses, ruby, msgpack, libssh }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libtool zlib openssl libevent ncurses ruby msgpack libssh ];
   nativeBuildInputs = [ autoreconfHook cmake pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://tmate.io/";
     description = "Instant Terminal Sharing";
     license     = licenses.mit;
diff --git a/pkgs/tools/misc/tmpwatch/default.nix b/pkgs/tools/misc/tmpwatch/default.nix
index ac20cab2842ed..1ef486fa8556f 100644
--- a/pkgs/tools/misc/tmpwatch/default.nix
+++ b/pkgs/tools/misc/tmpwatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, psmisc }:
+{ lib, stdenv, fetchurl, psmisc }:
 
 stdenv.mkDerivation {
   name = "tmpwatch-2.11";
@@ -10,7 +10,7 @@ stdenv.mkDerivation {
 
   configureFlags = [ "--with-fuser=${psmisc}/bin/fuser" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fedorahosted.org/tmpwatch/";
     description = "Recursively searches through specified directories and removes files which have not been accessed in a specified period of time";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/tmux-xpanes/default.nix b/pkgs/tools/misc/tmux-xpanes/default.nix
index 6e41eba735904..37a60e714df01 100644
--- a/pkgs/tools/misc/tmux-xpanes/default.nix
+++ b/pkgs/tools/misc/tmux-xpanes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, perl }:
+{ lib, stdenv, fetchFromGitHub, openssl, perl }:
 
 stdenv.mkDerivation rec {
   pname = "tmux-xpanes";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     install -m 644 man/*.1 $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "tmux-based terminal divider";
     homepage = "https://github.com/greymd/tmux-xpanes";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/tmuxp/default.nix b/pkgs/tools/misc/tmuxp/default.nix
index cc910c8b41c1e..839ee5b208218 100644
--- a/pkgs/tools/misc/tmuxp/default.nix
+++ b/pkgs/tools/misc/tmuxp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python }:
+{ lib, stdenv, python }:
 
 with python.pkgs;
 
@@ -27,7 +27,7 @@ buildPythonApplication rec {
     click colorama kaptan libtmux
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Manage tmux workspaces from JSON and YAML";
     homepage = "https://tmuxp.git-pull.com/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/misc/togglesg-download/default.nix b/pkgs/tools/misc/togglesg-download/default.nix
index 4afa1781ac0e3..c4d8b20ffdd67 100644
--- a/pkgs/tools/misc/togglesg-download/default.nix
+++ b/pkgs/tools/misc/togglesg-download/default.nix
@@ -31,7 +31,7 @@ pythonPackages.buildPythonApplication {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/0x776b7364/toggle.sg-download";
     description = "Command-line tool to download videos from toggle.sg written in Python";
     longDescription = ''
diff --git a/pkgs/tools/misc/toilet/default.nix b/pkgs/tools/misc/toilet/default.nix
index c598b37897c78..3dba479f03902 100644
--- a/pkgs/tools/misc/toilet/default.nix
+++ b/pkgs/tools/misc/toilet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libcaca }:
+{ lib, stdenv, fetchurl, pkgconfig, libcaca }:
 
 stdenv.mkDerivation rec {
   pname = "toilet";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libcaca ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display large colourful characters in text mode";
     homepage = "http://caca.zoy.org/wiki/toilet";
     license = licenses.wtfpl;
diff --git a/pkgs/tools/misc/toybox/default.nix b/pkgs/tools/misc/toybox/default.nix
index 5ae211bd23761..25db7e668678d 100644
--- a/pkgs/tools/misc/toybox/default.nix
+++ b/pkgs/tools/misc/toybox/default.nix
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-Wno-error";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight implementation of some Unix command line utilities";
     homepage = "https://landley.net/toybox/";
     license = licenses.bsd0;
diff --git a/pkgs/tools/misc/trash-cli/default.nix b/pkgs/tools/misc/trash-cli/default.nix
index 767e3ea946266..1da49a153b821 100644
--- a/pkgs/tools/misc/trash-cli/default.nix
+++ b/pkgs/tools/misc/trash-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "trash-cli";
@@ -19,7 +19,7 @@ python3Packages.buildPythonApplication rec {
   ];
   checkPhase = "nosetests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/andreafrancia/trash-cli";
     description = "Command line tool for the desktop trash can";
     maintainers = [ maintainers.rycee ];
diff --git a/pkgs/tools/misc/ttfautohint/default.nix b/pkgs/tools/misc/ttfautohint/default.nix
index 502b829afcecc..1e73f716a7ab1 100644
--- a/pkgs/tools/misc/ttfautohint/default.nix
+++ b/pkgs/tools/misc/ttfautohint/default.nix
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An automatic hinter for TrueType fonts";
     longDescription = ''
       A library and two programs which take a TrueType font as the
diff --git a/pkgs/tools/misc/ttwatch/default.nix b/pkgs/tools/misc/ttwatch/default.nix
index 8788608876ea1..acebd4f92e8eb 100644
--- a/pkgs/tools/misc/ttwatch/default.nix
+++ b/pkgs/tools/misc/ttwatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, perl, pkgconfig
 , openssl, curl, libusb1, protobufc
 , enableUnsafe ? false }:
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/ttbin2mysports
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ryanbinns/ttwatch";
     description = "Linux TomTom GPS Watch Utilities";
     maintainers = with maintainers; [ dotlambda ];
diff --git a/pkgs/tools/misc/tty-clock/default.nix b/pkgs/tools/misc/tty-clock/default.nix
index f6a312f046087..bc253a1d23b85 100644
--- a/pkgs/tools/misc/tty-clock/default.nix
+++ b/pkgs/tools/misc/tty-clock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, ncurses, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "tty-clock";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/xorg62/tty-clock";
     license = licenses.free;
     description = "Digital clock in ncurses";
diff --git a/pkgs/tools/misc/ttygif/default.nix b/pkgs/tools/misc/ttygif/default.nix
index dd74f5effed67..045448f030206 100644
--- a/pkgs/tools/misc/ttygif/default.nix
+++ b/pkgs/tools/misc/ttygif/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, imagemagick, xorg }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, imagemagick, xorg }:
 
 stdenv.mkDerivation rec {
   pname = "ttygif";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ imagemagick xorg.xwd ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/icholy/ttygif";
     description = "Convert terminal recordings to animated gifs";
     platforms = platforms.unix;
diff --git a/pkgs/tools/misc/ttylog/default.nix b/pkgs/tools/misc/ttylog/default.nix
index 55785c7a211cd..248630795cb08 100644
--- a/pkgs/tools/misc/ttylog/default.nix
+++ b/pkgs/tools/misc/ttylog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "ttylog";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://ttylog.sourceforge.net";
     description = "Simple serial port logger";
     longDescription = ''
diff --git a/pkgs/tools/misc/ttyplot/default.nix b/pkgs/tools/misc/ttyplot/default.nix
index afa4cb3e15556..7becc090a83bf 100644
--- a/pkgs/tools/misc/ttyplot/default.nix
+++ b/pkgs/tools/misc/ttyplot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses }:
+{ lib, stdenv, fetchFromGitHub, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "ttyplot";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp ttyplot $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple general purpose plotting utility for tty with data input from stdin";
     homepage = "https://github.com/tenox7/ttyplot";
     license = licenses.unlicense;
diff --git a/pkgs/tools/misc/txr/default.nix b/pkgs/tools/misc/txr/default.nix
index ce928f0a37810..9c200f1030ea4 100644
--- a/pkgs/tools/misc/txr/default.nix
+++ b/pkgs/tools/misc/txr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bison, flex, libffi }:
+{ lib, stdenv, fetchurl, bison, flex, libffi }:
 
 stdenv.mkDerivation rec {
   pname = "txr";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     EOF
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Programming language for convenient data munging";
     license = licenses.bsd2;
     homepage = "http://nongnu.org/txr";
diff --git a/pkgs/tools/misc/txtw/default.nix b/pkgs/tools/misc/txtw/default.nix
index 1cf80007901ee..e8a14b57634a7 100644
--- a/pkgs/tools/misc/txtw/default.nix
+++ b/pkgs/tools/misc/txtw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cairo }:
+{ lib, stdenv, fetchFromGitHub, cairo }:
 
 stdenv.mkDerivation rec {
   version = "0.4";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   prePatch = ''sed -i "s@/usr/local@$out@" Makefile'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Compute text widths";
     homepage = "https://github.com/baskerville/txtw";
     maintainers = with maintainers; [ lihop ];
diff --git a/pkgs/tools/misc/tydra/default.nix b/pkgs/tools/misc/tydra/default.nix
index c19f808397afc..6714ee489f5c3 100644
--- a/pkgs/tools/misc/tydra/default.nix
+++ b/pkgs/tools/misc/tydra/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, installShellFiles }:
 
 rustPlatform.buildRustPackage rec {
   pname = "tydra";
@@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion tydra.{bash,fish} _tydra
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Shortcut menu-based task runner, inspired by Emacs Hydra";
     homepage = "https://github.com/Mange/tydra";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/ugtrain/default.nix b/pkgs/tools/misc/ugtrain/default.nix
index 0645645ae2bf3..e92170ad595a6 100644
--- a/pkgs/tools/misc/ugtrain/default.nix
+++ b/pkgs/tools/misc/ugtrain/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkg-config
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook pkg-config scanmem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ugtrain/ugtrain";
     description = "The Universal Elite Game Trainer for CLI (Linux game trainer research project)";
     maintainers = with maintainers; [ mtrsk ];
diff --git a/pkgs/tools/misc/uhubctl/default.nix b/pkgs/tools/misc/uhubctl/default.nix
index 49da81d6094f6..bd7e956bb1cbf 100644
--- a/pkgs/tools/misc/uhubctl/default.nix
+++ b/pkgs/tools/misc/uhubctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , libusb1
 }:
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ libusb1 ];
 
   installFlags = [ "prefix=${placeholder "out"}" ];
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mvp/uhubctl";
     description = "Utility to control USB power per-port on smart USB hubs";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/umlet/default.nix b/pkgs/tools/misc/umlet/default.nix
index b0edf3e7de0a9..a073417be7d27 100644
--- a/pkgs/tools/misc/umlet/default.nix
+++ b/pkgs/tools/misc/umlet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, unzip, runtimeShell }:
+{ lib, stdenv, fetchurl, jre, unzip, runtimeShell }:
 
 stdenv.mkDerivation rec {
   major = "14";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     chmod a+x "$out/bin/umlet"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Free, open-source UML tool with a simple user interface";
     longDescription = ''
       UMLet is a free, open-source UML tool with a simple user interface:
diff --git a/pkgs/tools/misc/unclutter-xfixes/default.nix b/pkgs/tools/misc/unclutter-xfixes/default.nix
index 7d2e5e0c367df..612ace92f5bcc 100644
--- a/pkgs/tools/misc/unclutter-xfixes/default.nix
+++ b/pkgs/tools/misc/unclutter-xfixes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub,
+{ lib, stdenv, fetchFromGitHub,
   xlibsWrapper, libev, libXi, libXfixes,
   pkgconfig, asciidoc, libxslt, docbook_xsl }:
 
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rewrite of unclutter using the X11 Xfixes extension";
     platforms = platforms.unix;
     license = stdenv.lib.licenses.mit;
diff --git a/pkgs/tools/misc/unclutter/default.nix b/pkgs/tools/misc/unclutter/default.nix
index ef8e865e91f39..a7470fae6894a 100644
--- a/pkgs/tools/misc/unclutter/default.nix
+++ b/pkgs/tools/misc/unclutter/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, xlibsWrapper}:
+{lib, stdenv, fetchurl, xlibsWrapper}:
 
 stdenv.mkDerivation {
   name = "unclutter-8";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     make DESTDIR="$out" MANPATH="$out/share/man" PREFIX="" install.man
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Hides mouse pointer while not in use";
     longDescription = ''
       Unclutter hides your X mouse cursor when you do not need it, to prevent
diff --git a/pkgs/tools/misc/unicode/default.nix b/pkgs/tools/misc/unicode/default.nix
index b83dd17d0bc1b..c8e1a0f7ca4be 100644
--- a/pkgs/tools/misc/unicode/default.nix
+++ b/pkgs/tools/misc/unicode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, python3Packages, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, python3Packages, installShellFiles }:
 
 python3Packages.buildPythonApplication rec {
   pname = "unicode";
@@ -27,7 +27,7 @@ python3Packages.buildPythonApplication rec {
     installManPage paracode.1 unicode.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display unicode character properties";
     homepage = "https://github.com/garabik/unicode";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/units/default.nix b/pkgs/tools/misc/units/default.nix
index d62f10daeea6f..2b40e289cadde 100644
--- a/pkgs/tools/misc/units/default.nix
+++ b/pkgs/tools/misc/units/default.nix
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unit conversion tool";
     homepage = "https://www.gnu.org/software/units/";
     license = [ licenses.gpl3Plus ];
diff --git a/pkgs/tools/misc/usbmuxd/default.nix b/pkgs/tools/misc/usbmuxd/default.nix
index 968b4e0072a5f..68d972e5968d6 100644
--- a/pkgs/tools/misc/usbmuxd/default.nix
+++ b/pkgs/tools/misc/usbmuxd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libusb1, libimobiledevice }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libusb1, libimobiledevice }:
 
 stdenv.mkDerivation rec {
   pname = "usbmuxd";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     configureFlags="$configureFlags --with-systemdsystemunitdir=$out/lib/systemd/system"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/libimobiledevice/usbmuxd";
     description = "A socket daemon to multiplex connections from and to iOS devices";
     longDescription = ''
diff --git a/pkgs/tools/misc/vcs_query/default.nix b/pkgs/tools/misc/vcs_query/default.nix
index da42b35391b72..7e1387df1f826 100644
--- a/pkgs/tools/misc/vcs_query/default.nix
+++ b/pkgs/tools/misc/vcs_query/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchFromGitHub }:
+{ lib, stdenv, python3, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "vcs_query";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     patchPythonScript $out/bin/vcs_query
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mageta/vcs_query";
     description = "eMail query-command to use vCards in mutt and Vim";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/vector/default.nix b/pkgs/tools/misc/vector/default.nix
index d7b141153f46e..1d0b5d84f77bb 100644
--- a/pkgs/tools/misc/vector/default.nix
+++ b/pkgs/tools/misc/vector/default.nix
@@ -58,7 +58,7 @@ rustPlatform.buildRustPackage rec {
     ''}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high-performance logs, metrics, and events router";
     homepage    = "https://github.com/timberio/vector";
     license     = with licenses; [ asl20 ];
diff --git a/pkgs/tools/misc/vimer/default.nix b/pkgs/tools/misc/vimer/default.nix
index 5bef80adcaf8e..1fbb85f07516d 100644
--- a/pkgs/tools/misc/vimer/default.nix
+++ b/pkgs/tools/misc/vimer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   version = "0.2.0";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/vimer
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/susam/vimer";
     description = ''
       A convenience wrapper for gvim/mvim --remote(-tab)-silent to open files
diff --git a/pkgs/tools/misc/vimpager/build.nix b/pkgs/tools/misc/vimpager/build.nix
index 60389f6862b6f..ec1766d7af31f 100644
--- a/pkgs/tools/misc/vimpager/build.nix
+++ b/pkgs/tools/misc/vimpager/build.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , coreutils
 , sharutils
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Use Vim as PAGER";
     homepage    = "https://www.vim.org/scripts/script.php?script_id=1723";
     license     = with licenses; [ bsd2 mit vim ];
diff --git a/pkgs/tools/misc/vimv/default.nix b/pkgs/tools/misc/vimv/default.nix
index 023d3384ed681..2b056cd079a72 100644
--- a/pkgs/tools/misc/vimv/default.nix
+++ b/pkgs/tools/misc/vimv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bash, fetchFromGitHub }:
+{ lib, stdenv, bash, fetchFromGitHub }:
 stdenv.mkDerivation {
   pname = "vimv";
   version = "unstable-2019-10-31";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     install $src/vimv $out/bin/vimv
     patchShebangs $out/bin/vimv
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/thameera/vimv";
     description = "Batch-rename files using Vim";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/vimwiki-markdown/default.nix b/pkgs/tools/misc/vimwiki-markdown/default.nix
index 7c8a723f41f02..c1b1fce7abdde 100644
--- a/pkgs/tools/misc/vimwiki-markdown/default.nix
+++ b/pkgs/tools/misc/vimwiki-markdown/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonApplication
 , fetchPypi
 , markdown
@@ -19,7 +19,7 @@ buildPythonApplication rec {
     pygments
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Vimwiki markdown plugin";
     homepage = "https://github.com/WnP/vimwiki_markdown";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/vivid/default.nix b/pkgs/tools/misc/vivid/default.nix
index 35a1d5d2d12aa..dad352cc65771 100644
--- a/pkgs/tools/misc/vivid/default.nix
+++ b/pkgs/tools/misc/vivid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "vivid";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "10xddr5cccc5cmhn4kwi27h3krmgapd7bqcp4rhjlbhdhsw7qxkx";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A generator for LS_COLORS with support for multiple color themes";
     homepage = "https://github.com/sharkdp/vivid";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/tools/misc/vix/default.nix b/pkgs/tools/misc/vix/default.nix
index 7e93cd5d67ec3..cf060218889a7 100644
--- a/pkgs/tools/misc/vix/default.nix
+++ b/pkgs/tools/misc/vix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, SDL }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, SDL }:
 
 stdenv.mkDerivation {
   pname = "vix";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ SDL ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Visual Interface heXadecimal dump ";
     homepage = "http://actinid.org/vix/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/void/default.nix b/pkgs/tools/misc/void/default.nix
index 21df532f9489b..e6d36155732eb 100644
--- a/pkgs/tools/misc/void/default.nix
+++ b/pkgs/tools/misc/void/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "void";
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0fnkcjxcsiw9j0ibh4z7zy0m6r5d84q5hvr2darwpckbn9ryrh3k";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Terminal-based personal organizer";
     homepage = "https://github.com/spacejam/void";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/vorbisgain/default.nix b/pkgs/tools/misc/vorbisgain/default.nix
index 78e860f216a82..fe405b0eaa40e 100644
--- a/pkgs/tools/misc/vorbisgain/default.nix
+++ b/pkgs/tools/misc/vorbisgain/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, libogg, libvorbis }:
+{ lib, stdenv, fetchurl, unzip, libogg, libvorbis }:
 
 stdenv.mkDerivation rec {
   name = "vorbisgain-0.37";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     configureFlags="--mandir=$out/share/man"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sjeng.org/vorbisgain.html";
     description = "A utility that corrects the volume of an Ogg Vorbis file to a predefined standardized loudness";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/vttest/default.nix b/pkgs/tools/misc/vttest/default.nix
index 6be05cf53a21b..64a76e97baef7 100644
--- a/pkgs/tools/misc/vttest/default.nix
+++ b/pkgs/tools/misc/vttest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "vttest";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
     sha256 = "0181lk999gfqk8pkd4yx0qrz9r3k9a0z0i50wcayp7z1n1ivqllb";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tests the compatibility so-called 'VT100-compatible' terminals";
     homepage = "https://invisible-island.net/vttest/";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/wakatime/default.nix b/pkgs/tools/misc/wakatime/default.nix
index 4e0e9193fe7d1..75f461062093b 100644
--- a/pkgs/tools/misc/wakatime/default.nix
+++ b/pkgs/tools/misc/wakatime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, glibcLocales }:
+{ lib, stdenv, python3Packages, fetchFromGitHub, glibcLocales }:
 
 with python3Packages;
 buildPythonApplication rec {
@@ -22,7 +22,7 @@ buildPythonApplication rec {
     pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "WakaTime command line interface";
     longDescription = ''
diff --git a/pkgs/tools/misc/watchexec/default.nix b/pkgs/tools/misc/watchexec/default.nix
index 728cdd0c17365..8a68bef264cd8 100644
--- a/pkgs/tools/misc/watchexec/default.nix
+++ b/pkgs/tools/misc/watchexec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, CoreServices, installShellFiles }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, CoreServices, installShellFiles }:
 
 rustPlatform.buildRustPackage rec {
   pname = "watchexec";
@@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion --zsh --name _watchexec completions/zsh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Executes commands in response to file modifications";
     homepage = "https://github.com/watchexec/watchexec";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/tools/misc/websocat/default.nix b/pkgs/tools/misc/websocat/default.nix
index f2bcfd8b78135..0d4bfacfa273b 100644
--- a/pkgs/tools/misc/websocat/default.nix
+++ b/pkgs/tools/misc/websocat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, openssl, rustPlatform, Security, makeWrapper, bash }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, openssl, rustPlatform, Security, makeWrapper, bash }:
 
 rustPlatform.buildRustPackage rec {
   pname = "websocat";
@@ -25,7 +25,7 @@ rustPlatform.buildRustPackage rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ bash ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line client for WebSockets (like netcat/socat)";
     homepage = "https://github.com/vi/websocat";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/wev/default.nix b/pkgs/tools/misc/wev/default.nix
index 0f033d1c7e22e..c1debfd924da8 100644
--- a/pkgs/tools/misc/wev/default.nix
+++ b/pkgs/tools/misc/wev/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , pkg-config, scdoc, wayland
 , wayland-protocols, libxkbcommon
 }:
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wayland event viewer";
     longDescription = ''
       This is a tool for debugging events on a Wayland window, analagous to the
diff --git a/pkgs/tools/misc/wimboot/default.nix b/pkgs/tools/misc/wimboot/default.nix
index a63fa4106345e..b25e0b55379dd 100644
--- a/pkgs/tools/misc/wimboot/default.nix
+++ b/pkgs/tools/misc/wimboot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, libbfd, zlib, libiberty }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, libbfd, zlib, libiberty }:
 
 stdenv.mkDerivation rec {
   pname = "wimboot";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     cp wimboot.x86_64.efi $out/share/wimboot
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ipxe.org/wimboot";
     description = "Windows Imaging Format bootloader";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/wl-clipboard/default.nix b/pkgs/tools/misc/wl-clipboard/default.nix
index 66a6137855754..3904a1a03bcd4 100644
--- a/pkgs/tools/misc/wl-clipboard/default.nix
+++ b/pkgs/tools/misc/wl-clipboard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig
 , wayland, wayland-protocols }:
 
 stdenv.mkDerivation rec {
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson ninja pkgconfig wayland-protocols ];
   buildInputs = [ wayland ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line copy/paste utilities for Wayland";
     homepage = "https://github.com/bugaevc/wl-clipboard";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/wlr-randr/default.nix b/pkgs/tools/misc/wlr-randr/default.nix
index 7bdffb6f72210..5f0fec9fe616c 100644
--- a/pkgs/tools/misc/wlr-randr/default.nix
+++ b/pkgs/tools/misc/wlr-randr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, cmake, pkgconfig, wayland }:
+{ lib, stdenv, fetchFromGitHub, meson, ninja, cmake, pkgconfig, wayland }:
 
 stdenv.mkDerivation rec {
   pname = "wlr-randr";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson ninja cmake pkgconfig ];
   buildInputs = [ wayland ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.mit;
     description = "An xrandr clone for wlroots compositors";
     homepage = "https://github.com/emersion/wlr-randr";
diff --git a/pkgs/tools/misc/wob/default.nix b/pkgs/tools/misc/wob/default.nix
index a619a43c9f14d..8ddc7960cbbe1 100644
--- a/pkgs/tools/misc/wob/default.nix
+++ b/pkgs/tools/misc/wob/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , meson, ninja, pkg-config, scdoc, wayland # wayland-scanner
 , wayland-protocols, libseccomp
 }:
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   mesonFlags = stdenv.lib.optional stdenv.isLinux "-Dseccomp=enabled";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight overlay bar for Wayland";
     longDescription = ''
       A lightweight overlay volume/backlight/progress/anything bar for Wayland,
diff --git a/pkgs/tools/misc/woeusb/default.nix b/pkgs/tools/misc/woeusb/default.nix
index fddb98d8dc38b..63c2d017868ae 100644
--- a/pkgs/tools/misc/woeusb/default.nix
+++ b/pkgs/tools/misc/woeusb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, makeWrapper
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, makeWrapper
 , coreutils, dosfstools, findutils, gawk, gnugrep, grub2_light, ncurses, ntfs3g, parted, p7zip, util-linux, wget
 , wxGTK30 }:
 
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
     [ "$out_version" = '${version}' ]
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create bootable USB disks from Windows ISO images";
     homepage = "https://github.com/slacka/WoeUSB";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/woof/default.nix b/pkgs/tools/misc/woof/default.nix
index 158a83a99ca5a..5c48a3cb27582 100644
--- a/pkgs/tools/misc/woof/default.nix
+++ b/pkgs/tools/misc/woof/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 stdenv.mkDerivation rec {
   version = "2020-12-17";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/woof
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.home.unix-ag.org/simon/woof.html";
     description = "Web Offer One File - Command-line utility to easily exchange files over a local network";
     license = stdenv.lib.licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/wsl-open/default.nix b/pkgs/tools/misc/wsl-open/default.nix
index ddd3904a10577..2b5808e3be902 100644
--- a/pkgs/tools/misc/wsl-open/default.nix
+++ b/pkgs/tools/misc/wsl-open/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, installShellFiles }:
 
 stdenv.mkDerivation rec {
   pname = "wsl-open";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     installManPage wsl-open.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open files with xdg-open from Windows Subsystem for Linux (WSL) in Windows applications";
     homepage = "https://gitlab.com/4U6U57/wsl-open";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/wyrd/default.nix b/pkgs/tools/misc/wyrd/default.nix
index e1c4e4fd2fca7..491c362eed40d 100644
--- a/pkgs/tools/misc/wyrd/default.nix
+++ b/pkgs/tools/misc/wyrd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocamlPackages, ncurses, remind }:
+{ lib, stdenv, fetchurl, ocamlPackages, ncurses, remind }:
 
 stdenv.mkDerivation rec {
   version = "1.4.6";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   preferLocalBuild = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A text-based front-end to Remind";
     longDescription = ''
       Wyrd is a text-based front-end to Remind, a sophisticated
diff --git a/pkgs/tools/misc/x11idle/default.nix b/pkgs/tools/misc/x11idle/default.nix
index 5e64137cbf6ef..cd1c11dbdb643 100644
--- a/pkgs/tools/misc/x11idle/default.nix
+++ b/pkgs/tools/misc/x11idle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libXScrnSaver, libX11 }:
+{ lib, stdenv, fetchurl, libXScrnSaver, libX11 }:
 
 stdenv.mkDerivation rec {
 
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     gcc -lXss -lX11 $src -o $out/bin/x11idle
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Compute consecutive idle time for current X11 session with millisecond resolution
     '';
diff --git a/pkgs/tools/misc/xdaliclock/default.nix b/pkgs/tools/misc/xdaliclock/default.nix
index 3950e6bee28ae..6aaee0f00b519 100644
--- a/pkgs/tools/misc/xdaliclock/default.nix
+++ b/pkgs/tools/misc/xdaliclock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, xorgproto, libXt, libICE, libSM, libXext }:
+{ lib, stdenv, fetchurl, libX11, xorgproto, libXt, libICE, libSM, libXext }:
 
 stdenv.mkDerivation rec {
   pname = "xdaliclock";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     mkdir -vp $out/bin $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A clock application that morphs digits when they are changed";
     maintainers = with maintainers; [ raskin rycee ];
     platforms = with platforms; linux ++ freebsd;
diff --git a/pkgs/tools/misc/xdo/default.nix b/pkgs/tools/misc/xdo/default.nix
index f9928b6f140fb..31df9552accd8 100644
--- a/pkgs/tools/misc/xdo/default.nix
+++ b/pkgs/tools/misc/xdo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libxcb, xcbutil, xcbutilwm }:
+{ lib, stdenv, fetchFromGitHub, libxcb, xcbutil, xcbutilwm }:
 
 stdenv.mkDerivation rec {
    pname = "xdo";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
    buildInputs = [ libxcb xcbutilwm xcbutil ];
 
-   meta = with stdenv.lib; {
+   meta = with lib; {
      description = "Small X utility to perform elementary actions on windows";
      homepage = "https://github.com/baskerville/xdo";
      maintainers = with maintainers; [ meisternu ];
diff --git a/pkgs/tools/misc/xdxf2slob/default.nix b/pkgs/tools/misc/xdxf2slob/default.nix
index 00f1899f97afb..8d4998a9ff99e 100644
--- a/pkgs/tools/misc/xdxf2slob/default.nix
+++ b/pkgs/tools/misc/xdxf2slob/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication {
   name = "xdxf2slob-unstable-2015-06-30";
@@ -12,7 +12,7 @@ python3Packages.buildPythonApplication {
 
   propagatedBuildInputs = [ python3Packages.PyICU python3Packages.slob ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to convert XDXF dictionary files to slob format";
     homepage = "https://github.com/itkach/xdxf2slob/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/xfstests/default.nix b/pkgs/tools/misc/xfstests/default.nix
index 3bc01048c1edc..769e23c389c74 100644
--- a/pkgs/tools/misc/xfstests/default.nix
+++ b/pkgs/tools/misc/xfstests/default.nix
@@ -100,7 +100,7 @@ stdenv.mkDerivation {
     exec ./check "$@"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Torture test suite for filesystems";
     homepage = "https://git.kernel.org/pub/scm/fs/xfs/xfstests-dev.git/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/misc/xiccd/default.nix b/pkgs/tools/misc/xiccd/default.nix
index 82759441a46b7..8b9b30d56d493 100644
--- a/pkgs/tools/misc/xiccd/default.nix
+++ b/pkgs/tools/misc/xiccd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libX11, libXrandr, glib, colord }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libX11, libXrandr, glib, colord }:
 
 stdenv.mkDerivation rec {
   pname = "xiccd";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ libX11 libXrandr glib colord ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "X color profile daemon";
     homepage = "https://github.com/agalakhov/xiccd";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/xilinx-bootgen/default.nix b/pkgs/tools/misc/xilinx-bootgen/default.nix
index e7aa30ac05919..5d0c80c55bfb9 100644
--- a/pkgs/tools/misc/xilinx-bootgen/default.nix
+++ b/pkgs/tools/misc/xilinx-bootgen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl }:
+{ lib, stdenv, fetchFromGitHub, openssl }:
 
 stdenv.mkDerivation {
   pname = "xilinx-bootgen";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     install -Dm755 bootgen $out/bin/bootgen
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate Boot Images for Xilinx Zynq and ZU+ SoCs";
     longDescription = ''
       Bootgen for Xilinx Zynq and ZU+ SoCs, without code related to generating
diff --git a/pkgs/tools/misc/xmonad-log/default.nix b/pkgs/tools/misc/xmonad-log/default.nix
index 5dfbcdfad7405..b8dd369cd6a83 100644
--- a/pkgs/tools/misc/xmonad-log/default.nix
+++ b/pkgs/tools/misc/xmonad-log/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "xmonad-log";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "xmonad DBus monitoring solution";
     homepage = "https://github.com/xintron/xmonad-log";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/xprite-editor/default.nix b/pkgs/tools/misc/xprite-editor/default.nix
index 3f7e2e32294c3..553863dda1aed 100644
--- a/pkgs/tools/misc/xprite-editor/default.nix
+++ b/pkgs/tools/misc/xprite-editor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , gtk3
@@ -33,7 +33,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoBuildFlags = [ "--bin" "xprite-native" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rickyhan/xprite-editor";
     description = "Pixel art editor";
     license = licenses.gpl3;
diff --git a/pkgs/tools/misc/xvfb-run/default.nix b/pkgs/tools/misc/xvfb-run/default.nix
index 02a2d67de53dd..8717d90123927 100644
--- a/pkgs/tools/misc/xvfb-run/default.nix
+++ b/pkgs/tools/misc/xvfb-run/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, xorgserver, getopt
+{ lib, stdenv, fetchurl, makeWrapper, xorgserver, getopt
 , xauth, util-linux, which, fontsConf, gawk, coreutils }:
 let
   xvfb_run = fetchurl {
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
       --prefix PATH : ${stdenv.lib.makeBinPath [ getopt xorgserver xauth which util-linux gawk coreutils ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.unix;
     license = licenses.gpl2;
   };
diff --git a/pkgs/tools/misc/yad/default.nix b/pkgs/tools/misc/yad/default.nix
index 889c266d28e26..b28b5397e62d9 100644
--- a/pkgs/tools/misc/yad/default.nix
+++ b/pkgs/tools/misc/yad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, intltool, autoreconfHook, wrapGAppsHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, intltool, autoreconfHook, wrapGAppsHook
 , gtk3, hicolor-icon-theme, netpbm }:
 
 stdenv.mkDerivation rec {
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     intltoolize
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/yad-dialog/";
     description = "GUI dialog tool for shell scripts";
     longDescription = ''
diff --git a/pkgs/tools/misc/yank/default.nix b/pkgs/tools/misc/yank/default.nix
index 6111a0f98708b..19a4ba986ff22 100644
--- a/pkgs/tools/misc/yank/default.nix
+++ b/pkgs/tools/misc/yank/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, xsel }:
+{ lib, stdenv, fetchFromGitHub, xsel }:
 
 stdenv.mkDerivation rec {
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   installFlags = [ "PREFIX=$(out)" ];
   makeFlags = [ "YANKCMD=${xsel}/bin/xsel" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mptre/yank";
     description = "Yank terminal output to clipboard";
     longDescription = ''
diff --git a/pkgs/tools/misc/yle-dl/default.nix b/pkgs/tools/misc/yle-dl/default.nix
index 40bf214f4630d..64568ca46b068 100644
--- a/pkgs/tools/misc/yle-dl/default.nix
+++ b/pkgs/tools/misc/yle-dl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rtmpdump, php, wget, python3Packages, ffmpeg_3 }:
+{ lib, stdenv, fetchFromGitHub, rtmpdump, php, wget, python3Packages, ffmpeg_3 }:
 
 python3Packages.buildPythonApplication rec {
   pname = "yle-dl";
@@ -19,7 +19,7 @@ python3Packages.buildPythonApplication rec {
   doCheck = false; # tests require network access
   checkInputs = with python3Packages; [ ffmpeg_3 pytest pytestrunner ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Downloads videos from Yle (Finnish Broadcasting Company) servers";
     homepage = "https://aajanki.github.io/yle-dl/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/misc/you-get/default.nix b/pkgs/tools/misc/you-get/default.nix
index 6a13c455fe060..5444308399657 100644
--- a/pkgs/tools/misc/you-get/default.nix
+++ b/pkgs/tools/misc/you-get/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchPypi }:
+{ lib, stdenv, buildPythonApplication, fetchPypi }:
 
 buildPythonApplication rec {
   pname = "you-get";
@@ -13,7 +13,7 @@ buildPythonApplication rec {
     sha256 = "5a6cc0d661fe0cd4210bf467d6c89afd8611609e402690254722c1415736da92";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tiny command line utility to download media contents from the web";
     homepage = "https://you-get.org";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/ytree/default.nix b/pkgs/tools/misc/ytree/default.nix
index 9edd287776b1e..9121b1289f247 100644
--- a/pkgs/tools/misc/ytree/default.nix
+++ b/pkgs/tools/misc/ytree/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , ncurses
 , readline
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A curses-based file manager similar to DOS Xtree(TM)";
     homepage = "https://www.han.de/~werner/ytree.html";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/misc/yubico-piv-tool/default.nix b/pkgs/tools/misc/yubico-piv-tool/default.nix
index 07f186e33226e..188b7fa6b28da 100644
--- a/pkgs/tools/misc/yubico-piv-tool/default.nix
+++ b/pkgs/tools/misc/yubico-piv-tool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, openssl, check, pcsclite, PCSC
+{ lib, stdenv, fetchurl, pkgconfig, openssl, check, pcsclite, PCSC
 , withApplePCSC ? stdenv.isDarwin
 }:
 
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--with-backend=${if withApplePCSC then "macscard" else "pcsc"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://developers.yubico.com/yubico-piv-tool/";
     description = ''
       Used for interacting with the Privilege and Identification Card (PIV)
diff --git a/pkgs/tools/misc/yubikey-neo-manager/default.nix b/pkgs/tools/misc/yubikey-neo-manager/default.nix
index cb37ae249289e..eeb4f5c1bd59d 100644
--- a/pkgs/tools/misc/yubikey-neo-manager/default.nix
+++ b/pkgs/tools/misc/yubikey-neo-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python27Packages
+{ lib, stdenv, fetchurl, python27Packages
 , libykneomgr, yubikey-personalization, libu2f-host }:
 
 python27Packages.buildPythonPackage rec {
@@ -18,7 +18,7 @@ python27Packages.buildPythonPackage rec {
     "--set LD_PRELOAD '${libykneomgr}/lib/libykneomgr.so ${yubikey-personalization}/lib/libykpers-1.so ${libu2f-host}/lib/libu2f-host.so'"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://developers.yubico.com/yubikey-neo-manager";
     description = "Cross platform personalization tool for the YubiKey NEO";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/yubikey-personalization-gui/default.nix b/pkgs/tools/misc/yubikey-personalization-gui/default.nix
index 96e7024f7a7af..99187ef548f81 100644
--- a/pkgs/tools/misc/yubikey-personalization-gui/default.nix
+++ b/pkgs/tools/misc/yubikey-personalization-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mkDerivation, pkgconfig, qtbase, qmake, imagemagick
+{ lib, stdenv, fetchurl, mkDerivation, pkgconfig, qtbase, qmake, imagemagick
 , libyubikey, yubikey-personalization }:
 
 mkDerivation rec {
@@ -32,7 +32,7 @@ mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://developers.yubico.com/yubikey-personalization-gui";
     description = "A QT based cross-platform utility designed to facilitate reconfiguration of the Yubikey";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/yubikey-personalization/default.nix b/pkgs/tools/misc/yubikey-personalization/default.nix
index 69e3d5886537e..1830af6a9bc02 100644
--- a/pkgs/tools/misc/yubikey-personalization/default.nix
+++ b/pkgs/tools/misc/yubikey-personalization/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, libusb1, libyubikey, json_c }:
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, libusb1, libyubikey, json_c }:
 
 stdenv.mkDerivation rec {
   pname = "yubikey-personalization";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/lib/udev/rules.d 69-yubikey.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://developers.yubico.com/yubikey-personalization";
     description = "A library and command line tool to personalize YubiKeys";
     license = licenses.bsd2;
diff --git a/pkgs/tools/misc/z-lua/default.nix b/pkgs/tools/misc/z-lua/default.nix
index 2b5a46435499e..419846a9d3741 100644
--- a/pkgs/tools/misc/z-lua/default.nix
+++ b/pkgs/tools/misc/z-lua/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, lua52Packages, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, lua52Packages, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "z-lua";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/skywind3000/z.lua";
     description = "A new cd command that helps you navigate faster by learning your habits";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/zabbixctl/default.nix b/pkgs/tools/misc/zabbixctl/default.nix
index c54456ede3d4d..15add8ed19196 100644
--- a/pkgs/tools/misc/zabbixctl/default.nix
+++ b/pkgs/tools/misc/zabbixctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "zabbixctl";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Most effective way for operating in Zabbix Server";
     homepage = "https://github.com/kovetskiy/zabbixctl";
     license = licenses.mit;
diff --git a/pkgs/tools/misc/zalgo/default.nix b/pkgs/tools/misc/zalgo/default.nix
index d9538141af00d..71cc7f8b7ddbc 100644
--- a/pkgs/tools/misc/zalgo/default.nix
+++ b/pkgs/tools/misc/zalgo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "zalgo";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     install -Dm755 zalgo -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Read stdin and corrupt it with combining diacritics";
     homepage = "https://github.com/lunasorcery/zalgo";
     license = licenses.unfree;
diff --git a/pkgs/tools/misc/zsh-autoenv/default.nix b/pkgs/tools/misc/zsh-autoenv/default.nix
index f4295443f69e6..72aa2d77bc337 100644
--- a/pkgs/tools/misc/zsh-autoenv/default.nix
+++ b/pkgs/tools/misc/zsh-autoenv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, runtimeShell }:
+{ lib, stdenv, fetchFromGitHub, runtimeShell }:
 
 stdenv.mkDerivation {
   pname = "zsh-autoenv";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/zsh-autoenv-share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Automatically sources whitelisted .autoenv.zsh files";
     longDescription = ''
       zsh-autoenv automatically sources (known/whitelisted)
diff --git a/pkgs/tools/misc/zsh-navigation-tools/default.nix b/pkgs/tools/misc/zsh-navigation-tools/default.nix
index 86dd990cd746c..f719fe3b69225 100644
--- a/pkgs/tools/misc/zsh-navigation-tools/default.nix
+++ b/pkgs/tools/misc/zsh-navigation-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "zsh-navigation-tools";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp .config/znt/n-* $out/share/zsh/site-functions/.config/znt
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Curses-based tools for ZSH";
     homepage = "https://github.com/psprint/zsh-navigation-tools";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/aircrack-ng/default.nix b/pkgs/tools/networking/aircrack-ng/default.nix
index fe07d203607af..76c1de651e012 100644
--- a/pkgs/tools/networking/aircrack-ng/default.nix
+++ b/pkgs/tools/networking/aircrack-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap, openssl, zlib, wirelesstools
+{ lib, stdenv, fetchurl, libpcap, openssl, zlib, wirelesstools
 , iw, ethtool, pciutils, libnl, pkgconfig, makeWrapper
 , autoreconfHook, usbutils }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wireless encryption cracking tools";
     homepage = "http://www.aircrack-ng.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/airfield/default.nix b/pkgs/tools/networking/airfield/default.nix
index d08996eb13f65..0976a764a6f2d 100644
--- a/pkgs/tools/networking/airfield/default.nix
+++ b/pkgs/tools/networking/airfield/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgs, makeWrapper, buildEnv
 , nodejs, runtimeShell
 }:
@@ -60,7 +60,7 @@ in stdenv.mkDerivation {
       --set NODE_PATH "${runtimeEnv}/lib/node_modules"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A web-interface for hipache-proxy";
     license = licenses.mit;
     homepage = "https://github.com/emblica/airfield";
diff --git a/pkgs/tools/networking/altermime/default.nix b/pkgs/tools/networking/altermime/default.nix
index b1481b2208c6d..c28df46145927 100644
--- a/pkgs/tools/networking/altermime/default.nix
+++ b/pkgs/tools/networking/altermime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   baseName = "altermime";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     mkdir -p "$out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MIME alteration tool";
     maintainers = [ maintainers.raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/argus-clients/default.nix b/pkgs/tools/networking/argus-clients/default.nix
index a1ff30faff3fe..6da6f927eca23 100644
--- a/pkgs/tools/networking/argus-clients/default.nix
+++ b/pkgs/tools/networking/argus-clients/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap, bison, flex, cyrus_sasl, tcp_wrappers, pkgconfig, perl }:
+{ lib, stdenv, fetchurl, libpcap, bison, flex, cyrus_sasl, tcp_wrappers, pkgconfig, perl }:
 
 stdenv.mkDerivation rec {
   pname = "argus-clients";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libpcap bison cyrus_sasl tcp_wrappers flex ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Clients for ARGUS";
     longDescription = ''Clients for Audit Record Generation and
     Utilization System (ARGUS). The Argus Project is focused on developing all
diff --git a/pkgs/tools/networking/argus/default.nix b/pkgs/tools/networking/argus/default.nix
index 32c6c785fa5de..fb3f7228c8dc2 100644
--- a/pkgs/tools/networking/argus/default.nix
+++ b/pkgs/tools/networking/argus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap, bison, flex, cyrus_sasl, tcp_wrappers,
+{ lib, stdenv, fetchurl, libpcap, bison, flex, cyrus_sasl, tcp_wrappers,
   pkgconfig, procps, which, wget, lsof, net-snmp, perl }:
 
 stdenv.mkDerivation rec {
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
       --replace /usr/bin/snmpwalk ${stdenv.lib.getBin net-snmp}/bin/snmpwalk
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Audit Record Generation and Utilization System for networks";
     longDescription = ''The Argus Project is focused on developing all
     aspects of large scale network situtational awareness derived from
diff --git a/pkgs/tools/networking/aria2/default.nix b/pkgs/tools/networking/aria2/default.nix
index 614584a5f565b..428e8a2e112e8 100644
--- a/pkgs/tools/networking/aria2/default.nix
+++ b/pkgs/tools/networking/aria2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchpatch, fetchFromGitHub, pkgconfig, autoreconfHook
 , openssl, c-ares, libxml2, sqlite, zlib, libssh2
 , cppunit, sphinx
 , Security
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://aria2.github.io";
     description = "A lightweight, multi-protocol, multi-source, command-line download utility";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/arping/default.nix b/pkgs/tools/networking/arping/default.nix
index ad0139b184ddd..4a5cae9bd3c47 100644
--- a/pkgs/tools/networking/arping/default.nix
+++ b/pkgs/tools/networking/arping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, libnet, libpcap }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, libnet, libpcap }:
 
 stdenv.mkDerivation rec {
   version = "2.21";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Broadcasts a who-has ARP packet on the network and prints answers";
     homepage = "https://github.com/ThomasHabets/arping";
     license = with licenses; [ gpl2 ];
diff --git a/pkgs/tools/networking/arpoison/default.nix b/pkgs/tools/networking/arpoison/default.nix
index eac2f380d15b2..6268d958204f6 100644
--- a/pkgs/tools/networking/arpoison/default.nix
+++ b/pkgs/tools/networking/arpoison/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, libnet }:
+{ lib, stdenv, fetchzip, libnet }:
 
 stdenv.mkDerivation rec {
   name = "arpoison-0.7";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     cp arpoison.8.gz $out/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "UNIX arp cache update utility";
     homepage = "http://www.arpoison.net/";
     license = with licenses; [ gpl2 ];
diff --git a/pkgs/tools/networking/assh/default.nix b/pkgs/tools/networking/assh/default.nix
index caebcb6fe8c01..e8b93adcd6417 100644
--- a/pkgs/tools/networking/assh/default.nix
+++ b/pkgs/tools/networking/assh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, openssh, makeWrapper }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, openssh, makeWrapper }:
 
 buildGoModule rec {
   pname = "assh";
@@ -27,7 +27,7 @@ buildGoModule rec {
     $out/bin/assh --help > /dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced SSH config - Regex, aliases, gateways, includes and dynamic hosts";
     homepage = "https://github.com/moul/assh";
     changelog = "https://github.com/moul/assh/releases/tag/v${version}";
diff --git a/pkgs/tools/networking/atinout/default.nix b/pkgs/tools/networking/atinout/default.nix
index fcd48564da0f5..bc2af5c5ee298 100644
--- a/pkgs/tools/networking/atinout/default.nix
+++ b/pkgs/tools/networking/atinout/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, ronn, mount }:
+{ lib, stdenv, fetchgit, ronn, mount }:
 
 stdenv.mkDerivation rec {
   name = "atinout-${version}";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     make PREFIX=$out install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://atinout.sourceforge.net";
     description = "Tool for talking to modems";
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/autossh/default.nix b/pkgs/tools/networking/autossh/default.nix
index f89302c4295fa..49fb4d52e0b49 100644
--- a/pkgs/tools/networking/autossh/default.nix
+++ b/pkgs/tools/networking/autossh/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, openssh}:
+{lib, stdenv, fetchurl, openssh}:
 
 stdenv.mkDerivation rec {
   name = "autossh-1.4g";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
       install -D -m644 autossh.1    $out/man/man1/autossh.1                   || return 1
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.harding.motd.ca/autossh/";
     description = "Automatically restart SSH sessions and tunnels";
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/axel/default.nix b/pkgs/tools/networking/axel/default.nix
index baa498042f940..333009226c1ef 100644
--- a/pkgs/tools/networking/axel/default.nix
+++ b/pkgs/tools/networking/axel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, autoconf-archive
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, autoconf-archive
 , pkgconfig, gettext, libssl, txt2man }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "ETCDIR=${placeholder "out"}/etc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Console downloading program with some features for parallel connections for faster downloading";
     homepage = "https://github.com/axel-download-accelerator/axel";
     maintainers = with maintainers; [ pSub ];
diff --git a/pkgs/tools/networking/bacnet-stack/default.nix b/pkgs/tools/networking/bacnet-stack/default.nix
index 596b30d03e899..a4f2ef36360eb 100644
--- a/pkgs/tools/networking/bacnet-stack/default.nix
+++ b/pkgs/tools/networking/bacnet-stack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   name = "bacnet-stack";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     cp -r bin $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BACnet open source protocol stack for embedded systems, Linux, and Windows";
     platforms = platforms.linux;
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/bandwhich/default.nix b/pkgs/tools/networking/bandwhich/default.nix
index 46739742bd445..a9bf8c5189b0f 100644
--- a/pkgs/tools/networking/bandwhich/default.nix
+++ b/pkgs/tools/networking/bandwhich/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security, fetchpatch }:
 
 rustPlatform.buildRustPackage rec {
   pname = "bandwhich";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CLI utility for displaying current network utilization";
     longDescription = ''
       bandwhich sniffs a given network interface and records IP packet size, cross
diff --git a/pkgs/tools/networking/bgpq3/default.nix b/pkgs/tools/networking/bgpq3/default.nix
index e3d2218b0c97d..bd0a623a916d4 100644
--- a/pkgs/tools/networking/bgpq3/default.nix
+++ b/pkgs/tools/networking/bgpq3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "bgpq3";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   # Fix binary install location. Remove with next upstream release.
   preInstall = "mkdir -p $out/bin";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "bgp filtering automation tool";
     homepage = "https://github.com/snar/bgpq3";
     license = licenses.bsd2;
diff --git a/pkgs/tools/networking/bgpq4/default.nix b/pkgs/tools/networking/bgpq4/default.nix
index 2caeb437f7a26..4db2d933583cf 100644
--- a/pkgs/tools/networking/bgpq4/default.nix
+++ b/pkgs/tools/networking/bgpq4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "bgpq4";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     autoreconfHook
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BGP filtering automation tool";
     homepage = "https://github.com/bgp/bgpq4";
     license = licenses.bsd2;
diff --git a/pkgs/tools/networking/biosdevname/default.nix b/pkgs/tools/networking/biosdevname/default.nix
index 7cd7254518adb..f44574fb03647 100644
--- a/pkgs/tools/networking/biosdevname/default.nix
+++ b/pkgs/tools/networking/biosdevname/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, zlib, pciutils }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, zlib, pciutils }:
 
 stdenv.mkDerivation rec {
   pname = "biosdevname";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--sbindir=\${out}/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Udev helper for naming devices per BIOS names";
     license = licenses.gpl2;
     platforms = ["x86_64-linux" "i686-linux"];
diff --git a/pkgs/tools/networking/boringtun/default.nix b/pkgs/tools/networking/boringtun/default.nix
index 7c322638712c3..b2d41bf8019cf 100644
--- a/pkgs/tools/networking/boringtun/default.nix
+++ b/pkgs/tools/networking/boringtun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "boringtun";
@@ -18,7 +18,7 @@ rustPlatform.buildRustPackage rec {
   # Testing this project requires sudo, Docker and network access, etc.
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Userspace WireGuard® implementation in Rust";
     homepage = "https://github.com/cloudflare/boringtun";
     license = licenses.bsd3;
diff --git a/pkgs/tools/networking/brook/default.nix b/pkgs/tools/networking/brook/default.nix
index b70eb080a7af5..f84176495aa4b 100644
--- a/pkgs/tools/networking/brook/default.nix
+++ b/pkgs/tools/networking/brook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "brook";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/txthinking/brook";
     description = "A cross-platform Proxy/VPN software";
     license = with licenses; [ gpl3 ];
diff --git a/pkgs/tools/networking/bsd-finger/default.nix b/pkgs/tools/networking/bsd-finger/default.nix
index d011665a492bc..f3ecf7a9702de 100644
--- a/pkgs/tools/networking/bsd-finger/default.nix
+++ b/pkgs/tools/networking/bsd-finger/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 # !!! Duplication: this package is almost exactly the same as `bsd-finger'.
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   preInstall = '' mkdir -p $out/man/man1 $out/bin '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     license = licenses.bsdOriginal;
   };
diff --git a/pkgs/tools/networking/bukubrow/default.nix b/pkgs/tools/networking/bukubrow/default.nix
index ed8a6088db075..5188954b7634c 100644
--- a/pkgs/tools/networking/bukubrow/default.nix
+++ b/pkgs/tools/networking/bukubrow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, sqlite }: let
+{ lib, stdenv, rustPlatform, fetchFromGitHub, sqlite }: let
 
 manifest = {
   description = "Bukubrow extension host application";
@@ -38,7 +38,7 @@ in rustPlatform.buildRustPackage rec {
     install -Dm0644 chrome.json $out/etc/chromium/native-messaging-hosts/com.samhh.bukubrow.json
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A WebExtension for Buku, a command-line bookmark manager";
     homepage = "https://github.com/SamHH/bukubrow-host";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/bully/default.nix b/pkgs/tools/networking/bully/default.nix
index 4117932550f42..b49af33cd9e9d 100644
--- a/pkgs/tools/networking/bully/default.nix
+++ b/pkgs/tools/networking/bully/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpcap }:
+{ lib, stdenv, fetchFromGitHub, libpcap }:
 
 stdenv.mkDerivation rec {
   pname = "bully";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     install -Dm444 -t $out/share/doc/${pname} ../*.md
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Retrieve WPA/WPA2 passphrase from a WPS enabled access point";
     homepage = "https://github.com/kimocoder/bully";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/bwm-ng/default.nix b/pkgs/tools/networking/bwm-ng/default.nix
index ae3edf7dcea79..229b4a636c4c9 100644
--- a/pkgs/tools/networking/bwm-ng/default.nix
+++ b/pkgs/tools/networking/bwm-ng/default.nix
@@ -1,4 +1,4 @@
-{ writeText, stdenv, fetchurl, ncurses }:
+{ writeText, lib, stdenv, fetchurl, ncurses }:
 
 let
   version = "0.6.1";
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
   # This code uses inline in the gnu89 sense: see http://clang.llvm.org/compatibility.html#inline
   NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-std=gnu89";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small and simple console-based live network and disk io bandwidth monitor";
     homepage = "http://www.gropp.org/?id=projects&sub=bwm-ng";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/cadaver/default.nix b/pkgs/tools/networking/cadaver/default.nix
index 46ebb234fb180..84265d3f4b7e7 100644
--- a/pkgs/tools/networking/cadaver/default.nix
+++ b/pkgs/tools/networking/cadaver/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, openssl, readline }:
+{ lib, stdenv, fetchurl, fetchpatch, openssl, readline }:
 
 stdenv.mkDerivation rec {
   name = "cadaver-0.23.3";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ openssl readline ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line WebDAV client";
     homepage    = "http://www.webdav.org/cadaver";
     maintainers = with maintainers; [ ianwookim ];
diff --git a/pkgs/tools/networking/carddav-util/default.nix b/pkgs/tools/networking/carddav-util/default.nix
index c28048a56c076..39728f7e9a079 100644
--- a/pkgs/tools/networking/carddav-util/default.nix
+++ b/pkgs/tools/networking/carddav-util/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, python, pythonPackages, makeWrapper }:
+{ lib, stdenv, fetchgit, python, pythonPackages, makeWrapper }:
 
 stdenv.mkDerivation {
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
       --prefix PATH : "$prefix/bin:$PATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ljanyst/carddav-util";
     description = "A CardDAV import/export utility";
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/ccnet/default.nix b/pkgs/tools/networking/ccnet/default.nix
index 48d675ea09b33..e277f7fd6af6d 100644
--- a/pkgs/tools/networking/ccnet/default.nix
+++ b/pkgs/tools/networking/ccnet/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, which, autoreconfHook, pkgconfig, vala, python, libsearpc, libzdb, libuuid, libevent, sqlite, openssl}:
+{lib, stdenv, fetchurl, which, autoreconfHook, pkgconfig, vala, python, libsearpc, libzdb, libuuid, libevent, sqlite, openssl}:
 
 stdenv.mkDerivation rec {
   version = "6.1.8";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--enable-server" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/haiwen/ccnet";
     description = "A framework for writing networked applications in C";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/networking/chrony/default.nix b/pkgs/tools/networking/chrony/default.nix
index 374036d11a448..e11674f5b1b76 100644
--- a/pkgs/tools/networking/chrony/default.nix
+++ b/pkgs/tools/networking/chrony/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libcap, readline, texinfo, nss, nspr
+{ lib, stdenv, fetchurl, pkgconfig, libcap, readline, texinfo, nss, nspr
 , libseccomp, pps-tools, gnutls }:
 
 assert stdenv.isLinux -> libcap != null;
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
   configureFlags = [ "--chronyvardir=$(out)/var/lib/chrony" ]
     ++ stdenv.lib.optional stdenv.isLinux "--enable-scfilter";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sets your computer's clock from time servers on the Net";
     homepage = "https://chrony.tuxfamily.org/";
     repositories.git = "git://git.tuxfamily.org/gitroot/chrony/chrony.git";
diff --git a/pkgs/tools/networking/circus/default.nix b/pkgs/tools/networking/circus/default.nix
index ea03f8878b209..891eb19c83520 100644
--- a/pkgs/tools/networking/circus/default.nix
+++ b/pkgs/tools/networking/circus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3 }:
+{ lib, stdenv, python3 }:
 
 let
   python = python3.override {
@@ -32,7 +32,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ iowait psutil pyzmq tornado six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A process and socket manager";
     homepage = "https://github.circus.com/circus-tent/circus";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/cjdns/default.nix b/pkgs/tools/networking/cjdns/default.nix
index 8cc891cce19c7..cfc591cb2efff 100644
--- a/pkgs/tools/networking/cjdns/default.nix
+++ b/pkgs/tools/networking/cjdns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nodejs, which, python27, util-linux, nixosTests }:
+{ lib, stdenv, fetchFromGitHub, nodejs, which, python27, util-linux, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "cjdns";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests.basic = nixosTests.cjdns;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/cjdelisle/cjdns";
     description = "Encrypted networking for regular people";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/networking/cksfv/default.nix b/pkgs/tools/networking/cksfv/default.nix
index 00073686238de..581d39636fa7e 100644
--- a/pkgs/tools/networking/cksfv/default.nix
+++ b/pkgs/tools/networking/cksfv/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   name = "cksfv-1.3.15";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "0k06aq94cn5xp4knjw0p7gz06hzh622ql2xvnrlr3q8rcmdvwwx1";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://zakalwe.fi/~shd/foss/cksfv/";
     description = "A tool for verifying files against a SFV checksum file";
     platforms = platforms.all;
diff --git a/pkgs/tools/networking/clash/default.nix b/pkgs/tools/networking/clash/default.nix
index 502a4b4bbd42f..2044aeb35543e 100644
--- a/pkgs/tools/networking/clash/default.nix
+++ b/pkgs/tools/networking/clash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 
 buildGoModule rec {
   pname = "clash";
@@ -20,7 +20,7 @@ buildGoModule rec {
     "-X github.com/Dreamacro/clash/constant.Version=${version}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A rule-based tunnel in Go";
     homepage = "https://github.com/Dreamacro/clash";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/cntlm/default.nix b/pkgs/tools/networking/cntlm/default.nix
index d05d8e48dc0f1..a12ceb1d4480f 100644
--- a/pkgs/tools/networking/cntlm/default.nix
+++ b/pkgs/tools/networking/cntlm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which}:
+{ lib, stdenv, fetchurl, which}:
 
 stdenv.mkDerivation rec {
   pname = "cntlm";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/man/; cp doc/cntlm.1 $out/man/;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NTLM/NTLMv2 authenticating HTTP proxy";
     homepage = "http://cntlm.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/connman/connman-gtk/default.nix b/pkgs/tools/networking/connman/connman-gtk/default.nix
index 5de63098185c2..03606aabfe3f0 100644
--- a/pkgs/tools/networking/connman/connman-gtk/default.nix
+++ b/pkgs/tools/networking/connman/connman-gtk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, intltool, pkgconfig,
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, intltool, pkgconfig,
 gtk3, connman, openconnect, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK GUI for Connman";
     homepage = "https://github.com/jgke/connman-gtk";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/connman/connman-ncurses/default.nix b/pkgs/tools/networking/connman/connman-ncurses/default.nix
index 1e7f54f9ddbed..22cb9ccab88a7 100644
--- a/pkgs/tools/networking/connman/connman-ncurses/default.nix
+++ b/pkgs/tools/networking/connman/connman-ncurses/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, fetchFromGitHub, autoreconfHook, pkgconfig, dbus, json_c, ncurses, connman }:
+{ lib, stdenv, fetchpatch, fetchFromGitHub, autoreconfHook, pkgconfig, dbus, json_c, ncurses, connman }:
 
 stdenv.mkDerivation {
   pname = "connman-ncurses";
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     cp -va connman_ncurses "$out/bin/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple ncurses UI for connman";
     homepage = "https://github.com/eurogiciel-oss/connman-json-client";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/connman/connman-notify/default.nix b/pkgs/tools/networking/connman/connman-notify/default.nix
index df72a9474899e..9f0c9873e2a76 100644
--- a/pkgs/tools/networking/connman/connman-notify/default.nix
+++ b/pkgs/tools/networking/connman/connman-notify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, python3Packages, glib, gobject-introspection, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitLab, python3Packages, glib, gobject-introspection, wrapGAppsHook }:
 
 python3Packages.buildPythonApplication {
   pname = "connman-notify";
@@ -26,7 +26,7 @@ python3Packages.buildPythonApplication {
     install -D -t $out/share/doc README.rst
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Desktop notification integration for connman";
     homepage = "https://gitlab.com/wavexx/connman-notify";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/connman/connman.nix b/pkgs/tools/networking/connman/connman.nix
index 5121948722059..7f2552d11419a 100644
--- a/pkgs/tools/networking/connman/connman.nix
+++ b/pkgs/tools/networking/connman/connman.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkgconfig
 , file
@@ -161,7 +161,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon for managing internet connections";
     homepage = "https://01.org/connman";
     maintainers = [ maintainers.matejc ];
diff --git a/pkgs/tools/networking/corerad/default.nix b/pkgs/tools/networking/corerad/default.nix
index 6ac3c48100e8e..64e8e09467d99 100644
--- a/pkgs/tools/networking/corerad/default.nix
+++ b/pkgs/tools/networking/corerad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, nixosTests }:
 
 buildGoModule rec {
   pname = "corerad";
@@ -31,7 +31,7 @@ buildGoModule rec {
     inherit (nixosTests) corerad;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mdlayher/corerad";
     description = "Extensible and observable IPv6 NDP RA daemon";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/corkscrew/default.nix b/pkgs/tools/networking/corkscrew/default.nix
index 9cfe65873acdc..d5756cefdaf88 100644
--- a/pkgs/tools/networking/corkscrew/default.nix
+++ b/pkgs/tools/networking/corkscrew/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, automake }:
+{ lib, stdenv, fetchurl, automake }:
 
 stdenv.mkDerivation rec {
   name = "corkscrew-2.0";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
     ln -sf ${automake}/share/automake-*/config.guess config.guess
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://agroman.net/corkscrew/";
     description = "A tool for tunneling SSH through HTTP proxies";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/tools/networking/croc/default.nix b/pkgs/tools/networking/croc/default.nix
index 08eb3d69128bb..115f2f3216097 100644
--- a/pkgs/tools/networking/croc/default.nix
+++ b/pkgs/tools/networking/croc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, callPackage}:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, callPackage}:
 
 buildGoModule rec {
   pname = "croc";
@@ -22,7 +22,7 @@ buildGoModule rec {
       local-relay = callPackage ./test-local-relay.nix {};
     };
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Easily and securely send things from one computer to another";
     homepage = "https://github.com/schollz/croc";
diff --git a/pkgs/tools/networking/curl-unix-socket/default.nix b/pkgs/tools/networking/curl-unix-socket/default.nix
index b25e5dcab0b76..84b5c1861cd3a 100644
--- a/pkgs/tools/networking/curl-unix-socket/default.nix
+++ b/pkgs/tools/networking/curl-unix-socket/default.nix
@@ -1,4 +1,4 @@
-{ buildGoPackage, stdenv, fetchFromGitHub }:
+{ buildGoPackage, lib, stdenv, fetchFromGitHub }:
 
 buildGoPackage rec {
   name = "curl-unix-socket-2015-04-10";
@@ -21,7 +21,7 @@ buildGoPackage rec {
     runHook postBuild
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Run HTTP requests over UNIX socket";
     license = licenses.mit;
     homepage = "https://github.com/Soulou/curl-unix-socket";
diff --git a/pkgs/tools/networking/curl/default.nix b/pkgs/tools/networking/curl/default.nix
index 6f1c202a91cc5..a08ec75bfaa62 100644
--- a/pkgs/tools/networking/curl/default.nix
+++ b/pkgs/tools/networking/curl/default.nix
@@ -123,7 +123,7 @@ stdenv.mkDerivation rec {
     inherit sslSupport openssl;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line tool for transferring files with URL syntax";
     homepage    = "https://curl.haxx.se/";
     license = licenses.curl;
diff --git a/pkgs/tools/networking/cutter/default.nix b/pkgs/tools/networking/cutter/default.nix
index 2430e75430b09..8d94da7737b8c 100644
--- a/pkgs/tools/networking/cutter/default.nix
+++ b/pkgs/tools/networking/cutter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "cutter-1.04";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
     install -D -m 0755 cutter $out/bin/tcp-cutter
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TCP/IP Connection cutting on Linux Firewalls and Routers";
     homepage = "http://www.digitage.co.uk/digitage/software/linux-security/cutter";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/darkstat/default.nix b/pkgs/tools/networking/darkstat/default.nix
index af15e70aa86cb..04cab36557876 100644
--- a/pkgs/tools/networking/darkstat/default.nix
+++ b/pkgs/tools/networking/darkstat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap, zlib }:
+{ lib, stdenv, fetchurl, libpcap, zlib }:
 
 stdenv.mkDerivation rec {
   version = "3.0.719";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network statistics web interface";
     longDescription = ''
       Captures network traffic, calculates statistics about usage, and serves
diff --git a/pkgs/tools/networking/davix/default.nix b/pkgs/tools/networking/davix/default.nix
index ca9e7b033c511..8c88246577991 100644
--- a/pkgs/tools/networking/davix/default.nix
+++ b/pkgs/tools/networking/davix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, pkgconfig, openssl, libxml2, boost, python3, libuuid }:
+{ lib, stdenv, fetchurl, cmake, pkgconfig, openssl, libxml2, boost, python3, libuuid }:
 
 stdenv.mkDerivation rec {
   version = "0.7.6";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Toolkit for Http-based file management";
 
     longDescription = "Davix is a toolkit designed for file
diff --git a/pkgs/tools/networking/dd-agent/datadog-agent.nix b/pkgs/tools/networking/dd-agent/datadog-agent.nix
index c81192096927a..34e6395ca6d5b 100644
--- a/pkgs/tools/networking/dd-agent/datadog-agent.nix
+++ b/pkgs/tools/networking/dd-agent/datadog-agent.nix
@@ -68,7 +68,7 @@ in buildGoPackage rec {
       --prefix LD_LIBRARY_PATH : ${lib.getLib systemd}/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Event collector for the DataDog analysis service
       -- v6 new golang implementation.
diff --git a/pkgs/tools/networking/dd-agent/datadog-process-agent.nix b/pkgs/tools/networking/dd-agent/datadog-process-agent.nix
index a59f70f633b1a..a77030bba930e 100644
--- a/pkgs/tools/networking/dd-agent/datadog-process-agent.nix
+++ b/pkgs/tools/networking/dd-agent/datadog-process-agent.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage  }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage  }:
 
 buildGoPackage rec {
   pname = "datadog-process-agent";
@@ -15,7 +15,7 @@ buildGoPackage rec {
   goDeps = ./datadog-process-agent-deps.nix;
   goPackagePath = "github.com/${owner}/${repo}";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Live process collector for the DataDog Agent v6";
     homepage    = "https://www.datadoghq.com";
     license     = licenses.bsd3;
diff --git a/pkgs/tools/networking/ddclient/default.nix b/pkgs/tools/networking/ddclient/default.nix
index 375898913c8b6..3b52c2be25274 100644
--- a/pkgs/tools/networking/ddclient/default.nix
+++ b/pkgs/tools/networking/ddclient/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, iproute, perl }:
+{ lib, stdenv, fetchurl, perlPackages, iproute, perl }:
 
 perlPackages.buildPerlPackage rec {
   pname = "ddclient";
@@ -36,7 +36,7 @@ perlPackages.buildPerlPackage rec {
   # there are no tests distributed with ddclient
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client for updating dynamic DNS service entries";
     homepage    = "https://sourceforge.net/p/ddclient/wiki/Home/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/dhcp/default.nix b/pkgs/tools/networking/dhcp/default.nix
index 4a6eca8962491..55feb29af1d2f 100644
--- a/pkgs/tools/networking/dhcp/default.nix
+++ b/pkgs/tools/networking/dhcp/default.nix
@@ -73,7 +73,7 @@ stdenv.mkDerivation rec {
       export AR='${stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ar'
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynamic Host Configuration Protocol (DHCP) tools";
 
     longDescription = ''
diff --git a/pkgs/tools/networking/dhcpcd/default.nix b/pkgs/tools/networking/dhcpcd/default.nix
index 1a16645cc9b6e..3b55687ddd9ef 100644
--- a/pkgs/tools/networking/dhcpcd/default.nix
+++ b/pkgs/tools/networking/dhcpcd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, udev, runtimeShellPackage,
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, udev, runtimeShellPackage,
 runtimeShell }:
 
 stdenv.mkDerivation rec {
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
   # Check that the udev plugin got built.
   postInstall = stdenv.lib.optional (udev != null) "[ -e ${placeholder "out"}/lib/dhcpcd/dev/udev.so ]";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A client for the Dynamic Host Configuration Protocol (DHCP)";
     homepage = "https://roy.marples.name/projects/dhcpcd";
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/dhcpdump/default.nix b/pkgs/tools/networking/dhcpdump/default.nix
index f68d68382ddb2..dba08fea79568 100644
--- a/pkgs/tools/networking/dhcpdump/default.nix
+++ b/pkgs/tools/networking/dhcpdump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap, perl }:
+{ lib, stdenv, fetchurl, libpcap, perl }:
 
 stdenv.mkDerivation {
   name = "dhcpdump-1.8";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     cp dhcpdump $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for visualization of DHCP packets as recorded and output by tcpdump to analyze DHCP server responses";
     homepage = "http://www.mavetju.org/unix/dhcpdump-man.php";
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/dhcping/default.nix b/pkgs/tools/networking/dhcping/default.nix
index 36f81555495af..d4255d46096a0 100644
--- a/pkgs/tools/networking/dhcping/default.nix
+++ b/pkgs/tools/networking/dhcping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "dhcping";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Send DHCP request to find out if a DHCP server is running";
     longDescription = ''
       dhcping sends either a DHCPREQUEST or DHCPINFORM packet to the server
diff --git a/pkgs/tools/networking/dibbler/default.nix b/pkgs/tools/networking/dibbler/default.nix
index 1849890d23c2d..b8b40635a9691 100644
--- a/pkgs/tools/networking/dibbler/default.nix
+++ b/pkgs/tools/networking/dibbler/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "dibbler";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.isDarwin "-D__APPLE_USE_RFC_2292=1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Portable DHCPv6 implementation";
     homepage = "http://www.klub.com.pl/dhcpv6/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/djbdns/default.nix b/pkgs/tools/networking/djbdns/default.nix
index ca622a6244fcb..1b93d64d08f5b 100644
--- a/pkgs/tools/networking/djbdns/default.nix
+++ b/pkgs/tools/networking/djbdns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glibc, dns-root-data } :
+{ lib, stdenv, fetchurl, glibc, dns-root-data } :
 
 let
   version = "1.05";
@@ -41,7 +41,7 @@ stdenv.mkDerivation {
     rm -rv djbdns-man;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of Domain Name System tools";
     longDescription = "Includes software for all the fundamental DNS operations: DNS cache: finding addresses of Internet hosts; DNS server: publishing addresses of Internet hosts; and DNS client: talking to a DNS cache.";
     homepage = "https://cr.yp.to/djbdns.html";
diff --git a/pkgs/tools/networking/dnscrypt-proxy2/default.nix b/pkgs/tools/networking/dnscrypt-proxy2/default.nix
index 64a58bc15a96c..978b82c77fb78 100644
--- a/pkgs/tools/networking/dnscrypt-proxy2/default.nix
+++ b/pkgs/tools/networking/dnscrypt-proxy2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "dnscrypt-proxy2";
@@ -15,7 +15,7 @@ buildGoModule rec {
     sha256 = "08bg60j5z349blj5sip1f8f793q12ix3zmqkayym5nf69s1pfm7l";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool that provides secure DNS resolution";
 
     license = licenses.isc;
diff --git a/pkgs/tools/networking/dnscrypt-wrapper/default.nix b/pkgs/tools/networking/dnscrypt-wrapper/default.nix
index 5c44734665c9f..fdab2ff3003d7 100644
--- a/pkgs/tools/networking/dnscrypt-wrapper/default.nix
+++ b/pkgs/tools/networking/dnscrypt-wrapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libsodium, libevent }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, libsodium, libevent }:
 
 stdenv.mkDerivation rec {
   pname = "dnscrypt-wrapper";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig autoreconfHook ];
   buildInputs = [ libsodium libevent ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for adding dnscrypt support to any name resolver";
     homepage = "https://dnscrypt.info/";
     license = licenses.isc;
diff --git a/pkgs/tools/networking/dnsperf/default.nix b/pkgs/tools/networking/dnsperf/default.nix
index 68107f1932886..5aba2af865f38 100644
--- a/pkgs/tools/networking/dnsperf/default.nix
+++ b/pkgs/tools/networking/dnsperf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchurl, fetchFromGitHub, autoreconfHook, pkgconfig
 , openssl, ldns
 }:
 
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     cp ./dnsperf-src-*/doc/*.pdf "$doc/share/doc/dnsperf/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     outputsToInstall = outputs; # The man pages and docs are likely useful to most.
 
     description = "Tools for DNS benchmaring";
diff --git a/pkgs/tools/networking/dnsproxy/default.nix b/pkgs/tools/networking/dnsproxy/default.nix
index e7c30551dc9b9..3c51073570fb0 100644
--- a/pkgs/tools/networking/dnsproxy/default.nix
+++ b/pkgs/tools/networking/dnsproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 
 buildGoModule rec {
   pname = "dnsproxy";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple DNS proxy with DoH, DoT, and DNSCrypt support";
     homepage = "https://github.com/AdguardTeam/dnsproxy";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/dnstracer/default.nix b/pkgs/tools/networking/dnstracer/default.nix
index 558e0dca90345..53a3e32aa6c49 100644
--- a/pkgs/tools/networking/dnstracer/default.nix
+++ b/pkgs/tools/networking/dnstracer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libresolv, perl }:
+{ lib, stdenv, fetchurl, libresolv, perl }:
 
 stdenv.mkDerivation rec {
   version = "1.10";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = stdenv.lib.optionalString stdenv.isDarwin "-lresolv";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Determines where a given Domain Name Server (DNS) gets its information from, and follows the chain of DNS servers back to the servers which know the data";
     homepage = "http://www.mavetju.org/unix/general.php";
     license = licenses.bsd2;
diff --git a/pkgs/tools/networking/dogdns/default.nix b/pkgs/tools/networking/dogdns/default.nix
index 71e065e5d14c3..4e3b255fc55db 100644
--- a/pkgs/tools/networking/dogdns/default.nix
+++ b/pkgs/tools/networking/dogdns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , pkg-config
@@ -29,7 +29,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion completions/dog.{bash,fish,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line DNS client";
     homepage = "https://dns.lookup.dog";
     license = licenses.eupl12;
diff --git a/pkgs/tools/networking/drill/default.nix b/pkgs/tools/networking/drill/default.nix
index 176062ed314b3..7c1ba1928ec31 100644
--- a/pkgs/tools/networking/drill/default.nix
+++ b/pkgs/tools/networking/drill/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , pkg-config
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
     ++ stdenv.lib.optionals stdenv.isLinux [ openssl ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP load testing application inspired by Ansible syntax";
     homepage = "https://github.com/fcsonline/drill";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/dropbear/default.nix b/pkgs/tools/networking/dropbear/default.nix
index 605e95c9392a9..f922a70344c4e 100644
--- a/pkgs/tools/networking/dropbear/default.nix
+++ b/pkgs/tools/networking/dropbear/default.nix
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ zlib ] ++ lib.optionals enableStatic [ glibc.static zlib.static ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://matt.ucc.asn.au/dropbear/dropbear.html";
     description = "A small footprint implementation of the SSH 2 protocol";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/easyrsa/2.x.nix b/pkgs/tools/networking/easyrsa/2.x.nix
index fef2648de7fb9..52cf2082d63f4 100644
--- a/pkgs/tools/networking/easyrsa/2.x.nix
+++ b/pkgs/tools/networking/easyrsa/2.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, makeWrapper
+{ lib, stdenv, fetchurl, autoreconfHook, makeWrapper
 , gnugrep, openssl }:
 
 stdenv.mkDerivation {
@@ -28,7 +28,7 @@ stdenv.mkDerivation {
     sed -i "/EASY_RSA=\|OPENSSL=\|GREP=/d" $out/share/easy-rsa/vars
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple shell based CA utility";
     homepage = "https://openvpn.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/easyrsa/default.nix b/pkgs/tools/networking/easyrsa/default.nix
index 4568aec9c5d9c..34e326858fdcb 100644
--- a/pkgs/tools/networking/easyrsa/default.nix
+++ b/pkgs/tools/networking/easyrsa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, runtimeShell }:
+{ lib, stdenv, fetchFromGitHub, openssl, runtimeShell }:
 
 let
   version = "3.0.8";
@@ -32,7 +32,7 @@ in stdenv.mkDerivation {
     chmod +x $out/bin/easyrsa-init
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple shell based CA utility";
     homepage = "https://openvpn.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/eggdrop/default.nix b/pkgs/tools/networking/eggdrop/default.nix
index dc5bf1ef9760b..2db99bfa8280b 100644
--- a/pkgs/tools/networking/eggdrop/default.nix
+++ b/pkgs/tools/networking/eggdrop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, tcl }:
+{ lib, stdenv, fetchFromGitHub, tcl }:
 
 stdenv.mkDerivation rec {
   pname = "eggdrop";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     "--with-tclinc=${tcl}/include/tcl.h"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl2;
     platforms = platforms.unix;
     homepage = "http://www.eggheads.org";
diff --git a/pkgs/tools/networking/eternal-terminal/default.nix b/pkgs/tools/networking/eternal-terminal/default.nix
index fdad966c81b65..78884a23cbbd6 100644
--- a/pkgs/tools/networking/eternal-terminal/default.nix
+++ b/pkgs/tools/networking/eternal-terminal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , gflags
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ gflags libsodium protobuf ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Remote shell that automatically reconnects without interrupting the session";
     license = licenses.asl20;
     homepage = "https://mistertea.github.io/EternalTerminal/";
diff --git a/pkgs/tools/networking/fakeroute/default.nix b/pkgs/tools/networking/fakeroute/default.nix
index 2bfecc389d5f4..025eef72332f8 100644
--- a/pkgs/tools/networking/fakeroute/default.nix
+++ b/pkgs/tools/networking/fakeroute/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "fakeroute";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1sp342rxgm1gz4mvi5vvz1knz7kn9px9s39ii3jdjp4ks7lr5c8f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       Makes your machine appear to be anywhere on the internet
       to any host running a (UDP) unix traceroute
diff --git a/pkgs/tools/networking/fastd/default.nix b/pkgs/tools/networking/fastd/default.nix
index 864b57a0c3830..d57d9fc635b27 100644
--- a/pkgs/tools/networking/fastd/default.nix
+++ b/pkgs/tools/networking/fastd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bison, meson, ninja, pkgconfig
+{ lib, stdenv, fetchFromGitHub, bison, meson, ninja, pkgconfig
 , libuecc, libsodium, libcap, json_c, openssl }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and Secure Tunneling Daemon";
     homepage = "https://projects.universe-factory.net/projects/fastd/wiki";
     license = with licenses; [ bsd2 bsd3 ];
diff --git a/pkgs/tools/networking/fdm/default.nix b/pkgs/tools/networking/fdm/default.nix
index cb5a781f5efac..608b669535d46 100644
--- a/pkgs/tools/networking/fdm/default.nix
+++ b/pkgs/tools/networking/fdm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, openssl, tdb, zlib, flex, bison }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, openssl, tdb, zlib, flex, bison }:
 
 stdenv.mkDerivation rec {
   pname = "fdm";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ openssl tdb zlib flex bison ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mail fetching and delivery tool - should do the job of getmail and procmail";
     maintainers = with maintainers; [ ninjin raskin ];
     platforms = with platforms; linux;
diff --git a/pkgs/tools/networking/filegive/default.nix b/pkgs/tools/networking/filegive/default.nix
index bedb97200c127..3ed250ca4bcd9 100644
--- a/pkgs/tools/networking/filegive/default.nix
+++ b/pkgs/tools/networking/filegive/default.nix
@@ -1,4 +1,4 @@
-{ buildGoPackage, stdenv, fetchurl }:
+{ buildGoPackage, lib, stdenv, fetchurl }:
 
 buildGoPackage rec {
   name = "filegive-0.7.4";
@@ -12,7 +12,7 @@ buildGoPackage rec {
 
   goPackagePath = "viric.name/soft/filegive";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://viric.name/cgi-bin/filegive";
     description = "Easy p2p file sending program";
     license = licenses.agpl3Plus;
diff --git a/pkgs/tools/networking/fping/default.nix b/pkgs/tools/networking/fping/default.nix
index d170ee4cd0e3f..7974fdd244bd6 100644
--- a/pkgs/tools/networking/fping/default.nix
+++ b/pkgs/tools/networking/fping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "fping-5.0";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--enable-ipv6" "--enable-ipv4" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://fping.org/";
     description = "Send ICMP echo probes to network hosts";
     license = licenses.bsd0;
diff --git a/pkgs/tools/networking/freebind/default.nix b/pkgs/tools/networking/freebind/default.nix
index c1dc3d8fd5f8f..5ba462f15b249 100644
--- a/pkgs/tools/networking/freebind/default.nix
+++ b/pkgs/tools/networking/freebind/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libnetfilter_queue, libnfnetlink }:
+{ lib, stdenv, fetchFromGitHub, libnetfilter_queue, libnfnetlink }:
 
 stdenv.mkDerivation {
   pname = "freebind";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     mkdir -p $out/bin $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IPv4 and IPv6 address rate limiting evasion tool";
     homepage = "https://github.com/blechschmidt/freebind";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/gandi-cli/default.nix b/pkgs/tools/networking/gandi-cli/default.nix
index b323cde28bc28..e66d5b7c2a5ba 100644
--- a/pkgs/tools/networking/gandi-cli/default.nix
+++ b/pkgs/tools/networking/gandi-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 with python3Packages;
 
@@ -17,7 +17,7 @@ buildPythonApplication rec {
 
   doCheck = false;    # Tests try to contact the actual remote API
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line interface to the public Gandi.net API";
     homepage = "https://cli.gandi.net/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/networking/gmrender-resurrect/default.nix b/pkgs/tools/networking/gmrender-resurrect/default.nix
index 8a8ed25a5a62e..843c53a7ad596 100644
--- a/pkgs/tools/networking/gmrender-resurrect/default.nix
+++ b/pkgs/tools/networking/gmrender-resurrect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pkgconfig, makeWrapper, gstreamer
+{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pkgconfig, makeWrapper, gstreamer
 , gst-plugins-base, gst-plugins-good, gst-plugins-bad, gst-plugins-ugly, gst-libav, libupnp }:
 
 let
@@ -36,7 +36,7 @@ in
       done
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Resource efficient UPnP/DLNA renderer, optimal for Raspberry Pi, CuBox or a general MediaServer";
       homepage = "https://github.com/hzeller/gmrender-resurrect";
       license = licenses.gpl2;
diff --git a/pkgs/tools/networking/gnirehtet/default.nix b/pkgs/tools/networking/gnirehtet/default.nix
index 8d7d2392dfb75..193a0b9e0fb54 100644
--- a/pkgs/tools/networking/gnirehtet/default.nix
+++ b/pkgs/tools/networking/gnirehtet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, fetchzip, androidenv, makeWrapper }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, fetchzip, androidenv, makeWrapper }:
 let
 version = "2.5";
 apk = stdenv.mkDerivation {
@@ -35,7 +35,7 @@ rustPlatform.buildRustPackage {
     --set ADB ${androidenv.androidPkgs_9_0.platform-tools}/bin/adb
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reverse tethering over adb for Android";
     longDescription = ''
       This project provides reverse tethering over adb for Android: it allows devices to use the internet connection of the computer they are plugged on. It does not require any root access (neither on the device nor on the computer).
diff --git a/pkgs/tools/networking/go-shadowsocks2/default.nix b/pkgs/tools/networking/go-shadowsocks2/default.nix
index 6b55c21b5b04f..fe2285df22cc4 100644
--- a/pkgs/tools/networking/go-shadowsocks2/default.nix
+++ b/pkgs/tools/networking/go-shadowsocks2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "go-shadowsocks2";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fresh implementation of Shadowsocks in Go";
     homepage = "https://github.com/shadowsocks/go-shadowsocks2/";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/goklp/default.nix b/pkgs/tools/networking/goklp/default.nix
index 534a809e46af4..78117a700bd35 100644
--- a/pkgs/tools/networking/goklp/default.nix
+++ b/pkgs/tools/networking/goklp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "goklp";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Golang OpenSSH Keys Ldap Provider for AuthorizedKeysCommand";
     homepage = "https://github.com/AppliedTrust/goklp";
     maintainers = with maintainers; [ disassembler ];
diff --git a/pkgs/tools/networking/gupnp-tools/default.nix b/pkgs/tools/networking/gupnp-tools/default.nix
index c93873caa07f3..bace27f3d8dc4 100644
--- a/pkgs/tools/networking/gupnp-tools/default.nix
+++ b/pkgs/tools/networking/gupnp-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of utilities and demos to work with UPnP";
     homepage = "https://wiki.gnome.org/Projects/GUPnP";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/gvpe/default.nix b/pkgs/tools/networking/gvpe/default.nix
index 3dea0217b60d4..788d61e9ca95e 100644
--- a/pkgs/tools/networking/gvpe/default.nix
+++ b/pkgs/tools/networking/gvpe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, gmp, zlib, iproute, nettools }:
+{ lib, stdenv, fetchurl, openssl, gmp, zlib, iproute, nettools }:
 
 stdenv.mkDerivation rec {
   pname = "gvpe";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     sed -e 's@/sbin/ifconfig@${nettools}/sbin/ifconfig@g' -i src/device-*.C
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A protected multinode virtual network";
     homepage = "http://software.schmorp.de/pkg/gvpe.html";
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/tools/networking/hans/default.nix b/pkgs/tools/networking/hans/default.nix
index cea13bca24c3c..04271d6ef7105 100644
--- a/pkgs/tools/networking/hans/default.nix
+++ b/pkgs/tools/networking/hans/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nettools }:
+{ lib, stdenv, fetchFromGitHub, nettools }:
 
 stdenv.mkDerivation rec {
   pname = "hans";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     install -D -m0755 hans $out/bin/hans
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tunnel IPv4 over ICMP";
     longDescription = ''
       Hans makes it possible to tunnel IPv4 through ICMP echo packets, so you
diff --git a/pkgs/tools/networking/horst/default.nix b/pkgs/tools/networking/horst/default.nix
index 704eaa85cd04a..66cb883f5aa12 100644
--- a/pkgs/tools/networking/horst/default.nix
+++ b/pkgs/tools/networking/horst/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, pkgconfig, ncurses, libnl }:
+{lib, stdenv, fetchFromGitHub, pkgconfig, ncurses, libnl }:
 
 stdenv.mkDerivation rec {
   pname = "horst";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "DESTDIR=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small and lightweight IEEE802.11 wireless LAN analyzer with a text interface";
     homepage = "http://br1.einfach.org/tech/horst/";
     maintainers = [ maintainers.fpletz ];
diff --git a/pkgs/tools/networking/hping/default.nix b/pkgs/tools/networking/hping/default.nix
index daa0ba38e9ee7..5d8b6ab37e849 100644
--- a/pkgs/tools/networking/hping/default.nix
+++ b/pkgs/tools/networking/hping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpcap, withTcl ? true, tcl }:
+{ lib, stdenv, fetchFromGitHub, libpcap, withTcl ? true, tcl }:
 
 stdenv.mkDerivation rec {
   pname = "hping";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     ln -s hping3.8.gz $out/share/man/man8/hping2.8.gz
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command-line oriented TCP/IP packet assembler/analyzer";
     homepage = "http://www.hping.org/";
     license = licenses.gpl2Only;
diff --git a/pkgs/tools/networking/htpdate/default.nix b/pkgs/tools/networking/htpdate/default.nix
index d03b08cf5eb5e..cd2b3a18d4215 100644
--- a/pkgs/tools/networking/htpdate/default.nix
+++ b/pkgs/tools/networking/htpdate/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "1.2.2";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility to fetch time and set the system clock over HTTP";
     homepage = "http://www.vervest.org/htp/";
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/http-prompt/default.nix b/pkgs/tools/networking/http-prompt/default.nix
index 9c524c0cc090a..59a3bffdc6db6 100644
--- a/pkgs/tools/networking/http-prompt/default.nix
+++ b/pkgs/tools/networking/http-prompt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages, httpie }:
+{ lib, stdenv, fetchFromGitHub, python3Packages, httpie }:
 
 python3Packages.buildPythonApplication rec {
   pname = "http-prompt";
@@ -24,7 +24,7 @@ python3Packages.buildPythonApplication rec {
     $out/bin/${pname} --version | grep -q "${version}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interactive command-line HTTP client featuring autocomplete and syntax highlighting";
     homepage = "https://github.com/eliangcs/http-prompt";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/httperf/default.nix b/pkgs/tools/networking/httperf/default.nix
index 50c35fbb33c1d..f5c888dc4bb6a 100644
--- a/pkgs/tools/networking/httperf/default.nix
+++ b/pkgs/tools/networking/httperf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, openssl }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "httperf";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     mv -v src/httperf $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The httperf HTTP load generator";
     homepage = "https://github.com/httperf/httperf";
     maintainers = with maintainers; [ nand0p ];
diff --git a/pkgs/tools/networking/httping/default.nix b/pkgs/tools/networking/httping/default.nix
index 74aff38e1a609..7389c78ef8db6 100644
--- a/pkgs/tools/networking/httping/default.nix
+++ b/pkgs/tools/networking/httping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gettext, libintl, ncurses, openssl
+{ lib, stdenv, fetchurl, gettext, libintl, ncurses, openssl
 , fftw ? null }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "PREFIX="
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://vanheusden.com/httping";
     description = "ping with HTTP requests";
     longDescription = ''
diff --git a/pkgs/tools/networking/httplab/default.nix b/pkgs/tools/networking/httplab/default.nix
index f4fb4fe960764..22dc500fd4cd0 100644
--- a/pkgs/tools/networking/httplab/default.nix
+++ b/pkgs/tools/networking/httplab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "httplab";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "0442nnpxyfl2gi9pilv7q6cxs2cd98wblg8d4nw6dx98yh4h99zs";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gchaincl/httplab";
     description = "Interactive WebServer";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/httplz/default.nix b/pkgs/tools/networking/httplz/default.nix
index bf0a5b9038880..3932bbd08cf8e 100644
--- a/pkgs/tools/networking/httplz/default.nix
+++ b/pkgs/tools/networking/httplz/default.nix
@@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec {
       --prefix PATH : "${openssl}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A basic http server for hosting a folder fast and simply";
     homepage = "https://github.com/thecoshman/http";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/httptunnel/default.nix b/pkgs/tools/networking/httptunnel/default.nix
index e8ed86da3da35..13ef641753586 100644
--- a/pkgs/tools/networking/httptunnel/default.nix
+++ b/pkgs/tools/networking/httptunnel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "3.3";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0mn5s6p68n32xzadz6ds5i6bp44dyxzkq68r1yljlv470jr84bql";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Creates a bidirectional virtual data connection tunnelled in HTTP requests";
     homepage    = "http://www.nocrew.org/software/httptunnel";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/networking/i2p/default.nix b/pkgs/tools/networking/i2p/default.nix
index 5c209393978f0..a3b52d19e2dcf 100644
--- a/pkgs/tools/networking/i2p/default.nix
+++ b/pkgs/tools/networking/i2p/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, ps, coreutils, fetchurl, jdk, jre, ant, gettext, which }:
+{ lib, stdenv, ps, coreutils, fetchurl, jdk, jre, ant, gettext, which }:
 
 let wrapper = stdenv.mkDerivation rec {
   pname = "wrapper";
@@ -72,7 +72,7 @@ stdenv.mkDerivation rec {
     rm $out/{osid,postinstall.sh,INSTALL-headless.txt}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Applications and router for I2P, anonymity over the Internet";
     homepage = "https://geti2p.net";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/i2pd/default.nix b/pkgs/tools/networking/i2pd/default.nix
index 8bf90293a8ecf..873ecf03bbb1d 100644
--- a/pkgs/tools/networking/i2pd/default.nix
+++ b/pkgs/tools/networking/i2pd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , boost, zlib, openssl
 , upnpSupport ? true, miniupnpc ? null
 , aesniSupport ? stdenv.hostPlatform.aesSupport
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     install -D i2pd $out/bin/i2pd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://i2pd.website";
     description = "Minimal I2P router written in C++";
     license = licenses.bsd3;
diff --git a/pkgs/tools/networking/ifstat-legacy/default.nix b/pkgs/tools/networking/ifstat-legacy/default.nix
index 25b6af5e92f4d..8383f82fd93c4 100644
--- a/pkgs/tools/networking/ifstat-legacy/default.nix
+++ b/pkgs/tools/networking/ifstat-legacy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, net-snmp }:
+{ lib, stdenv, fetchurl, autoreconfHook, net-snmp }:
 
 stdenv.mkDerivation rec {
   pname = "ifstat-legacy";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     mv $out/share/man/man1/ifstat.1 $out/share/man/man1/ifstat-legacy.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Report network interfaces bandwith just like vmstat/iostat do for other system counters - legacy version";
     homepage    = "http://gael.roualland.free.fr/ifstat/";
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/tools/networking/iftop/default.nix b/pkgs/tools/networking/iftop/default.nix
index 70c1f0b6c965f..900a740c7246b 100644
--- a/pkgs/tools/networking/iftop/default.nix
+++ b/pkgs/tools/networking/iftop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, libpcap, automake, nixosTests }:
+{ lib, stdenv, fetchurl, ncurses, libpcap, automake, nixosTests }:
 
 stdenv.mkDerivation {
   name = "iftop-1.0pre4";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
 
   passthru.tests = { inherit (nixosTests) iftop; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Display bandwidth usage on a network interface";
     longDescription = ''
       iftop does for network usage what top(1) does for CPU usage. It listens
diff --git a/pkgs/tools/networking/igmpproxy/default.nix b/pkgs/tools/networking/igmpproxy/default.nix
index 83b35c0986694..0c4279b6f6492 100644
--- a/pkgs/tools/networking/igmpproxy/default.nix
+++ b/pkgs/tools/networking/igmpproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "igmpproxy";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon that routes multicast using IGMP forwarding";
     homepage = "https://github.com/pali/igmpproxy/";
     changelog = "https://github.com/pali/igmpproxy/releases/tag/${version}";
diff --git a/pkgs/tools/networking/imapsync/default.nix b/pkgs/tools/networking/imapsync/default.nix
index aa0980a2514e8..bec0b197c184e 100644
--- a/pkgs/tools/networking/imapsync/default.nix
+++ b/pkgs/tools/networking/imapsync/default.nix
@@ -1,4 +1,4 @@
-{stdenv, makeWrapper, fetchurl, perl, openssl, perlPackages }:
+{lib, stdenv, makeWrapper, fetchurl, perl, openssl, perlPackages }:
 
 stdenv.mkDerivation rec {
   name = "imapsync-1.727";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     IOSocketInet6 NTLM
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.linux-france.org/prj/imapsync/";
     description = "Mail folder synchronizer between IMAP servers";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/inadyn/default.nix b/pkgs/tools/networking/inadyn/default.nix
index f01bffa76da5c..2cb04c1b2101f 100644
--- a/pkgs/tools/networking/inadyn/default.nix
+++ b/pkgs/tools/networking/inadyn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , gnutls, libite, libconfuse }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://troglobit.com/project/inadyn/";
     description = "Free dynamic DNS client";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/iouyap/default.nix b/pkgs/tools/networking/iouyap/default.nix
index b49b34d6dc7aa..2367261b52239 100644
--- a/pkgs/tools/networking/iouyap/default.nix
+++ b/pkgs/tools/networking/iouyap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bison, flex }:
+{ lib, stdenv, fetchFromGitHub, bison, flex }:
 
 stdenv.mkDerivation rec {
   pname = "iouyap";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -D -m555 iouyap $out/bin/iouyap;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bridge IOU to UDP, TAP and Ethernet";
     inherit (src.meta) homepage;
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/networking/ip2location/default.nix b/pkgs/tools/networking/ip2location/default.nix
index 205a4e6e70150..df5d26b4f5dbd 100644
--- a/pkgs/tools/networking/ip2location/default.nix
+++ b/pkgs/tools/networking/ip2location/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "ip2location";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Look up locations of host names and IP addresses";
     longDescription = ''
       A command-line tool to find the country, region, city,coordinates,
diff --git a/pkgs/tools/networking/iperf/2.nix b/pkgs/tools/networking/iperf/2.nix
index f90b74313e505..3270a25e67b2d 100644
--- a/pkgs/tools/networking/iperf/2.nix
+++ b/pkgs/tools/networking/iperf/2.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "iperf-2.0.13";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     ln -s $out/bin/iperf2 $out/bin/iperf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/iperf/";
     description = "Tool to measure IP bandwidth using UDP or TCP";
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/iperf/3.nix b/pkgs/tools/networking/iperf/3.nix
index 2ca924731466e..aa9316642dd5a 100644
--- a/pkgs/tools/networking/iperf/3.nix
+++ b/pkgs/tools/networking/iperf/3.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, fetchpatch }:
+{ lib, stdenv, fetchurl, openssl, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "iperf";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     ln -s $man/share/man/man1/iperf3.1 $man/share/man/man1/iperf.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://software.es.net/iperf/";
     description = "Tool to measure IP bandwidth using UDP or TCP";
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/ipgrep/default.nix b/pkgs/tools/networking/ipgrep/default.nix
index d9fc41e94b6f7..dd85a5dcb617b 100644
--- a/pkgs/tools/networking/ipgrep/default.nix
+++ b/pkgs/tools/networking/ipgrep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   version = "1.0.1";
@@ -25,7 +25,7 @@ python3Packages.buildPythonApplication rec {
     requests
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extract, defang, resolve names and IPs from text";
     longDescription = ''
       ipgrep extracts possibly obfuscated host names and IP addresses
diff --git a/pkgs/tools/networking/ipv6calc/default.nix b/pkgs/tools/networking/ipv6calc/default.nix
index 35aeb23a9a830..47b8abe54d334 100644
--- a/pkgs/tools/networking/ipv6calc/default.nix
+++ b/pkgs/tools/networking/ipv6calc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, getopt, ip2location-c, openssl, perl
+{ lib, stdenv, fetchurl, getopt, ip2location-c, openssl, perl
 , libmaxminddb ? null, geolite-legacy ? null }:
 
 stdenv.mkDerivation rec {
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calculate/manipulate (not only) IPv6 addresses";
     longDescription = ''
       ipv6calc is a small utility to manipulate (not only) IPv6 addresses and
diff --git a/pkgs/tools/networking/isync/default.nix b/pkgs/tools/networking/isync/default.nix
index 44eb5c50ba802..365a0669e42de 100644
--- a/pkgs/tools/networking/isync/default.nix
+++ b/pkgs/tools/networking/isync/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkg-config, perl
+{ lib, stdenv, fetchurl, pkg-config, perl
 , openssl, db, zlib, cyrus_sasl
 }:
 
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkg-config perl ];
   buildInputs = [ openssl db cyrus_sasl zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://isync.sourceforge.net/";
     # https://sourceforge.net/projects/isync/
     changelog = "https://sourceforge.net/p/isync/isync/ci/v${version}/tree/NEWS";
diff --git a/pkgs/tools/networking/kail/default.nix b/pkgs/tools/networking/kail/default.nix
index 497afb459ef08..2ddcd6c7d4bfa 100644
--- a/pkgs/tools/networking/kail/default.nix
+++ b/pkgs/tools/networking/kail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "kail";
@@ -23,7 +23,7 @@ buildGoPackage rec {
   deleteVendor = true;
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kubernetes log viewer";
     homepage = "https://github.com/boz/kail";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/kea/default.nix b/pkgs/tools/networking/kea/default.nix
index 1637827f66ea5..6b3640919466b 100644
--- a/pkgs/tools/networking/kea/default.nix
+++ b/pkgs/tools/networking/kea/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig, openssl, botan2, log4cplus
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig, openssl, botan2, log4cplus
 , boost, python3, postgresql, libmysqlclient, gmp, bzip2 }:
 
 let inherit (stdenv) lib; in
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kea.isc.org/";
     description = "High-performance, extensible DHCP server by ISC";
     longDescription = ''
diff --git a/pkgs/tools/networking/keepalived/default.nix b/pkgs/tools/networking/keepalived/default.nix
index b773e116d8bee..604a30a0ba7b7 100644
--- a/pkgs/tools/networking/keepalived/default.nix
+++ b/pkgs/tools/networking/keepalived/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, nixosTests
+{ lib, stdenv, fetchFromGitHub, nixosTests
 , libnfnetlink, libnl, net-snmp, openssl
 , pkgconfig, autoreconfHook }:
 
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     "--enable-snmp"
  ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://keepalived.org";
     description = "Routing software written in C";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/lftp/default.nix b/pkgs/tools/networking/lftp/default.nix
index 53568615a6246..d356601a93403 100644
--- a/pkgs/tools/networking/lftp/default.nix
+++ b/pkgs/tools/networking/lftp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gnutls, pkgconfig, readline, zlib, libidn2, gmp, libiconv, libunistring, gettext }:
+{ lib, stdenv, fetchurl, gnutls, pkgconfig, readline, zlib, libidn2, gmp, libiconv, libunistring, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "lftp";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A file transfer program supporting a number of network protocols";
     homepage = "https://lftp.tech/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/libnids/default.nix b/pkgs/tools/networking/libnids/default.nix
index 2a93d3c8a5989..aff451ab44a0a 100644
--- a/pkgs/tools/networking/libnids/default.nix
+++ b/pkgs/tools/networking/libnids/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, libpcap, glib, pkgconfig, libnet }:
+{ lib, stdenv, fetchzip, libpcap, glib, pkgconfig, libnet }:
 stdenv.mkDerivation {
   pname = "libnids";
   version = "1.24";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
   */
   NIX_CFLAGS_COMPILE="-Dg_thread_init= ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An E-component of Network Intrusion Detection System which emulates the IP stack of Linux 2.0.x";
     homepage = "http://libnids.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/libreswan/default.nix b/pkgs/tools/networking/libreswan/default.nix
index 7e6f2c475ca5f..1281f1b212977 100644
--- a/pkgs/tools/networking/libreswan/default.nix
+++ b/pkgs/tools/networking/libreswan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper,
+{ lib, stdenv, fetchurl, makeWrapper,
   pkgconfig, systemd, gmp, unbound, bison, flex, pam, libevent, libcap_ng, curl, nspr,
   bash, iproute, iptables, procps, coreutils, gnused, gawk, nss, which, python,
   docs ? false, xmlto, libselinux, ldns
@@ -83,7 +83,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://libreswan.org";
     description = "A free software implementation of the VPN protocol based on IPSec and the Internet Key Exchange";
     platforms = platforms.linux ++ platforms.freebsd;
diff --git a/pkgs/tools/networking/logmein-hamachi/default.nix b/pkgs/tools/networking/logmein-hamachi/default.nix
index 4abe083a0b9cc..82cd9ec3f12fc 100644
--- a/pkgs/tools/networking/logmein-hamachi/default.nix
+++ b/pkgs/tools/networking/logmein-hamachi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 with stdenv.lib;
 
@@ -35,7 +35,7 @@ in stdenv.mkDerivation rec {
   dontStrip = true;
   dontPatchELF = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A hosted VPN service that lets you securely extend LAN-like networks to distributed teams";
     homepage = "https://secure.logmein.com/products/hamachi/";
     license = licenses.unfreeRedistributable;
diff --git a/pkgs/tools/networking/maildrop/default.nix b/pkgs/tools/networking/maildrop/default.nix
index d0a74fe4b5bfa..d9fb58685b688 100644
--- a/pkgs/tools/networking/maildrop/default.nix
+++ b/pkgs/tools/networking/maildrop/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, pkgconfig, pcre, perl }:
+{ fetchurl, lib, stdenv, pkgconfig, pcre, perl }:
 
 stdenv.mkDerivation {
   name = "maildrop-2.6.0";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
 
   doCheck = false; # fails with "setlocale: LC_ALL: cannot change locale (en_US.UTF-8)"
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.courier-mta.org/maildrop/";
     description = "Mail filter/mail delivery agent that is used by the Courier Mail Server";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/mailutils/default.nix b/pkgs/tools/networking/mailutils/default.nix
index ff7d4176bd2eb..0cc289d0149f8 100644
--- a/pkgs/tools/networking/mailutils/default.nix
+++ b/pkgs/tools/networking/mailutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, autoreconfHook, dejagnu, gettext, pkgconfig
+{ lib, stdenv, fetchurl, fetchpatch, autoreconfHook, dejagnu, gettext, pkgconfig
 , gdbm, pam, readline, ncurses, gnutls, guile, texinfo, gnum4, sasl, fribidi, nettools
 , python3, gss, libmysqlclient, system-sendmail }:
 
@@ -90,7 +90,7 @@ stdenv.mkDerivation rec {
     unset LD_LIBRARY_PATH
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Rich and powerful protocol-independent mail framework";
 
     longDescription = ''
diff --git a/pkgs/tools/networking/maxscale/default.nix b/pkgs/tools/networking/maxscale/default.nix
index 9036e07e7f3f1..38ac35c342d0d 100644
--- a/pkgs/tools/networking/maxscale/default.nix
+++ b/pkgs/tools/networking/maxscale/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, glibc
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, glibc
 , bison, curl, flex, gperftools, jansson, jemalloc, kerberos, lua, libmysqlclient
 , ncurses, openssl, pcre, pcre2, perl, rabbitmq-c, sqlite, tcl
 , libaio, libedit, libtool, libui, libuuid, zlib
@@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/{etc,var}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
      description = "MaxScale database proxy extends MariaDB Server's high availability";
      homepage = "https://mariadb.com/products/technology/maxscale";
      license = licenses.bsl11;
diff --git a/pkgs/tools/networking/megatools/default.nix b/pkgs/tools/networking/megatools/default.nix
index 2a957c8a3f412..829ba028fd5ae 100644
--- a/pkgs/tools/networking/megatools/default.nix
+++ b/pkgs/tools/networking/megatools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, pkg-config, glib, fuse, curl, glib-networking
+{ lib, stdenv, fetchgit, autoreconfHook, pkg-config, glib, fuse, curl, glib-networking
 , asciidoc, libxml2, docbook_xsl, docbook_xml_dtd_45, libxslt, wrapGAppsNoGuiHook }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line client for Mega.co.nz";
     homepage = "https://megatools.megous.com/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/minidlna/default.nix b/pkgs/tools/networking/minidlna/default.nix
index d425e16782b39..df194ccaaaa94 100644
--- a/pkgs/tools/networking/minidlna/default.nix
+++ b/pkgs/tools/networking/minidlna/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ffmpeg_3, flac, libvorbis, libogg, libid3tag, libexif, libjpeg, sqlite, gettext }:
+{ lib, stdenv, fetchurl, ffmpeg_3, flac, libvorbis, libogg, libid3tag, libexif, libjpeg, sqlite, gettext }:
 
 let version = "1.3.0"; in
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     cp minidlnad.8 $out/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Media server software";
     longDescription = ''
       MiniDLNA (aka ReadyDLNA) is server software with the aim of being fully
diff --git a/pkgs/tools/networking/minio-client/default.nix b/pkgs/tools/networking/minio-client/default.nix
index e452719a494a1..51ea6e1a0b391 100644
--- a/pkgs/tools/networking/minio-client/default.nix
+++ b/pkgs/tools/networking/minio-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "minio-client";
@@ -23,7 +23,7 @@ buildGoModule rec {
     sed -i "s/CommitID.*/CommitID = \"${src.rev}\"/g" cmd/build-constants.go
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/minio/mc";
     description = "A replacement for ls, cp, mkdir, diff and rsync commands for filesystems and object storage";
     maintainers = with maintainers; [ eelco bachp ];
diff --git a/pkgs/tools/networking/minissdpd/default.nix b/pkgs/tools/networking/minissdpd/default.nix
index b5702b9bfaddd..869abe92e5c2a 100644
--- a/pkgs/tools/networking/minissdpd/default.nix
+++ b/pkgs/tools/networking/minissdpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libnfnetlink }:
+{ lib, stdenv, fetchurl, libnfnetlink }:
 
 stdenv.mkDerivation rec {
   pname = "minissdpd";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small daemon to speed up UPnP device discoveries";
     longDescription = ''
       MiniSSDPd receives NOTIFY packets and stores (caches) that information
diff --git a/pkgs/tools/networking/miniupnpc/default.nix b/pkgs/tools/networking/miniupnpc/default.nix
index 41927278ac82d..152a0b0df66b2 100644
--- a/pkgs/tools/networking/miniupnpc/default.nix
+++ b/pkgs/tools/networking/miniupnpc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, cctools }:
+{ lib, stdenv, fetchurl, which, cctools }:
 
 let
   generic = { version, sha256 }:
@@ -19,7 +19,7 @@ let
 
       makeFlags = [ "PREFIX=$(out)" "INSTALLPREFIX=$(out)" ];
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "http://miniupnp.free.fr/";
         description = "A client that implements the UPnP Internet Gateway Device (IGD) specification";
         platforms = with platforms; linux ++ freebsd ++ darwin;
diff --git a/pkgs/tools/networking/miniupnpd/default.nix b/pkgs/tools/networking/miniupnpd/default.nix
index 23f02dde1f42a..fe15d8bd32828 100644
--- a/pkgs/tools/networking/miniupnpd/default.nix
+++ b/pkgs/tools/networking/miniupnpd/default.nix
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://miniupnp.free.fr/";
     description = "A daemon that implements the UPnP Internet Gateway Device (IGD) specification";
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/miredo/default.nix b/pkgs/tools/networking/miredo/default.nix
index 1982cab6b3953..48b6f5dc4cf59 100644
--- a/pkgs/tools/networking/miredo/default.nix
+++ b/pkgs/tools/networking/miredo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nettools, iproute, judy }:
+{ lib, stdenv, fetchurl, nettools, iproute, judy }:
 
 stdenv.mkDerivation rec {
   version = "1.2.6";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/lib/systemd $out/var $out/etc/miredo/miredo.conf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Teredo IPv6 Tunneling Daemon";
     homepage = "https://www.remlab.net/miredo/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/mmsd/default.nix b/pkgs/tools/networking/mmsd/default.nix
index fee347dd20159..ccc99457d9b3b 100644
--- a/pkgs/tools/networking/mmsd/default.nix
+++ b/pkgs/tools/networking/mmsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , autoreconfHook
 , pkgconfig
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multimedia Messaging Service Daemon";
     homepage = "https://01.org/ofono";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/modem-manager/default.nix b/pkgs/tools/networking/modem-manager/default.nix
index 7bad593e4dfa4..248cd59fe12e3 100644
--- a/pkgs/tools/networking/modem-manager/default.nix
+++ b/pkgs/tools/networking/modem-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, glib, udev, libgudev, polkit, ppp, gettext, pkgconfig
+{ lib, stdenv, fetchurl, glib, udev, libgudev, polkit, ppp, gettext, pkgconfig
 , libmbim, libqmi, systemd, vala, gobject-introspection, dbus }:
 
 stdenv.mkDerivation rec {
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WWAN modem manager, part of NetworkManager";
     homepage = "https://www.freedesktop.org/wiki/Software/ModemManager/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/mozwire/default.nix b/pkgs/tools/networking/mozwire/default.nix
index 58afc833ea0ef..532d69c3f4ee6 100644
--- a/pkgs/tools/networking/mozwire/default.nix
+++ b/pkgs/tools/networking/mozwire/default.nix
@@ -1,4 +1,4 @@
-{ rustPlatform, stdenv, fetchFromGitHub, Security }:
+{ rustPlatform, lib, stdenv, fetchFromGitHub, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "MozWire";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0yxnpnxwis46wz4j5rjzyyzrvh94hn8vzxmmrcmrdz3gkakg77hg";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MozillaVPN configuration manager giving Linux, macOS users (among others), access to MozillaVPN";
     homepage = "https://github.com/NilsIrl/MozWire";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/mpack/default.nix b/pkgs/tools/networking/mpack/default.nix
index 5a8af7de36a00..3aca81596e08c 100644
--- a/pkgs/tools/networking/mpack/default.nix
+++ b/pkgs/tools/networking/mpack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "mpack-1.6";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for encoding and decoding binary files in MIME";
     license = licenses.free;
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/mtr/default.nix b/pkgs/tools/networking/mtr/default.nix
index 6b8b2f9237453..0ebeb8410a680 100644
--- a/pkgs/tools/networking/mtr/default.nix
+++ b/pkgs/tools/networking/mtr/default.nix
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A network diagnostics tool";
     homepage    = "https://www.bitwizard.nl/mtr/";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/networking/mu/default.nix b/pkgs/tools/networking/mu/default.nix
index 82a22dd947d7b..3b505d34f2a0e 100644
--- a/pkgs/tools/networking/mu/default.nix
+++ b/pkgs/tools/networking/mu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, sqlite, pkgconfig, autoreconfHook, pmccabe
+{ lib, stdenv, fetchFromGitHub, sqlite, pkgconfig, autoreconfHook, pmccabe
 , xapian, glib, gmime3, texinfo , emacs, guile
 , gtk3, webkitgtk, libsoup, icu
 , withMug ? false
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of utilties for indexing and searching Maildirs";
     license = licenses.gpl3Plus;
     homepage = "https://www.djcbsoftware.nl/code/mu/";
diff --git a/pkgs/tools/networking/nat-traverse/default.nix b/pkgs/tools/networking/nat-traverse/default.nix
index e3bf3391f21e8..a1c1337a216bb 100644
--- a/pkgs/tools/networking/nat-traverse/default.nix
+++ b/pkgs/tools/networking/nat-traverse/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   pname = "nat-traverse";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     gzip -c nat-traverse.1 > $out/share/man/man1/nat-traverse.1.gz
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NAT gateway traversal utility";
     longDescription = ''
       nat-traverse establishes direct connections between nodes which are
diff --git a/pkgs/tools/networking/ncftp/default.nix b/pkgs/tools/networking/ncftp/default.nix
index d8c37ff58707c..a43d5f4a88c8c 100644
--- a/pkgs/tools/networking/ncftp/default.nix
+++ b/pkgs/tools/networking/ncftp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, coreutils }:
+{ lib, stdenv, fetchurl, ncurses, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "ncftp";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     "--mandir=$(out)/share/man/"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line FTP (File Transfer Protocol) client";
     homepage = "https://www.ncftp.com/ncftp/";
     maintainers = with maintainers; [ bjornfor ];
diff --git a/pkgs/tools/networking/ndisc6/default.nix b/pkgs/tools/networking/ndisc6/default.nix
index 03304df5f7928..6612315c6f2d2 100644
--- a/pkgs/tools/networking/ndisc6/default.nix
+++ b/pkgs/tools/networking/ndisc6/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   name = "ndisc6-1.0.4";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "localstatedir=$(TMPDIR)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.remlab.net/ndisc6/";
     description = "A small collection of useful tools for IPv6 networking";
     maintainers = with maintainers; [ eelco ];
diff --git a/pkgs/tools/networking/netboot/default.nix b/pkgs/tools/networking/netboot/default.nix
index 7a1eac59eeae4..28d9f2c5b32c3 100644
--- a/pkgs/tools/networking/netboot/default.nix
+++ b/pkgs/tools/networking/netboot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, yacc, lzo, db4 }:
+{ lib, stdenv, fetchurl, yacc, lzo, db4 }:
 
 stdenv.mkDerivation rec {
   name = "netboot-0.10.2";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mini PXE server";
     maintainers = [ maintainers.raskin ];
     platforms = ["x86_64-linux"];
diff --git a/pkgs/tools/networking/netcat/default.nix b/pkgs/tools/networking/netcat/default.nix
index 5c275ee6ab4b0..7b325b2f4840a 100644
--- a/pkgs/tools/networking/netcat/default.nix
+++ b/pkgs/tools/networking/netcat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "netcat-gnu-0.7.1";
@@ -8,7 +8,7 @@ stdenv.mkDerivation {
     sha256 = "1frjcdkhkpzk0f84hx6hmw5l0ynpmji8vcbaxg8h5k2svyxz0nmm";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility which reads and writes data across network connections";
     homepage = "http://netcat.sourceforge.net/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/nethogs/default.nix b/pkgs/tools/networking/nethogs/default.nix
index 7bc6d0e2be78d..c6a8f3b7f4e94 100644
--- a/pkgs/tools/networking/nethogs/default.nix
+++ b/pkgs/tools/networking/nethogs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, libpcap }:
+{ lib, stdenv, fetchFromGitHub, ncurses, libpcap }:
 
 stdenv.mkDerivation rec {
   pname = "nethogs";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" "sbin=$(out)/bin" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small 'net top' tool, grouping bandwidth by process";
     longDescription = ''
       NetHogs is a small 'net top' tool. Instead of breaking the traffic down
diff --git a/pkgs/tools/networking/netifd/default.nix b/pkgs/tools/networking/netifd/default.nix
index 36d1ec7a423ab..bfa64601ebfb9 100644
--- a/pkgs/tools/networking/netifd/default.nix
+++ b/pkgs/tools/networking/netifd/default.nix
@@ -1,4 +1,4 @@
-{ runCommand, stdenv, cmake, fetchgit, libnl, libubox, uci, ubus, json_c }:
+{ runCommand, lib, stdenv, cmake, fetchgit, libnl, libubox, uci, ubus, json_c }:
 
 stdenv.mkDerivation {
   pname = "netifd";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
       -I$(echo "${stdenv.lib.getDev libnl}"/include/libnl*/)"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenWrt Network interface configuration daemon";
     homepage = "https://git.openwrt.org/?p=project/netifd.git;a=summary";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/networking/netmask/default.nix b/pkgs/tools/networking/netmask/default.nix
index fa36ee5d80267..c1613fcf92063 100644
--- a/pkgs/tools/networking/netmask/default.nix
+++ b/pkgs/tools/networking/netmask/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, texinfo }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, texinfo }:
 
 stdenv.mkDerivation rec {
   pname = "netmask";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ texinfo ];
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/tlby/netmask";
     description = "An IP address formatting tool ";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/netselect/default.nix b/pkgs/tools/networking/netselect/default.nix
index dfca4c9058ee1..be68e3e2c6009 100644
--- a/pkgs/tools/networking/netselect/default.nix
+++ b/pkgs/tools/networking/netselect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "netselect";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/apenwarr/netselect";
     description = "An ultrafast intelligent parallelizing binary-search implementation of \"ping\"";
     license = licenses.bsd3;
diff --git a/pkgs/tools/networking/netsniff-ng/default.nix b/pkgs/tools/networking/netsniff-ng/default.nix
index 9eb9afcb0e788..c2fbb06167d51 100644
--- a/pkgs/tools/networking/netsniff-ng/default.nix
+++ b/pkgs/tools/networking/netsniff-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, bison, flex, geoip, geolite-legacy
+{ lib, stdenv, fetchFromGitHub, makeWrapper, bison, flex, geoip, geolite-legacy
 , libcli, libnet, libnetfilter_conntrack, libnl, libpcap, libsodium
 , liburcu, ncurses, pkgconfig, zlib }:
 
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     rm -v $out/etc/netsniff-ng/geoip.conf # updating databases after installation is impossible
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Swiss army knife for daily Linux network plumbing";
     longDescription = ''
       netsniff-ng is a free Linux networking toolkit. Its gain of performance
diff --git a/pkgs/tools/networking/network-manager/0.9.8/default.nix b/pkgs/tools/networking/network-manager/0.9.8/default.nix
index 6035e35f63405..6252d776886e6 100644
--- a/pkgs/tools/networking/network-manager/0.9.8/default.nix
+++ b/pkgs/tools/networking/network-manager/0.9.8/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, pkgconfig, dbus-glib
+{ lib, stdenv, fetchurl, intltool, pkgconfig, dbus-glib
 , udev, libnl, libuuid, gnutls, dhcp
 , libgcrypt, perl, libgudev, avahi, ppp, kmod }:
 
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
       installFlagsArray=( "sysconfdir=$out/etc" "localstatedir=$out/var" )
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://projects.gnome.org/NetworkManager/";
     description = "Network configuration and management tool";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/network-manager/applet/default.nix b/pkgs/tools/networking/network-manager/applet/default.nix
index 9f92fcfa1ab34..0eb5045ba2c26 100644
--- a/pkgs/tools/networking/network-manager/applet/default.nix
+++ b/pkgs/tools/networking/network-manager/applet/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -78,7 +78,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/GNOME/network-manager-applet/";
     description = "NetworkManager control applet for GNOME";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/network-manager/default.nix b/pkgs/tools/networking/network-manager/default.nix
index c02275ef5b81f..c5f59e3606fb7 100644
--- a/pkgs/tools/networking/network-manager/default.nix
+++ b/pkgs/tools/networking/network-manager/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll, intltool, pkgconfig, fetchpatch, dbus
+{ lib, stdenv, fetchurl, substituteAll, intltool, pkgconfig, fetchpatch, dbus
 , gnome3, systemd, libuuid, polkit, gnutls, ppp, dhcp, iptables, python3, vala
 , libgcrypt, dnsmasq, bluez5, readline, libselinux, audit
 , gobject-introspection, modemmanager, openresolv, libndp, newt, libsoup
@@ -108,7 +108,7 @@ in stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Projects/NetworkManager";
     description = "Network configuration and management tool";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/network-manager/dmenu/default.nix b/pkgs/tools/networking/network-manager/dmenu/default.nix
index e17d4ebc07198..0e07f2cda801c 100644
--- a/pkgs/tools/networking/network-manager/dmenu/default.nix
+++ b/pkgs/tools/networking/network-manager/dmenu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, glib, fetchFromGitHub, networkmanager, python3Packages
+{ lib, stdenv, glib, fetchFromGitHub, networkmanager, python3Packages
 , gobject-introspection }:
 
 let inherit (python3Packages) python pygobject3;
@@ -30,7 +30,7 @@ in stdenv.mkDerivation rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "Small script to manage NetworkManager connections with dmenu instead of nm-applet";
     homepage     = "https://github.com/firecat53/networkmanager-dmenu";
     license      = stdenv.lib.licenses.mit;
diff --git a/pkgs/tools/networking/network-manager/fortisslvpn/default.nix b/pkgs/tools/networking/network-manager/fortisslvpn/default.nix
index 3cc4133b41cf8..0488f23481e48 100644
--- a/pkgs/tools/networking/network-manager/fortisslvpn/default.nix
+++ b/pkgs/tools/networking/network-manager/fortisslvpn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , substituteAll
 , openfortivpn
@@ -75,7 +75,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NetworkManager’s FortiSSL plugin";
     inherit (networkmanager.meta) maintainers platforms;
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/network-manager/iodine/default.nix b/pkgs/tools/networking/network-manager/iodine/default.nix
index 95d015f6964f0..2ead084d51ee7 100644
--- a/pkgs/tools/networking/network-manager/iodine/default.nix
+++ b/pkgs/tools/networking/network-manager/iodine/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, substituteAll, autoreconfHook, iodine, intltool, pkgconfig, networkmanager, libsecret, gtk3
+{ lib, stdenv, fetchFromGitLab, substituteAll, autoreconfHook, iodine, intltool, pkgconfig, networkmanager, libsecret, gtk3
 , withGnome ? true, gnome3, fetchpatch, libnma, glib }:
 
 let
@@ -50,7 +50,7 @@ in stdenv.mkDerivation {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NetworkManager's iodine plugin";
     inherit (networkmanager.meta) maintainers platforms;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/network-manager/l2tp/default.nix b/pkgs/tools/networking/network-manager/l2tp/default.nix
index 430462f919971..cd79a612bf981 100644
--- a/pkgs/tools/networking/network-manager/l2tp/default.nix
+++ b/pkgs/tools/networking/network-manager/l2tp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, substituteAll, fetchFromGitHub, autoreconfHook, libtool, intltool, pkgconfig
+{ lib, stdenv, substituteAll, fetchFromGitHub, autoreconfHook, libtool, intltool, pkgconfig
 , file, findutils
 , gtk3, networkmanager, ppp, xl2tpd, strongswan, libsecret
 , withGnome ? true, libnma }:
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "L2TP plugin for NetworkManager";
     inherit (networkmanager.meta) platforms;
     homepage = "https://github.com/nm-l2tp/network-manager-l2tp";
diff --git a/pkgs/tools/networking/network-manager/libnma/default.nix b/pkgs/tools/networking/network-manager/libnma/default.nix
index d50ccc6517b4c..9e8bd915dee9d 100644
--- a/pkgs/tools/networking/network-manager/libnma/default.nix
+++ b/pkgs/tools/networking/network-manager/libnma/default.nix
@@ -80,7 +80,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.gnome.org/GNOME/libnma";
     description = "NetworkManager UI utilities (libnm version)";
     license = licenses.gpl2Plus; # Mix of GPL and LPGL 2+
diff --git a/pkgs/tools/networking/network-manager/openconnect/default.nix b/pkgs/tools/networking/network-manager/openconnect/default.nix
index 3c1a8d1104295..cc267aec68afc 100644
--- a/pkgs/tools/networking/network-manager/openconnect/default.nix
+++ b/pkgs/tools/networking/network-manager/openconnect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , substituteAll
 , glib
@@ -72,7 +72,7 @@ in stdenv.mkDerivation {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NetworkManager’s OpenConnect plugin";
     inherit (networkmanager.meta) maintainers platforms;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/network-manager/openvpn/default.nix b/pkgs/tools/networking/network-manager/openvpn/default.nix
index 79435a9e5e8b5..31b86bd2b005c 100644
--- a/pkgs/tools/networking/network-manager/openvpn/default.nix
+++ b/pkgs/tools/networking/network-manager/openvpn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll, openvpn, intltool, libxml2, pkgconfig, file, networkmanager, libsecret
+{ lib, stdenv, fetchurl, substituteAll, openvpn, intltool, libxml2, pkgconfig, file, networkmanager, libsecret
 , gtk3, withGnome ? true, gnome3, kmod, libnma }:
 
 let
@@ -37,7 +37,7 @@ in stdenv.mkDerivation {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NetworkManager's OpenVPN plugin";
     inherit (networkmanager.meta) maintainers platforms;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/network-manager/sstp/default.nix b/pkgs/tools/networking/network-manager/sstp/default.nix
index d5195cba34531..bca53f8d9cd62 100644
--- a/pkgs/tools/networking/network-manager/sstp/default.nix
+++ b/pkgs/tools/networking/network-manager/sstp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , autoreconfHook
 , fetchFromGitHub
 , fetchpatch
@@ -56,7 +56,7 @@ in stdenv.mkDerivation {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NetworkManager's sstp plugin";
     inherit (networkmanager.meta) maintainers platforms;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/network-manager/strongswan/default.nix b/pkgs/tools/networking/network-manager/strongswan/default.nix
index 028d852f13954..6f37ca296bb4b 100644
--- a/pkgs/tools/networking/network-manager/strongswan/default.nix
+++ b/pkgs/tools/networking/network-manager/strongswan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, pkgconfig, networkmanager, strongswanNM
+{ lib, stdenv, fetchurl, intltool, pkgconfig, networkmanager, strongswanNM
 , gtk3, gnome3, libsecret, libnma }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   PKG_CONFIG_LIBNM_VPNSERVICEDIR = "$(out)/lib/NetworkManager/VPN";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NetworkManager's strongswan plugin";
     inherit (networkmanager.meta) platforms;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/network-manager/vpnc/default.nix b/pkgs/tools/networking/network-manager/vpnc/default.nix
index 6cd0d2e75f57f..f5f3d82d6c0ac 100644
--- a/pkgs/tools/networking/network-manager/vpnc/default.nix
+++ b/pkgs/tools/networking/network-manager/vpnc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, substituteAll, vpnc, intltool, pkgconfig, networkmanager, libsecret
+{ lib, stdenv, fetchurl, substituteAll, vpnc, intltool, pkgconfig, networkmanager, libsecret
 , gtk3, withGnome ? true, gnome3, glib, kmod, file, fetchpatch, libnma }:
 let
   pname = "NetworkManager-vpnc";
@@ -41,7 +41,7 @@ in stdenv.mkDerivation {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NetworkManager's VPNC plugin";
     inherit (networkmanager.meta) maintainers platforms;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/nfdump/default.nix b/pkgs/tools/networking/nfdump/default.nix
index 0c9bc41099f24..9420f77e6185b 100644
--- a/pkgs/tools/networking/nfdump/default.nix
+++ b/pkgs/tools/networking/nfdump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoconf, automake, libtool, pkg-config
 , bzip2, libpcap, flex, yacc }:
 
@@ -31,7 +31,7 @@ stdenv.mkDerivation {
     "--enable-nfpcapd"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for working with netflow data";
     longDescription = ''
       nfdump is a set of tools for working with netflow data.
diff --git a/pkgs/tools/networking/nfstrace/default.nix b/pkgs/tools/networking/nfstrace/default.nix
index 6377f276af3f2..a1bf83726d262 100644
--- a/pkgs/tools/networking/nfstrace/default.nix
+++ b/pkgs/tools/networking/nfstrace/default.nix
@@ -1,4 +1,4 @@
-{ cmake, fetchFromGitHub, fetchpatch, json_c, libpcap, ncurses, stdenv, libtirpc }:
+{ cmake, fetchFromGitHub, fetchpatch, json_c, libpcap, ncurses, lib, stdenv, libtirpc }:
 
 stdenv.mkDerivation rec {
   pname = "nfstrace";
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false; # requires network access
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://epam.github.io/nfstrace/";
     description = "NFS and CIFS tracing/monitoring/capturing/analyzing tool";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/ngrep/default.nix b/pkgs/tools/networking/ngrep/default.nix
index 60125b515d67c..1e57ac75843e4 100644
--- a/pkgs/tools/networking/ngrep/default.nix
+++ b/pkgs/tools/networking/ngrep/default.nix
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     sed -i "s|BPF=.*|BPF=${libpcap}/include/pcap/bpf.h|" configure
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network packet analyzer";
     longDescription = ''
       ngrep strives to provide most of GNU grep's common features, applying
diff --git a/pkgs/tools/networking/noip/default.nix b/pkgs/tools/networking/noip/default.nix
index 6503e70137748..309607941af12 100644
--- a/pkgs/tools/networking/noip/default.nix
+++ b/pkgs/tools/networking/noip/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "noip-2.1.9-1";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dynamic DNS daemon for no-ip accounts";
     homepage = "http://noip.com/download?page=linux";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/tools/networking/nss-pam-ldapd/default.nix b/pkgs/tools/networking/nss-pam-ldapd/default.nix
index 3ce7638923c3c..9f2c071c408ce 100644
--- a/pkgs/tools/networking/nss-pam-ldapd/default.nix
+++ b/pkgs/tools/networking/nss-pam-ldapd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , pkgconfig, makeWrapper, autoreconfHook
 , openldap, python, pam
 }:
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/sbin/nslcd --prefix LD_LIBRARY_PATH ":" $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LDAP identity and authentication for NSS/PAM";
     homepage = "https://arthurdejong.org/nss-pam-ldapd/";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/networking/ntopng/default.nix b/pkgs/tools/networking/ntopng/default.nix
index 3db5a28f1616a..7606cb06d905f 100644
--- a/pkgs/tools/networking/ntopng/default.nix
+++ b/pkgs/tools/networking/ntopng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap,/* gnutls, libgcrypt,*/ libxml2, glib
+{ lib, stdenv, fetchurl, libpcap,/* gnutls, libgcrypt,*/ libxml2, glib
 , geoip, geolite-legacy, sqlite, which, autoreconfHook, git
 , pkgconfig, groff, curl, json_c, luajit, zeromq, rrdtool
 }:
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE = "-fpermissive"
     + stdenv.lib.optionalString stdenv.cc.isClang " -Wno-error=reserved-user-defined-literal";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "High-speed web-based traffic analysis and flow collection tool";
     homepage = "http://www.ntop.org/products/ntop/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/networking/ntp/default.nix b/pkgs/tools/networking/ntp/default.nix
index a7deaf7b69488..b2f8d8a21076b 100644
--- a/pkgs/tools/networking/ntp/default.nix
+++ b/pkgs/tools/networking/ntp/default.nix
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/share/doc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.ntp.org/";
     description = "An implementation of the Network Time Protocol";
     license = {
diff --git a/pkgs/tools/networking/nuttcp/default.nix b/pkgs/tools/networking/nuttcp/default.nix
index fe3cde5f91a03..1b9e9fe04e43d 100644
--- a/pkgs/tools/networking/nuttcp/default.nix
+++ b/pkgs/tools/networking/nuttcp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "nuttcp";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     cp nuttcp $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network performance measurement tool";
     longDescription = ''
       nuttcp is a network performance measurement tool intended for use by
diff --git a/pkgs/tools/networking/nylon/default.nix b/pkgs/tools/networking/nylon/default.nix
index d6f8cb21e0bcf..840b714fc9f88 100644
--- a/pkgs/tools/networking/nylon/default.nix
+++ b/pkgs/tools/networking/nylon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libevent, buildEnv }:
+{ lib, stdenv, fetchurl, libevent, buildEnv }:
 let
   # failed to find a better way to make it work
   libevent-comb = buildEnv {
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ libevent ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://monkey.org/~marius/nylon";
     description = "Proxy server, supporting SOCKS 4 and 5, as well as a mirror mode";
     license = licenses.bsdOriginal;
diff --git a/pkgs/tools/networking/nzbget/default.nix b/pkgs/tools/networking/nzbget/default.nix
index c25f19c03507a..224474f1b38ba 100644
--- a/pkgs/tools/networking/nzbget/default.nix
+++ b/pkgs/tools/networking/nzbget/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxml2, ncurses, libsigcxx, libpar2
+{ lib, stdenv, fetchurl, pkgconfig, libxml2, ncurses, libsigcxx, libpar2
 , gnutls, libgcrypt, zlib, openssl }:
 
 stdenv.mkDerivation rec {
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://nzbget.net";
     license = licenses.gpl2Plus;
     description = "A command line tool for downloading files from news servers";
diff --git a/pkgs/tools/networking/ocproxy/default.nix b/pkgs/tools/networking/ocproxy/default.nix
index 877f15865acbc..bc21884e6ac8d 100644
--- a/pkgs/tools/networking/ocproxy/default.nix
+++ b/pkgs/tools/networking/ocproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libevent }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libevent }:
 
 stdenv.mkDerivation rec {
   version = "1.60";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenConnect proxy";
     longDescription = ''
       ocproxy is a user-level SOCKS and port forwarding proxy for OpenConnect
diff --git a/pkgs/tools/networking/ocserv/default.nix b/pkgs/tools/networking/ocserv/default.nix
index daaa483149a24..587379bde89ab 100644
--- a/pkgs/tools/networking/ocserv/default.nix
+++ b/pkgs/tools/networking/ocserv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, autoreconfHook, pkgconfig, nettle, gnutls
+{ lib, stdenv, fetchFromGitLab, autoreconfHook, pkgconfig, nettle, gnutls
 , libev, protobufc, guile, geoip, libseccomp, gperf, readline
 , lz4, libgssglue, ronn, pam
 }:
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ nettle gnutls libev protobufc guile geoip libseccomp gperf readline lz4 libgssglue ronn pam ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.com/openconnect/ocserv";
     license = licenses.gpl2;
     description = "This program is openconnect VPN server (ocserv), a server for the openconnect VPN client";
diff --git a/pkgs/tools/networking/ofono/default.nix b/pkgs/tools/networking/ofono/default.nix
index c6b2ffe9e832f..2806e09c994b4 100644
--- a/pkgs/tools/networking/ofono/default.nix
+++ b/pkgs/tools/networking/ofono/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , autoreconfHook
 , pkgconfig
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Infrastructure for building mobile telephony (GSM/UMTS) applications";
     homepage = "https://01.org/ofono";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/openapi-generator-cli/default.nix b/pkgs/tools/networking/openapi-generator-cli/default.nix
index 4630342cf8aec..a5271bf410f1a 100644
--- a/pkgs/tools/networking/openapi-generator-cli/default.nix
+++ b/pkgs/tools/networking/openapi-generator-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   version = "4.3.1";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --add-flags "-jar $out/share/java/${jarfilename}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows generation of API client libraries (SDK generation), server stubs and documentation automatically given an OpenAPI Spec";
     homepage = "https://github.com/OpenAPITools/openapi-generator";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/openapi-generator-cli/unstable.nix b/pkgs/tools/networking/openapi-generator-cli/unstable.nix
index f5d71fb8e85b3..a0af97b2ea9a8 100644
--- a/pkgs/tools/networking/openapi-generator-cli/unstable.nix
+++ b/pkgs/tools/networking/openapi-generator-cli/unstable.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   version = "5.0.0-2020-02-04";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --add-flags "-jar $out/share/java/${jarfilename}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows generation of API client libraries (SDK generation), server stubs and documentation automatically given an OpenAPI Spec";
     homepage = "https://github.com/OpenAPITools/openapi-generator";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/openconnect/default.nix b/pkgs/tools/networking/openconnect/default.nix
index 11f9fdc0fd8c1..a36330add4df2 100644
--- a/pkgs/tools/networking/openconnect/default.nix
+++ b/pkgs/tools/networking/openconnect/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, openssl ? null, gnutls ? null, gmp, libxml2, stoken, zlib, fetchgit, darwin } :
+{ lib, stdenv, fetchurl, pkgconfig, openssl ? null, gnutls ? null, gmp, libxml2, stoken, zlib, fetchgit, darwin } :
 
 assert (openssl != null) == (gnutls == null);
 
@@ -31,7 +31,7 @@ in stdenv.mkDerivation rec {
     ++ stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.PCSC;
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VPN Client for Cisco's AnyConnect SSL VPN";
     homepage = "http://www.infradead.org/openconnect/";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/networking/openconnect_pa/default.nix b/pkgs/tools/networking/openconnect_pa/default.nix
index 4b108dc303e88..3bbc474aa60f4 100644
--- a/pkgs/tools/networking/openconnect_pa/default.nix
+++ b/pkgs/tools/networking/openconnect_pa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, vpnc, openssl ? null, gnutls ? null, gmp, libxml2, stoken, zlib, autoreconfHook } :
+{ lib, stdenv, fetchFromGitHub, pkgconfig, vpnc, openssl ? null, gnutls ? null, gmp, libxml2, stoken, zlib, autoreconfHook } :
 
 assert (openssl != null) == (gnutls == null);
 
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig autoreconfHook ];
   propagatedBuildInputs = [ vpnc openssl gnutls gmp libxml2 stoken zlib ];
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenConnect client extended to support Palo Alto Networks' GlobalProtect VPN";
     homepage = "https://github.com/dlenski/openconnect/";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/networking/openfortivpn/default.nix b/pkgs/tools/networking/openfortivpn/default.nix
index a8ce80f983823..56ae2590576da 100644
--- a/pkgs/tools/networking/openfortivpn/default.nix
+++ b/pkgs/tools/networking/openfortivpn/default.nix
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client for PPP+SSL VPN tunnel services";
     homepage = "https://github.com/adrienverge/openfortivpn";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/openntpd/default.nix b/pkgs/tools/networking/openntpd/default.nix
index aa0a3926b1413..e6703c748fcea 100644
--- a/pkgs/tools/networking/openntpd/default.nix
+++ b/pkgs/tools/networking/openntpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libressl
+{ lib, stdenv, fetchurl, libressl
 , privsepPath ? "/var/empty"
 , privsepUser ? "ntp"
 }:
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     "localstatedir=\${TMPDIR}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.openntpd.org/";
     license = licenses.bsd3;
     description = "OpenBSD NTP daemon (Debian port)";
diff --git a/pkgs/tools/networking/opensm/default.nix b/pkgs/tools/networking/opensm/default.nix
index 3fe9f87d65856..a21fe68e81633 100644
--- a/pkgs/tools/networking/opensm/default.nix
+++ b/pkgs/tools/networking/opensm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, bison, flex, rdma-core }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, bison, flex, rdma-core }:
 
 stdenv.mkDerivation rec {
   pname = "opensm";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Infiniband subnet manager";
     homepage = "https://www.openfabrics.org/";
     license = licenses.gpl2; # dual licensed as 2-clause BSD
diff --git a/pkgs/tools/networking/openvpn/default.nix b/pkgs/tools/networking/openvpn/default.nix
index 04ac97003102c..09495ded95440 100644
--- a/pkgs/tools/networking/openvpn/default.nix
+++ b/pkgs/tools/networking/openvpn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkg-config
 , makeWrapper
@@ -68,7 +68,7 @@ let
 
         enableParallelBuilding = true;
 
-        meta = with stdenv.lib; {
+        meta = with lib; {
           description = "A robust and highly flexible tunneling application";
           downloadPage = "https://openvpn.net/community-downloads/";
           homepage = "https://openvpn.net/";
diff --git a/pkgs/tools/networking/openvpn/update-resolv-conf.nix b/pkgs/tools/networking/openvpn/update-resolv-conf.nix
index 76d04e6b685cf..d71ab72901bc2 100644
--- a/pkgs/tools/networking/openvpn/update-resolv-conf.nix
+++ b/pkgs/tools/networking/openvpn/update-resolv-conf.nix
@@ -24,7 +24,7 @@ in stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Script to update your /etc/resolv.conf with DNS settings that come from the received push dhcp-options";
     homepage = "https://github.com/masterkorp/openvpn-update-resolv-conf/";
     maintainers = with maintainers; [ abbradar ];
diff --git a/pkgs/tools/networking/openvpn/update-systemd-resolved.nix b/pkgs/tools/networking/openvpn/update-systemd-resolved.nix
index 1a192ce6688a5..9d8e669fe4590 100644
--- a/pkgs/tools/networking/openvpn/update-systemd-resolved.nix
+++ b/pkgs/tools/networking/openvpn/update-systemd-resolved.nix
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${lib.makeBinPath [ iproute systemd coreutils util-linux ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Helper script for OpenVPN to directly update the DNS settings of a link through systemd-resolved via DBus";
     homepage = "https://github.com/jonathanio/update-systemd-resolved";
     maintainers = with maintainers; [ eadwu ];
diff --git a/pkgs/tools/networking/p2p/gtk-gnutella/default.nix b/pkgs/tools/networking/p2p/gtk-gnutella/default.nix
index 710f7dedb9975..06b247b28bf95 100644
--- a/pkgs/tools/networking/p2p/gtk-gnutella/default.nix
+++ b/pkgs/tools/networking/p2p/gtk-gnutella/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , bison
@@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
     install -Dm0444 src/${pname}.man $out/share/man/man1/${pname}.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GTK Gnutella client, optimized for speed and scalability";
     homepage = "http://gtk-gnutella.sourceforge.net/"; # Code: https://github.com/gtk-gnutella/gtk-gnutella
     changelog = "https://raw.githubusercontent.com/gtk-gnutella/gtk-gnutella/v${version}/ChangeLog";
diff --git a/pkgs/tools/networking/p2p/libtorrent/default.nix b/pkgs/tools/networking/p2p/libtorrent/default.nix
index f750e3b1bfe1e..cbb1ae0311316 100644
--- a/pkgs/tools/networking/p2p/libtorrent/default.nix
+++ b/pkgs/tools/networking/p2p/libtorrent/default.nix
@@ -1,6 +1,6 @@
 # NOTE: this is rakshava's version of libtorrent, used mainly by rtorrent
 # This is NOT libtorrent-rasterbar, used by Deluge, qbitttorent, and others
-{ stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoreconfHook
 , cppunit, openssl, libsigcxx, zlib
 }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig autoreconfHook ];
   buildInputs = [ cppunit openssl libsigcxx zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rakshasa/libtorrent";
     description = "A BitTorrent library written in C++ for *nix, with focus on high performance and good code";
 
diff --git a/pkgs/tools/networking/p2p/rtorrent/default.nix b/pkgs/tools/networking/p2p/rtorrent/default.nix
index b55c673c058bb..f9ad9773d4dae 100644
--- a/pkgs/tools/networking/p2p/rtorrent/default.nix
+++ b/pkgs/tools/networking/p2p/rtorrent/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchFromGitHub, pkgconfig
+{ lib, stdenv, fetchurl, fetchFromGitHub, pkgconfig
 , libtool, autoconf, automake, cppunit
 , libtorrent, ncurses, libsigcxx, curl
 , zlib, openssl, xmlrpc_c
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     mv doc/rtorrent.rc $out/share/doc/rtorrent/rtorrent.rc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://rakshasa.github.io/rtorrent/";
     description = "An ncurses client for libtorrent, ideal for use with screen, tmux, or dtach";
 
diff --git a/pkgs/tools/networking/pacparser/default.nix b/pkgs/tools/networking/pacparser/default.nix
index 2d703730785f6..ce639a4cbc790 100644
--- a/pkgs/tools/networking/pacparser/default.nix
+++ b/pkgs/tools/networking/pacparser/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "pacparser";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A library to parse proxy auto-config (PAC) files";
     homepage = "http://pacparser.manugarg.com/";
     license = licenses.lgpl3;
diff --git a/pkgs/tools/networking/par2cmdline/default.nix b/pkgs/tools/networking/par2cmdline/default.nix
index ecfe5fa035727..73e12e1285678 100644
--- a/pkgs/tools/networking/par2cmdline/default.nix
+++ b/pkgs/tools/networking/par2cmdline/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "par2cmdline";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/Parchive/par2cmdline";
     description = "PAR 2.0 compatible file verification and repair tool";
     longDescription = ''
diff --git a/pkgs/tools/networking/pcapc/default.nix b/pkgs/tools/networking/pcapc/default.nix
index b279f681a2b4a..48dc96bb3f713 100644
--- a/pkgs/tools/networking/pcapc/default.nix
+++ b/pkgs/tools/networking/pcapc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpcap, cmake }:
+{ lib, stdenv, fetchFromGitHub, libpcap, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "pcapc";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pfactum/pcapc";
     description = "Compile libpcap filter expressions into BPF opcodes";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/pcapfix/default.nix b/pkgs/tools/networking/pcapfix/default.nix
index a700bd54e7ae0..c20a19f23a428 100644
--- a/pkgs/tools/networking/pcapfix/default.nix
+++ b/pkgs/tools/networking/pcapfix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "pcapfix-1.1.4";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   postPatch = ''sed -i "s|/usr|$out|" Makefile'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://f00l.de/pcapfix/";
     description = "Repair your broken pcap and pcapng files";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/pdnsd/default.nix b/pkgs/tools/networking/pdnsd/default.nix
index d2894271301fe..a08182394b1fe 100644
--- a/pkgs/tools/networking/pdnsd/default.nix
+++ b/pkgs/tools/networking/pdnsd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "pdnsd-1.2.9a-par";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
   # fix ipv6 on darwin
   CPPFLAGS = "-D__APPLE_USE_RFC_3542";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Permanent DNS caching";
     homepage = "http://members.home.nl/p.a.rombouts/pdnsd";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/networking/persepolis/default.nix b/pkgs/tools/networking/persepolis/default.nix
index 32fb053f811c7..fd36680c992ec 100644
--- a/pkgs/tools/networking/persepolis/default.nix
+++ b/pkgs/tools/networking/persepolis/default.nix
@@ -61,7 +61,7 @@ buildPythonApplication rec {
     youtube-dl
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Persepolis Download Manager is a GUI for aria2";
     homepage = "https://persepolisdm.github.io/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/philter/default.nix b/pkgs/tools/networking/philter/default.nix
index ee079fe9fdf03..752f43b3348df 100644
--- a/pkgs/tools/networking/philter/default.nix
+++ b/pkgs/tools/networking/philter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python }:
+{ lib, stdenv, fetchurl, python }:
 
 stdenv.mkDerivation rec {
   pname = "philter";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     chmod +x "$out"/bin/philter
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mail sorter for Maildirs";
     homepage = "http://philter.sourceforge.net";
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/tools/networking/phodav/default.nix b/pkgs/tools/networking/phodav/default.nix
index 4939e75661ecf..a7405abacb4b9 100644
--- a/pkgs/tools/networking/phodav/default.nix
+++ b/pkgs/tools/networking/phodav/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , pkgconfig, libsoup, meson, ninja }:
 
 let
@@ -23,7 +23,7 @@ in stdenv.mkDerivation rec {
 
   outputs = [ "out" "dev" "lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "WebDav server implementation and library using libsoup";
     homepage = "https://wiki.gnome.org/phodav";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/networking/photon/default.nix b/pkgs/tools/networking/photon/default.nix
index db6917ef0b76e..55dedc09bea5c 100644
--- a/pkgs/tools/networking/photon/default.nix
+++ b/pkgs/tools/networking/photon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 python3Packages.buildPythonApplication rec {
   pname = "photon";
@@ -25,7 +25,7 @@ python3Packages.buildPythonApplication rec {
       --add-flags "-O $out/share/photon/photon.py"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "a lightning fast web crawler which extracts URLs, files, intel & endpoints from a target";
     homepage = "https://github.com/s0md3v/Photon";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/pingtcp/default.nix b/pkgs/tools/networking/pingtcp/default.nix
index 70296f5a4259d..5b4cbf10321f5 100644
--- a/pkgs/tools/networking/pingtcp/default.nix
+++ b/pkgs/tools/networking/pingtcp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake }:
+{ lib, stdenv, fetchFromGitHub, cmake }:
 
 stdenv.mkDerivation rec {
   pname = "pingtcp";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -Dm644 {..,$out/share/doc/pingtcp}/README.md
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Measure TCP handshake time";
     homepage = "https://github.com/LanetNetwork/pingtcp";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/pirate-get/default.nix b/pkgs/tools/networking/pirate-get/default.nix
index b89ab8164cc4b..76b77da1764b1 100644
--- a/pkgs/tools/networking/pirate-get/default.nix
+++ b/pkgs/tools/networking/pirate-get/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 with python3Packages;
 
@@ -13,7 +13,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ colorama veryprettytable pyperclip ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line interface for The Pirate Bay";
     homepage = "https://github.com/vikstrous/pirate-get";
     license = licenses.gpl1;
diff --git a/pkgs/tools/networking/pmacct/default.nix b/pkgs/tools/networking/pmacct/default.nix
index 4ef3cd6345e57..12c6eeaf4704b 100644
--- a/pkgs/tools/networking/pmacct/default.nix
+++ b/pkgs/tools/networking/pmacct/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , autoreconfHook
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     ++ optional withPgSQL "--enable-pgsql"
     ++ optional withMysql "--enable-mysql";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small set of multi-purpose passive network monitoring tools";
     longDescription = ''
       pmacct is a small set of multi-purpose passive network monitoring tools
diff --git a/pkgs/tools/networking/polygraph/default.nix b/pkgs/tools/networking/polygraph/default.nix
index 05053b3734948..addb72359297c 100644
--- a/pkgs/tools/networking/polygraph/default.nix
+++ b/pkgs/tools/networking/polygraph/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, zlib, ncurses }:
+{ lib, stdenv, fetchurl, openssl, zlib, ncurses }:
 
 stdenv.mkDerivation rec {
   name = "polygraph-4.13.0";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ openssl zlib ncurses ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.web-polygraph.org";
     description = "Performance testing tool for caching proxies, origin server accelerators, L4/7 switches, content filters, and other Web intermediaries";
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/polysh/default.nix b/pkgs/tools/networking/polysh/default.nix
index 34bc908060aaa..68cb8fed57a00 100644
--- a/pkgs/tools/networking/polysh/default.nix
+++ b/pkgs/tools/networking/polysh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python2Packages }:
+{ lib, stdenv, fetchurl, python2Packages }:
 
 let
   inherit (python2Packages) buildPythonApplication;
@@ -11,7 +11,7 @@ buildPythonApplication rec {
           sha256 = "0kxhp38c8a8hc8l86y53l2z5zpzxc4b8lx5zyzmq1badcrfc4mh4";
         };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to aggregate several remote shells into one";
     longDescription = ''
       Polysh is a tool to aggregate several remote shells into one. It
diff --git a/pkgs/tools/networking/ppp/default.nix b/pkgs/tools/networking/ppp/default.nix
index f507b582f64b4..36d156a3994b1 100644
--- a/pkgs/tools/networking/ppp/default.nix
+++ b/pkgs/tools/networking/ppp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, fetchFromGitHub, substituteAll, libpcap, openssl }:
+{ lib, stdenv, fetchurl, fetchpatch, fetchFromGitHub, substituteAll, libpcap, openssl }:
 
 stdenv.mkDerivation rec {
   version = "2.4.8";
@@ -65,7 +65,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ppp.samba.org/";
     description = "Point-to-point implementation for Linux and Solaris";
     license = with licenses; [ bsdOriginal publicDomain gpl2 lgpl2 ];
diff --git a/pkgs/tools/networking/pptp/default.nix b/pkgs/tools/networking/pptp/default.nix
index dfc61d8197c19..1534d1083f4a3 100644
--- a/pkgs/tools/networking/pptp/default.nix
+++ b/pkgs/tools/networking/pptp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, ppp, iproute }:
+{ lib, stdenv, fetchurl, perl, ppp, iproute }:
 
 stdenv.mkDerivation rec {
   pname = "pptp";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     patchShebangs $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PPTP client for Linux";
     homepage = "http://pptpclient.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/pptpd/default.nix b/pkgs/tools/networking/pptpd/default.nix
index e6f5f9503d8e6..8a802281192e2 100644
--- a/pkgs/tools/networking/pptpd/default.nix
+++ b/pkgs/tools/networking/pptpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ppp }:
+{ lib, stdenv, fetchurl, ppp }:
 
 stdenv.mkDerivation rec {
   pname   = "pptpd";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     substituteInPlace plugins/Makefile --replace "install -o root" "install"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://poptop.sourceforge.net/dox/";
     description = "The PPTP Server for Linux";
     platforms   = platforms.linux;
diff --git a/pkgs/tools/networking/privoxy/default.nix b/pkgs/tools/networking/privoxy/default.nix
index 8346c862fc6e0..2963f2aff523f 100644
--- a/pkgs/tools/networking/privoxy/default.nix
+++ b/pkgs/tools/networking/privoxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, zlib, pcre, w3m, man }:
+{ lib, stdenv, fetchurl, autoreconfHook, zlib, pcre, w3m, man }:
 
 stdenv.mkDerivation rec {
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     rm -rf $out/var
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.privoxy.org/";
     description = "Non-caching web proxy with advanced filtering capabilities";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/proxify/default.nix b/pkgs/tools/networking/proxify/default.nix
index 4a75b3ca2f175..7f45d53d41d14 100644
--- a/pkgs/tools/networking/proxify/default.nix
+++ b/pkgs/tools/networking/proxify/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "1x78n88ri8kph827k03x1q06zpbbbp7793xsvc376ljda5n6bqig";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Proxy tool for HTTP/HTTPS traffic capture";
     longDescription = ''
       This tool supports multiple operations such as request/response dump, filtering
diff --git a/pkgs/tools/networking/pssh/default.nix b/pkgs/tools/networking/pssh/default.nix
index 43e465e05b6ae..b2b08cea84436 100644
--- a/pkgs/tools/networking/pssh/default.nix
+++ b/pkgs/tools/networking/pssh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages, openssh, rsync }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages, openssh, rsync }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "pssh";
@@ -20,7 +20,7 @@ pythonPackages.buildPythonApplication rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Parallel SSH Tools";
     longDescription = ''
       PSSH provides parallel versions of OpenSSH and related tools,
diff --git a/pkgs/tools/networking/pwnat/default.nix b/pkgs/tools/networking/pwnat/default.nix
index 55965173e0ef3..b710b6601d1b3 100644
--- a/pkgs/tools/networking/pwnat/default.nix
+++ b/pkgs/tools/networking/pwnat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   name  = "${pname}-${date}";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     cp README* COPYING* $out/share/pwnat
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "http://samy.pl/pwnat/";
     description = "ICMP NAT to NAT client-server communication";
     license     = stdenv.lib.licenses.gpl3Plus;
diff --git a/pkgs/tools/networking/pykms/default.nix b/pkgs/tools/networking/pykms/default.nix
index 345999c00bcd9..f7ddd2ef3f996 100644
--- a/pkgs/tools/networking/pykms/default.nix
+++ b/pkgs/tools/networking/pykms/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, runtimeShell, fetchFromGitHub, python3, writeText, writeScript
+{ lib, stdenv, runtimeShell, fetchFromGitHub, python3, writeText, writeScript
 , coreutils, sqlite }:
 
 with python3.pkgs;
@@ -81,7 +81,7 @@ in buildPythonApplication rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Windows KMS (Key Management Service) server written in Python";
     homepage    = "https://github.com/SystemRage/py-kms";
     license     = licenses.mit;
diff --git a/pkgs/tools/networking/quickserve/default.nix b/pkgs/tools/networking/quickserve/default.nix
index 53d649d791fc4..f23bbcd25371b 100644
--- a/pkgs/tools/networking/quickserve/default.nix
+++ b/pkgs/tools/networking/quickserve/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, fetchzip, python3, python3Packages }:
+{ lib, stdenv, makeWrapper, fetchzip, python3, python3Packages }:
 let
   threaded_servers = python3Packages.buildPythonPackage {
     name = "threaded_servers";
@@ -26,7 +26,7 @@ in stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple HTTP server for quickly sharing files";
     homepage = "https://xyne.archlinux.ca/projects/quickserve/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/quicktun/default.nix b/pkgs/tools/networking/quicktun/default.nix
index 0f7a16caa82cd..8d227e1fbba16 100644
--- a/pkgs/tools/networking/quicktun/default.nix
+++ b/pkgs/tools/networking/quicktun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libsodium }:
+{ lib, stdenv, fetchFromGitHub, libsodium }:
 
 stdenv.mkDerivation {
   pname = "quicktun";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     install -vD out/quicktun* -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Very simple, yet secure VPN software";
     homepage = "http://wiki.ucis.nl/QuickTun";
     maintainers = [ maintainers.fpletz ];
diff --git a/pkgs/tools/networking/radsecproxy/default.nix b/pkgs/tools/networking/radsecproxy/default.nix
index 283131b56714a..1a7d895f81025 100644
--- a/pkgs/tools/networking/radsecproxy/default.nix
+++ b/pkgs/tools/networking/radsecproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, autoreconfHook, nettle }:
+{ lib, stdenv, fetchFromGitHub, openssl, autoreconfHook, nettle }:
 
 stdenv.mkDerivation rec {
   pname = "radsecproxy";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
      "--localstatedir=/var"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://software.nordu.net/radsecproxy/";
     description = "A generic RADIUS proxy that supports both UDP and TLS (RadSec) RADIUS transports";
     license = licenses.bsd3;
diff --git a/pkgs/tools/networking/radvd/default.nix b/pkgs/tools/networking/radvd/default.nix
index aef67022f7865..116b1de83ec5b 100644
--- a/pkgs/tools/networking/radvd/default.nix
+++ b/pkgs/tools/networking/radvd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libdaemon, bison, flex, check }:
+{ lib, stdenv, fetchurl, pkgconfig, libdaemon, bison, flex, check }:
 
 stdenv.mkDerivation rec {
   pname = "radvd";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig bison flex check ];
   buildInputs = [ libdaemon ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.litech.org/radvd/";
     description = "IPv6 Router Advertisement Daemon";
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/ratools/default.nix b/pkgs/tools/networking/ratools/default.nix
index 23d0dae086ec8..0eea11bb3f588 100644
--- a/pkgs/tools/networking/ratools/default.nix
+++ b/pkgs/tools/networking/ratools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "ratools";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     install -vD man/* -t $out/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast, dynamic, multi-threading framework for IPv6 Router Advertisements";
     homepage = "https://github.com/danrl/ratools";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/rcon/default.nix b/pkgs/tools/networking/rcon/default.nix
index f7cd08e197e87..1ec988676e4a4 100644
--- a/pkgs/tools/networking/rcon/default.nix
+++ b/pkgs/tools/networking/rcon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, glib, libbsd, check, pcre }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, glib, libbsd, check, pcre }:
 
 stdenv.mkDerivation rec {
   pname = "rcon";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     pcre
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/n0la/rcon";
     description = "Source RCON client for command line";
     maintainers = with maintainers; [ f4814n ];
diff --git a/pkgs/tools/networking/rdrview/default.nix b/pkgs/tools/networking/rdrview/default.nix
index 628bd98534151..8f51039570531 100644
--- a/pkgs/tools/networking/rdrview/default.nix
+++ b/pkgs/tools/networking/rdrview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libxml2, curl, libseccomp }:
+{ lib, stdenv, fetchFromGitHub, libxml2, curl, libseccomp }:
 
 stdenv.mkDerivation {
   name = "rdrview";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     install -Dm755 rdrview -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tool to extract main content from a webpage";
     homepage = "https://github.com/eafer/rdrview";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/reaver-wps-t6x/default.nix b/pkgs/tools/networking/reaver-wps-t6x/default.nix
index d347273f50ec7..147eb2c3bf24c 100644
--- a/pkgs/tools/networking/reaver-wps-t6x/default.nix
+++ b/pkgs/tools/networking/reaver-wps-t6x/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpcap, pixiewps, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, libpcap, pixiewps, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "reaver-wps-t6x";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   sourceRoot = "source/src";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Online and offline brute force attack against WPS";
     homepage = "https://github.com/t6x/reaver-wps-fork-t6x";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/reaver-wps/default.nix b/pkgs/tools/networking/reaver-wps/default.nix
index 9f4f2d5bea4eb..ec226f50668b0 100644
--- a/pkgs/tools/networking/reaver-wps/default.nix
+++ b/pkgs/tools/networking/reaver-wps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap, sqlite, makeWrapper }:
+{ lib, stdenv, fetchurl, libpcap, sqlite, makeWrapper }:
 
 stdenv.mkDerivation rec {
   version = "1.4";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/wash   --run "[ -s ${confdir}/reaver/reaver.db ] || install -D $out/etc/reaver.db ${confdir}/reaver/reaver.db"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Brute force attack against Wifi Protected Setup";
     homepage = "https://code.google.com/archive/p/reaver-wps/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/ripmime/default.nix b/pkgs/tools/networking/ripmime/default.nix
index 0c3c32270b17a..d40c1d10aa7ca 100644
--- a/pkgs/tools/networking/ripmime/default.nix
+++ b/pkgs/tools/networking/ripmime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "ripmime";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE=" -Wno-error ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Attachment extractor for MIME messages";
     maintainers = with maintainers; [ raskin ];
     homepage = "http://www.pldaniels.com/ripmime/";
diff --git a/pkgs/tools/networking/rp-pppoe/default.nix b/pkgs/tools/networking/rp-pppoe/default.nix
index d8476d1d159a6..fd3a563c209d8 100644
--- a/pkgs/tools/networking/rp-pppoe/default.nix
+++ b/pkgs/tools/networking/rp-pppoe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ppp } :
+{ lib, stdenv, fetchurl, ppp } :
 let
   version = "3.12";
 in
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     sed -i Makefile -e 's@PPPOESERVER_PPPD_OPTIONS=@&$(out)@'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Roaring Penguin Point-to-Point over Ethernet tool";
     platforms = platforms.linux;
     homepage = "https://www.roaringpenguin.com/products/pppoe";
diff --git a/pkgs/tools/networking/s3cmd/default.nix b/pkgs/tools/networking/s3cmd/default.nix
index 53f24ddb75245..06f51b0c5063d 100644
--- a/pkgs/tools/networking/s3cmd/default.nix
+++ b/pkgs/tools/networking/s3cmd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchFromGitHub, python_magic, dateutil }:
+{ lib, stdenv, buildPythonApplication, fetchFromGitHub, python_magic, dateutil }:
 
 buildPythonApplication rec {
   pname = "s3cmd";
@@ -15,7 +15,7 @@ buildPythonApplication rec {
 
   dontUseSetuptoolsCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://s3tools.org/s3cmd";
     description = "Command line tool for managing Amazon S3 and CloudFront services";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/s4cmd/default.nix b/pkgs/tools/networking/s4cmd/default.nix
index dedbc751179f0..80874649072aa 100644
--- a/pkgs/tools/networking/s4cmd/default.nix
+++ b/pkgs/tools/networking/s4cmd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "s4cmd";
@@ -26,7 +26,7 @@ python3Packages.buildPythonApplication rec {
   # Test suite requires an S3 bucket
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/bloomreach/s4cmd";
     description = "Super S3 command line tool";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/saldl/default.nix b/pkgs/tools/networking/saldl/default.nix
index 9c2b4915bf1e9..b697f4c3b3d00 100644
--- a/pkgs/tools/networking/saldl/default.nix
+++ b/pkgs/tools/networking/saldl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkgconfig
 , wafHook
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI downloader optimized for speed and early preview";
     homepage = "https://saldl.github.io";
     license = licenses.agpl3;
diff --git a/pkgs/tools/networking/shadowfox/default.nix b/pkgs/tools/networking/shadowfox/default.nix
index d1cc33457737f..c7507925f5f84 100644
--- a/pkgs/tools/networking/shadowfox/default.nix
+++ b/pkgs/tools/networking/shadowfox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 
 buildGoModule rec {
   pname = "shadowfox";
@@ -19,7 +19,7 @@ buildGoModule rec {
     "-ldflags=-X main.tag=v${version}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       This project aims at creating a universal dark theme for Firefox while
       adhering to the modern design principles set by Mozilla.
diff --git a/pkgs/tools/networking/shadowsocks-libev/default.nix b/pkgs/tools/networking/shadowsocks-libev/default.nix
index 22b291ec44e97..b0a24b539c2be 100644
--- a/pkgs/tools/networking/shadowsocks-libev/default.nix
+++ b/pkgs/tools/networking/shadowsocks-libev/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake
+{ lib, stdenv, fetchFromGitHub, cmake
 , libsodium, mbedtls, libev, c-ares, pcre
 , asciidoc, xmlto, docbook_xml_dtd_45, docbook_xsl, libxslt
 }:
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     cp lib/* $out/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight secured SOCKS5 proxy";
     longDescription = ''
       Shadowsocks-libev is a lightweight secured SOCKS5 proxy for embedded devices and low-end boxes.
diff --git a/pkgs/tools/networking/shadowsocks-rust/default.nix b/pkgs/tools/networking/shadowsocks-rust/default.nix
index ed793a50cb8f0..4f927a684c030 100644
--- a/pkgs/tools/networking/shadowsocks-rust/default.nix
+++ b/pkgs/tools/networking/shadowsocks-rust/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, libsodium, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, libsodium, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "shadowsocks-rust";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
     ++ stdenv.lib.optionals stdenv.isDarwin [ Security ];
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/shadowsocks/shadowsocks-rust";
     description = "A Rust port of shadowsocks";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/shncpd/default.nix b/pkgs/tools/networking/shncpd/default.nix
index 46c9b22248acf..8cfd1f94252a1 100644
--- a/pkgs/tools/networking/shncpd/default.nix
+++ b/pkgs/tools/networking/shncpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "shncpd";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     makeFlags=( "PREFIX=$out" )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple, stupid and slow HNCP daemon";
     homepage = "https://www.irif.univ-paris-diderot.fr/~jch/software/homenet/shncpd.html";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/siege/default.nix b/pkgs/tools/networking/siege/default.nix
index 4df008364d0c3..125b66b36a5ac 100644
--- a/pkgs/tools/networking/siege/default.nix
+++ b/pkgs/tools/networking/siege/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, zlib }:
+{ lib, stdenv, fetchurl, openssl, zlib }:
 
 stdenv.mkDerivation rec {
   name = "siege-4.0.7";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "--with-zlib=${zlib.dev}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP load tester";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/simpleproxy/default.nix b/pkgs/tools/networking/simpleproxy/default.nix
index 7a5bc713faee3..6c110be05da37 100644
--- a/pkgs/tools/networking/simpleproxy/default.nix
+++ b/pkgs/tools/networking/simpleproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "simpleproxy";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
     sha256 = "1my9g4vp19dikx3fsbii4ichid1bs9b9in46bkg05gbljhj340f6";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/vzaliva/simpleproxy";
     description = "A simple TCP proxy";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/sipcalc/default.nix b/pkgs/tools/networking/sipcalc/default.nix
index 081f200533012..c9470cd5b8b33 100644
--- a/pkgs/tools/networking/sipcalc/default.nix
+++ b/pkgs/tools/networking/sipcalc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "sipcalc";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "cfd476c667f7a119e49eb5fe8adcfb9d2339bc2e0d4d01a1d64b7c229be56357";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Advanced console ip subnet calculator";
     homepage = "http://www.routemeister.net/projects/sipcalc/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/networking/sipsak/default.nix b/pkgs/tools/networking/sipsak/default.nix
index 09de1c2e594a7..320a856437b93 100644
--- a/pkgs/tools/networking/sipsak/default.nix
+++ b/pkgs/tools/networking/sipsak/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, c-ares, openssl ? null }:
+{ lib, stdenv, fetchurl, autoreconfHook, c-ares, openssl ? null }:
 
 stdenv.mkDerivation rec {
   pname = "sipsak";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     sha256 = "769fe59966b1962b67aa35aad7beb9a2110ebdface36558072a05c6405fb5374";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sipwise/sipsak";
     description = "SIP Swiss army knife";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/tools/networking/slirp4netns/default.nix b/pkgs/tools/networking/slirp4netns/default.nix
index c0c64405c0d49..bda3d36c24551 100644
--- a/pkgs/tools/networking/slirp4netns/default.nix
+++ b/pkgs/tools/networking/slirp4netns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pkg-config
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests = { inherit (nixosTests) podman; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/rootless-containers/slirp4netns";
     description = "User-mode networking for unprivileged network namespaces";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/smartdns/default.nix b/pkgs/tools/networking/smartdns/default.nix
index ca40012433ef0..91fcc0e982eb5 100644
--- a/pkgs/tools/networking/smartdns/default.nix
+++ b/pkgs/tools/networking/smartdns/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl }:
+{ lib, stdenv, fetchFromGitHub, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "smartdns";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "SYSCONFDIR=${placeholder "out"}/etc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "A local DNS server to obtain the fastest website IP for the best Internet experience";
     longDescription = ''
diff --git a/pkgs/tools/networking/socat/2.x.nix b/pkgs/tools/networking/socat/2.x.nix
index 97775a00604bb..0f36b83e16510 100644
--- a/pkgs/tools/networking/socat/2.x.nix
+++ b/pkgs/tools/networking/socat/2.x.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl }:
+{ lib, stdenv, fetchurl, openssl }:
 
 stdenv.mkDerivation rec {
   name = "socat-2.0.0-b9";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   patches = stdenv.lib.singleton ./libressl-fixes.patch ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility for bidirectional data transfer between two independent data channels";
     homepage = "http://www.dest-unreach.org/socat/";
     repositories.git = "git://repo.or.cz/socat.git";
diff --git a/pkgs/tools/networking/spoofer/default.nix b/pkgs/tools/networking/spoofer/default.nix
index cadaf021cda7a..b0aefa9ef1143 100644
--- a/pkgs/tools/networking/spoofer/default.nix
+++ b/pkgs/tools/networking/spoofer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, protobuf, openssl, libpcap, traceroute
+{ lib, stdenv, fetchurl, pkgconfig, protobuf, openssl, libpcap, traceroute
 , withGUI ? false, qt5 }:
 
 let inherit (stdenv.lib) optional;
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ openssl protobuf libpcap traceroute ]
                 ++ optional withGUI qt5.qtbase ;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.caida.org/projects/spoofer";
     description = "Assess and report on deployment of source address validation";
     longDescription = ''
diff --git a/pkgs/tools/networking/ssh-askpass-fullscreen/default.nix b/pkgs/tools/networking/ssh-askpass-fullscreen/default.nix
index 07cc5da960dd1..05e5183712624 100644
--- a/pkgs/tools/networking/ssh-askpass-fullscreen/default.nix
+++ b/pkgs/tools/networking/ssh-askpass-fullscreen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkg-config, gtk2, openssh }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config, gtk2, openssh }:
 
 stdenv.mkDerivation rec {
   pname = "ssh-askpass-fullscreen";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     openssh
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A small SSH askpass GUI using GTK+2";
     homepage = "https://github.com/atj/ssh-askpass-fullscreen";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/sshoogr/default.nix b/pkgs/tools/networking/sshoogr/default.nix
index 764b34fc5a530..9539c15f5ed90 100644
--- a/pkgs/tools/networking/sshoogr/default.nix
+++ b/pkgs/tools/networking/sshoogr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jdk, makeWrapper }:
+{ lib, stdenv, fetchzip, jdk, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "sshoogr";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       --prefix JAVA_HOME : ${jdk}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A Groovy-based DSL for working with remote SSH servers
     '';
diff --git a/pkgs/tools/networking/sshpass/default.nix b/pkgs/tools/networking/sshpass/default.nix
index 7f5644edb5263..60c9ab97a8b3e 100644
--- a/pkgs/tools/networking/sshpass/default.nix
+++ b/pkgs/tools/networking/sshpass/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "sshpass";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0q7fblaczb7kwbsz0gdy9267z0sllzgmf0c7z5c9mf88wv74ycn6";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/sshpass/";
     description = "Non-interactive ssh password auth";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/sshping/default.nix b/pkgs/tools/networking/sshping/default.nix
index aa3e57d53f88a..13abba539ac5d 100644
--- a/pkgs/tools/networking/sshping/default.nix
+++ b/pkgs/tools/networking/sshping/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, libssh}:
+{lib, stdenv, fetchFromGitHub, libssh}:
 
 stdenv.mkDerivation rec {
   pname = "sshping";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       install -Dm755 bin/sshping $out/bin/sshping
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/spook/sshping";
     description = "Measure character-echo latency and bandwidth for an interactive ssh session";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/sslsplit/default.nix b/pkgs/tools/networking/sslsplit/default.nix
index bf23d06551d7d..c3a343d7fa1e0 100644
--- a/pkgs/tools/networking/sslsplit/default.nix
+++ b/pkgs/tools/networking/sslsplit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, libevent, libpcap, libnet, zlib }:
+{ lib, stdenv, fetchFromGitHub, openssl, libevent, libpcap, libnet, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "sslsplit";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "LIBNET_BASE=${libnet}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Transparent SSL/TLS interception";
     homepage = "https://www.roe.ch/SSLsplit";
     platforms = platforms.all;
diff --git a/pkgs/tools/networking/ssmtp/default.nix b/pkgs/tools/networking/ssmtp/default.nix
index 90547eb13643f..0e624631d47f7 100644
--- a/pkgs/tools/networking/ssmtp/default.nix
+++ b/pkgs/tools/networking/ssmtp/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, tlsSupport ? true, openssl ? null}:
+{lib, stdenv, fetchurl, tlsSupport ? true, openssl ? null}:
 
 assert tlsSupport -> openssl != null;
 
@@ -38,7 +38,7 @@ stdenv.mkDerivation {
 
   NIX_LDFLAGS = stdenv.lib.optionalString tlsSupport "-lcrypto";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     license = licenses.gpl2;
     maintainers = with maintainers; [ basvandijk ];
diff --git a/pkgs/tools/networking/stubby/default.nix b/pkgs/tools/networking/stubby/default.nix
index 2a10eb13e3205..a87204ff0c6c3 100644
--- a/pkgs/tools/networking/stubby/default.nix
+++ b/pkgs/tools/networking/stubby/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, getdns, doxygen, libyaml, darwin, cmake, systemd }:
+{ lib, stdenv, fetchFromGitHub, getdns, doxygen, libyaml, darwin, cmake, systemd }:
 
 stdenv.mkDerivation rec {
   pname = "stubby";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ doxygen getdns systemd ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ darwin.Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A local DNS Privacy stub resolver (using DNS-over-TLS)";
     longDescription = ''
       Stubby is an application that acts as a local DNS Privacy stub
diff --git a/pkgs/tools/networking/stun/default.nix b/pkgs/tools/networking/stun/default.nix
index 306b1899f763f..c74c73ec6a0e8 100644
--- a/pkgs/tools/networking/stun/default.nix
+++ b/pkgs/tools/networking/stun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname   = "stun";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     cp -v debian/manpages/stund.8.gz $server/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stun server and test client";
     homepage    = "https://sourceforge.net/projects/stun/";
     license     = licenses.vsl10;
diff --git a/pkgs/tools/networking/subfinder/default.nix b/pkgs/tools/networking/subfinder/default.nix
index f812f7ffa91f3..4474cba6aee02 100644
--- a/pkgs/tools/networking/subfinder/default.nix
+++ b/pkgs/tools/networking/subfinder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "subfinder";
@@ -15,7 +15,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Subdomain discovery tool";
     longDescription = ''
       SubFinder is a subdomain discovery tool that discovers valid
diff --git a/pkgs/tools/networking/swagger-codegen/default.nix b/pkgs/tools/networking/swagger-codegen/default.nix
index c5026851f50ea..e93435515b2b4 100644
--- a/pkgs/tools/networking/swagger-codegen/default.nix
+++ b/pkgs/tools/networking/swagger-codegen/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   version = "2.4.17";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --add-flags "-jar $out/share/java/${jarfilename}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Allows generation of API client libraries (SDK generation), server stubs and documentation automatically given an OpenAPI Spec";
     homepage = "https://github.com/swagger-api/swagger-codegen";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/swaks/default.nix b/pkgs/tools/networking/swaks/default.nix
index 81d0935f0b08a..85e8998947592 100644
--- a/pkgs/tools/networking/swaks/default.nix
+++ b/pkgs/tools/networking/swaks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, perlPackages, makeWrapper }:
+{ lib, stdenv, fetchurl, perl, perlPackages, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "swaks";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
       ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.jetmore.org/john/code/swaks/";
     description = "A featureful, flexible, scriptable, transaction-oriented SMTP test tool";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/tayga/default.nix b/pkgs/tools/networking/tayga/default.nix
index 1cecf2d634df6..8d0de6a6c1883 100644
--- a/pkgs/tools/networking/tayga/default.nix
+++ b/pkgs/tools/networking/tayga/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   version = "0.9.2";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "1700y121lhvpna49bjpssb7jq1abj9qw5wxgjn8gzp6jm4kpj7rb";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Userland stateless NAT64 daemon";
     longDescription = ''
       TAYGA is an out-of-kernel stateless NAT64 implementation
diff --git a/pkgs/tools/networking/tcpflow/default.nix b/pkgs/tools/networking/tcpflow/default.nix
index 8f502c5ef3f6a..74c7f0f113521 100644
--- a/pkgs/tools/networking/tcpflow/default.nix
+++ b/pkgs/tools/networking/tcpflow/default.nix
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "bash ./bootstrap.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TCP stream extractor";
     longDescription = ''
       tcpflow is a program that captures data transmitted as part of TCP
diff --git a/pkgs/tools/networking/tcpreplay/default.nix b/pkgs/tools/networking/tcpreplay/default.nix
index fdf7965311d03..2875d13671a73 100644
--- a/pkgs/tools/networking/tcpreplay/default.nix
+++ b/pkgs/tools/networking/tcpreplay/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libpcap, tcpdump, Carbon, CoreServices }:
+{ lib, stdenv, fetchurl, libpcap, tcpdump, Carbon, CoreServices }:
 
 stdenv.mkDerivation rec {
   pname = "tcpreplay";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     "--with-tcpdump=${tcpdump}/bin"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A suite of utilities for editing and replaying network traffic";
     homepage = "http://tcpreplay.appneta.com/";
     license = with licenses; [ bsd3 gpl3 ];
diff --git a/pkgs/tools/networking/tdns-cli/default.nix b/pkgs/tools/networking/tdns-cli/default.nix
index 681109712ab1a..0ed7922874dc9 100644
--- a/pkgs/tools/networking/tdns-cli/default.nix
+++ b/pkgs/tools/networking/tdns-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   name = "tdns-cli";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0v1hx6kjsmydx6ckjqj31y2gcpvax4mshwrniicplkka3q6hx9ra";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DNS tool that aims to replace dig and nsupdate";
     homepage = "https://github.com/rotty/tdns-cli";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/tendermint/default.nix b/pkgs/tools/networking/tendermint/default.nix
index 2fedae4b7a793..bd280e75379db 100644
--- a/pkgs/tools/networking/tendermint/default.nix
+++ b/pkgs/tools/networking/tendermint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoModule }:
+{ lib, stdenv, fetchFromGitHub, buildGoModule }:
 
 buildGoModule rec {
   pname = "tendermint";
@@ -19,7 +19,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X github.com/tendermint/tendermint/version.GitCommit=${src.rev}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Byzantine-Fault Tolerant State Machines. Or Blockchain, for short";
     homepage = "https://tendermint.com/";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/termshark/default.nix b/pkgs/tools/networking/termshark/default.nix
index 51168f01f4482..43b7702a818a8 100644
--- a/pkgs/tools/networking/termshark/default.nix
+++ b/pkgs/tools/networking/termshark/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, buildGoModule, wireshark-cli }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, buildGoModule, wireshark-cli }:
 
 buildGoModule rec {
   pname = "termshark";
@@ -27,7 +27,7 @@ buildGoModule rec {
     -X github.com/gcla/termshark.Version=${version}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://termshark.io/";
     description = "A terminal UI for wireshark-cli, inspired by Wireshark";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/tftp-hpa/default.nix b/pkgs/tools/networking/tftp-hpa/default.nix
index 2d88c9bf07e60..f8e028dc616a6 100644
--- a/pkgs/tools/networking/tftp-hpa/default.nix
+++ b/pkgs/tools/networking/tftp-hpa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "tftp-hpa";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "12vidchglhyc20znq5wdsbhi9mqg90jnl7qr9qs8hbvaz4fkdvmg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TFTP tools - a lot of fixes on top of BSD TFTP";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/tgt/default.nix b/pkgs/tools/networking/tgt/default.nix
index d9d8478e9856d..9ef0c9d46d14a 100644
--- a/pkgs/tools/networking/tgt/default.nix
+++ b/pkgs/tools/networking/tgt/default.nix
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "iSCSI Target daemon with RDMA support";
     homepage = "http://stgt.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/tinc/pre.nix b/pkgs/tools/networking/tinc/pre.nix
index a49ab43e55ed4..2379338e51d97 100644
--- a/pkgs/tools/networking/tinc/pre.nix
+++ b/pkgs/tools/networking/tinc/pre.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchpatch, autoreconfHook, texinfo, ncurses, readline, zlib, lzo, openssl }:
+{ lib, stdenv, fetchgit, fetchpatch, autoreconfHook, texinfo, ncurses, readline, zlib, lzo, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "tinc";
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     "--localstatedir=/var"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "VPN daemon with full mesh routing";
     longDescription = ''
       tinc is a Virtual Private Network (VPN) daemon that uses tunnelling and
diff --git a/pkgs/tools/networking/tinyfecvpn/default.nix b/pkgs/tools/networking/tinyfecvpn/default.nix
index aab937c994eea..0873b9a541a35 100644
--- a/pkgs/tools/networking/tinyfecvpn/default.nix
+++ b/pkgs/tools/networking/tinyfecvpn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "tinyfecvpn";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/wangyu-/tinyfecVPN";
     description = "A VPN Designed for Lossy Links, with Build-in Forward Error Correction(FEC) Support";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/tinyproxy/default.nix b/pkgs/tools/networking/tinyproxy/default.nix
index 7d3c49db7b799..610322b23da51 100644
--- a/pkgs/tools/networking/tinyproxy/default.nix
+++ b/pkgs/tools/networking/tinyproxy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, asciidoc, libxml2,
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, asciidoc, libxml2,
   libxslt, docbook_xsl }:
 
 stdenv.mkDerivation rec {
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
   # See: https://github.com/tinyproxy/tinyproxy/issues/1
   stdenv.lib.optional stdenv.isDarwin "--disable-regexcheck";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tinyproxy.github.io/";
     description = "A light-weight HTTP/HTTPS proxy daemon for POSIX operating systems";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/tlspool/default.nix b/pkgs/tools/networking/tlspool/default.nix
index c91c703f28fb8..d3415a88b8623 100644
--- a/pkgs/tools/networking/tlspool/default.nix
+++ b/pkgs/tools/networking/tlspool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, pkgconfig, arpa2cm
 , openldap, p11-kit, unbound, libtasn1, db, openssl, quickder, libkrb5, ldns, gnutls-kdh
 , softhsm
@@ -43,7 +43,7 @@ stdenv.mkDerivation {
     cp $src/src/*.h $out/include/${pname}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A supercharged TLS daemon that allows for easy, strong and consistent deployment";
     license = licenses.gpl3;
     homepage = "http://www.tlspool.org";
diff --git a/pkgs/tools/networking/tox-node/default.nix b/pkgs/tools/networking/tox-node/default.nix
index 43be37c94288d..be949d60067cb 100644
--- a/pkgs/tools/networking/tox-node/default.nix
+++ b/pkgs/tools/networking/tox-node/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub
+{ lib, stdenv, rustPlatform, fetchFromGitHub
 , libsodium, openssl
 , pkgconfig
 }:
@@ -33,7 +33,7 @@ buildRustPackage rec {
 
   cargoSha256 = "087ccb824hmmxmnn5c2bzww2q888a8zy6y7rwgsdfr8rbay2c909";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A server application to run tox node written in pure Rust";
     homepage = "https://github.com/tox-rs/tox-node";
     license = [ licenses.gpl3Plus ];
diff --git a/pkgs/tools/networking/toxvpn/default.nix b/pkgs/tools/networking/toxvpn/default.nix
index 10e4dc2f1b14f..887200fa2aa5d 100644
--- a/pkgs/tools/networking/toxvpn/default.nix
+++ b/pkgs/tools/networking/toxvpn/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, nlohmann_json,
+{ lib, stdenv, fetchFromGitHub, cmake, nlohmann_json,
   libtoxcore, libsodium, libcap, zeromq,
   systemd ? null }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
 
   postInstall = "$out/bin/toxvpn -h";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A powerful tool that allows one to make tunneled point to point connections over Tox";
     homepage    = "https://github.com/cleverca22/toxvpn";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/networking/tracebox/default.nix b/pkgs/tools/networking/tracebox/default.nix
index 1fe2d25e35d0e..7ac4c88325c98 100644
--- a/pkgs/tools/networking/tracebox/default.nix
+++ b/pkgs/tools/networking/tracebox/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, autoreconfHook, libcrafter, libpcap, lua }:
+{ lib, stdenv, fetchzip, autoreconfHook, libcrafter, libpcap, lua }:
 
 stdenv.mkDerivation rec {
   pname = "tracebox";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     sed '/libcrafter/d' -i src/tracebox/Makefile.am
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.tracebox.org/";
     description = "A middlebox detection tool";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/tools/networking/traceroute/default.nix b/pkgs/tools/networking/traceroute/default.nix
index 2948a571a3861..04e66f29fccc2 100644
--- a/pkgs/tools/networking/traceroute/default.nix
+++ b/pkgs/tools/networking/traceroute/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "traceroute";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     sed -i 's@LIBS := \(.*\) -lm \(.*\)@LIBS := \1 \2@' Make.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://traceroute.sourceforge.net/";
     description = "Tracks the route taken by packets over an IP network";
     license = stdenv.lib.licenses.gpl2;
diff --git a/pkgs/tools/networking/tridactyl-native/default.nix b/pkgs/tools/networking/tridactyl-native/default.nix
index 1ebd8d8be6a28..2e17f753a5b69 100644
--- a/pkgs/tools/networking/tridactyl-native/default.nix
+++ b/pkgs/tools/networking/tridactyl-native/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , python3
 }:
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     wrapPythonProgramsIn "$out/share/tridactyl"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tridactyl native messaging host application";
     homepage = "https://github.com/tridactyl/tridactyl";
     license = licenses.asl20;
diff --git a/pkgs/tools/networking/tunnelto/default.nix b/pkgs/tools/networking/tunnelto/default.nix
index 4bf251be81fce..a91a82b9d5dd4 100644
--- a/pkgs/tools/networking/tunnelto/default.nix
+++ b/pkgs/tools/networking/tunnelto/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , openssl
@@ -24,7 +24,7 @@ rustPlatform.buildRustPackage rec {
     ++ stdenv.lib.optionals stdenv.isLinux [ openssl ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Expose your local web server to the internet with a public URL";
     homepage = "https://tunnelto.dev";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/ubridge/default.nix b/pkgs/tools/networking/ubridge/default.nix
index c628a2c8a8cc5..ac475e6e8a538 100644
--- a/pkgs/tools/networking/ubridge/default.nix
+++ b/pkgs/tools/networking/ubridge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , libpcap
 }:
 
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bridge for UDP tunnels, Ethernet, TAP, and VMnet interfaces";
     longDescription = ''
       uBridge is a simple application to create user-land bridges between
diff --git a/pkgs/tools/networking/ucspi-tcp/default.nix b/pkgs/tools/networking/ucspi-tcp/default.nix
index 72325df8be79d..0d6e0a2f8d96a 100644
--- a/pkgs/tools/networking/ucspi-tcp/default.nix
+++ b/pkgs/tools/networking/ucspi-tcp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "ucspi-tcp-0.88";
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     cp debian/ucspi-tcp-man/*.1 "$out/share/man/man1"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line tools for building TCP client-server applications";
     longDescription = ''
       tcpserver waits for incoming connections and, for each connection, runs a
diff --git a/pkgs/tools/networking/uget-integrator/default.nix b/pkgs/tools/networking/uget-integrator/default.nix
index a600d6c5341c4..f89b168b84cc0 100644
--- a/pkgs/tools/networking/uget-integrator/default.nix
+++ b/pkgs/tools/networking/uget-integrator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, uget, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, uget, python3Packages }:
 
 stdenv.mkDerivation rec {
   pname = "uget-integrator";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Native messaging host to integrate uGet Download Manager with web browsers";
     homepage = "https://github.com/ugetdm/uget-integrator";
     license = licenses.gpl3;
diff --git a/pkgs/tools/networking/uget/default.nix b/pkgs/tools/networking/uget/default.nix
index f8c585c3b2521..5267eda9bf29a 100644
--- a/pkgs/tools/networking/uget/default.nix
+++ b/pkgs/tools/networking/uget/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, intltool, openssl, curl, libnotify,
+{ lib, stdenv, fetchurl, pkgconfig, intltool, openssl, curl, libnotify,
   libappindicator-gtk3, gst_all_1, gtk3, dconf, wrapGAppsHook, aria2 ? null
 }:
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   preFixup = stdenv.lib.optionalString (aria2 != null)
                ''gappsWrapperArgs+=(--suffix PATH : "${aria2}/bin")'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Download manager using GTK and libcurl";
     longDescription = ''
       uGet is a VERY Powerful download manager application with a large
diff --git a/pkgs/tools/networking/unbound/python.nix b/pkgs/tools/networking/unbound/python.nix
index 939c2299e32c5..71ff3b954f420 100644
--- a/pkgs/tools/networking/unbound/python.nix
+++ b/pkgs/tools/networking/unbound/python.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, expat, libevent, swig, pythonPackages }:
+{ lib, stdenv, fetchurl, openssl, expat, libevent, swig, pythonPackages }:
 
 let
   inherit (pythonPackages) python;
@@ -54,7 +54,7 @@ in stdenv.mkDerivation rec {
     patchelf --replace-needed libunbound.so.2 $out/${python.sitePackages}/libunbound.so.2 $out/${python.sitePackages}/_unbound.so
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python library for Unbound, the validating, recursive, and caching DNS resolver";
     license = licenses.bsd3;
     homepage = "http://www.unbound.net";
diff --git a/pkgs/tools/networking/urlwatch/default.nix b/pkgs/tools/networking/urlwatch/default.nix
index 15734132da755..10bbc963a28dc 100644
--- a/pkgs/tools/networking/urlwatch/default.nix
+++ b/pkgs/tools/networking/urlwatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "urlwatch";
@@ -26,7 +26,7 @@ python3Packages.buildPythonApplication rec {
   # no tests
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for monitoring webpages for updates";
     homepage = "https://thp.io/2008/urlwatch/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/networking/vde2/default.nix b/pkgs/tools/networking/vde2/default.nix
index b10ec5c1695d1..98a5217424078 100644
--- a/pkgs/tools/networking/vde2/default.nix
+++ b/pkgs/tools/networking/vde2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, openssl, libpcap, python2, withPython ? false }:
+{ lib, stdenv, fetchurl, fetchpatch, openssl, libpcap, python2, withPython ? false }:
 
 stdenv.mkDerivation rec {
   name = "vde2-2.3.2";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/virtualsquare/vde-2";
     description = "Virtual Distributed Ethernet, an Ethernet compliant virtual network";
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/vlan/default.nix b/pkgs/tools/networking/vlan/default.nix
index 331a993f3acdf..2d329cb29b06a 100644
--- a/pkgs/tools/networking/vlan/default.nix
+++ b/pkgs/tools/networking/vlan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   name = "vlan-1.9";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
       cp vconfig.8 $out/share/man/man8/
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "User mode programs to enable VLANs on Ethernet devices";
     platforms = platforms.linux;
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/networking/vtun/default.nix b/pkgs/tools/networking/vtun/default.nix
index 71d9097a15013..af4cc0fe2e525 100644
--- a/pkgs/tools/networking/vtun/default.nix
+++ b/pkgs/tools/networking/vtun/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, openssl, lzo, zlib, yacc, flex }:
+{ lib, stdenv, fetchurl, fetchpatch, openssl, lzo, zlib, yacc, flex }:
 
 stdenv.mkDerivation rec {
   name = "vtun-3.0.4";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     "--with-blowfish-headers=${openssl.dev}/include/openssl"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
       description = "Virtual Tunnels over TCP/IP with traffic shaping, compression and encryption";
       homepage = "http://vtun.sourceforge.net/";
       license = licenses.gpl2;
diff --git a/pkgs/tools/networking/wavemon/default.nix b/pkgs/tools/networking/wavemon/default.nix
index 0f39a221f4dbc..4b265e12fbf17 100644
--- a/pkgs/tools/networking/wavemon/default.nix
+++ b/pkgs/tools/networking/wavemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, libnl, pkg-config }:
+{ lib, stdenv, fetchFromGitHub, ncurses, libnl, pkg-config }:
 
 stdenv.mkDerivation rec {
   pname = "wavemon";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     sha256 = "0m9n5asjxs1ir5rqprigqcrm976mgjvh4yql1jhfnbszwbf95193";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     description = "Ncurses-based monitoring application for wireless network devices";
     homepage = "https://github.com/uoaerg/wavemon";
diff --git a/pkgs/tools/networking/webalizer/default.nix b/pkgs/tools/networking/webalizer/default.nix
index 133aac67bdbf0..332d1cf2867f9 100644
--- a/pkgs/tools/networking/webalizer/default.nix
+++ b/pkgs/tools/networking/webalizer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib, libpng, gd, geoip, db }:
+{ lib, stdenv, fetchurl, zlib, libpng, gd, geoip, db }:
 
 stdenv.mkDerivation {
   name = "webalizer-2.23-05";
@@ -22,7 +22,7 @@ stdenv.mkDerivation {
     "--enable-shared"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Web server log file analysis program";
     homepage = "http://www.webalizer.org";
     platforms = platforms.unix;
diff --git a/pkgs/tools/networking/wget/default.nix b/pkgs/tools/networking/wget/default.nix
index 77913c4f32a11..ca70126782d6a 100644
--- a/pkgs/tools/networking/wget/default.nix
+++ b/pkgs/tools/networking/wget/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gettext, pkgconfig, perlPackages
+{ lib, stdenv, fetchurl, gettext, pkgconfig, perlPackages
 , libidn2, zlib, pcre, libuuid, libiconv, libintl
 , python3, lzip
 , libpsl ? null
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for retrieving files using HTTP, HTTPS, and FTP";
 
     longDescription =
diff --git a/pkgs/tools/networking/whois/default.nix b/pkgs/tools/networking/whois/default.nix
index 35124ef6719cf..e2dd3a4c4fd68 100644
--- a/pkgs/tools/networking/whois/default.nix
+++ b/pkgs/tools/networking/whois/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl, gettext, pkgconfig, libidn2, libiconv }:
+{ lib, stdenv, fetchFromGitHub, perl, gettext, pkgconfig, libidn2, libiconv }:
 
 stdenv.mkDerivation rec {
   version = "5.5.6";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   installTargets = [ "install-whois" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Intelligent WHOIS client from Debian";
     longDescription = ''
       This package provides a commandline client for the WHOIS (RFC 3912)
diff --git a/pkgs/tools/networking/wicd/default.nix b/pkgs/tools/networking/wicd/default.nix
index 8cd0b7c55f7c8..40550b48abbe2 100644
--- a/pkgs/tools/networking/wicd/default.nix
+++ b/pkgs/tools/networking/wicd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, python2Packages
+{ lib, stdenv, fetchurl, python2Packages
 , wpa_supplicant, dhcp, dhcpcd, wirelesstools
 , nettools, openresolv, iproute, iputils }:
 
@@ -102,7 +102,7 @@ in stdenv.mkDerivation rec {
     echo "wpa2-ttls" >> "$out/etc/encryption/templates/active"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://wicd.net/";
     description = "A wiredless and wired network manager";
     longDescription=''
diff --git a/pkgs/tools/networking/wifite2/default.nix b/pkgs/tools/networking/wifite2/default.nix
index 101c4643a77f9..3b1c3f14ac536 100644
--- a/pkgs/tools/networking/wifite2/default.nix
+++ b/pkgs/tools/networking/wifite2/default.nix
@@ -46,7 +46,7 @@ python3.pkgs.buildPythonApplication rec {
   checkInputs = propagatedBuildInputs;
   checkPhase = "python -m unittest discover tests -v";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/derv82/wifite2";
     description = "Rewrite of the popular wireless network auditor, wifite";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/wireguard-go/default.nix b/pkgs/tools/networking/wireguard-go/default.nix
index 2913a31e16ad2..100de62683dbe 100644
--- a/pkgs/tools/networking/wireguard-go/default.nix
+++ b/pkgs/tools/networking/wireguard-go/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchzip }:
+{ lib, stdenv, buildGoPackage, fetchzip }:
 
 buildGoPackage rec {
   pname = "wireguard-go";
@@ -21,7 +21,7 @@ buildGoPackage rec {
     mv $out/bin/wireguard $out/bin/wireguard-go
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Userspace Go implementation of WireGuard";
     homepage = "https://git.zx2c4.com/wireguard-go/about/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/wol/default.nix b/pkgs/tools/networking/wol/default.nix
index 3ca10e2ecbc3f..114a8457d5b2c 100644
--- a/pkgs/tools/networking/wol/default.nix
+++ b/pkgs/tools/networking/wol/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   pname = "wol";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Implements Wake On LAN functionality in a small program";
     homepage = "https://sourceforge.net/projects/wake-on-lan/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/networking/wolfebin/default.nix b/pkgs/tools/networking/wolfebin/default.nix
index 52874e89bbe7a..23458f2a39642 100644
--- a/pkgs/tools/networking/wolfebin/default.nix
+++ b/pkgs/tools/networking/wolfebin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python }:
+{ lib, stdenv, fetchFromGitHub, python }:
 
 stdenv.mkDerivation rec {
   version = "5.4";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -m 755 wolfebin_server.py $out/bin/wolfebin_server
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/thejoshwolfe/wolfebin";
     description = "Quick and easy file sharing";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/wormhole-william/default.nix b/pkgs/tools/networking/wormhole-william/default.nix
index 261db4590c1d0..6476d4f43b1e0 100644
--- a/pkgs/tools/networking/wormhole-william/default.nix
+++ b/pkgs/tools/networking/wormhole-william/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "wormhole-william";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/psanford/wormhole-william";
     description = "End-to-end encrypted file transfers";
     changelog = "https://github.com/psanford/wormhole-william/releases/tag/v${version}";
diff --git a/pkgs/tools/networking/wrk/default.nix b/pkgs/tools/networking/wrk/default.nix
index 40daeb8619443..4298bd70d600d 100644
--- a/pkgs/tools/networking/wrk/default.nix
+++ b/pkgs/tools/networking/wrk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, luajit, openssl, perl }:
+{ lib, stdenv, fetchFromGitHub, luajit, openssl, perl }:
 
 stdenv.mkDerivation rec {
   pname = "wrk";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     cp wrk $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "HTTP benchmarking tool";
     homepage = "https://github.com/wg/wrk";
     longDescription = ''
diff --git a/pkgs/tools/networking/wuzz/default.nix b/pkgs/tools/networking/wuzz/default.nix
index 8db9c07ffc564..73db27f1a9422 100644
--- a/pkgs/tools/networking/wuzz/default.nix
+++ b/pkgs/tools/networking/wuzz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "wuzz";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/asciimoo/wuzz";
     description = "Interactive cli tool for HTTP inspection";
     license = licenses.agpl3;
diff --git a/pkgs/tools/networking/x11-ssh-askpass/default.nix b/pkgs/tools/networking/x11-ssh-askpass/default.nix
index 7e1597451b13c..d33dd3df12ee7 100644
--- a/pkgs/tools/networking/x11-ssh-askpass/default.nix
+++ b/pkgs/tools/networking/x11-ssh-askpass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xlibsWrapper, imake, gccmakedep }:
+{ lib, stdenv, fetchurl, xlibsWrapper, imake, gccmakedep }:
 
 stdenv.mkDerivation {
   name = "x11-ssh-askpass-1.2.4.1";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
 
   installTargets = [ "install" "install.man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sigmavirus24/x11-ssh-askpass";
     description = "Lightweight passphrase dialog for OpenSSH or other open variants of SSH";
     license = licenses.mit;
diff --git a/pkgs/tools/networking/xl2tpd/default.nix b/pkgs/tools/networking/xl2tpd/default.nix
index 38a45fd3e6fa3..26731817c80f0 100644
--- a/pkgs/tools/networking/xl2tpd/default.nix
+++ b/pkgs/tools/networking/xl2tpd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpcap, ppp }:
+{ lib, stdenv, fetchFromGitHub, libpcap, ppp }:
 
 stdenv.mkDerivation rec {
   pname = "xl2tpd";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.xelerance.com/software/xl2tpd/";
     description = "Layer 2 Tunnelling Protocol Daemon (RFC 2661)";
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/yrd/default.nix b/pkgs/tools/networking/yrd/default.nix
index 9b76d033829ff..7f946718588b8 100644
--- a/pkgs/tools/networking/yrd/default.nix
+++ b/pkgs/tools/networking/yrd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 let
   pname = "yrd";
@@ -17,7 +17,7 @@ in pythonPackages.buildPythonApplication {
 
   propagatedBuildInputs = with pythonPackages; [ argh ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cjdns swiss army knife";
     maintainers = with maintainers; [ akru ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/networking/zap/default.nix b/pkgs/tools/networking/zap/default.nix
index f12578b273380..183f226f84b10 100644
--- a/pkgs/tools/networking/zap/default.nix
+++ b/pkgs/tools/networking/zap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jdk8, ant, runtimeShell }:
+{ lib, stdenv, fetchFromGitHub, jdk8, ant, runtimeShell }:
 
 let jdk = jdk8; in
 stdenv.mkDerivation rec {
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     chmod +x "$out/bin/zap"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.owasp.org/index.php/ZAP";
     description = "Java application for web penetration testing";
     maintainers = with maintainers; [ mog ];
diff --git a/pkgs/tools/networking/zerotierone/default.nix b/pkgs/tools/networking/zerotierone/default.nix
index 1413ca72a1052..96de4fc34e467 100644
--- a/pkgs/tools/networking/zerotierone/default.nix
+++ b/pkgs/tools/networking/zerotierone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchFromGitHub, openssl, lzo, zlib, iproute, ronn }:
+{ lib, stdenv, buildPackages, fetchFromGitHub, openssl, lzo, zlib, iproute, ronn }:
 
 stdenv.mkDerivation rec {
   pname = "zerotierone";
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create flat virtual Ethernet networks of almost unlimited size";
     homepage = "https://www.zerotier.com";
     license = licenses.bsl11;
diff --git a/pkgs/tools/nix/cached-nix-shell/default.nix b/pkgs/tools/nix/cached-nix-shell/default.nix
index 0b40e2b71435b..9acf9ed11c59c 100644
--- a/pkgs/tools/nix/cached-nix-shell/default.nix
+++ b/pkgs/tools/nix/cached-nix-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, pkgconfig, ronn, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, openssl, pkgconfig, ronn, rustPlatform }:
 
 let
   blake3-src = fetchFromGitHub {
@@ -36,7 +36,7 @@ in rustPlatform.buildRustPackage rec {
     make -f nix/Makefile post-install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Instant startup time for nix-shell";
     homepage = "https://github.com/xzfc/cached-nix-shell";
     license = with licenses; [ unlicense /* or */ mit ];
diff --git a/pkgs/tools/nix/dnadd/default.nix b/pkgs/tools/nix/dnadd/default.nix
index eff99743f1e1c..3f4d76a9c4d4e 100644
--- a/pkgs/tools/nix/dnadd/default.nix
+++ b/pkgs/tools/nix/dnadd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "dnadd";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/joelancaster/dnadd";
     description = "Adds packages declaratively on the command line";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/nix/manix/default.nix b/pkgs/tools/nix/manix/default.nix
index c4d1930a0fb53..f93e25efae7f5 100644
--- a/pkgs/tools/nix/manix/default.nix
+++ b/pkgs/tools/nix/manix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "manix";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0f2q3bj1cmpbma0fjhc2lc92j4al78fhrx3yc37kmbgzaza0yan5";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Fast Documentation Searcher for Nix";
     homepage    = "https://github.com/mlvzk/manix";
     license     = [ licenses.mpl20 ];
diff --git a/pkgs/tools/nix/nar-serve/default.nix b/pkgs/tools/nix/nar-serve/default.nix
index 89a38b40a1992..4b0239a2fa234 100644
--- a/pkgs/tools/nix/nar-serve/default.nix
+++ b/pkgs/tools/nix/nar-serve/default.nix
@@ -22,7 +22,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Serve NAR file contents via HTTP";
     homepage = "https://github.com/numtide/nar-serve";
     license = licenses.mit;
diff --git a/pkgs/tools/nix/nix-query-tree-viewer/default.nix b/pkgs/tools/nix/nix-query-tree-viewer/default.nix
index de0b88378a48c..f820f36e49f8c 100644
--- a/pkgs/tools/nix/nix-query-tree-viewer/default.nix
+++ b/pkgs/tools/nix/nix-query-tree-viewer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, glib, gtk3, wrapGAppsHook }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, glib, gtk3, wrapGAppsHook }:
 
 rustPlatform.buildRustPackage rec {
   pname = "nix-query-tree-viewer";
@@ -22,7 +22,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1pbyi7knqmqxbpi3jhl492is9zkaxdpdnmbm11nqwc1nvvbjblzc";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK viewer for the output of `nix store --query --tree`";
     homepage    = "https://github.com/cdepillabout/nix-query-tree-viewer";
     license     = with licenses; [ mit ];
diff --git a/pkgs/tools/nix/nix-script/default.nix b/pkgs/tools/nix/nix-script/default.nix
index d604463bb05cb..a755d933219e9 100644
--- a/pkgs/tools/nix/nix-script/default.nix
+++ b/pkgs/tools/nix/nix-script/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, haskellPackages, fetchFromGitHub }:
+{ lib, stdenv, haskellPackages, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "nix-script";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     ln -s $out/bin/nix-script $out/bin/nix-scripti
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A shebang for running inside nix-shell";
     homepage    = "https://github.com/bennofs/nix-script";
     license     = licenses.bsd3;
diff --git a/pkgs/tools/nix/nixdoc/default.nix b/pkgs/tools/nix/nixdoc/default.nix
index cdcb274945e2f..3d2e434912f6c 100644
--- a/pkgs/tools/nix/nixdoc/default.nix
+++ b/pkgs/tools/nix/nixdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "nixdoc";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1vamwynkbnffs8ryr2zb1a41cymjvr8zzh1bifyh9hpkx2k11rs3";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Generate documentation for Nix functions";
     homepage    = "https://github.com/tazjin/nixdoc";
     license     = [ licenses.gpl3 ];
diff --git a/pkgs/tools/nix/nixos-generators/default.nix b/pkgs/tools/nix/nixos-generators/default.nix
index 74bbcbd0ae6bb..871e223eb4be8 100644
--- a/pkgs/tools/nix/nixos-generators/default.nix
+++ b/pkgs/tools/nix/nixos-generators/default.nix
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${lib.makeBinPath [ jq coreutils findutils nix ] }
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of image builders";
     homepage    = "https://github.com/nix-community/nixos-generators";
     license     = licenses.mit;
diff --git a/pkgs/tools/package-management/appimagekit/default.nix b/pkgs/tools/package-management/appimagekit/default.nix
index 21e869b7b01e0..e392d8c4a7016 100644
--- a/pkgs/tools/package-management/appimagekit/default.nix
+++ b/pkgs/tools/package-management/appimagekit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , pkgconfig, cmake, autoconf, automake, libtool, makeWrapper
 , wget, xxd, desktop-file-utils, file
 , gnupg, glib, zlib, cairo, openssl, fuse, xz, squashfuse, inotify-tools, libarchive
@@ -109,7 +109,7 @@ in stdenv.mkDerivation rec {
     squashfuse = appimagekit_squashfuse;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to package desktop applications as AppImages";
     longDescription = ''
       AppImageKit is an implementation of the AppImage format that
diff --git a/pkgs/tools/package-management/apt-dater/default.nix b/pkgs/tools/package-management/apt-dater/default.nix
index 49669cba40a97..296012cc68f7e 100644
--- a/pkgs/tools/package-management/apt-dater/default.nix
+++ b/pkgs/tools/package-management/apt-dater/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook, pkgconfig, gettext
 , vim, glib, libxml2, ncurses, popt, screen
 }:
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/DE-IBH/apt-dater";
     description = "Terminal-based remote package update manager";
     longDescription = ''
diff --git a/pkgs/tools/package-management/bunny/default.nix b/pkgs/tools/package-management/bunny/default.nix
index 33c6249ebd47b..8ef808610db7a 100644
--- a/pkgs/tools/package-management/bunny/default.nix
+++ b/pkgs/tools/package-management/bunny/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab }:
+{ lib, stdenv, fetchFromGitLab }:
 
 stdenv.mkDerivation rec {
   pname = "bunny";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple shell script wrapper around multiple package managers";
     homepage = "https://gitlab.com/tim241/bunny";
     license = licenses.gpl3;
diff --git a/pkgs/tools/package-management/cargo-outdated/default.nix b/pkgs/tools/package-management/cargo-outdated/default.nix
index 185cba66e311e..a12271f5a99fb 100644
--- a/pkgs/tools/package-management/cargo-outdated/default.nix
+++ b/pkgs/tools/package-management/cargo-outdated/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl, libiconv, curl, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, pkg-config, openssl, libiconv, curl, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-outdated";
@@ -21,7 +21,7 @@ rustPlatform.buildRustPackage rec {
     curl
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cargo subcommand for displaying when Rust dependencies are out of date";
     homepage = "https://github.com/kbknapp/cargo-outdated";
     license = with licenses; [ asl20 /* or */ mit ];
diff --git a/pkgs/tools/package-management/cargo-release/default.nix b/pkgs/tools/package-management/cargo-release/default.nix
index d24eb6950f36d..64092ac2bb1d8 100644
--- a/pkgs/tools/package-management/cargo-release/default.nix
+++ b/pkgs/tools/package-management/cargo-release/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, libiconv, Security, openssl, pkg-config }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, libiconv, Security, openssl, pkg-config }:
 
 rustPlatform.buildRustPackage rec {
   pname = "cargo-release";
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
   buildInputs = [ openssl ]
   ++ stdenv.lib.optionals stdenv.isDarwin [ libiconv Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''Cargo subcommand "release": everything about releasing a rust crate'';
     homepage = "https://github.com/sunng87/cargo-release";
     license = with licenses; [ mit ];
diff --git a/pkgs/tools/package-management/cargo-update/default.nix b/pkgs/tools/package-management/cargo-update/default.nix
index 1158d10ed2964..4e3767579990c 100644
--- a/pkgs/tools/package-management/cargo-update/default.nix
+++ b/pkgs/tools/package-management/cargo-update/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , cmake
@@ -43,7 +43,7 @@ rustPlatform.buildRustPackage rec {
     installManPage man/*.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cargo subcommand for checking and applying updates to installed executables";
     homepage = "https://github.com/nabijaczleweli/cargo-update";
     license = licenses.mit;
diff --git a/pkgs/tools/package-management/cde/default.nix b/pkgs/tools/package-management/cde/default.nix
index 957919e260017..f2c308de5a76f 100644
--- a/pkgs/tools/package-management/cde/default.nix
+++ b/pkgs/tools/package-management/cde/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "cde";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     install -t $out/bin cde cde-exec
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://pg.ucsd.edu/cde/manual/";
     description = "A packaging tool for building portable packages";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/package-management/clib/default.nix b/pkgs/tools/package-management/clib/default.nix
index 3155891202718..e79c376ab7927 100644
--- a/pkgs/tools/package-management/clib/default.nix
+++ b/pkgs/tools/package-management/clib/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, curl  }:
+{ lib, stdenv, fetchFromGitHub, curl  }:
 
 stdenv.mkDerivation rec {
   version = "1.11.4";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ curl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C micro-package manager";
     homepage = "https://github.com/clibs/clib";
     license = licenses.mit;
diff --git a/pkgs/tools/package-management/createrepo_c/default.nix b/pkgs/tools/package-management/createrepo_c/default.nix
index 15a64ffd25e60..cc671d7329c5b 100644
--- a/pkgs/tools/package-management/createrepo_c/default.nix
+++ b/pkgs/tools/package-management/createrepo_c/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, bzip2, expat, glib, curl, libxml2, python3, rpm, openssl, sqlite, file, xz, pcre, bash-completion }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, bzip2, expat, glib, curl, libxml2, python3, rpm, openssl, sqlite, file, xz, pcre, bash-completion }:
 
 stdenv.mkDerivation rec {
   pname = "createrepo_c";
@@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ bzip2 expat glib curl libxml2 python3 rpm openssl sqlite file xz pcre bash-completion ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "C implementation of createrepo";
     homepage    = "http://rpm-software-management.github.io/createrepo_c/";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/package-management/dpkg/default.nix b/pkgs/tools/package-management/dpkg/default.nix
index 8b9d812ee3634..96032bc0a6951 100644
--- a/pkgs/tools/package-management/dpkg/default.nix
+++ b/pkgs/tools/package-management/dpkg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl, zlib, bzip2, xz, makeWrapper, coreutils }:
+{ lib, stdenv, fetchurl, perl, zlib, bzip2, xz, makeWrapper, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "dpkg";
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
       cp -r scripts/t/origins $out/etc/dpkg
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The Debian package manager";
     homepage = "https://wiki.debian.org/Teams/Dpkg";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/package-management/gx/default.nix b/pkgs/tools/package-management/gx/default.nix
index f9b996b277614..920b23f36abf6 100644
--- a/pkgs/tools/package-management/gx/default.nix
+++ b/pkgs/tools/package-management/gx/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by go2nix.
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gx";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A packaging tool built around IPFS";
     homepage = "https://github.com/whyrusleeping/gx";
     license = licenses.mit;
diff --git a/pkgs/tools/package-management/gx/go/default.nix b/pkgs/tools/package-management/gx/go/default.nix
index 8579ef574d55f..dd14976e63320 100644
--- a/pkgs/tools/package-management/gx/go/default.nix
+++ b/pkgs/tools/package-management/gx/go/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by go2nix.
-{ stdenv, buildGoPackage, fetchFromGitHub
+{ lib, stdenv, buildGoPackage, fetchFromGitHub
 , gx
 }:
 
@@ -25,7 +25,7 @@ buildGoPackage rec {
     }
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for importing go packages into gx";
     homepage = "https://github.com/whyrusleeping/gx-go";
     license = licenses.mit;
diff --git a/pkgs/tools/package-management/home-manager/default.nix b/pkgs/tools/package-management/home-manager/default.nix
index cff6122fe6d43..b8b4de36eb424 100644
--- a/pkgs/tools/package-management/home-manager/default.nix
+++ b/pkgs/tools/package-management/home-manager/default.nix
@@ -1,7 +1,7 @@
 #Adapted from
 #https://github.com/rycee/home-manager/blob/2c07829be2bcae55e04997b19719ff902a44016d/home-manager/default.nix
 
-{ bash, coreutils, findutils, gnused, less, stdenv, makeWrapper, fetchFromGitHub }:
+{ bash, coreutils, findutils, gnused, less, lib, stdenv, makeWrapper, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
       "$out/share/bash-completion/completions/home-manager"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A user environment configurator";
     homepage = "https://rycee.gitlab.io/home-manager/";
     platforms = platforms.unix;
diff --git a/pkgs/tools/package-management/libdnf/default.nix b/pkgs/tools/package-management/libdnf/default.nix
index 480222a45de2d..c93f3031e8256 100644
--- a/pkgs/tools/package-management/libdnf/default.nix
+++ b/pkgs/tools/package-management/libdnf/default.nix
@@ -1,4 +1,4 @@
-{ gcc9Stdenv, stdenv, fetchFromGitHub, cmake, gettext, pkg-config, gpgme, libsolv, openssl, check
+{ gcc9Stdenv, lib, stdenv, fetchFromGitHub, cmake, gettext, pkg-config, gpgme, libsolv, openssl, check
 , pcre, json_c, libmodulemd, libsmartcols, sqlite, librepo, libyaml, rpm }:
 
 gcc9Stdenv.mkDerivation rec {
@@ -56,7 +56,7 @@ gcc9Stdenv.mkDerivation rec {
     "-DWITH_ZCHUNK=OFF"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Package management library.";
     homepage = "https://github.com/rpm-software-management/libdnf";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/package-management/librepo/default.nix b/pkgs/tools/package-management/librepo/default.nix
index 203d5e20f8810..64a5bc32b5c9a 100644
--- a/pkgs/tools/package-management/librepo/default.nix
+++ b/pkgs/tools/package-management/librepo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , python
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     moveToOutput "lib/${python.libPrefix}" "$py"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library providing C and Python (libcURL like) API for downloading linux repository metadata and packages";
     homepage = "https://rpm-software-management.github.io/librepo/";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/tools/package-management/microdnf/default.nix b/pkgs/tools/package-management/microdnf/default.nix
index de473cf6a8988..af5d50460c1ab 100644
--- a/pkgs/tools/package-management/microdnf/default.nix
+++ b/pkgs/tools/package-management/microdnf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, gettext, libdnf, pkg-config, glib, libpeas, libsmartcols, help2man }:
+{ lib, stdenv, fetchFromGitHub, cmake, gettext, libdnf, pkg-config, glib, libpeas, libsmartcols, help2man }:
 
 stdenv.mkDerivation rec {
   pname = "microdnf";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkg-config cmake gettext help2man ];
   buildInputs = [ libdnf glib libpeas libsmartcols ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight implementation of dnf in C";
     homepage = "https://github.com/rpm-software-management/microdnf";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/package-management/mynewt-newt/default.nix b/pkgs/tools/package-management/mynewt-newt/default.nix
index 63e2ae12a6e5b..2390c33ca031f 100644
--- a/pkgs/tools/package-management/mynewt-newt/default.nix
+++ b/pkgs/tools/package-management/mynewt-newt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, fetchpatch }:
 
 buildGoModule rec {
   pname = "mynewt-newt";
@@ -26,7 +26,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://mynewt.apache.org/";
     description = "Build and package management tool for embedded development";
     longDescription = ''
diff --git a/pkgs/tools/package-management/nix-doc/default.nix b/pkgs/tools/package-management/nix-doc/default.nix
index 630ac6e94a9b3..66691d9f5c5a7 100644
--- a/pkgs/tools/package-management/nix-doc/default.nix
+++ b/pkgs/tools/package-management/nix-doc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, boost, nix, pkg-config }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, boost, nix, pkg-config }:
 
 rustPlatform.buildRustPackage rec {
   pname = "nix-doc";
@@ -18,7 +18,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1xz3qngs8p0s62dq4d46c01z3k1vvgg856767g56b13c38pzfh28";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interactive Nix documentation tool";
     longDescription = "An interactive Nix documentation tool providing a CLI for function search and a Nix plugin for docs in the REPL";
     homepage = "https://github.com/lf-/nix-doc";
diff --git a/pkgs/tools/package-management/nix-du/default.nix b/pkgs/tools/package-management/nix-du/default.nix
index 8356e43e2e654..0e4ad412e6786 100644
--- a/pkgs/tools/package-management/nix-du/default.nix
+++ b/pkgs/tools/package-management/nix-du/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, nix, boost, graphviz, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, nix, boost, graphviz, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "nix-du";
@@ -21,7 +21,7 @@ rustPlatform.buildRustPackage rec {
     nix
   ] ++ stdenv.lib.optional stdenv.isDarwin darwin.apple_sdk.frameworks.Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to determine which gc-roots take space in your nix store";
     homepage = "https://github.com/symphorien/nix-du";
     license = licenses.lgpl3;
diff --git a/pkgs/tools/package-management/nix-index/default.nix b/pkgs/tools/package-management/nix-index/default.nix
index 37a638c5670dd..af46c51235ed5 100644
--- a/pkgs/tools/package-management/nix-index/default.nix
+++ b/pkgs/tools/package-management/nix-index/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, pkgconfig, makeWrapper, openssl, curl
+{ lib, stdenv, rustPlatform, fetchFromGitHub, pkgconfig, makeWrapper, openssl, curl
 , nix, Security
 }:
 
@@ -30,7 +30,7 @@ rustPlatform.buildRustPackage rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ nix ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A files database for nixpkgs";
     homepage = "https://github.com/bennofs/nix-index";
     license = with licenses; [ bsd3 ];
diff --git a/pkgs/tools/package-management/nix-pin/default.nix b/pkgs/tools/package-management/nix-pin/default.nix
index f5dfacf319bcf..0e4005022ff93 100644
--- a/pkgs/tools/package-management/nix-pin/default.nix
+++ b/pkgs/tools/package-management/nix-pin/default.nix
@@ -42,7 +42,7 @@ let self = stdenv.mkDerivation rec {
           --modify-nix default.nix
       '';
     };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/timbertson/nix-pin";
     description = "nixpkgs development utility";
     license = licenses.mit;
diff --git a/pkgs/tools/package-management/nix-prefetch-scripts/default.nix b/pkgs/tools/package-management/nix-prefetch-scripts/default.nix
index bab12ca8e8df3..1b4ecc8afec4d 100644
--- a/pkgs/tools/package-management/nix-prefetch-scripts/default.nix
+++ b/pkgs/tools/package-management/nix-prefetch-scripts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, buildEnv,
+{ lib, stdenv, makeWrapper, buildEnv,
   breezy, coreutils, cvs, findutils, gawk, git, gnused, mercurial, nix, subversion
 }:
 
@@ -19,7 +19,7 @@ let mkPrefetchScript = tool: src: deps:
 
     preferLocalBuild = true;
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Script used to obtain source hashes for fetch${tool}";
       maintainers = with maintainers; [ bennofs ];
       platforms = stdenv.lib.platforms.unix;
@@ -37,7 +37,7 @@ in rec {
 
     paths = [ nix-prefetch-bzr nix-prefetch-cvs nix-prefetch-git nix-prefetch-hg nix-prefetch-svn ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Collection of all the nix-prefetch-* scripts which may be used to obtain source hashes";
       maintainers = with maintainers; [ bennofs ];
       platforms = stdenv.lib.platforms.unix;
diff --git a/pkgs/tools/package-management/nix-prefetch/default.nix b/pkgs/tools/package-management/nix-prefetch/default.nix
index f1f575a81b941..fb19d3dac6a1a 100644
--- a/pkgs/tools/package-management/nix-prefetch/default.nix
+++ b/pkgs/tools/package-management/nix-prefetch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, installShellFiles, makeWrapper, asciidoc
+{ lib, stdenv, fetchFromGitHub, installShellFiles, makeWrapper, asciidoc
 , docbook_xml_dtd_45, git, docbook_xsl, libxml2, libxslt, coreutils, gawk
 , gnugrep, gnused, jq, nix, fetchpatch }:
 
@@ -79,7 +79,7 @@ in stdenv.mkDerivation rec {
     cp -r contrib/hello_rs $out/share/doc/${pname}/contrib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prefetch any fetcher function call, e.g. package sources";
     license = licenses.mit;
     maintainers = with maintainers; [ msteen ];
diff --git a/pkgs/tools/package-management/nix-simple-deploy/default.nix b/pkgs/tools/package-management/nix-simple-deploy/default.nix
index 5782aa9dc35de..47734f73fd65b 100644
--- a/pkgs/tools/package-management/nix-simple-deploy/default.nix
+++ b/pkgs/tools/package-management/nix-simple-deploy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform }:
 
 rustPlatform.buildRustPackage rec {
   pname = "nix-simple-deploy";
@@ -13,7 +13,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0svnz9r0lrmz333qpbpdddjd46vh9i74qchws8aifa2qwnqy0kmn";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Deploy software or an entire NixOS system configuration to another NixOS system";
     homepage = "https://github.com/misuzu/nix-simple-deploy";
     license = with licenses; [ asl20 /* OR */ mit ];
diff --git a/pkgs/tools/package-management/nix-universal-prefetch/default.nix b/pkgs/tools/package-management/nix-universal-prefetch/default.nix
index 224ccd1cd9ed6..802fc4047bfcb 100644
--- a/pkgs/tools/package-management/nix-universal-prefetch/default.nix
+++ b/pkgs/tools/package-management/nix-universal-prefetch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , ruby
 }:
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --replace "/usr/bin/env nix-shell" "${ruby}/bin/ruby"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Uses nixpkgs fetchers to figure out hashes";
     homepage = "https://github.com/samueldr/nix-universal-prefetch";
     license = licenses.mit;
diff --git a/pkgs/tools/package-management/nixpkgs-review/default.nix b/pkgs/tools/package-management/nixpkgs-review/default.nix
index c093b2fab0ee8..b1a86f3137e40 100644
--- a/pkgs/tools/package-management/nixpkgs-review/default.nix
+++ b/pkgs/tools/package-management/nixpkgs-review/default.nix
@@ -21,7 +21,7 @@ python3.pkgs.buildPythonApplication rec {
     "--prefix" "PATH" ":" (lib.makeBinPath [ nixFlakes git ])
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Review pull-requests on https://github.com/NixOS/nixpkgs";
     homepage = "https://github.com/Mic92/nixpkgs-review";
     license = licenses.mit;
diff --git a/pkgs/tools/package-management/opkg-utils/default.nix b/pkgs/tools/package-management/opkg-utils/default.nix
index 373ebbeb02f88..2554ae47a4116 100644
--- a/pkgs/tools/package-management/opkg-utils/default.nix
+++ b/pkgs/tools/package-management/opkg-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit }:
+{ lib, stdenv, fetchgit }:
 
 stdenv.mkDerivation {
   name = "opkg-utils-20141030";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
     makeFlagsArray+=(PREFIX="$out")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Helper scripts for use with the opkg package manager";
     homepage = "http://git.yoctoproject.org/cgit/cgit.cgi/opkg-utils/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/package-management/opkg/default.nix b/pkgs/tools/package-management/opkg/default.nix
index 9195804a43dc9..4178e7d9707ad 100644
--- a/pkgs/tools/package-management/opkg/default.nix
+++ b/pkgs/tools/package-management/opkg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, curl, gpgme, libarchive, bzip2, lzma, attr, acl, libxml2
+{ lib, stdenv, fetchurl, pkgconfig, curl, gpgme, libarchive, bzip2, lzma, attr, acl, libxml2
 , autoreconfHook }:
 
 stdenv.mkDerivation rec {
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig autoreconfHook ];
   buildInputs = [ curl gpgme libarchive bzip2 lzma attr acl libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A lightweight package management system based upon ipkg";
     homepage = "https://git.yoctoproject.org/cgit/cgit.cgi/opkg/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/package-management/python2nix/default.nix b/pkgs/tools/package-management/python2nix/default.nix
index 675ec61f4db92..ceb919ecb8205 100644
--- a/pkgs/tools/package-management/python2nix/default.nix
+++ b/pkgs/tools/package-management/python2nix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 pythonPackages.buildPythonApplication {
   name = "python2nix-20140927";
@@ -12,7 +12,7 @@ pythonPackages.buildPythonApplication {
 
   propagatedBuildInputs = with pythonPackages; [ requests pip setuptools ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     maintainers = [ maintainers.domenkozar ];
     platforms = platforms.all;
   };
diff --git a/pkgs/tools/package-management/rpm/default.nix b/pkgs/tools/package-management/rpm/default.nix
index ac470d3e26a52..2f2080358e5e3 100644
--- a/pkgs/tools/package-management/rpm/default.nix
+++ b/pkgs/tools/package-management/rpm/default.nix
@@ -71,7 +71,7 @@ stdenv.mkDerivation rec {
     ln -sf $out/bin/{rpm,rpmverify}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.rpm.org/";
     license = licenses.gpl2;
     description = "The RPM Package Manager";
diff --git a/pkgs/tools/package-management/xbps/default.nix b/pkgs/tools/package-management/xbps/default.nix
index 108b64bd8b2f8..19fbe8ae43d64 100644
--- a/pkgs/tools/package-management/xbps/default.nix
+++ b/pkgs/tools/package-management/xbps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, which, zlib, openssl, libarchive }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, which, zlib, openssl, libarchive }:
 
 stdenv.mkDerivation rec {
   pname = "xbps";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/void-linux/xbps";
     description = "The X Binary Package System";
     platforms = platforms.linux; # known to not work on Darwin, at least
diff --git a/pkgs/tools/security/1password-gui/default.nix b/pkgs/tools/security/1password-gui/default.nix
index 667a21343e617..d9f7a7c7d3315 100644
--- a/pkgs/tools/security/1password-gui/default.nix
+++ b/pkgs/tools/security/1password-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , appimageTools
 , makeWrapper
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
 
   passthru.updateScript = ./update.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Multi-platform password manager";
     longDescription = ''
       1Password is a multi-platform package manager.
diff --git a/pkgs/tools/security/2fa/default.nix b/pkgs/tools/security/2fa/default.nix
index 7b6048660c454..41e4439eeb372 100644
--- a/pkgs/tools/security/2fa/default.nix
+++ b/pkgs/tools/security/2fa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   version = "1.1.0";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "0827vl2bxd6m2rbj00x7857cs7cic3mlg5nlhqzd0n73dm5vk2za";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://rsc.io/2fa";
     description = "Two-factor authentication on the command line";
     maintainers = with maintainers; [ rvolosatovs ];
diff --git a/pkgs/tools/security/acsccid/default.nix b/pkgs/tools/security/acsccid/default.nix
index 53842cbb1fc48..df30d18edfc65 100644
--- a/pkgs/tools/security/acsccid/default.nix
+++ b/pkgs/tools/security/acsccid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoconf
 , automake
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
     autoconf
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PC/SC driver for Linux/Mac OS X and it supports ACS CCID smart card readers";
     longDescription = ''
       acsccid is a PC/SC driver for Linux/Mac OS X and it supports ACS CCID smart card
diff --git a/pkgs/tools/security/aespipe/default.nix b/pkgs/tools/security/aespipe/default.nix
index e25416e55b88d..f0a1dbbf7aca5 100644
--- a/pkgs/tools/security/aespipe/default.nix
+++ b/pkgs/tools/security/aespipe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, sharutils, makeWrapper }:
+{ lib, stdenv, fetchurl, sharutils, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "aespipe";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
      --prefix PATH : $out/bin:${stdenv.lib.makeBinPath [ sharutils ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AES encrypting or decrypting pipe";
     homepage = "http://loop-aes.sourceforge.net/aespipe.README";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/afl/libdislocator.nix b/pkgs/tools/security/afl/libdislocator.nix
index 103786d12441d..1c22c7d1d244d 100644
--- a/pkgs/tools/security/afl/libdislocator.nix
+++ b/pkgs/tools/security/afl/libdislocator.nix
@@ -1,4 +1,4 @@
-{ stdenv, afl}:
+{ lib, stdenv, afl}:
 
 stdenv.mkDerivation {
   version = stdenv.lib.getVersion afl;
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/get-libdislocator-so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://lcamtuf.coredump.cx/afl/";
     description = ''
       Drop-in replacement for the libc allocator which improves
diff --git a/pkgs/tools/security/afl/qemu.nix b/pkgs/tools/security/afl/qemu.nix
index 3af44763a8a6a..31aac2430b8bb 100644
--- a/pkgs/tools/security/afl/qemu.nix
+++ b/pkgs/tools/security/afl/qemu.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, afl, python2, zlib, pkgconfig, glib, perl
+{ lib, stdenv, fetchurl, afl, python2, zlib, pkgconfig, glib, perl
 , texinfo, libuuid, flex, bison, pixman, autoconf
 }:
 
@@ -69,7 +69,7 @@ stdenv.mkDerivation {
       "--localstatedir=/var"
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.qemu.org/";
     description = "Fork of QEMU with AFL instrumentation support";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/aflplusplus/libdislocator.nix b/pkgs/tools/security/aflplusplus/libdislocator.nix
index 6f947a7280af6..99f9d51ea7e64 100644
--- a/pkgs/tools/security/aflplusplus/libdislocator.nix
+++ b/pkgs/tools/security/aflplusplus/libdislocator.nix
@@ -1,4 +1,4 @@
-{ stdenv, aflplusplus}:
+{ lib, stdenv, aflplusplus}:
 
 stdenv.mkDerivation {
   version = stdenv.lib.getVersion aflplusplus;
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/get-libdislocator-so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/vanhauser-thc/AFLplusplus";
     description = ''
       Drop-in replacement for the libc allocator which improves
diff --git a/pkgs/tools/security/aflplusplus/libtokencap.nix b/pkgs/tools/security/aflplusplus/libtokencap.nix
index 9421ee0d1e2b6..87e06ed9aeb94 100644
--- a/pkgs/tools/security/aflplusplus/libtokencap.nix
+++ b/pkgs/tools/security/aflplusplus/libtokencap.nix
@@ -1,4 +1,4 @@
-{ stdenv, aflplusplus}:
+{ lib, stdenv, aflplusplus}:
 
 stdenv.mkDerivation {
   version = stdenv.lib.getVersion aflplusplus;
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     chmod +x $out/bin/get-libtokencap-so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/vanhauser-thc/AFLplusplus";
     description = "strcmp & memcmp token capture library";
     license = stdenv.lib.licenses.asl20;
diff --git a/pkgs/tools/security/aflplusplus/qemu.nix b/pkgs/tools/security/aflplusplus/qemu.nix
index c51c839afe85b..cc6bf3a83efad 100644
--- a/pkgs/tools/security/aflplusplus/qemu.nix
+++ b/pkgs/tools/security/aflplusplus/qemu.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, aflplusplus, python2, zlib, pkgconfig, glib, perl
+{ lib, stdenv, fetchurl, aflplusplus, python2, zlib, pkgconfig, glib, perl
 , texinfo, libuuid, flex, bison, pixman, autoconf
 }:
 
@@ -73,7 +73,7 @@ stdenv.mkDerivation {
       "--localstatedir=/var"
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.qemu.org/";
     description = "Fork of QEMU with AFL++ instrumentation support";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/aide/default.nix b/pkgs/tools/security/aide/default.nix
index 59b7232075834..49291775e3796 100644
--- a/pkgs/tools/security/aide/default.nix
+++ b/pkgs/tools/security/aide/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, flex, bison, libmhash, zlib, acl, attr, libselinux, pcre }:
+{ lib, stdenv, fetchurl, flex, bison, libmhash, zlib, acl, attr, libselinux, pcre }:
 
 stdenv.mkDerivation rec {
   pname = "aide";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "--with-xattr"
     ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://aide.github.io/";
     description = "A file and directory integrity checker";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/asc-key-to-qr-code-gif/default.nix b/pkgs/tools/security/asc-key-to-qr-code-gif/default.nix
index ee5fa924cb6fb..b0e3a6449596f 100644
--- a/pkgs/tools/security/asc-key-to-qr-code-gif/default.nix
+++ b/pkgs/tools/security/asc-key-to-qr-code-gif/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, imagemagick, qrencode
+{ lib, stdenv, fetchFromGitHub, imagemagick, qrencode
 , testQR ? false, zbar ? null
 }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
     cp * $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/yishilin14/asc-key-to-qr-code-gif";
     description = "Convert ASCII-armored PGP keys to animated QR code";
     platforms = platforms.linux;
diff --git a/pkgs/tools/security/aws-iam-authenticator/default.nix b/pkgs/tools/security/aws-iam-authenticator/default.nix
index 44282d5f96434..851eed43adef4 100644
--- a/pkgs/tools/security/aws-iam-authenticator/default.nix
+++ b/pkgs/tools/security/aws-iam-authenticator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "aws-iam-authenticator";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "1ghl2vms9wmvczdl2raqhy0gffxmk24h158gjb5mlw7rggzvb7bg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kubernetes-sigs/aws-iam-authenticator";
     description = "AWS IAM credentials for Kubernetes authentication";
     license = licenses.asl20;
diff --git a/pkgs/tools/security/aws-okta/default.nix b/pkgs/tools/security/aws-okta/default.nix
index 340c2cd971c6f..de84e43b5aa6b 100644
--- a/pkgs/tools/security/aws-okta/default.nix
+++ b/pkgs/tools/security/aws-okta/default.nix
@@ -1,4 +1,4 @@
-{ buildGoPackage, fetchFromGitHub, libusb1, pkgconfig, stdenv, libiconv }:
+{ buildGoPackage, fetchFromGitHub, libusb1, pkgconfig, lib, stdenv, libiconv }:
 
 buildGoPackage rec {
   pname = "aws-okta";
@@ -20,7 +20,7 @@ buildGoPackage rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libusb1  libiconv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     description = "aws-vault like tool for Okta authentication";
     license = licenses.mit;
diff --git a/pkgs/tools/security/bash-supergenpass/default.nix b/pkgs/tools/security/bash-supergenpass/default.nix
index 53bc45acf8f70..cbacf8b33a471 100644
--- a/pkgs/tools/security/bash-supergenpass/default.nix
+++ b/pkgs/tools/security/bash-supergenpass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , unstableGitUpdater
 , makeWrapper
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
 
   passthru.updateScript = unstableGitUpdater { };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Bash shell-script implementation of SuperGenPass password generation";
     longDescription = ''
       Bash shell-script implementation of SuperGenPass password generation
diff --git a/pkgs/tools/security/bettercap/default.nix b/pkgs/tools/security/bettercap/default.nix
index 17cb0308a168e..3b0a6ca626407 100644
--- a/pkgs/tools/security/bettercap/default.nix
+++ b/pkgs/tools/security/bettercap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 , pkg-config
@@ -27,7 +27,7 @@ buildGoModule rec {
   buildInputs = [ libpcap libusb1 ]
     ++ stdenv.lib.optionals stdenv.isLinux [ libnfnetlink libnetfilter_queue ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A man in the middle tool";
     longDescription = ''
       BetterCAP is a powerful, flexible and portable tool created to perform various types of MITM attacks against a network, manipulate HTTP, HTTPS and TCP traffic in realtime, sniff for credentials and much more.
diff --git a/pkgs/tools/security/bitwarden/default.nix b/pkgs/tools/security/bitwarden/default.nix
index c35a4d60e9e79..9bbcdab6bf7d8 100644
--- a/pkgs/tools/security/bitwarden/default.nix
+++ b/pkgs/tools/security/bitwarden/default.nix
@@ -24,7 +24,7 @@ let
     x86_64-linux = "1z1r8327xymqf2h98wb2fb02s41pxc6fh5w4bxmdgpx7k1jx5kvg";
   }.${system} or "";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A secure and free password manager for all of your devices";
     homepage = "https://bitwarden.com";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/bitwarden_rs/default.nix b/pkgs/tools/security/bitwarden_rs/default.nix
index 57e865ef596a7..482ba400e637d 100644
--- a/pkgs/tools/security/bitwarden_rs/default.nix
+++ b/pkgs/tools/security/bitwarden_rs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, nixosTests
+{ lib, stdenv, rustPlatform, fetchFromGitHub, nixosTests
 , pkgconfig, openssl
 , Security, CoreServices
 , dbBackend ? "sqlite", libmysqlclient, postgresql }:
@@ -37,7 +37,7 @@ in rustPlatform.buildRustPackage rec {
 
   passthru.tests = nixosTests.bitwarden;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Unofficial Bitwarden compatible server written in Rust";
     homepage = "https://github.com/dani-garcia/bitwarden_rs";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/bitwarden_rs/vault.nix b/pkgs/tools/security/bitwarden_rs/vault.nix
index 786ff57845577..a6e238f9085b7 100644
--- a/pkgs/tools/security/bitwarden_rs/vault.nix
+++ b/pkgs/tools/security/bitwarden_rs/vault.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, nixosTests }:
+{ lib, stdenv, fetchurl, nixosTests }:
 
 stdenv.mkDerivation rec {
   pname = "bitwarden_rs-vault";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   passthru.tests = nixosTests.bitwarden;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Integrates the web vault into bitwarden_rs";
     homepage = "https://github.com/dani-garcia/bw_web_builds";
     platforms = platforms.all;
diff --git a/pkgs/tools/security/bmrsa/11.nix b/pkgs/tools/security/bmrsa/11.nix
index c7d4c4d017416..c8188fe4216a0 100644
--- a/pkgs/tools/security/bmrsa/11.nix
+++ b/pkgs/tools/security/bmrsa/11.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "bmrsa";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     echo -e 'install:\n\tcp bmrsa '$out'/bin' >> Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "RSA utility";
     homepage = "http://bmrsa.sourceforge.net/";
     license = licenses.gpl1;
diff --git a/pkgs/tools/security/bruteforce-luks/default.nix b/pkgs/tools/security/bruteforce-luks/default.nix
index cfa27a5c6865f..084368c105b2e 100644
--- a/pkgs/tools/security/bruteforce-luks/default.nix
+++ b/pkgs/tools/security/bruteforce-luks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, cryptsetup }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, cryptsetup }:
 
 stdenv.mkDerivation rec {
   pname = "bruteforce-luks";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Cracks passwords of LUKS encrypted volumes";
     longDescription = ''
diff --git a/pkgs/tools/security/brutespray/default.nix b/pkgs/tools/security/brutespray/default.nix
index 78dd789047d07..69d8dbc96235e 100644
--- a/pkgs/tools/security/brutespray/default.nix
+++ b/pkgs/tools/security/brutespray/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchFromGitHub, makeWrapper, medusa }:
+{ lib, stdenv, python3, fetchFromGitHub, makeWrapper, medusa }:
 
 stdenv.mkDerivation rec {
   pname = "brutespray";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     cp -r wordlist/ $out/share/brutespray/wordlist
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/x90skysn3k/brutespray";
     description = "Brute-Forcing from Nmap output - Automatically attempts default creds on found services";
     license = licenses.mit;
diff --git a/pkgs/tools/security/ccid/default.nix b/pkgs/tools/security/ccid/default.nix
index b7f408e748fd9..1be561dae5490 100644
--- a/pkgs/tools/security/ccid/default.nix
+++ b/pkgs/tools/security/ccid/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pcsclite, pkgconfig, libusb1, perl }:
+{ lib, stdenv, fetchurl, pcsclite, pkgconfig, libusb1, perl }:
 
 stdenv.mkDerivation rec {
   pname = "ccid";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig perl ];
   buildInputs = [ pcsclite libusb1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ccid drivers for pcsclite";
     homepage = "https://ccid.apdu.fr/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/certmgr/default.nix b/pkgs/tools/security/certmgr/default.nix
index be3f891cc8bbb..47848b25b435e 100644
--- a/pkgs/tools/security/certmgr/default.nix
+++ b/pkgs/tools/security/certmgr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, fetchpatch }:
 
 let
   generic = { patches ? [] }:
@@ -17,7 +17,7 @@ let
 
       inherit patches;
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         homepage = "https://cfssl.org/";
         description = "Cloudflare's certificate manager";
         platforms = platforms.linux;
diff --git a/pkgs/tools/security/certstrap/default.nix b/pkgs/tools/security/certstrap/default.nix
index 99ba5c9e29b77..f0c756f54f9d4 100644
--- a/pkgs/tools/security/certstrap/default.nix
+++ b/pkgs/tools/security/certstrap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "certstrap";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "1ymchnn7c9g3pq7rw4lrwsd6z3wfjx90g7qgrw6r5hssl77mnscj";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Tools to bootstrap CAs, certificate requests, and signed certificates";
     license = licenses.asl20;
diff --git a/pkgs/tools/security/cfssl/default.nix b/pkgs/tools/security/cfssl/default.nix
index d926aaca68fb4..835c5daa72c57 100644
--- a/pkgs/tools/security/cfssl/default.nix
+++ b/pkgs/tools/security/cfssl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub, go-rice }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub, go-rice }:
 
 buildGoModule rec {
   pname = "cfssl";
@@ -40,7 +40,7 @@ buildGoModule rec {
       -X github.com/cloudflare/cfssl/cli/version.version=v${version}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://cfssl.org/";
     description = "Cloudflare's PKI and TLS toolkit";
     license = licenses.bsd2;
diff --git a/pkgs/tools/security/chaps/default.nix b/pkgs/tools/security/chaps/default.nix
index decc9ba31268c..0200fca8ff37c 100644
--- a/pkgs/tools/security/chaps/default.nix
+++ b/pkgs/tools/security/chaps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitiles, fetchFromGitHub, fetchurl, trousers, leveldb, unzip
+{ lib, stdenv, fetchFromGitiles, fetchFromGitHub, fetchurl, trousers, leveldb, unzip
 , scons, pkgconfig, glib, dbus_cplusplus, dbus, protobuf, openssl, snappy, pam
 }:
 
@@ -80,7 +80,7 @@ stdenv.mkDerivation rec {
     cp ${name}/man/* $out/usr/share/man/man8/.
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PKCS #11 implementation based on trusted platform module (TPM)";
     homepage = "https://www.chromium.org/developers/design-documents/chaps-technical-design";
     maintainers = [ maintainers.tstrobel ];
diff --git a/pkgs/tools/security/chipsec/default.nix b/pkgs/tools/security/chipsec/default.nix
index 0f162347cc831..45d6349af4036 100644
--- a/pkgs/tools/security/chipsec/default.nix
+++ b/pkgs/tools/security/chipsec/default.nix
@@ -25,7 +25,7 @@ pythonPackages.buildPythonApplication rec {
 
   KERNEL_SRC_DIR = lib.optionalString withDriver "${kernel.dev}/lib/modules/${kernel.modDirVersion}/build";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Platform Security Assessment Framework";
     longDescription = ''
       CHIPSEC is a framework for analyzing the security of PC platforms
diff --git a/pkgs/tools/security/chkrootkit/default.nix b/pkgs/tools/security/chkrootkit/default.nix
index 864d73aaa9720..5753784542dad 100644
--- a/pkgs/tools/security/chkrootkit/default.nix
+++ b/pkgs/tools/security/chkrootkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "chkrootkit-0.53";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp check_wtmpx chkdirs chklastlog chkproc chkrootkit chkutmp chkwtmp ifpromisc strings-static $out/sbin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Locally checks for signs of a rootkit";
     homepage = "http://www.chkrootkit.org/";
     license = licenses.bsd2;
diff --git a/pkgs/tools/security/chntpw/default.nix b/pkgs/tools/security/chntpw/default.nix
index 0a44c463eb70a..d0b75bdd42b28 100644
--- a/pkgs/tools/security/chntpw/default.nix
+++ b/pkgs/tools/security/chntpw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 stdenv.mkDerivation rec {
   pname = "chntpw";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     make install PREFIX=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pogostick.net/~pnh/ntpasswd/";
     description = "An utility to reset the password of any user that has a valid local account on a Windows system";
     maintainers = with stdenv.lib.maintainers; [ deepfire ];
diff --git a/pkgs/tools/security/chrome-token-signing/default.nix b/pkgs/tools/security/chrome-token-signing/default.nix
index 0065758e1c3f8..134f916f0434e 100644
--- a/pkgs/tools/security/chrome-token-signing/default.nix
+++ b/pkgs/tools/security/chrome-token-signing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, pcsclite, pkgconfig, opensc }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, pcsclite, pkgconfig, opensc }:
 
 mkDerivation rec {
   pname = "chrome-token-signing";
@@ -28,7 +28,7 @@ mkDerivation rec {
     install -D -t $out/lib/mozilla/native-messaging-hosts host-linux/ff/ee.ria.esteid.json
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chrome and Firefox extension for signing with your eID on the web";
     homepage = "https://github.com/open-eid/chrome-token-signing/wiki";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/security/clamav/default.nix b/pkgs/tools/security/clamav/default.nix
index e3c57cbc9e900..4b3048223f7a4 100644
--- a/pkgs/tools/security/clamav/default.nix
+++ b/pkgs/tools/security/clamav/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkg-config
+{ lib, stdenv, fetchurl, pkg-config
 , zlib, bzip2, libiconv, libxml2, openssl, ncurses, curl, libmilter, pcre2
 , libmspack, systemd, Foundation, json_c, check
 }:
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
   hardeningDisable = [ "format" ];
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.clamav.net";
     description = "Antivirus engine designed for detecting Trojans, viruses, malware and other malicious threats";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/cloudbrute/default.nix b/pkgs/tools/security/cloudbrute/default.nix
index 20f4a9a0d07b1..06f0dd413a5fb 100644
--- a/pkgs/tools/security/cloudbrute/default.nix
+++ b/pkgs/tools/security/cloudbrute/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "0f3n0wrmg9d2qyn8hlnhf9lsfqd9443myzr04p48v68m8n83j6a9";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cloud enumeration tool";
     longDescription = ''
       A tool to find a company (target) infrastructure, files, and apps on
diff --git a/pkgs/tools/security/crackxls/default.nix b/pkgs/tools/security/crackxls/default.nix
index aff6bbd028ad4..33a219e86218b 100644
--- a/pkgs/tools/security/crackxls/default.nix
+++ b/pkgs/tools/security/crackxls/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, autoconf, automake, openssl, libgsf, gmp }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, autoconf, automake, openssl, libgsf, gmp }:
 
 stdenv.mkDerivation rec {
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     cp crackxls2003 $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/GavinSmith0123/crackxls2003/";
     description = "Used to break the encryption on old Microsoft Excel and Microsoft Word files";
     platforms = platforms.linux;
diff --git a/pkgs/tools/security/creddump/default.nix b/pkgs/tools/security/creddump/default.nix
index ffa2fd2311c1a..7a936408433a2 100644
--- a/pkgs/tools/security/creddump/default.nix
+++ b/pkgs/tools/security/creddump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, python2, python2Packages }:
+{ lib, stdenv, fetchFromGitLab, python2, python2Packages }:
 
 python2Packages.buildPythonApplication rec {
   pname = "creddump";
@@ -24,7 +24,7 @@ python2Packages.buildPythonApplication rec {
     cp lsadump.py ${placeholder "out"}/bin/lsadump
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python tool to extract various credentials and secrets from Windows registry hives";
     homepage = "https://gitlab.com/kalilinux/packages/creddump";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/crowbar/default.nix b/pkgs/tools/security/crowbar/default.nix
index cd4e7db87186e..2f197421e1f71 100644
--- a/pkgs/tools/security/crowbar/default.nix
+++ b/pkgs/tools/security/crowbar/default.nix
@@ -3,7 +3,7 @@
 , nmap
 , openvpn
 , python3Packages
-, stdenv
+, lib, stdenv
 , tigervnc
 }:
 
@@ -33,7 +33,7 @@ python3Packages.buildPythonApplication rec {
     $out/bin/crowbar --help > /dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/galkan/crowbar";
     description = "A brute forcing tool that can be used during penetration tests";
     license = licenses.mit;
diff --git a/pkgs/tools/security/crunch/default.nix b/pkgs/tools/security/crunch/default.nix
index b53ead1c8527c..2422a2278bb5c 100644
--- a/pkgs/tools/security/crunch/default.nix
+++ b/pkgs/tools/security/crunch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which }:
+{ lib, stdenv, fetchurl, which }:
 
 stdenv.mkDerivation  rec {
   pname = "crunch";
@@ -20,7 +20,7 @@ stdenv.mkDerivation  rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wordlist generator";
     homepage = "https://sourceforge.net/projects/crunch-wordlist/";
     platforms = platforms.unix;
diff --git a/pkgs/tools/security/ctmg/default.nix b/pkgs/tools/security/ctmg/default.nix
index a30523c3bbc19..b08af06825e3c 100644
--- a/pkgs/tools/security/ctmg/default.nix
+++ b/pkgs/tools/security/ctmg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "ctmg";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   installPhase = "install -D ctmg.sh $out/bin/ctmg";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An encrypted container manager for Linux using cryptsetup";
     homepage = "https://git.zx2c4.com/ctmg/about/";
     license = licenses.isc;
diff --git a/pkgs/tools/security/deepsea/default.nix b/pkgs/tools/security/deepsea/default.nix
index 5cd7ed48aa342..855549bb0c813 100644
--- a/pkgs/tools/security/deepsea/default.nix
+++ b/pkgs/tools/security/deepsea/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "0vpkzykfg1rq4qi1v5lsa0drpil9i6ccfw96k48ppi9hiwzpq94w";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Phishing tool for red teams and pentesters";
     longDescription = ''
       DeepSea phishing gear aims to help RTOs and pentesters with the
diff --git a/pkgs/tools/security/dnsenum/default.nix b/pkgs/tools/security/dnsenum/default.nix
index 3374c827d7565..a24fc96621f12 100644
--- a/pkgs/tools/security/dnsenum/default.nix
+++ b/pkgs/tools/security/dnsenum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, perl, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, perl, perlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "dnsenum";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -vD dns.txt -t $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/fwaeytens/dnsenum";
     description = "A tool to enumerate DNS information";
     maintainers = with maintainers; [ c0bw3b ];
diff --git a/pkgs/tools/security/dnsrecon/default.nix b/pkgs/tools/security/dnsrecon/default.nix
index 2575636aeca24..65b18c5c8226f 100644
--- a/pkgs/tools/security/dnsrecon/default.nix
+++ b/pkgs/tools/security/dnsrecon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "dnsrecon";
@@ -34,7 +34,7 @@ python3.pkgs.buildPythonApplication rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DNS Enumeration Script";
     homepage = "https://github.com/darkoperator/dnsrecon";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/dnsx/default.nix b/pkgs/tools/security/dnsx/default.nix
index 21bf7d4664cc9..1a82467201dfa 100644
--- a/pkgs/tools/security/dnsx/default.nix
+++ b/pkgs/tools/security/dnsx/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "0j2cqvskzxbyfrvsv4gm4qwfjm0digizcg157z5iignnknddajax";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and multi-purpose DNS toolkit";
     longDescription = ''
       dnsx is a fast and multi-purpose DNS toolkit allow to run multiple
diff --git a/pkgs/tools/security/doona/default.nix b/pkgs/tools/security/doona/default.nix
index 5e1233f308c3f..e0f459ad7453d 100644
--- a/pkgs/tools/security/doona/default.nix
+++ b/pkgs/tools/security/doona/default.nix
@@ -1,5 +1,5 @@
 { fetchFromGitHub
-, stdenv
+, lib, stdenv
 , perl
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/doona
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/wireghoul/doona";
     description = "A fork of the Bruteforce Exploit Detector Tool (BED)";
     longDescription = ''
diff --git a/pkgs/tools/security/ecdsatool/default.nix b/pkgs/tools/security/ecdsatool/default.nix
index b1a86fe7e64a7..0498b758c1d32 100644
--- a/pkgs/tools/security/ecdsatool/default.nix
+++ b/pkgs/tools/security/ecdsatool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgs }:
+{ lib, stdenv, pkgs }:
 
 stdenv.mkDerivation {
   version = "0.0.1";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = with pkgs; [openssl autoconf automake];
   buildInputs = with pkgs; [libuecc];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create and manipulate ECC NISTP256 keypairs";
     homepage = "https://github.com/kaniini/ecdsatool/";
     license = with licenses; [free];
diff --git a/pkgs/tools/security/ecdsautils/default.nix b/pkgs/tools/security/ecdsautils/default.nix
index f5ead317f4ecd..adf1a74f42af0 100644
--- a/pkgs/tools/security/ecdsautils/default.nix
+++ b/pkgs/tools/security/ecdsautils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgs }:
+{ lib, stdenv, pkgs }:
 
 stdenv.mkDerivation {
   version = "0.4.0";
@@ -14,7 +14,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = with pkgs; [ cmake pkgconfig doxygen ];
   buildInputs = with pkgs; [ libuecc  ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tiny collection of programs used for ECDSA (keygen, sign, verify)";
     homepage = "https://github.com/tcatm/ecdsautils/";
     license = with licenses; [ mit bsd2 ];
diff --git a/pkgs/tools/security/ecryptfs/default.nix b/pkgs/tools/security/ecryptfs/default.nix
index 1a8329885ba2a..dbec36cb12b05 100644
--- a/pkgs/tools/security/ecryptfs/default.nix
+++ b/pkgs/tools/security/ecryptfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, perl, util-linux, keyutils, nss, nspr, python2, pam, enablePython ? false
+{ lib, stdenv, fetchurl, pkgconfig, perl, util-linux, keyutils, nss, nspr, python2, pam, enablePython ? false
 , intltool, makeWrapper, coreutils, bash, gettext, cryptsetup, lvm2, rsync, which, lsof }:
 
 stdenv.mkDerivation rec {
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enterprise-class stacked cryptographic filesystem";
     license     = licenses.gpl2Plus;
     maintainers = with maintainers; [ obadz ];
diff --git a/pkgs/tools/security/ecryptfs/helper.nix b/pkgs/tools/security/ecryptfs/helper.nix
index fcb8d091d933e..ecd12a2738d82 100644
--- a/pkgs/tools/security/ecryptfs/helper.nix
+++ b/pkgs/tools/security/ecryptfs/helper.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeWrapper
 , python2
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     makeWrapper "${python2.interpreter}" "$out/bin/ecryptfs-helper" --add-flags "$out/libexec/ecryptfs-helper.py"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description    = "Helper script to create/mount/unemount encrypted directories using eCryptfs without needing root permissions";
     license        = licenses.gpl2Plus;
     maintainers    = with maintainers; [ obadz ];
diff --git a/pkgs/tools/security/efitools/default.nix b/pkgs/tools/security/efitools/default.nix
index 33b6c3b672da1..60bb3627cc993 100644
--- a/pkgs/tools/security/efitools/default.nix
+++ b/pkgs/tools/security/efitools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gnu-efi, openssl, sbsigntool, perl, perlPackages,
+{ lib, stdenv, gnu-efi, openssl, sbsigntool, perl, perlPackages,
 help2man, fetchgit }:
 stdenv.mkDerivation rec {
   pname = "efitools";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     patchShebangs .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for manipulating UEFI secure boot platforms";
     homepage = "https://git.kernel.org/cgit/linux/kernel/git/jejb/efitools.git";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/eid-mw/default.nix b/pkgs/tools/security/eid-mw/default.nix
index a55c1d8db6616..116add243144e 100644
--- a/pkgs/tools/security/eid-mw/default.nix
+++ b/pkgs/tools/security/eid-mw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook, pkgconfig
 , gtk3, nssTools, pcsclite
 , libxml2, libproxy
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Belgian electronic identity card (eID) middleware";
     homepage = "https://eid.belgium.be/en/using_your_eid/installing_the_eid_software/linux/";
     license = licenses.lgpl3;
diff --git a/pkgs/tools/security/encryptr/default.nix b/pkgs/tools/security/encryptr/default.nix
index 62311a41da370..0cbfd79296dc0 100644
--- a/pkgs/tools/security/encryptr/default.nix
+++ b/pkgs/tools/security/encryptr/default.nix
@@ -47,7 +47,7 @@ in stdenv.mkDerivation rec {
   # its application and shows a generic page
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://spideroak.com/solutions/encryptr";
     description = "Free, private and secure password management tool and e-wallet";
     license = licenses.unfree;
diff --git a/pkgs/tools/security/enpass/default.nix b/pkgs/tools/security/enpass/default.nix
index be2e5b06246d0..3b25dd58b3479 100644
--- a/pkgs/tools/security/enpass/default.nix
+++ b/pkgs/tools/security/enpass/default.nix
@@ -51,7 +51,7 @@ let
       url = "${baseUrl}/${data.path}";
     };
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A well known password manager";
       homepage = "https://www.enpass.io/";
       license = licenses.unfree;
diff --git a/pkgs/tools/security/enum4linux/default.nix b/pkgs/tools/security/enum4linux/default.nix
index 9a7d1861d9bd6..4fe567d1ed0f5 100644
--- a/pkgs/tools/security/enum4linux/default.nix
+++ b/pkgs/tools/security/enum4linux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, samba, perl, openldap }:
+{ lib, stdenv, fetchurl, makeWrapper, samba, perl, openldap }:
 
 stdenv.mkDerivation rec {
   pname = "enum4linux";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ samba openldap ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool for enumerating information from Windows and Samba systems";
     homepage = "https://labs.portcullis.co.uk/tools/enum4linux/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/eschalot/default.nix b/pkgs/tools/security/eschalot/default.nix
index 28df3a284427d..0467506161524 100644
--- a/pkgs/tools/security/eschalot/default.nix
+++ b/pkgs/tools/security/eschalot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl }:
+{ lib, stdenv, fetchFromGitHub, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "eschalot";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     install -D -t $out/bin eschalot worgen
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tor hidden service name generator";
     homepage = src.meta.homepage;
     license = licenses.isc;
diff --git a/pkgs/tools/security/fail2ban/default.nix b/pkgs/tools/security/fail2ban/default.nix
index c27f82d70536b..45bea0ae99f1b 100644
--- a/pkgs/tools/security/fail2ban/default.nix
+++ b/pkgs/tools/security/fail2ban/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 let version = "0.11.1"; in
 
@@ -49,7 +49,7 @@ python3.pkgs.buildPythonApplication {
     rm -rf ${sitePackages}/etc ${sitePackages}/usr ${sitePackages}/var;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage    = "https://www.fail2ban.org/";
     description = "A program that scans log files for repeated failing login attempts and bans IP addresses";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/fcrackzip/default.nix b/pkgs/tools/security/fcrackzip/default.nix
index 15510f7b70967..31d0b44fb710d 100644
--- a/pkgs/tools/security/fcrackzip/default.nix
+++ b/pkgs/tools/security/fcrackzip/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "fcrackzip";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   # Do not clash with unizp/zipinfo
   postInstall = "mv $out/bin/zipinfo $out/bin/fcrackzip-zipinfo";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "zip password cracker, similar to fzc, zipcrack and others";
     homepage = "http://oldhome.schmorp.de/marc/fcrackzip.html";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/ffuf/default.nix b/pkgs/tools/security/ffuf/default.nix
index 77a286df4c695..084601a412228 100644
--- a/pkgs/tools/security/ffuf/default.nix
+++ b/pkgs/tools/security/ffuf/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -20,7 +20,7 @@ buildGoModule rec {
   # https://github.com/ffuf/ffuf/issues/367
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast web fuzzer written in Go";
     longDescription = ''
       FFUF, or “Fuzz Faster you Fool” is an open source web fuzzing tool,
diff --git a/pkgs/tools/security/fido2luks/default.nix b/pkgs/tools/security/fido2luks/default.nix
index d2a5d91467a89..e0dcdadb7b073 100644
--- a/pkgs/tools/security/fido2luks/default.nix
+++ b/pkgs/tools/security/fido2luks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , rustPlatform
 , fetchFromGitHub
 , cryptsetup
@@ -27,7 +27,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "19drjql13z8bw257z10kjppxm25jlfgrpc9g1jf68ka5j2b3nx7k";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Decrypt your LUKS partition using a FIDO2 compatible authenticator";
     homepage = "https://github.com/shimunn/fido2luks";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/fierce/default.nix b/pkgs/tools/security/fierce/default.nix
index 13146c3373e7a..3d6472cbb44f8 100644
--- a/pkgs/tools/security/fierce/default.nix
+++ b/pkgs/tools/security/fierce/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3 }:
+{ lib, stdenv, fetchFromGitHub, python3 }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "fierce";
@@ -21,7 +21,7 @@ python3.pkgs.buildPythonApplication rec {
   doCheck = false;
   pythonImportsCheck = [ "fierce" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mschwager/fierce";
     description = "DNS reconnaissance tool for locating non-contiguous IP space";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/fprintd/default.nix b/pkgs/tools/security/fprintd/default.nix
index b14aff386abad..368f49d944d2f 100644
--- a/pkgs/tools/security/fprintd/default.nix
+++ b/pkgs/tools/security/fprintd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , fetchpatch
 , pkgconfig
@@ -106,7 +106,7 @@ stdenv.mkDerivation rec {
     patchShebangs po/check-translations.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://fprint.freedesktop.org/";
     description = "D-Bus daemon that offers libfprint functionality over the D-Bus interprocess communication bus";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/fprot/default.nix b/pkgs/tools/security/fprot/default.nix
index 12b47694db3c7..22779327a9bf1 100644
--- a/pkgs/tools/security/fprot/default.nix
+++ b/pkgs/tools/security/fprot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
     cp doc/man/fpupdate.8 $out/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.f-prot.com";
     description = "A popular proprietary antivirus program";
     license = licenses.unfree;
diff --git a/pkgs/tools/security/fwknop/default.nix b/pkgs/tools/security/fwknop/default.nix
index 0f1c37aa79752..d3787f834d03f 100644
--- a/pkgs/tools/security/fwknop/default.nix
+++ b/pkgs/tools/security/fwknop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook
+{ lib, stdenv, fetchFromGitHub, autoreconfHook
 , libpcap, texinfo
 , iptables
 , gnupgSupport ? true, gnupg, gpgme # Increases dependencies!
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
       "wknopddir = $out/etc/fwknop"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "Single Packet Authorization (and Port Knocking) server/client";
     longDescription = ''
diff --git a/pkgs/tools/security/gau/default.nix b/pkgs/tools/security/gau/default.nix
index cfbae951526ca..98045a107e50b 100644
--- a/pkgs/tools/security/gau/default.nix
+++ b/pkgs/tools/security/gau/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "17ag2wvaxv2dyx3yx3fvlf36ww4a44660pn4gvpbrwacsan9as5s";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to fetch known URLs";
     longDescription = ''
       getallurls (gau) fetches known URLs from various sources for any
diff --git a/pkgs/tools/security/gen-oath-safe/default.nix b/pkgs/tools/security/gen-oath-safe/default.nix
index 68536a519aa35..670b9631f219a 100644
--- a/pkgs/tools/security/gen-oath-safe/default.nix
+++ b/pkgs/tools/security/gen-oath-safe/default.nix
@@ -1,4 +1,4 @@
-{ coreutils, fetchFromGitHub, file, libcaca, makeWrapper, python, openssl, qrencode, stdenv, yubikey-manager }:
+{ coreutils, fetchFromGitHub, file, libcaca, makeWrapper, python, openssl, qrencode, lib, stdenv, yubikey-manager }:
 
 stdenv.mkDerivation rec {
   pname = "gen-oath-safe";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
       wrapProgram $out/bin/gen-oath-safe \
         --prefix PATH : ${path}
     '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mcepl/gen-oath-safe";
     description = "Script for generating HOTP/TOTP keys (and QR code)";
     platforms =  platforms.unix;
diff --git a/pkgs/tools/security/gencfsm/default.nix b/pkgs/tools/security/gencfsm/default.nix
index e56c9e20fd43d..a41c995ab407f 100644
--- a/pkgs/tools/security/gencfsm/default.nix
+++ b/pkgs/tools/security/gencfsm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, intltool, libtool, pkgconfig, encfs
+{ lib, stdenv, fetchurl, autoconf, automake, intltool, libtool, pkgconfig, encfs
 , glib , gnome3, gtk3, libgnome-keyring, vala, wrapGAppsHook, xorg, gobject-introspection
 }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.libertyzero.com/GEncfsM/";
     downloadPage = "https://launchpad.net/gencfsm/";
     description = "EncFS manager and mounter with GNOME3 integration";
diff --git a/pkgs/tools/security/genpass/default.nix b/pkgs/tools/security/genpass/default.nix
index 6818af194b3ab..88d6604be8378 100644
--- a/pkgs/tools/security/genpass/default.nix
+++ b/pkgs/tools/security/genpass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit
 , rustPlatform
 , CoreFoundation
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ CoreFoundation libiconv Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple yet robust commandline random password generator";
     homepage = "https://sr.ht/~cyplo/genpass/";
     license = licenses.agpl3;
diff --git a/pkgs/tools/security/gnome-keysign/default.nix b/pkgs/tools/security/gnome-keysign/default.nix
index 4b9a6fb0e3219..db0e88a805ba6 100644
--- a/pkgs/tools/security/gnome-keysign/default.nix
+++ b/pkgs/tools/security/gnome-keysign/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , fetchpatch
 , python3
@@ -73,7 +73,7 @@ python3.pkgs.buildPythonApplication rec {
   # bunch of linting
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GTK/GNOME application to use GnuPG for signing other peoples’ keys";
     homepage = "https://wiki.gnome.org/Apps/Keysign";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/gnupg-pkcs11-scd/default.nix b/pkgs/tools/security/gnupg-pkcs11-scd/default.nix
index 04af88e333522..eb0553ed08326 100644
--- a/pkgs/tools/security/gnupg-pkcs11-scd/default.nix
+++ b/pkgs/tools/security/gnupg-pkcs11-scd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libgpgerror, libassuan, libgcrypt, pkcs11helper,
+{ lib, stdenv, fetchurl, libgpgerror, libassuan, libgcrypt, pkcs11helper,
   pkgconfig, openssl }:
 
 stdenv.mkDerivation rec {
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "--with-libgcrypt-prefix=${libgcrypt.dev}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A smart-card daemon to enable the use of PKCS#11 tokens with GnuPG";
     longDescription = ''
     gnupg-pkcs11 is a project to implement a BSD-licensed smart-card
diff --git a/pkgs/tools/security/gnupg/1.nix b/pkgs/tools/security/gnupg/1.nix
index 20ecd7c92fb22..66b05384c6bed 100644
--- a/pkgs/tools/security/gnupg/1.nix
+++ b/pkgs/tools/security/gnupg/1.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, readline, bzip2 }:
+{ lib, stdenv, fetchurl, readline, bzip2 }:
 
 stdenv.mkDerivation rec {
   name = "gnupg-1.4.23";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gnupg.org";
     description = "Classic (1.4) release of the GNU Privacy Guard, a GPL OpenPGP implementation";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/gnupg/22.nix b/pkgs/tools/security/gnupg/22.nix
index c2861574c2b88..94e62c03ad3b0 100644
--- a/pkgs/tools/security/gnupg/22.nix
+++ b/pkgs/tools/security/gnupg/22.nix
@@ -1,4 +1,4 @@
-{ fetchurl, fetchpatch, stdenv, pkgconfig, libgcrypt, libassuan, libksba
+{ fetchurl, fetchpatch, lib, stdenv, pkgconfig, libgcrypt, libassuan, libksba
 , libgpgerror, libiconv, npth, gettext, texinfo, buildPackages
 
 # Each of the dependencies below are optional.
@@ -76,7 +76,7 @@ stdenv.mkDerivation rec {
     ln -s -t $out/bin $out/libexec/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gnupg.org";
     description = "Modern (2.1) release of the GNU Privacy Guard, a GPL OpenPGP implementation";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/gopass/default.nix b/pkgs/tools/security/gopass/default.nix
index ff855cce240c5..943bebf41c794 100644
--- a/pkgs/tools/security/gopass/default.nix
+++ b/pkgs/tools/security/gopass/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , makeWrapper
 , buildGoModule
 , fetchFromGitHub
@@ -55,7 +55,7 @@ buildGoModule rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The slightly more awesome Standard Unix Password Manager for Teams. Written in Go";
     homepage = "https://www.gopass.pw/";
     license = licenses.mit;
diff --git a/pkgs/tools/security/gospider/default.nix b/pkgs/tools/security/gospider/default.nix
index b7c94c9402394..ef3184a0422f2 100644
--- a/pkgs/tools/security/gospider/default.nix
+++ b/pkgs/tools/security/gospider/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -19,7 +19,7 @@ buildGoModule rec {
   # tests require internet access and API keys
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast web spider written in Go";
     longDescription = ''
       GoSpider is a fast web crawler that parses sitemap.xml and robots.txt file.
diff --git a/pkgs/tools/security/gpgstats/default.nix b/pkgs/tools/security/gpgstats/default.nix
index 80153b857c4fb..c9a178cff42d4 100644
--- a/pkgs/tools/security/gpgstats/default.nix
+++ b/pkgs/tools/security/gpgstats/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses, gpgme }:
+{ lib, stdenv, fetchurl, ncurses, gpgme }:
 
 stdenv.mkDerivation rec {
   pname = "gpgstats";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE = stdenv.lib.optionalString (!stdenv.is64bit)
     "-D_FILE_OFFSET_BITS=64 -DLARGEFILE_SOURCE=1";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Calculates statistics on the keys in your gpg key-ring";
     longDescription = ''
     GPGstats calculates statistics on the keys in your key-ring.
diff --git a/pkgs/tools/security/grype/default.nix b/pkgs/tools/security/grype/default.nix
index 9786fd4166305..495302139855a 100644
--- a/pkgs/tools/security/grype/default.nix
+++ b/pkgs/tools/security/grype/default.nix
@@ -1,7 +1,7 @@
 { buildGoModule
 , docker
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -22,7 +22,7 @@ buildGoModule rec {
   # tests require a running Docker instance
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Vulnerability scanner for container images and filesystems";
     longDescription = ''
       As a vulnerability scanner is grype abale to scan the contents of a container
diff --git a/pkgs/tools/security/hash_extender/default.nix b/pkgs/tools/security/hash_extender/default.nix
index dc8ea8b2c9b43..5baeb71ce8992 100644
--- a/pkgs/tools/security/hash_extender/default.nix
+++ b/pkgs/tools/security/hash_extender/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl }:
+{ lib, stdenv, fetchFromGitHub, openssl }:
 
 stdenv.mkDerivation {
   pname = "hash_extender";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     cp hash_extender $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to automate hash length extension attacks";
     homepage = "https://github.com/iagox86/hash_extender";
     license = licenses.bsd3;
diff --git a/pkgs/tools/security/hashcash/default.nix b/pkgs/tools/security/hashcash/default.nix
index bb8fba33e1d4d..b13425b720551 100644
--- a/pkgs/tools/security/hashcash/default.nix
+++ b/pkgs/tools/security/hashcash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl }:
+{ lib, stdenv, fetchurl, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "hashcash";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     "DOC_INSTALL_PATH=${placeholder "out"}/share/doc/hashcash-$(version)"
   ];
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Proof-of-work algorithm used as spam and denial-of-service counter measure";
     homepage = "http://hashcash.org";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/hashcat-utils/default.nix b/pkgs/tools/security/hashcat-utils/default.nix
index 7dcfff038a8df..8b91a53db013f 100644
--- a/pkgs/tools/security/hashcat-utils/default.nix
+++ b/pkgs/tools/security/hashcat-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "hashcat-utils";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small utilities that are useful in advanced password cracking";
     homepage = "https://github.com/hashcat/hashcat-utils";
     license = licenses.mit;
diff --git a/pkgs/tools/security/hashcat/default.nix b/pkgs/tools/security/hashcat/default.nix
index b156cda99ac74..20b5aed393204 100644
--- a/pkgs/tools/security/hashcat/default.nix
+++ b/pkgs/tools/security/hashcat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , makeWrapper
 , opencl-headers
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/hashcat --prefix LD_LIBRARY_PATH : ${ocl-icd}/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast password cracker";
     homepage    = "https://hashcat.net/hashcat/";
     license     = licenses.mit;
diff --git a/pkgs/tools/security/hashdeep/default.nix b/pkgs/tools/security/hashdeep/default.nix
index 4ad656462b14a..2f0a40dfc5e25 100644
--- a/pkgs/tools/security/hashdeep/default.nix
+++ b/pkgs/tools/security/hashdeep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 let version = "4.4";
 in stdenv.mkDerivation {
@@ -13,7 +13,7 @@ in stdenv.mkDerivation {
 
   nativeBuildInputs = [ autoreconfHook ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of cross-platform tools to compute hashes";
     homepage = "https://github.com/jessek/hashdeep";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/hcxdumptool/default.nix b/pkgs/tools/security/hcxdumptool/default.nix
index afc08d88a5903..082ebac7f6f9e 100644
--- a/pkgs/tools/security/hcxdumptool/default.nix
+++ b/pkgs/tools/security/hcxdumptool/default.nix
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ZerBea/hcxdumptool";
     description = "Small tool to capture packets from wlan devices";
     license = licenses.mit;
diff --git a/pkgs/tools/security/hcxtools/default.nix b/pkgs/tools/security/hcxtools/default.nix
index a81c1ef75cf06..a1ba32b35ed7e 100644
--- a/pkgs/tools/security/hcxtools/default.nix
+++ b/pkgs/tools/security/hcxtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, curl, openssl, zlib }:
+{ lib, stdenv, fetchFromGitHub, curl, openssl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "hcxtools";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     "PREFIX=${placeholder "out"}"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for capturing wlan traffic and conversion to hashcat and John the Ripper formats";
     homepage = "https://github.com/ZerBea/hcxtools";
     license = licenses.mit;
diff --git a/pkgs/tools/security/hologram/default.nix b/pkgs/tools/security/hologram/default.nix
index 9a8722ac2639a..6ec4d7776e1fe 100644
--- a/pkgs/tools/security/hologram/default.nix
+++ b/pkgs/tools/security/hologram/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   name = "hologram-2018-03-19";
@@ -17,7 +17,7 @@ buildGoPackage rec {
     sed -i 's|cacheTimeout != 3600|cacheTimeout != 0|' cmd/hologram-server/main.go
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AdRoll/hologram/";
     description = "Easy, painless AWS credentials on developer laptops";
     maintainers = with maintainers; [ nand0p ];
diff --git a/pkgs/tools/security/httpx/default.nix b/pkgs/tools/security/httpx/default.nix
index c7d83075e9da4..7135baab37598 100644
--- a/pkgs/tools/security/httpx/default.nix
+++ b/pkgs/tools/security/httpx/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "0fg93vhwpx113fpw8qg4ram4bdh6a8x3a36pr1c962s4vhrabwy2";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and multi-purpose HTTP toolkit";
     longDescription = ''
       httpx is a fast and multi-purpose HTTP toolkit allow to run multiple
diff --git a/pkgs/tools/security/ifdnfc/default.nix b/pkgs/tools/security/ifdnfc/default.nix
index bab6527f41532..648774c58674c 100644
--- a/pkgs/tools/security/ifdnfc/default.nix
+++ b/pkgs/tools/security/ifdnfc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub , pkgconfig
+{ lib, stdenv, fetchFromGitHub , pkgconfig
 , pcsclite
 , autoreconfHook
 , libnfc
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
   configureFlags = [ "--prefix=$(out)" ];
   makeFlags = [ "DESTDIR=/" "usbdropdir=$(out)/pcsc/drivers" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PC/SC IFD Handler based on libnfc";
     longDescription =
     '' libnfc Interface Plugin to be used in <code>services.pcscd.plugins</code>.
diff --git a/pkgs/tools/security/ipscan/default.nix b/pkgs/tools/security/ipscan/default.nix
index 4963f57748750..8440b0b6ec989 100644
--- a/pkgs/tools/security/ipscan/default.nix
+++ b/pkgs/tools/security/ipscan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jdk, jre, swt, makeWrapper, xorg, dpkg }:
+{ lib, stdenv, fetchurl, jdk, jre, swt, makeWrapper, xorg, dpkg }:
 
 stdenv.mkDerivation rec {
   pname = "ipscan";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     cp usr/share/pixmaps/ipscan.png $out/share/pixmaps/ipscan.png
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and friendly network scanner";
     homepage = "https://angryip.org";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/jadx/default.nix b/pkgs/tools/security/jadx/default.nix
index 770062736bf15..02533f7f6f5fc 100644
--- a/pkgs/tools/security/jadx/default.nix
+++ b/pkgs/tools/security/jadx/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, gradle, jdk, makeWrapper, perl }:
+{ lib, stdenv, fetchFromGitHub, gradle, jdk, makeWrapper, perl }:
 
 let
   pname = "jadx";
@@ -90,7 +90,7 @@ in stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Dex to Java decompiler";
     longDescription = ''
       Command line and GUI tools for produce Java source code from Android Dex
diff --git a/pkgs/tools/security/jd-gui/default.nix b/pkgs/tools/security/jd-gui/default.nix
index 91c092922f04a..046abed36f0ce 100644
--- a/pkgs/tools/security/jd-gui/default.nix
+++ b/pkgs/tools/security/jd-gui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jre, jdk, gradle_5, makeDesktopItem, copyDesktopItems, perl, writeText, runtimeShell }:
+{ lib, stdenv, fetchFromGitHub, jre, jdk, gradle_5, makeDesktopItem, copyDesktopItems, perl, writeText, runtimeShell }:
 
 let
   pname = "jd-gui";
@@ -99,7 +99,7 @@ in stdenv.mkDerivation rec {
 
   desktopItems = [ desktopItem ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast Java Decompiler with powerful GUI";
     homepage    = "https://java-decompiler.github.io/";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/security/jwt-cli/default.nix b/pkgs/tools/security/jwt-cli/default.nix
index db73bb958eb6a..b607cabf916ee 100644
--- a/pkgs/tools/security/jwt-cli/default.nix
+++ b/pkgs/tools/security/jwt-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security, fetchpatch }:
 
 rustPlatform.buildRustPackage rec {
   pname = "jwt-cli";
@@ -18,7 +18,7 @@ rustPlatform.buildRustPackage rec {
   doInstallCheck = true;
   installCheckPhase = "$out/bin/jwt --version";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Super fast CLI tool to decode and encode JWTs";
     homepage = "https://github.com/mike-engel/jwt-cli";
     license = with licenses; [ mit ];
diff --git a/pkgs/tools/security/kbs2/default.nix b/pkgs/tools/security/kbs2/default.nix
index a13e7214cbbd3..e7b1c95126a66 100644
--- a/pkgs/tools/security/kbs2/default.nix
+++ b/pkgs/tools/security/kbs2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, installShellFiles, python3, libxcb, AppKit }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, installShellFiles, python3, libxcb, AppKit }:
 
 rustPlatform.buildRustPackage rec {
   pname = "kbs2";
@@ -36,7 +36,7 @@ rustPlatform.buildRustPackage rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A secret manager backed by age";
     homepage = "https://github.com/woodruffw/kbs2";
     changelog = "https://github.com/woodruffw/kbs2/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/tools/security/keybase/default.nix b/pkgs/tools/security/keybase/default.nix
index ddc83ce0ce625..ba9649f36ab9c 100644
--- a/pkgs/tools/security/keybase/default.nix
+++ b/pkgs/tools/security/keybase/default.nix
@@ -31,7 +31,7 @@ buildGoPackage rec {
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ AVFoundation AudioToolbox ImageIO CoreMedia Foundation CoreGraphics MediaToolbox ];
   buildFlags = [ "-tags production" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.keybase.io/";
     description = "The Keybase official command-line utility and service";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/security/keybase/gui.nix b/pkgs/tools/security/keybase/gui.nix
index 13a1fed2e3081..54be692b007bb 100644
--- a/pkgs/tools/security/keybase/gui.nix
+++ b/pkgs/tools/security/keybase/gui.nix
@@ -105,7 +105,7 @@ stdenv.mkDerivation rec {
       --replace run_keybase $out/bin/keybase-gui
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.keybase.io/";
     description = "The Keybase official GUI";
     platforms = [ "x86_64-linux" ];
diff --git a/pkgs/tools/security/keybase/kbfs.nix b/pkgs/tools/security/keybase/kbfs.nix
index e9284e7230fb2..6916d6b99bd8d 100644
--- a/pkgs/tools/security/keybase/kbfs.nix
+++ b/pkgs/tools/security/keybase/kbfs.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub, keybase }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, keybase }:
 
 buildGoPackage {
   pname = "kbfs";
@@ -12,7 +12,7 @@ buildGoPackage {
 
   buildFlags = [ "-tags production" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://keybase.io/docs/kbfs";
     description = "The Keybase filesystem";
     platforms = platforms.unix;
diff --git a/pkgs/tools/security/knockknock/default.nix b/pkgs/tools/security/knockknock/default.nix
index 9478bb4ca237c..7a00f183f15da 100644
--- a/pkgs/tools/security/knockknock/default.nix
+++ b/pkgs/tools/security/knockknock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python2Packages, hping }:
+{ lib, stdenv, fetchFromGitHub, python2Packages, hping }:
 let
   rev  = "bf14bbff";
 in python2Packages.buildPythonApplication rec {
@@ -23,7 +23,7 @@ in python2Packages.buildPythonApplication rec {
     substituteInPlace knockknock.py --replace 'existsInPath("hping3")' '"${hping}/bin/hping3"'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple, secure port knocking daemon and client written in Python";
     homepage    = "http://www.thoughtcrime.org/software/knockknock/";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/security/kpcli/default.nix b/pkgs/tools/security/kpcli/default.nix
index 12e2bb03d38d4..a0dd8c7fc8b6f 100644
--- a/pkgs/tools/security/kpcli/default.nix
+++ b/pkgs/tools/security/kpcli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, perl, perlPackages }:
+{ lib, stdenv, fetchurl, makeWrapper, perl, perlPackages }:
 
 stdenv.mkDerivation rec {
   version = "3.6";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "KeePass Command Line Interface";
     longDescription = ''
       KeePass Command Line Interface (CLI) / interactive shell. 
diff --git a/pkgs/tools/security/lesspass-cli/default.nix b/pkgs/tools/security/lesspass-cli/default.nix
index 5bf7358fa76ac..20473d1003e4f 100644
--- a/pkgs/tools/security/lesspass-cli/default.nix
+++ b/pkgs/tools/security/lesspass-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, fetchFromGitHub }:
+{ lib, stdenv, python3, fetchFromGitHub }:
 
 let
   inherit (python3.pkgs) buildPythonApplication pytest mock pexpect;
@@ -30,7 +30,7 @@ buildPythonApplication rec {
     pytest tests
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stateless password manager";
     homepage = "https://lesspass.com";
     maintainers = with maintainers; [ jasoncarr ];
diff --git a/pkgs/tools/security/libacr38u/default.nix b/pkgs/tools/security/libacr38u/default.nix
index b56c15af3d62a..126cfedd1576d 100644
--- a/pkgs/tools/security/libacr38u/default.nix
+++ b/pkgs/tools/security/libacr38u/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, pcsclite , libusb-compat-0_1 }:
+{ lib, stdenv, fetchurl, pkgconfig, pcsclite , libusb-compat-0_1 }:
 
 stdenv.mkDerivation {
   version = "1.7.11";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     makeFlagsArray=(usbdropdir="$out/pcsc/drivers");
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ACR38U smartcard reader driver for pcsclite";
     longDescription = ''
       A PC/SC IFD handler implementation for the ACS ACR38U
diff --git a/pkgs/tools/security/libmodsecurity/default.nix b/pkgs/tools/security/libmodsecurity/default.nix
index 01e9a38479204..5735263206ecc 100644
--- a/pkgs/tools/security/libmodsecurity/default.nix
+++ b/pkgs/tools/security/libmodsecurity/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , doxygen, perl, valgrind
 , curl, geoip, libxml2, lmdb, lua, pcre, yajl }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       ModSecurity v3 library component.
     '';
diff --git a/pkgs/tools/security/logkeys/default.nix b/pkgs/tools/security/logkeys/default.nix
index f3ea25d716010..7cd6b5fd194b9 100644
--- a/pkgs/tools/security/logkeys/default.nix
+++ b/pkgs/tools/security/logkeys/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, which, procps, kbd }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, which, procps, kbd }:
 
 stdenv.mkDerivation {
   pname = "logkeys";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
 
   preConfigure = "./autogen.sh";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A GNU/Linux keylogger that works!";
     license = licenses.gpl3;
     homepage = "https://github.com/kernc/logkeys";
diff --git a/pkgs/tools/security/lynis/default.nix b/pkgs/tools/security/lynis/default.nix
index 9bbbc455b9b33..6533c9e96fdfe 100644
--- a/pkgs/tools/security/lynis/default.nix
+++ b/pkgs/tools/security/lynis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeWrapper, fetchFromGitHub, gawk, installShellFiles }:
+{ lib, stdenv, makeWrapper, fetchFromGitHub, gawk, installShellFiles }:
 
 stdenv.mkDerivation rec {
   pname = "lynis";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
       extras/bash_completion.d/lynis
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Security auditing tool for Linux, macOS, and UNIX-based systems";
     homepage = "https://cisofy.com/lynis/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/masscan/default.nix b/pkgs/tools/security/masscan/default.nix
index 6acfec9f3be8b..0f45edcff6cf0 100644
--- a/pkgs/tools/security/masscan/default.nix
+++ b/pkgs/tools/security/masscan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, libpcap }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, libpcap }:
 
 stdenv.mkDerivation rec {
   pname = "masscan";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/masscan --prefix LD_LIBRARY_PATH : "${libpcap}/lib"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast scan of the Internet";
     homepage    = "https://github.com/robertdavidgraham/masscan";
     license     = licenses.agpl3;
diff --git a/pkgs/tools/security/medusa/default.nix b/pkgs/tools/security/medusa/default.nix
index bc18f165be73c..43a30aad82550 100644
--- a/pkgs/tools/security/medusa/default.nix
+++ b/pkgs/tools/security/medusa/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkg-config, freerdp, openssl, libssh2 }:
+{ lib, stdenv, fetchFromGitHub, pkg-config, freerdp, openssl, libssh2 }:
 
 stdenv.mkDerivation rec {
   pname = "medusa-unstable";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkg-config ];
   buildInputs = [ freerdp openssl libssh2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jmk-foofus/medusa";
     description = "A speedy, parallel, and modular, login brute-forcer";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/metasploit/default.nix b/pkgs/tools/security/metasploit/default.nix
index a2a0a28bbff6c..1260584a3a7aa 100644
--- a/pkgs/tools/security/metasploit/default.nix
+++ b/pkgs/tools/security/metasploit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, ruby, bundlerEnv }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, ruby, bundlerEnv }:
 
 let
   env = bundlerEnv {
@@ -39,7 +39,7 @@ in stdenv.mkDerivation rec {
   # run with: nix-shell maintainers/scripts/update.nix --argstr path metasploit
   passthru.updateScript = ./update.sh;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Metasploit Framework - a collection of exploits";
     homepage = "https://github.com/rapid7/metasploit-framework/wiki";
     platforms = platforms.unix;
diff --git a/pkgs/tools/security/mfcuk/default.nix b/pkgs/tools/security/mfcuk/default.nix
index 59908f2a9ce57..006e89871c77d 100644
--- a/pkgs/tools/security/mfcuk/default.nix
+++ b/pkgs/tools/security/mfcuk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libnfc }:
+{ lib, stdenv, fetchurl, pkgconfig, libnfc }:
 
 stdenv.mkDerivation {
   pname = "mfcuk";
@@ -12,7 +12,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libnfc ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MiFare Classic Universal toolKit";
     license = licenses.gpl2;
     homepage = "https://github.com/nfc-tools/mfcuk";
diff --git a/pkgs/tools/security/mfoc/default.nix b/pkgs/tools/security/mfoc/default.nix
index fb622ad82496d..1d2478b6bae43 100644
--- a/pkgs/tools/security/mfoc/default.nix
+++ b/pkgs/tools/security/mfoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pkgconfig, libnfc }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, pkgconfig, libnfc }:
 
 stdenv.mkDerivation rec {
   pname = "mfoc";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ libnfc ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mifare Classic Offline Cracker";
     license = licenses.gpl2;
     homepage = "https://github.com/nfc-tools/mfoc";
diff --git a/pkgs/tools/security/minisign/default.nix b/pkgs/tools/security/minisign/default.nix
index b67b65b0cf8be..1fb1d6893a9f9 100644
--- a/pkgs/tools/security/minisign/default.nix
+++ b/pkgs/tools/security/minisign/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkg-config, libsodium }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, libsodium }:
 
 stdenv.mkDerivation rec {
   pname = "minisign";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake pkg-config ];
   buildInputs = [ libsodium ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple tool for signing files and verifying signatures";
     longDescription = ''
       minisign uses public key cryptography to help facilitate secure (but not
diff --git a/pkgs/tools/security/mkpasswd/default.nix b/pkgs/tools/security/mkpasswd/default.nix
index b88852966ee1d..e001239f3136e 100644
--- a/pkgs/tools/security/mkpasswd/default.nix
+++ b/pkgs/tools/security/mkpasswd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, whois, perl }:
+{ lib, stdenv, whois, perl }:
 
 stdenv.mkDerivation {
   name = "mkpasswd-${whois.version}";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
   buildPhase = "make mkpasswd";
   installPhase = "make install-mkpasswd";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://packages.qa.debian.org/w/whois.html";
     description = "Overfeatured front-end to crypt, from the Debian whois package";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/mktemp/default.nix b/pkgs/tools/security/mktemp/default.nix
index 0732adecc45bc..dc3f2a8904bcb 100644
--- a/pkgs/tools/security/mktemp/default.nix
+++ b/pkgs/tools/security/mktemp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, groff }:
+{ lib, stdenv, fetchurl, groff }:
 
 stdenv.mkDerivation {
   name = "mktemp-1.7";
@@ -16,7 +16,7 @@ stdenv.mkDerivation {
     sha256 = "0x969152znxxjbj7387xb38waslr4yv6bnj5jmhb4rpqxphvk54f";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple tool to make temporary file handling in shells scripts safe and simple";
     homepage = "https://www.mktemp.org";
     license = licenses.isc;
diff --git a/pkgs/tools/security/monkeysphere/default.nix b/pkgs/tools/security/monkeysphere/default.nix
index 4b1f756988715..e5dca7721ac75 100644
--- a/pkgs/tools/security/monkeysphere/default.nix
+++ b/pkgs/tools/security/monkeysphere/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper
+{ lib, stdenv, fetchurl, makeWrapper
 , perl, libassuan, libgcrypt
 , perlPackages, lockfileProgs, gnupg, coreutils
 # For the tests:
@@ -84,7 +84,7 @@ in stdenv.mkDerivation rec {
         done
       '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://web.monkeysphere.info/";
     description = "Leverage the OpenPGP web of trust for SSH and TLS authentication";
     longDescription = ''
diff --git a/pkgs/tools/security/mpw/default.nix b/pkgs/tools/security/mpw/default.nix
index 9d25daf29a69f..3973ed51343f9 100644
--- a/pkgs/tools/security/mpw/default.nix
+++ b/pkgs/tools/security/mpw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, fetchFromGitLab
+{ lib, stdenv, cmake, fetchFromGitLab
 , json_c, libsodium, libxml2, ncurses }:
 
 let
@@ -53,7 +53,7 @@ in stdenv.mkDerivation rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A stateless password management solution";
     homepage = "https://masterpasswordapp.com/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/munge/default.nix b/pkgs/tools/security/munge/default.nix
index ee1858ad2845c..0462db8859c9c 100644
--- a/pkgs/tools/security/munge/default.nix
+++ b/pkgs/tools/security/munge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, gawk, gnused, libgcrypt, zlib, bzip2 }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, gawk, gnused, libgcrypt, zlib, bzip2 }:
 
 stdenv.mkDerivation rec {
   name = "munge-0.5.14";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     "--localstatedir=/var"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       An authentication service for creating and validating credentials
     '';
diff --git a/pkgs/tools/security/nasty/default.nix b/pkgs/tools/security/nasty/default.nix
index 7f423860100be..b3b19c9268bfc 100644
--- a/pkgs/tools/security/nasty/default.nix
+++ b/pkgs/tools/security/nasty/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gpgme }:
+{ lib, stdenv, fetchurl, gpgme }:
 
 stdenv.mkDerivation rec {
   pname = "nasty";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     cp nasty $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recover the passphrase of your PGP or GPG-key";
     longDescription = ''
     Nasty is a program that helps you to recover the passphrase of your PGP or GPG-key
diff --git a/pkgs/tools/security/ncrack/default.nix b/pkgs/tools/security/ncrack/default.nix
index e377d9748645e..e1504eb12b4cc 100644
--- a/pkgs/tools/security/ncrack/default.nix
+++ b/pkgs/tools/security/ncrack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, zlib }:
+{ lib, stdenv, fetchFromGitHub, openssl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "ncrack";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ openssl zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Network authentication tool";
     homepage = "https://nmap.org/ncrack/";
     license = licenses.gpl2Only;
diff --git a/pkgs/tools/security/neopg/default.nix b/pkgs/tools/security/neopg/default.nix
index 8c0d31853ff9e..93c12c1582880 100644
--- a/pkgs/tools/security/neopg/default.nix
+++ b/pkgs/tools/security/neopg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , sqlite
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     export LD_LIBRARY_PATH=$LD_LIBRARY_PATH''${LD_LIBRARY_PATH:+:}$(pwd)/3rdparty/googletest/googletest:$(pwd)/neopg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://neopg.io/";
     description = "Modern replacement for GnuPG 2";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/nitrokey-app/default.nix b/pkgs/tools/security/nitrokey-app/default.nix
index a4936d763b6cd..1da54526a614c 100644
--- a/pkgs/tools/security/nitrokey-app/default.nix
+++ b/pkgs/tools/security/nitrokey-app/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bash-completion, cmake, fetchFromGitHub, hidapi, libusb1, pkgconfig
+{ lib, stdenv, bash-completion, cmake, fetchFromGitHub, hidapi, libusb1, pkgconfig
 , qtbase, qttranslations, qtsvg, wrapQtAppsHook }:
 
 stdenv.mkDerivation rec {
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   ];
   cmakeFlags = [ "-DCMAKE_BUILD_TYPE=Release" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description      = "Provides extra functionality for the Nitrokey Pro and Storage";
     longDescription  = ''
        The nitrokey-app provides a QT system tray widget with wich you can
diff --git a/pkgs/tools/security/nmap/qt.nix b/pkgs/tools/security/nmap/qt.nix
index befd6108919bc..39026c400d04f 100644
--- a/pkgs/tools/security/nmap/qt.nix
+++ b/pkgs/tools/security/nmap/qt.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , cmake
 , pkgconfig
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt frontend for nmap";
     license = licenses.gpl2;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/tools/security/notary/default.nix b/pkgs/tools/security/notary/default.nix
index 020f37c836bac..fa3db0c3623c6 100644
--- a/pkgs/tools/security/notary/default.nix
+++ b/pkgs/tools/security/notary/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage, libtool }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage, libtool }:
 
 buildGoPackage rec {
   pname = "notary";
@@ -35,7 +35,7 @@ buildGoPackage rec {
     make test PKGS=github.com/theupdateframework/notary/cmd/notary
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A project that allows anyone to have trust over arbitrary collections of data";
     longDescription = ''
       The Notary project comprises a server and a client for running and
diff --git a/pkgs/tools/security/nsjail/default.nix b/pkgs/tools/security/nsjail/default.nix
index 4522d0e897af7..deab1b929c943 100644
--- a/pkgs/tools/security/nsjail/default.nix
+++ b/pkgs/tools/security/nsjail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, bison, flex, libtool, pkgconfig, which
+{ lib, stdenv, fetchFromGitHub, autoconf, bison, flex, libtool, pkgconfig, which
 , libnl, protobuf, protobufc, shadow
 }:
 
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     install nsjail.1 $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A light-weight process isolation tool, making use of Linux namespaces and seccomp-bpf syscall filters";
     homepage    = "http://nsjail.com/";
     license     = licenses.asl20;
diff --git a/pkgs/tools/security/nuclei/default.nix b/pkgs/tools/security/nuclei/default.nix
index 22013352a38da..7e9d3d52e56b1 100644
--- a/pkgs/tools/security/nuclei/default.nix
+++ b/pkgs/tools/security/nuclei/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -20,7 +20,7 @@ buildGoModule rec {
     mv v2/* .
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for configurable targeted scanning";
     longDescription = ''
       Nuclei is used to send requests across targets based on a template
diff --git a/pkgs/tools/security/nwipe/default.nix b/pkgs/tools/security/nwipe/default.nix
index c72ada8676144..53d8abc61007e 100644
--- a/pkgs/tools/security/nwipe/default.nix
+++ b/pkgs/tools/security/nwipe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ncurses, parted, automake, autoconf, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, ncurses, parted, automake, autoconf, pkgconfig }:
 
 stdenv.mkDerivation rec {
   version = "0.28";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ automake autoconf pkgconfig ];
   buildInputs = [ ncurses parted ];
   preConfigure = "sh init.sh || :";
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Securely erase disks";
     homepage = "https://github.com/martijnvanbrummelen/nwipe";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/oath-toolkit/default.nix b/pkgs/tools/security/oath-toolkit/default.nix
index 22327c6a38f00..5fb7fadbc5c4c 100644
--- a/pkgs/tools/security/oath-toolkit/default.nix
+++ b/pkgs/tools/security/oath-toolkit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, fetchpatch, pam, xmlsec, autoreconfHook, pkgconfig, libxml2, gtk-doc, perl, gengetopt, bison, help2man }:
+{ lib, stdenv, fetchFromGitLab, fetchpatch, pam, xmlsec, autoreconfHook, pkgconfig, libxml2, gtk-doc, perl, gengetopt, bison, help2man }:
 
 let
   securityDependency =
@@ -40,7 +40,7 @@ in stdenv.mkDerivation {
     touch ChangeLog
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Components for building one-time password authentication systems";
     homepage = "https://www.nongnu.org/oath-toolkit/";
     platforms = with platforms; linux ++ darwin;
diff --git a/pkgs/tools/security/omapd/default.nix b/pkgs/tools/security/omapd/default.nix
index 8ed23864ced50..7ce377e601a36 100644
--- a/pkgs/tools/security/omapd/default.nix
+++ b/pkgs/tools/security/omapd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, qt4, gdb, zlib }:
+{ lib, stdenv, fetchurl, qt4, gdb, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "omapd";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     ln -s $out/usr/lib/omapd/plugins $out/bin/plugins
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://code.google.com/archive/p/omapd/";
     description = "IF-MAP Server that implements the IF-MAP v1.1 and v2.0 specifications published by the Trusted Computing Group (TCG)";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/onesixtyone/default.nix b/pkgs/tools/security/onesixtyone/default.nix
index 4eed52b07f0e9..374d1322246bf 100644
--- a/pkgs/tools/security/onesixtyone/default.nix
+++ b/pkgs/tools/security/onesixtyone/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "onesixtyone";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     install -D onesixtyone $out/bin/onesixtyone
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast SNMP Scanner";
     homepage = "https://github.com/trailofbits/onesixtyone";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/onioncircuits/default.nix b/pkgs/tools/security/onioncircuits/default.nix
index 92888a8de2a15..bdaf087004a1a 100644
--- a/pkgs/tools/security/onioncircuits/default.nix
+++ b/pkgs/tools/security/onioncircuits/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, python3, intltool, gtk3, gobject-introspection, gnome3 }:
+{ lib, stdenv, fetchgit, python3, intltool, gtk3, gobject-introspection, gnome3 }:
 
 python3.pkgs.buildPythonApplication rec {
   pname = "onioncircuits";
@@ -20,7 +20,7 @@ python3.pkgs.buildPythonApplication rec {
       --prefix XDG_DATA_DIRS : "$out/share:${gnome3.adwaita-icon-theme}/share"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://tails.boum.org";
     description = "GTK application to display Tor circuits and streams";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/open-ecard/default.nix b/pkgs/tools/security/open-ecard/default.nix
index bac036e67900b..0dfdba804c09f 100644
--- a/pkgs/tools/security/open-ecard/default.nix
+++ b/pkgs/tools/security/open-ecard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, pcsclite, makeDesktopItem, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, pcsclite, makeDesktopItem, makeWrapper }:
 
 let
   version = "1.2.4";
@@ -53,7 +53,7 @@ in stdenv.mkDerivation rec {
       --suffix LD_LIBRARY_PATH ':' ${stdenv.lib.getLib pcsclite}/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Client side implementation of the eCard-API-Framework (BSI
       TR-03112) and related international standards, such as ISO/IEC 24727";
     homepage = "https://www.openecard.org/";
diff --git a/pkgs/tools/security/opencryptoki/default.nix b/pkgs/tools/security/opencryptoki/default.nix
index 1eb4aab66b475..0825708f71fdf 100644
--- a/pkgs/tools/security/opencryptoki/default.nix
+++ b/pkgs/tools/security/opencryptoki/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl, trousers, autoreconfHook, libtool, bison, flex }:
+{ lib, stdenv, fetchFromGitHub, openssl, trousers, autoreconfHook, libtool, bison, flex }:
 
 stdenv.mkDerivation rec {
   pname = "opencryptoki";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PKCS#11 implementation for Linux";
     homepage    = "https://github.com/opencryptoki/opencryptoki";
     license     = licenses.cpl10;
diff --git a/pkgs/tools/security/opensc/default.nix b/pkgs/tools/security/opensc/default.nix
index 735f7558e7a88..f623e3a2f6ffb 100644
--- a/pkgs/tools/security/opensc/default.nix
+++ b/pkgs/tools/security/opensc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, zlib, readline, openssl
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, zlib, readline, openssl
 , libiconv, pcsclite, libassuan, libXt
 , docbook_xsl, libxslt, docbook_xml_dtd_412
 , Carbon, PCSC, buildPackages
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
     "completiondir=$(out)/etc"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of libraries and utilities to access smart cards";
     homepage = "https://github.com/OpenSC/OpenSC/wiki";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/tools/security/pamtester/default.nix b/pkgs/tools/security/pamtester/default.nix
index a1055dadc6cab..1944e5187d216 100644
--- a/pkgs/tools/security/pamtester/default.nix
+++ b/pkgs/tools/security/pamtester/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pam }:
+{ lib, stdenv, fetchurl, pam }:
 
 stdenv.mkDerivation rec {
   name = "pamtester-0.1.2";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pam ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utility program to test the PAM facility";
     homepage = "http://pamtester.sourceforge.net/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/security/paperkey/default.nix b/pkgs/tools/security/paperkey/default.nix
index dc3582b7369f9..766b570a074e1 100644
--- a/pkgs/tools/security/paperkey/default.nix
+++ b/pkgs/tools/security/paperkey/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv }:
+{ fetchurl, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   pname = "paperkey";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Store OpenPGP or GnuPG on paper";
     longDescription = ''
       A reasonable way to achieve a long term backup of OpenPGP (GnuPG, PGP, etc)
diff --git a/pkgs/tools/security/pass/default.nix b/pkgs/tools/security/pass/default.nix
index 354437a9bd56b..e2b163445ce25 100644
--- a/pkgs/tools/security/pass/default.nix
+++ b/pkgs/tools/security/pass/default.nix
@@ -149,7 +149,7 @@ stdenv.mkDerivation rec {
     withExtensions = env;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stores, retrieves, generates, and synchronizes passwords securely";
     homepage    = "https://www.passwordstore.org/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/pass/extensions/audit/default.nix b/pkgs/tools/security/pass/extensions/audit/default.nix
index ec0f23ddc3834..415a4b9e79d17 100644
--- a/pkgs/tools/security/pass/extensions/audit/default.nix
+++ b/pkgs/tools/security/pass/extensions/audit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pass, fetchFromGitHub, pythonPackages, makeWrapper, gnupg }:
+{ lib, stdenv, pass, fetchFromGitHub, pythonPackages, makeWrapper, gnupg }:
 
 let
   pythonEnv = pythonPackages.python.withPackages (p: [ p.requests p.setuptools p.zxcvbn ]);
@@ -43,7 +43,7 @@ in stdenv.mkDerivation rec {
       --prefix PYTHONPATH : "$out/lib/${pythonEnv.libPrefix}/site-packages"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pass extension for auditing your password repository.";
     homepage = "https://github.com/roddhjav/pass-audit";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/pass/extensions/checkup.nix b/pkgs/tools/security/pass/extensions/checkup.nix
index 83a1d7a8872d9..bafaabba843bc 100644
--- a/pkgs/tools/security/pass/extensions/checkup.nix
+++ b/pkgs/tools/security/pass/extensions/checkup.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , curl, findutils, gnugrep, gnused }:
 
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     install -D -m755 checkup.bash $out/lib/password-store/extensions/checkup.bash
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pass extension to check against the Have I been pwned API to see if your passwords are publicly leaked or not";
     homepage = "https://github.com/etu/pass-checkup";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/pass/extensions/genphrase.nix b/pkgs/tools/security/pass/extensions/genphrase.nix
index d45e35d9bbc0a..dff64d7f18551 100644
--- a/pkgs/tools/security/pass/extensions/genphrase.nix
+++ b/pkgs/tools/security/pass/extensions/genphrase.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "pass-genphrase";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --replace '$EXTENSIONS' "$out/lib/password-store/extensions/"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pass extension that generates memorable passwords";
     homepage = "https://github.com/congma/pass-genphrase";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/pass/extensions/import.nix b/pkgs/tools/security/pass/extensions/import.nix
index 885dd05110f32..0fd14901d0db9 100644
--- a/pkgs/tools/security/pass/extensions/import.nix
+++ b/pkgs/tools/security/pass/extensions/import.nix
@@ -1,4 +1,4 @@
-{ stdenv, pass, fetchFromGitHub, pythonPackages, makeWrapper, fetchpatch }:
+{ lib, stdenv, pass, fetchFromGitHub, pythonPackages, makeWrapper, fetchpatch }:
 
 let
   pythonEnv = pythonPackages.python.withPackages (p: [
@@ -39,7 +39,7 @@ in stdenv.mkDerivation rec {
       --prefix PYTHONPATH : "$out/${pythonPackages.python.sitePackages}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pass extension for importing data from existing password managers";
     homepage = "https://github.com/roddhjav/pass-import";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/pass/extensions/otp.nix b/pkgs/tools/security/pass/extensions/otp.nix
index 835e693c2c5c2..8d9b350543dc6 100644
--- a/pkgs/tools/security/pass/extensions/otp.nix
+++ b/pkgs/tools/security/pass/extensions/otp.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, oathToolkit }:
+{ lib, stdenv, fetchFromGitHub, oathToolkit }:
 
 stdenv.mkDerivation rec {
   pname = "pass-otp";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
                    "BASHCOMPDIR=$(out)/share/bash-completion/completions"
                  ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pass extension for managing one-time-password (OTP) tokens";
     homepage = "https://github.com/tadfisher/pass-otp";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/pass/extensions/tomb.nix b/pkgs/tools/security/pass/extensions/tomb.nix
index 43c74a9029b3a..74f8694f224c5 100644
--- a/pkgs/tools/security/pass/extensions/tomb.nix
+++ b/pkgs/tools/security/pass/extensions/tomb.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, tomb }:
+{ lib, stdenv, fetchFromGitHub, tomb }:
 
 stdenv.mkDerivation rec {
   pname = "pass-tomb";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
       --replace 'TOMB="''${PASSWORD_STORE_TOMB:-tomb}"' 'TOMB="''${PASSWORD_STORE_TOMB:-${tomb}/bin/tomb}"'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pass extension that keeps the password store encrypted inside a tomb";
     homepage = "https://github.com/roddhjav/pass-tomb";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/pass/extensions/update.nix b/pkgs/tools/security/pass/extensions/update.nix
index c364c341bda5b..50a4c49b90d15 100644
--- a/pkgs/tools/security/pass/extensions/update.nix
+++ b/pkgs/tools/security/pass/extensions/update.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "pass-update";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Pass extension that provides an easy flow for updating passwords";
     homepage = "https://github.com/roddhjav/pass-update";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/security/passff-host/default.nix b/pkgs/tools/security/passff-host/default.nix
index 0bdb04b761294..fb348800f5a16 100644
--- a/pkgs/tools/security/passff-host/default.nix
+++ b/pkgs/tools/security/passff-host/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, pass }:
+{ lib, stdenv, fetchFromGitHub, python3, pass }:
 
 stdenv.mkDerivation rec {
   pname = "passff-host";
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Host app for the WebExtension PassFF";
     homepage = "https://github.com/passff/passff-host";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/pbis/default.nix b/pkgs/tools/security/pbis/default.nix
index 176ef7f7616bf..25e945a082d2e 100644
--- a/pkgs/tools/security/pbis/default.nix
+++ b/pkgs/tools/security/pbis/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, perl, flex, bison, curl,
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, perl, flex, bison, curl,
   pam, popt, libiconv, libuuid, openssl_1_0_2, cyrus_sasl, sqlite, tdb, libxml2 }:
 
 stdenv.mkDerivation rec {
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
   '';
   outputs = [ "out" "sys" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "BeyondTrust AD Bridge Open simplifies the process of joining non-Microsoft hosts to Active Directory domains";
     homepage = "https://github.com/BeyondTrust/pbis-open";
     license = with licenses; [ gpl2 lgpl21 ];
diff --git a/pkgs/tools/security/pcsc-cyberjack/default.nix b/pkgs/tools/security/pcsc-cyberjack/default.nix
index 015e3938c3ef7..65446e6fc44cb 100644
--- a/pkgs/tools/security/pcsc-cyberjack/default.nix
+++ b/pkgs/tools/security/pcsc-cyberjack/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, pkgconfig, libusb1, pcsclite }:
+{ lib, stdenv, fetchurl, autoreconfHook, pkgconfig, libusb1, pcsclite }:
 
 let
   version = "3.99.5";
@@ -32,7 +32,7 @@ in stdenv.mkDerivation rec {
 
   postInstall = "make -C tools/cjflash install";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "REINER SCT cyberJack USB chipcard reader user space driver";
     homepage = "https://www.reiner-sct.com/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/pcsc-scm-scl011/default.nix b/pkgs/tools/security/pcsc-scm-scl011/default.nix
index 02e38bbe249ad..a9697718e3cfc 100644
--- a/pkgs/tools/security/pcsc-scm-scl011/default.nix
+++ b/pkgs/tools/security/pcsc-scm-scl011/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, libusb-compat-0_1 }:
+{ lib, stdenv, fetchurl, unzip, libusb-compat-0_1 }:
 
 let
   arch = if stdenv.hostPlatform.system == "i686-linux" then "32"
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
       $out/pcsc/drivers/SCLGENERIC.bundle/Contents/Linux/libSCLGENERIC.so.${version};
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SCM Microsystems SCL011 chipcard reader user space driver";
     homepage = "https://www.scm-pc-card.de/index.php?lang=en&page=product&function=show_product&product_id=630";
     downloadPage = "https://support.identiv.com/scl010-scl011/";
diff --git a/pkgs/tools/security/pcsclite/default.nix b/pkgs/tools/security/pcsclite/default.nix
index 98a3e8797fbf5..8a4ae08944035 100644
--- a/pkgs/tools/security/pcsclite/default.nix
+++ b/pkgs/tools/security/pcsclite/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, udev, dbus, perl, python3
+{ lib, stdenv, fetchurl, pkgconfig, udev, dbus, perl, python3
 , IOKit ? null }:
 
 stdenv.mkDerivation rec {
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ python3 ] ++ stdenv.lib.optionals stdenv.isLinux [ udev dbus ]
              ++ stdenv.lib.optionals stdenv.isDarwin [ IOKit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Middleware to access a smart card using SCard API (PC/SC)";
     homepage = "https://pcsclite.apdu.fr/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/security/pgpdump/default.nix b/pkgs/tools/security/pgpdump/default.nix
index cd421224fa633..89ee6a9eab2df 100644
--- a/pkgs/tools/security/pgpdump/default.nix
+++ b/pkgs/tools/security/pgpdump/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , supportCompressedPackets ? true, zlib, bzip2
 }:
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = stdenv.lib.optionals supportCompressedPackets [ zlib bzip2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PGP packet visualizer";
     longDescription = ''
       pgpdump is a PGP packet visualizer which displays the packet format of
diff --git a/pkgs/tools/security/phrasendrescher/default.nix b/pkgs/tools/security/phrasendrescher/default.nix
index f62288c062b8c..7e8c87f6e82c3 100644
--- a/pkgs/tools/security/phrasendrescher/default.nix
+++ b/pkgs/tools/security/phrasendrescher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, libssh2, gpgme }:
+{ lib, stdenv, fetchurl, openssl, libssh2, gpgme }:
 
 stdenv.mkDerivation rec {
   pname = "phrasendrescher";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--with-plugins" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A modular and multi processing pass phrase cracking tool";
     homepage = "https://leidecker.info/projects/phrasendrescher/index.shtml";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/pinentry/default.nix b/pkgs/tools/security/pinentry/default.nix
index a72e8f9f5b2ab..cac245bb256ee 100644
--- a/pkgs/tools/security/pinentry/default.nix
+++ b/pkgs/tools/security/pinentry/default.nix
@@ -89,7 +89,7 @@ pinentryMkDerivation rec {
 
   passthru = { flavors = enabledFlavors; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gnupg.org/aegypten2/";
     description = "GnuPG’s interface to passphrase input";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/proxmark3/default.nix b/pkgs/tools/security/proxmark3/default.nix
index 304ba041b46df..4cc831eda391a 100644
--- a/pkgs/tools/security/proxmark3/default.nix
+++ b/pkgs/tools/security/proxmark3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, ncurses, readline, pcsclite, qt5
+{ lib, stdenv, fetchFromGitHub, pkgconfig, ncurses, readline, pcsclite, qt5
 , gcc-arm-embedded }:
 
 let
@@ -33,7 +33,7 @@ let
         install -Dt $out/firmware bootrom/obj/bootrom.elf armsrc/obj/fullimage.elf
       '';
 
-      meta = with stdenv.lib; {
+      meta = with lib; {
         description = "Client for proxmark3, powerful general purpose RFID tool";
         homepage = "http://www.proxmark.org";
         license = licenses.gpl2Plus;
diff --git a/pkgs/tools/security/pyrit/default.nix b/pkgs/tools/security/pyrit/default.nix
index 93ae86416e13c..ead55036425fc 100644
--- a/pkgs/tools/security/pyrit/default.nix
+++ b/pkgs/tools/security/pyrit/default.nix
@@ -32,7 +32,7 @@ python2Packages.buildPythonApplication rec {
   buildInputs = [ openssl zlib libpcap ];
   propagatedBuildInputs = [ cpyrit_opencl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/JPaulMora/Pyrit";
     description = "GPGPU-driven WPA/WPA2-PSK key cracker";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/qdigidoc/default.nix b/pkgs/tools/security/qdigidoc/default.nix
index fcbc166689e3a..51ddad0634f63 100644
--- a/pkgs/tools/security/qdigidoc/default.nix
+++ b/pkgs/tools/security/qdigidoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchgit, fetchurl, cmake, darkhttpd, gettext, makeWrapper, pkgconfig
+{ lib, stdenv, mkDerivation, fetchgit, fetchurl, cmake, darkhttpd, gettext, makeWrapper, pkgconfig
 , libdigidocpp, opensc, openldap, openssl, pcsclite, qtbase, qttranslations, qtsvg }:
 
 mkDerivation rec {
@@ -40,7 +40,7 @@ mkDerivation rec {
       --prefix LD_LIBRARY_PATH : ${opensc}/lib/pkcs11/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Qt-based UI for signing and verifying DigiDoc documents";
     homepage = "https://www.id.ee/";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/tools/security/rage/default.nix b/pkgs/tools/security/rage/default.nix
index 69ea8c0f9c2cf..5cf38cb756d95 100644
--- a/pkgs/tools/security/rage/default.nix
+++ b/pkgs/tools/security/rage/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, installShellFiles
+{ lib, stdenv, rustPlatform, fetchFromGitHub, installShellFiles
 , Foundation, Security }:
 
 rustPlatform.buildRustPackage rec {
@@ -31,7 +31,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion target/completions/*.{bash,fish,zsh}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple, secure and modern encryption tool with small explicit keys, no config options, and UNIX-style composability";
     homepage = "https://github.com/str4d/rage";
     changelog = "https://github.com/str4d/rage/releases/tag/v${version}";
diff --git a/pkgs/tools/security/rarcrack/default.nix b/pkgs/tools/security/rarcrack/default.nix
index 9749d82516882..e5bbb7e8421db 100644
--- a/pkgs/tools/security/rarcrack/default.nix
+++ b/pkgs/tools/security/rarcrack/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, libxml2, file, p7zip, unrar, unzip}:
+{lib, stdenv, fetchFromGitHub, libxml2, file, p7zip, unrar, unzip}:
 
 stdenv.mkDerivation {
   pname = "rarcrack";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     mkdir -p $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "This program can crack zip,7z and rar file passwords";
     longDescription = ''
     If you forget your password for compressed archive (rar, 7z, zip), this program is the solution.
diff --git a/pkgs/tools/security/rhash/default.nix b/pkgs/tools/security/rhash/default.nix
index 394dd89484fe5..f4cc65f5d8e7d 100644
--- a/pkgs/tools/security/rhash/default.nix
+++ b/pkgs/tools/security/rhash/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which }:
+{ lib, stdenv, fetchFromGitHub, which }:
 
 stdenv.mkDerivation rec {
   version = "1.4.0";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   installTargets = [ "install" "install-lib-shared" "install-lib-so-link" "install-lib-headers" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://rhash.sourceforge.net/";
     description = "Console utility and library for computing and verifying hash sums of files";
     license = licenses.bsd0;
diff --git a/pkgs/tools/security/ripasso/cursive.nix b/pkgs/tools/security/ripasso/cursive.nix
index 29229bff00289..24e1146346450 100644
--- a/pkgs/tools/security/ripasso/cursive.nix
+++ b/pkgs/tools/security/ripasso/cursive.nix
@@ -29,7 +29,7 @@ buildRustPackage rec {
     rm $out/bin/ripasso-man
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple password manager written in Rust";
     homepage = "https://github.com/cortex/ripasso";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/rustscan/default.nix b/pkgs/tools/security/rustscan/default.nix
index 43b6a3a0afd79..3d84900f18e64 100644
--- a/pkgs/tools/security/rustscan/default.nix
+++ b/pkgs/tools/security/rustscan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, nmap, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, nmap, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "rustscan";
@@ -29,7 +29,7 @@ rustPlatform.buildRustPackage rec {
     "--skip=run_python_script"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Faster Nmap Scanning with Rust";
     homepage = "https://github.com/RustScan/RustScan";
     license = licenses.gpl3Only;
diff --git a/pkgs/tools/security/safe/default.nix b/pkgs/tools/security/safe/default.nix
index 43d791e19dbe8..2f0f4501fd2f4 100644
--- a/pkgs/tools/security/safe/default.nix
+++ b/pkgs/tools/security/safe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoPackage
 , fetchFromGitHub
 }:
@@ -22,7 +22,7 @@ buildGoPackage rec {
     buildFlagsArray+=("-ldflags" "-X main.Version=${version}")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Vault CLI";
     homepage = "https://github.com/starkandwayne/safe";
     license = licenses.mit;
diff --git a/pkgs/tools/security/saml2aws/default.nix b/pkgs/tools/security/saml2aws/default.nix
index 68721bbdebc19..2e617a8de8a50 100644
--- a/pkgs/tools/security/saml2aws/default.nix
+++ b/pkgs/tools/security/saml2aws/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "saml2aws";
@@ -22,7 +22,7 @@ buildGoModule rec {
     -ldflags=-X main.Version=${version}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CLI tool which enables you to login and retrieve AWS temporary credentials using a SAML IDP";
     homepage    = "https://github.com/Versent/saml2aws";
     license     = licenses.mit;
diff --git a/pkgs/tools/security/sbsigntool/default.nix b/pkgs/tools/security/sbsigntool/default.nix
index 1a42ddf8becad..36e75094c5958 100644
--- a/pkgs/tools/security/sbsigntool/default.nix
+++ b/pkgs/tools/security/sbsigntool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchgit, autoconf, automake, pkgconfig, help2man
 , openssl, libuuid, gnu-efi, libbfd
 }:
@@ -42,7 +42,7 @@ stdenv.mkDerivation {
     make install
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for maintaining UEFI signature databases";
     homepage    = "http://jk.ozlabs.org/docs/sbkeysync-maintaing-uefi-key-databases";
     maintainers = [ maintainers.tstrobel ];
diff --git a/pkgs/tools/security/scallion/default.nix b/pkgs/tools/security/scallion/default.nix
index 1395b8e106177..91b92071fe796 100644
--- a/pkgs/tools/security/scallion/default.nix
+++ b/pkgs/tools/security/scallion/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, mono, openssl_1_0_2, ocl-icd }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, mono, openssl_1_0_2, ocl-icd }:
 
 stdenv.mkDerivation rec {
   version = "2.1";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       --add-flags $out/share/scallion.exe
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GPU-based tor hidden service name generator";
     homepage = src.meta.homepage;
     license = licenses.mit;
diff --git a/pkgs/tools/security/scrypt/default.nix b/pkgs/tools/security/scrypt/default.nix
index e230b2ee45745..89ff50e0a8a07 100644
--- a/pkgs/tools/security/scrypt/default.nix
+++ b/pkgs/tools/security/scrypt/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, util-linux, getconf }:
+{ lib, stdenv, fetchurl, openssl, util-linux, getconf }:
 
 stdenv.mkDerivation rec {
   pname = "scrypt";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
   checkTarget = "test";
   checkInputs = [ util-linux ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Encryption utility";
     homepage    = "https://www.tarsnap.com/scrypt.html";
     license     = licenses.bsd2;
diff --git a/pkgs/tools/security/secp256k1/default.nix b/pkgs/tools/security/secp256k1/default.nix
index d3b43d6adf691..55b02d7a8c30d 100644
--- a/pkgs/tools/security/secp256k1/default.nix
+++ b/pkgs/tools/security/secp256k1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, jdk
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, jdk
 
 # Enable ECDSA pubkey recovery module
 , enableRecovery ? true
@@ -42,7 +42,7 @@ stdenv.mkDerivation {
   doCheck = true;
   checkPhase = "./tests";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimized C library for EC operations on curve secp256k1";
     longDescription = ''
       Optimized C library for EC operations on curve secp256k1. Part of
diff --git a/pkgs/tools/security/sedutil/default.nix b/pkgs/tools/security/sedutil/default.nix
index 4877a8adfcefa..6ed4a23af1dd8 100644
--- a/pkgs/tools/security/sedutil/default.nix
+++ b/pkgs/tools/security/sedutil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "sedutil";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "DTA sedutil Self encrypting drive software";
     homepage    = "https://www.drivetrust.com";
     license     = licenses.gpl3;
diff --git a/pkgs/tools/security/sequoia/default.nix b/pkgs/tools/security/sequoia/default.nix
index 201b4c56f2b9e..706c9edc481ce 100644
--- a/pkgs/tools/security/sequoia/default.nix
+++ b/pkgs/tools/security/sequoia/default.nix
@@ -97,7 +97,7 @@ rustPlatform.buildRustPackage rec {
   checkPhase = null;
   installPhase = null;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cool new OpenPGP implementation";
     homepage = "https://sequoia-pgp.org/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/sha1collisiondetection/default.nix b/pkgs/tools/security/sha1collisiondetection/default.nix
index 8c6a026a61248..07c9ed9b24083 100644
--- a/pkgs/tools/security/sha1collisiondetection/default.nix
+++ b/pkgs/tools/security/sha1collisiondetection/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libtool, which }:
+{ lib, stdenv, fetchFromGitHub, libtool, which }:
 
 stdenv.mkDerivation  rec {
   pname = "sha1collisiondetection";
@@ -17,7 +17,7 @@ stdenv.mkDerivation  rec {
 
   nativeBuildInputs = [ libtool which ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Library and command line tool to detect SHA-1 collision";
     longDescription = ''
       This library and command line tool were designed as near drop-in
diff --git a/pkgs/tools/security/shc/default.nix b/pkgs/tools/security/shc/default.nix
index 3705d2c7ed1ad..f9bdf66ed860a 100644
--- a/pkgs/tools/security/shc/default.nix
+++ b/pkgs/tools/security/shc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "shc";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
     sha256 = "0bfn404plsssa14q89k9l3s5lxq3df0sny5lis4j2w75qrkqx694";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://neurobin.org/projects/softwares/unix/shc/";
     description = "Shell Script Compiler";
     platforms = stdenv.lib.platforms.linux;
diff --git a/pkgs/tools/security/signify/default.nix b/pkgs/tools/security/signify/default.nix
index 3ec260a7c0c57..1b59db540a2bf 100644
--- a/pkgs/tools/security/signify/default.nix
+++ b/pkgs/tools/security/signify/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libbsd, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, libbsd, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "signify";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     export PREFIX=$out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "OpenBSD signing tool";
     longDescription = ''
       OpenBSDs signing tool, which uses the Ed25519 public key signature system
diff --git a/pkgs/tools/security/signing-party/default.nix b/pkgs/tools/security/signing-party/default.nix
index 17c65d28884e1..c2a51f3bdf5de 100644
--- a/pkgs/tools/security/signing-party/default.nix
+++ b/pkgs/tools/security/signing-party/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, autoconf, automake, makeWrapper
+{ lib, stdenv, fetchFromGitLab, autoconf, automake, makeWrapper
 , python3, perl, perlPackages
 , libmd, gnupg, which, getopt, libpaper, nettools, qprint
 , sendmailPath ? "/run/wrappers/bin/sendmail" }:
@@ -196,7 +196,7 @@ in stdenv.mkDerivation rec {
       ${with perlPackages; makePerlPath [ GD ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://salsa.debian.org/signing-party-team/signing-party";
     description = "A collection of several projects relating to OpenPGP";
     longDescription = ''
diff --git a/pkgs/tools/security/simple-tpm-pk11/default.nix b/pkgs/tools/security/simple-tpm-pk11/default.nix
index 2a360b4321c50..4d5c020ad422a 100644
--- a/pkgs/tools/security/simple-tpm-pk11/default.nix
+++ b/pkgs/tools/security/simple-tpm-pk11/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, trousers, openssl, opencryptoki, autoreconfHook, libtool }:
+{ lib, stdenv, fetchFromGitHub, trousers, openssl, opencryptoki, autoreconfHook, libtool }:
 
 stdenv.mkDerivation rec {
   pname = "simple-tpm-pk11";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple PKCS11 provider for TPM chips";
     longDescription = ''
       A simple library for using the TPM chip to secure SSH keys.
diff --git a/pkgs/tools/security/snow/default.nix b/pkgs/tools/security/snow/default.nix
index db52d853b7a3d..6d264c09ade9c 100644
--- a/pkgs/tools/security/snow/default.nix
+++ b/pkgs/tools/security/snow/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "snow";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
     install -Dm755 snow -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Conceal messages in ASCII text by appending whitespace to the end of lines";
     homepage = "http://www.darkside.com.au/snow/";
     license = licenses.apsl20;
diff --git a/pkgs/tools/security/softhsm/default.nix b/pkgs/tools/security/softhsm/default.nix
index 61afb9082d0fa..5ba0bd11f827b 100644
--- a/pkgs/tools/security/softhsm/default.nix
+++ b/pkgs/tools/security/softhsm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, botan2, libobjc, Security }:
+{ lib, stdenv, fetchurl, botan2, libobjc, Security }:
 
 stdenv.mkDerivation rec {
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   postInstall = "rm -rf $out/var";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.opendnssec.org/softhsm";
     description = "Cryptographic store accessible through a PKCS #11 interface";
     longDescription = "
diff --git a/pkgs/tools/security/sops/default.nix b/pkgs/tools/security/sops/default.nix
index 7557fa6a6d386..9eddc308a4ff9 100644
--- a/pkgs/tools/security/sops/default.nix
+++ b/pkgs/tools/security/sops/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "sops";
@@ -15,7 +15,7 @@ buildGoModule rec {
 
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mozilla/sops";
     description = "Mozilla sops (Secrets OPerationS) is an editor of encrypted files";
     maintainers = [ maintainers.marsam ];
diff --git a/pkgs/tools/security/spectre-meltdown-checker/default.nix b/pkgs/tools/security/spectre-meltdown-checker/default.nix
index b8f4eeea338fa..53797ef98514c 100644
--- a/pkgs/tools/security/spectre-meltdown-checker/default.nix
+++ b/pkgs/tools/security/spectre-meltdown-checker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, coreutils, binutils-unwrapped }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, coreutils, binutils-unwrapped }:
 
 stdenv.mkDerivation rec {
   pname = "spectre-meltdown-checker";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Spectre & Meltdown vulnerability/mitigation checker for Linux";
     homepage = "https://github.com/speed47/spectre-meltdown-checker";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/srm/default.nix b/pkgs/tools/security/srm/default.nix
index 853ad4f280a2e..587d7782e765f 100644
--- a/pkgs/tools/security/srm/default.nix
+++ b/pkgs/tools/security/srm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
 
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     sha256 = "10sjarhprs6s4zandndg720528rcnd4xk8dl48pjj7li1q9c30vm";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Delete files securely";
     longDescription = ''
       srm (secure rm) is a command-line compatible rm(1) which
diff --git a/pkgs/tools/security/sshguard/default.nix b/pkgs/tools/security/sshguard/default.nix
index 6bae0fddc23d0..88e726bc86353 100644
--- a/pkgs/tools/security/sshguard/default.nix
+++ b/pkgs/tools/security/sshguard/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook, yacc, flex}:
+{ lib, stdenv, fetchurl, autoreconfHook, yacc, flex}:
 
 stdenv.mkDerivation rec {
   version = "2.4.1";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--sysconfdir=/etc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Protects hosts from brute-force attacks";
     longDescription = ''
       SSHGuard can read log messages from various input sources. Log messages are parsed, line-by-line, for recognized patterns.
diff --git a/pkgs/tools/security/sshuttle/default.nix b/pkgs/tools/security/sshuttle/default.nix
index 6f620904872dd..4a24e4596972f 100644
--- a/pkgs/tools/security/sshuttle/default.nix
+++ b/pkgs/tools/security/sshuttle/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python3Packages
 , makeWrapper
 , coreutils
@@ -30,7 +30,7 @@ python3Packages.buildPythonApplication rec {
       --prefix PATH : "${stdenv.lib.makeBinPath runtimeDeps}" \
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sshuttle/sshuttle/";
     description = "Transparent proxy server that works as a poor man's VPN";
     longDescription = ''
diff --git a/pkgs/tools/security/sslscan/default.nix b/pkgs/tools/security/sslscan/default.nix
index 68efa7a17d1fe..fcf9c4c1ac2fd 100644
--- a/pkgs/tools/security/sslscan/default.nix
+++ b/pkgs/tools/security/sslscan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openssl }:
+{ lib, stdenv, fetchFromGitHub, openssl }:
 
 stdenv.mkDerivation rec {
   pname = "sslscan";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" "CC=cc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tests SSL/TLS services and discover supported cipher suites";
     homepage = "https://github.com/rbsec/sslscan";
     license = licenses.gpl3;
diff --git a/pkgs/tools/security/steghide/default.nix b/pkgs/tools/security/steghide/default.nix
index 5ac40e0a04744..cb2a0473cf155 100644
--- a/pkgs/tools/security/steghide/default.nix
+++ b/pkgs/tools/security/steghide/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libjpeg, libmcrypt, zlib, libmhash, gettext, libtool}:
+{ lib, stdenv, fetchurl, libjpeg, libmcrypt, zlib, libmhash, gettext, libtool}:
 
 stdenv.mkDerivation rec {
   buildInputs = [ libjpeg libmcrypt zlib libmhash gettext libtool ];
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     export AM_CXXFLAGS="$CXXFLAGS -std=c++0x"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://steghide.sourceforge.net/";
     description = "Steganography program that is able to hide data in various kinds of image- and audio-files";
     license = licenses.gpl2;
diff --git a/pkgs/tools/security/stegseek/default.nix b/pkgs/tools/security/stegseek/default.nix
index b3d518a719faf..d2fb825b5296f 100644
--- a/pkgs/tools/security/stegseek/default.nix
+++ b/pkgs/tools/security/stegseek/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , cmake
 , fetchFromGitHub
 , libjpeg
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to crack steganography";
     longDescription = ''
       Stegseek is a lightning fast steghide cracker that can be
diff --git a/pkgs/tools/security/stoken/default.nix b/pkgs/tools/security/stoken/default.nix
index 22dc5e476e7f4..497d3816a767c 100644
--- a/pkgs/tools/security/stoken/default.nix
+++ b/pkgs/tools/security/stoken/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig
 , libxml2, nettle
 , withGTK3 ? true, gtk3 }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     libxml2 nettle
   ] ++ stdenv.lib.optional withGTK3 gtk3;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Software Token for Linux/UNIX";
     homepage = "https://github.com/cernekee/stoken";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/tools/security/su-exec/default.nix b/pkgs/tools/security/su-exec/default.nix
index 8ff33ee1ec91c..0e26d2430cb13 100644
--- a/pkgs/tools/security/su-exec/default.nix
+++ b/pkgs/tools/security/su-exec/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "su-exec";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp -a su-exec $out/bin/su-exec
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "switch user and group id and exec";
     homepage    = "https://github.com/ncopa/su-exec";
     license     = licenses.mit;
diff --git a/pkgs/tools/security/subjs/default.nix b/pkgs/tools/security/subjs/default.nix
index ad10ef5eaf24c..5b9a237d49cb2 100644
--- a/pkgs/tools/security/subjs/default.nix
+++ b/pkgs/tools/security/subjs/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -18,7 +18,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.AppVersion=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fetcher for Javascript files";
     longDescription = ''
       subjs fetches Javascript files from a list of URLs or subdomains.
diff --git a/pkgs/tools/security/sudolikeaboss/default.nix b/pkgs/tools/security/sudolikeaboss/default.nix
index 639926578c7b5..a137646382379 100644
--- a/pkgs/tools/security/sudolikeaboss/default.nix
+++ b/pkgs/tools/security/sudolikeaboss/default.nix
@@ -1,5 +1,5 @@
 # This file was generated by go2nix, then modified by hand for Darwin support.
-{ stdenv, buildGoPackage, fetchFromGitHub, darwin }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub, darwin }:
 
 buildGoPackage rec {
   pname = "sudolikeaboss-unstable";
@@ -21,7 +21,7 @@ buildGoPackage rec {
     Cocoa
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit version;
     inherit (src.meta) homepage;
     description = "Get 1password access from iterm2";
diff --git a/pkgs/tools/security/tboot/default.nix b/pkgs/tools/security/tboot/default.nix
index 38f467fb441f1..bf13fe7822e84 100644
--- a/pkgs/tools/security/tboot/default.nix
+++ b/pkgs/tools/security/tboot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, trousers, openssl, zlib }:
+{ lib, stdenv, fetchurl, trousers, openssl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "tboot";
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A pre-kernel/VMM module that uses Intel(R) TXT to perform a measured and verified launch of an OS kernel/VMM";
     homepage    = "https://sourceforge.net/projects/tboot/";
     license     = licenses.bsd3;
diff --git a/pkgs/tools/security/teler/default.nix b/pkgs/tools/security/teler/default.nix
index 3786637585916..1acb9e5609ebf 100644
--- a/pkgs/tools/security/teler/default.nix
+++ b/pkgs/tools/security/teler/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -19,7 +19,7 @@ buildGoModule rec {
   # test require internet access
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Real-time HTTP Intrusion Detection";
     longDescription = ''
       teler is an real-time intrusion detection and threat alert
diff --git a/pkgs/tools/security/thc-hydra/default.nix b/pkgs/tools/security/thc-hydra/default.nix
index f83d2675c6ac1..81086e77483fd 100644
--- a/pkgs/tools/security/thc-hydra/default.nix
+++ b/pkgs/tools/security/thc-hydra/default.nix
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
       --add-flags --hydra-path --add-flags "$out/bin/hydra"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A very fast network logon cracker which support many different services";
     homepage = "https://www.thc.org/thc-hydra/";
     license = licenses.agpl3;
diff --git a/pkgs/tools/security/thc-ipv6/default.nix b/pkgs/tools/security/thc-ipv6/default.nix
index b8175ef6dbaca..6e7f4fb2891aa 100644
--- a/pkgs/tools/security/thc-ipv6/default.nix
+++ b/pkgs/tools/security/thc-ipv6/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpcap, openssl, libnetfilter_queue, libnfnetlink }:
+{ lib, stdenv, fetchFromGitHub, libpcap, openssl, libnetfilter_queue, libnfnetlink }:
 stdenv.mkDerivation rec {
   pname = "thc-ipv6";
   version = "3.8";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "PREFIX=$(out)"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "IPv6 attack toolkit";
     homepage = "https://github.com/vanhauser-thc/thc-ipv6";
     maintainers = with maintainers; [ ajs124 ];
diff --git a/pkgs/tools/security/tor/default.nix b/pkgs/tools/security/tor/default.nix
index e46fd4790a31f..038f4040d31af 100644
--- a/pkgs/tools/security/tor/default.nix
+++ b/pkgs/tools/security/tor/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libevent, openssl, zlib, torsocks
+{ lib, stdenv, fetchurl, pkgconfig, libevent, openssl, zlib, torsocks
 , libseccomp, systemd, libcap, lzma, zstd, scrypt, nixosTests
 , writeShellScript
 
@@ -88,7 +88,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.torproject.org/";
     repositories.git = "https://git.torproject.org/git/tor";
     description = "Anonymizing overlay network";
diff --git a/pkgs/tools/security/tpm-luks/default.nix b/pkgs/tools/security/tpm-luks/default.nix
index fc1931fa4ba27..25e28f1583159 100644
--- a/pkgs/tools/security/tpm-luks/default.nix
+++ b/pkgs/tools/security/tpm-luks/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, gawk, trousers, cryptsetup, openssl }:
+{ lib, stdenv, fetchgit, autoreconfHook, gawk, trousers, cryptsetup, openssl }:
 
 stdenv.mkDerivation {
   pname = "tpm-luks";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
     rm -r $out/nix
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "LUKS key storage in TPM NVRAM";
     homepage    = "https://github.com/shpedoikal/tpm-luks/";
     maintainers = [ maintainers.tstrobel ];
diff --git a/pkgs/tools/security/tpm-quote-tools/default.nix b/pkgs/tools/security/tpm-quote-tools/default.nix
index a652867a0d096..94da17fabeca6 100644
--- a/pkgs/tools/security/tpm-quote-tools/default.nix
+++ b/pkgs/tools/security/tpm-quote-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, trousers, openssl }:
+{ lib, stdenv, fetchurl, trousers, openssl }:
 
 stdenv.mkDerivation rec { 
   pname = "tpm-quote-tools";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
       $out/bin/tpm_mkaik
   '';
 
-  meta = with stdenv.lib; { 
+  meta = with lib; { 
     description = "A collection of programs that provide support for TPM based attestation using the TPM quote mechanism";
     longDescription = ''
       The TPM Quote Tools is a collection of programs that provide support
diff --git a/pkgs/tools/security/tpm-tools/default.nix b/pkgs/tools/security/tpm-tools/default.nix
index 5e0b4e6d94f43..c0e2941323a6e 100644
--- a/pkgs/tools/security/tpm-tools/default.nix
+++ b/pkgs/tools/security/tpm-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, trousers, openssl, opencryptoki, perl }:
+{ lib, stdenv, fetchurl, trousers, openssl, opencryptoki, perl }:
 
 let
   version = "1.3.9.1";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ perl ];
   buildInputs = [ trousers openssl opencryptoki ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Management tools for TPM hardware";
     longDescription = ''
       tpm-tools is an open-source package designed to enable user and
diff --git a/pkgs/tools/security/trousers/default.nix b/pkgs/tools/security/trousers/default.nix
index 2cc702cf6f2f6..76a3443d07698 100644
--- a/pkgs/tools/security/trousers/default.nix
+++ b/pkgs/tools/security/trousers/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, pkgconfig }:
+{ lib, stdenv, fetchurl, openssl, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "trousers";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE = [ "-DALLOW_NON_TSS_CONFIG_FILE" ];
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Trusted computing software stack";
     homepage    = "http://trousers.sourceforge.net/";
     license     = licenses.bsd3;
diff --git a/pkgs/tools/security/urlhunter/default.nix b/pkgs/tools/security/urlhunter/default.nix
index 239eabbe8b361..3364b622ad63b 100644
--- a/pkgs/tools/security/urlhunter/default.nix
+++ b/pkgs/tools/security/urlhunter/default.nix
@@ -1,6 +1,6 @@
 { buildGoModule
 , fetchFromGitHub
-, stdenv
+, lib, stdenv
 }:
 
 buildGoModule rec {
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "165kplaqigis0anafvzfqzwc3jjhsn2mwgf4phb4ck75n3yf85ys";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recon tool that allows searching shortened URLs";
     longDescription = ''
       urlhunter is a recon tool that allows searching on URLs that are
diff --git a/pkgs/tools/security/vault/default.nix b/pkgs/tools/security/vault/default.nix
index d1d16a89d460c..3af00b9a22b3b 100644
--- a/pkgs/tools/security/vault/default.nix
+++ b/pkgs/tools/security/vault/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage, installShellFiles, nixosTests }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage, installShellFiles, nixosTests }:
 
 buildGoPackage rec {
   pname = "vault";
@@ -26,7 +26,7 @@ buildGoPackage rec {
 
   passthru.tests.vault = nixosTests.vault;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.vaultproject.io/";
     description = "A tool for managing secrets";
     changelog = "https://github.com/hashicorp/vault/blob/v${version}/CHANGELOG.md";
diff --git a/pkgs/tools/security/vault/vault-bin.nix b/pkgs/tools/security/vault/vault-bin.nix
index 01bb80f518a96..775bd8c6951e1 100644
--- a/pkgs/tools/security/vault/vault-bin.nix
+++ b/pkgs/tools/security/vault/vault-bin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip }:
+{ lib, stdenv, fetchurl, unzip }:
 
 let
   version = "1.6.1";
@@ -40,7 +40,7 @@ in stdenv.mkDerivation {
     echo "complete -C $out/bin/vault vault" > $out/share/bash-completion/completions/vault
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.vaultproject.io";
     description = "A tool for managing secrets, this binary includes the UI";
     platforms = [ "x86_64-linux" "i686-linux" "x86_64-darwin" "aarch64-linux" ];
diff --git a/pkgs/tools/security/volatility/default.nix b/pkgs/tools/security/volatility/default.nix
index 4f1e90eb9100e..8ffdfc4e2b097 100644
--- a/pkgs/tools/security/volatility/default.nix
+++ b/pkgs/tools/security/volatility/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "volatility";
@@ -15,7 +15,7 @@ pythonPackages.buildPythonApplication rec {
 
   propagatedBuildInputs = [ pythonPackages.pycrypto pythonPackages.distorm3 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.volatilityfoundation.org/";
     description = "Advanced memory forensics framework";
     maintainers = with maintainers; [ bosu ];
diff --git a/pkgs/tools/security/vulnix/default.nix b/pkgs/tools/security/vulnix/default.nix
index d4a3a0c621a1c..e95adf3e1e6c2 100644
--- a/pkgs/tools/security/vulnix/default.nix
+++ b/pkgs/tools/security/vulnix/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , python3Packages
 , nix
 , ronn
@@ -48,7 +48,7 @@ python3Packages.buildPythonApplication rec {
 
   dontStrip = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "NixOS vulnerability scanner";
     homepage = "https://github.com/flyingcircusio/vulnix";
     license = licenses.bsd3;
diff --git a/pkgs/tools/security/wipe/default.nix b/pkgs/tools/security/wipe/default.nix
index 6b84803d2c46c..2c3c9376f67b3 100644
--- a/pkgs/tools/security/wipe/default.nix
+++ b/pkgs/tools/security/wipe/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "wipe";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   patches = [ ./fix-install.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Secure file wiping utility";
     homepage    = "http://wipe.sourceforge.net/";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/security/yara/default.nix b/pkgs/tools/security/yara/default.nix
index 8a11953502341..19d409e03eea0 100644
--- a/pkgs/tools/security/yara/default.nix
+++ b/pkgs/tools/security/yara/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , autoreconfHook
 , pcre
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
     (stdenv.lib.enableFeature enableCuckoo "cuckoo")
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The pattern matching swiss knife for malware researchers";
     homepage = "http://Virustotal.github.io/yara/";
     license = licenses.asl20;
diff --git a/pkgs/tools/security/zmap/default.nix b/pkgs/tools/security/zmap/default.nix
index e2350b67c7d7d..fdcb5ed5ce92e 100644
--- a/pkgs/tools/security/zmap/default.nix
+++ b/pkgs/tools/security/zmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, libjson, json_c, gengetopt, flex, byacc, gmp
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, libjson, json_c, gengetopt, flex, byacc, gmp
 , libpcap
 }:
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://zmap.io/";
     license = licenses.asl20;
     description = "Fast single packet network scanner designed for Internet-wide network surveys";
diff --git a/pkgs/tools/security/zzuf/default.nix b/pkgs/tools/security/zzuf/default.nix
index 428f1ec1d09cd..e7d12d8a68ea0 100644
--- a/pkgs/tools/security/zzuf/default.nix
+++ b/pkgs/tools/security/zzuf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, pkgconfig }:
 
 stdenv.mkDerivation rec {
   pname = "zzuf";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   preConfigure = "./bootstrap";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Transparent application input fuzzer";
     homepage = "http://caca.zoy.org/wiki/zzuf";
     license = licenses.wtfpl;
diff --git a/pkgs/tools/system/acct/default.nix b/pkgs/tools/system/acct/default.nix
index dd4eb0d5d2b84..fbe396f1fdf41 100644
--- a/pkgs/tools/system/acct/default.nix
+++ b/pkgs/tools/system/acct/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv }:
+{ fetchurl, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   name = "acct-6.6.4";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNU Accounting Utilities, login and process accounting utilities";
 
     longDescription = ''
diff --git a/pkgs/tools/system/acpica-tools/default.nix b/pkgs/tools/system/acpica-tools/default.nix
index 62b1be619650a..36ad8ff06e389 100644
--- a/pkgs/tools/system/acpica-tools/default.nix
+++ b/pkgs/tools/system/acpica-tools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bison, flex }:
+{ lib, stdenv, fetchurl, bison, flex }:
 
 stdenv.mkDerivation rec {
   pname = "acpica-tools";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ACPICA Tools";
     homepage = "https://www.acpica.org/";
     license = with licenses; [ gpl2 bsd3 ];
diff --git a/pkgs/tools/system/actkbd/default.nix b/pkgs/tools/system/actkbd/default.nix
index 706b3700a4157..ac2fb338d3d2f 100644
--- a/pkgs/tools/system/actkbd/default.nix
+++ b/pkgs/tools/system/actkbd/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv }:
+{ fetchurl, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   name = "actkbd-0.2.8";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     cp -r README samples $out/share/doc/actkbd
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A keyboard shortcut daemon";
     longDescription = ''
       actkbd is a simple daemon that binds actions to keyboard events
diff --git a/pkgs/tools/system/augeas/default.nix b/pkgs/tools/system/augeas/default.nix
index 338b8f8ac4531..6a8c50c60957c 100644
--- a/pkgs/tools/system/augeas/default.nix
+++ b/pkgs/tools/system/augeas/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, readline, libxml2 }:
+{ lib, stdenv, fetchurl, pkgconfig, readline, libxml2 }:
 
 stdenv.mkDerivation rec {
   pname = "augeas";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ readline libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Configuration editing tool";
     license = licenses.lgpl2;
     homepage = "http://augeas.net/";
diff --git a/pkgs/tools/system/autocpu-freq/default.nix b/pkgs/tools/system/autocpu-freq/default.nix
index 348fd689ab960..7e23b8b5b0f74 100644
--- a/pkgs/tools/system/autocpu-freq/default.nix
+++ b/pkgs/tools/system/autocpu-freq/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub }:
+{ lib, stdenv, python3Packages, fetchFromGitHub }:
 
 python3Packages.buildPythonPackage rec {
   pname = "auto-cpufreq";
@@ -24,7 +24,7 @@ python3Packages.buildPythonPackage rec {
     cp ${src}/scripts/cpufreqctl.sh $out/bin/cpufreqctl
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/AdnanHodzic/auto-cpufreq";
     description = "Automatic CPU speed & power optimizer for Linux";
     license = licenses.lgpl3Plus;
diff --git a/pkgs/tools/system/awstats/default.nix b/pkgs/tools/system/awstats/default.nix
index 9da6ac59f3de7..b04532d842ff8 100644
--- a/pkgs/tools/system/awstats/default.nix
+++ b/pkgs/tools/system/awstats/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, jdk }:
+{ lib, stdenv, fetchurl, perlPackages, jdk }:
 
 perlPackages.buildPerlPackage rec {
   pname = "awstats";
@@ -52,7 +52,7 @@ perlPackages.buildPerlPackage rec {
     mv docs "$doc/share/doc/awstats"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Real-time logfile analyzer to get advanced statistics";
     homepage = "http://awstats.org";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/system/bfs/default.nix b/pkgs/tools/system/bfs/default.nix
index c0755fafc06ab..c49f033c42ad3 100644
--- a/pkgs/tools/system/bfs/default.nix
+++ b/pkgs/tools/system/bfs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libcap, acl }:
+{ lib, stdenv, fetchFromGitHub, libcap, acl }:
 
 stdenv.mkDerivation rec {
   pname = "bfs";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
   makeFlags = [ "PREFIX=$(out)" ];
   buildFlags = [ "release" ]; # "release" enables compiler optimizations
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A breadth-first version of the UNIX find command";
     longDescription = ''
       bfs is a variant of the UNIX find command that operates breadth-first rather than
diff --git a/pkgs/tools/system/bottom/default.nix b/pkgs/tools/system/bottom/default.nix
index 1a975aef3932e..a79e8bdcebf20 100644
--- a/pkgs/tools/system/bottom/default.nix
+++ b/pkgs/tools/system/bottom/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, darwin, installShellFiles }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, darwin, installShellFiles }:
 
 rustPlatform.buildRustPackage rec {
   pname = "bottom";
@@ -27,7 +27,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion $releaseDir/build/bottom-*/out/btm.{bash,fish} --zsh $releaseDir/build/bottom-*/out/_btm
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cross-platform graphical process/system monitor with a customizable interface";
     homepage = "https://github.com/ClementTsang/bottom";
     license = licenses.mit;
diff --git a/pkgs/tools/system/bpytop/default.nix b/pkgs/tools/system/bpytop/default.nix
index feaebc14e0ad5..abcc159398846 100644
--- a/pkgs/tools/system/bpytop/default.nix
+++ b/pkgs/tools/system/bpytop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, fetchFromGitHub, makeWrapper, substituteAll }:
+{ lib, stdenv, python3Packages, fetchFromGitHub, makeWrapper, substituteAll }:
 
 stdenv.mkDerivation rec {
   pname = "bpytop";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
       --prefix PYTHONPATH : "$PYTHONPATH"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A resource monitor; python port of bashtop";
     homepage = src.meta.homepage;
     license = licenses.apsl20;
diff --git a/pkgs/tools/system/clinfo/default.nix b/pkgs/tools/system/clinfo/default.nix
index 7db7386c11116..dbcbae6eaa9a5 100644
--- a/pkgs/tools/system/clinfo/default.nix
+++ b/pkgs/tools/system/clinfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ocl-icd, opencl-headers }:
+{ lib, stdenv, fetchFromGitHub, ocl-icd, opencl-headers }:
 
 stdenv.mkDerivation rec {
   pname = "clinfo";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Print all known information about all available OpenCL platforms and devices in the system";
     homepage = "https://github.com/Oblomov/clinfo";
     license = licenses.cc0;
diff --git a/pkgs/tools/system/cm-rgb/default.nix b/pkgs/tools/system/cm-rgb/default.nix
index acfe440b5d5c9..a50fa60197acb 100644
--- a/pkgs/tools/system/cm-rgb/default.nix
+++ b/pkgs/tools/system/cm-rgb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildPythonApplication
 , fetchFromGitHub
 , atk
@@ -46,7 +46,7 @@ buildPythonApplication rec {
       > $out/etc/udev/rules.d/60-cm-rgb.rules
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Control AMD Wraith Prism RGB LEDs";
     longDescription = ''
       cm-rgb controls AMD Wraith Prism RGB LEDS.
diff --git a/pkgs/tools/system/collectd/default.nix b/pkgs/tools/system/collectd/default.nix
index 278ab9056ad9f..eb64a09a22bd2 100644
--- a/pkgs/tools/system/collectd/default.nix
+++ b/pkgs/tools/system/collectd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, darwin, callPackage
+{ lib, stdenv, fetchurl, fetchpatch, darwin, callPackage
 , autoreconfHook
 , pkgconfig
 , libtool
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon which collects system performance statistics periodically";
     homepage = "https://collectd.org";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/consul-template/default.nix b/pkgs/tools/system/consul-template/default.nix
index fc388dd7cea4d..7604584e16754 100644
--- a/pkgs/tools/system/consul-template/default.nix
+++ b/pkgs/tools/system/consul-template/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "consul-template";
@@ -17,7 +17,7 @@ buildGoModule rec {
   # execute tests so we skip them here
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hashicorp/consul-template/";
     description = "Generic template rendering and notifications with Consul";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/system/cron/default.nix b/pkgs/tools/system/cron/default.nix
index 9cde31205e1f9..d1b8d2d6afd9e 100644
--- a/pkgs/tools/system/cron/default.nix
+++ b/pkgs/tools/system/cron/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, vim, sendmailPath ? "/usr/sbin/sendmail"}:
+{lib, stdenv, fetchurl, vim, sendmailPath ? "/usr/sbin/sendmail"}:
 
 stdenv.mkDerivation {
   name = "cron-4.1";
@@ -39,7 +39,7 @@ stdenv.mkDerivation {
 
   preInstall = "mkdir -p $out/bin $out/sbin $out/share/man/man1 $out/share/man/man5 $out/share/man/man8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Daemon for running commands at specific times (Vixie Cron)";
     license = licenses.bsd0;
     platforms = with platforms; linux ++ darwin;
diff --git a/pkgs/tools/system/daemon/default.nix b/pkgs/tools/system/daemon/default.nix
index c419824f96993..58f8da3ce4f7d 100644
--- a/pkgs/tools/system/daemon/default.nix
+++ b/pkgs/tools/system/daemon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation rec {
   pname = "daemon";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Turns other processes into daemons";
     longDescription = ''
       Daemon turns other process into daemons. There are many tasks that need
diff --git a/pkgs/tools/system/daemonize/default.nix b/pkgs/tools/system/daemonize/default.nix
index a8685189b61c8..b79da1986d73a 100644
--- a/pkgs/tools/system/daemonize/default.nix
+++ b/pkgs/tools/system/daemonize/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "daemonize";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "0q2c3i3si3k7wfhl6fyckkmkc81yp67pz52p3ggis79p4nczri10";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Runs a command as a Unix daemon";
     homepage    = "http://software.clapper.org/daemonize/";
     license     = licenses.bsd3;
diff --git a/pkgs/tools/system/das_watchdog/default.nix b/pkgs/tools/system/das_watchdog/default.nix
index 8c1a5657991cc..b9c25aef7a77f 100644
--- a/pkgs/tools/system/das_watchdog/default.nix
+++ b/pkgs/tools/system/das_watchdog/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, libgtop, xmessage, which, pkgconfig }:
+{ lib, stdenv, fetchgit, libgtop, xmessage, which, pkgconfig }:
 
 stdenv.mkDerivation {
   pname = "das_watchdog";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp test_rt $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/kmatheussen/das_watchdog";
     description = "A general watchdog for the linux operating system";
     longDescription = ''
diff --git a/pkgs/tools/system/datefudge/default.nix b/pkgs/tools/system/datefudge/default.nix
index 819071f3f068e..be2ad70498ae7 100644
--- a/pkgs/tools/system/datefudge/default.nix
+++ b/pkgs/tools/system/datefudge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, fetchpatch }:
+{ lib, stdenv, fetchgit, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "datefudge";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
 
   postInstall = "chmod +x $out/lib/datefudge/datefudge.so";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fake the system date";
     longDescription = ''
       datefudge is a small utility that pretends that the system time is
diff --git a/pkgs/tools/system/dcfldd/default.nix b/pkgs/tools/system/dcfldd/default.nix
index 9ea7b485b96b1..e5d5026e62909 100644
--- a/pkgs/tools/system/dcfldd/default.nix
+++ b/pkgs/tools/system/dcfldd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "dcfldd-1.3.4-1";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An enhanced version of GNU dd";
 
     homepage = "http://dcfldd.sourceforge.net/";
diff --git a/pkgs/tools/system/dd_rescue/default.nix b/pkgs/tools/system/dd_rescue/default.nix
index 9962337de078a..ba18c58becb9e 100644
--- a/pkgs/tools/system/dd_rescue/default.nix
+++ b/pkgs/tools/system/dd_rescue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf }:
+{ lib, stdenv, fetchurl, autoconf }:
 
 stdenv.mkDerivation rec {
   version = "1.99.8";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     cp "$out/share/dd_rescue"/dd_rhelp*/dd_rhelp "$out/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to copy data from a damaged block device";
     maintainers = with maintainers; [ raskin domenkozar ];
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/ddrescue/default.nix b/pkgs/tools/system/ddrescue/default.nix
index 8efcf22312fb6..7e96a4c01f7ce 100644
--- a/pkgs/tools/system/ddrescue/default.nix
+++ b/pkgs/tools/system/ddrescue/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl, lzip
 }:
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   doCheck = true; # not cross;
   configureFlags = [ "CXX=${stdenv.cc.targetPrefix}c++" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNU ddrescue, a data recovery tool";
 
     longDescription =
diff --git a/pkgs/tools/system/ddrutility/default.nix b/pkgs/tools/system/ddrutility/default.nix
index bb24076ce7c8c..02c89b2298907 100644
--- a/pkgs/tools/system/ddrutility/default.nix
+++ b/pkgs/tools/system/ddrutility/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "ddrutility";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A set of utilities for hard drive data rescue";
     homepage = "https://sourceforge.net/projects/ddrutility/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/system/di/default.nix b/pkgs/tools/system/di/default.nix
index 0a6ae26547bfd..fcf4054c18201 100644
--- a/pkgs/tools/system/di/default.nix
+++ b/pkgs/tools/system/di/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "di";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "INSTALL_DIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Disk information utility; displays everything 'df' does and more";
     homepage = "https://gentoo.com/di/";
     license = licenses.zlib;
diff --git a/pkgs/tools/system/disk-filltest/default.nix b/pkgs/tools/system/disk-filltest/default.nix
index 7bcf592012a48..ecfa14aa91be9 100644
--- a/pkgs/tools/system/disk-filltest/default.nix
+++ b/pkgs/tools/system/disk-filltest/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "disk-filltest";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/share/man; mv $out/man1 $out/share/man
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple program to detect bad disks by filling them with random data";
     longDescription = ''
       disk-filltest is a tool to check storage disks for coming
diff --git a/pkgs/tools/system/dog/default.nix b/pkgs/tools/system/dog/default.nix
index 5063e3555bb1d..94a6b34ff53ef 100644
--- a/pkgs/tools/system/dog/default.nix
+++ b/pkgs/tools/system/dog/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "dog-1.7";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     cp dog $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://lwn.net/Articles/421072/";
     description = "cat replacement";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/system/efibootmgr/default.nix b/pkgs/tools/system/efibootmgr/default.nix
index dd898de0fc26c..773127fa18781 100644
--- a/pkgs/tools/system/efibootmgr/default.nix
+++ b/pkgs/tools/system/efibootmgr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig, efivar, popt }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, pkgconfig, efivar, popt }:
 
 stdenv.mkDerivation rec {
   pname = "efibootmgr";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Linux user-space application to modify the Intel Extensible Firmware Interface (EFI) Boot Manager";
     homepage = "https://github.com/rhboot/efibootmgr";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/efivar/default.nix b/pkgs/tools/system/efivar/default.nix
index afff716c249a4..3300e0b275183 100644
--- a/pkgs/tools/system/efivar/default.nix
+++ b/pkgs/tools/system/efivar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPackages, fetchFromGitHub, fetchurl, pkgconfig, popt }:
+{ lib, stdenv, buildPackages, fetchFromGitHub, fetchurl, pkgconfig, popt }:
 
 stdenv.mkDerivation rec {
   pname = "efivar";
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     "PCDIR=$(dev)/lib/pkgconfig"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Tools and library to manipulate EFI variables";
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/envconsul/default.nix b/pkgs/tools/system/envconsul/default.nix
index 09175f14609f3..1706b32449eb9 100644
--- a/pkgs/tools/system/envconsul/default.nix
+++ b/pkgs/tools/system/envconsul/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "envconsul";
@@ -14,7 +14,7 @@ buildGoPackage rec {
     sha256 = "03cgxkyyynr067dg5b0lhvaxn60318fj9fh55p1n43vj5nrzgnbc";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/hashicorp/envconsul/";
     description = "Read and set environmental variables for processes from Consul";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/tools/system/evemu/default.nix b/pkgs/tools/system/evemu/default.nix
index 02f92a198909a..4bb5fce1875d1 100644
--- a/pkgs/tools/system/evemu/default.nix
+++ b/pkgs/tools/system/evemu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoreconfHook, pkgconfig, pythonPackages
+{ lib, stdenv, fetchgit, autoreconfHook, pkgconfig, pythonPackages
 , libevdev
 }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pythonPackages.python pythonPackages.evdev libevdev ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Records and replays device descriptions and events to emulate input devices through the kernel's input system";
     homepage = "https://www.freedesktop.org/wiki/Evemu/";
     repositories.git = "git://git.freedesktop.org/git/evemu";
diff --git a/pkgs/tools/system/facter/default.nix b/pkgs/tools/system/facter/default.nix
index d1a7f742974f0..a67b975ec92ca 100644
--- a/pkgs/tools/system/facter/default.nix
+++ b/pkgs/tools/system/facter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, cmake, cpp-hocon, curl, leatherman, libwhereami, libyamlcpp, openssl, ruby, util-linux }:
+{ lib, stdenv, fetchFromGitHub, boost, cmake, cpp-hocon, curl, leatherman, libwhereami, libyamlcpp, openssl, ruby, util-linux }:
 
 stdenv.mkDerivation rec {
   pname = "facter";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ boost cpp-hocon curl leatherman libwhereami libyamlcpp openssl ruby util-linux ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/puppetlabs/facter";
     description = "A system inventory tool";
     license = licenses.asl20;
diff --git a/pkgs/tools/system/fakechroot/default.nix b/pkgs/tools/system/fakechroot/default.nix
index fc74644ab0323..fb56350aa72f5 100644
--- a/pkgs/tools/system/fakechroot/default.nix
+++ b/pkgs/tools/system/fakechroot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, perl }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch, autoreconfHook, perl }:
 
 stdenv.mkDerivation rec {
   pname = "fakechroot";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   buildInputs = [ perl ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/dex4er/fakechroot";
     description = "Give a fake chroot environment through LD_PRELOAD";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/system/fcron/default.nix b/pkgs/tools/system/fcron/default.nix
index 59daac89bd440..d6f764b9ea6ae 100644
--- a/pkgs/tools/system/fcron/default.nix
+++ b/pkgs/tools/system/fcron/default.nix
@@ -1,7 +1,7 @@
 # restart using 'killall -TERM fcron; fcron -b
 # use convert-fcrontab to update fcrontab files
 
-{ stdenv, fetchurl, perl, busybox, vim }:
+{ lib, stdenv, fetchurl, perl, busybox, vim }:
 
 stdenv.mkDerivation rec {
   pname = "fcron";
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     find -type f | xargs sed -i -e 's@^\(\s\)*chown@\1:@' -e 's@^\(\s\)*chgrp@\1:@'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description="A command scheduler with extended capabilities over cron and anacron";
     homepage = "http://fcron.free.fr";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/fio/default.nix b/pkgs/tools/system/fio/default.nix
index e0dc69de0e431..6efa107ef321a 100644
--- a/pkgs/tools/system/fio/default.nix
+++ b/pkgs/tools/system/fio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper
+{ lib, stdenv, fetchFromGitHub, makeWrapper
 , libaio, python, zlib
 , withGnuplot ? false, gnuplot ? null }:
 
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ gnuplot ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Flexible IO Tester - an IO benchmark tool";
     homepage = "https://git.kernel.dk/cgit/fio/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/foremost/default.nix b/pkgs/tools/system/foremost/default.nix
index 96c54513ef1b1..24f207e95f149 100644
--- a/pkgs/tools/system/foremost/default.nix
+++ b/pkgs/tools/system/foremost/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "foremost";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/{bin,share/man/man8}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Recover files based on their contents";
     longDescription = ''
       Foremost is a console program to recover files based on their headers,
diff --git a/pkgs/tools/system/gdmap/default.nix b/pkgs/tools/system/gdmap/default.nix
index 6fdfd6e719096..da1925152bf40 100644
--- a/pkgs/tools/system/gdmap/default.nix
+++ b/pkgs/tools/system/gdmap/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk2, pkgconfig, libxml2, intltool, gettext }:
+{ lib, stdenv, fetchurl, gtk2, pkgconfig, libxml2, intltool, gettext }:
 
 stdenv.mkDerivation rec {
   name = "gdmap-0.8.1";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   NIX_LDFLAGS = "-lm";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://gdmap.sourceforge.net";
     description = "Recursive rectangle map of disk usage";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/gdu/default.nix b/pkgs/tools/system/gdu/default.nix
index a0b4177264470..db7275da7df28 100644
--- a/pkgs/tools/system/gdu/default.nix
+++ b/pkgs/tools/system/gdu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 }:
@@ -18,7 +18,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.AppVersion=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Disk usage analyzer with console interface";
     longDescription = ''
       Gdu is intended primarily for SSD disks where it can fully
diff --git a/pkgs/tools/system/gotop/default.nix b/pkgs/tools/system/gotop/default.nix
index f5d7ff4759e7e..b49307f500f63 100644
--- a/pkgs/tools/system/gotop/default.nix
+++ b/pkgs/tools/system/gotop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "gotop";
@@ -18,7 +18,7 @@ buildGoModule rec {
     export HOME=$(mktemp -d)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A terminal based graphical activity monitor inspired by gtop and vtop";
     homepage = "https://github.com/xxxserxxx/gotop";
     license = licenses.agpl3;
diff --git a/pkgs/tools/system/gptfdisk/default.nix b/pkgs/tools/system/gptfdisk/default.nix
index 613f63c3f0441..5e2f047674e9f 100644
--- a/pkgs/tools/system/gptfdisk/default.nix
+++ b/pkgs/tools/system/gptfdisk/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, libuuid, popt, icu, ncurses }:
+{ fetchurl, lib, stdenv, libuuid, popt, icu, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "gptfdisk";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Set of text-mode partitioning tools for Globally Unique Identifier (GUID) Partition Table (GPT) disks";
     license = licenses.gpl2;
     homepage = "https://www.rodsbooks.com/gdisk/";
diff --git a/pkgs/tools/system/hardinfo/default.nix b/pkgs/tools/system/hardinfo/default.nix
index fd8fb08cf2938..2dd1d96ee6482 100644
--- a/pkgs/tools/system/hardinfo/default.nix
+++ b/pkgs/tools/system/hardinfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which, pkgconfig, gtk2, pcre, glib, libxml2
+{ lib, stdenv, fetchurl, which, pkgconfig, gtk2, pcre, glib, libxml2
 , libsoup ? null
 }:
 
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
     rmdir "$out/usr"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://hardinfo.org/";
     description = "Display information about your hardware and operating system";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/hardlink/default.nix b/pkgs/tools/system/hardlink/default.nix
index c0c6aa72d3ba2..a790c600a9d33 100644
--- a/pkgs/tools/system/hardlink/default.nix
+++ b/pkgs/tools/system/hardlink/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pcre2 }:
+{ lib, stdenv, fetchurl, pcre2 }:
 
 
 stdenv.mkDerivation {
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
     cp -f hardlink.1 $out/share/man/man1/hardlink.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Consolidate duplicate files via hardlinks";
     homepage = "https://pagure.io/hardlink";
     repositories.git = "https://src.fedoraproject.org/cgit/rpms/hardlink.git";
diff --git a/pkgs/tools/system/honcho/default.nix b/pkgs/tools/system/honcho/default.nix
index eb96c3f46132a..f39c7dd793c47 100644
--- a/pkgs/tools/system/honcho/default.nix
+++ b/pkgs/tools/system/honcho/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 let
   inherit (pythonPackages) python;
@@ -40,7 +40,7 @@ pythonPackages.buildPythonApplication rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Python clone of Foreman, a tool for managing Procfile-based applications";
     license = licenses.mit;
     homepage = "https://github.com/nickstenning/honcho";
diff --git a/pkgs/tools/system/htop/default.nix b/pkgs/tools/system/htop/default.nix
index bf811942c3e61..02a3c7991d20f 100644
--- a/pkgs/tools/system/htop/default.nix
+++ b/pkgs/tools/system/htop/default.nix
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ ncurses
   ] ++ lib.optionals stdenv.isDarwin [ IOKit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interactive process viewer for Linux";
     homepage = "https://htop.dev";
     license = licenses.gpl2Only;
diff --git a/pkgs/tools/system/hwinfo/default.nix b/pkgs/tools/system/hwinfo/default.nix
index 7a212f5bbeeb5..925b60d54346e 100644
--- a/pkgs/tools/system/hwinfo/default.nix
+++ b/pkgs/tools/system/hwinfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libx86emu, flex, perl, libuuid }:
+{ lib, stdenv, fetchFromGitHub, libx86emu, flex, perl, libuuid }:
 
 stdenv.mkDerivation rec {
   pname = "hwinfo";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "DESTDIR=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Hardware detection tool from openSUSE";
     license = licenses.gpl2;
     homepage = "https://github.com/openSUSE/hwinfo";
diff --git a/pkgs/tools/system/incron/default.nix b/pkgs/tools/system/incron/default.nix
index d407982bb6738..2df4acba9b583 100644
--- a/pkgs/tools/system/incron/default.nix
+++ b/pkgs/tools/system/incron/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bash }:
+{ lib, stdenv, fetchFromGitHub, bash }:
 
 stdenv.mkDerivation rec {
   name = "incron-0.5.12";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     cp incrond incrontab $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cron-like daemon which handles filesystem events";
     homepage = "https://github.com/ar-/incron";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/inxi/default.nix b/pkgs/tools/system/inxi/default.nix
index 5efdc5381747f..1b1aaf00b378d 100644
--- a/pkgs/tools/system/inxi/default.nix
+++ b/pkgs/tools/system/inxi/default.nix
@@ -43,7 +43,7 @@ in stdenv.mkDerivation rec {
     cp inxi.1 $out/share/man/man1/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A full featured CLI system information tool";
     longDescription = ''
       inxi is a command line system information script built for console and
diff --git a/pkgs/tools/system/ioping/default.nix b/pkgs/tools/system/ioping/default.nix
index 7b65739c1a8d9..9af290503f494 100644
--- a/pkgs/tools/system/ioping/default.nix
+++ b/pkgs/tools/system/ioping/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "ioping";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Disk I/O latency measuring tool";
     maintainers = with maintainers; [ raskin ];
     platforms = platforms.unix;
diff --git a/pkgs/tools/system/iops/default.nix b/pkgs/tools/system/iops/default.nix
index cf34cb115f142..b2be488673eb7 100644
--- a/pkgs/tools/system/iops/default.nix
+++ b/pkgs/tools/system/iops/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "iops";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     cp iops $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Measure I/O operations per second of a storage device";
     longDescription = ''
       Iops lets you measure how many I/O operations per second a storage device can perform.
diff --git a/pkgs/tools/system/ior/default.nix b/pkgs/tools/system/ior/default.nix
index eff85589a1eb8..330bf35e55356 100644
--- a/pkgs/tools/system/ior/default.nix
+++ b/pkgs/tools/system/ior/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, openmpi, perl, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, openmpi, perl, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "ior";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ior.readthedocs.io/en/latest/";
     description = "Parallel file system I/O performance test";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/ipmiutil/default.nix b/pkgs/tools/system/ipmiutil/default.nix
index 17c28b3cd420e..4efc8024cc4ae 100644
--- a/pkgs/tools/system/ipmiutil/default.nix
+++ b/pkgs/tools/system/ipmiutil/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl }:
+{ lib, stdenv, fetchurl, openssl }:
 
 stdenv.mkDerivation rec {
   baseName = "ipmiutil";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-fno-stack-protector";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An easy-to-use IPMI server management utility";
     homepage = "http://ipmiutil.sourceforge.net/";
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/tools/system/java-service-wrapper/default.nix b/pkgs/tools/system/java-service-wrapper/default.nix
index 758942c05494b..8c87f64d7454f 100644
--- a/pkgs/tools/system/java-service-wrapper/default.nix
+++ b/pkgs/tools/system/java-service-wrapper/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , jdk
 , ant, cunit, ncurses
 }:
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     cp lib/libwrapper.so $out/lib/libwrapper.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Enables a Java Application to be run as a Windows Service or Unix Daemon";
     homepage = "https://wrapper.tanukisoftware.com/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/journalwatch/default.nix b/pkgs/tools/system/journalwatch/default.nix
index b41196b85c914..0ec7ef36623e9 100644
--- a/pkgs/tools/system/journalwatch/default.nix
+++ b/pkgs/tools/system/journalwatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder, systemd, pytest }:
+{ lib, stdenv, buildPythonPackage, fetchFromGitHub, pythonOlder, systemd, pytest }:
 
 buildPythonPackage rec {
   pname = "journalwatch";
@@ -30,7 +30,7 @@ buildPythonPackage rec {
   ];
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "journalwatch is a tool to find error messages in the systemd journal.";
     homepage = "https://github.com/The-Compiler/journalwatch";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/system/ledmon/default.nix b/pkgs/tools/system/ledmon/default.nix
index 6775a4711261a..ee9ba6c734669 100644
--- a/pkgs/tools/system/ledmon/default.nix
+++ b/pkgs/tools/system/ledmon/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl, udev, sg3_utils }:
+{ lib, stdenv, fetchFromGitHub, perl, udev, sg3_utils }:
 
 stdenv.mkDerivation rec {
   pname = "ledmon";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     "LEDMON_INSTDIR=${placeholder "out"}/sbin"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/intel/ledmon";
     description = "Enclosure LED Utilities";
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/loadwatch/default.nix b/pkgs/tools/system/loadwatch/default.nix
index eb7f1e3bb59bc..d7abc87677491 100644
--- a/pkgs/tools/system/loadwatch/default.nix
+++ b/pkgs/tools/system/loadwatch/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, ... }:
+{ lib, stdenv, fetchgit, ... }:
 
 stdenv.mkDerivation {
   name = "loadwatch-1.1-1-g6d2544c";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
     mkdir -p $out/bin
     install loadwatch lw-ctl $out/bin
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Run a program using only idle cycles";
     license = licenses.gpl2;
     maintainers = with maintainers; [ woffs ];
diff --git a/pkgs/tools/system/localtime/default.nix b/pkgs/tools/system/localtime/default.nix
index 805a70c74e9e7..99e0674016b61 100644
--- a/pkgs/tools/system/localtime/default.nix
+++ b/pkgs/tools/system/localtime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, buildGoPackage, m4 }:
+{ lib, stdenv, fetchFromGitHub, buildGoPackage, m4 }:
 
 buildGoPackage rec {
   name = "localtime-2017-11-07";
@@ -28,7 +28,7 @@ buildGoPackage rec {
     make install $makeFlags
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A daemon for keeping the system timezone up-to-date based on the current location";
     homepage = "https://github.com/Stebalien/localtime";
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/logcheck/default.nix b/pkgs/tools/system/logcheck/default.nix
index 71edfde9a0b3a..bdf2a4bcd3022 100644
--- a/pkgs/tools/system/logcheck/default.nix
+++ b/pkgs/tools/system/logcheck/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, lockfileProgs, perlPackages }:
+{ lib, stdenv, fetchurl, lockfileProgs, perlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "logcheck";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     "SHAREDIR=share/logtail/detectrotate"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Mails anomalies in the system logfiles to the administrator";
     longDescription = ''
       Mails anomalies in the system logfiles to the administrator.
diff --git a/pkgs/tools/system/lr/default.nix b/pkgs/tools/system/lr/default.nix
index 8d2febbeb8afb..43d37569ba310 100644
--- a/pkgs/tools/system/lr/default.nix
+++ b/pkgs/tools/system/lr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "lr";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/chneukirchen/lr";
     description = "List files recursively";
     license = licenses.mit;
diff --git a/pkgs/tools/system/lshw/default.nix b/pkgs/tools/system/lshw/default.nix
index 3d1a6ace08e4a..18fe6ca43b153 100644
--- a/pkgs/tools/system/lshw/default.nix
+++ b/pkgs/tools/system/lshw/default.nix
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://ezix.org/project/wiki/HardwareLiSter";
     description = "Provide detailed information on the hardware configuration of the machine";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/memtester/default.nix b/pkgs/tools/system/memtester/default.nix
index 870d7e0dd1dba..276d4f446cfa9 100644
--- a/pkgs/tools/system/memtester/default.nix
+++ b/pkgs/tools/system/memtester/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "memtester";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "INSTALLPATH=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A userspace utility for testing the memory subsystem for faults";
     homepage = "http://pyropus.ca/software/memtester/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/mlc/default.nix b/pkgs/tools/system/mlc/default.nix
index d055c98e04cbe..257cd31c0606d 100644
--- a/pkgs/tools/system/mlc/default.nix
+++ b/pkgs/tools/system/mlc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, patchelf }:
+{ lib, stdenv, fetchurl, patchelf }:
 stdenv.mkDerivation rec {
   pname = "mlc";
   version = "3.9";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" $out/bin/mlc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://software.intel.com/content/www/us/en/develop/articles/intelr-memory-latency-checker.html";
     description = "Intel Memory Latency Checker";
     license = licenses.unfree;
diff --git a/pkgs/tools/system/nvtop/default.nix b/pkgs/tools/system/nvtop/default.nix
index 1b826e6fab4f5..fdbfeb1c31f31 100644
--- a/pkgs/tools/system/nvtop/default.nix
+++ b/pkgs/tools/system/nvtop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, cudatoolkit, ncurses, addOpenGLRunpath }:
+{ lib, stdenv, fetchFromGitHub, cmake, cudatoolkit, ncurses, addOpenGLRunpath }:
 
 stdenv.mkDerivation rec {
   pname = "nvtop";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     addOpenGLRunpath $out/bin/nvtop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A (h)top like task monitor for NVIDIA GPUs";
     homepage = "https://github.com/Syllo/nvtop";
     license = licenses.gpl3;
diff --git a/pkgs/tools/system/opencl-info/default.nix b/pkgs/tools/system/opencl-info/default.nix
index 34295c90ae435..d5fd86f231ab9 100644
--- a/pkgs/tools/system/opencl-info/default.nix
+++ b/pkgs/tools/system/opencl-info/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, opencl-clhpp, ocl-icd }:
+{ lib, stdenv, fetchFromGitHub, opencl-clhpp, ocl-icd }:
 
 stdenv.mkDerivation {
   name = "opencl-info-2014-02-21";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
     install -Dm755 opencl-info $out/bin/opencl-info
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool to dump OpenCL platform/device information";
     homepage = "https://github.com/marchv/opencl-info";
     license = licenses.mit;
diff --git a/pkgs/tools/system/pciutils/default.nix b/pkgs/tools/system/pciutils/default.nix
index c062e1f3bd086..226f55f00dcc6 100644
--- a/pkgs/tools/system/pciutils/default.nix
+++ b/pkgs/tools/system/pciutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, zlib, kmod, which
+{ lib, stdenv, fetchurl, pkgconfig, zlib, kmod, which
 , static ? stdenv.hostPlatform.isStatic
 , darwin ? null
 }:
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
   # Get rid of update-pciids as it won't work.
   postInstall = "rm $out/sbin/update-pciids $out/man/man8/update-pciids.8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://mj.ucw.cz/pciutils.html";
     description = "A collection of programs for inspecting and manipulating configuration of PCI devices";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/system/pcstat/default.nix b/pkgs/tools/system/pcstat/default.nix
index 436fa5cae6fcd..9e0f6fe147e64 100644
--- a/pkgs/tools/system/pcstat/default.nix
+++ b/pkgs/tools/system/pcstat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage {
   pname = "pcstat-unstable";
@@ -15,7 +15,7 @@ buildGoPackage {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Page Cache stat: get page cache stats for files on Linux";
     homepage = "https://github.com/tobert/pcstat";
     license = licenses.asl20;
diff --git a/pkgs/tools/system/plan9port/default.nix b/pkgs/tools/system/plan9port/default.nix
index 8164dfa9136da..c7c2ff60a7d9d 100644
--- a/pkgs/tools/system/plan9port/default.nix
+++ b/pkgs/tools/system/plan9port/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, which
+{ lib, stdenv, fetchFromGitHub, which
 , darwin ? null
 , xorgproto ? null
 , libX11
@@ -79,7 +79,7 @@ stdenv.mkDerivation {
     ./test
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://9fans.github.io/plan9port/";
     description = "Plan 9 from User Space";
     longDescription = ''
diff --git a/pkgs/tools/system/proot/default.nix b/pkgs/tools/system/proot/default.nix
index 06147df093e65..e1871eeb7336d 100644
--- a/pkgs/tools/system/proot/default.nix
+++ b/pkgs/tools/system/proot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , talloc, docutils, swig, python, coreutils, enablePython ? true }:
 
 stdenv.mkDerivation {
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
     install -Dm644 doc/proot/man.1 $out/share/man/man1/proot.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://proot-me.github.io";
     description = "User-space implementation of chroot, mount --bind and binfmt_misc";
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/ps_mem/default.nix b/pkgs/tools/system/ps_mem/default.nix
index 45a33a1adb7bb..dcca1a86da74c 100644
--- a/pkgs/tools/system/ps_mem/default.nix
+++ b/pkgs/tools/system/ps_mem/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pythonPackages, fetchFromGitHub }:
+{ lib, stdenv, pythonPackages, fetchFromGitHub }:
 
 let
   version = "3.13";
@@ -13,7 +13,7 @@ in pythonPackages.buildPythonApplication {
     sha256 = "0pgi9hvwfbkzvwicqlkwx4rwal1ikza018yxbwpnf7c80zw0zaw9";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility to accurately report the in core memory usage for a program";
     homepage = "https://github.com/pixelb/ps_mem";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/system/psstop/default.nix b/pkgs/tools/system/psstop/default.nix
index 3a5ee2b058133..dd2b30ada1231 100644
--- a/pkgs/tools/system/psstop/default.nix
+++ b/pkgs/tools/system/psstop/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, glib }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, glib }:
 
 stdenv.mkDerivation rec {
   pname = "psstop";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ glib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/clearlinux/psstop";
     description = "Show processes' memory usage by looking into pss"; # upstream summary
     license = licenses.gpl3;
diff --git a/pkgs/tools/system/rowhammer-test/default.nix b/pkgs/tools/system/rowhammer-test/default.nix
index 02462584c6508..e2d736477ee76 100644
--- a/pkgs/tools/system/rowhammer-test/default.nix
+++ b/pkgs/tools/system/rowhammer-test/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   name = "rowhammer-test-20150811";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp rowhammer_test double_sided_rowhammer $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Test DRAM for bit flips caused by the rowhammer problem";
     homepage = "https://github.com/google/rowhammer-test";
     license = licenses.asl20;
diff --git a/pkgs/tools/system/runit/default.nix b/pkgs/tools/system/runit/default.nix
index acca0acf3ef9c..977550837df61 100644
--- a/pkgs/tools/system/runit/default.nix
+++ b/pkgs/tools/system/runit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, darwin
+{ lib, stdenv, fetchurl, darwin
 
 # Build runit-init as a static binary
 , static ? false
@@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
     cp -r ../man $man/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "UNIX init scheme with service supervision";
     license = licenses.bsd3;
     homepage = "http://smarden.org/runit";
diff --git a/pkgs/tools/system/s-tui/default.nix b/pkgs/tools/system/s-tui/default.nix
index 1192a1762632d..51c47ab105070 100644
--- a/pkgs/tools/system/s-tui/default.nix
+++ b/pkgs/tools/system/s-tui/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonPackage rec {
   pname = "s-tui";
@@ -16,7 +16,7 @@ python3Packages.buildPythonPackage rec {
 
   LC_ALL = "en_US.UTF-8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://amanusk.github.io/s-tui/";
     description = "Stress-Terminal UI monitoring tool";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/safe-rm/default.nix b/pkgs/tools/system/safe-rm/default.nix
index c188f066d1804..c76a48ff8d590 100644
--- a/pkgs/tools/system/safe-rm/default.nix
+++ b/pkgs/tools/system/safe-rm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, perl, coreutils }:
+{ lib, stdenv, fetchgit, perl, coreutils }:
 
 stdenv.mkDerivation rec {
   pname = "safe-rm";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     pod2man safe-rm > $out/share/man/man1/safe-rm.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool intended to prevent the accidental deletion of important files";
     homepage = "https://launchpad.net/safe-rm";
     license = licenses.gpl3;
diff --git a/pkgs/tools/system/sg3_utils/default.nix b/pkgs/tools/system/sg3_utils/default.nix
index 45e3287511a35..d0084e1f4d8ae 100644
--- a/pkgs/tools/system/sg3_utils/default.nix
+++ b/pkgs/tools/system/sg3_utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "sg3_utils-1.45";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "0qasc3qm4i8swjfaywiwpgz76gdxqvm47qycxgmprbsjmxqwk1qb";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://sg.danny.cz/sg/";
     description = "Utilities that send SCSI commands to devices";
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/smartmontools/default.nix b/pkgs/tools/system/smartmontools/default.nix
index 5d9196fcc1634..093fd7b5bd503 100644
--- a/pkgs/tools/system/smartmontools/default.nix
+++ b/pkgs/tools/system/smartmontools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook
+{ lib, stdenv, fetchurl, autoreconfHook
 , mailutils, inetutils
 , IOKit ? null , ApplicationServices ? null }:
 
@@ -33,7 +33,7 @@ in stdenv.mkDerivation rec {
   buildInputs = [] ++ stdenv.lib.optionals stdenv.isDarwin [IOKit ApplicationServices];
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools for monitoring the health of hard drives";
     homepage    = "https://www.smartmontools.org/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/tools/system/snooze/default.nix b/pkgs/tools/system/snooze/default.nix
index fb1ceaf897b8b..750a0954d3fb5 100644
--- a/pkgs/tools/system/snooze/default.nix
+++ b/pkgs/tools/system/snooze/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 stdenv.mkDerivation rec {
   pname = "snooze";
   version = "0.4";
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
   };
   makeFlags = [ "DESTDIR=$(out)" "PREFIX=/" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for waiting until a particular time and then running a command";
     maintainers = with maintainers; [ kaction ];
     license = licenses.cc0;
diff --git a/pkgs/tools/system/stress-ng/default.nix b/pkgs/tools/system/stress-ng/default.nix
index 9939f9ea15428..f033b038267e0 100644
--- a/pkgs/tools/system/stress-ng/default.nix
+++ b/pkgs/tools/system/stress-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , attr, judy, keyutils, libaio, libapparmor, libbsd, libcap, libgcrypt, lksctp-tools, zlib
 }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
   # mystery, though. :-(
   enableParallelBuilding = (!stdenv.isi686);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Stress test a computer system";
     longDescription = ''
       stress-ng will stress test a computer system in various selectable ways. It
diff --git a/pkgs/tools/system/stress/default.nix b/pkgs/tools/system/stress/default.nix
index 1595e8347e154..2b9923eb571bd 100644
--- a/pkgs/tools/system/stress/default.nix
+++ b/pkgs/tools/system/stress/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "stress-1.0.4";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "0nw210jajk38m3y7h8s130ps2qsbz7j75wab07hi2r3hlz14yzh5";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple workload generator for POSIX systems. It imposes a configurable amount of CPU, memory, I/O, and disk stress on the system";
     license = licenses.gpl2;
     platforms = platforms.unix;
diff --git a/pkgs/tools/system/suid-chroot/default.nix b/pkgs/tools/system/suid-chroot/default.nix
index 9697748e056d2..e12b0d828619a 100644
--- a/pkgs/tools/system/suid-chroot/default.nix
+++ b/pkgs/tools/system/suid-chroot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "suid-chroot";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
     sed -i -e '/chmod u+s/d' Makefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Setuid-safe wrapper for chroot";
     license = licenses.gpl2Plus;
     platforms = with platforms; unix;
diff --git a/pkgs/tools/system/supervise/default.nix b/pkgs/tools/system/supervise/default.nix
index cbf96818f4864..2776d28fa38df 100644
--- a/pkgs/tools/system/supervise/default.nix
+++ b/pkgs/tools/system/supervise/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
 
@@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
     sha256 = "0jk6q2f67pfs18ah040lmsbvbrnjap7w04jjddsfn1j5bcrvs13x";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/catern/supervise";
     description = "A minimal unprivileged process supervisor making use of modern Linux features";
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/symlinks/default.nix b/pkgs/tools/system/symlinks/default.nix
index 93a6bbf0c75b4..ad275a2d44793 100644
--- a/pkgs/tools/system/symlinks/default.nix
+++ b/pkgs/tools/system/symlinks/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv }:
+{ fetchurl, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   pname = "symlinks";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     cp symlinks.8 $out/share/man/man8
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Find and remedy problematic symbolic links on a system";
     homepage = "https://github.com/brandt/symlinks";
     license = licenses.mit;
diff --git a/pkgs/tools/system/syslog-ng-incubator/default.nix b/pkgs/tools/system/syslog-ng-incubator/default.nix
index 5d802dbed7e57..51d79d267dd70 100644
--- a/pkgs/tools/system/syslog-ng-incubator/default.nix
+++ b/pkgs/tools/system/syslog-ng-incubator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, glib, syslogng
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, glib, syslogng
 , eventlog, perl, python, yacc, protobufc, libivykis, libcap, czmq
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     "--with-module-dir=$(out)/lib/syslog-ng"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/balabit/syslog-ng-incubator";
     description = "A collection of tools and modules for syslog-ng";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/syslog-ng/default.nix b/pkgs/tools/system/syslog-ng/default.nix
index eeb2a99740ee8..527e82e8cf152 100644
--- a/pkgs/tools/system/syslog-ng/default.nix
+++ b/pkgs/tools/system/syslog-ng/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, openssl, libcap, curl, which
+{ lib, stdenv, fetchurl, openssl, libcap, curl, which
 , eventlog, pkgconfig, glib, python, systemd, perl
 , riemann_c_client, protobufc, pcre, libnet
 , json_c, libuuid, libivykis, mongoc, rabbitmq-c
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.syslog-ng.com";
     description = "Next-generation syslogd with advanced networking and filtering capabilities";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/systemd-journal2gelf/default.nix b/pkgs/tools/system/systemd-journal2gelf/default.nix
index d10cbb197c50b..7ac5d7cf210f8 100644
--- a/pkgs/tools/system/systemd-journal2gelf/default.nix
+++ b/pkgs/tools/system/systemd-journal2gelf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "SystemdJournal2Gelf-unstable";
@@ -14,7 +14,7 @@ buildGoPackage rec {
 
   goPackagePath = "github.com/parse-nl/SystemdJournal2Gelf";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Export entries from systemd's journal and send them to a graylog server using gelf";
     license = licenses.bsd2;
     maintainers = with maintainers; [ fadenb fpletz ];
diff --git a/pkgs/tools/system/testdisk/default.nix b/pkgs/tools/system/testdisk/default.nix
index bbece24bf655a..032b206174471 100644
--- a/pkgs/tools/system/testdisk/default.nix
+++ b/pkgs/tools/system/testdisk/default.nix
@@ -1,5 +1,5 @@
 { mkDerivation
-, stdenv
+, lib, stdenv
 , fetchurl
 , ncurses
 , libuuid
@@ -43,7 +43,7 @@ assert enableQt -> qwt != null;
 
   NIX_CFLAGS_COMPILE="-Wno-unused";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.cgsecurity.org/wiki/Main_Page";
     downloadPage = "https://www.cgsecurity.org/wiki/TestDisk_Download";
     description = "Data recovery utilities";
diff --git a/pkgs/tools/system/thermald/default.nix b/pkgs/tools/system/thermald/default.nix
index 4c076db7b8c07..16259f3b9ff04 100644
--- a/pkgs/tools/system/thermald/default.nix
+++ b/pkgs/tools/system/thermald/default.nix
@@ -12,7 +12,7 @@
 , libxml2
 , lzma
 , pkgconfig
-, stdenv
+, lib, stdenv
 , upower
 }:
 
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     cp ./data/thermal-conf.xml $out/etc/thermald/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Thermal Daemon";
     homepage = "https://01.org/linux-thermal-daemon";
     changelog = "https://github.com/intel/thermal_daemon/blob/master/README.txt";
diff --git a/pkgs/tools/system/thinkfan/default.nix b/pkgs/tools/system/thinkfan/default.nix
index bf594b6b9cd18..48d5d5fc08bea 100644
--- a/pkgs/tools/system/thinkfan/default.nix
+++ b/pkgs/tools/system/thinkfan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libyamlcpp, pkgconfig
+{ lib, stdenv, fetchFromGitHub, cmake, libyamlcpp, pkgconfig
 , smartSupport ? false, libatasmart }:
 
 stdenv.mkDerivation rec {
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "A minimalist fan control program";
     longDescription = "A minimalist fan control program. Originally designed
 specifically for IBM/Lenovo Thinkpads, it now supports any kind of system via
diff --git a/pkgs/tools/system/throttled/default.nix b/pkgs/tools/system/throttled/default.nix
index b19e4c471c003..d0458660c20f0 100644
--- a/pkgs/tools/system/throttled/default.nix
+++ b/pkgs/tools/system/throttled/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3Packages }:
+{ lib, stdenv, fetchFromGitHub, python3Packages }:
 
 stdenv.mkDerivation rec {
   pname = "throttled";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
 
   postFixup = ''wrapPythonPrograms'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fix for Intel CPU throttling issues";
     homepage = "https://github.com/erpalma/throttled";
     license = licenses.mit;
diff --git a/pkgs/tools/system/tm/default.nix b/pkgs/tools/system/tm/default.nix
index 390eae4de50a3..aa946c72ffc6b 100644
--- a/pkgs/tools/system/tm/default.nix
+++ b/pkgs/tools/system/tm/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
 
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     sha256 = "3b389bc03b6964ad5ffa57a344b891fdbcf7c9b2604adda723a863f83657c4a0";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://vicerveza.homeunix.net/~viric/soft/tm";
     description = "Terminal mixer - multiplexer for the i/o of terminal applications";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/tre-command/default.nix b/pkgs/tools/system/tre-command/default.nix
index c3241a04587b8..5a2ad41c74471 100644
--- a/pkgs/tools/system/tre-command/default.nix
+++ b/pkgs/tools/system/tre-command/default.nix
@@ -1,4 +1,4 @@
-{ rustPlatform, fetchFromGitHub, stdenv, installShellFiles }:
+{ rustPlatform, fetchFromGitHub, lib, stdenv, installShellFiles }:
 
 rustPlatform.buildRustPackage rec {
   pname = "tre-command";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
     installManPage manual/tre.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tree command, improved";
     homepage = "https://github.com/dduan/tre";
     license = licenses.mit;
diff --git a/pkgs/tools/system/ts/default.nix b/pkgs/tools/system/ts/default.nix
index 4046b36381121..b954b1adc01fc 100644
--- a/pkgs/tools/system/ts/default.nix
+++ b/pkgs/tools/system/ts/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , sendmailPath ? "/run/wrappers/bin/sendmail"
 }:
 
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     sha256 = "15dkzczx10fhl0zs9bmcgkxfbwq2znc7bpscljm4rchbzx7y6lsg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://vicerveza.homeunix.net/~viric/soft/ts";
     description = "Task spooler - batch queue";
     license = licenses.gpl2;
diff --git a/pkgs/tools/system/tuptime/default.nix b/pkgs/tools/system/tuptime/default.nix
index 213a79fe2700a..c0c0ef1b2138e 100644
--- a/pkgs/tools/system/tuptime/default.nix
+++ b/pkgs/tools/system/tuptime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , makeWrapper, installShellFiles
 , python3, sqlite }:
 
@@ -34,7 +34,7 @@ stdenv.mkDerivation rec {
       --prefix PATH : "${stdenv.lib.makeBinPath [ sqlite ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Total uptime & downtime statistics utility";
     homepage = "https://github.com/rfrail3/tuptime";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/system/uptimed/default.nix b/pkgs/tools/system/uptimed/default.nix
index e9224977542fc..0e427a66b2613 100644
--- a/pkgs/tools/system/uptimed/default.nix
+++ b/pkgs/tools/system/uptimed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
 
 stdenv.mkDerivation rec {
   pname = "uptimed";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook ];
   patches = [ ./no-var-spool-install.patch ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Uptime record daemon";
     longDescription = ''
       An uptime record daemon keeping track of the highest uptimes a computer
diff --git a/pkgs/tools/system/vbetool/default.nix b/pkgs/tools/system/vbetool/default.nix
index dc2ec24e594aa..ed0cf5f13c64a 100644
--- a/pkgs/tools/system/vbetool/default.nix
+++ b/pkgs/tools/system/vbetool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pciutils, libx86, zlib }:
+{ lib, stdenv, fetchurl, pciutils, libx86, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "vbetool";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "LDFLAGS=-lpci" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Video BIOS execution tool";
     homepage = "http://www.codon.org.uk/~mjg59/vbetool/";
     maintainers = [ maintainers.raskin ];
diff --git a/pkgs/tools/system/vboot_reference/default.nix b/pkgs/tools/system/vboot_reference/default.nix
index 1391a2a5ed236..13a1fd37d9c34 100644
--- a/pkgs/tools/system/vboot_reference/default.nix
+++ b/pkgs/tools/system/vboot_reference/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitiles, pkgconfig, libuuid, openssl, libyaml, lzma }:
+{ lib, stdenv, fetchFromGitiles, pkgconfig, libuuid, openssl, libyaml, lzma }:
 
 stdenv.mkDerivation rec {
   version = "20180311";
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     cp -r tests/devkeys* $out/share/vboot/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Chrome OS partitioning and kernel signing tools";
     license = licenses.bsd3;
     platforms = platforms.linux;
diff --git a/pkgs/tools/system/which/default.nix b/pkgs/tools/system/which/default.nix
index 79a50e43ed8b3..f4c871d5af08a 100644
--- a/pkgs/tools/system/which/default.nix
+++ b/pkgs/tools/system/which/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "which-2.21";
@@ -8,7 +8,7 @@ stdenv.mkDerivation rec {
     sha256 = "1bgafvy3ypbhhfznwjv1lxmd6mci3x1byilnnkc7gcr486wlb8pl";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/which/";
     description = "Shows the full path of (shell) commands";
     platforms = platforms.all;
diff --git a/pkgs/tools/system/wsmancli/default.nix b/pkgs/tools/system/wsmancli/default.nix
index 79fb92d5bb2a4..a0b7fae4d2aa1 100644
--- a/pkgs/tools/system/wsmancli/default.nix
+++ b/pkgs/tools/system/wsmancli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig
 , openssl, openwsman }:
 
 stdenv.mkDerivation rec {
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     touch AUTHORS NEWS README
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Openwsman command-line client";
     longDescription = ''
       Openwsman provides a command-line tool, wsman, to perform basic
diff --git a/pkgs/tools/system/yeshup/default.nix b/pkgs/tools/system/yeshup/default.nix
index 3242eeaeebc57..113d17b09b537 100644
--- a/pkgs/tools/system/yeshup/default.nix
+++ b/pkgs/tools/system/yeshup/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "yeshup";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
     cp -v yeshup $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/RhysU/yeshup";
     platforms = platforms.linux;
     license = licenses.cc-by-sa-30; # From Stackoverflow answer
diff --git a/pkgs/tools/system/zenith/default.nix b/pkgs/tools/system/zenith/default.nix
index 35498c4cb563c..430b4db257774 100644
--- a/pkgs/tools/system/zenith/default.nix
+++ b/pkgs/tools/system/zenith/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, rustPlatform, fetchFromGitHub, IOKit }:
+{ lib, stdenv, rustPlatform, fetchFromGitHub, IOKit }:
 
 rustPlatform.buildRustPackage rec {
   pname = "zenith";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ IOKit ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Sort of like top or htop but with zoom-able charts, network, and disk usage";
     homepage = "https://github.com/bvaisvil/zenith";
     license = licenses.mit;
diff --git a/pkgs/tools/text/a2ps/default.nix b/pkgs/tools/text/a2ps/default.nix
index c29060cb82fcf..978839ab1fde7 100644
--- a/pkgs/tools/text/a2ps/default.nix
+++ b/pkgs/tools/text/a2ps/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, autoconf, bison, libpaper, gperf, file, perl }:
+{ lib, stdenv, fetchurl, fetchpatch, autoconf, bison, libpaper, gperf, file, perl }:
 
 stdenv.mkDerivation rec {
   name = "a2ps-4.14";
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoconf file bison perl ];
   buildInputs = [ libpaper gperf ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An Anything to PostScript converter and pretty-printer";
     longDescription = ''
       GNU a2ps converts files into PostScript for printing or viewing. It uses a nice default format,
diff --git a/pkgs/tools/text/agrep/default.nix b/pkgs/tools/text/agrep/default.nix
index c0816f8ab76c5..c5028b2812883 100644
--- a/pkgs/tools/text/agrep/default.nix
+++ b/pkgs/tools/text/agrep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "agrep";
@@ -23,7 +23,7 @@ stdenv.mkDerivation {
 
   makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Approximate grep for fast fuzzy string searching";
     homepage = "https://www.tgries.de/agrep/";
     license = licenses.isc;
diff --git a/pkgs/tools/text/aha/default.nix b/pkgs/tools/text/aha/default.nix
index 1a6d65c52cd86..4ac07cef7eedc 100644
--- a/pkgs/tools/text/aha/default.nix
+++ b/pkgs/tools/text/aha/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   pname = "aha";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "ANSI HTML Adapter";
     longDescription = ''
       aha takes ANSI SGR-coloured input and produces W3C-conformant HTML code.
diff --git a/pkgs/tools/text/amber/default.nix b/pkgs/tools/text/amber/default.nix
index 205efc414d59e..0f7a0eb5f8464 100644
--- a/pkgs/tools/text/amber/default.nix
+++ b/pkgs/tools/text/amber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform
+{ lib, stdenv, fetchFromGitHub, rustPlatform
 , Security
 }:
 
@@ -17,7 +17,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A code search-and-replace tool";
     homepage = "https://github.com/dalance/amber";
     license = with licenses; [ mit ];
diff --git a/pkgs/tools/text/angle-grinder/default.nix b/pkgs/tools/text/angle-grinder/default.nix
index a8702553c4b3d..e04530b8110b9 100644
--- a/pkgs/tools/text/angle-grinder/default.nix
+++ b/pkgs/tools/text/angle-grinder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 }:
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "0y4c1gja0i3h2whjpm74yf3z1y85pkwmpmrl2fjsyy0mn493hzv8";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Slice and dice logs on the command line";
     homepage = "https://github.com/rcoh/angle-grinder";
     license = licenses.mit;
diff --git a/pkgs/tools/text/ansifilter/default.nix b/pkgs/tools/text/ansifilter/default.nix
index 8d79317ce344e..6928c959dfd38 100644
--- a/pkgs/tools/text/ansifilter/default.nix
+++ b/pkgs/tools/text/ansifilter/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, pkgconfig, boost, lua }:
+{ fetchurl, lib, stdenv, pkgconfig, boost, lua }:
 
 stdenv.mkDerivation rec {
   pname = "ansifilter";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     "conf_dir=/etc/ansifilter"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to convert ANSI to other formats";
     longDescription = ''
       Tool to remove ANSI or convert them to another format
diff --git a/pkgs/tools/text/ascii/default.nix b/pkgs/tools/text/ascii/default.nix
index 94ab5286f8c02..f596c8d330d2d 100644
--- a/pkgs/tools/text/ascii/default.nix
+++ b/pkgs/tools/text/ascii/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "ascii";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     mkdir -vp "$out/bin" "$out/share/man/man1"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interactive ASCII name and synonym chart";
     homepage = "http://www.catb.org/~esr/ascii/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/text/boxes/default.nix b/pkgs/tools/text/boxes/default.nix
index b9d54d3a9e77d..407b2c67a8f0a 100644
--- a/pkgs/tools/text/boxes/default.nix
+++ b/pkgs/tools/text/boxes/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, bison, flex }:
+{ lib, stdenv, fetchFromGitHub, bison, flex }:
 
 stdenv.mkDerivation rec {
   pname = "boxes";
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     install -Dm644 -t $out/share/man/man1 doc/boxes.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line ASCII boxes unlimited!";
     longDescription = ''
       Boxes is a command line filter program that draws ASCII art boxes around
diff --git a/pkgs/tools/text/catdoc/default.nix b/pkgs/tools/text/catdoc/default.nix
index 64ef092f36bee..61570a70b7d8d 100644
--- a/pkgs/tools/text/catdoc/default.nix
+++ b/pkgs/tools/text/catdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch }:
+{ lib, stdenv, fetchurl, fetchpatch }:
 
 stdenv.mkDerivation rec {
   pname = "catdoc";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   configureFlags = [ "--disable-wordview" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "MS-Word/Excel/PowerPoint to text converter";
     platforms = platforms.all;
     license = licenses.gpl2;
diff --git a/pkgs/tools/text/catdocx/default.nix b/pkgs/tools/text/catdocx/default.nix
index f24864f754b35..adf78397fcb3d 100644
--- a/pkgs/tools/text/catdocx/default.nix
+++ b/pkgs/tools/text/catdocx/default.nix
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     ln -s $out/libexec/catdocx.sh $out/bin/catdocx
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extracts plain text from docx files";
     homepage = "https://github.com/jncraton/catdocx";
     license = with licenses; [ bsd3 ];
diff --git a/pkgs/tools/text/cconv/default.nix b/pkgs/tools/text/cconv/default.nix
index 8fe400aaab255..de16854927b4f 100644
--- a/pkgs/tools/text/cconv/default.nix
+++ b/pkgs/tools/text/cconv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoreconfHook }:
+{ lib, stdenv, fetchurl, autoreconfHook }:
 let version = "0.6.3"; in
   stdenv.mkDerivation {
   pname = "cconv";
@@ -11,7 +11,7 @@ let version = "0.6.3"; in
 
   nativeBuildInputs = [ autoreconfHook ];
   
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A iconv based simplified-traditional chinese conversion tool";
     homepage = "https://github.com/xiaoyjy/cconv";
     license = licenses.mit;
diff --git a/pkgs/tools/text/chars/default.nix b/pkgs/tools/text/chars/default.nix
index fa58d110550ee..a65506154777c 100644
--- a/pkgs/tools/text/chars/default.nix
+++ b/pkgs/tools/text/chars/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , Security
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Commandline tool to display information about unicode characters";
     homepage = "https://github.com/antifuchs/chars";
     license = licenses.mit;
diff --git a/pkgs/tools/text/choose/default.nix b/pkgs/tools/text/choose/default.nix
index 26192732511f7..20d651df008e9 100644
--- a/pkgs/tools/text/choose/default.nix
+++ b/pkgs/tools/text/choose/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 }:
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
 
   cargoSha256 = "1p18926pfff1yayb2i28v0nz37j52hqqv7244yfrzgidi29kyvbc";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A human-friendly and fast alternative to cut and (sometimes) awk";
     homepage = "https://github.com/theryangeary/choose";
     license = licenses.gpl3;
diff --git a/pkgs/tools/text/cmigemo/default.nix b/pkgs/tools/text/cmigemo/default.nix
index c84299c68436e..6787d68991d3d 100644
--- a/pkgs/tools/text/cmigemo/default.nix
+++ b/pkgs/tools/text/cmigemo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, gzip, libiconv, nkf, perl, skk-dicts, which }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, gzip, libiconv, nkf, perl, skk-dicts, which }:
 
 stdenv.mkDerivation {
   pname = "cmigemo";
@@ -25,7 +25,7 @@ stdenv.mkDerivation {
 
   installTargets = [ (if stdenv.isDarwin then "osx-install" else "gcc-install") ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A tool that supports Japanese incremental search with Romaji";
     homepage = "https://www.kaoriya.net/software/cmigemo";
     license = licenses.mit;
diff --git a/pkgs/tools/text/colordiff/default.nix b/pkgs/tools/text/colordiff/default.nix
index c3da9a6055583..04d41b74db0f1 100644
--- a/pkgs/tools/text/colordiff/default.nix
+++ b/pkgs/tools/text/colordiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl /*, xmlto */}:
+{ lib, stdenv, fetchurl, perl /*, xmlto */}:
 
 stdenv.mkDerivation rec {
   name = "colordiff-1.0.19";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   installPhase = ''make INSTALL_DIR=/bin MAN_DIR=/share/man/man1 DESTDIR="$out" install'';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wrapper for 'diff' that produces the same output but with pretty 'syntax' highlighting";
     homepage = "https://www.colordiff.org/";
     license = licenses.gpl3;
diff --git a/pkgs/tools/text/coloursum/default.nix b/pkgs/tools/text/coloursum/default.nix
index 38f544496d5e4..0a87e9b3905c1 100644
--- a/pkgs/tools/text/coloursum/default.nix
+++ b/pkgs/tools/text/coloursum/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "coloursum";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Colourise your checksum output";
     homepage = "https://github.com/ticky/coloursum";
     license = licenses.mit;
diff --git a/pkgs/tools/text/copyright-update/default.nix b/pkgs/tools/text/copyright-update/default.nix
index ca815f915db35..e0318c20a0e69 100644
--- a/pkgs/tools/text/copyright-update/default.nix
+++ b/pkgs/tools/text/copyright-update/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perl }:
+{ lib, stdenv, fetchFromGitHub, perl }:
 
 stdenv.mkDerivation rec {
   pname = "copyright-update";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "INSTALL=install" "prefix=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jaalto/project--copyright-update";
     description = "Updates the copyright information in a set of files";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/text/dadadodo/default.nix b/pkgs/tools/text/dadadodo/default.nix
index 5de8e25e6fb2b..85e57546d9339 100644
--- a/pkgs/tools/text/dadadodo/default.nix
+++ b/pkgs/tools/text/dadadodo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "dadadodo";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Markov chain-based text generator";
     homepage = "http://www.jwz.org/dadadodo";
     maintainers = with maintainers; [ pSub ];
diff --git a/pkgs/tools/text/diffr/default.nix b/pkgs/tools/text/diffr/default.nix
index 4fa7814ad0004..e2dcf4122b1bb 100644
--- a/pkgs/tools/text/diffr/default.nix
+++ b/pkgs/tools/text/diffr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "diffr";
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
     export DIFFR_TESTS_BINARY_PATH=$releaseDir/diffr
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Yet another diff highlighting tool";
     homepage = "https://github.com/mookid/diffr";
     license = with licenses; [ mit ];
diff --git a/pkgs/tools/text/diffstat/default.nix b/pkgs/tools/text/diffstat/default.nix
index bed34e30e7902..b558386536e40 100644
--- a/pkgs/tools/text/diffstat/default.nix
+++ b/pkgs/tools/text/diffstat/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv }:
+{ fetchurl, lib, stdenv }:
 
 stdenv.mkDerivation rec {
   name = "diffstat-1.63";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
     sha256 = "0vyw200s5dv1257pmrh6c6fdkmw3slyz5szpqfx916xr04sdbpby";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Read output of diff and display a histogram of the changes";
     longDescription = ''
       diffstat reads the output of diff and displays a histogram of the
diff --git a/pkgs/tools/text/diffutils/default.nix b/pkgs/tools/text/diffutils/default.nix
index 6fd69a9ba4cc5..8fd36211e2ea3 100644
--- a/pkgs/tools/text/diffutils/default.nix
+++ b/pkgs/tools/text/diffutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xz, coreutils ? null }:
+{ lib, stdenv, fetchurl, xz, coreutils ? null }:
 
 # Note: this package is used for bootstrapping fetchurl, and thus
 # cannot use fetchpatch! All mutable patches (generated by GitHub or
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
     stdenv.lib.optional (coreutils != null) "PR_PROGRAM=${coreutils}/bin/pr"
     ++ stdenv.lib.optional (stdenv.buildPlatform != stdenv.hostPlatform) "gl_cv_func_getopt_gnu=yes";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/diffutils/diffutils.html";
     description = "Commands for showing the differences between files (diff, cmp, etc.)";
     license = licenses.gpl3;
diff --git a/pkgs/tools/text/discount/default.nix b/pkgs/tools/text/discount/default.nix
index a2c6ec8a9e088..264e944028e33 100644
--- a/pkgs/tools/text/discount/default.nix
+++ b/pkgs/tools/text/discount/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub }:
+{ lib, stdenv, fetchFromGitHub }:
 
 stdenv.mkDerivation rec {
   version = "2.2.7";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Implementation of Markdown markup language in C";
     homepage = "http://www.pell.portland.or.us/~orc/Code/discount/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/text/dos2unix/default.nix b/pkgs/tools/text/dos2unix/default.nix
index b85d33d887aad..e2e07e9e48847 100644
--- a/pkgs/tools/text/dos2unix/default.nix
+++ b/pkgs/tools/text/dos2unix/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, perl, gettext }:
+{lib, stdenv, fetchurl, perl, gettext }:
 
 stdenv.mkDerivation rec {
   pname = "dos2unix";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ perl gettext ];
   makeFlags = [ "prefix=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert text files with DOS or Mac line breaks to Unix line breaks and vice versa";
     homepage = "https://waterlan.home.xs4all.nl/dos2unix.html";
     changelog = "https://sourceforge.net/p/dos2unix/dos2unix/ci/dos2unix-${version}/tree/dos2unix/NEWS.txt?format=raw";
diff --git a/pkgs/tools/text/enca/default.nix b/pkgs/tools/text/enca/default.nix
index 6cfb4721066c5..6c23acb86b4b9 100644
--- a/pkgs/tools/text/enca/default.nix
+++ b/pkgs/tools/text/enca/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libiconv, recode }:
+{ lib, stdenv, fetchurl, libiconv, recode }:
 
 stdenv.mkDerivation rec {
   pname = "enca";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ recode libiconv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Detects the encoding of text files and reencodes them";
 
     longDescription = ''
diff --git a/pkgs/tools/text/epubcheck/default.nix b/pkgs/tools/text/epubcheck/default.nix
index b40769e552225..88ead40541f18 100644
--- a/pkgs/tools/text/epubcheck/default.nix
+++ b/pkgs/tools/text/epubcheck/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip
+{ lib, stdenv, fetchzip
 , jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
       --add-flags "-classpath $classpath com.adobe.epubcheck.tool.Checker"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/w3c/epubcheck";
     description = "Validation tool for EPUB";
     license = with licenses; [ asl20 bsd3 mpl10 w3c ];
diff --git a/pkgs/tools/text/esh/default.nix b/pkgs/tools/text/esh/default.nix
index 171d90026be82..a1d6db2a7c2d7 100644
--- a/pkgs/tools/text/esh/default.nix
+++ b/pkgs/tools/text/esh/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, asciidoctor, gawk, gnused, runtimeShell }:
+{ lib, stdenv, fetchFromGitHub, asciidoctor, gawk, gnused, runtimeShell }:
 
 stdenv.mkDerivation rec {
   pname = "esh";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
   doCheck = true;
   checkTarget = "test";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple templating engine based on shell";
     homepage = "https://github.com/jirutka/esh";
     license = licenses.mit;
diff --git a/pkgs/tools/text/fanficfare/default.nix b/pkgs/tools/text/fanficfare/default.nix
index 1dbe451436319..ad92ffa9350b8 100644
--- a/pkgs/tools/text/fanficfare/default.nix
+++ b/pkgs/tools/text/fanficfare/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages }:
+{ lib, stdenv, python3Packages }:
 
 python3Packages.buildPythonApplication rec {
   pname = "FanFicFare";
@@ -18,7 +18,7 @@ python3Packages.buildPythonApplication rec {
 
   doCheck = false; # no tests exist
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool for making eBooks from fanfiction web sites";
     homepage = "https://github.com/JimmXinu/FanFicFare";
     license = licenses.gpl3;
diff --git a/pkgs/tools/text/fastmod/default.nix b/pkgs/tools/text/fastmod/default.nix
index 023cc58f4a6b6..d2a865335c183 100644
--- a/pkgs/tools/text/fastmod/default.nix
+++ b/pkgs/tools/text/fastmod/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , Security
@@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility that makes sweeping changes to large, shared code bases";
     homepage = "https://github.com/facebookincubator/fastmod";
     license = licenses.asl20;
diff --git a/pkgs/tools/text/gawk/default.nix b/pkgs/tools/text/gawk/default.nix
index 73e2b8a6de49b..bcc66cf93dad1 100644
--- a/pkgs/tools/text/gawk/default.nix
+++ b/pkgs/tools/text/gawk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 # TODO: links -lsigsegv but loses the reference for some reason
 , withSigsegv ? (false && stdenv.hostPlatform.system != "x86_64-cygwin"), libsigsegv
 , interactive ? false, readline
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     libsigsegv = if withSigsegv then libsigsegv else null; # for stdenv bootstrap
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/gawk/";
     description = "GNU implementation of the Awk programming language";
 
@@ -81,4 +81,3 @@ stdenv.mkDerivation rec {
     maintainers = [ ];
   };
 }
-
diff --git a/pkgs/tools/text/gawk/gawkextlib.nix b/pkgs/tools/text/gawk/gawkextlib.nix
index e15b2d4e257dd..058712df40957 100644
--- a/pkgs/tools/text/gawk/gawkextlib.nix
+++ b/pkgs/tools/text/gawk/gawkextlib.nix
@@ -1,4 +1,4 @@
-{ stdenv, recurseIntoAttrs, fetchgit, writeText, pkgconfig, autoreconfHook
+{ lib, stdenv, recurseIntoAttrs, fetchgit, writeText, pkgconfig, autoreconfHook
 , autoconf, automake, libiconv, libtool, texinfo, gettext, gawk, rapidjson, gd
 , shapelib, libharu, lmdb, gmp, glibcLocales, mpfr, more, postgresql, hiredis
 , expat, tre, makeWrapper }:
@@ -40,7 +40,7 @@ let
         inherit doCheck;
         checkInputs = [ more ];
 
-        meta = with stdenv.lib; {
+        meta = with lib; {
           homepage = "https://sourceforge.net/projects/gawkextlib/";
           description = "Dynamically loaded extension libraries for GNU AWK";
           longDescription = ''
diff --git a/pkgs/tools/text/gjo/default.nix b/pkgs/tools/text/gjo/default.nix
index 28af709c30e01..27dcf633fe7a9 100644
--- a/pkgs/tools/text/gjo/default.nix
+++ b/pkgs/tools/text/gjo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , buildGoModule
 , fetchFromGitHub
 }:
@@ -16,7 +16,7 @@ buildGoModule rec {
 
   vendorSha256 = "0sjjj9z1dhilhpc8pq4154czrb79z9cm044jvn75kxcjv6v5l2m5";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Small utility to create JSON objects";
     homepage = "https://github.com/skanehira/gjo";
     license = licenses.mit;
diff --git a/pkgs/tools/text/glogg/default.nix b/pkgs/tools/text/glogg/default.nix
index dff7262bed2ba..ceddda11c0993 100644
--- a/pkgs/tools/text/glogg/default.nix
+++ b/pkgs/tools/text/glogg/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, qmake, boost }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, qmake, boost }:
 
 mkDerivation rec {
   pname = "glogg";
@@ -29,7 +29,7 @@ mkDerivation rec {
     wrapQtApp $out/Applications/glogg.app/Contents/MacOS/glogg
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The fast, smart log explorer";
     longDescription = ''
       A multi-platform GUI application to browse and search through long or complex log files. It is designed with programmers and system administrators in mind. glogg can be seen as a graphical, interactive combination of grep and less.
diff --git a/pkgs/tools/text/gnugrep/default.nix b/pkgs/tools/text/gnugrep/default.nix
index 08b588691e50a..42a9d913dd20d 100644
--- a/pkgs/tools/text/gnugrep/default.nix
+++ b/pkgs/tools/text/gnugrep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pcre, libiconv, perl }:
+{ lib, stdenv, fetchurl, pcre, libiconv, perl }:
 
 # Note: this package is used for bootstrapping fetchurl, and thus
 # cannot use fetchpatch! All mutable patches (generated by GitHub or
@@ -46,7 +46,7 @@ stdenv.mkDerivation {
       chmod +x $out/bin/egrep $out/bin/fgrep
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/grep/";
     description = "GNU implementation of the Unix grep command";
 
diff --git a/pkgs/tools/text/grip-search/default.nix b/pkgs/tools/text/grip-search/default.nix
index 921691a40afd8..34644e431d9cd 100644
--- a/pkgs/tools/text/grip-search/default.nix
+++ b/pkgs/tools/text/grip-search/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, pkgconfig, cmake, catch2 }:
+{ lib, stdenv, fetchFromGitHub, boost, pkgconfig, cmake, catch2 }:
 
 stdenv.mkDerivation rec {
   pname = "grip-search";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     substituteInPlace src/general/config.h --replace "CUSTOM-BUILD" "${version}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast, indexed regexp search over large file trees";
     homepage = "https://github.com/sc0ty/grip";
     license = licenses.gpl3;
diff --git a/pkgs/tools/text/groff/default.nix b/pkgs/tools/text/groff/default.nix
index 73c8ed6834235..d6f1c051de987 100644
--- a/pkgs/tools/text/groff/default.nix
+++ b/pkgs/tools/text/groff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl
+{ lib, stdenv, fetchurl, perl
 , ghostscript #for postscript and html output
 , psutils, netpbm #for html output
 , buildPackages
@@ -103,7 +103,7 @@ stdenv.mkDerivation rec {
     find $perl/ -type f -print0 | xargs --null sed -i 's|${buildPackages.perl}|${perl}|'
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.gnu.org/software/groff/";
     description = "GNU Troff, a typesetting package that reads plain text and produces formatted output";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/text/gtranslator/default.nix b/pkgs/tools/text/gtranslator/default.nix
index f091d867503b5..d8b2df1fc0bd1 100644
--- a/pkgs/tools/text/gtranslator/default.nix
+++ b/pkgs/tools/text/gtranslator/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GNOME translation making program";
     homepage = "https://wiki.gnome.org/Apps/Gtranslator";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/text/gucci/default.nix b/pkgs/tools/text/gucci/default.nix
index 1667f2e45b543..4e938787ff466 100644
--- a/pkgs/tools/text/gucci/default.nix
+++ b/pkgs/tools/text/gucci/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "gucci";
@@ -19,7 +19,7 @@ buildGoPackage rec {
     -ldflags=-X main.AppVersion=${version}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple CLI templating tool written in golang";
     homepage = "https://github.com/noqcks/gucci";
     license = licenses.mit;
diff --git a/pkgs/tools/text/highlight/default.nix b/pkgs/tools/text/highlight/default.nix
index e4e80e694fe13..62b449ff9c4f9 100644
--- a/pkgs/tools/text/highlight/default.nix
+++ b/pkgs/tools/text/highlight/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, getopt, lua, boost, pkgconfig, swig, perl, gcc }:
+{ lib, stdenv, fetchFromGitLab, getopt, lua, boost, pkgconfig, swig, perl, gcc }:
 
 with stdenv.lib;
 
@@ -45,7 +45,7 @@ let
       make -C extras/swig clean # Clean up intermediate files.
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Source code highlighting tool";
       homepage = "http://www.andre-simon.de/doku/highlight/en/highlight.php";
       platforms = platforms.unix;
diff --git a/pkgs/tools/text/html-tidy/default.nix b/pkgs/tools/text/html-tidy/default.nix
index 28e1759fea59c..15ee4c7564805 100644
--- a/pkgs/tools/text/html-tidy/default.nix
+++ b/pkgs/tools/text/html-tidy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libxslt }:
+{ lib, stdenv, fetchFromGitHub, cmake, libxslt }:
 
 stdenv.mkDerivation rec {
   pname = "html-tidy";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   # ATM bin/tidy is statically linked, as upstream provides no other option yet.
   # https://github.com/htacg/tidy-html5/issues/326#issuecomment-160322107
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A HTML validator and `tidier'";
     longDescription = ''
       HTML Tidy is a command-line tool and C library that can be
diff --git a/pkgs/tools/text/icdiff/default.nix b/pkgs/tools/text/icdiff/default.nix
index 15739432a19f3..07082c4c56f36 100644
--- a/pkgs/tools/text/icdiff/default.nix
+++ b/pkgs/tools/text/icdiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "icdiff";
@@ -11,7 +11,7 @@ pythonPackages.buildPythonApplication rec {
     sha256 = "080v8h09pv8qwplin4kwfm0kmqjwdqjfxbpcdrv16sv4hwfwl5qd";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.jefftk.com/icdiff";
     description = "Side-by-side highlighted command line diffs";
     maintainers = with maintainers; [ aneeshusa ];
diff --git a/pkgs/tools/text/invoice2data/default.nix b/pkgs/tools/text/invoice2data/default.nix
index 78ab971f0c0d3..2ed3005ee776b 100644
--- a/pkgs/tools/text/invoice2data/default.nix
+++ b/pkgs/tools/text/invoice2data/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3Packages, xpdf, imagemagick, tesseract }:
+{ lib, stdenv, python3Packages, xpdf, imagemagick, tesseract }:
 
 python3Packages.buildPythonPackage rec {
   pname = "invoice2data";
@@ -16,7 +16,7 @@ python3Packages.buildPythonPackage rec {
   # Tests fails even when ran manually on my ubuntu machine !!
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Data extractor for PDF invoices";
     homepage = "https://github.com/invoice-x/invoice2data";
     license = licenses.mit;
diff --git a/pkgs/tools/text/ispell/default.nix b/pkgs/tools/text/ispell/default.nix
index 2f61536ed2c00..9b78b8dad7c94 100644
--- a/pkgs/tools/text/ispell/default.nix
+++ b/pkgs/tools/text/ispell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, bison, ncurses }:
+{ lib, stdenv, fetchurl, bison, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "ispell";
@@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interactive spell-checking program for Unix";
     homepage = "https://www.cs.hmc.edu/~geoff/ispell.html";
     license = licenses.free;
diff --git a/pkgs/tools/text/jumanpp/default.nix b/pkgs/tools/text/jumanpp/default.nix
index 37d7577dfe6fa..f002e228ac5da 100644
--- a/pkgs/tools/text/jumanpp/default.nix
+++ b/pkgs/tools/text/jumanpp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, cmake, protobuf }:
+{ lib, stdenv, fetchurl, cmake, protobuf }:
 
 stdenv.mkDerivation rec {
   pname = "jumanpp";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ cmake ];
   buildInputs = [ protobuf ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Japanese morphological analyser using a recurrent neural network language model (RNNLM)";
     longDescription = ''
       JUMAN++ is a new morphological analyser that considers semantic
diff --git a/pkgs/tools/text/kakasi/default.nix b/pkgs/tools/text/kakasi/default.nix
index 6264557325999..79b26e6fb56dc 100644
--- a/pkgs/tools/text/kakasi/default.nix
+++ b/pkgs/tools/text/kakasi/default.nix
@@ -1,11 +1,11 @@
-{ stdenv, fetchurl, libiconv }:
+{ lib, stdenv, fetchurl, libiconv }:
 
 stdenv.mkDerivation rec {
   name = "kakasi-2.3.6";
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin [ libiconv ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Kanji Kana Simple Inverter";
     longDescription = ''
       KAKASI is the language processing filter to convert Kanji
diff --git a/pkgs/tools/text/kytea/default.nix b/pkgs/tools/text/kytea/default.nix
index b120d43287a57..8ef7b276a3836 100644
--- a/pkgs/tools/text/kytea/default.nix
+++ b/pkgs/tools/text/kytea/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
 
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = stdenv.lib.optionalString stdenv.cc.isClang "-Wno-error=c++11-narrowing";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.phontron.com/kytea/";
     description = "General toolkit developed for analyzing text";
 
diff --git a/pkgs/tools/text/languagetool/default.nix b/pkgs/tools/text/languagetool/default.nix
index 30029d2d4e979..a951285bd06b6 100644
--- a/pkgs/tools/text/languagetool/default.nix
+++ b/pkgs/tools/text/languagetool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jre, makeWrapper }:
+{ lib, stdenv, fetchzip, jre, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "LanguageTool";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
       --add-flags "-cp $out/share/languagetool-server.jar org.languagetool.server.HTTPServer"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://languagetool.org";
     license = licenses.lgpl21Plus;
     maintainers = with maintainers; [
diff --git a/pkgs/tools/text/link-grammar/default.nix b/pkgs/tools/text/link-grammar/default.nix
index 25a5d129c81b1..ce58f4dbd5847 100644
--- a/pkgs/tools/text/link-grammar/default.nix
+++ b/pkgs/tools/text/link-grammar/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, python3, sqlite, libedit, zlib }:
+{ lib, stdenv, fetchurl, pkgconfig, python3, sqlite, libedit, zlib }:
 
 stdenv.mkDerivation rec {
   version = "5.8.0";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     "--disable-java-bindings"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Grammar Checking library";
     homepage = "https://www.abisource.com/projects/link-grammar/";
     license = licenses.lgpl21;
diff --git a/pkgs/tools/text/lv/default.nix b/pkgs/tools/text/lv/default.nix
index 3e96858f9c9c4..48ed867c8e4c7 100644
--- a/pkgs/tools/text/lv/default.nix
+++ b/pkgs/tools/text/lv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ncurses }:
+{ lib, stdenv, fetchurl, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "lv";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful multi-lingual file viewer / grep";
     homepage = "https://web.archive.org/web/20160310122517/www.ff.iij4u.or.jp/~nrt/lv/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/text/markdown-pp/default.nix b/pkgs/tools/text/markdown-pp/default.nix
index eaaa0547964dc..55febe1172983 100644
--- a/pkgs/tools/text/markdown-pp/default.nix
+++ b/pkgs/tools/text/markdown-pp/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, pythonPackages, stdenv }:
+{ fetchFromGitHub, pythonPackages, lib, stdenv }:
 
 with pythonPackages;
 buildPythonApplication rec {
@@ -15,7 +15,7 @@ buildPythonApplication rec {
     rev = "v${version}";
     sha256 = "180i5wn9z6vdk2k2bh8345z3g80hj7zf5s2pq0h7k9vaxqpp7avc";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Preprocessor for Markdown files to generate a table of contents and other documentation needs";
     license = licenses.mit;
     homepage = "https://github.com/jreese/markdown-pp";
diff --git a/pkgs/tools/text/mawk/default.nix b/pkgs/tools/text/mawk/default.nix
index 204d346082c36..d5f228d787307 100644
--- a/pkgs/tools/text/mawk/default.nix
+++ b/pkgs/tools/text/mawk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   name = "mawk-1.3.4-20200120";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
     sha256 = "0dw2icf8bnqd9y0clfd9pkcxz4b2phdihwci13z914mf3wgcvm3z";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Interpreter for the AWK Programming Language";
     homepage = "https://invisible-island.net/mawk/mawk.html";
     license = licenses.gpl2;
diff --git a/pkgs/tools/text/mb2md/default.nix b/pkgs/tools/text/mb2md/default.nix
index 91c958cf06757..78ce7f5939741 100644
--- a/pkgs/tools/text/mb2md/default.nix
+++ b/pkgs/tools/text/mb2md/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, perlPackages }:
+{ lib, stdenv, fetchurl, makeWrapper, perlPackages }:
 
 let
   perlDeps = with perlPackages; [ TimeDate ];
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
       --set PERL5LIB "${perlPackages.makePerlPath perlDeps}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "mbox to maildir tool";
     license = licenses.publicDomain;
     platforms = platforms.all;
diff --git a/pkgs/tools/text/mdbook/default.nix b/pkgs/tools/text/mdbook/default.nix
index d95f9854d5448..69b9b8b12cf3f 100644
--- a/pkgs/tools/text/mdbook/default.nix
+++ b/pkgs/tools/text/mdbook/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, CoreServices, darwin }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, CoreServices, darwin }:
 
 rustPlatform.buildRustPackage rec {
   pname = "mdbook";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ CoreServices ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create books from MarkDown";
     homepage = "https://github.com/rust-lang-nursery/mdbook";
     license = [ licenses.mpl20 ];
diff --git a/pkgs/tools/text/mdcat/default.nix b/pkgs/tools/text/mdcat/default.nix
index eb51ad6d260a9..5f5a331daca4e 100644
--- a/pkgs/tools/text/mdcat/default.nix
+++ b/pkgs/tools/text/mdcat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , rustPlatform
 , pkgconfig
@@ -44,7 +44,7 @@ rustPlatform.buildRustPackage rec {
     installShellCompletion --zsh $releaseDir/build/mdcat-*/out/completions/_mdcat
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "cat for markdown";
     homepage = "https://github.com/lunaryorn/mdcat";
     license = with licenses; [ asl20 ];
diff --git a/pkgs/tools/text/mecab/default.nix b/pkgs/tools/text/mecab/default.nix
index 32060a6179a2d..c579dcb8a175b 100644
--- a/pkgs/tools/text/mecab/default.nix
+++ b/pkgs/tools/text/mecab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, mecab-ipadic }:
+{ lib, stdenv, fetchurl, mecab-ipadic }:
 
 let
   mecab-base = import ./base.nix { inherit fetchurl; };
@@ -10,7 +10,7 @@ stdenv.mkDerivation (mecab-base // {
       sed -i 's|^dicdir = .*$|dicdir = ${mecab-ipadic}|' "$out/etc/mecabrc"
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "Japanese morphological analysis system";
       homepage = "http://taku910.github.io/mecab/";
       license = licenses.bsd3;
diff --git a/pkgs/tools/text/miller/default.nix b/pkgs/tools/text/miller/default.nix
index ca71c3a1b3d4a..9cc31be7ed491 100644
--- a/pkgs/tools/text/miller/default.nix
+++ b/pkgs/tools/text/miller/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoreconfHook, flex, libtool }:
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, flex, libtool }:
 
 stdenv.mkDerivation rec {
   pname = "miller";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ autoreconfHook flex libtool ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Like awk, sed, cut, join, and sort for name-indexed data such as CSV, TSV, and tabular JSON";
     homepage    = "http://johnkerl.org/miller/";
     license     = licenses.bsd2;
diff --git a/pkgs/tools/text/numdiff/default.nix b/pkgs/tools/text/numdiff/default.nix
index 6e0c7e756493b..db27c1bfd0c0f 100644
--- a/pkgs/tools/text/numdiff/default.nix
+++ b/pkgs/tools/text/numdiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 
 stdenv.mkDerivation rec {
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     url = "mirror://savannah/numdiff/numdiff-${version}.tar.gz";
     sha256 = "1vzmjh8mhwwysn4x4m2vif7q2k8i19x8azq7pzmkwwj4g48lla47";
   };
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = ''
       A little program that can be used to compare putatively similar files
       line by line and field by field, ignoring small numeric differences
diff --git a/pkgs/tools/text/ocrmypdf/default.nix b/pkgs/tools/text/ocrmypdf/default.nix
index 1e2b76c008e0b..2ba34d42270c4 100644
--- a/pkgs/tools/text/ocrmypdf/default.nix
+++ b/pkgs/tools/text/ocrmypdf/default.nix
@@ -7,7 +7,7 @@
 , python3
 , python3Packages
 , qpdf
-, stdenv
+, lib, stdenv
 , tesseract4
 , unpaper
 , substituteAll
@@ -80,7 +80,7 @@ buildPythonApplication rec {
 
   makeWrapperArgs = [ "--prefix PATH : ${stdenv.lib.makeBinPath [ ghostscript jbig2enc pngquant qpdf tesseract4 unpaper ]}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/jbarlow83/OCRmyPDF";
     description = "Adds an OCR text layer to scanned PDF files, allowing them to be searched";
     license = licenses.gpl3;
diff --git a/pkgs/tools/text/opencc/default.nix b/pkgs/tools/text/opencc/default.nix
index 54027de9acded..32c82341d7b27 100644
--- a/pkgs/tools/text/opencc/default.nix
+++ b/pkgs/tools/text/opencc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, python }:
+{ lib, stdenv, fetchFromGitHub, cmake, python }:
 
 stdenv.mkDerivation rec {
   pname = "opencc";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
   # Parallel building occasionaly fails with: Error copying file "/tmp/nix-build-opencc-1.0.5.drv-0/OpenCC-ver.1.0.5/build/src/libopencc.so.1.0.0" to "/tmp/nix-build-opencc-1.0.5.drv-0/OpenCC-ver.1.0.5/build/src/tools".
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/BYVoid/OpenCC";
     license = licenses.asl20;
     description = "A project for conversion between Traditional and Simplified Chinese";
diff --git a/pkgs/tools/text/papertrail/default.nix b/pkgs/tools/text/papertrail/default.nix
index d635fab74d5ac..57e79b08fda89 100644
--- a/pkgs/tools/text/papertrail/default.nix
+++ b/pkgs/tools/text/papertrail/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, bundlerEnv, ruby, bundlerUpdateScript }:
+{ lib, stdenv, bundlerEnv, ruby, bundlerUpdateScript }:
 
 let
   papertrail-env = bundlerEnv {
@@ -20,7 +20,7 @@ in stdenv.mkDerivation {
 
   passthru.updateScript = bundlerUpdateScript "papertrail";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line client for Papertrail log management service";
     homepage    = "https://github.com/papertrail/papertrail-cli/";
     license     = licenses.mit;
diff --git a/pkgs/tools/text/par/default.nix b/pkgs/tools/text/par/default.nix
index 54b5e6566e871..321421a6b80e7 100644
--- a/pkgs/tools/text/par/default.nix
+++ b/pkgs/tools/text/par/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, fetchpatch}:
+{lib, stdenv, fetchurl, fetchpatch}:
 
 stdenv.mkDerivation {
   pname = "par";
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
   '';
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.nicemice.net/par/";
     description = "Paragraph reflow for email";
     platforms = platforms.unix;
diff --git a/pkgs/tools/text/patchutils/generic.nix b/pkgs/tools/text/patchutils/generic.nix
index 52961e58c0eea..d3e9da242e2e9 100644
--- a/pkgs/tools/text/patchutils/generic.nix
+++ b/pkgs/tools/text/patchutils/generic.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl
+{ lib, stdenv, fetchurl, perl
 , version, sha256, patches ? []
 , ...
 }:
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
 
   doCheck = false; # fails
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tools to manipulate patch files";
     homepage = "http://cyberelk.net/tim/software/patchutils";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/text/pbgopy/default.nix b/pkgs/tools/text/pbgopy/default.nix
index 0982fbf28b5f9..cb8b981b2655a 100644
--- a/pkgs/tools/text/pbgopy/default.nix
+++ b/pkgs/tools/text/pbgopy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "pbgopy";
@@ -13,7 +13,7 @@ buildGoModule rec {
 
   vendorSha256 = "09hn92bi2rmixpsgckbi8f70widls40fwqqm7y7rqglyjqi7rdmw";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Copy and paste between devices";
     homepage = "https://github.com/nakabonne/pbgopy";
     license = licenses.mit;
diff --git a/pkgs/tools/text/peco/default.nix b/pkgs/tools/text/peco/default.nix
index c5655cb2a5852..03d3580ddedb8 100644
--- a/pkgs/tools/text/peco/default.nix
+++ b/pkgs/tools/text/peco/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "peco";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simplistic interactive filtering tool";
     homepage = "https://github.com/peco/peco";
     license = licenses.mit;
diff --git a/pkgs/tools/text/platinum-searcher/default.nix b/pkgs/tools/text/platinum-searcher/default.nix
index e621d13f013d2..30e7e58345d60 100644
--- a/pkgs/tools/text/platinum-searcher/default.nix
+++ b/pkgs/tools/text/platinum-searcher/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "the_platinum_searcher";
@@ -16,7 +16,7 @@ buildGoPackage rec {
 
   goDeps = ./deps.nix;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/monochromegane/the_platinum_searcher";
     description = "A code search tool similar to ack and the_silver_searcher(ag)";
     license = licenses.mit;
diff --git a/pkgs/tools/text/podiff/default.nix b/pkgs/tools/text/podiff/default.nix
index b76dfd2256a08..b44003a9f0dfb 100644
--- a/pkgs/tools/text/podiff/default.nix
+++ b/pkgs/tools/text/podiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation {
   pname = "podiff";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     mkdir -p $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Finds differences in translations between two PO files, or revisions";
     homepage = "http://puszcza.gnu.org.ua/software/podiff";
     license = licenses.gpl3Plus;
diff --git a/pkgs/tools/text/poedit/default.nix b/pkgs/tools/text/poedit/default.nix
index 1c82d8d365e79..f6e5e4a9ebbc7 100644
--- a/pkgs/tools/text/poedit/default.nix
+++ b/pkgs/tools/text/poedit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, autoconf, automake, libtool, gettext, pkgconfig, wxGTK30,
+{ lib, stdenv, fetchurl, autoconf, automake, libtool, gettext, pkgconfig, wxGTK30,
   boost, icu, lucenepp, asciidoc, libxslt, xmlto, gtk2, gtkspell2, pugixml,
   nlohmann_json, hicolor-icon-theme, wrapGAppsHook }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Cross-platform gettext catalogs (.po files) editor";
     homepage = "https://www.poedit.net/";
     license = licenses.mit;
diff --git a/pkgs/tools/text/proselint/default.nix b/pkgs/tools/text/proselint/default.nix
index 36a68f9406d39..ea72468dc6935 100644
--- a/pkgs/tools/text/proselint/default.nix
+++ b/pkgs/tools/text/proselint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, buildPythonApplication, click, future, six }:
+{ lib, stdenv, fetchurl, buildPythonApplication, click, future, six }:
 
 buildPythonApplication rec {
   pname = "proselint";
@@ -13,7 +13,7 @@ buildPythonApplication rec {
 
   propagatedBuildInputs = [ click future six ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A linter for prose";
     homepage = "http://proselint.com";
     license = licenses.bsd3;
diff --git a/pkgs/tools/text/qgrep/default.nix b/pkgs/tools/text/qgrep/default.nix
index 30873e89d1bf3..a3e18c6bba3d8 100644
--- a/pkgs/tools/text/qgrep/default.nix
+++ b/pkgs/tools/text/qgrep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, CoreServices, CoreFoundation, fetchpatch }:
+{ lib, stdenv, fetchFromGitHub, CoreServices, CoreFoundation, fetchpatch }:
 
 stdenv.mkDerivation rec {
   version = "1.1";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     install -Dm755 qgrep $out/bin/qgrep
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast regular expression grep for source code with incremental index updates";
     homepage = "https://github.com/zeux/qgrep";
     license = licenses.mit;
diff --git a/pkgs/tools/text/rgxg/default.nix b/pkgs/tools/text/rgxg/default.nix
index bd291be7015b0..8e4d991e7bf03 100644
--- a/pkgs/tools/text/rgxg/default.nix
+++ b/pkgs/tools/text/rgxg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip }:
+{ lib, stdenv, fetchzip }:
 
 stdenv.mkDerivation rec {
   pname = "rgxg";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "050jxc3qhfrm9fdbzd67hlsqlp4qk1fa20q1g2v919sh7s6v77si";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A C library and a command-line tool to generate (extended) regular expressions";
     license = licenses.zlib;
     maintainers = with maintainers; [ hloeffler ];
diff --git a/pkgs/tools/text/ripgrep-all/default.nix b/pkgs/tools/text/ripgrep-all/default.nix
index 8da7a54ebb240..5d6a74327d42c 100644
--- a/pkgs/tools/text/ripgrep-all/default.nix
+++ b/pkgs/tools/text/ripgrep-all/default.nix
@@ -46,7 +46,7 @@ rustPlatform.buildRustPackage rec {
 
   doInstallCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ripgrep, but also search in PDFs, E-Books, Office documents, zip, tar.gz, and more";
     longDescription = ''
       Ripgrep, but also search in PDFs, E-Books, Office documents, zip, tar.gz, etc.
diff --git a/pkgs/tools/text/ripgrep/default.nix b/pkgs/tools/text/ripgrep/default.nix
index c69c6fef8cbd4..3bea0bdf8fb5e 100644
--- a/pkgs/tools/text/ripgrep/default.nix
+++ b/pkgs/tools/text/ripgrep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , nixosTests
 , fetchFromGitHub
 , rustPlatform
@@ -37,7 +37,7 @@ rustPlatform.buildRustPackage rec {
 
   passthru.tests = { inherit (nixosTests) ripgrep; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility that combines the usability of The Silver Searcher with the raw speed of grep";
     homepage = "https://github.com/BurntSushi/ripgrep";
     license = with licenses; [ unlicense /* or */ mit ];
diff --git a/pkgs/tools/text/rpl/default.nix b/pkgs/tools/text/rpl/default.nix
index 7ac3790f8a980..f53a1d790806b 100644
--- a/pkgs/tools/text/rpl/default.nix
+++ b/pkgs/tools/text/rpl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 pythonPackages.buildPythonApplication rec {
   pname = "rpl";
@@ -14,7 +14,7 @@ pythonPackages.buildPythonApplication rec {
     sha256 = "1xhpgcmq91ivy9ijfyz5ilg51m7fz8ar2077r7gq246j8gbf8ggr";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Replace strings in files";
     homepage    = "https://github.com/kcoyner/rpl";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/text/rs/default.nix b/pkgs/tools/text/rs/default.nix
index bd141f491d415..9aca92922a523 100644
--- a/pkgs/tools/text/rs/default.nix
+++ b/pkgs/tools/text/rs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libbsd }:
+{ lib, stdenv, fetchurl, libbsd }:
 
 stdenv.mkDerivation rec {
   pname = "rs";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
     install -Dm 644 rs.1 -t $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Reshape a data array from standard input";
     longDescription = ''
       rs reads the standard input, interpreting each line as a row of blank-
diff --git a/pkgs/tools/text/ruplacer/default.nix b/pkgs/tools/text/ruplacer/default.nix
index f4b3ed3dca4c4..33a95c365e6fb 100644
--- a/pkgs/tools/text/ruplacer/default.nix
+++ b/pkgs/tools/text/ruplacer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "ruplacer";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = (stdenv.lib.optional stdenv.isDarwin Security);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Find and replace text in source files";
     homepage = "https://github.com/TankerHQ/ruplacer";
     license = [ licenses.bsd3 ];
diff --git a/pkgs/tools/text/schema2ldif/default.nix b/pkgs/tools/text/schema2ldif/default.nix
index 5df4e90ff1aa6..409bbc16a93f1 100644
--- a/pkgs/tools/text/schema2ldif/default.nix
+++ b/pkgs/tools/text/schema2ldif/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeWrapper, perlPackages }: stdenv.mkDerivation rec {
+{ lib, stdenv, fetchurl, makeWrapper, perlPackages }: stdenv.mkDerivation rec {
   pname = "schema2ldif";
   version = "1.3";
 
@@ -21,7 +21,7 @@
        --prefix PERL5PATH : "${perlPackages.makePerlPath [ perlPackages.GetoptLong ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities to manage schema in .schema and .ldif format";
     homepage = "https://www.fusiondirectory.org/schema2ldif-project-and-components/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/text/sd/default.nix b/pkgs/tools/text/sd/default.nix
index 66529514ec7b0..c986150b26c24 100644
--- a/pkgs/tools/text/sd/default.nix
+++ b/pkgs/tools/text/sd/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security
 }:
 
 rustPlatform.buildRustPackage rec {
@@ -16,7 +16,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optionals stdenv.isDarwin [ Security ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Intuitive find & replace CLI (sed alternative)";
     homepage = "https://github.com/chmln/sd";
     license = licenses.mit;
diff --git a/pkgs/tools/text/shocco/default.nix b/pkgs/tools/text/shocco/default.nix
index 65adfc29b95a6..11d8194bb702d 100644
--- a/pkgs/tools/text/shocco/default.nix
+++ b/pkgs/tools/text/shocco/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, perlPackages, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, perlPackages, pythonPackages }:
 
 stdenv.mkDerivation rec {
   pname = "shocco";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ perlPackages.TextMarkdown pythonPackages.pygments ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A quick-and-dirty, literate-programming-style documentation generator for / in POSIX shell";
     homepage = "https://rtomayko.github.io/shocco/";
     license = licenses.mit;
diff --git a/pkgs/tools/text/silver-searcher/default.nix b/pkgs/tools/text/silver-searcher/default.nix
index 51003694203f4..99e0e0a2ac2dd 100644
--- a/pkgs/tools/text/silver-searcher/default.nix
+++ b/pkgs/tools/text/silver-searcher/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, pcre, zlib, lzma}:
+{lib, stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, pcre, zlib, lzma}:
 
 stdenv.mkDerivation rec {
   pname = "silver-searcher";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ autoreconfHook pkgconfig ];
   buildInputs = [ pcre zlib lzma ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ggreer/the_silver_searcher/";
     description = "A code-searching tool similar to ack, but faster";
     maintainers = with maintainers; [ madjar ];
diff --git a/pkgs/tools/text/snippetpixie/default.nix b/pkgs/tools/text/snippetpixie/default.nix
index ed35a9109a07e..fe8ce9657b523 100644
--- a/pkgs/tools/text/snippetpixie/default.nix
+++ b/pkgs/tools/text/snippetpixie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , meson
@@ -73,7 +73,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Your little expandable text snippet helper";
     longDescription = ''
       Your little expandable text snippet helper.
diff --git a/pkgs/tools/text/tab/default.nix b/pkgs/tools/text/tab/default.nix
index 8a80c7ad10e92..a0539d4d372bb 100644
--- a/pkgs/tools/text/tab/default.nix
+++ b/pkgs/tools/text/tab/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromBitbucket, python3 }:
+{ lib, stdenv, fetchFromBitbucket, python3 }:
 
 stdenv.mkDerivation rec {
   version = "7.2";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Programming language/shell calculator";
     homepage    = "https://tkatchev.bitbucket.io/tab/";
     license     = licenses.boost;
diff --git a/pkgs/tools/text/transifex-client/default.nix b/pkgs/tools/text/transifex-client/default.nix
index ac10564c9f769..411c9cb989985 100644
--- a/pkgs/tools/text/transifex-client/default.nix
+++ b/pkgs/tools/text/transifex-client/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildPythonApplication, fetchPypi
+{ lib, stdenv, buildPythonApplication, fetchPypi
 , python-slugify, requests, urllib3, six, setuptools }:
 
 buildPythonApplication rec {
@@ -23,7 +23,7 @@ buildPythonApplication rec {
   # Requires external resources
   doCheck = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.transifex.com/";
     license = licenses.gpl2;
     description = "Transifex translation service client";
diff --git a/pkgs/tools/text/ucg/default.nix b/pkgs/tools/text/ucg/default.nix
index db89845368044..d81b5a14f0914 100644
--- a/pkgs/tools/text/ucg/default.nix
+++ b/pkgs/tools/text/ucg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , pkg-config
 , autoreconfHook
@@ -22,7 +22,7 @@ in stdenv.mkDerivation {
   nativeBuildInputs = [ autoreconfHook pkg-config ];
   buildInputs = [ pcre ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/gvansickle/ucg/";
     description = "Grep-like tool for searching large bodies of source code";
     longDescription = ''
diff --git a/pkgs/tools/text/ugrep/default.nix b/pkgs/tools/text/ugrep/default.nix
index 84dc21aba3e95..83cb0e4638803 100644
--- a/pkgs/tools/text/ugrep/default.nix
+++ b/pkgs/tools/text/ugrep/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, bzip2, lz4, pcre2, xz, zlib }:
+{ lib, stdenv, fetchFromGitHub, boost, bzip2, lz4, pcre2, xz, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "ugrep";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ boost bzip2 lz4 pcre2 xz zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Ultra fast grep with interactive query UI";
     homepage = "https://github.com/Genivia/ugrep";
     maintainers = with maintainers; [ numkem ];
diff --git a/pkgs/tools/text/unoconv/default.nix b/pkgs/tools/text/unoconv/default.nix
index dc9412d3c0e02..97a3b4d725ee4 100644
--- a/pkgs/tools/text/unoconv/default.nix
+++ b/pkgs/tools/text/unoconv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python3, libreoffice-unwrapped, asciidoc, makeWrapper
+{ lib, stdenv, fetchFromGitHub, python3, libreoffice-unwrapped, asciidoc, makeWrapper
 # whether to install odt2pdf/odt2doc/... symlinks to unoconv
 , installSymlinks ? true
 }:
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
     make install-links prefix="$out"
   '' else "");
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert between any document format supported by LibreOffice/OpenOffice";
     homepage = "http://dag.wieers.com/home-made/unoconv/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/text/unrtf/default.nix b/pkgs/tools/text/unrtf/default.nix
index 752d576701ee4..57ffe95988d07 100644
--- a/pkgs/tools/text/unrtf/default.nix
+++ b/pkgs/tools/text/unrtf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, autoconf, automake, libiconv }:
+{ lib, stdenv, fetchurl, fetchpatch, autoconf, automake, libiconv }:
 
 stdenv.mkDerivation rec {
   pname = "unrtf";
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "man" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A converter from Rich Text Format to other formats";
     longDescription = ''
       UnRTF converts documents in Rich Text Format to other
diff --git a/pkgs/tools/text/untex/default.nix b/pkgs/tools/text/untex/default.nix
index 829c4da384936..55cf01d698f8c 100644
--- a/pkgs/tools/text/untex/default.nix
+++ b/pkgs/tools/text/untex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "untex";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A utility which removes LaTeX commands from input";
     homepage = "https://www.ctan.org/pkg/untex";
     license = licenses.gpl1;
diff --git a/pkgs/tools/text/vale/default.nix b/pkgs/tools/text/vale/default.nix
index 52a5c9341f852..2b6307ed0096c 100644
--- a/pkgs/tools/text/vale/default.nix
+++ b/pkgs/tools/text/vale/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "vale";
@@ -23,7 +23,7 @@ buildGoModule rec {
 
   buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://errata-ai.gitbook.io/vale/";
     description = "A syntax-aware linter for prose built with speed and extensibility in mind";
     license = licenses.mit;
diff --git a/pkgs/tools/text/xidel/default.nix b/pkgs/tools/text/xidel/default.nix
index fabfdd857107c..0996cf944eb04 100644
--- a/pkgs/tools/text/xidel/default.nix
+++ b/pkgs/tools/text/xidel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dpkg }:
+{ lib, stdenv, fetchurl, dpkg }:
 
 stdenv.mkDerivation rec {
   pname = "xidel";
@@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
     patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" "$out/bin/xidel"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line tool to download and extract data from html/xml pages";
     homepage = "http://videlibri.sourceforge.net/xidel.html";
     # source contains no license info (AFAICS), but sourceforge says GPLv2
diff --git a/pkgs/tools/text/xml/basex/default.nix b/pkgs/tools/text/xml/basex/default.nix
index 45c9eb4866cef..9256abf3cbdb6 100644
--- a/pkgs/tools/text/xml/basex/default.nix
+++ b/pkgs/tools/text/xml/basex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, unzip, jre, coreutils, makeDesktopItem }:
+{ lib, stdenv, fetchurl, unzip, jre, coreutils, makeDesktopItem }:
 
 stdenv.mkDerivation rec {
   pname = "basex";
@@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XML database and XPath/XQuery processor";
     longDescription = ''
       BaseX is a very fast and light-weight, yet powerful XML database and
diff --git a/pkgs/tools/text/xml/html-xml-utils/default.nix b/pkgs/tools/text/xml/html-xml-utils/default.nix
index d4bd40a119931..5dab3d642a3bb 100644
--- a/pkgs/tools/text/xml/html-xml-utils/default.nix
+++ b/pkgs/tools/text/xml/html-xml-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, curl, libiconv }:
+{ lib, stdenv, fetchurl, curl, libiconv }:
 
 stdenv.mkDerivation rec {
   pname = "html-xml-utils";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [curl libiconv];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for manipulating HTML and XML files";
     homepage = "http://www.w3.org/Tools/HTML-XML-utils/";
     license = licenses.w3c;
diff --git a/pkgs/tools/text/xml/jing-trang/default.nix b/pkgs/tools/text/xml/jing-trang/default.nix
index dcf83c736cc42..542a4709efebd 100644
--- a/pkgs/tools/text/xml/jing-trang/default.nix
+++ b/pkgs/tools/text/xml/jing-trang/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, jre_headless, jdk, ant, saxon }:
+{ lib, stdenv, fetchFromGitHub, jre_headless, jdk, ant, saxon }:
 
 stdenv.mkDerivation {
   pname = "jing-trang";
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
     chmod +x "$out"/bin/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A RELAX NG validator in Java";
     # The homepage is www.thaiopensource.com, but it links to googlecode.com
     # for downloads and call it the "project site".
diff --git a/pkgs/tools/text/xml/rnv/default.nix b/pkgs/tools/text/xml/rnv/default.nix
index 2bc1b6ddddac4..1ee3355d10529 100644
--- a/pkgs/tools/text/xml/rnv/default.nix
+++ b/pkgs/tools/text/xml/rnv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, expat }:
+{ lib, stdenv, fetchurl, expat }:
 
 stdenv.mkDerivation rec {
   pname = "rnv";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ expat ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Relax NG Compact Syntax validator";
     homepage = "http://www.davidashen.net/rnv.html";
     license = licenses.bsd3;
diff --git a/pkgs/tools/text/xml/xml2/default.nix b/pkgs/tools/text/xml/xml2/default.nix
index 8c341855e6877..8ae8ea48bf3e8 100644
--- a/pkgs/tools/text/xml/xml2/default.nix
+++ b/pkgs/tools/text/xml/xml2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libxml2 }:
+{ lib, stdenv, fetchurl, pkgconfig, libxml2 }:
 
 stdenv.mkDerivation {
   name = "xml2-0.5";
@@ -11,7 +11,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ libxml2 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://web.archive.org/web/20160515005047/http://dan.egnor.name:80/xml2";
     description = "Tools for command line processing of XML, HTML, and CSV";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/text/xml/xmloscopy/default.nix b/pkgs/tools/text/xml/xmloscopy/default.nix
index 2cd7a580ee344..c915e2c7fc5bc 100644
--- a/pkgs/tools/text/xml/xmloscopy/default.nix
+++ b/pkgs/tools/text/xml/xmloscopy/default.nix
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
       --set PATH "${spath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "wtf is my docbook broken?";
     homepage = "https://github.com/grahamc/xmloscopy";
     license = licenses.mit;
diff --git a/pkgs/tools/text/xsv/default.nix b/pkgs/tools/text/xsv/default.nix
index b17dba7a127fe..c71221ccd761c 100644
--- a/pkgs/tools/text/xsv/default.nix
+++ b/pkgs/tools/text/xsv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform, Security }:
+{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }:
 
 rustPlatform.buildRustPackage rec {
   pname = "xsv";
@@ -15,7 +15,7 @@ rustPlatform.buildRustPackage rec {
 
   buildInputs = stdenv.lib.optional stdenv.isDarwin Security;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast CSV toolkit written in Rust";
     homepage = "https://github.com/BurntSushi/xsv";
     license = with licenses; [ unlicense /* or */ mit ];
diff --git a/pkgs/tools/text/xurls/default.nix b/pkgs/tools/text/xurls/default.nix
index 6c8e5520d7453..b1fd02ca75bbc 100644
--- a/pkgs/tools/text/xurls/default.nix
+++ b/pkgs/tools/text/xurls/default.nix
@@ -1,4 +1,4 @@
-{ buildGoPackage, stdenv, fetchFromGitHub }:
+{ buildGoPackage, lib, stdenv, fetchFromGitHub }:
 
 buildGoPackage rec {
   version = "2.2.0";
@@ -14,7 +14,7 @@ buildGoPackage rec {
   goPackagePath = "mvdan.cc/xurls/v2";
   subPackages = [ "cmd/xurls" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Extract urls from text";
     homepage = "https://github.com/mvdan/xurls";
     maintainers = with maintainers; [ koral ];
diff --git a/pkgs/tools/text/yaml-merge/default.nix b/pkgs/tools/text/yaml-merge/default.nix
index b91d24e1137d7..d36522edb8743 100644
--- a/pkgs/tools/text/yaml-merge/default.nix
+++ b/pkgs/tools/text/yaml-merge/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pythonPackages }:
+{ lib, stdenv, fetchFromGitHub, pythonPackages }:
 
 stdenv.mkDerivation {
   name= "yaml-merge-2016-02-16";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     wrapPythonPrograms
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Merge YAML data files";
     homepage = "https://github.com/abbradar/yaml-merge";
     license = licenses.bsd2;
diff --git a/pkgs/tools/typesetting/asciidoc/default.nix b/pkgs/tools/typesetting/asciidoc/default.nix
index 136c25f73b159..1bcd07aceb586 100644
--- a/pkgs/tools/typesetting/asciidoc/default.nix
+++ b/pkgs/tools/typesetting/asciidoc/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, python2
+{ fetchurl, lib, stdenv, python2
 
 , enableStandardFeatures ? false
 , sourceHighlight ? null
@@ -261,7 +261,7 @@ stdenv.mkDerivation rec {
   preInstall = "mkdir -p $out/etc/vim";
   makeFlags = stdenv.lib.optional stdenv.isCygwin "DESTDIR=/.";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Text-based document generation system";
     longDescription = ''
       AsciiDoc is a text document format for writing notes, documentation,
diff --git a/pkgs/tools/typesetting/asciidoctorj/default.nix b/pkgs/tools/typesetting/asciidoctorj/default.nix
index 391c78814e772..6a3b43dc8d189 100644
--- a/pkgs/tools/typesetting/asciidoctorj/default.nix
+++ b/pkgs/tools/typesetting/asciidoctorj/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, jdk, makeWrapper }:
+{ lib, stdenv, fetchzip, jdk, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "asciidoctorj";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
       --prefix JAVA_HOME : ${jdk}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Official library for running Asciidoctor on the JVM";
     longDescription = ''
       AsciidoctorJ is the official library for running Asciidoctor on the JVM.
diff --git a/pkgs/tools/typesetting/bibclean/default.nix b/pkgs/tools/typesetting/bibclean/default.nix
index c95c6921a4e0d..8c7e123acf73b 100644
--- a/pkgs/tools/typesetting/bibclean/default.nix
+++ b/pkgs/tools/typesetting/bibclean/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "bibclean";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     mkdir -p $out/bin $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prettyprint and syntax check BibTeX and Scribe bibliography data base files";
     homepage = "http://ftp.math.utah.edu/pub/bibclean";
     license = licenses.gpl2;
diff --git a/pkgs/tools/typesetting/biber/default.nix b/pkgs/tools/typesetting/biber/default.nix
index 0c472947c0a2d..1bcee62ac6cae 100644
--- a/pkgs/tools/typesetting/biber/default.nix
+++ b/pkgs/tools/typesetting/biber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchpatch, perlPackages, shortenPerlShebang, texlive }:
+{ lib, stdenv, fetchpatch, perlPackages, shortenPerlShebang, texlive }:
 
 let
   biberSource = stdenv.lib.head (builtins.filter (p: p.tlType == "source") texlive.biber.pkgs);
@@ -35,7 +35,7 @@ perlPackages.buildPerlModule {
     shortenPerlShebang $out/bin/biber
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Backend for BibLaTeX";
     license = with licenses; [ artistic1 gpl1Plus ];
     platforms = platforms.unix;
diff --git a/pkgs/tools/typesetting/biblatex-check/default.nix b/pkgs/tools/typesetting/biblatex-check/default.nix
index bad5606600239..606e07730e4f6 100644
--- a/pkgs/tools/typesetting/biblatex-check/default.nix
+++ b/pkgs/tools/typesetting/biblatex-check/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, python }:
+{ lib, stdenv, fetchFromGitHub, python }:
 
 stdenv.mkDerivation {
   pname = "biblatex-check";
@@ -17,7 +17,7 @@ stdenv.mkDerivation {
     install -Dm755 biblatex_check.py $out/bin/biblatex-check
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Python2/3 script for checking BibLatex .bib files";
     homepage = "https://github.com/Pezmc/BibLatex-Check";
     license = licenses.mit;
diff --git a/pkgs/tools/typesetting/docbook2odf/default.nix b/pkgs/tools/typesetting/docbook2odf/default.nix
index d846d9394b26c..b6b56e83688d2 100644
--- a/pkgs/tools/typesetting/docbook2odf/default.nix
+++ b/pkgs/tools/typesetting/docbook2odf/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, makeWrapper, zip, libxslt }:
+{ lib, stdenv, fetchurl, perlPackages, makeWrapper, zip, libxslt }:
 
 stdenv.mkDerivation rec {
   name = "docbook2odf-0.244";
@@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
       --prefix PERL5PATH : "${perlPackages.makePerlPath [ perlPackages.PerlMagick ]}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Convert DocBook to OpenDocument Format (ODF)";
     longDescription = ''
       Docbook2odf is a toolkit that automaticaly converts DocBook to OASIS
diff --git a/pkgs/tools/typesetting/docbook2x/default.nix b/pkgs/tools/typesetting/docbook2x/default.nix
index a36da7a2b6ae8..fdfa05f20c1f7 100644
--- a/pkgs/tools/typesetting/docbook2x/default.nix
+++ b/pkgs/tools/typesetting/docbook2x/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, texinfo, perlPackages
+{ fetchurl, lib, stdenv, texinfo, perlPackages
 , groff, libxml2, libxslt, gnused, libiconv, opensp
 , docbook_xml_dtd_43
 , makeWrapper }:
@@ -44,7 +44,7 @@ stdenv.mkDerivation rec {
       "${gnused}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     longDescription = ''
       docbook2X is a software package that converts DocBook documents
       into the traditional Unix man page format and the GNU Texinfo
diff --git a/pkgs/tools/typesetting/fop/default.nix b/pkgs/tools/typesetting/fop/default.nix
index d5dea2c6dc6fe..a572ce216ee6c 100644
--- a/pkgs/tools/typesetting/fop/default.nix
+++ b/pkgs/tools/typesetting/fop/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, ant, jdk, runtimeShell }:
+{ fetchurl, lib, stdenv, ant, jdk, runtimeShell }:
 
 stdenv.mkDerivation rec {
   pname = "fop";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     chmod a+x $out/bin/fop
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XML formatter driven by XSL Formatting Objects (XSL-FO)";
     longDescription = ''
       FOP is a Java application that reads a formatting object tree and then
diff --git a/pkgs/tools/typesetting/git-latexdiff/default.nix b/pkgs/tools/typesetting/git-latexdiff/default.nix
index d969ca8fec6fc..0bc8b7e073ec2 100644
--- a/pkgs/tools/typesetting/git-latexdiff/default.nix
+++ b/pkgs/tools/typesetting/git-latexdiff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, git, bash }:
+{ lib, stdenv, fetchFromGitLab, git, bash }:
 
 stdenv.mkDerivation rec {
   version = "1.3.0";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
     chmod +x $prefix/bin/git-latexdiff
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "View diff on LaTeX source files on the generated PDF files";
     homepage = "https://gitlab.com/git-latexdiff/git-latexdiff";
     maintainers = [ ];
diff --git a/pkgs/tools/typesetting/halibut/default.nix b/pkgs/tools/typesetting/halibut/default.nix
index d2779df0c9442..d077ef823ffc4 100644
--- a/pkgs/tools/typesetting/halibut/default.nix
+++ b/pkgs/tools/typesetting/halibut/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, perl}:
+{lib, stdenv, fetchurl, perl}:
 
 stdenv.mkDerivation rec {
   name = "halibut-1.2";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     make install
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Documentation production system for software manuals";
     homepage = "https://www.chiark.greenend.org.uk/~sgtatham/halibut/";
     license = licenses.mit;
diff --git a/pkgs/tools/typesetting/hevea/default.nix b/pkgs/tools/typesetting/hevea/default.nix
index f3f634eb944c7..97b020d3e21cb 100644
--- a/pkgs/tools/typesetting/hevea/default.nix
+++ b/pkgs/tools/typesetting/hevea/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ocamlPackages }:
+{ lib, stdenv, fetchurl, ocamlPackages }:
 
 stdenv.mkDerivation rec {
   name = "hevea-2.34";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
 
   makeFlags = [ "PREFIX=$(out)" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A quite complete and fast LATEX to HTML translator";
     homepage = "http://pauillac.inria.fr/~maranget/hevea/";
     license = licenses.qpl;
diff --git a/pkgs/tools/typesetting/htmldoc/default.nix b/pkgs/tools/typesetting/htmldoc/default.nix
index ae6e2e9006e64..124839ca45d64 100644
--- a/pkgs/tools/typesetting/htmldoc/default.nix
+++ b/pkgs/tools/typesetting/htmldoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 
 , SystemConfiguration ? null, Foundation ? null
 }:
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
        lib.optional isDarwin SystemConfiguration
     ++ lib.optional isDarwin Foundation;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Converts HTML files to PostScript and PDF";
     homepage    = "https://michaelrsweet.github.io/htmldoc";
     license     = licenses.gpl2;
diff --git a/pkgs/tools/typesetting/kindlegen/default.nix b/pkgs/tools/typesetting/kindlegen/default.nix
index 1067386c2f8d3..60f58a361dfd8 100644
--- a/pkgs/tools/typesetting/kindlegen/default.nix
+++ b/pkgs/tools/typesetting/kindlegen/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, unzip }:
+{ fetchurl, lib, stdenv, unzip }:
 
 let
   version = "2.9";
@@ -41,7 +41,7 @@ in stdenv.mkDerivation {
     cp -r *.txt *.html docs/* $out/share/kindlegen/doc
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     broken = true; # download links got removed
     description = "Convert documents to .mobi for use with Amazon Kindle";
     homepage = "https://www.amazon.com/gp/feature.html?docId=1000765211";
diff --git a/pkgs/tools/typesetting/lowdown/default.nix b/pkgs/tools/typesetting/lowdown/default.nix
index ecd25bf8e8338..d6b92991340a3 100644
--- a/pkgs/tools/typesetting/lowdown/default.nix
+++ b/pkgs/tools/typesetting/lowdown/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, which }:
+{ lib, stdenv, fetchurl, which }:
 
 stdenv.mkDerivation rec {
   pname = "lowdown";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
                 MANDIR=''${!outputBin}/share/man
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kristaps.bsd.lv/lowdown/";
     description = "Simple markdown translator";
     license = licenses.isc;
diff --git a/pkgs/tools/typesetting/multimarkdown/default.nix b/pkgs/tools/typesetting/multimarkdown/default.nix
index 5043eb681e881..67c995f6c269e 100644
--- a/pkgs/tools/typesetting/multimarkdown/default.nix
+++ b/pkgs/tools/typesetting/multimarkdown/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, perl }:
+{ lib, stdenv, fetchgit, perl }:
 
 stdenv.mkDerivation {
   pname = "multimarkdown";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
   checkPhase = "make test-all";
   installPhase = "make pkg-install prefix='' DESTDIR=$out; make pkg-install-scripts prefix='' DESTDIR=$out";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A derivative of Markdown that adds new syntax features";
     longDescription = ''
       MultiMarkdown is a lightweight markup language created by
diff --git a/pkgs/tools/typesetting/odpdown/default.nix b/pkgs/tools/typesetting/odpdown/default.nix
index 4b85a252c1308..989f61f4592eb 100644
--- a/pkgs/tools/typesetting/odpdown/default.nix
+++ b/pkgs/tools/typesetting/odpdown/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pythonPackages, libreoffice }:
+{ lib, stdenv, fetchurl, pythonPackages, libreoffice }:
 
 pythonPackages.buildPythonApplication rec {
 
@@ -16,7 +16,7 @@ pythonPackages.buildPythonApplication rec {
     nose
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/thorstenb/odpdown";
     repositories.git = "https://github.com/thorstenb/odpdown.git";
     description = "Create nice-looking slides from your favourite text editor";
diff --git a/pkgs/tools/typesetting/pdf2djvu/default.nix b/pkgs/tools/typesetting/pdf2djvu/default.nix
index c3ddb219ab8cb..eb605ef8fab4c 100644
--- a/pkgs/tools/typesetting/pdf2djvu/default.nix
+++ b/pkgs/tools/typesetting/pdf2djvu/default.nix
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Creates djvu files from PDF files";
     homepage = "https://jwilk.net/software/pdf2djvu";
     license = licenses.gpl2;
diff --git a/pkgs/tools/typesetting/pdf2odt/default.nix b/pkgs/tools/typesetting/pdf2odt/default.nix
index 879597f91da4e..8365163c2fcb1 100644
--- a/pkgs/tools/typesetting/pdf2odt/default.nix
+++ b/pkgs/tools/typesetting/pdf2odt/default.nix
@@ -38,7 +38,7 @@ in stdenv.mkDerivation rec {
       --prefix PATH : ${path}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "PDF to ODT format converter";
     homepage    = "https://github.com/gutschke/pdf2odt";
     license     = licenses.mit;
diff --git a/pkgs/tools/typesetting/pdfsandwich/default.nix b/pkgs/tools/typesetting/pdfsandwich/default.nix
index 12fcf8a71a26b..de3cc7f64e8a9 100644
--- a/pkgs/tools/typesetting/pdfsandwich/default.nix
+++ b/pkgs/tools/typesetting/pdfsandwich/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, ocaml, makeWrapper, fetchsvn, ghostscript, imagemagick, perl, poppler_utils, tesseract, unpaper }:
+{ lib, stdenv, ocaml, makeWrapper, fetchsvn, ghostscript, imagemagick, perl, poppler_utils, tesseract, unpaper }:
 
 stdenv.mkDerivation {
   version = "0.1.7";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     cp -p pdfsandwich.1.gz $out/man/man1
   '';
 
-meta = with stdenv.lib; {
+meta = with lib; {
     description = "OCR tool for scanned PDFs";
     homepage = "http://www.tobias-elze.de/pdfsandwich/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/typesetting/pdftk/default.nix b/pkgs/tools/typesetting/pdftk/default.nix
index 25fc794b05580..f90d1d4a7ed1d 100644
--- a/pkgs/tools/typesetting/pdftk/default.nix
+++ b/pkgs/tools/typesetting/pdftk/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, gradle, jre, perl, writeText, runtimeShell }:
+{ lib, stdenv, fetchFromGitLab, gradle, jre, perl, writeText, runtimeShell }:
 
 let
   pname = "pdftk";
@@ -85,7 +85,7 @@ in stdenv.mkDerivation rec {
     cp ${src}/pdftk.1 $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command-line tool for working with PDFs";
     homepage = "https://gitlab.com/pdftk-java/pdftk";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/typesetting/psutils/default.nix b/pkgs/tools/typesetting/psutils/default.nix
index 72c72d1b3baa6..fe3223ae6c902 100644
--- a/pkgs/tools/typesetting/psutils/default.nix
+++ b/pkgs/tools/typesetting/psutils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perl }:
+{ lib, stdenv, fetchurl, perl }:
 
 stdenv.mkDerivation {
   name = "psutils-17";
@@ -18,7 +18,7 @@ stdenv.mkDerivation {
     mkdir -p $out/bin $out/share/man/man1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of useful utilities for manipulating PS documents";
     homepage = "http://knackered.knackered.org/angus/psutils/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/typesetting/rubber/default.nix b/pkgs/tools/typesetting/rubber/default.nix
index f3f036ce50eb0..c09ae04e3a1d8 100644
--- a/pkgs/tools/typesetting/rubber/default.nix
+++ b/pkgs/tools/typesetting/rubber/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, python3Packages, texinfo }:
+{ fetchurl, lib, stdenv, python3Packages, texinfo }:
 
 python3Packages.buildPythonApplication rec {
   pname = "rubber";
@@ -24,7 +24,7 @@ python3Packages.buildPythonApplication rec {
     cd tests && ${stdenv.shell} run.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wrapper for LaTeX and friends";
     longDescription = ''
       Rubber is a program whose purpose is to handle all tasks related
diff --git a/pkgs/tools/typesetting/satysfi/default.nix b/pkgs/tools/typesetting/satysfi/default.nix
index b97652bb4a695..03ce2eb5ee806 100644
--- a/pkgs/tools/typesetting/satysfi/default.nix
+++ b/pkgs/tools/typesetting/satysfi/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, fetchFromGitHub, ruby, dune_2, ocamlPackages
+{ lib, stdenv, fetchzip, fetchFromGitHub, ruby, dune_2, ocamlPackages
 , ipaexfont, junicode, lmodern, lmmath
 }:
 let
@@ -67,7 +67,7 @@ in
       cp -r lib-satysfi/dist/ $out/share/satysfi/
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://github.com/gfngfn/SATySFi";
       description = "A statically-typed, functional typesetting system";
       license = licenses.lgpl3;
diff --git a/pkgs/tools/typesetting/scdoc/default.nix b/pkgs/tools/typesetting/scdoc/default.nix
index ddff50ea0e830..1b22b781d5496 100644
--- a/pkgs/tools/typesetting/scdoc/default.nix
+++ b/pkgs/tools/typesetting/scdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ lib, stdenv, fetchurl }:
 
 stdenv.mkDerivation rec {
   pname = "scdoc";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple man page generator";
     longDescription = ''
       scdoc is a simple man page generator written for POSIX systems written in
diff --git a/pkgs/tools/typesetting/sile/default.nix b/pkgs/tools/typesetting/sile/default.nix
index 9ed6c1de0e91b..e28fd9a7eaf93 100644
--- a/pkgs/tools/typesetting/sile/default.nix
+++ b/pkgs/tools/typesetting/sile/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , darwin
 , fetchurl
 , makeWrapper
@@ -95,7 +95,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "doc" "man" "dev" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A typesetting system";
     longDescription = ''
       SILE is a typesetting system; its job is to produce beautiful
diff --git a/pkgs/tools/typesetting/sshlatex/default.nix b/pkgs/tools/typesetting/sshlatex/default.nix
index 26af225894673..663f12611b1de 100644
--- a/pkgs/tools/typesetting/sshlatex/default.nix
+++ b/pkgs/tools/typesetting/sshlatex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, inotify-tools, openssh, perl, gnutar, bash, makeWrapper }:
+{ lib, stdenv, fetchFromGitHub, inotify-tools, openssh, perl, gnutar, bash, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "sshlatex";
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     wrapProgram $out/bin/sshlatex --prefix PATH : "${binPath}"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A collection of hacks to efficiently run LaTeX via ssh";
     longDescription = ''
       sshlatex is a tool which uploads LaTeX source files to a remote, runs
diff --git a/pkgs/tools/typesetting/tectonic/default.nix b/pkgs/tools/typesetting/tectonic/default.nix
index d37a4a69570bf..f22840e2d862c 100644
--- a/pkgs/tools/typesetting/tectonic/default.nix
+++ b/pkgs/tools/typesetting/tectonic/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, rustPlatform
+{ lib, stdenv, fetchFromGitHub, rustPlatform
 , darwin, fontconfig, harfbuzz, openssl, pkgconfig }:
 
 rustPlatform.buildRustPackage rec {
@@ -26,7 +26,7 @@ rustPlatform.buildRustPackage rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Modernized, complete, self-contained TeX/LaTeX engine, powered by XeTeX and TeXLive";
     homepage = "https://tectonic-typesetting.github.io/";
     changelog = "https://github.com/tectonic-typesetting/tectonic/blob/tectonic@${version}/CHANGELOG.md";
diff --git a/pkgs/tools/typesetting/ted/default.nix b/pkgs/tools/typesetting/ted/default.nix
index 6d7ef3348613b..0fc2427588f72 100644
--- a/pkgs/tools/typesetting/ted/default.nix
+++ b/pkgs/tools/typesetting/ted/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, zlib, pcre, xorg, libjpeg, libtiff, libpng, gtk2, libpaper, makeWrapper, ghostscript }:
+{ lib, stdenv, fetchurl, pkgconfig, zlib, pcre, xorg, libjpeg, libtiff, libpng, gtk2, libpaper, makeWrapper, ghostscript }:
 
 stdenv.mkDerivation rec {
   pname = "ted";
@@ -60,7 +60,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ pkgconfig zlib pcre xorg.xlibsWrapper xorg.libXpm libjpeg libtiff libpng gtk2 libpaper makeWrapper ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An easy rich text processor";
     longDescription = ''
       Ted is a text processor running under X Windows on Unix/Linux systems.
diff --git a/pkgs/tools/typesetting/tex/lkproof/default.nix b/pkgs/tools/typesetting/tex/lkproof/default.nix
index 39029635beb46..d5b6a7f9f9734 100644
--- a/pkgs/tools/typesetting/tex/lkproof/default.nix
+++ b/pkgs/tools/typesetting/tex/lkproof/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip}:
+{lib, stdenv, fetchurl, unzip}:
 
 stdenv.mkDerivation {
   name = "lkproof-3.1";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     cp -prd *.sty $out/share/texmf-nix/tex/generic/lkproof
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.unix;
     license = licenses.gpl1Plus;
   };
diff --git a/pkgs/tools/typesetting/tex/pgf/1.x.nix b/pkgs/tools/typesetting/tex/pgf/1.x.nix
index dc13ea3317822..efaf0e0fe1b36 100644
--- a/pkgs/tools/typesetting/tex/pgf/1.x.nix
+++ b/pkgs/tools/typesetting/tex/pgf/1.x.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "pgf-1.18";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     cp -prd * $out/share/texmf-nix
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     branch = "1";
     platforms = platforms.unix;
     license = licenses.gpl2;
diff --git a/pkgs/tools/typesetting/tex/pgf/2.x.nix b/pkgs/tools/typesetting/tex/pgf/2.x.nix
index 00b92935babb6..9661ec3324be1 100644
--- a/pkgs/tools/typesetting/tex/pgf/2.x.nix
+++ b/pkgs/tools/typesetting/tex/pgf/2.x.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation {
   name = "pgf-2.00";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     cp -prd * $out/share/texmf-nix
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     branch = "2";
     platforms = platforms.unix;
     license = licenses.gpl2;
diff --git a/pkgs/tools/typesetting/tex/pgf/3.x.nix b/pkgs/tools/typesetting/tex/pgf/3.x.nix
index a9ff54e4c11ec..42320b49b3d86 100644
--- a/pkgs/tools/typesetting/tex/pgf/3.x.nix
+++ b/pkgs/tools/typesetting/tex/pgf/3.x.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip}:
+{lib, stdenv, fetchurl, unzip}:
 
 stdenv.mkDerivation {
   name = "pgf-3.00";
@@ -24,7 +24,7 @@ stdenv.mkDerivation {
     cp -prd * $out/share/texmf-nix
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     branch = "3";
     platforms = platforms.unix;
     license = licenses.gpl2;
diff --git a/pkgs/tools/typesetting/tex/pgfplots/default.nix b/pkgs/tools/typesetting/tex/pgfplots/default.nix
index 998f61786db45..aecf32c587472 100644
--- a/pkgs/tools/typesetting/tex/pgfplots/default.nix
+++ b/pkgs/tools/typesetting/tex/pgfplots/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, unzip}:
+{lib, stdenv, fetchurl, unzip}:
 
 stdenv.mkDerivation {
   name = "pgfplots-1.5.1";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     cp -prd * $out/share/texmf-nix
   ";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "TeX package to draw plots directly in TeX in two and three dimensions";
     homepage = "http://pgfplots.sourceforge.net";
     platforms = platforms.unix;
diff --git a/pkgs/tools/typesetting/tex/pplatex/default.nix b/pkgs/tools/typesetting/tex/pplatex/default.nix
index 01777f3dd4285..d59ab8a2a90c3 100644
--- a/pkgs/tools/typesetting/tex/pplatex/default.nix
+++ b/pkgs/tools/typesetting/tex/pplatex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, pcre }:
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, pcre }:
 
 stdenv.mkDerivation {
   pname = "pplatex";
@@ -21,7 +21,7 @@ stdenv.mkDerivation {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description =
       "A tool to reformat the output of latex and friends into readable messages";
     homepage = "https://github.com/stefanhepp/pplatex";
diff --git a/pkgs/tools/typesetting/tex/tetex/default.nix b/pkgs/tools/typesetting/tex/tetex/default.nix
index 021927702ffbe..db0a4c0160247 100644
--- a/pkgs/tools/typesetting/tex/tetex/default.nix
+++ b/pkgs/tools/typesetting/tex/tetex/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, flex, bison, zlib, libpng, ncurses, ed, automake }:
+{ lib, stdenv, fetchurl, flex, bison, zlib, libpng, ncurses, ed, automake }:
 
 stdenv.mkDerivation {
   name = "tetex-3.0";
@@ -45,7 +45,7 @@ stdenv.mkDerivation {
     substituteInPlace ./tetex-src-3.0/configure --replace /usr/bin/install $(type -P install)
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description  = "A full-featured (La)TeX distribution";
     homepage     = "http://www.tug.org/tetex/";
     maintainers  = with maintainers; [ lovek323 ];
diff --git a/pkgs/tools/typesetting/tex/texlive/bin.nix b/pkgs/tools/typesetting/tex/texlive/bin.nix
index 030ac1b43aae7..3b09bc4a55a8a 100644
--- a/pkgs/tools/typesetting/tex/texlive/bin.nix
+++ b/pkgs/tools/typesetting/tex/texlive/bin.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , texlive
 , zlib, libiconv, libpng, libX11
 , freetype, gd, libXaw, icu, ghostscript, libXpm, libXmu, libXext
@@ -142,7 +142,7 @@ core = stdenv.mkDerivation rec {
   setupHook = ./setup-hook.sh; # TODO: maybe texmf-nix -> texmf (and all references)
   passthru = { inherit version buildInputs; };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Basic binaries for TeX Live";
     homepage    = "http://www.tug.org/texlive";
     license     = stdenv.lib.licenses.gpl2;
@@ -341,7 +341,7 @@ pygmentex = python2Packages.buildPythonApplication rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.ctan.org/pkg/pygmentex";
     description = "Auxiliary tool for typesetting code listings in LaTeX documents using Pygments";
     longDescription = ''
diff --git a/pkgs/tools/typesetting/tikzit/default.nix b/pkgs/tools/typesetting/tikzit/default.nix
index 76b9b285d153e..29fd21ed31fe8 100644
--- a/pkgs/tools/typesetting/tikzit/default.nix
+++ b/pkgs/tools/typesetting/tikzit/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, qmake, qttools, qtbase, poppler, flex, bison }:
+{ lib, stdenv, mkDerivation, fetchFromGitHub, qmake, qttools, qtbase, poppler, flex, bison }:
 
 mkDerivation {
   pname = "tikzit";
@@ -17,7 +17,7 @@ mkDerivation {
   # src/data/tikzlexer.l:29:10: fatal error: tikzparser.parser.hpp: No such file or directory
   enableParallelBuilding = false;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A graphical tool for rapidly creating graphs and diagrams using PGF/TikZ";
     longDescription = ''
       TikZiT is a simple GUI editor for graphs and string diagrams.
diff --git a/pkgs/tools/typesetting/xmlroff/default.nix b/pkgs/tools/typesetting/xmlroff/default.nix
index eb026e5557ebb..d214b24b80b3c 100644
--- a/pkgs/tools/typesetting/xmlroff/default.nix
+++ b/pkgs/tools/typesetting/xmlroff/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , autoreconfHook
 , gtk2
 , libxml2
@@ -46,7 +46,7 @@ stdenv.mkDerivation rec {
     substituteInPlace Makefile --replace "docs" ""  # docs target wants to download from network
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "XSL Formatter";
     homepage = "http://xmlroff.org/";
     platforms = platforms.unix;
diff --git a/pkgs/tools/video/atomicparsley/default.nix b/pkgs/tools/video/atomicparsley/default.nix
index 2f7e4d97cbba9..7f3bdcb1bd661 100644
--- a/pkgs/tools/video/atomicparsley/default.nix
+++ b/pkgs/tools/video/atomicparsley/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, zlib, Cocoa }:
+{ lib, stdenv, fetchFromGitHub, cmake, zlib, Cocoa }:
 
 stdenv.mkDerivation rec {
   pname = "atomicparsley";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A CLI program for reading, parsing and setting metadata into MPEG-4 files";
     homepage = "https://github.com/wez/atomicparsley";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/video/bento4/default.nix b/pkgs/tools/video/bento4/default.nix
index 87585caebfb5b..d096f834ba1bf 100644
--- a/pkgs/tools/video/bento4/default.nix
+++ b/pkgs/tools/video/bento4/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake
 }:
 stdenv.mkDerivation rec {
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     find -maxdepth 1 -executable -type f -exec mv --target-directory="$out/bin" {} \;
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Full-featured MP4 format and MPEG DASH library and tools";
     homepage = "http://bento4.com";
     license = licenses.gpl2Plus;
diff --git a/pkgs/tools/video/dvgrab/default.nix b/pkgs/tools/video/dvgrab/default.nix
index 9077d34614df9..7f9be8bb616d2 100644
--- a/pkgs/tools/video/dvgrab/default.nix
+++ b/pkgs/tools/video/dvgrab/default.nix
@@ -1,4 +1,4 @@
-{ fetchFromGitHub, stdenv, libunwind, libraw1394, libjpeg, libiec61883, libdv
+{ fetchFromGitHub, lib, stdenv, libunwind, libraw1394, libjpeg, libiec61883, libdv
 , libavc1394, pkgconfig, autoreconfHook }:
 
 stdenv.mkDerivation {
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
     autoreconfHook pkgconfig
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Receive and store audio & video over IEEE1394";
 
     longDescription = ''
diff --git a/pkgs/tools/video/gopro/default.nix b/pkgs/tools/video/gopro/default.nix
index 9979b224868a1..9aa20a786dd29 100644
--- a/pkgs/tools/video/gopro/default.nix
+++ b/pkgs/tools/video/gopro/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , ffmpeg_3
 , imagemagick
 , makeWrapper
@@ -28,7 +28,7 @@ stdenv.mkDerivation rec {
     runHook postInstall
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Command line interface for processing media filmed on GoPro HERO 3, 4, 5, 6, and 7 cameras";
     homepage = "https://github.com/KonradIT/gopro-linux";
     platforms = platforms.linux;
diff --git a/pkgs/tools/video/mjpegtools/default.nix b/pkgs/tools/video/mjpegtools/default.nix
index 6c74aab957319..801d8c564c18e 100644
--- a/pkgs/tools/video/mjpegtools/default.nix
+++ b/pkgs/tools/video/mjpegtools/default.nix
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
 
   outputs = [ "out" "lib" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A suite of programs for processing MPEG or MJPEG video";
     homepage = "http://mjpeg.sourceforge.net/";
     license = licenses.gpl2;
diff --git a/pkgs/tools/video/svt-av1/default.nix b/pkgs/tools/video/svt-av1/default.nix
index c3d2de311b1f2..38c16fadcb820 100644
--- a/pkgs/tools/video/svt-av1/default.nix
+++ b/pkgs/tools/video/svt-av1/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, nasm }:
+{ lib, stdenv, fetchFromGitHub, cmake, nasm }:
 
 stdenv.mkDerivation rec {
   pname = "svt-av1";
@@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ cmake nasm ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "AV1-compliant encoder/decoder library core";
     homepage = "https://github.com/AOMediaCodec/SVT-AV1";
     license = licenses.bsd2;
diff --git a/pkgs/tools/video/untrunc-anthwlock/default.nix b/pkgs/tools/video/untrunc-anthwlock/default.nix
index 126952850936c..632f8c41463db 100644
--- a/pkgs/tools/video/untrunc-anthwlock/default.nix
+++ b/pkgs/tools/video/untrunc-anthwlock/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, ffmpeg, libui }:
+{ lib, stdenv, fetchFromGitHub, ffmpeg, libui }:
 
 stdenv.mkDerivation {
   pname = "untrunc-anthwlock";
@@ -26,7 +26,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Restore a truncated mp4/mov (improved version of ponchio/untrunc)";
     homepage = "https://github.com/anthwlock/untrunc";
     license = licenses.gpl2;
diff --git a/pkgs/tools/video/untrunc/default.nix b/pkgs/tools/video/untrunc/default.nix
index 1918f4e597456..3ef025f5875c4 100644
--- a/pkgs/tools/video/untrunc/default.nix
+++ b/pkgs/tools/video/untrunc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, gcc, libav_12, fetchFromGitHub }:
+{ lib, stdenv, gcc, libav_12, fetchFromGitHub }:
 
 stdenv.mkDerivation {
   pname = "untrunc";
@@ -30,7 +30,7 @@ stdenv.mkDerivation {
         -I$libavConfiguredSrc -lavformat -lavcodec -lavutil
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Restore a damaged (truncated) mp4, m4v, mov, 3gp video from a similar, undamaged video";
     license = licenses.gpl2;
     homepage = "https://github.com/ponchio/untrunc";
diff --git a/pkgs/tools/video/yamdi/default.nix b/pkgs/tools/video/yamdi/default.nix
index 28861887ed2a4..32620fe98c5ab 100644
--- a/pkgs/tools/video/yamdi/default.nix
+++ b/pkgs/tools/video/yamdi/default.nix
@@ -1,5 +1,5 @@
 {
-  stdenv,
+  lib, stdenv,
   fetchurl,
 }:
 
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
     install -D {,$out/share/man/}man1/yamdi.1
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Yet Another MetaData Injector for FLV";
     homepage = "http://yamdi.sourceforge.net/";
     license = licenses.bsd3;
diff --git a/pkgs/tools/virtualization/amazon-ecs-cli/default.nix b/pkgs/tools/virtualization/amazon-ecs-cli/default.nix
index bd63481054c33..012546160e091 100644
--- a/pkgs/tools/virtualization/amazon-ecs-cli/default.nix
+++ b/pkgs/tools/virtualization/amazon-ecs-cli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl}:
+{ lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "amazon-ecs-cli";
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
       chmod +x $out/bin/ecs-cli
     '';  # */
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ECS_CLI.html";
     description = "The Amazon ECS command line interface";
     longDescription = "The Amazon Elastic Container Service (Amazon ECS) command line interface (CLI) provides high-level commands to simplify creating, updating, and monitoring clusters and tasks from a local development environment.";
diff --git a/pkgs/tools/virtualization/awless/default.nix b/pkgs/tools/virtualization/awless/default.nix
index f051fd12ab3b6..3faf90ab4ac63 100644
--- a/pkgs/tools/virtualization/awless/default.nix
+++ b/pkgs/tools/virtualization/awless/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage rec {
   pname = "awless";
@@ -13,7 +13,7 @@ buildGoPackage rec {
     sha256 = "187i21yrm10r3f5naj3jl0rmydr5dkhmdhxs90hhf8hjp59a89kg";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/wallix/awless/";
     description = "A Mighty CLI for AWS";
     platforms = with platforms; linux ++ darwin;
diff --git a/pkgs/tools/virtualization/awsebcli/default.nix b/pkgs/tools/virtualization/awsebcli/default.nix
index 00f8ed89a2bfb..fa8e96def24a1 100644
--- a/pkgs/tools/virtualization/awsebcli/default.nix
+++ b/pkgs/tools/virtualization/awsebcli/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, python3, glibcLocales }:
+{ lib, stdenv, python3, glibcLocales }:
 let
 
   localPython = python3.override {
@@ -87,7 +87,7 @@ in with localPython.pkgs; buildPythonApplication rec {
     mv $out/bin/eb_completion.bash $out/share/bash-completion/completions/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://aws.amazon.com/elasticbeanstalk/";
     description = "A command line interface for Elastic Beanstalk";
     maintainers = with maintainers; [ eqyiel ];
diff --git a/pkgs/tools/virtualization/distrobuilder/default.nix b/pkgs/tools/virtualization/distrobuilder/default.nix
index 6ad8c355ee299..ccdd80fb37c5a 100644
--- a/pkgs/tools/virtualization/distrobuilder/default.nix
+++ b/pkgs/tools/virtualization/distrobuilder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, pkgconfig, buildGoPackage, fetchFromGitHub
+{ lib, stdenv, pkgconfig, buildGoPackage, fetchFromGitHub
 , makeWrapper, coreutils, gnupg, gnutar, squashfsTools, debootstrap
 }:
 
@@ -27,7 +27,7 @@ buildGoPackage rec {
   '';
   nativeBuildInputs = [ pkgconfig makeWrapper ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "System container image builder for LXC and LXD";
     homepage = "https://github.com/lxc/distrobuilder";
     license = licenses.asl20;
diff --git a/pkgs/tools/virtualization/google-compute-engine-oslogin/default.nix b/pkgs/tools/virtualization/google-compute-engine-oslogin/default.nix
index ea58eb4c6b837..4d34cd50b1e78 100644
--- a/pkgs/tools/virtualization/google-compute-engine-oslogin/default.nix
+++ b/pkgs/tools/virtualization/google-compute-engine-oslogin/default.nix
@@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
     inherit (nixosTests) google-oslogin;
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/GoogleCloudPlatform/compute-image-packages";
     description = "OS Login Guest Environment for Google Compute Engine";
     license = licenses.asl20;
diff --git a/pkgs/tools/virtualization/marathonctl/default.nix b/pkgs/tools/virtualization/marathonctl/default.nix
index 20b461fa34659..6f036795e7201 100644
--- a/pkgs/tools/virtualization/marathonctl/default.nix
+++ b/pkgs/tools/virtualization/marathonctl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoPackage, fetchFromGitHub }:
+{ lib, stdenv, buildGoPackage, fetchFromGitHub }:
 
 buildGoPackage {
   pname = "marathonctl-unstable";
@@ -15,7 +15,7 @@ buildGoPackage {
     sha256 = "1fcc54hwpa8s3kz4gn26mc6nrv6zjrw869331nvm47khi23gpmxw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/shoenig/marathonctl";
     description = "CLI tool for Marathon";
     license = licenses.mit;
diff --git a/pkgs/tools/virtualization/nixos-shell/default.nix b/pkgs/tools/virtualization/nixos-shell/default.nix
index d529986c5d467..f0657f4638b16 100644
--- a/pkgs/tools/virtualization/nixos-shell/default.nix
+++ b/pkgs/tools/virtualization/nixos-shell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, nix, fetchFromGitHub, makeWrapper }:
+{ lib, stdenv, nix, fetchFromGitHub, makeWrapper }:
 
 stdenv.mkDerivation rec {
   pname = "nixos-shell";
@@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
 
   installFlags = [ "PREFIX=${placeholder "out"}" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Spawns lightweight nixos vms in a shell";
     inherit (src.meta) homepage;
     license = licenses.mit;
diff --git a/pkgs/tools/virtualization/udocker/default.nix b/pkgs/tools/virtualization/udocker/default.nix
index 00771b9175015..c971dfcb1bd0c 100644
--- a/pkgs/tools/virtualization/udocker/default.nix
+++ b/pkgs/tools/virtualization/udocker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, proot, patchelf, fakechroot, runc, simplejson, pycurl, coreutils, nose, mock, buildPythonApplication }:
+{ lib, stdenv, fetchFromGitHub, proot, patchelf, fakechroot, runc, simplejson, pycurl, coreutils, nose, mock, buildPythonApplication }:
 
 buildPythonApplication rec {
 
@@ -31,7 +31,7 @@ buildPythonApplication rec {
     NOSE_EXCLUDE=test_03_create_repo,test_04_is_repo,test_02__get_group_from_host nosetests -v tests/unit_tests.py
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "basic user tool to execute simple docker containers in user space without root privileges";
     homepage = "https://indigo-dc.gitbooks.io/udocker";
     license = licenses.asl20;
diff --git a/pkgs/tools/wayland/wayland-utils/default.nix b/pkgs/tools/wayland/wayland-utils/default.nix
index 23629309e52e3..5c07081099c6d 100644
--- a/pkgs/tools/wayland/wayland-utils/default.nix
+++ b/pkgs/tools/wayland/wayland-utils/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , meson, pkg-config, ninja
 , wayland, wayland-protocols
 }:
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson pkg-config ninja wayland ];
   buildInputs = [ wayland wayland-protocols ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Wayland utilities (wayland-info)";
     longDescription = ''
       A collection of Wayland related utilities:
diff --git a/pkgs/tools/wayland/wlsunset/default.nix b/pkgs/tools/wayland/wlsunset/default.nix
index 2993f990aad57..692ddd37cf392 100644
--- a/pkgs/tools/wayland/wlsunset/default.nix
+++ b/pkgs/tools/wayland/wlsunset/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, meson, pkg-config, ninja, wayland
+{ lib, stdenv, fetchurl, meson, pkg-config, ninja, wayland
 , wayland-protocols
 }:
 
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson pkg-config ninja wayland ];
   buildInputs = [ wayland wayland-protocols ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Day/night gamma adjustments for Wayland";
     longDescription = ''
       Day/night gamma adjustments for Wayland compositors supporting
diff --git a/pkgs/tools/wayland/wshowkeys/default.nix b/pkgs/tools/wayland/wshowkeys/default.nix
index 0db02990c036d..1c095ca297a64 100644
--- a/pkgs/tools/wayland/wshowkeys/default.nix
+++ b/pkgs/tools/wayland/wshowkeys/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl
+{ lib, stdenv, fetchurl
 , meson, pkg-config, wayland, ninja
 , cairo, libinput, pango, wayland-protocols, libxkbcommon
 }:
@@ -18,7 +18,7 @@ in stdenv.mkDerivation rec {
   nativeBuildInputs = [ meson pkg-config wayland ninja ];
   buildInputs = [ cairo libinput pango wayland-protocols libxkbcommon ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Displays keys being pressed on a Wayland session";
     longDescription = ''
       Displays keypresses on screen on supported Wayland compositors (requires
diff --git a/pkgs/tools/wayland/ydotool/default.nix b/pkgs/tools/wayland/ydotool/default.nix
index d8b6ad4ff87c0..eaa93daf3cf85 100644
--- a/pkgs/tools/wayland/ydotool/default.nix
+++ b/pkgs/tools/wayland/ydotool/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, cmake, boost, libevdevplus, libuinputplus }:
+{ lib, stdenv, fetchFromGitHub, pkgconfig, cmake, boost, libevdevplus, libuinputplus }:
 
 stdenv.mkDerivation rec {
   pname = "ydotool";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     boost libevdevplus libuinputplus
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     inherit (src.meta) homepage;
     description = "Generic Linux command-line automation tool";
     license = licenses.mit;