about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/tools/misc
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/tools/misc')
-rw-r--r--nixpkgs/pkgs/development/tools/misc/abi-compliance-checker/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/abi-dumper/default.nix33
-rw-r--r--nixpkgs/pkgs/development/tools/misc/act/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/arcanist/default.nix67
-rw-r--r--nixpkgs/pkgs/development/tools/misc/argbash/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/asls/default.nix25
-rw-r--r--nixpkgs/pkgs/development/tools/misc/astyle/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/autobuild/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/autoconf-archive/default.nix20
-rw-r--r--nixpkgs/pkgs/development/tools/misc/autoconf/2.13.nix40
-rw-r--r--nixpkgs/pkgs/development/tools/misc/autoconf/2.64.nix51
-rw-r--r--nixpkgs/pkgs/development/tools/misc/autoconf/2.69.nix52
-rw-r--r--nixpkgs/pkgs/development/tools/misc/autoconf/default.nix55
-rw-r--r--nixpkgs/pkgs/development/tools/misc/autogen/default.nix96
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/automake-1.11.x.nix49
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/automake-1.15.x.nix45
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/automake-1.16.x.nix43
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/builder.sh47
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/fix-perl-5.26.patch10
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/fix-test-autoconf-2.69.patch13
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/help2man-SOURCE_DATE_EPOCH-support.patch41
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automake/setup-hook.sh5
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automaticcomponenttoolkit/default.nix33
-rw-r--r--nixpkgs/pkgs/development/tools/misc/automoc4/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/avrdude/default.nix33
-rw-r--r--nixpkgs/pkgs/development/tools/misc/awf/default.nix37
-rw-r--r--nixpkgs/pkgs/development/tools/misc/babeltrace/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bashdb/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bin_replace_string/default.nix31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/CVE-2020-35448.patch77
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/R_ARM_COPY.patch29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/always-search-rpath.patch14
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/build-components-separately.patch164
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/default.nix177
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/deterministic.patch12
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/disambiguate-arm-targets.patch23
-rw-r--r--nixpkgs/pkgs/development/tools/misc/binutils/support-ios.patch168
-rw-r--r--nixpkgs/pkgs/development/tools/misc/blackfire/default.nix52
-rw-r--r--nixpkgs/pkgs/development/tools/misc/blackfire/php-probe.nix64
-rw-r--r--nixpkgs/pkgs/development/tools/misc/blackmagic/default.nix78
-rwxr-xr-xnixpkgs/pkgs/development/tools/misc/blackmagic/helper.sh52
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bonnmotion/default.nix50
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bonnmotion/install.patch75
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bossa/bin2c.c122
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bossa/bossa-no-applet-build.patch16
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bossa/default.nix52
-rw-r--r--nixpkgs/pkgs/development/tools/misc/bsdbuild/default.nix68
-rw-r--r--nixpkgs/pkgs/development/tools/misc/c2ffi/default.nix56
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cbrowser/backslashes-quotes.diff49
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cbrowser/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cc-tool/default.nix42
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ccache/default.nix115
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ccache/force-objdump-on-darwin.patch31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ccls/default.nix41
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ccls/wrapper9
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cflow/default.nix50
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cgdb/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/checkbashisms/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/chrpath/default.nix23
-rw-r--r--nixpkgs/pkgs/development/tools/misc/chruby-fish/default.nix28
-rw-r--r--nixpkgs/pkgs/development/tools/misc/chruby/default.nix45
-rw-r--r--nixpkgs/pkgs/development/tools/misc/chruby/env.patch12
-rw-r--r--nixpkgs/pkgs/development/tools/misc/circleci-cli/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cl-launch/default.nix38
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cl-launch/default.upstream2
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cli11/default.nix41
-rw-r--r--nixpkgs/pkgs/development/tools/misc/clojure-lsp/default.nix61
-rw-r--r--nixpkgs/pkgs/development/tools/misc/clojure-lsp/disable-check-toolchain.patch12
-rw-r--r--nixpkgs/pkgs/development/tools/misc/coccinelle/default.nix41
-rw-r--r--nixpkgs/pkgs/development/tools/misc/complexity/default.nix32
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cppi/default.nix31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cproto/cproto.patch11
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cproto/default.nix34
-rw-r--r--nixpkgs/pkgs/development/tools/misc/creduce/default.nix54
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cscope/default.nix53
-rw-r--r--nixpkgs/pkgs/development/tools/misc/csmith/default.nix49
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ctags/default.nix43
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ctags/unused-collision.patch246
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ctags/wrapped.nix78
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cvise/default.nix46
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cvise/unifdef.patch8
-rw-r--r--nixpkgs/pkgs/development/tools/misc/cwebbin/default.nix59
-rw-r--r--nixpkgs/pkgs/development/tools/misc/d-feet/default.nix82
-rw-r--r--nixpkgs/pkgs/development/tools/misc/dbench/default.nix45
-rw-r--r--nixpkgs/pkgs/development/tools/misc/dbench/fix-missing-stdint.patch10
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ddd/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ddd/gcc44.patch11
-rw-r--r--nixpkgs/pkgs/development/tools/misc/dejagnu/default.nix54
-rw-r--r--nixpkgs/pkgs/development/tools/misc/dfu-programmer/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/dfu-util/default.nix31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/direvent/default.nix21
-rw-r--r--nixpkgs/pkgs/development/tools/misc/distcc/default.nix84
-rw-r--r--nixpkgs/pkgs/development/tools/misc/distcc/masq.nix44
-rw-r--r--nixpkgs/pkgs/development/tools/misc/doclifter/default.nix28
-rw-r--r--nixpkgs/pkgs/development/tools/misc/docopts/default.nix31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/docopts/deps.nix11
-rw-r--r--nixpkgs/pkgs/development/tools/misc/drush/default.nix38
-rw-r--r--nixpkgs/pkgs/development/tools/misc/easypdkprog/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/edb/default.nix42
-rw-r--r--nixpkgs/pkgs/development/tools/misc/editorconfig-checker/default.nix32
-rw-r--r--nixpkgs/pkgs/development/tools/misc/editorconfig-core-c/default.nix38
-rw-r--r--nixpkgs/pkgs/development/tools/misc/eggdbus/default.nix20
-rw-r--r--nixpkgs/pkgs/development/tools/misc/elfinfo/default.nix21
-rw-r--r--nixpkgs/pkgs/development/tools/misc/elfkickers/default.nix23
-rw-r--r--nixpkgs/pkgs/development/tools/misc/elfutils/debug-info-from-env.patch27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/elfutils/default.nix106
-rw-r--r--nixpkgs/pkgs/development/tools/misc/elfutils/musl-cdefs_h.patch15
-rw-r--r--nixpkgs/pkgs/development/tools/misc/elfutils/musl-error_h.patch66
-rw-r--r--nixpkgs/pkgs/development/tools/misc/epm/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/findnewest/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/fsatrace/default.nix34
-rw-r--r--nixpkgs/pkgs/development/tools/misc/fswatch/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/fujprog/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gdb/darwin-target-match.patch11
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gdb/debug-info-from-env.patch24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gdb/default.nix118
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gdbgui/default.nix96
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gede/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gengetopt/default.nix45
-rw-r--r--nixpkgs/pkgs/development/tools/misc/global/default.nix61
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gnum4/darwin-secure-format.patch15
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gnum4/default.nix56
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gnum4/s_isdir.patch14
-rw-r--r--nixpkgs/pkgs/development/tools/misc/go-license-detector/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/go-md2man/default.nix23
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gob2/default.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gperf/3.0.x.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gperf/default.nix33
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gperf/gperf-ar-fix.patch46
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gpshell/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gputils/default.nix19
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gpuvis/default.nix42
-rw-r--r--nixpkgs/pkgs/development/tools/misc/grpc-tools/default.nix40
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gtkdialog/default.nix21
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gtkperf/bench.patch60
-rw-r--r--nixpkgs/pkgs/development/tools/misc/gtkperf/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/help2man/1.40.4-cygwin-nls.patch165
-rw-r--r--nixpkgs/pkgs/development/tools/misc/help2man/default.nix51
-rw-r--r--nixpkgs/pkgs/development/tools/misc/hound/default.nix38
-rw-r--r--nixpkgs/pkgs/development/tools/misc/hydra-cli/default.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/hydra/common.nix140
-rw-r--r--nixpkgs/pkgs/development/tools/misc/hydra/default.nix18
-rw-r--r--nixpkgs/pkgs/development/tools/misc/icon-naming-utils/default.nix18
-rw-r--r--nixpkgs/pkgs/development/tools/misc/igprof/default.nix43
-rw-r--r--nixpkgs/pkgs/development/tools/misc/indent/darwin.patch15
-rw-r--r--nixpkgs/pkgs/development/tools/misc/indent/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/inotify-tools/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/intel-gpu-tools/default.nix43
-rw-r--r--nixpkgs/pkgs/development/tools/misc/intltool/default.nix37
-rw-r--r--nixpkgs/pkgs/development/tools/misc/iozone/default.nix62
-rw-r--r--nixpkgs/pkgs/development/tools/misc/itm-tools/cargo-lock.patch321
-rw-r--r--nixpkgs/pkgs/development/tools/misc/itm-tools/default.nix28
-rw-r--r--nixpkgs/pkgs/development/tools/misc/itstool/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/jiq/default.nix31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/jscoverage/default.nix54
-rw-r--r--nixpkgs/pkgs/development/tools/misc/jscoverage/jsfalse_to_null.patch26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/k2tf/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/kconfig-frontends/default.nix37
-rw-r--r--nixpkgs/pkgs/development/tools/misc/kdbg/default.nix33
-rw-r--r--nixpkgs/pkgs/development/tools/misc/kibana/6.x.nix63
-rw-r--r--nixpkgs/pkgs/development/tools/misc/kibana/7.x.nix63
-rw-r--r--nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check-7.patch19
-rw-r--r--nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check.patch19
-rw-r--r--nixpkgs/pkgs/development/tools/misc/libtool/default.nix41
-rw-r--r--nixpkgs/pkgs/development/tools/misc/libtool/libtool2-macos11.patch32
-rw-r--r--nixpkgs/pkgs/development/tools/misc/libtool/libtool2.nix69
-rw-r--r--nixpkgs/pkgs/development/tools/misc/libwhich/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/linuxkit/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/lit/default.nix25
-rw-r--r--nixpkgs/pkgs/development/tools/misc/loccount/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/lsof/default.nix58
-rw-r--r--nixpkgs/pkgs/development/tools/misc/lsof/no-build-info.patch43
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ltrace/default.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/lttng-tools/default.nix23
-rw-r--r--nixpkgs/pkgs/development/tools/misc/lttng-ust/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/lttv/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/luarocks/darwin-3.1.3.patch24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/luarocks/default.nix79
-rw-r--r--nixpkgs/pkgs/development/tools/misc/luarocks/default.upstream1
-rw-r--r--nixpkgs/pkgs/development/tools/misc/luarocks/luarocks-nix.nix11
-rw-r--r--nixpkgs/pkgs/development/tools/misc/luarocks/setup-hook.sh16
-rw-r--r--nixpkgs/pkgs/development/tools/misc/macdylibbundler/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/mdctags/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/mdl/Gemfile3
-rw-r--r--nixpkgs/pkgs/development/tools/misc/mdl/Gemfile.lock30
-rw-r--r--nixpkgs/pkgs/development/tools/misc/mdl/default.nix17
-rw-r--r--nixpkgs/pkgs/development/tools/misc/mdl/gemset.nix97
-rw-r--r--nixpkgs/pkgs/development/tools/misc/micronucleus/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/mkcert/default.nix28
-rw-r--r--nixpkgs/pkgs/development/tools/misc/msitools/default.nix87
-rw-r--r--nixpkgs/pkgs/development/tools/misc/nimlsp/default.nix48
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ninka/default.nix36
-rw-r--r--nixpkgs/pkgs/development/tools/misc/nix-build-uncached/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/nixbang/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/nrfutil/default.nix30
-rw-r--r--nixpkgs/pkgs/development/tools/misc/nxpmicro-mfgtools/default.nix54
-rw-r--r--nixpkgs/pkgs/development/tools/misc/objconv/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile2
-rw-r--r--nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile.lock17
-rw-r--r--nixpkgs/pkgs/development/tools/misc/one_gadget/default.nix17
-rw-r--r--nixpkgs/pkgs/development/tools/misc/one_gadget/gemset.nix34
-rw-r--r--nixpkgs/pkgs/development/tools/misc/openfpgaloader/default.nix36
-rw-r--r--nixpkgs/pkgs/development/tools/misc/opengrok/default.nix32
-rw-r--r--nixpkgs/pkgs/development/tools/misc/openocd/default.nix66
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pahole/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/patchelf/0.9.nix16
-rw-r--r--nixpkgs/pkgs/development/tools/misc/patchelf/default.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/patchelf/setup-hook.sh22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/patchelf/unstable.nix34
-rw-r--r--nixpkgs/pkgs/development/tools/misc/perfect-hash/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pkg-config/2.36.3-not-win32.patch324
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pkg-config/default.nix50
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pkg-config/requires-private.patch17
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pkgconf/default.nix46
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pmccabe/default.nix48
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pmccabe/getopt_on_darwin.patch15
-rw-r--r--nixpkgs/pkgs/development/tools/misc/polylith/default.nix49
-rw-r--r--nixpkgs/pkgs/development/tools/misc/prelink/default.nix25
-rw-r--r--nixpkgs/pkgs/development/tools/misc/premake/3.nix30
-rw-r--r--nixpkgs/pkgs/development/tools/misc/premake/5.nix43
-rw-r--r--nixpkgs/pkgs/development/tools/misc/premake/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/premake/setup-hook.sh19
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ptags/default.nix41
-rw-r--r--nixpkgs/pkgs/development/tools/misc/pwndbg/default.nix52
-rw-r--r--nixpkgs/pkgs/development/tools/misc/remarkable/remarkable-toolchain/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/remarkable/remarkable2-toolchain/default.nix39
-rw-r--r--nixpkgs/pkgs/development/tools/misc/replacement/default.nix46
-rw-r--r--nixpkgs/pkgs/development/tools/misc/reviewdog/default.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/rman/default.nix33
-rw-r--r--nixpkgs/pkgs/development/tools/misc/rolespec/default.nix49
-rw-r--r--nixpkgs/pkgs/development/tools/misc/rtss/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/saleae-logic/default.nix97
-rw-r--r--nixpkgs/pkgs/development/tools/misc/saleae-logic/preload.c341
-rw-r--r--nixpkgs/pkgs/development/tools/misc/scc/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/sccache/default.nix31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/segger-ozone/default.nix84
-rw-r--r--nixpkgs/pkgs/development/tools/misc/semver-tool/default.nix32
-rw-r--r--nixpkgs/pkgs/development/tools/misc/sipp/default.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/sloccount/default.nix72
-rw-r--r--nixpkgs/pkgs/development/tools/misc/sqitch/default.nix46
-rw-r--r--nixpkgs/pkgs/development/tools/misc/srecord/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/stlink/default.nix53
-rw-r--r--nixpkgs/pkgs/development/tools/misc/stm32cubemx/default.nix71
-rw-r--r--nixpkgs/pkgs/development/tools/misc/stm32flash/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/strace/default.nix30
-rw-r--r--nixpkgs/pkgs/development/tools/misc/svls/default.nix25
-rw-r--r--nixpkgs/pkgs/development/tools/misc/swig/2.x.nix35
-rw-r--r--nixpkgs/pkgs/development/tools/misc/swig/3.x.nix36
-rw-r--r--nixpkgs/pkgs/development/tools/misc/swig/4.nix37
-rw-r--r--nixpkgs/pkgs/development/tools/misc/swig/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/sysbench/default.nix27
-rw-r--r--nixpkgs/pkgs/development/tools/misc/tcptrack/default.nix25
-rw-r--r--nixpkgs/pkgs/development/tools/misc/teensy-loader-cli/default.nix31
-rw-r--r--nixpkgs/pkgs/development/tools/misc/terracognita/default.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/terraform-ls/default.nix46
-rw-r--r--nixpkgs/pkgs/development/tools/misc/terraform-lsp/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/terraformer/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/tet/default.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texi2html/default.nix34
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texinfo/4.13a.nix19
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texinfo/5.2.nix4
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texinfo/6.5.nix4
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texinfo/6.7.nix4
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texinfo/common.nix81
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texinfo/cross-tools-flags.patch13
-rw-r--r--nixpkgs/pkgs/development/tools/misc/texlab/default.nix48
-rw-r--r--nixpkgs/pkgs/development/tools/misc/tie/default.nix28
-rw-r--r--nixpkgs/pkgs/development/tools/misc/tinyprog/default.nix43
-rw-r--r--nixpkgs/pkgs/development/tools/misc/tockloader/default.nix37
-rw-r--r--nixpkgs/pkgs/development/tools/misc/tokei/default.nix32
-rw-r--r--nixpkgs/pkgs/development/tools/misc/travis/Gemfile4
-rw-r--r--nixpkgs/pkgs/development/tools/misc/travis/Gemfile.lock71
-rw-r--r--nixpkgs/pkgs/development/tools/misc/travis/default.nix16
-rw-r--r--nixpkgs/pkgs/development/tools/misc/travis/gemset.nix269
-rw-r--r--nixpkgs/pkgs/development/tools/misc/travis/shell.nix11
-rw-r--r--nixpkgs/pkgs/development/tools/misc/uisp/default.nix19
-rw-r--r--nixpkgs/pkgs/development/tools/misc/uncrustify/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/unifdef/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/universal-ctags/default.nix50
-rw-r--r--nixpkgs/pkgs/development/tools/misc/universal-ctags/sed-test.patch12
-rw-r--r--nixpkgs/pkgs/development/tools/misc/unused/default.nix23
-rw-r--r--nixpkgs/pkgs/development/tools/misc/usb-modeswitch/configurable-usb-modeswitch.patch283
-rw-r--r--nixpkgs/pkgs/development/tools/misc/usb-modeswitch/data.nix29
-rw-r--r--nixpkgs/pkgs/development/tools/misc/usb-modeswitch/default.nix46
-rw-r--r--nixpkgs/pkgs/development/tools/misc/usbsdmux/default.nix22
-rw-r--r--nixpkgs/pkgs/development/tools/misc/vtable-dumper/default.nix24
-rw-r--r--nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile2
-rw-r--r--nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile.lock15
-rw-r--r--nixpkgs/pkgs/development/tools/misc/watson-ruby/default.nix30
-rw-r--r--nixpkgs/pkgs/development/tools/misc/watson-ruby/gemset.nix18
-rw-r--r--nixpkgs/pkgs/development/tools/misc/whatstyle/default.nix30
-rw-r--r--nixpkgs/pkgs/development/tools/misc/wishbone-tool/default.nix33
-rw-r--r--nixpkgs/pkgs/development/tools/misc/xc3sprog/default.nix26
-rw-r--r--nixpkgs/pkgs/development/tools/misc/xxdiff/default.nix51
-rw-r--r--nixpkgs/pkgs/development/tools/misc/ycmd/default.nix100
-rw-r--r--nixpkgs/pkgs/development/tools/misc/yodl/default.nix52
296 files changed, 13000 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/tools/misc/abi-compliance-checker/default.nix b/nixpkgs/pkgs/development/tools/misc/abi-compliance-checker/default.nix
new file mode 100644
index 000000000000..c4dda95a7f25
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/abi-compliance-checker/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchFromGitHub, ctags, perl, binutils, abi-dumper }:
+
+stdenv.mkDerivation rec {
+  pname = "abi-compliance-checker";
+  version = "2.3";
+
+  src = fetchFromGitHub {
+    owner = "lvc";
+    repo = "abi-compliance-checker";
+    rev = version;
+    sha256 = "1f1f9j2nf9j83sfl2ljadch99v6ha8rq8xm7ax5akc05hjpyckij";
+  };
+
+  buildInputs = [ binutils ctags perl ];
+  propagatedBuildInputs = [ abi-dumper ];
+
+  makeFlags = [ "prefix=$(out)" ];
+
+  meta = with lib; {
+    homepage = "https://lvc.github.io/abi-compliance-checker";
+    description = "A tool for checking backward API/ABI compatibility of a C/C++ library";
+    license = licenses.lgpl21;
+    maintainers = [ maintainers.bhipple ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/abi-dumper/default.nix b/nixpkgs/pkgs/development/tools/misc/abi-dumper/default.nix
new file mode 100644
index 000000000000..6dd2bf41ba6f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/abi-dumper/default.nix
@@ -0,0 +1,33 @@
+{ lib, stdenv, fetchFromGitHub, ctags, perl, elfutils, vtable-dumper }:
+
+stdenv.mkDerivation rec {
+  pname = "abi-dumper";
+  version = "1.2";
+
+  src = fetchFromGitHub {
+    owner = "lvc";
+    repo = "abi-dumper";
+    rev = version;
+    sha256 = "1i00rfnddrrb9lb1l6ib19g3a76pyasl9lb7rqz2p998gav1gjp2";
+  };
+
+  patchPhase = ''
+    substituteInPlace abi-dumper.pl \
+      --replace eu-readelf ${elfutils}/bin/eu-readelf \
+      --replace vtable-dumper ${vtable-dumper}/bin/vtable-dumper \
+      --replace '"ctags"' '"${ctags}/bin/ctags"'
+  '';
+
+  buildInputs = [ elfutils ctags perl vtable-dumper ];
+
+  preBuild = "mkdir -p $out";
+  makeFlags = [ "prefix=$(out)" ];
+
+  meta = with lib; {
+    homepage = "https://github.com/lvc/abi-dumper";
+    description = "Dump ABI of an ELF object containing DWARF debug info";
+    license = licenses.lgpl21;
+    maintainers = [ maintainers.bhipple ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/act/default.nix b/nixpkgs/pkgs/development/tools/misc/act/default.nix
new file mode 100644
index 000000000000..38520b4b3e56
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/act/default.nix
@@ -0,0 +1,27 @@
+{ lib, fetchFromGitHub, buildGoModule }:
+
+buildGoModule rec {
+  pname = "act";
+  version = "0.2.23";
+
+  src = fetchFromGitHub {
+    owner = "nektos";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-PBhlBWycAYuczfP0D+Gf1pDvrfI9gz3JyGe5FBq782Y=";
+  };
+
+  vendorSha256 = "sha256-dLIsVWN/PjcH0CUYRmn4YaF8Pczf/gaWhD3lulqGiuA=";
+
+  doCheck = false;
+
+  buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version}" ];
+
+  meta = with lib; {
+    description = "Run your GitHub Actions locally";
+    homepage = "https://github.com/nektos/act";
+    changelog = "https://github.com/nektos/act/releases/tag/v${version}";
+    license = licenses.mit;
+    maintainers = with maintainers; [ Br1ght0ne SuperSandro2000 ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/arcanist/default.nix b/nixpkgs/pkgs/development/tools/misc/arcanist/default.nix
new file mode 100644
index 000000000000..a5a9d724a79e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/arcanist/default.nix
@@ -0,0 +1,67 @@
+{ bison
+, fetchFromGitHub
+, flex
+, php
+, lib, stdenv
+}:
+
+# Make a custom wrapper. If `wrapProgram` is used, arcanist thinks .arc-wrapped is being
+# invoked and complains about it being an unknown toolset. We could use `makeWrapper`, but
+# then we’d need to still craft a script that does the `php libexec/arcanist/bin/...` dance
+# anyway... So just do everything at once.
+let makeArcWrapper = toolset: ''
+  cat << WRAPPER > $out/bin/${toolset}
+  #!$shell -e
+  export PATH='${php}/bin/'\''${PATH:+':'}\$PATH
+  exec ${php}/bin/php $out/libexec/arcanist/bin/${toolset} "\$@"
+  WRAPPER
+  chmod +x $out/bin/${toolset}
+'';
+
+in
+stdenv.mkDerivation {
+  pname = "arcanist";
+  version = "20200711";
+
+  src = fetchFromGitHub {
+    owner = "phacility";
+    repo = "arcanist";
+    rev = "2565cc7b4d1dbce6bc7a5b3c4e72ae94be4712fe";
+    sha256 = "0jiv4aj4m5750dqw9r8hizjkwiyxk4cg4grkr63sllsa2dpiibxw";
+  };
+  buildInputs = [ bison flex php ];
+
+  postPatch = lib.optionalString stdenv.isAarch64 ''
+    substituteInPlace support/xhpast/Makefile \
+      --replace "-minline-all-stringops" ""
+  '';
+
+  buildPhase = ''
+    make cleanall -C support/xhpast
+    make xhpast -C support/xhpast
+  '';
+
+  installPhase = ''
+    mkdir -p $out/bin $out/libexec
+    make install -C support/xhpast
+    make cleanall -C support/xhpast
+    cp -R . $out/libexec/arcanist
+
+    ${makeArcWrapper "arc"}
+    ${makeArcWrapper "phage"}
+  '';
+
+  doInstallCheck = true;
+  installCheckPhase = ''
+    $out/bin/arc help diff -- > /dev/null
+    $out/bin/phage help alias -- > /dev/null
+  '';
+
+  meta = {
+    description = "Command line interface to Phabricator";
+    homepage = "http://phabricator.org";
+    license = lib.licenses.asl20;
+    platforms = lib.platforms.unix;
+    maintainers = [ lib.maintainers.thoughtpolice ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/argbash/default.nix b/nixpkgs/pkgs/development/tools/misc/argbash/default.nix
new file mode 100644
index 000000000000..571050508146
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/argbash/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv, fetchFromGitHub, autoconf, runtimeShell, python3Packages, makeWrapper }:
+
+stdenv.mkDerivation rec {
+  pname = "argbash";
+
+  version = "2.10.0";
+
+  src = fetchFromGitHub {
+    owner = "matejak";
+    repo = "argbash";
+    rev = version;
+    sha256 = "1xdhpbnc0xjv6ydcm122hhdjcl77jhiqnccjfqjp3cd1lfmzvg8v";
+  };
+
+  sourceRoot = "source/resources";
+
+  postPatch = ''
+    chmod -R +w ..
+    patchShebangs ..
+    substituteInPlace Makefile \
+      --replace '/bin/bash' "${runtimeShell}"
+  '';
+
+  nativeBuildInputs = [ autoconf python3Packages.docutils makeWrapper ];
+
+  makeFlags = [ "PREFIX=$(out)" ];
+
+  postInstall = ''
+    wrapProgram $out/bin/argbash \
+      --prefix PATH : '${autoconf}/bin'
+  '';
+
+  meta = with lib; {
+    description = "Bash argument parsing code generator";
+    homepage = "https://argbash.io/";
+    license = licenses.free; # custom license.  See LICENSE in source repo.
+    maintainers = with maintainers; [ rencire ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/asls/default.nix b/nixpkgs/pkgs/development/tools/misc/asls/default.nix
new file mode 100644
index 000000000000..bccda0185036
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/asls/default.nix
@@ -0,0 +1,25 @@
+{ lib, stdenv
+, fetchurl
+, erlangR22
+}:
+
+stdenv.mkDerivation rec {
+  pname = "asls";
+  version = "0.5.1";
+
+  src = fetchurl {
+    url = "https://github.com/saulecabrera/asls/releases/download/v${version}/bin.tar.gz";
+    sha256 = "05kp44p4q4sdykfw0b4k9j3qdp0qvwgjbs48ncmnd0ass0xrmi3s";
+  };
+
+  buildInputs = [ erlangR22 ];
+  installPhase = "install -Dm755 -t $out/bin asls";
+
+  meta = with lib; {
+    description = "AssemblyScript Language Server";
+    homepage = "https://github.com/saulecabrera/asls";
+    license = licenses.mit;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ saulecabrera ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/astyle/default.nix b/nixpkgs/pkgs/development/tools/misc/astyle/default.nix
new file mode 100644
index 000000000000..66e972826cb9
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/astyle/default.nix
@@ -0,0 +1,26 @@
+{ stdenv, lib, fetchurl, cmake }:
+
+stdenv.mkDerivation rec {
+  pname = "astyle";
+  version = "3.1";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/${pname}/${pname}_${version}_linux.tar.gz";
+    sha256 = "1ms54wcs7hg1bsywqwf2lhdfizgbk7qxc9ghasxk8i99jvwlrk6b";
+  };
+
+  # lots of hardcoded references to /usr
+  postPatch = ''
+    substituteInPlace CMakeLists.txt \
+      --replace ' /usr/' " $out/"
+  '';
+
+  nativeBuildInputs = [ cmake ];
+
+  meta = with lib; {
+    description = "Source code indenter, formatter, and beautifier for C, C++, C# and Java";
+    homepage = "https://astyle.sourceforge.net/";
+    license = licenses.lgpl3;
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/autobuild/default.nix b/nixpkgs/pkgs/development/tools/misc/autobuild/default.nix
new file mode 100644
index 000000000000..186608cde3f1
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/autobuild/default.nix
@@ -0,0 +1,35 @@
+{ fetchurl, lib, stdenv, makeWrapper, perl, openssh, rsync }:
+
+stdenv.mkDerivation rec {
+  name = "autobuild-5.3";
+
+  src = fetchurl {
+    url = "http://savannah.spinellicreations.com/autobuild/${name}.tar.gz";
+    sha256 = "0gv7g61ja9q9zg1m30k4snqwwy1kq7b4df6sb7d2qra7kbdq8af1";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+  buildInputs = [ perl openssh rsync ];
+
+  doCheck = true;
+
+  meta = {
+    description = "Continuous integration tool";
+
+    longDescription = ''
+      Autobuild is a package that process output from building
+      software, primarily focused on packages using Autoconf and
+      Automake, and then generate a HTML summary file, containing
+      links to each build log.
+
+      Autobuild can also help you automate building your project on
+      many systems concurrently.  Users with accounts on the
+      SourceForge compile farms will be able to invoke a parallel
+      build of their Autoconf/Automake based software, and produce a
+      summary of the build status, after reading the manual.
+    '';
+
+    homepage = "https://josefsson.org/autobuild/";
+    license = lib.licenses.gpl2Plus;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/autoconf-archive/default.nix b/nixpkgs/pkgs/development/tools/misc/autoconf-archive/default.nix
new file mode 100644
index 000000000000..b53adfd0be06
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/autoconf-archive/default.nix
@@ -0,0 +1,20 @@
+{ lib, stdenv, fetchurl, xz }:
+
+stdenv.mkDerivation rec {
+  pname = "autoconf-archive";
+  version = "2021.02.19";
+
+  src = fetchurl {
+    url = "mirror://gnu/autoconf-archive/autoconf-archive-${version}.tar.xz";
+    sha256 = "sha256-6KbrnSjdy6j/7z+iEWUyOem/I5q6agGmt8/Hzq7GnL0=";
+  };
+
+  buildInputs = [ xz ];
+
+  meta = with lib; {
+    description = "Archive of autoconf m4 macros";
+    homepage = "https://www.gnu.org/software/autoconf-archive/";
+    license = licenses.gpl3;
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/autoconf/2.13.nix b/nixpkgs/pkgs/development/tools/misc/autoconf/2.13.nix
new file mode 100644
index 000000000000..26d6d9178edd
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/autoconf/2.13.nix
@@ -0,0 +1,40 @@
+{lib, stdenv, fetchurl, m4, perl, xz}:
+
+stdenv.mkDerivation rec {
+  name = "autoconf-2.13";
+
+  src = fetchurl {
+    url = "mirror://gnu/autoconf/${name}.tar.gz";
+    sha256 = "07krzl4czczdsgzrrw9fiqx35xcf32naf751khg821g5pqv12qgh";
+  };
+
+  nativebuildInputs = [ xz ];
+  buildInputs = [ m4 perl ];
+
+  doCheck = true;
+
+  # Don't fixup "#! /bin/sh" in Autoconf, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  postInstall = ''ln -s autoconf "$out"/bin/autoconf-2.13'';
+
+  meta = {
+    homepage = "https://www.gnu.org/software/autoconf/";
+    description = "Part of the GNU Build System";
+    branch = "2.13";
+
+    longDescription = ''
+      GNU Autoconf is an extensible package of M4 macros that produce
+      shell scripts to automatically configure software source code
+      packages.  These scripts can adapt the packages to many kinds of
+      UNIX-like systems without manual user intervention.  Autoconf
+      creates a configuration script for a package from a template
+      file that lists the operating system features that the package
+      can use, in the form of M4 macro calls.
+    '';
+
+    license = lib.licenses.gpl2Plus;
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/autoconf/2.64.nix b/nixpkgs/pkgs/development/tools/misc/autoconf/2.64.nix
new file mode 100644
index 000000000000..6976a291ae72
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/autoconf/2.64.nix
@@ -0,0 +1,51 @@
+{ lib, stdenv, fetchurl, m4, perl }:
+
+stdenv.mkDerivation rec {
+  name = "autoconf-2.64";
+
+  src = fetchurl {
+    url = "mirror://gnu/autoconf/${name}.tar.xz";
+    sha256 = "0j3jdjpf5ly39dlp0bg70h72nzqr059k0x8iqxvaxf106chpgn9j";
+  };
+
+  buildInputs = [ m4 perl ];
+
+  # Work around a known issue in Cygwin.  See
+  # http://thread.gmane.org/gmane.comp.sysutils.autoconf.bugs/6822 for
+  # details.
+  # There are many test failures on `i386-pc-solaris2.11'.
+  #doCheck = ((!stdenv.isCygwin) && (!stdenv.isSunOS));
+  doCheck = false;
+
+  # Don't fixup "#! /bin/sh" in Autoconf, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  enableParallelBuilding = true;
+
+  # Make the Autotest test suite run in parallel.
+  preCheck =''
+    export TESTSUITEFLAGS="-j$NIX_BUILD_CORES"
+  '';
+
+  doInstallCheck = false; # fails
+
+  meta = {
+    homepage = "https://www.gnu.org/software/autoconf/";
+    description = "Part of the GNU Build System";
+
+    longDescription = ''
+      GNU Autoconf is an extensible package of M4 macros that produce
+      shell scripts to automatically configure software source code
+      packages.  These scripts can adapt the packages to many kinds of
+      UNIX-like systems without manual user intervention.  Autoconf
+      creates a configuration script for a package from a template
+      file that lists the operating system features that the package
+      can use, in the form of M4 macro calls.
+    '';
+
+    license = lib.licenses.gpl2Plus;
+
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/autoconf/2.69.nix b/nixpkgs/pkgs/development/tools/misc/autoconf/2.69.nix
new file mode 100644
index 000000000000..f2f8ca0a858c
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/autoconf/2.69.nix
@@ -0,0 +1,52 @@
+{ lib, stdenv, fetchurl, m4, perl }:
+
+stdenv.mkDerivation rec {
+  name = "autoconf-2.69";
+
+  src = fetchurl {
+    url = "mirror://gnu/autoconf/${name}.tar.xz";
+    sha256 = "113nlmidxy9kjr45kg9x3ngar4951mvag1js2a3j8nxcz34wxsv4";
+  };
+
+  nativeBuildInputs = [ m4 perl ];
+  buildInputs = [ m4 ];
+
+  # Work around a known issue in Cygwin.  See
+  # http://thread.gmane.org/gmane.comp.sysutils.autoconf.bugs/6822 for
+  # details.
+  # There are many test failures on `i386-pc-solaris2.11'.
+  #doCheck = ((!stdenv.isCygwin) && (!stdenv.isSunOS));
+  doCheck = false;
+
+  # Don't fixup "#! /bin/sh" in Autoconf, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  enableParallelBuilding = true;
+
+  # Make the Autotest test suite run in parallel.
+  preCheck =''
+    export TESTSUITEFLAGS="-j$NIX_BUILD_CORES"
+  '';
+
+  doInstallCheck = false; # fails
+
+  meta = {
+    homepage = "https://www.gnu.org/software/autoconf/";
+    description = "Part of the GNU Build System";
+
+    longDescription = ''
+      GNU Autoconf is an extensible package of M4 macros that produce
+      shell scripts to automatically configure software source code
+      packages.  These scripts can adapt the packages to many kinds of
+      UNIX-like systems without manual user intervention.  Autoconf
+      creates a configuration script for a package from a template
+      file that lists the operating system features that the package
+      can use, in the form of M4 macro calls.
+    '';
+
+    license = lib.licenses.gpl2Plus;
+
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/autoconf/default.nix b/nixpkgs/pkgs/development/tools/misc/autoconf/default.nix
new file mode 100644
index 000000000000..a2c160f56622
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/autoconf/default.nix
@@ -0,0 +1,55 @@
+{ lib, stdenv, fetchurl, m4, perl }:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+stdenv.mkDerivation rec {
+  pname = "autoconf";
+  version = "2.71";
+
+  src = fetchurl {
+    url = "mirror://gnu/autoconf/autoconf-${version}.tar.xz";
+    sha256 = "197sl23irn6s9pd54rxj5vcp5y8dv65jb9yfqgr2g56cxg7q6k7i";
+  };
+
+  nativeBuildInputs = [ m4 perl ];
+  buildInputs = [ m4 ];
+
+  # Work around a known issue in Cygwin.  See
+  # http://thread.gmane.org/gmane.comp.sysutils.autoconf.bugs/6822 for
+  # details.
+  # There are many test failures on `i386-pc-solaris2.11'.
+  doCheck = ((!stdenv.isCygwin) && (!stdenv.isSunOS));
+
+  # Don't fixup "#! /bin/sh" in Autoconf, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  enableParallelBuilding = true;
+
+  # Make the Autotest test suite run in parallel.
+  preCheck =''
+    export TESTSUITEFLAGS="-j$NIX_BUILD_CORES"
+  '';
+
+  meta = {
+    homepage = "https://www.gnu.org/software/autoconf/";
+    description = "Part of the GNU Build System";
+
+    longDescription = ''
+      GNU Autoconf is an extensible package of M4 macros that produce
+      shell scripts to automatically configure software source code
+      packages.  These scripts can adapt the packages to many kinds of
+      UNIX-like systems without manual user intervention.  Autoconf
+      creates a configuration script for a package from a template
+      file that lists the operating system features that the package
+      can use, in the form of M4 macro calls.
+    '';
+
+    license = lib.licenses.gpl3Plus;
+
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/autogen/default.nix b/nixpkgs/pkgs/development/tools/misc/autogen/default.nix
new file mode 100644
index 000000000000..75c6471eb4c6
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/autogen/default.nix
@@ -0,0 +1,96 @@
+{ lib, stdenv, buildPackages, fetchurl, autoreconfHook, which, pkg-config, perl, guile, libxml2 }:
+
+stdenv.mkDerivation rec {
+  pname = "autogen";
+  version = "5.18.16";
+
+  src = fetchurl {
+    url = "mirror://gnu/autogen/rel${version}/autogen-${version}.tar.xz";
+    sha256 = "16mlbdys8q4ckxlvxyhwkdnh1ay9f6g0cyp1kylkpalgnik398gq";
+  };
+
+  patches = let
+    dp = { ver ? "1%255.18.16-4", pname, name ? (pname + ".diff"), sha256 }: fetchurl {
+      url = "https://salsa.debian.org/debian/autogen/-/raw/debian/${ver}"
+          + "/debian/patches/${pname}.diff?inline=false";
+      inherit name sha256;
+    };
+  in [
+    (dp {
+      pname = "20_no_Werror";
+      sha256 = "08z4s2ifiqyaacjpd9pzr59w8m4j3548kkaq1bwvp2gjn29m680x";
+    })
+    (dp {
+      pname = "30_ag_macros.m4_syntax_error";
+      sha256 = "1z8vmbwbkz3505wd33i2xx91mlf8rwsa7klndq37nw821skxwyh3";
+    })
+    (dp {
+      pname = "31_allow_overriding_AGexe_for_crossbuild";
+      sha256 = "0h9wkc9bqb509knh8mymi43hg6n6sxg2lixvjlchcx7z0j7p8xkf";
+    })
+  ];
+
+  outputs = [ "bin" "dev" "lib" "out" "man" "info" ];
+
+  nativeBuildInputs = [
+    which pkg-config perl autoreconfHook/*patches applied*/
+  ] ++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
+    # autogen needs a build autogen when cross-compiling
+    buildPackages.buildPackages.autogen buildPackages.texinfo
+  ];
+  buildInputs = [
+    guile libxml2
+  ];
+
+  preConfigure = ''
+    export MAN_PAGE_DATE=$(date '+%Y-%m-%d' -d "@$SOURCE_DATE_EPOCH")
+  '';
+
+  configureFlags =
+    [
+      # Make sure to use a static value for the timeout. If we do not set a value
+      # here autogen will select one based on the execution time of the configure
+      # phase which is not really reproducible.
+      #
+      # If you are curious about the number 78, it has been cargo-culted from
+      # Debian: https://salsa.debian.org/debian/autogen/-/blob/master/debian/rules#L21
+      "--enable-timeout=78"
+    ]
+    ++ (lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
+      "--with-libxml2=${libxml2.dev}"
+      "--with-libxml2-cflags=-I${libxml2.dev}/include/libxml2"
+      # the configure check for regcomp wants to run a host program
+      "libopts_cv_with_libregex=yes"
+      #"MAKEINFO=${buildPackages.texinfo}/bin/makeinfo"
+    ])
+    # See: https://sourceforge.net/p/autogen/bugs/187/
+    ++ lib.optionals stdenv.isDarwin [ "ac_cv_func_utimensat=no" ];
+
+  #doCheck = true; # not reliable
+
+  postInstall = ''
+    mkdir -p $dev/bin
+    mv $bin/bin/autoopts-config $dev/bin
+
+    for f in $lib/lib/autogen/tpl-config.tlib $out/share/autogen/tpl-config.tlib; do
+      sed -e "s|$dev/include|/no-such-autogen-include-path|" -i $f
+      sed -e "s|$bin/bin|/no-such-autogen-bin-path|" -i $f
+      sed -e "s|$lib/lib|/no-such-autogen-lib-path|" -i $f
+    done
+
+  '' + lib.optionalString (!stdenv.hostPlatform.isDarwin) ''
+    # remove /build/** from RPATHs
+    for f in "$bin"/bin/*; do
+      local nrp="$(patchelf --print-rpath "$f" | sed -E 's@(:|^)/build/[^:]*:@\1@g')"
+      patchelf --set-rpath "$nrp" "$f"
+    done
+  '';
+
+  meta = with lib; {
+    description = "Automated text and program generation tool";
+    license = with licenses; [ gpl3Plus lgpl3Plus ];
+    homepage = "https://www.gnu.org/software/autogen/";
+    platforms = platforms.all;
+    maintainers = [ ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/automake-1.11.x.nix b/nixpkgs/pkgs/development/tools/misc/automake/automake-1.11.x.nix
new file mode 100644
index 000000000000..5e3167d182dc
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/automake-1.11.x.nix
@@ -0,0 +1,49 @@
+{ lib, stdenv, fetchurl, perl, autoconf }:
+
+stdenv.mkDerivation rec {
+  name = "automake-1.11.6";
+
+  # TODO: Remove the `aclocal' wrapper when $ACLOCAL_PATH support is
+  # available upstream; see
+  # <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=9026>.
+  builder = ./builder.sh;
+
+  setupHook = ./setup-hook.sh;
+
+  src = fetchurl {
+    url = "mirror://gnu/automake/${name}.tar.xz";
+    sha256 = "1ffbc6cc41f0ea6c864fbe9485b981679dc5e350f6c4bc6c3512f5a4226936b5";
+  };
+
+  patches = [ ./fix-test-autoconf-2.69.patch ./fix-perl-5.26.patch ];
+
+  buildInputs = [ perl autoconf ];
+
+  # Disable indented log output from Make, otherwise "make.test" will
+  # fail.
+  preCheck = "unset NIX_INDENT_MAKE";
+  doCheck = false; # takes _a lot_ of time, fails 11 of 782 tests
+
+  # Don't fixup "#! /bin/sh" in Libtool, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  # Run the test suite in parallel.
+  enableParallelBuilding = true;
+
+  meta = {
+    branch = "1.11";
+    homepage = "https://www.gnu.org/software/automake/";
+    description = "GNU standard-compliant makefile generator";
+
+    longDescription = ''
+      GNU Automake is a tool for automatically generating
+      `Makefile.in' files compliant with the GNU Coding
+      Standards.  Automake requires the use of Autoconf.
+    '';
+
+    license = lib.licenses.gpl2Plus;
+
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/automake-1.15.x.nix b/nixpkgs/pkgs/development/tools/misc/automake/automake-1.15.x.nix
new file mode 100644
index 000000000000..0088eb74cc48
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/automake-1.15.x.nix
@@ -0,0 +1,45 @@
+{ lib, stdenv, fetchurl, perl, autoconf }:
+
+stdenv.mkDerivation rec {
+  name = "automake-1.15.1";
+
+  src = fetchurl {
+    url = "mirror://gnu/automake/${name}.tar.xz";
+    sha256 = "1bzd9g32dfm4rsbw93ld9x7b5nc1y6i4m6zp032qf1i28a8s6sxg";
+  };
+
+  nativeBuildInputs = [ autoconf perl ];
+  buildInputs = [ autoconf ];
+
+  setupHook = ./setup-hook.sh;
+
+  patches = [ ./help2man-SOURCE_DATE_EPOCH-support.patch ];
+
+  # Disable indented log output from Make, otherwise "make.test" will
+  # fail.
+  preCheck = "unset NIX_INDENT_MAKE";
+  doCheck = false; # takes _a lot_ of time, fails 3 out of 2698 tests, all seem to be related to paths
+  doInstallCheck = false; # runs the same thing, fails the same tests
+
+  # The test suite can run in parallel.
+  enableParallelBuilding = true;
+
+  # Don't fixup "#! /bin/sh" in Libtool, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  meta = {
+    branch = "1.15";
+    homepage = "https://www.gnu.org/software/automake/";
+    description = "GNU standard-compliant makefile generator";
+    license = lib.licenses.gpl2Plus;
+
+    longDescription = ''
+      GNU Automake is a tool for automatically generating
+      `Makefile.in' files compliant with the GNU Coding
+      Standards.  Automake requires the use of Autoconf.
+    '';
+
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/automake-1.16.x.nix b/nixpkgs/pkgs/development/tools/misc/automake/automake-1.16.x.nix
new file mode 100644
index 000000000000..48f01f8d0f67
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/automake-1.16.x.nix
@@ -0,0 +1,43 @@
+{ lib, stdenv, fetchurl, perl, autoconf }:
+
+stdenv.mkDerivation rec {
+  name = "automake-1.16.3";
+
+  src = fetchurl {
+    url = "mirror://gnu/automake/${name}.tar.xz";
+    sha256 = "0fmz2fhmzcpacnprl5msphvaflwiy0hvpgmqlgfny72ddijzfazz";
+  };
+
+  nativeBuildInputs = [ autoconf perl ];
+  buildInputs = [ autoconf ];
+
+  setupHook = ./setup-hook.sh;
+
+  # Disable indented log output from Make, otherwise "make.test" will
+  # fail.
+  preCheck = "unset NIX_INDENT_MAKE";
+  doCheck = false; # takes _a lot_ of time, fails 3 out of 2698 tests, all seem to be related to paths
+  doInstallCheck = false; # runs the same thing, fails the same tests
+
+  # The test suite can run in parallel.
+  enableParallelBuilding = true;
+
+  # Don't fixup "#! /bin/sh" in Libtool, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  meta = {
+    branch = "1.16";
+    homepage = "https://www.gnu.org/software/automake/";
+    description = "GNU standard-compliant makefile generator";
+    license = lib.licenses.gpl2Plus;
+
+    longDescription = ''
+      GNU Automake is a tool for automatically generating
+      `Makefile.in' files compliant with the GNU Coding
+      Standards.  Automake requires the use of Autoconf.
+    '';
+
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/builder.sh b/nixpkgs/pkgs/development/tools/misc/automake/builder.sh
new file mode 100644
index 000000000000..e54a2acca67e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/builder.sh
@@ -0,0 +1,47 @@
+source $stdenv/setup
+
+# Wrap the given `aclocal' program, appending extra `-I' flags
+# corresponding to the directories listed in $ACLOCAL_PATH.  (Note
+# that `wrapProgram' can't be used for that purpose since it can only
+# prepend flags, not append them.)
+wrapAclocal() {
+    local program="$1"
+    local wrapped="$(dirname $program)/.$(basename $program)-wrapped"
+
+    mv "$program" "$wrapped"
+    cat > "$program"<<EOF
+#! $SHELL -e
+
+unset extraFlagsArray
+declare -a extraFlagsArray
+
+oldIFS=\$IFS
+IFS=:
+for dir in \$ACLOCAL_PATH; do
+    if test -n "\$dir" -a -d "\$dir"; then
+        extraFlagsArray=("\${extraFlagsArray[@]}" "-I" "\$dir")
+    fi
+done
+IFS=\$oldIFS
+
+exec "$wrapped" "\$@" "\${extraFlagsArray[@]}"
+EOF
+    chmod +x "$program"
+}
+
+postInstall() {
+    # Create a wrapper around `aclocal' that converts every element in
+    # `ACLOCAL_PATH' into a `-I dir' option.  This way `aclocal'
+    # becomes modular; M4 macros do not need to be stored in a single
+    # global directory, while callers of `aclocal' do not need to pass
+    # `-I' options explicitly.
+
+    for prog in $out/bin/aclocal*; do
+        wrapAclocal "$prog"
+    done
+
+    ln -s aclocal-1.11 $out/share/aclocal
+    ln -s automake-1.11 $out/share/automake
+}
+
+genericBuild
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/fix-perl-5.26.patch b/nixpkgs/pkgs/development/tools/misc/automake/fix-perl-5.26.patch
new file mode 100644
index 000000000000..fb2d08de6d81
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/fix-perl-5.26.patch
@@ -0,0 +1,10 @@
+--- automake-1.11.2/automake.in
++++ automake-1.11.2/automake.in
+@@ -4156,7 +4156,7 @@ sub substitute_ac_subst_variables_worker($)
+ sub substitute_ac_subst_variables ($)
+ {
+   my ($text) = @_;
+-  $text =~ s/\${([^ \t=:+{}]+)}/&substitute_ac_subst_variables_worker ($1)/ge;
++  $text =~ s/\$\{([^ \t=:+{}]+)}/&substitute_ac_subst_variables_worker ($1)/ge;
+   return $text;
+ }
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/fix-test-autoconf-2.69.patch b/nixpkgs/pkgs/development/tools/misc/automake/fix-test-autoconf-2.69.patch
new file mode 100644
index 000000000000..2ffa91f24eda
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/fix-test-autoconf-2.69.patch
@@ -0,0 +1,13 @@
+With Autoconf 2.69 (instead of 2.68), config.{guess,sub} are needed.
+
+--- automake-1.11.2/tests/compile_f90_c_cxx.test	2011-12-20 21:56:29.000000000 +0100
++++ automake-1.11.2/tests/compile_f90_c_cxx.test	2012-07-07 13:35:58.000000000 +0200
+@@ -41,7 +41,7 @@ END
+ : > baz.cc
+ 
+ $ACLOCAL
+-$AUTOMAKE
++$AUTOMAKE --add-missing
+ 
+ # Look for the macros at the beginning of rules.  Be careful, as there
+ # are literal tabs at the beginning of the search strings.
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/help2man-SOURCE_DATE_EPOCH-support.patch b/nixpkgs/pkgs/development/tools/misc/automake/help2man-SOURCE_DATE_EPOCH-support.patch
new file mode 100644
index 000000000000..048f75e63343
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/help2man-SOURCE_DATE_EPOCH-support.patch
@@ -0,0 +1,41 @@
+From 2e3357d7f0d63f1caeb40d9644c2436a5cd0da5f Mon Sep 17 00:00:00 2001
+From: David Terry <me@xwvvvvwx.com>
+Date: Fri, 18 Oct 2019 10:23:11 +0200
+Subject: [PATCH] help2man: add support for SOURCE_DATE_EPOCH
+
+---
+ doc/help2man | 14 +++++++++++++-
+ 1 file changed, 13 insertions(+), 1 deletion(-)
+
+diff --git a/doc/help2man b/doc/help2man
+index af4306f..4a64167 100755
+--- a/doc/help2man
++++ b/doc/help2man
+@@ -213,11 +213,23 @@ sub get_option_value;
+ my $help_text   = get_option_value $ARGV[0], $help_option;
+ $version_text ||= get_option_value $ARGV[0], $version_option;
+ 
++# By default the generated manual pages will include the current date.  This may
++# however be overriden by setting the environment variable $SOURCE_DATE_EPOCH
++# to an integer value of the seconds since the UNIX epoch.  This is primarily
++# intended to support reproducible builds (wiki.debian.org/ReproducibleBuilds)
++# and will additionally ensure that the output date string is UTC.
++my $epoch_secs = time;
++if (exists $ENV{SOURCE_DATE_EPOCH} and $ENV{SOURCE_DATE_EPOCH} =~ /^(\d+)$/)
++{
++    $epoch_secs = $1;
++    $ENV{TZ} = 'UTC';
++}
++
+ # Translators: the following message is a strftime(3) format string, which in
+ # the English version expands to the month as a word and the full year.  It
+ # is used on the footer of the generated manual pages.  If in doubt, you may
+ # just use %x as the value (which should be the full locale-specific date).
+-my $date = enc strftime _("%B %Y"), localtime;
++my $date = enc strftime _("%B %Y"), localtime $epoch_secs;
+ (my $program = $ARGV[0]) =~ s!.*/!!;
+ my $package = $program;
+ my $version;
+-- 
+2.23.0
+
diff --git a/nixpkgs/pkgs/development/tools/misc/automake/setup-hook.sh b/nixpkgs/pkgs/development/tools/misc/automake/setup-hook.sh
new file mode 100644
index 000000000000..292632b7cbce
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automake/setup-hook.sh
@@ -0,0 +1,5 @@
+addAclocals () {
+    addToSearchPathWithCustomDelimiter : ACLOCAL_PATH $1/share/aclocal
+}
+
+addEnvHooks "$hostOffset" addAclocals
diff --git a/nixpkgs/pkgs/development/tools/misc/automaticcomponenttoolkit/default.nix b/nixpkgs/pkgs/development/tools/misc/automaticcomponenttoolkit/default.nix
new file mode 100644
index 000000000000..cf84a98467d6
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automaticcomponenttoolkit/default.nix
@@ -0,0 +1,33 @@
+{ stdenv, lib, fetchFromGitHub, go }:
+
+stdenv.mkDerivation rec {
+  pname = "AutomaticComponentToolkit";
+  version = "1.6.0";
+
+  src = fetchFromGitHub {
+    owner = "Autodesk";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "1r0sbw82cf9dbcj3vgnbd4sc1lklzvijic2z5wgkvs21azcm0yzh";
+  };
+
+  nativeBuildInputs = [ go ];
+
+  buildPhase = ''
+    cd Source
+    export HOME=/tmp
+    go build -o act *.go
+  '';
+
+  installPhase = ''
+    install -Dm0755 act $out/bin/act
+  '';
+
+  meta = with lib; {
+    description = "Toolkit to automatically generate software components: abstract API, implementation stubs and language bindings";
+    homepage = "https://github.com/Autodesk/AutomaticComponentToolkit";
+    license = licenses.bsd2;
+    maintainers = with maintainers; [ gebner ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/automoc4/default.nix b/nixpkgs/pkgs/development/tools/misc/automoc4/default.nix
new file mode 100644
index 000000000000..ac027ec45301
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/automoc4/default.nix
@@ -0,0 +1,22 @@
+{ lib, stdenv, fetchurl, cmake, qt4 }:
+
+stdenv.mkDerivation rec {
+  pname = "automoc4";
+  version = "0.9.88";
+
+  src = fetchurl {
+    url = "mirror://kde/stable/automoc4/0.9.88/${pname}.tar.bz2";
+    sha256 = "0jackvg0bdjg797qlbbyf9syylm0qjs55mllhn11vqjsq3s1ch93";
+  };
+
+  nativeBuildInputs = [ cmake ];
+  buildInputs = [ qt4 ];
+
+  meta = with lib; {
+    homepage = "https://techbase.kde.org/Development/Tools/Automoc4";
+    description = "KDE Meta Object Compiler";
+    license = licenses.bsd2;
+    maintainers = [ maintainers.sander ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/avrdude/default.nix b/nixpkgs/pkgs/development/tools/misc/avrdude/default.nix
new file mode 100644
index 000000000000..9cfd93800103
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/avrdude/default.nix
@@ -0,0 +1,33 @@
+{ lib, stdenv, fetchurl, bison, flex, libusb-compat-0_1, libelf, libftdi1, readline
+# docSupport is a big dependency, disabled by default
+, docSupport ? false, texLive ? null, texinfo ? null, texi2html ? null
+}:
+
+assert docSupport -> texLive != null && texinfo != null && texi2html != null;
+
+stdenv.mkDerivation rec {
+  name = "avrdude-6.3";
+
+  src = fetchurl {
+    url = "mirror://savannah/avrdude/${name}.tar.gz";
+    sha256 = "15m1w1qad3dj7r8n5ng1qqcaiyx1gyd6hnc3p2apgjllccdp77qg";
+  };
+
+  configureFlags = lib.optionals docSupport "--enable-doc";
+
+  buildInputs = [ bison flex libusb-compat-0_1 libelf libftdi1 readline ]
+    ++ lib.optionals docSupport [ texLive texinfo texi2html ];
+
+  meta = with lib; {
+    description = "Command-line tool for programming Atmel AVR microcontrollers";
+    longDescription = ''
+      AVRDUDE (AVR Downloader/UploaDEr) is an utility to
+      download/upload/manipulate the ROM and EEPROM contents of AVR
+      microcontrollers using the in-system programming technique (ISP).
+    '';
+    homepage = "https://www.nongnu.org/avrdude/";
+    license = licenses.gpl2Plus;
+    platforms = with platforms; linux ++ darwin;
+    maintainers = [ maintainers.bjornfor ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/awf/default.nix b/nixpkgs/pkgs/development/tools/misc/awf/default.nix
new file mode 100644
index 000000000000..b73f1dc04502
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/awf/default.nix
@@ -0,0 +1,37 @@
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, gtk2, gtk3, pkg-config
+, wrapGAppsHook }:
+
+stdenv.mkDerivation rec {
+  pname = "awf";
+  version = "1.4.0";
+
+  src = fetchFromGitHub {
+    owner = "valr";
+    repo = "awf";
+    rev = "v${version}";
+    sha256 = "0jl2kxwpvf2n8974zzyp69mqhsbjnjcqm39y0jvijvjb1iy8iman";
+  };
+
+  nativeBuildInputs = [ autoreconfHook pkg-config wrapGAppsHook ];
+
+  buildInputs = [ gtk2 gtk3 ];
+
+  autoreconfPhase = ''
+    patchShebangs ./autogen.sh
+    ./autogen.sh
+  '';
+
+  meta = with lib; {
+    description = "A Widget Factory";
+    longDescription = ''
+      A widget factory is a theme preview application for gtk2 and
+      gtk3. It displays the various widget types provided by gtk2/gtk3
+      in a single window allowing to see the visual effect of the
+      applied theme.
+    '';
+    homepage = "https://github.com/valr/awf";
+    license = licenses.gpl3;
+    platforms = platforms.all;
+    maintainers = with maintainers; [ michalrus ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/babeltrace/default.nix b/nixpkgs/pkgs/development/tools/misc/babeltrace/default.nix
new file mode 100644
index 000000000000..26c484017d2b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/babeltrace/default.nix
@@ -0,0 +1,22 @@
+{ lib, stdenv, fetchurl, pkg-config, glib, libuuid, popt, elfutils }:
+
+stdenv.mkDerivation rec {
+  name = "babeltrace-1.5.8";
+
+  src = fetchurl {
+    url = "https://www.efficios.com/files/babeltrace/${name}.tar.bz2";
+    sha256 = "1hkg3phnamxfrhwzmiiirbhdgckzfkqwhajl0lmr1wfps7j47wcz";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ glib libuuid popt elfutils ];
+
+  meta = with lib; {
+    description = "Command-line tool and library to read and convert LTTng tracefiles";
+    homepage = "https://www.efficios.com/babeltrace";
+    license = licenses.mit;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/bashdb/default.nix b/nixpkgs/pkgs/development/tools/misc/bashdb/default.nix
new file mode 100644
index 000000000000..72ec8c96be34
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bashdb/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchurl, makeWrapper, python3Packages }:
+
+stdenv.mkDerivation rec {
+  pname = "bashdb";
+  version = "4.4-1.0.0";
+
+  src = fetchurl {
+    url =  "mirror://sourceforge/bashdb/${pname}-${version}.tar.bz2";
+    sha256 = "0p7i7bpzs6q1i7swnkr89kxqgzr146xw8d2acmqwqbslzm9dqlml";
+  };
+
+  nativeBuildInputs = [
+    makeWrapper
+  ];
+
+  postInstall = ''
+    wrapProgram $out/bin/bashdb --prefix PYTHONPATH ":" "$(toPythonPath ${python3Packages.pygments})"
+  '';
+
+  meta = {
+    description = "Bash script debugger";
+    homepage = "http://bashdb.sourceforge.net/";
+    license = lib.licenses.gpl2;
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/bin_replace_string/default.nix b/nixpkgs/pkgs/development/tools/misc/bin_replace_string/default.nix
new file mode 100644
index 000000000000..a732d6e732c5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bin_replace_string/default.nix
@@ -0,0 +1,31 @@
+{ lib, stdenv, fetchurl, libelf, txt2man }:
+
+stdenv.mkDerivation {
+  pname = "bin_replace_string";
+  version = "0.2";
+
+  src = fetchurl {
+    sha256 = "1gnpddxwpsfrg4l76x5yplsvbcdbviybciqpn22yq3g3qgnr5c2a";
+    url = "ftp://ohnopub.net/mirror/bin_replace_string-0.2.tar.bz2";
+  };
+
+  buildInputs = [ libelf ];
+  nativeBuildInputs = [ txt2man ];
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    description = "Edit precompiled binaries";
+    longDescription = ''
+      bin_replace_string edits C-style strings in precompiled binaries. This is
+      intended to be useful to replace arbitrary strings in binaries whose
+      source code is not available. However, because of the nature of compiled
+      binaries, bin_replace_string may only replace a given C-string with a
+      shorter C-string.
+    '';
+    homepage = "http://ohnopub.net/~ohnobinki/bin_replace_string/";
+    downloadPage = "ftp://ohnopub.net/mirror/";
+    license = licenses.gpl3Plus;
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/CVE-2020-35448.patch b/nixpkgs/pkgs/development/tools/misc/binutils/CVE-2020-35448.patch
new file mode 100644
index 000000000000..2eba7b51849f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/CVE-2020-35448.patch
@@ -0,0 +1,77 @@
+From 8642dafaef21aa6747cec01df1977e9c52eb4679 Mon Sep 17 00:00:00 2001
+From: Alan Modra <amodra@gmail.com>
+Date: Fri, 4 Sep 2020 19:19:18 +0930
+Subject: [PATCH] PR26574, heap buffer overflow in
+ _bfd_elf_slurp_secondary_reloc_section
+
+A horribly fuzzed object with section headers inside the ELF header.
+Disallow that, and crazy reloc sizes.
+
+	PR 26574
+	* elfcode.h (elf_object_p): Sanity check section header offset.
+	* elf.c (_bfd_elf_slurp_secondary_reloc_section): Sanity check
+	sh_entsize.
+---
+ bfd/elf.c     | 4 +++-
+ bfd/elfcode.h | 8 ++++----
+ 3 files changed, 14 insertions(+), 5 deletions(-)
+
+diff --git a/bfd/elf.c b/bfd/elf.c
+index ac2095f787d..5a02f8dc309 100644
+--- a/bfd/elf.c
++++ b/bfd/elf.c
+@@ -12576,7 +12576,9 @@ _bfd_elf_slurp_secondary_reloc_section (bfd *      abfd,
+       Elf_Internal_Shdr * hdr = & elf_section_data (relsec)->this_hdr;
+ 
+       if (hdr->sh_type == SHT_SECONDARY_RELOC
+-	  && hdr->sh_info == (unsigned) elf_section_data (sec)->this_idx)
++	  && hdr->sh_info == (unsigned) elf_section_data (sec)->this_idx
++	  && (hdr->sh_entsize == ebd->s->sizeof_rel
++	      || hdr->sh_entsize == ebd->s->sizeof_rela))
+ 	{
+ 	  bfd_byte * native_relocs;
+ 	  bfd_byte * native_reloc;
+diff --git a/bfd/elfcode.h b/bfd/elfcode.h
+index 2ed2f135c34..606ff64fd4d 100644
+--- a/bfd/elfcode.h
++++ b/bfd/elfcode.h
+@@ -571,7 +571,7 @@ elf_object_p (bfd *abfd)
+ 
+   /* If this is a relocatable file and there is no section header
+      table, then we're hosed.  */
+-  if (i_ehdrp->e_shoff == 0 && i_ehdrp->e_type == ET_REL)
++  if (i_ehdrp->e_shoff < sizeof (x_ehdr) && i_ehdrp->e_type == ET_REL)
+     goto got_wrong_format_error;
+ 
+   /* As a simple sanity check, verify that what BFD thinks is the
+@@ -581,7 +581,7 @@ elf_object_p (bfd *abfd)
+     goto got_wrong_format_error;
+ 
+   /* Further sanity check.  */
+-  if (i_ehdrp->e_shoff == 0 && i_ehdrp->e_shnum != 0)
++  if (i_ehdrp->e_shoff < sizeof (x_ehdr) && i_ehdrp->e_shnum != 0)
+     goto got_wrong_format_error;
+ 
+   ebd = get_elf_backend_data (abfd);
+@@ -618,7 +618,7 @@ elf_object_p (bfd *abfd)
+       && ebd->elf_osabi != ELFOSABI_NONE)
+     goto got_wrong_format_error;
+ 
+-  if (i_ehdrp->e_shoff != 0)
++  if (i_ehdrp->e_shoff >= sizeof (x_ehdr))
+     {
+       file_ptr where = (file_ptr) i_ehdrp->e_shoff;
+ 
+@@ -819,7 +819,7 @@ elf_object_p (bfd *abfd)
+ 	}
+     }
+ 
+-  if (i_ehdrp->e_shstrndx != 0 && i_ehdrp->e_shoff != 0)
++  if (i_ehdrp->e_shstrndx != 0 && i_ehdrp->e_shoff >= sizeof (x_ehdr))
+     {
+       unsigned int num_sec;
+ 
+-- 
+2.27.0
+
+
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/R_ARM_COPY.patch b/nixpkgs/pkgs/development/tools/misc/binutils/R_ARM_COPY.patch
new file mode 100644
index 000000000000..874809863523
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/R_ARM_COPY.patch
@@ -0,0 +1,29 @@
+@@ -, +, @@ 
+---
+ bfd/elf32-arm.c | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+--- a/bfd/elf32-arm.c	
++++ a/bfd/elf32-arm.c	
+@@ -15398,7 +15398,11 @@ elf32_arm_adjust_dynamic_symbol (struct bfd_link_info * info,
+      linker to copy the initial value out of the dynamic object and into
+      the runtime process image.  We need to remember the offset into the
+      .rel(a).bss section we are going to use.  */
+-  if ((h->root.u.def.section->flags & SEC_READONLY) != 0)
++  if (info->nocopyreloc == 0
++      && (h->root.u.def.section->flags & SEC_ALLOC) != 0
++      /* PR 16177: A copy is only needed if the input section is readonly.  */
++      && (h->root.u.def.section->flags & SEC_READONLY) != 0
++      && h->size != 0)
+     {
+       s = globals->root.sdynrelro;
+       srel = globals->root.sreldynrelro;
+@@ -15410,6 +15414,8 @@ elf32_arm_adjust_dynamic_symbol (struct bfd_link_info * info,
+     }
+   if (info->nocopyreloc == 0
+       && (h->root.u.def.section->flags & SEC_ALLOC) != 0
++      /* PR 16177: A copy is only needed if the input section is readonly.  */
++      && (h->root.u.def.section->flags & SEC_READONLY) != 0
+       && h->size != 0)
+     {
+       elf32_arm_allocate_dynrelocs (info, srel, 1);
+
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/always-search-rpath.patch b/nixpkgs/pkgs/development/tools/misc/binutils/always-search-rpath.patch
new file mode 100644
index 000000000000..2e9956e6b6e4
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/always-search-rpath.patch
@@ -0,0 +1,14 @@
+diff --git a/ld/genscripts.sh b/ld/genscripts.sh
+index b6940d376d..0feb1adfd0 100755
+--- a/ld/genscripts.sh
++++ b/ld/genscripts.sh
+@@ -125,6 +125,9 @@ if test "x$NATIVE" = "xyes" ; then
+   USE_LIBPATH=yes
+ fi
+ 
++# TODO: why is this needed?
++USE_LIBPATH=yes
++
+ # Set the library search path, for libraries named by -lfoo.
+ # If LIB_PATH is defined (e.g., by Makefile) and non-empty, it is used.
+ # Otherwise, the default is set here.
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/build-components-separately.patch b/nixpkgs/pkgs/development/tools/misc/binutils/build-components-separately.patch
new file mode 100644
index 000000000000..38fa4934a28a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/build-components-separately.patch
@@ -0,0 +1,164 @@
+diff --git a/bfd/configure.ac b/bfd/configure.ac
+index c5bfbd5d..45ad4c26 100644
+--- a/bfd/configure.ac
++++ b/bfd/configure.ac
+@@ -278,31 +278,19 @@ AC_CACHE_CHECK(linker --as-needed support, bfd_cv_ld_as_needed,
+ 
+ LT_LIB_M
+ 
+-# When building a shared libbfd, link against the pic version of libiberty
+-# so that apps that use libbfd won't need libiberty just to satisfy any
+-# libbfd references.
+-# We can't do that if a pic libiberty is unavailable since including non-pic
+-# code would insert text relocations into libbfd.
+ SHARED_LIBADD=
+-SHARED_LDFLAGS=
++SHARED_LDFLAGS=-liberty
+ if test "$enable_shared" = "yes"; then
+-changequote(,)dnl
+-  x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
+-changequote([,])dnl
+-  if test -n "$x"; then
+-    SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
+-  fi
+-
+   case "${host}" in
+   # More hacks to build DLLs on Windows.
+   *-*-cygwin*)
+     SHARED_LDFLAGS="-no-undefined"
+-    SHARED_LIBADD="-L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin -lkernel32"
++    SHARED_LIBADD="-liberty -lintl -lcygwin -lkernel32"
+   ;;
+ 
+   # Use built-in libintl on macOS, since it is not provided by libc.
+   *-*-darwin*)
+-    SHARED_LIBADD="-L`pwd`/../libiberty/pic -L`pwd`/../intl -liberty -lintl"
++    SHARED_LIBADD="-liberty -lintl"
+   ;;
+   esac
+ 
+diff --git a/opcodes/Makefile.am b/opcodes/Makefile.am
+index 4f06074a..6836c589 100644
+--- a/opcodes/Makefile.am
++++ b/opcodes/Makefile.am
+@@ -51,7 +51,7 @@ libopcodes_la_LDFLAGS += -rpath $(rpath_bfdlibdir)
+ endif
+ 
+ # This is where bfd.h lives.
+-BFD_H = ../bfd/bfd.h
++BFD_H = $(BFDDIR)/bfd.h
+ 
+ BUILD_LIBS = @BUILD_LIBS@
+ BUILD_LIB_DEPS = @BUILD_LIB_DEPS@
+@@ -301,7 +301,7 @@ OFILES = @BFD_MACHINES@
+ # development.sh is used to determine -Werror default.
+ CONFIG_STATUS_DEPENDENCIES = $(BFDDIR)/development.sh
+ 
+-AM_CPPFLAGS = -I. -I$(srcdir) -I../bfd -I$(INCDIR) -I$(BFDDIR) @HDEFINES@ @INCINTL@
++AM_CPPFLAGS = -I. -I$(srcdir) -I$(INCDIR) -I$(BFDDIR) @HDEFINES@ @INCINTL@
+ 
+ disassemble.lo: disassemble.c
+ if am__fastdepCC
+@@ -322,12 +322,21 @@ libopcodes_la_SOURCES =  dis-buf.c disassemble.c dis-init.c
+ # old version of libbfd, or to pick up libbfd for the wrong architecture
+ # if host != build. So for building with shared libraries we use a
+ # hardcoded path to libbfd.so instead of relying on the entries in libbfd.la.
+-libopcodes_la_DEPENDENCIES = $(OFILES) @SHARED_DEPENDENCIES@
++libopcodes_la_DEPENDENCIES = $(OFILES) @SHARED_DEPENDENCIES@ libtool-soversion
+ libopcodes_la_LIBADD = $(OFILES) @SHARED_LIBADD@
+-libopcodes_la_LDFLAGS += -release `cat ../bfd/libtool-soversion` @SHARED_LDFLAGS@
++libopcodes_la_LDFLAGS += -release `cat libtool-soversion` @SHARED_LDFLAGS@
+ # Allow dependency tracking to work on all the source files.
+ EXTRA_libopcodes_la_SOURCES = $(LIBOPCODES_CFILES)
+ 
++libtool-soversion:
++	@echo "creating $@"
++	bfd_soversion="$(VERSION)" ;\
++	. $(BFDDIR)/development.sh ;\
++	if test "$$development" = true ; then \
++	  bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
++	fi ;\
++	echo "$${bfd_soversion}" > $@
++
+ # libtool will build .libs/libopcodes.a.  We create libopcodes.a in
+ # the build directory so that we don't have to convert all the
+ # programs that use libopcodes.a simultaneously.  This is a hack which
+diff --git a/opcodes/configure.ac b/opcodes/configure.ac
+index 00be9c88..6e589ae4 100644
+--- a/opcodes/configure.ac
++++ b/opcodes/configure.ac
+@@ -86,6 +86,7 @@ AC_PROG_INSTALL
+ 
+ AC_CHECK_HEADERS(string.h strings.h stdlib.h limits.h)
+ ACX_HEADER_STRING
++GCC_HEADER_STDINT(bfd_stdint.h)
+ 
+ AC_CHECK_DECLS([basename, stpcpy])
+ 
+@@ -137,61 +138,27 @@ AC_CACHE_CHECK(linker --as-needed support, bfd_cv_ld_as_needed,
+ 
+ LT_LIB_M
+ 
+-#Libs for generator progs
+-if test "x$cross_compiling" = "xno"; then
+-  BUILD_LIBS=../libiberty/libiberty.a
+-  BUILD_LIB_DEPS=$BUILD_LIBS
+-else
+-  # if cross-compiling, assume that the system provides -liberty
+-  # and that the version is compatible with new headers.
+-  BUILD_LIBS=-liberty
+-  BUILD_LIB_DEPS=
+-fi
+-BUILD_LIBS="$BUILD_LIBS $LIBINTL"
+-BUILD_LIB_DEPS="$BUILD_LIB_DEPS $LIBINTL_DEP"
++BUILD_LIBS="-liberty $LIBINTL"
++BUILD_LIB_DEPS="$LIBINTL_DEP"
+ 
+ AC_SUBST(BUILD_LIBS)
+ AC_SUBST(BUILD_LIB_DEPS)
+ 
+ # Horrible hacks to build DLLs on Windows and a shared library elsewhere.
+ SHARED_LDFLAGS=
+-SHARED_LIBADD=
++SHARED_LIBADD=-liberty
+ SHARED_DEPENDENCIES=
+ if test "$enable_shared" = "yes"; then
+-# When building a shared libopcodes, link against the pic version of libiberty
+-# so that apps that use libopcodes won't need libiberty just to satisfy any
+-# libopcodes references.
+-# We can't do that if a pic libiberty is unavailable since including non-pic
+-# code would insert text relocations into libopcodes.
+ # Note that linking against libbfd as we do here, which is itself linked
+ # against libiberty, may not satisfy all the libopcodes libiberty references
+ # since libbfd may not pull in the entirety of libiberty.
+-changequote(,)dnl
+-  x=`sed -n -e 's/^[ 	]*PICFLAG[ 	]*=[ 	]*//p' < ../libiberty/Makefile | sed -n '$p'`
+-changequote([,])dnl
+-  if test -n "$x"; then
+-    SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
+-  fi
+-
+   case "${host}" in
+     *-*-cygwin*)
+       SHARED_LDFLAGS="-no-undefined"
+-      SHARED_LIBADD="-L`pwd`/../bfd -lbfd -L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin"
++      SHARED_LIBADD="-lbfd -liberty -lintl -lcygwin"
+       ;;
+-   *-*-darwin*)
+-     SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.dylib ${SHARED_LIBADD}"
+-     SHARED_DEPENDENCIES="../bfd/libbfd.la"
+-     ;;
+     *)
+-      case "$host_vendor" in
+-        hp)
+-          SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.sl ${SHARED_LIBADD}"
+-	  ;;
+-	*)
+-          SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.so ${SHARED_LIBADD}"
+-	  ;;
+-      esac
+-      SHARED_DEPENDENCIES="../bfd/libbfd.la"
++      SHARED_LIBADD="-lbfd ${SHARED_LIBADD}"
+       ;;
+   esac
+ 
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/default.nix b/nixpkgs/pkgs/development/tools/misc/binutils/default.nix
new file mode 100644
index 000000000000..8042655a859d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/default.nix
@@ -0,0 +1,177 @@
+{ stdenv, lib, buildPackages
+, fetchFromGitHub, fetchurl, zlib, autoreconfHook, gettext
+# Enabling all targets increases output size to a multiple.
+, withAllTargets ? false, libbfd, libopcodes
+, enableShared ? !stdenv.hostPlatform.isStatic
+, noSysDirs
+, gold ? true
+, bison ? null
+, flex
+, texinfo
+, perl
+}:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+let
+  reuseLibs = enableShared && withAllTargets;
+
+  version = "2.35.1";
+  basename = "binutils";
+  # The targetPrefix prepended to binary names to allow multiple binuntils on the
+  # PATH to both be usable.
+  targetPrefix = lib.optionalString (stdenv.targetPlatform != stdenv.hostPlatform)
+                  "${stdenv.targetPlatform.config}-";
+  vc4-binutils-src = fetchFromGitHub {
+    owner = "itszor";
+    repo = "binutils-vc4";
+    rev = "708acc851880dbeda1dd18aca4fd0a95b2573b36";
+    sha256 = "1kdrz6fki55lm15rwwamn74fnqpy0zlafsida2zymk76n3656c63";
+  };
+  # HACK to ensure that we preserve source from bootstrap binutils to not rebuild LLVM
+  normal-src = stdenv.__bootPackages.binutils-unwrapped.src or (fetchurl {
+    url = "mirror://gnu/binutils/${basename}-${version}.tar.bz2";
+    sha256 = "sha256-Mg56HQ9G/Nn0E/EEbiFsviO7K85t62xqYzBEJeSLGUI=";
+  });
+in
+
+stdenv.mkDerivation {
+  pname = targetPrefix + basename;
+  inherit version;
+
+  src = if stdenv.targetPlatform.isVc4 then vc4-binutils-src else normal-src;
+
+  patches = [
+    # Make binutils output deterministic by default.
+    ./deterministic.patch
+
+    # Help bfd choose between elf32-littlearm, elf32-littlearm-symbian, and
+    # elf32-littlearm-vxworks in favor of the first.
+    # https://github.com/NixOS/nixpkgs/pull/30484#issuecomment-345472766
+    ./disambiguate-arm-targets.patch
+
+    # For some reason bfd ld doesn't search DT_RPATH when cross-compiling. It's
+    # not clear why this behavior was decided upon but it has the unfortunate
+    # consequence that the linker will fail to find transitive dependencies of
+    # shared objects when cross-compiling. Consequently, we are forced to
+    # override this behavior, forcing ld to search DT_RPATH even when
+    # cross-compiling.
+    ./always-search-rpath.patch
+
+    ./CVE-2020-35448.patch
+  ] ++ lib.optional stdenv.targetPlatform.isiOS ./support-ios.patch
+    ++ # This patch was suggested by Nick Clifton to fix
+       # https://sourceware.org/bugzilla/show_bug.cgi?id=16177
+       # It can be removed when that 7-year-old bug is closed.
+       # This binutils bug causes GHC to emit broken binaries on armv7, and
+       # indeed GHC will refuse to compile with a binutils suffering from it. See
+       # this comment for more information:
+       # https://gitlab.haskell.org/ghc/ghc/issues/4210#note_78333
+       lib.optional stdenv.targetPlatform.isAarch32 ./R_ARM_COPY.patch;
+
+  outputs = [ "out" "info" "man" ];
+
+  depsBuildBuild = [ buildPackages.stdenv.cc ];
+  nativeBuildInputs = [
+    bison
+    perl
+    texinfo
+  ] ++ (lib.optionals stdenv.targetPlatform.isiOS [
+    autoreconfHook
+  ]) ++ lib.optionals stdenv.targetPlatform.isVc4 [ flex ];
+  buildInputs = [ zlib gettext ];
+
+  inherit noSysDirs;
+
+  preConfigure = ''
+    # Clear the default library search path.
+    if test "$noSysDirs" = "1"; then
+        echo 'NATIVE_LIB_DIRS=' >> ld/configure.tgt
+    fi
+
+    # Use symlinks instead of hard links to save space ("strip" in the
+    # fixup phase strips each hard link separately).
+    for i in binutils/Makefile.in gas/Makefile.in ld/Makefile.in gold/Makefile.in; do
+        sed -i "$i" -e 's|ln |ln -s |'
+    done
+  '';
+
+  # As binutils takes part in the stdenv building, we don't want references
+  # to the bootstrap-tools libgcc (as uses to happen on arm/mips)
+  NIX_CFLAGS_COMPILE = if stdenv.hostPlatform.isDarwin
+    then "-Wno-string-plus-int -Wno-deprecated-declarations"
+    else "-static-libgcc";
+
+  hardeningDisable = [ "format" "pie" ];
+
+  configurePlatforms = [ "build" "host" "target" ];
+
+  configureFlags =
+    (if enableShared then [ "--enable-shared" "--disable-static" ]
+                     else [ "--disable-shared" "--enable-static" ])
+  ++ lib.optional withAllTargets "--enable-targets=all"
+  ++ [
+    "--enable-64-bit-bfd"
+    "--with-system-zlib"
+
+    "--enable-deterministic-archives"
+    "--disable-werror"
+    "--enable-fix-loongson2f-nop"
+
+    # Turn on --enable-new-dtags by default to make the linker set
+    # RUNPATH instead of RPATH on binaries.  This is important because
+    # RUNPATH can be overriden using LD_LIBRARY_PATH at runtime.
+    "--enable-new-dtags"
+
+    # force target prefix. Some versions of binutils will make it empty
+    # if `--host` and `--target` are too close, even if Nixpkgs thinks
+    # the platforms are different (e.g. because not all the info makes
+    # the `config`). Other versions of binutils will always prefix if
+    # `--target` is passed, even if `--host` and `--target` are the same.
+    # The easiest thing for us to do is not leave it to chance, and force
+    # the program prefix to be what we want it to be.
+    "--program-prefix=${targetPrefix}"
+  ] ++ lib.optionals gold [
+    "--enable-gold"
+    "--enable-plugins"
+  ];
+
+  doCheck = false; # fails
+
+  postFixup = lib.optionalString reuseLibs ''
+    rm "$out"/lib/lib{bfd,opcodes}-${version}.so
+    ln -s '${lib.getLib libbfd}/lib/libbfd-${version}.so' "$out/lib/"
+    ln -s '${lib.getLib libopcodes}/lib/libopcodes-${version}.so' "$out/lib/"
+  '';
+
+  # else fails with "./sanity.sh: line 36: $out/bin/size: not found"
+  doInstallCheck = stdenv.buildPlatform == stdenv.hostPlatform && stdenv.hostPlatform == stdenv.targetPlatform;
+
+  enableParallelBuilding = true;
+
+  passthru = {
+    inherit targetPrefix;
+    isGNU = true;
+  };
+
+  meta = with lib; {
+    description = "Tools for manipulating binaries (linker, assembler, etc.)";
+    longDescription = ''
+      The GNU Binutils are a collection of binary tools.  The main
+      ones are `ld' (the GNU linker) and `as' (the GNU assembler).
+      They also include the BFD (Binary File Descriptor) library,
+      `gprof', `nm', `strip', etc.
+    '';
+    homepage = "https://www.gnu.org/software/binutils/";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ ericson2314 ];
+    platforms = platforms.unix;
+
+    /* Give binutils a lower priority than gcc-wrapper to prevent a
+       collision due to the ld/as wrappers/symlinks in the latter. */
+    priority = 10;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/deterministic.patch b/nixpkgs/pkgs/development/tools/misc/binutils/deterministic.patch
new file mode 100644
index 000000000000..736e0aca6ce1
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/deterministic.patch
@@ -0,0 +1,12 @@
+diff -ur orig/binutils-2.23.1/ld/ldlang.c binutils-2.23.1/ld/ldlang.c
+--- orig/ld/ldlang.c
++++ new/ld/ldlang.c
+@@ -3095,6 +3095,8 @@
+                           ldfile_output_machine))
+     einfo (_("%P%F:%s: can not set architecture: %E\n"), name);
+ 
++  link_info.output_bfd->flags |= BFD_DETERMINISTIC_OUTPUT;
++
+   link_info.hash = bfd_link_hash_table_create (link_info.output_bfd);
+   if (link_info.hash == NULL)
+     einfo (_("%P%F: can not create hash table: %E\n"));
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/disambiguate-arm-targets.patch b/nixpkgs/pkgs/development/tools/misc/binutils/disambiguate-arm-targets.patch
new file mode 100644
index 000000000000..abbfa73da05d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/disambiguate-arm-targets.patch
@@ -0,0 +1,23 @@
+diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c
+index 9f956d3..f5b61f1 100644
+--- a/bfd/elf32-arm.c
++++ b/bfd/elf32-arm.c
+@@ -19585,7 +19585,10 @@ elf32_arm_vxworks_final_write_processing (bfd *abfd, bfd_boolean linker)
+ #undef  ELF_MAXPAGESIZE
+ #define ELF_MAXPAGESIZE			0x1000
+ 
++/* Prioritize elf32-*arm (priority 1) over elf32-*arm-vxworks (priority 2) */
++#define elf_match_priority 2
+ #include "elf32-target.h"
++#undef  elf_match_priority
+ 
+ 
+ /* Merge backend specific data from an object file to the output
+@@ -19974,4 +19977,7 @@ elf32_arm_symbian_plt_sym_val (bfd_vma i, const asection *plt,
+ #undef  ELF_MAXPAGESIZE
+ #define ELF_MAXPAGESIZE			0x8000
+ 
++/* Prioritize elf32-*arm (priority 1) over elf32-*arm-symbian (priority 2) */
++#define elf_match_priority 2
+ #include "elf32-target.h"
++#undef  elf_match_priority
diff --git a/nixpkgs/pkgs/development/tools/misc/binutils/support-ios.patch b/nixpkgs/pkgs/development/tools/misc/binutils/support-ios.patch
new file mode 100644
index 000000000000..74e56d130ed5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/binutils/support-ios.patch
@@ -0,0 +1,168 @@
+diff --git a/bfd/config.bfd b/bfd/config.bfd
+index f04a993f06..1e24a9d030 100644
+--- a/bfd/config.bfd
++++ b/bfd/config.bfd
+@@ -238,7 +238,7 @@ case "${targ}" in
+ 
+ # START OF targmatch.h
+ #ifdef BFD64
+-  aarch64-*-darwin*)
++  aarch64-*-darwin* | aarch64-*-ios*)
+     targ_defvec=aarch64_mach_o_vec
+     targ_selvecs="arm_mach_o_vec mach_o_le_vec mach_o_be_vec mach_o_fat_vec"
+     targ_archs="$targ_archs bfd_i386_arch bfd_powerpc_arch bfd_rs6000_arch"
+@@ -358,7 +358,7 @@ case "${targ}" in
+     targ_selvecs=arc_elf32_be_vec
+     ;;
+ 
+-  arm-*-darwin*)
++  arm-*-darwin* | arm-*-ios*)
+     targ_defvec=arm_mach_o_vec
+     targ_selvecs="mach_o_le_vec mach_o_be_vec mach_o_fat_vec"
+     targ_archs="$targ_archs bfd_i386_arch bfd_powerpc_arch bfd_rs6000_arch"
+@@ -678,7 +678,7 @@ case "${targ}" in
+   i[3-7]86-*-aix*)
+     targ_defvec=i386_coff_vec
+     ;;
+-  i[3-7]86-*-darwin* | i[3-7]86-*-macos10* | i[3-7]86-*-rhapsody*)
++  i[3-7]86-*-darwin* | i[3-7]86-*-ios* | i[3-7]86-*-macos10* | i[3-7]86-*-rhapsody*)
+     targ_defvec=i386_mach_o_vec
+     targ_selvecs="mach_o_le_vec mach_o_be_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
+     targ64_selvecs=x86_64_mach_o_vec
+@@ -762,7 +762,7 @@ case "${targ}" in
+     targ_defvec=x86_64_elf64_cloudabi_vec
+     want64=true
+     ;;
+-  x86_64-*-darwin*)
++  x86_64-*-darwin* | x86_64-*-ios*)
+     targ_defvec=x86_64_mach_o_vec
+     targ_selvecs="i386_mach_o_vec mach_o_le_vec mach_o_be_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
+     targ_archs="$targ_archs bfd_powerpc_arch bfd_rs6000_arch"
+@@ -1402,7 +1402,7 @@ case "${targ}" in
+     targ_selvecs="powerpc_elf32_le_vec powerpc_boot_vec"
+     targ64_selvecs="powerpc_elf64_vec powerpc_elf64_le_vec"
+     ;;
+-  powerpc-*-darwin* | powerpc-*-macos10* | powerpc-*-rhapsody*)
++  powerpc-*-darwin* | powerpc-*-ios* | powerpc-*-macos10* | powerpc-*-rhapsody*)
+     targ_defvec=mach_o_be_vec
+     targ_selvecs="mach_o_be_vec mach_o_le_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
+     targ_archs="$targ_archs bfd_i386_arch"
+diff --git a/configure.ac b/configure.ac
+index aae94501e4..2cceb4dad4 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -510,7 +510,7 @@ if test x$enable_libgomp = x ; then
+ 	;;
+     *-*-solaris2* | *-*-hpux11*)
+ 	;;
+-    *-*-darwin* | *-*-aix*)
++    *-*-darwin* | *-*-ios* | *-*-aix*)
+ 	;;
+     nvptx*-*-*)
+ 	;;
+@@ -700,13 +700,13 @@ esac
+ 
+ # Disable libffi for some systems.
+ case "${target}" in
+-  powerpc-*-darwin*)
++  powerpc-*-darwin* | powerpc-*-ios*)
+     ;;
+-  i[[3456789]]86-*-darwin*)
++  i[[3456789]]86-*-darwin* | i[[3456789]]86-*-ios*)
+     ;;
+-  x86_64-*-darwin[[912]]*)
++  x86_64-*-darwin[[912]]* | x86_64-*-ios[[912]]*)
+     ;;
+-  *-*-darwin*)
++  *-*-darwin* | *-*-ios*)
+     noconfigdirs="$noconfigdirs target-libffi"
+     ;;
+   *-*-netware*)
+@@ -788,7 +788,7 @@ esac
+ # Disable the go frontend on systems where it is known to not work. Please keep
+ # this in sync with contrib/config-list.mk.
+ case "${target}" in
+-*-*-darwin* | *-*-cygwin* | *-*-mingw*)
++*-*-darwin* | *-*-ios* | *-*-cygwin* | *-*-mingw*)
+     unsupported_languages="$unsupported_languages go"
+     ;;
+ esac
+@@ -797,7 +797,7 @@ esac
+ # For testing, you can easily override this with --enable-libgo.
+ if test x$enable_libgo = x; then
+     case "${target}" in
+-    *-*-darwin*)
++    *-*-darwin* | *-*-ios*)
+ 	# PR 46986
+ 	noconfigdirs="$noconfigdirs target-libgo"
+ 	;;
+@@ -916,27 +916,27 @@ esac
+ case "${target}" in
+   *-*-chorusos)
+     ;;
+-  aarch64-*-darwin*)
++  aarch64-*-darwin* | aarch64-*-ios*)
+     noconfigdirs="$noconfigdirs ld gas gdb gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
+-  arm-*-darwin*)
++  arm-*-darwin* | arm-*-ios*)
+     noconfigdirs="$noconfigdirs ld gas gdb gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
+-  powerpc-*-darwin*)
++  powerpc-*-darwin* | powerpc-*-ios*)
+     noconfigdirs="$noconfigdirs ld gas gdb gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
+-  i[[3456789]]86-*-darwin*)
++  i[[3456789]]86-*-darwin* | i[[3456789]]86-*-ios*)
+     noconfigdirs="$noconfigdirs ld gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
+-  x86_64-*-darwin[[912]]*)
++  x86_64-*-darwin[[912]]* | x86_64-*-ios[[912]]*)
+     noconfigdirs="$noconfigdirs ld gas gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
+-  *-*-darwin*)
++  *-*-darwin* | *-*-ios*)
+     noconfigdirs="$noconfigdirs ld gas gdb gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
+@@ -1226,7 +1226,7 @@ case "${host}" in
+   hppa*-*)	
+     host_makefile_frag="config/mh-pa"
+     ;;
+-  *-*-darwin*)
++  *-*-darwin* | *-*-ios*)
+     host_makefile_frag="config/mh-darwin"
+     ;;
+   powerpc-*-aix*)
+@@ -1697,7 +1697,7 @@ ACX_ELF_TARGET_IFELSE([# ELF platforms build the lto-plugin always.
+   build_lto_plugin=yes
+ ],[if test x"$default_enable_lto" = x"yes" ; then
+     case $target in
+-      *-apple-darwin[[912]]* | *-cygwin* | *-mingw* | *djgpp*) ;;
++      *-apple-darwin[[912]]* | *-apple-ios[[912]]* | *-cygwin* | *-mingw* | *djgpp*) ;;
+       # On other non-ELF platforms, LTO has yet to be validated.
+       *) enable_lto=no ;;
+     esac
+@@ -1708,7 +1708,7 @@ ACX_ELF_TARGET_IFELSE([# ELF platforms build the lto-plugin always.
+   # warn during gcc/ subconfigure; unless you're bootstrapping with
+   # -flto it won't be needed until after installation anyway.
+     case $target in
+-      *-cygwin* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
++      *-cygwin* | *-mingw* | *-apple-darwin* | *-apple-ios* | *djgpp*) ;;
+       *) if test x"$enable_lto" = x"yes"; then
+ 	AC_MSG_ERROR([LTO support is not enabled for this target.])
+         fi
+@@ -2590,7 +2590,7 @@ rm -f conftest*
+ # Decide which environment variable is used to find dynamic libraries.
+ case "${host}" in
+   *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
+-  *-*-darwin*) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
++  *-*-darwin* | *-*-ios* ) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
+   *-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
+   *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
+ esac
diff --git a/nixpkgs/pkgs/development/tools/misc/blackfire/default.nix b/nixpkgs/pkgs/development/tools/misc/blackfire/default.nix
new file mode 100644
index 000000000000..31c5d0d26e8f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/blackfire/default.nix
@@ -0,0 +1,52 @@
+{ stdenv
+, lib
+, fetchurl
+, dpkg
+, autoPatchelfHook
+, writeShellScript
+, curl
+, jq
+, common-updater-scripts
+}:
+
+stdenv.mkDerivation rec {
+  pname = "blackfire-agent";
+  version = "1.46.0";
+
+  src = fetchurl {
+    url = "https://packages.blackfire.io/debian/pool/any/main/b/blackfire-php/blackfire-agent_${version}_amd64.deb";
+    sha256 = "0cxgc18xpwyb5wp08km7aj8asn5biqnwq9fkgkk6wv1r1ihqlhf2";
+  };
+
+  nativeBuildInputs = [
+    dpkg
+    autoPatchelfHook
+  ];
+
+  dontUnpack = true;
+
+  installPhase = ''
+    runHook preInstall
+
+    dpkg-deb -x $src $out
+    mv $out/usr/* $out
+    rmdir $out/usr
+
+    runHook postInstall
+  '';
+
+  passthru = {
+    updateScript = writeShellScript "update-${pname}" ''
+      export PATH="${lib.makeBinPath [ curl jq common-updater-scripts ]}"
+      update-source-version "$UPDATE_NIX_ATTR_PATH" "$(curl https://blackfire.io/api/v1/releases | jq .agent --raw-output)"
+    '';
+  };
+
+  meta = with lib; {
+    description = "Blackfire Profiler agent and client";
+    homepage = "https://blackfire.io/";
+    license = licenses.unfree;
+    maintainers = with maintainers; [ jtojnar ];
+    platforms = [ "x86_64-linux" ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/blackfire/php-probe.nix b/nixpkgs/pkgs/development/tools/misc/blackfire/php-probe.nix
new file mode 100644
index 000000000000..e9bc52874018
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/blackfire/php-probe.nix
@@ -0,0 +1,64 @@
+{ stdenv
+, lib
+, fetchurl
+, dpkg
+, autoPatchelfHook
+, php
+, writeShellScript
+, curl
+, jq
+, common-updater-scripts
+}:
+
+let
+  soFile = {
+    "7.3" = "blackfire-20180731";
+    "7.4" = "blackfire-20190902";
+    "8.0" = "blackfire-20200930";
+  }.${lib.versions.majorMinor php.version} or (throw "Unsupported PHP version.");
+in stdenv.mkDerivation rec {
+  pname = "php-blackfire";
+  version = "1.53.0";
+
+  src = fetchurl {
+    url = "https://packages.blackfire.io/debian/pool/any/main/b/blackfire-php/blackfire-php_${version}_amd64.deb";
+    sha256 = "ApKj5gulTCzWh7oSAM+JWQnWviHCnHV3OJHegpXJL54=";
+  };
+
+  nativeBuildInputs = [
+    dpkg
+    autoPatchelfHook
+  ];
+
+  unpackPhase = ''
+    runHook preUnpack
+
+    dpkg-deb -x $src pkg
+    sourceRoot=pkg
+
+    runHook postUnpack
+  '';
+
+  installPhase = ''
+    runHook preInstall
+
+    install -D usr/lib/blackfire-php/amd64/${soFile}${lib.optionalString php.ztsSupport "-zts"}.so $out/lib/php/extensions/blackfire.so
+
+    runHook postInstall
+  '';
+
+  passthru = {
+    updateScript = writeShellScript "update-${pname}" ''
+      export PATH="${lib.makeBinPath [ curl jq common-updater-scripts ]}"
+      update-source-version "$UPDATE_NIX_ATTR_PATH" "$(curl https://blackfire.io/api/v1/releases | jq .probe.php --raw-output)"
+    '';
+  };
+
+  meta = with lib; {
+    description = "Blackfire Profiler PHP module";
+    homepage = "https://blackfire.io/";
+    license = licenses.unfree;
+    maintainers = with maintainers; [ jtojnar ];
+    platforms = [ "x86_64-linux" ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/blackmagic/default.nix b/nixpkgs/pkgs/development/tools/misc/blackmagic/default.nix
new file mode 100644
index 000000000000..f3b3b0b2d04b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/blackmagic/default.nix
@@ -0,0 +1,78 @@
+{ stdenv, lib, fetchFromGitHub, fetchpatch
+, gcc-arm-embedded, libftdi1, libusb-compat-0_1, pkg-config
+, python3
+}:
+
+with lib;
+
+stdenv.mkDerivation rec {
+  pname = "blackmagic";
+  version = "unstable-2020-08-05";
+  # `git describe --always`
+  firmwareVersion = "v1.6.1-539-gdd74ec8";
+
+  src = fetchFromGitHub {
+    owner = "blacksphere";
+    repo = "blackmagic";
+    rev = "dd74ec8e6f734302daa1ee361af88dfb5043f166";
+    sha256 = "18w8y64fs7wfdypa4vm3migk5w095z8nbd8qp795f322mf2bz281";
+    fetchSubmodules = true;
+  };
+
+  patches = [
+    # Fix deprecation warning with libftdi 1.5
+    (fetchpatch {
+      url = "https://github.com/blacksphere/blackmagic/commit/dea4be2539c5ea63836ec78dca08b52fa8b26ab5.patch";
+      sha256 = "0f81simij1wdhifsxaavalc6yxzagfbgwry969dbjmxqzvrsrds5";
+    })
+  ];
+
+  nativeBuildInputs = [
+    gcc-arm-embedded pkg-config
+    python3
+  ];
+
+  buildInputs = [
+    libftdi1
+    libusb-compat-0_1
+  ];
+
+  strictDeps = true;
+
+  postPatch = ''
+    # Prevent calling out to `git' to generate a version number:
+    substituteInPlace src/Makefile \
+      --replace '$(shell git describe --always --dirty)' '${firmwareVersion}'
+
+    # Fix scripts that generate headers:
+    for f in $(find scripts libopencm3/scripts -type f); do
+      patchShebangs "$f"
+    done
+  '';
+
+  buildPhase = "${stdenv.shell} ${./helper.sh}";
+  dontInstall = true;
+
+  enableParallelBuilding = true;
+
+  meta = {
+    description = "In-application debugger for ARM Cortex microcontrollers";
+    longDescription = ''
+      The Black Magic Probe is a modern, in-application debugging tool
+      for embedded microprocessors. It allows you to see what is going
+      on "inside" an application running on an embedded microprocessor
+      while it executes.
+
+      This package builds the firmware for all supported platforms,
+      placing them in separate directories under the firmware
+      directory.  It also places the FTDI version of the blackmagic
+      executable in the bin directory.
+    '';
+    homepage = "https://github.com/blacksphere/blackmagic";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ pjones emily sorki ];
+    # fails on darwin with
+    # arm-none-eabi-gcc: error: unrecognized command line option '-iframework'
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/blackmagic/helper.sh b/nixpkgs/pkgs/development/tools/misc/blackmagic/helper.sh
new file mode 100755
index 000000000000..bae57f633cfb
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/blackmagic/helper.sh
@@ -0,0 +1,52 @@
+################################################################################
+# Build all of the platforms manually since the `all_platforms' target
+# doesn't preserve all of the build outputs and overrides CFLAGS.
+set -e
+set -u
+
+################################################################################
+# Prevent a warning from shellcheck:
+out=${out:-/tmp}
+
+################################################################################
+export CFLAGS=$NIX_CFLAGS_COMPILE
+export MAKEFLAGS="\
+  ${enableParallelBuilding:+-j${NIX_BUILD_CORES} -l${NIX_BUILD_CORES}}"
+
+################################################################################
+PRODUCTS="blackmagic.bin blackmagic.hex blackmagic_dfu.bin blackmagic_dfu.hex"
+
+################################################################################
+make_platform() {
+  echo "Building for hardware platform $1"
+
+  make clean
+  make PROBE_HOST="$1"
+
+  if [ "$1" = "hosted" ]; then
+    install -m 0555 blackmagic "$out/bin"
+  fi
+
+  for f in $PRODUCTS; do
+    if [ -r "$f" ]; then
+      mkdir -p "$out/firmware/$1"
+      install -m 0444 "$f" "$out/firmware/$1"
+    fi
+  done
+
+}
+
+################################################################################
+# Start by building libopencm3:
+make -C libopencm3
+
+################################################################################
+# And now all of the platforms:
+cd src
+
+mkdir -p "$out/bin"
+
+for platform in platforms/*/Makefile.inc; do
+  probe=$(basename "$(dirname "$platform")")
+  make_platform "$probe"
+done
diff --git a/nixpkgs/pkgs/development/tools/misc/bonnmotion/default.nix b/nixpkgs/pkgs/development/tools/misc/bonnmotion/default.nix
new file mode 100644
index 000000000000..7ec9f3e1400a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bonnmotion/default.nix
@@ -0,0 +1,50 @@
+{ stdenv, lib, fetchzip, substituteAll, bash, jre }:
+
+stdenv.mkDerivation rec {
+  pname = "bonnmotion";
+  version = "3.0.1";
+
+  src = fetchzip {
+    url = "https://sys.cs.uos.de/bonnmotion/src/bonnmotion-${version}.zip";
+    sha256 = "16bjgr0hy6an892m5r3x9yq6rqrl11n91f9rambq5ik1cxjqarxw";
+  };
+
+  patches = [
+    # The software has a non-standard install bash script which kind of works.
+    # However, to make it fully functional, the automatically detection of the
+    # program paths must be substituted with full paths.
+    (substituteAll {
+      src = ./install.patch;
+      inherit bash jre;
+    })
+  ];
+
+  installPhase = ''
+    runHook preInstall
+
+    ./install
+
+    mkdir -p $out/bin $out/share/bonnmotion
+    cp -r ./classes ./lib $out/share/bonnmotion/
+    cp ./bin/bm $out/bin/
+
+    substituteInPlace $out/bin/bm \
+      --replace /build/source $out/share/bonnmotion
+
+    runHook postInstall
+  '';
+
+  meta = with lib; {
+    description = "A mobility scenario generation and analysis tool";
+    longDescription = ''
+      BonnMotion is a Java software which creates and analyzes mobility
+      scenarios and is most commonly used as a tool for the investigation of
+      mobile ad hoc network characteristics. The scenarios can also be exported
+      for several network simulators, such as ns-2, ns-3, GloMoSim/QualNet,
+      COOJA, MiXiM, and ONE.
+    '';
+    homepage = "https://sys.cs.uos.de/bonnmotion/";
+    license = licenses.gpl2Plus;
+    maintainers = with maintainers; [ oxzi ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/bonnmotion/install.patch b/nixpkgs/pkgs/development/tools/misc/bonnmotion/install.patch
new file mode 100644
index 000000000000..86be99b3dd5e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bonnmotion/install.patch
@@ -0,0 +1,75 @@
+diff --git a/install b/install
+index 95afa2c..70c5fca 100755
+--- a/install
++++ b/install
+@@ -1,4 +1,4 @@
+-#!/bin/bash
++#!@bash@/bin/bash
+ 
+ echo "BonnMotion - a mobility scenario generation and analysis tool"
+ echo "Copyright (C) 2002-2012 University of Bonn"
+@@ -19,28 +19,11 @@ echo "along with this program; if not, write to the Free Software"
+ echo "Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA"
+ echo
+ 
+-OS=`uname -s | tr A-Z a-z | sed -e s/_.\*//`
+-
+ PACKAGE=edu.bonn.cs.iv.bonnmotion
+-JAVAPATH=`which java 2> /dev/null`
+-if [ ! "$JAVAPATH" = "" ]
+-then
+-	JAVAPATH=`dirname ${JAVAPATH}`
+-fi
+-echo -n Please enter your Java binary path \[$JAVAPATH\]:\ 
+-read KBDENTRY
+-if [ ! "$KBDENTRY" = "" ]
+-then
+-	JAVAPATH=$KBDENTRY
+-fi
++JAVAPATH="@jre@/bin"
+ if [ -x "${JAVAPATH}/java" ]
+ then
+-	cd `dirname $0`
+-	BONNMOTION=`pwd`
+-
+-	cd "${JAVAPATH}"
+-	JAVAPATH=`pwd`
+-	cd "${BONNMOTION}"
++  BONNMOTION="$(realpath .)"
+ 
+ 	CLASSPATH="${BONNMOTION}/classes"
+ 	DOCPATH="${BONNMOTION}/javadoc"
+@@ -52,14 +35,7 @@ then
+ 	then
+ 		mkdir "${DOCPATH}"
+ 	fi
+-	if [ $OS = "cygwin" ]
+-	then
+-		cd "${CLASSPATH}"
+-		CLASSPATH=`cmd.exe /c cd`
+-		cd "${DOCPATH}"
+-		DOCPATH=`cmd.exe /c cd`
+-	fi
+-	
++
+ 	for l in $BONNMOTION/lib/*.jar
+ 	do
+ 		LIBRARYPATH=$LIBRARYPATH:$l
+@@ -69,7 +45,7 @@ then
+ 	APPS=`ls`
+ 	cd "${BONNMOTION}/bin"
+ 
+-	echo \#\!/bin/bash > .head
++	echo \#\!@bash@/bin/bash > .head
+ 	echo >> .head
+ 	echo BONNMOTION=\"$BONNMOTION\" >> .head
+ 	echo PACKAGE=\"$PACKAGE\" >> .head
+@@ -103,8 +79,6 @@ then
+ 	fi
+ 	echo "done."
+ 	echo
+-	echo "$ ./bin/bm -h"
+-	./bm
+ else
+ 	echo No executable \"$JAVAPATH/java\", aborting.
+ fi
diff --git a/nixpkgs/pkgs/development/tools/misc/bossa/bin2c.c b/nixpkgs/pkgs/development/tools/misc/bossa/bin2c.c
new file mode 100644
index 000000000000..f0b915de540a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bossa/bin2c.c
@@ -0,0 +1,122 @@
+// bin2c.c
+//
+// convert a binary file into a C source vector
+//
+// THE "BEER-WARE LICENSE" (Revision 3.1415):
+// sandro AT sigala DOT it wrote this file. As long as you retain this notice you can do
+// whatever you want with this stuff.  If we meet some day, and you think this stuff is
+// worth it, you can buy me a beer in return.  Sandro Sigala
+//
+// syntax:  bin2c [-c] [-z] <input_file> <output_file>
+//
+//          -c    add the "const" keyword to definition
+//          -z    terminate the array with a zero (useful for embedded C strings)
+//
+// examples:
+//     bin2c -c myimage.png myimage_png.cpp
+//     bin2c -z sometext.txt sometext_txt.cpp
+ 
+#include <ctype.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+ 
+#ifndef PATH_MAX
+#define PATH_MAX 1024
+#endif
+ 
+int useconst = 0;
+int zeroterminated = 0;
+ 
+int myfgetc(FILE *f)
+{
+	int c = fgetc(f);
+	if (c == EOF && zeroterminated)
+	{
+		zeroterminated = 0;
+		return 0;
+	}
+	return c;
+}
+ 
+void process(const char *ifname, const char *ofname)
+{
+	FILE *ifile, *ofile;
+	ifile = fopen(ifname, "rb");
+	if (ifile == NULL)
+	{
+		fprintf(stderr, "cannot open %s for reading\n", ifname);
+		exit(1);
+	}
+	ofile = fopen(ofname, "wb");
+	if (ofile == NULL)
+	{
+		fprintf(stderr, "cannot open %s for writing\n", ofname);
+		exit(1);
+	}
+	char buf[PATH_MAX], *p;
+	const char *cp;
+	if ((cp = strrchr(ifname, '/')) != NULL)
+	{
+		++cp;
+	} else {
+		if ((cp = strrchr(ifname, '\\')) != NULL)
+			++cp;
+		else
+			cp = ifname;
+	}
+	strcpy(buf, cp);
+	for (p = buf; *p != '\0'; ++p)
+	{
+		if (!isalnum(*p))
+			*p = '_';
+	}
+	fprintf(ofile, "static %sunsigned char %s[] = {\n", useconst ? "const " : "", buf);
+	int c, col = 1;
+	while ((c = myfgetc(ifile)) != EOF)
+	{
+		if (col >= 78 - 6)
+		{
+			fputc('\n', ofile);
+			col = 1;
+		}
+		fprintf(ofile, "0x%.2x, ", c);
+		col += 6;
+	}
+	fprintf(ofile, "\n};\n");
+ 
+	fclose(ifile);
+	fclose(ofile);
+}
+ 
+void usage(void)
+{
+	fprintf(stderr, "usage: bin2c [-cz] <input_file> <output_file>\n");
+	exit(1);
+}
+ 
+int main(int argc, char **argv)
+{
+	while (argc > 3)
+	{
+		if (!strcmp(argv[1], "-c"))
+		{
+			useconst = 1;
+			--argc;
+			++argv;
+		} else if (!strcmp(argv[1], "-z"))
+		{
+			zeroterminated = 1;
+			--argc;
+			++argv;
+		} else {
+			usage();
+		}
+	}
+	if (argc != 3)
+	{
+		usage();
+	}
+	process(argv[1], argv[2]);
+	return 0;
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/bossa/bossa-no-applet-build.patch b/nixpkgs/pkgs/development/tools/misc/bossa/bossa-no-applet-build.patch
new file mode 100644
index 000000000000..4284245f485d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bossa/bossa-no-applet-build.patch
@@ -0,0 +1,16 @@
+diff --git a/Makefile b/Makefile
+index cc8882e..97b11ee 100644
+--- a/Makefile
++++ b/Makefile
+@@ -184,11 +184,6 @@ $(foreach src,$(COMMON_SRCS),$(eval $(call common_obj,$(src))))
+ # Applet rules
+ #
+ define applet_obj
+-$(SRCDIR)/$(1:%.asm=%.cpp): $(SRCDIR)/$(1)
+-	@echo APPLET $(1:%.asm=%)
+-	$$(Q)$$(ARMAS) -o $$(@:%.o=%.obj) $$<
+-	$$(Q)$$(ARMOBJCOPY) -O binary $$(@:%.o=%.obj) $$(@:%.o=%.bin)
+-	$$(Q)appletgen $(1:%.asm=%) $(SRCDIR) $(OBJDIR)
+ $(OBJDIR)/$(1:%.asm=%.o): $(SRCDIR)/$(1:%.asm=%.cpp)
+ 	@echo CPP APPLET $$<
+ 	$$(Q)$$(CXX) $$(COMMON_CXXFLAGS) -c -o $$(@) $$(<:%.asm=%.cpp)
diff --git a/nixpkgs/pkgs/development/tools/misc/bossa/default.nix b/nixpkgs/pkgs/development/tools/misc/bossa/default.nix
new file mode 100644
index 000000000000..74073722857f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bossa/default.nix
@@ -0,0 +1,52 @@
+{ lib, stdenv, fetchgit, wxGTK, libX11, readline }:
+
+let
+  # BOSSA needs a "bin2c" program to embed images.
+  # Source taken from:
+  # http://wiki.wxwidgets.org/Embedding_PNG_Images-Bin2c_In_C
+  bin2c = stdenv.mkDerivation {
+    name = "bossa-bin2c";
+    src = ./bin2c.c;
+    dontUnpack = true;
+    buildPhase = "cc $src -o bin2c";
+    installPhase = "mkdir -p $out/bin; cp bin2c $out/bin/";
+  };
+
+in
+stdenv.mkDerivation {
+  name = "bossa-1.8";
+
+  src = fetchgit {
+    url = "https://github.com/shumatech/BOSSA";
+    rev = "3be622ca0aa6214a2fc51c1ec682c4a58a423d62";
+    sha256 = "19ik86qbffcb04cgmi4mnascbkck4ynfj87ha65qdk6fmp5q35vm";
+  };
+
+  patches = [ ./bossa-no-applet-build.patch ];
+
+  nativeBuildInputs = [ bin2c ];
+  buildInputs = [ wxGTK libX11 readline ];
+
+  # Explicitly specify targets so they don't get stripped.
+  makeFlags = [ "bin/bossac" "bin/bossash" "bin/bossa" ];
+  NIX_CFLAGS_COMPILE = "-Wno-error=deprecated-declarations";
+
+  installPhase = ''
+    mkdir -p $out/bin
+    cp bin/bossa{c,sh,} $out/bin/
+  '';
+
+  meta = with lib; {
+    description = "A flash programming utility for Atmel's SAM family of flash-based ARM microcontrollers";
+    longDescription = ''
+      BOSSA is a flash programming utility for Atmel's SAM family of
+      flash-based ARM microcontrollers. The motivation behind BOSSA is
+      to create a simple, easy-to-use, open source utility to replace
+      Atmel's SAM-BA software. BOSSA is an acronym for Basic Open
+      Source SAM-BA Application to reflect that goal.
+    '';
+    homepage = "http://www.shumatech.com/web/products/bossa";
+    license = licenses.bsd3;
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/bsdbuild/default.nix b/nixpkgs/pkgs/development/tools/misc/bsdbuild/default.nix
new file mode 100644
index 000000000000..e3bfc958437a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/bsdbuild/default.nix
@@ -0,0 +1,68 @@
+{ lib, stdenv, fetchurl, perl, libtool, pkg-config, gettext, mandoc, ed }:
+
+stdenv.mkDerivation rec {
+  pname = "bsdbuild";
+  version = "3.1";
+
+  src = fetchurl {
+    url = "http://stable.hypertriton.com/bsdbuild/${pname}-${version}.tar.gz";
+    sha256 = "1zrdjh7a6z4khhfw9zrp490afq306cpl5v8wqz2z55ys7k1n5ifl";
+  };
+
+  buildInputs = [ perl mandoc ed ];
+  nativeBuildInputs = [ pkg-config libtool gettext ];
+
+  prePatch = ''
+    #ignore unfamiliar flags
+    substituteInPlace configure \
+      --replace '--sbindir=*' '--sbindir=* | --includedir=* | --oldincludedir=*'
+    #same for packages using bsdbuild
+    substituteInPlace mkconfigure.pl \
+      --replace '--sbindir=*' '--sbindir=* | --includedir=* | --oldincludedir=*'
+    #insert header for missing NULL macro
+    for f in db4.pm sdl_ttf.pm mysql.pm uim.pm strlcpy.pm getpwuid.pm \
+      getaddrinfo.pm strtoll.pm free_null.pm getpwnam_r.pm \
+      gettimeofday.pm gethostbyname.pm xinerama.pm strsep.pm \
+      fontconfig.pm gettext.pm pthreads.pm strlcat.pm kqueue.pm wgl.pm \
+      alsa.pm crypt.pm cracklib.pm freesg-rg.pm edacious.pm mmap.pm \
+      agar.pm x11.pm x11.pm execvp.pm agar-core.pm dyld.pm getopt.pm \
+      strtold.pm sdl_image.pm shl_load.pm glx.pm percgi.pm timerfd.pm \
+      glob.pm dlopen.pm freesg.pm csidl.pm perl.pm select.pm \
+      portaudio.pm etubestore.pm;
+    do
+ed -s -v BSDBuild/$f << EOF
+/#include
+i
+#include <stddef.h>
+.
+w
+EOF
+    done
+  '';
+
+  configureFlags = [
+    "--with-libtool=${libtool}/bin/libtool"
+    "--enable-nls=yes"
+    "--with-gettext=${gettext}"
+    "--with-manpages=yes"
+  ];
+
+  meta = {
+    homepage = "http://bsdbuild.hypertriton.com";
+    description = "A cross-platform build system";
+
+    longDescription = ''
+      BSDBuild is a cross-platform build system. Derived from the
+      traditional 4.4BSD make libraries, BSDBuild allows BSD-style
+      Makefiles (without BSD make extensions), and works natively
+      under most operating systems and make flavors. Since BSDBuild
+      is implemented as a library (as opposed to a macro package),
+      Makefiles are edited directly, as opposed to being compiled
+      (however, if the build directory is separate from the source
+      directory, BSDBuild will produce the required Makefiles in place).
+    '';
+
+    license = lib.licenses.bsd3;
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/c2ffi/default.nix b/nixpkgs/pkgs/development/tools/misc/c2ffi/default.nix
new file mode 100644
index 000000000000..b7a5b1dc7eb8
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/c2ffi/default.nix
@@ -0,0 +1,56 @@
+{ lib
+, fetchFromGitHub
+, cmake
+, llvmPackages_11
+, unstableGitUpdater
+}:
+
+let
+  c2ffiBranch = "llvm-11.0.0";
+  llvmPackages = llvmPackages_11;
+in
+
+llvmPackages.stdenv.mkDerivation {
+  pname = "c2ffi-${c2ffiBranch}";
+  version = "unstable-2021-04-15";
+
+  src = fetchFromGitHub {
+    owner = "rpav";
+    repo = "c2ffi";
+    rev = "0255131f80b21334e565231331c2b451b6bba8c4";
+    sha256 = "0ihysgqjyg5xwi098hxf15lpdi6g4nwpzczp495is912c48fy6b6";
+  };
+
+  passthru.updateScript = unstableGitUpdater {
+    url = "https://github.com/rpav/c2ffi.git";
+    branch = c2ffiBranch;
+  };
+
+  nativeBuildInputs = [
+    cmake
+  ];
+
+  buildInputs = [
+    llvmPackages.llvm
+    llvmPackages.clang
+    llvmPackages.libclang
+  ];
+
+  # This isn't much, but...
+  doInstallCheck = true;
+  installCheckPhase = ''
+    $out/bin/c2ffi --help 2>&1 >/dev/null
+  '';
+
+  # LLVM may be compiled with -fno-rtti, so let's just turn it off.
+  # A mismatch between lib{clang,LLVM}* and us can lead to the link time error:
+  # undefined reference to `typeinfo for clang::ASTConsumer'
+  CXXFLAGS="-fno-rtti";
+
+  meta = with lib; {
+    homepage = "https://github.com/rpav/c2ffi";
+    description = "An LLVM based tool for extracting definitions from C, C++, and Objective C header files for use with foreign function call interfaces";
+    license = licenses.lgpl21Only;
+    maintainers = with maintainers; [ attila-lendvai ];
+ };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cbrowser/backslashes-quotes.diff b/nixpkgs/pkgs/development/tools/misc/cbrowser/backslashes-quotes.diff
new file mode 100644
index 000000000000..cc42f0745da5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cbrowser/backslashes-quotes.diff
@@ -0,0 +1,49 @@
+Based on this:
+http://sourceforge.net/tracker/?func=detail&aid=1493886&group_id=5152&atid=305152
+fix the infinite loops in quote highlight - ID: 1493886
+
+--- cbrowser-0.8-2/ftcllib.tcl	2000-07-04 01:17:43.000000000 +0200
++++ cbrowser-0.8/ftcllib.tcl	2006-05-24 00:39:18.833762522 +0200
+@@ -1290,13 +1290,39 @@
+   foreach {start end} [concat 1.0 [$widget tag ranges comment] end] {
+ 
+     while {[set temp [$widget search -regexp -- $pattern $start $end]] != ""} {
++      set startquote [$widget index "$temp + 1chars"]
+ 
+-      set endquote [$widget search -regexp -- {[^\\]\"} "$temp + 1chars" $end]
++      set temp [$widget index "$startquote + 1chars"]
++      while {1==1} {
++        set endquote [$widget search -regexp -- {\"} $temp $end]
++
++	# The program will not break if a /*C comment*/ is between C quotes.
++	if { $endquote == "" } {
++	  set endquote $startquote
++	  break
++	}
++
++        # look for double backslashes
++	if {[set temp2 [$widget search -regexp -- {\\\\} $temp $endquote]] != ""} {
++	  set temp "$temp2 + 2chars"
++	  continue
++	}
++        
++        # look for \"
++	if {[set temp2 [$widget search -regexp -- {\\\"} $temp $endquote]] != ""} {
++	  set temp "$temp2 + 2chars"
++	  continue
++	}
++
++	break
++      }
+ 
+       if {[strlen $endquote] > 0} {
+-        set start [$widget index "$endquote + 2chars"]
++        set start [$widget index "$endquote + 1chars"]
+ 
+-        $widget tag add quote "$temp + 1chars" $start
++        $widget tag add quote $startquote $start
++      } else {
++        set start [$widget index "$start + 1chars"]
+       }
+     }
+   }
diff --git a/nixpkgs/pkgs/development/tools/misc/cbrowser/default.nix b/nixpkgs/pkgs/development/tools/misc/cbrowser/default.nix
new file mode 100644
index 000000000000..62aa0ab5decf
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cbrowser/default.nix
@@ -0,0 +1,35 @@
+{ fetchurl, lib, stdenv, tk, makeWrapper }:
+
+stdenv.mkDerivation rec {
+  name = "cbrowser-0.8";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/cbrowser/cbrowser-0.8.tar.gz";
+    sha256 = "1050mirjab23qsnq3lp3a9vwcbavmh9kznzjm7dr5vkx8b7ffcji";
+  };
+
+  patches = [ ./backslashes-quotes.diff ];
+
+  nativeBuildInputs = [ makeWrapper ];
+  buildInputs = [ tk ];
+
+  installPhase = ''
+    mkdir -p $out/bin $out/share/${name}
+    cp -R * $out/share/${name}/
+
+    makeWrapper $out/share/${name}/cbrowser $out/bin/cbrowser \
+      --prefix PATH : ${tk}/bin
+  '';
+
+  meta = {
+    description = "Tcl/Tk GUI front-end to cscope";
+
+    license = lib.licenses.gpl2Plus;
+
+    homepage = "https://sourceforge.net/projects/cbrowser/";
+
+    maintainers = with lib.maintainers; [viric];
+
+    platforms = with lib.platforms; linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cc-tool/default.nix b/nixpkgs/pkgs/development/tools/misc/cc-tool/default.nix
new file mode 100644
index 000000000000..e2a511a0e328
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cc-tool/default.nix
@@ -0,0 +1,42 @@
+{ lib, stdenv
+, fetchFromGitHub
+, autoreconfHook
+, boost
+, libusb1
+, pkg-config
+}:
+
+stdenv.mkDerivation rec {
+  pname = "cc-tool";
+  version = "unstable-2020-05-19";
+
+  src = fetchFromGitHub {
+    owner = "dashesy";
+    repo = pname;
+    rev = "19e707eafaaddee8b996ad27a9f3e1aafcb900d2";
+    hash = "sha256:1f78j498fdd36xbci57jkgh25gq14g3b6xmp76imdpar0jkpyljv";
+  };
+
+  nativeBuildInputs = [ autoreconfHook pkg-config ];
+  buildInputs = [ boost libusb1 ];
+
+  postPatch = ''
+    substituteInPlace udev/90-cc-debugger.rules \
+      --replace 'MODE="0666"' 'MODE="0660", GROUP="plugdev", TAG+="uaccess"'
+  '';
+
+  postInstall = ''
+    install -D udev/90-cc-debugger.rules $out/lib/udev/rules.d/90-cc-debugger.rules
+  '';
+
+  meta = with lib; {
+    description = "Command line tool for the Texas Instruments CC Debugger";
+    longDescription = ''
+      cc-tool provides support for Texas Instruments CC Debugger
+    '';
+    homepage = "https://github.com/dashesy/cc-tool";
+    license = licenses.gpl2;
+    platforms = with platforms; linux ++ darwin;
+    maintainers = [ maintainers.CRTified ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/ccache/default.nix b/nixpkgs/pkgs/development/tools/misc/ccache/default.nix
new file mode 100644
index 000000000000..909a160c7eea
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ccache/default.nix
@@ -0,0 +1,115 @@
+{ lib
+, stdenv
+, fetchFromGitHub
+, fetchpatch
+, substituteAll
+, binutils
+, asciidoc
+, cmake
+, perl
+, zstd
+, bashInteractive
+, xcodebuild
+, makeWrapper
+}:
+
+let ccache = stdenv.mkDerivation rec {
+  pname = "ccache";
+  version = "4.3";
+
+  src = fetchFromGitHub {
+    owner = pname;
+    repo = pname;
+    rev = "v${version}";
+    hash = "sha256-ZBxDTMUZiZJLIYbvACTFwvlss+IZiMjiL0khfM5hFCM=";
+  };
+
+  outputs = [ "out" "man" ];
+
+  patches = [
+    # When building for Darwin, test/run uses dwarfdump, whereas on
+    # Linux it uses objdump. We don't have dwarfdump packaged for
+    # Darwin, so this patch updates the test to also use objdump on
+    # Darwin.
+    (substituteAll {
+      src = ./force-objdump-on-darwin.patch;
+      objdump = "${binutils.bintools}/bin/objdump";
+    })
+    # Fix clang C++ modules test (remove in next release)
+    (fetchpatch {
+      url = "https://github.com/ccache/ccache/commit/8b0c783ffc77d29a3e3520345b776a5c496fd892.patch";
+      sha256 = "13qllx0qhfrdila6bdij9lk74fhkm3vdj01zgq1ri6ffrv9lqrla";
+    })
+  ];
+
+  nativeBuildInputs = [ asciidoc cmake perl ];
+  buildInputs = [ zstd ];
+
+  doCheck = true;
+  checkInputs = [
+    # test/run requires the compgen function which is available in
+    # bashInteractive, but not bash.
+    bashInteractive
+  ] ++ lib.optional stdenv.isDarwin xcodebuild;
+
+  checkPhase = ''
+    runHook preCheck
+    export HOME=$(mktemp -d)
+    ctest --output-on-failure ${lib.optionalString stdenv.isDarwin ''
+      -E '^(test.nocpp2|test.basedir|test.multi_arch)$'
+    ''}
+    runHook postCheck
+  '';
+
+  passthru = {
+    # A derivation that provides gcc and g++ commands, but that
+    # will end up calling ccache for the given cacheDir
+    links = {unwrappedCC, extraConfig}: stdenv.mkDerivation {
+      name = "ccache-links";
+      passthru = {
+        isClang = unwrappedCC.isClang or false;
+        isGNU = unwrappedCC.isGNU or false;
+      };
+      inherit (unwrappedCC) lib;
+      nativeBuildInputs = [ makeWrapper ];
+      buildCommand = ''
+        mkdir -p $out/bin
+
+        wrap() {
+          local cname="$1"
+          if [ -x "${unwrappedCC}/bin/$cname" ]; then
+            makeWrapper ${ccache}/bin/ccache $out/bin/$cname \
+              --run ${lib.escapeShellArg extraConfig} \
+              --add-flags ${unwrappedCC}/bin/$cname
+          fi
+        }
+
+        wrap cc
+        wrap c++
+        wrap gcc
+        wrap g++
+        wrap clang
+        wrap clang++
+
+        for executable in $(ls ${unwrappedCC}/bin); do
+          if [ ! -x "$out/bin/$executable" ]; then
+            ln -s ${unwrappedCC}/bin/$executable $out/bin/$executable
+          fi
+        done
+        for file in $(ls ${unwrappedCC} | grep -vw bin); do
+          ln -s ${unwrappedCC}/$file $out/$file
+        done
+      '';
+    };
+  };
+
+  meta = with lib; {
+    description = "Compiler cache for fast recompilation of C/C++ code";
+    homepage = "https://ccache.dev";
+    downloadPage = "https://ccache.dev/download.html";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ kira-bruneau r-burns ];
+    platforms = platforms.unix;
+  };
+};
+in ccache
diff --git a/nixpkgs/pkgs/development/tools/misc/ccache/force-objdump-on-darwin.patch b/nixpkgs/pkgs/development/tools/misc/ccache/force-objdump-on-darwin.patch
new file mode 100644
index 000000000000..81a4f27ab736
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ccache/force-objdump-on-darwin.patch
@@ -0,0 +1,31 @@
+diff --git a/test/run b/test/run
+index 9623e49d..3df1c5a8 100755
+--- a/test/run
++++ b/test/run
+@@ -126,23 +126,17 @@ file_size() {
+ objdump_cmd() {
+     local file="$1"
+ 
+-    if $HOST_OS_APPLE; then
+-        xcrun dwarfdump -r 0 "$file"
+-    elif $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then
++    if $HOST_OS_WINDOWS || $HOST_OS_CYGWIN; then
+         # For some reason objdump only shows the basename of the file, so fall
+         # back to brute force and ignorance.
+         strings "$1"
+     else
+-        objdump -W "$file"
++        @objdump@ -W "$file"
+     fi
+ }
+ 
+ objdump_grep_cmd() {
+-    if $HOST_OS_APPLE; then
+-        fgrep -q "\"$1\""
+-    else
+-        fgrep -q ": $1"
+-    fi
++    fgrep -q ": $1"
+ }
+ 
+ expect_stat() {
diff --git a/nixpkgs/pkgs/development/tools/misc/ccls/default.nix b/nixpkgs/pkgs/development/tools/misc/ccls/default.nix
new file mode 100644
index 000000000000..bd753016fc8b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ccls/default.nix
@@ -0,0 +1,41 @@
+{ lib, stdenv, fetchFromGitHub
+, cmake, llvmPackages, rapidjson, runtimeShell }:
+
+stdenv.mkDerivation rec {
+  pname = "ccls";
+  version = "0.20210330";
+
+  src = fetchFromGitHub {
+    owner = "MaskRay";
+    repo = "ccls";
+    rev = version;
+    sha256 = "sha256-jipSipgD0avd7XODlpxnqjHK3s6nacaxbIQIddix7X8=";
+  };
+
+  nativeBuildInputs = [ cmake llvmPackages.llvm.dev ];
+  buildInputs = with llvmPackages; [ libclang llvm rapidjson ];
+
+  cmakeFlags = [ "-DCCLS_VERSION=${version}" ];
+
+  preConfigure = ''
+    cmakeFlagsArray+=(-DCMAKE_CXX_FLAGS="-fvisibility=hidden -fno-rtti")
+  '';
+
+  clang = llvmPackages.clang;
+  shell = runtimeShell;
+
+  postFixup = ''
+    export wrapped=".ccls-wrapped"
+    mv $out/bin/ccls $out/bin/$wrapped
+    substituteAll ${./wrapper} $out/bin/ccls
+    chmod --reference=$out/bin/$wrapped $out/bin/ccls
+  '';
+
+  meta = with lib; {
+    description = "A c/c++ language server powered by clang";
+    homepage    = "https://github.com/MaskRay/ccls";
+    license     = licenses.asl20;
+    platforms   = platforms.linux ++ platforms.darwin;
+    maintainers = with maintainers; [ mic92 tobim ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/ccls/wrapper b/nixpkgs/pkgs/development/tools/misc/ccls/wrapper
new file mode 100644
index 000000000000..c92bc6b40d1a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ccls/wrapper
@@ -0,0 +1,9 @@
+#! @shell@ -e
+
+printf -v extraArgs ',\"%s\"' \
+  $(cat @clang@/nix-support/libc-cflags \
+        @clang@/nix-support/libcxx-cxxflags) \
+  ${NIX_CFLAGS_COMPILE}
+initString="--init={\"clang\":{\"extraArgs\":[${extraArgs:1}]}}"
+
+exec -a "$0" "@out@/bin/@wrapped@" "${initString}" "$@"
diff --git a/nixpkgs/pkgs/development/tools/misc/cflow/default.nix b/nixpkgs/pkgs/development/tools/misc/cflow/default.nix
new file mode 100644
index 000000000000..b9e75d7cb2a3
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cflow/default.nix
@@ -0,0 +1,50 @@
+{ lib, stdenv, fetchurl, gettext, emacs }:
+
+stdenv.mkDerivation rec {
+  name = "cflow-1.6";
+
+  src = fetchurl {
+    url = "mirror://gnu/cflow/${name}.tar.bz2";
+    sha256 = "1mzd3yf0dfv8h2av5vsxxlhpk21nw064h91b2kgfrdz92r0pnj1l";
+  };
+
+  patchPhase = ''
+    substituteInPlace "src/cflow.h"					\
+      --replace "/usr/bin/cpp"						\
+                "$(cat ${stdenv.cc}/nix-support/orig-cc)/bin/cpp"
+  '';
+
+  buildInputs = [ gettext ] ++
+    # We don't have Emacs/GTK/etc. on {Dar,Cyg}win.
+    lib.optional
+      (! (lib.lists.any (x: stdenv.hostPlatform.system == x)
+              [ "i686-cygwin" ]))
+      emacs;
+
+  doCheck = true;
+
+  meta = with lib; {
+    description = "Tool to analyze the control flow of C programs";
+
+    longDescription = ''
+      GNU cflow analyzes a collection of C source files and prints a
+      graph, charting control flow within the program.
+
+      GNU cflow is able to produce both direct and inverted flowgraphs
+      for C sources.  Optionally a cross-reference listing can be
+      generated.  Two output formats are implemented: POSIX and GNU
+      (extended).
+
+      The package also provides Emacs major mode for examining the
+      produced flowcharts in Emacs.
+    '';
+
+    license = licenses.gpl3Plus;
+
+    homepage = "https://www.gnu.org/software/cflow/";
+
+    maintainers = [ maintainers.vrthra ];
+
+    platforms = platforms.linux ++ platforms.darwin;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cgdb/default.nix b/nixpkgs/pkgs/development/tools/misc/cgdb/default.nix
new file mode 100644
index 000000000000..0e92d373c0b3
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cgdb/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchurl, ncurses, readline, flex, texinfo }:
+
+stdenv.mkDerivation rec {
+  pname = "cgdb";
+  version = "0.7.1";
+
+  src = fetchurl {
+    url = "https://cgdb.me/files/${pname}-${version}.tar.gz";
+    sha256 = "1671gpz5gx5j0zga8xy2x7h33vqh3nij93lbb6dbb366ivjknwmv";
+  };
+
+  buildInputs = [ ncurses readline flex texinfo ];
+
+  meta = with lib; {
+    description = "A curses interface to gdb";
+
+    homepage = "https://cgdb.github.io/";
+
+    repositories.git = "git://github.com/cgdb/cgdb.git";
+
+    license = licenses.gpl2Plus;
+
+    platforms = with platforms; linux ++ cygwin;
+    maintainers = with maintainers; [ vrthra ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/checkbashisms/default.nix b/nixpkgs/pkgs/development/tools/misc/checkbashisms/default.nix
new file mode 100644
index 000000000000..6222bb312bb0
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/checkbashisms/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv, fetchurl, perl, installShellFiles }:
+stdenv.mkDerivation rec {
+  version = "2.21.1";
+  pname = "checkbashisms";
+
+  src = fetchurl {
+    url = "mirror://debian/pool/main/d/devscripts/devscripts_${version}.tar.xz";
+    hash = "sha256-1ZbIiUrFd38uMVLy7YayLLm5RrmcovsA++JTb8PbTFI=";
+  };
+
+  nativeBuildInputs = [ installShellFiles ];
+  buildInputs = [ perl ];
+
+  buildPhase = ''
+    runHook preBuild
+
+    substituteInPlace ./scripts/checkbashisms.pl \
+      --replace '###VERSION###' "$version"
+
+    runHook postBuild
+  '';
+  installPhase = ''
+    runHook preInstall
+
+    installManPage scripts/$pname.1
+    installShellCompletion --bash --name $pname scripts/$pname.bash_completion
+    install -D -m755 scripts/$pname.pl $out/bin/$pname
+
+    runHook postInstall
+  '';
+
+  meta = {
+    homepage = "https://sourceforge.net/projects/checkbaskisms/";
+    description = "Check shell scripts for non-portable syntax";
+    license = lib.licenses.gpl2Plus;
+    maintainers = with lib.maintainers; [ kaction ];
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/chrpath/default.nix b/nixpkgs/pkgs/development/tools/misc/chrpath/default.nix
new file mode 100644
index 000000000000..ff804f897d1e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/chrpath/default.nix
@@ -0,0 +1,23 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation {
+  name = "chrpath-0.16";
+
+  src = fetchurl {
+    url = "https://alioth-archive.debian.org/releases/chrpath/chrpath/0.16/chrpath-0.16.tar.gz";
+    sha256 = "0yvfq891mcdkf8g18gjjkn2m5rvs8z4z4cl1vwdhx6f2p9a4q3dv";
+  };
+
+  meta = with lib; {
+    description = "Command line tool to adjust the RPATH or RUNPATH of ELF binaries";
+    longDescription = ''
+      chrpath changes, lists or removes the rpath or runpath setting in a
+      binary. The rpath, or runpath if it is present, is where the runtime
+      linker should look for the libraries needed for a program.
+    '';
+    homepage = "https://tracker.debian.org/pkg/chrpath";
+    license = licenses.gpl2;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/chruby-fish/default.nix b/nixpkgs/pkgs/development/tools/misc/chruby-fish/default.nix
new file mode 100644
index 000000000000..6268c740e212
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/chruby-fish/default.nix
@@ -0,0 +1,28 @@
+{ stdenv, lib, fetchFromGitHub, chruby }:
+
+stdenv.mkDerivation rec {
+  pname = "chruby-fish";
+  version = "0.8.2";
+
+  src = fetchFromGitHub {
+    owner = "JeanMertz";
+    repo = "chruby-fish";
+    rev = "v${version}";
+    sha256 = "15q0ywsn9pcypbpvlq0wb41x4igxm9bsvhg9a05dqw1n437qjhyb";
+  };
+
+  postInstall = ''
+    sed -i -e '1iset CHRUBY_ROOT ${chruby}' $out/share/chruby/auto.fish
+    sed -i -e '1iset CHRUBY_ROOT ${chruby}' $out/share/chruby/chruby.fish
+  '';
+
+  installFlags = [ "PREFIX=$(out)" ];
+
+  meta = {
+    description = "Thin wrapper around chruby to make it work with the Fish shell";
+    homepage = "https://github.com/JeanMertz/chruby-fish";
+    license = lib.licenses.mit;
+    platforms = lib.platforms.all;
+    maintainers = [ lib.maintainers.cohei ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/chruby/default.nix b/nixpkgs/pkgs/development/tools/misc/chruby/default.nix
new file mode 100644
index 000000000000..bcc0687f55b6
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/chruby/default.nix
@@ -0,0 +1,45 @@
+{ stdenv, lib, fetchFromGitHub, runCommand, rubies ? null }:
+
+let
+  rubiesEnv = runCommand "chruby-env" { preferLocalBuild = true; } ''
+    mkdir $out
+    ${lib.concatStrings
+        (lib.mapAttrsToList (name: path: "ln -s ${path} $out/${name}\n") rubies)}
+  '';
+
+in stdenv.mkDerivation rec {
+  pname = "chruby";
+
+  version = "0.3.9";
+
+  src = fetchFromGitHub {
+    owner = "postmodern";
+    repo = "chruby";
+    rev = "v${version}";
+    sha256 = "1894g6fymr8kra9vwhbmnrcr58l022mcd7g9ans4zd3izla2j3gx";
+  };
+
+  phases = [ "unpackPhase" "patchPhase" "installPhase" "fixupPhase" ];
+
+  patches = lib.optionalString (rubies != null) [
+    ./env.patch
+  ];
+
+  postPatch = lib.optionalString (rubies != null) ''
+    substituteInPlace share/chruby/chruby.sh --replace "@rubiesEnv@" ${rubiesEnv}
+  '';
+
+  installPhase = ''
+    mkdir $out
+    cp -r bin $out
+    cp -r share $out
+  '';
+
+  meta = with lib; {
+    description = "Changes the current Ruby";
+    homepage = "https://github.com/postmodern/chruby";
+    license = licenses.mit;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ cstrahan ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/chruby/env.patch b/nixpkgs/pkgs/development/tools/misc/chruby/env.patch
new file mode 100644
index 000000000000..6a4ef8b73497
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/chruby/env.patch
@@ -0,0 +1,12 @@
+diff --git a/share/chruby/chruby.sh b/share/chruby/chruby.sh
+--- a/share/chruby/chruby.sh
++++ b/share/chruby/chruby.sh
+@@ -1,7 +1,7 @@
+ CHRUBY_VERSION="0.3.8"
+ RUBIES=()
+ 
+-for dir in "$PREFIX/opt/rubies" "$HOME/.rubies"; do
++for dir in @rubiesEnv@; do
+ 	[[ -d "$dir" && -n "$(ls -A "$dir")" ]] && RUBIES+=("$dir"/*)
+ done
+ unset dir
diff --git a/nixpkgs/pkgs/development/tools/misc/circleci-cli/default.nix b/nixpkgs/pkgs/development/tools/misc/circleci-cli/default.nix
new file mode 100644
index 000000000000..2d5e77f79186
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/circleci-cli/default.nix
@@ -0,0 +1,39 @@
+{ lib, fetchFromGitHub, buildGoModule }:
+
+buildGoModule rec {
+  pname = "circleci-cli";
+  version = "0.1.15149";
+
+  src = fetchFromGitHub {
+    owner = "CircleCI-Public";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-pmLDCNgCQv4fetl/q6ZokH1qF6pSqsR0DUWbzGeEtaw=";
+  };
+
+  vendorSha256 = "sha256-j7VP/QKKMdmWQ60BYpChG4syDlll7CY4rb4wfb4+Z1s=";
+
+  doCheck = false;
+
+  buildFlagsArray = [ "-ldflags=-s -w -X github.com/CircleCI-Public/circleci-cli/version.Version=${version} -X github.com/CircleCI-Public/circleci-cli/version.Commit=${src.rev} -X github.com/CircleCI-Public/circleci-cli/version.packageManager=nix" ];
+
+  preBuild = ''
+    substituteInPlace data/data.go \
+      --replace 'packr.New("circleci-cli-box", "../_data")' 'packr.New("circleci-cli-box", "${placeholder "out"}/share/circleci-cli")'
+  '';
+
+  postInstall = ''
+    install -Dm644 -t $out/share/circleci-cli _data/data.yml
+  '';
+
+  meta = with lib; {
+    # Box blurb edited from the AUR package circleci-cli
+    description = ''
+      Command to enable you to reproduce the CircleCI environment locally and
+      run jobs as if they were running on the hosted CirleCI application.
+    '';
+    maintainers = with maintainers; [ synthetica ];
+    license = licenses.mit;
+    homepage = "https://circleci.com/";
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cl-launch/default.nix b/nixpkgs/pkgs/development/tools/misc/cl-launch/default.nix
new file mode 100644
index 000000000000..4fe93694ab77
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cl-launch/default.nix
@@ -0,0 +1,38 @@
+{lib, stdenv, fetchurl}:
+let
+  s = # Generated upstream information
+  rec {
+    baseName="cl-launch";
+    version="4.1.4.1";
+    name="${baseName}-${version}";
+    hash="09450yknzb0m3375lg4k8gdypmk3xwl8m1krv1kvhylmrm3995mz";
+    url="http://common-lisp.net/project/xcvb/cl-launch/cl-launch-4.1.4.1.tar.gz";
+    sha256="09450yknzb0m3375lg4k8gdypmk3xwl8m1krv1kvhylmrm3995mz";
+  };
+  buildInputs = [
+  ];
+in
+stdenv.mkDerivation {
+  inherit (s) name version;
+  inherit buildInputs;
+  src = fetchurl {
+    inherit (s) url sha256;
+  };
+
+  preConfigure = ''
+    export makeFlags="$makeFlags PREFIX='$out'"
+    mkdir -p "$out/bin"
+  '';
+
+  preBuild = ''
+    sed -e 's/\t\t@/\t\t/g' -i Makefile
+  '';
+
+  meta = {
+    inherit (s) version;
+    description = "Common Lisp launcher script";
+    license = lib.licenses.llgpl21 ;
+    maintainers = [lib.maintainers.raskin];
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cl-launch/default.upstream b/nixpkgs/pkgs/development/tools/misc/cl-launch/default.upstream
new file mode 100644
index 000000000000..ff7ee9446d28
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cl-launch/default.upstream
@@ -0,0 +1,2 @@
+url http://common-lisp.net/project/xcvb/cl-launch/
+version_link '.-[0-9].*[0-9][.]tar[.][a-z0-9]*$'
diff --git a/nixpkgs/pkgs/development/tools/misc/cli11/default.nix b/nixpkgs/pkgs/development/tools/misc/cli11/default.nix
new file mode 100644
index 000000000000..dbab7c880efb
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cli11/default.nix
@@ -0,0 +1,41 @@
+{
+  lib, stdenv,
+  fetchFromGitHub,
+  cmake,
+  gtest,
+  python3,
+  boost
+}:
+
+stdenv.mkDerivation rec {
+  pname = "cli11";
+  version = "1.9.1";
+
+  src = fetchFromGitHub {
+    owner = "CLIUtils";
+    repo = "CLI11";
+    rev = "v${version}";
+    sha256 = "0hbch0vk8irgmiaxnfqlqys65v1770rxxdfn3d23m2vqyjh0j9l6";
+  };
+
+  nativeBuildInputs = [ cmake ];
+
+  checkInputs = [ boost python3 ];
+
+  doCheck = true;
+
+  preConfigure = ''
+    rm -rfv extern/googletest
+    ln -sfv ${gtest.src} extern/googletest
+    sed -i '/TrueFalseTest/d' tests/CMakeLists.txt
+  '';
+
+  meta = with lib; {
+    description = "Command line parser for C++11";
+    homepage = "https://github.com/CLIUtils/CLI11";
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ ];
+    license = licenses.bsd3;
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/clojure-lsp/default.nix b/nixpkgs/pkgs/development/tools/misc/clojure-lsp/default.nix
new file mode 100644
index 000000000000..8783d217c1fa
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/clojure-lsp/default.nix
@@ -0,0 +1,61 @@
+{ lib, stdenv, graalvm11-ce, babashka, fetchurl, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  pname = "clojure-lsp";
+  version = "2021.06.01-16.19.44";
+
+  src = fetchFromGitHub {
+    owner = pname;
+    repo = pname;
+    rev = version;
+    sha256 = "sha256-dACvjm+uEVWotoeYhA4gCenKeprpF2dI0PGNRAVALao=";
+  };
+
+  jar = fetchurl {
+    url = "https://github.com/clojure-lsp/clojure-lsp/releases/download/${version}/clojure-lsp.jar";
+    sha256 = "sha256-V12rSYv/Yu12ZpLSROd+4pyGiEGRfJ7lmRqCeikcQ5Q=";
+  };
+
+  GRAALVM_HOME = graalvm11-ce;
+  CLOJURE_LSP_JAR = jar;
+  CLOJURE_LSP_XMX = "-J-Xmx4g";
+
+  patches = lib.optionals stdenv.isDarwin [ ./disable-check-toolchain.patch ];
+
+  buildInputs = [ graalvm11-ce ];
+
+  buildPhase = with lib; ''
+    runHook preBuild
+
+    bash ./graalvm/native-unix-compile.sh
+
+    runHook postBuild
+  '';
+
+  installPhase = ''
+    runHook preInstall
+
+    install -Dm755 ./clojure-lsp $out/bin/clojure-lsp
+
+    runHook postInstall
+  '';
+
+  doCheck = true;
+  checkPhase = ''
+    runHook preCheck
+
+    export HOME="$(mktemp -d)"
+    ./clojure-lsp --version | fgrep -q '${version}'
+    ${babashka}/bin/bb integration-test/run-all.clj ./clojure-lsp
+
+    runHook postCheck
+  '';
+
+  meta = with lib; {
+    description = "Language Server Protocol (LSP) for Clojure";
+    homepage = "https://github.com/clojure-lsp/clojure-lsp";
+    license = licenses.mit;
+    maintainers = with maintainers; [ ericdallo babariviere ];
+    platforms = graalvm11-ce.meta.platforms;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/clojure-lsp/disable-check-toolchain.patch b/nixpkgs/pkgs/development/tools/misc/clojure-lsp/disable-check-toolchain.patch
new file mode 100644
index 000000000000..402189627c25
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/clojure-lsp/disable-check-toolchain.patch
@@ -0,0 +1,12 @@
+diff --git a/graalvm/native-unix-compile.sh b/graalvm/native-unix-compile.sh
+index ec0e49f..e19a120 100755
+--- a/graalvm/native-unix-compile.sh
++++ b/graalvm/native-unix-compile.sh
+@@ -17,6 +17,7 @@ CLOJURE_LSP_XMX=${CLOJURE_LSP_XMX:-"-J-Xmx4g"}
+ 
+ args=("-jar" "$CLOJURE_LSP_JAR"
+       "-H:+ReportExceptionStackTraces"
++      "-H:-CheckToolchain"
+       "--verbose"
+       "--no-fallback"
+       "--native-image-info"
diff --git a/nixpkgs/pkgs/development/tools/misc/coccinelle/default.nix b/nixpkgs/pkgs/development/tools/misc/coccinelle/default.nix
new file mode 100644
index 000000000000..8534f1e2d85a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/coccinelle/default.nix
@@ -0,0 +1,41 @@
+{ fetchurl, lib, stdenv, python, ncurses, ocamlPackages, pkg-config }:
+
+stdenv.mkDerivation rec {
+  pname = "coccinelle";
+  version = "1.1.0";
+
+  src = fetchurl {
+    url = "https://coccinelle.gitlabpages.inria.fr/website/distrib/${pname}-${version}.tar.gz";
+    sha256 = "0k0x4qnxzj8fymkp6y9irggcah070hj7hxq8l6ddj8ccpmjbhnsb";
+  };
+
+  buildInputs = with ocamlPackages; [
+    ocaml findlib menhir
+    ocaml_pcre parmap stdcompat
+    python ncurses pkg-config
+  ];
+
+  doCheck = false;
+
+  meta = {
+    description = "Program to apply semantic patches to C code";
+    longDescription = ''
+      Coccinelle is a program matching and transformation engine which
+      provides the language SmPL (Semantic Patch Language) for
+      specifying desired matches and transformations in C code.
+      Coccinelle was initially targeted towards performing collateral
+      evolutions in Linux.  Such evolutions comprise the changes that
+      are needed in client code in response to evolutions in library
+      APIs, and may include modifications such as renaming a function,
+      adding a function argument whose value is somehow
+      context-dependent, and reorganizing a data structure.  Beyond
+      collateral evolutions, Coccinelle is successfully used (by us
+      and others) for finding and fixing bugs in systems code.
+    '';
+
+    homepage = "http://coccinelle.lip6.fr/";
+    license = lib.licenses.gpl2;
+    platforms = lib.platforms.unix;
+    maintainers = [ lib.maintainers.thoughtpolice ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/complexity/default.nix b/nixpkgs/pkgs/development/tools/misc/complexity/default.nix
new file mode 100644
index 000000000000..6e70fbcfcde5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/complexity/default.nix
@@ -0,0 +1,32 @@
+{ fetchurl, lib, stdenv, autogen }:
+
+stdenv.mkDerivation rec {
+  pname = "complexity";
+  version = "1.10";
+
+  src = fetchurl {
+    url = "mirror://gnu/complexity/${pname}-${version}.tar.gz";
+    sha256 = "1vfns9xm7w0wrz12a3w15slrqnrfh6qxk15nv7qkj3irll3ff522";
+  };
+
+  buildInputs = [ autogen ];
+
+  doCheck = true;
+
+  meta = {
+    description = "C code complexity measurement tool";
+
+    longDescription =
+      '' GNU Complexity is a tool designed for analyzing the complexity of C
+         program functions.  It is very similar to the McCabe scoring, but
+         addresses several issues not considered in that scoring scheme.
+      '';
+
+    license = lib.licenses.gpl3Plus;
+
+    homepage = "https://www.gnu.org/software/complexity/";
+
+    platforms = lib.platforms.gnu ++ lib.platforms.linux;
+    maintainers = [ ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cppi/default.nix b/nixpkgs/pkgs/development/tools/misc/cppi/default.nix
new file mode 100644
index 000000000000..9fe5ed966724
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cppi/default.nix
@@ -0,0 +1,31 @@
+{ fetchurl, lib, stdenv }:
+
+stdenv.mkDerivation rec {
+  name = "cppi-1.18";
+
+  src = fetchurl {
+    url = "mirror://gnu/cppi/${name}.tar.xz";
+    sha256 = "1jk42cjaggk71rimjnx3qpmb6hivps0917vl3z7wbxk3i2whb98j";
+  };
+
+  doCheck = true;
+
+  meta = {
+    homepage = "https://savannah.gnu.org/projects/cppi/";
+
+    description = "A C preprocessor directive indenter";
+
+    longDescription =
+      '' GNU cppi indents C preprocessor directives to reflect their nesting
+         and ensure that there is exactly one space character between each #if,
+         #elif, #define directive and the following token.  The number of
+         spaces between the `#' and the following directive must correspond
+         to the level of nesting of that directive.
+      '';
+
+    license = lib.licenses.gpl3Plus;
+
+    maintainers = [ ];
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cproto/cproto.patch b/nixpkgs/pkgs/development/tools/misc/cproto/cproto.patch
new file mode 100644
index 000000000000..3743fef977b0
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cproto/cproto.patch
@@ -0,0 +1,11 @@
+diff -Naur cproto-4.6-old/cproto.h cproto-4.6/cproto.h
+--- cproto-4.6-old/cproto.h	1998-01-18 19:49:16.000000000 -0500
++++ cproto-4.6/cproto.h	2004-03-14 00:02:32.148070032 -0500
+@@ -117,6 +117,7 @@
+     Declarator *declarator;
+     DeclaratorList decl_list;
+ } YYSTYPE;
++#define YYSTYPE_IS_DECLARED 1
+ 
+ /* Prototype styles */
+ #if OPT_LINTLIBRARY
diff --git a/nixpkgs/pkgs/development/tools/misc/cproto/default.nix b/nixpkgs/pkgs/development/tools/misc/cproto/default.nix
new file mode 100644
index 000000000000..84890f166235
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cproto/default.nix
@@ -0,0 +1,34 @@
+{ lib, stdenv, fetchurl, flex, bison }:
+
+stdenv.mkDerivation rec {
+  pname = "cproto";
+  version = "4.7r";
+
+  src = fetchurl {
+    urls = [
+      "mirror://debian/pool/main/c/cproto/cproto_${version}.orig.tar.gz"
+      # No version listings and apparently no versioned tarball over http(s).
+      "ftp://ftp.invisible-island.net/cproto/cproto-${version}.tgz"
+    ];
+    sha256 = "sha256-bgRg2yVZXHobUz8AUaV4ZKBkp2KjP+2oXbDXmPTUX8U=";
+  };
+
+  # patch made by Joe Khoobyar copied from gentoo bugs
+  patches = [ ./cproto.patch ];
+
+  nativeBuildInputs = [ flex bison ];
+
+  doCheck = true;
+
+  doInstallCheck = true;
+  installCheckPhase = ''
+    [ "$("$out/bin/cproto" -V 2>&1)" = '${version}' ]
+  '';
+
+  meta = with lib; {
+    description = "Tool to generate C function prototypes from C source code";
+    homepage = "https://invisible-island.net/cproto/";
+    license = licenses.publicDomain;
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/creduce/default.nix b/nixpkgs/pkgs/development/tools/misc/creduce/default.nix
new file mode 100644
index 000000000000..0ae900060b97
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/creduce/default.nix
@@ -0,0 +1,54 @@
+{ lib, stdenv, fetchurl, cmake, makeWrapper
+, llvm, libclang
+, flex
+, zlib
+, perlPackages
+, util-linux
+}:
+
+stdenv.mkDerivation rec {
+  pname = "creduce";
+  version = "2.9.0";
+
+  src = fetchurl {
+    url = "https://embed.cs.utah.edu/${pname}/${pname}-${version}.tar.gz";
+    sha256 = "1b833z0g1hich68kzbkpfc26xb8w2phfl5savy8c6ir9ihwy1a8w";
+  };
+
+  nativeBuildInputs = [ cmake makeWrapper llvm.dev ];
+  buildInputs = [
+    # Ensure stdenv's CC is on PATH before clang-unwrapped
+    stdenv.cc
+    # Actual deps:
+    llvm libclang
+    flex zlib
+  ] ++ (with perlPackages; [ perl ExporterLite FileWhich GetoptTabular RegexpCommon TermReadKey ]);
+
+  # On Linux, c-reduce's preferred way to reason about
+  # the cpu architecture/topology is to use 'lscpu',
+  # so let's make sure it knows where to find it:
+  postPatch = lib.optionalString stdenv.isLinux ''
+    substituteInPlace creduce/creduce_utils.pm --replace \
+      lscpu ${util-linux}/bin/lscpu
+  '';
+
+  postInstall = ''
+    wrapProgram $out/bin/creduce --prefix PERL5LIB : "$PERL5LIB"
+  '';
+
+  meta = with lib; {
+    description = "A C program reducer";
+    homepage = "https://embed.cs.utah.edu/creduce";
+    # Officially, the license is: https://github.com/csmith-project/creduce/blob/master/COPYING
+    license = licenses.ncsa;
+    longDescription = ''
+      C-Reduce is a tool that takes a large C or C++ program that has a
+      property of interest (such as triggering a compiler bug) and
+      automatically produces a much smaller C/C++ program that has the same
+      property.  It is intended for use by people who discover and report
+      bugs in compilers and other tools that process C/C++ code.
+    '';
+    maintainers = [ maintainers.dtzWill ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cscope/default.nix b/nixpkgs/pkgs/development/tools/misc/cscope/default.nix
new file mode 100644
index 000000000000..7eb38e385e8f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cscope/default.nix
@@ -0,0 +1,53 @@
+{ fetchurl, lib, stdenv, ncurses
+, emacsSupport ? true, emacs
+}:
+
+stdenv.mkDerivation rec {
+  name = "cscope-15.9";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/cscope/${name}.tar.gz";
+    sha256 = "0ngiv4aj3rr35k3q3wjx0y19gh7i1ydqa0cqip6sjwd8fph5ll65";
+  };
+
+  configureFlags = [ "--with-ncurses=${ncurses.dev}" ];
+
+  buildInputs = [ ncurses ];
+  nativeBuildInputs = lib.optional emacsSupport emacs;
+
+  postInstall = lib.optionalString emacsSupport ''
+    cd "contrib/xcscope"
+
+    sed -i "cscope-indexer" \
+        -"es|^PATH=.*$|PATH=\"$out/bin:\$PATH\"|g"
+    sed -i "xcscope.el" \
+        -"es|\"cscope-indexer\"|\"$out/libexec/cscope/cscope-indexer\"|g";
+
+    mkdir -p "$out/libexec/cscope"
+    cp "cscope-indexer" "$out/libexec/cscope"
+
+    mkdir -p "$out/share/emacs/site-lisp"
+    emacs --batch --eval '(byte-compile-file "xcscope.el")'
+    cp xcscope.el{,c} "$out/share/emacs/site-lisp"
+  '';
+
+  meta = {
+    description = "A developer's tool for browsing source code";
+
+    longDescription = ''
+      Cscope is a developer's tool for browsing source code.  It has
+      an impeccable Unix pedigree, having been originally developed at
+      Bell Labs back in the days of the PDP-11.  Cscope was part of
+      the official AT&T Unix distribution for many years, and has been
+      used to manage projects involving 20 million lines of code!
+    '';
+
+    license = "BSD-style";
+
+    homepage = "http://cscope.sourceforge.net/";
+
+    maintainers = with lib.maintainers; [viric];
+
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/csmith/default.nix b/nixpkgs/pkgs/development/tools/misc/csmith/default.nix
new file mode 100644
index 000000000000..0643e81edf99
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/csmith/default.nix
@@ -0,0 +1,49 @@
+{ lib, stdenv, fetchurl, m4, makeWrapper, libbsd, perlPackages }:
+
+stdenv.mkDerivation rec {
+  pname = "csmith";
+  version = "2.3.0";
+
+  src = fetchurl {
+    url = "https://embed.cs.utah.edu/csmith/${pname}-${version}.tar.gz";
+    sha256 = "1mb5zgixsyf86slggs756k8a5ddmj980md3ic9sa1y75xl5cqizj";
+  };
+
+  nativeBuildInputs = [ m4 makeWrapper ];
+  buildInputs = [ libbsd ] ++ (with perlPackages; [ perl SysCPU ]);
+
+  postInstall = ''
+    substituteInPlace $out/bin/compiler_test.pl \
+      --replace '$CSMITH_HOME/runtime' $out/include/${pname}-${version} \
+      --replace ' ''${CSMITH_HOME}/runtime' " $out/include/${pname}-${version}" \
+      --replace '$CSMITH_HOME/src/csmith' $out/bin/csmith
+
+    substituteInPlace $out/bin/launchn.pl \
+      --replace '../compiler_test.pl' $out/bin/compiler_test.pl \
+      --replace '../$CONFIG_FILE' '$CONFIG_FILE'
+
+    wrapProgram $out/bin/launchn.pl \
+      --prefix PERL5LIB : "$PERL5LIB"
+
+    mkdir -p $out/share/csmith
+    mv $out/bin/compiler_test.in $out/share/csmith/
+  '';
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    description = "A random generator of C programs";
+    homepage = "https://embed.cs.utah.edu/csmith";
+    # Officially, the license is this: https://github.com/csmith-project/csmith/blob/master/COPYING
+    license = licenses.bsd2;
+    longDescription = ''
+      Csmith is a tool that can generate random C programs that statically and
+      dynamically conform to the C99 standard. It is useful for stress-testing
+      compilers, static analyzers, and other tools that process C code.
+      Csmith has found bugs in every tool that it has tested, and has been used
+      to find and report more than 400 previously unknown compiler bugs.
+    '';
+    maintainers = [ maintainers.dtzWill ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/ctags/default.nix b/nixpkgs/pkgs/development/tools/misc/ctags/default.nix
new file mode 100644
index 000000000000..fde7307b27dc
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ctags/default.nix
@@ -0,0 +1,43 @@
+{ lib, stdenv, fetchsvn, autoreconfHook }:
+
+stdenv.mkDerivation rec {
+  name = "ctags-${revision}";
+  revision = "816";
+
+  src = fetchsvn {
+    url = "https://svn.code.sf.net/p/ctags/code/trunk";
+    rev = revision;
+    sha256 = "0jmbkrmscbl64j71qffcc39x005jrmphx8kirs1g2ws44wil39hf";
+  };
+
+  nativeBuildInputs = [ autoreconfHook ];
+
+  # don't use $T(E)MP which is set to the build directory
+  configureFlags= [ "--enable-tmpdir=/tmp" ];
+
+  patches = [
+    # Library defines an `__unused__` which is a reserved name, and may
+    # conflict with the standard library definition. One such conflict is with
+    # macOS headers.
+    ./unused-collision.patch
+  ];
+
+  meta = with lib; {
+    description = "A tool for fast source code browsing (exuberant ctags)";
+    longDescription = ''
+      Ctags generates an index (or tag) file of language objects found
+      in source files that allows these items to be quickly and easily
+      located by a text editor or other utility.  A tag signifies a
+      language object for which an index entry is available (or,
+      alternatively, the index entry created for that object).  Many
+      programming languages are supported.
+    '';
+    homepage = "http://ctags.sourceforge.net/";
+    license = licenses.gpl2Plus;
+    platforms = platforms.unix;
+
+    # So that Exuberant ctags is preferred over emacs's ctags
+    priority = 1;
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/ctags/unused-collision.patch b/nixpkgs/pkgs/development/tools/misc/ctags/unused-collision.patch
new file mode 100644
index 000000000000..595f67a01b5a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ctags/unused-collision.patch
@@ -0,0 +1,246 @@
+--- a/c.c	(revision 816)
++++ b/c.c	(working copy)
+@@ -619,7 +619,7 @@
+ 	return name;
+ }
+ 
+-static void __unused__ pt (tokenInfo *const token)
++static void UNUSED pt (tokenInfo *const token)
+ {
+ 	if (isType (token, TOKEN_NAME))
+ 		printf ("type: %-12s: %-13s   line: %lu\n",
+@@ -634,7 +634,7 @@
+ 			tokenString (token->type), token->lineNumber);
+ }
+ 
+-static void __unused__ ps (statementInfo *const st)
++static void UNUSED ps (statementInfo *const st)
+ {
+ 	unsigned int i;
+ 	printf ("scope: %s   decl: %s   gotName: %s   gotParenName: %s\n",
+--- a/eiffel.c	(revision 816)
++++ b/eiffel.c	(working copy)
+@@ -807,7 +807,7 @@
+ 
+ static boolean parseType (tokenInfo *const token);
+ 
+-static void parseGeneric (tokenInfo *const token, boolean declaration __unused__)
++static void parseGeneric (tokenInfo *const token, boolean declaration UNUSED)
+ {
+ 	unsigned int depth = 0;
+ #ifdef TYPE_REFERENCE_TOOL
+--- a/general.h	(revision 816)
++++ b/general.h	(working copy)
+@@ -57,10 +57,10 @@
+  *  to prevent warnings about unused variables.
+  */
+ #if (__GNUC__ > 2  ||  (__GNUC__ == 2  &&  __GNUC_MINOR__ >= 7)) && !defined (__GNUG__)
+-# define __unused__  __attribute__((unused))
++# define UNUSED  __attribute__((unused))
+ # define __printf__(s,f)  __attribute__((format (printf, s, f)))
+ #else
+-# define __unused__
++# define UNUSED
+ # define __printf__(s,f)
+ #endif
+ 
+--- a/lregex.c	(revision 816)
++++ b/lregex.c	(working copy)
+@@ -538,11 +538,11 @@
+ #endif  /* HAVE_REGEX */
+ 
+ extern void addTagRegex (
+-		const langType language __unused__,
+-		const char* const regex __unused__,
+-		const char* const name __unused__,
+-		const char* const kinds __unused__,
+-		const char* const flags __unused__)
++		const langType language UNUSED,
++		const char* const regex UNUSED,
++		const char* const name UNUSED,
++		const char* const kinds UNUSED,
++		const char* const flags UNUSED)
+ {
+ #ifdef HAVE_REGEX
+ 	Assert (regex != NULL);
+@@ -564,10 +564,10 @@
+ }
+ 
+ extern void addCallbackRegex (
+-		const langType language __unused__,
+-		const char* const regex __unused__,
+-		const char* const flags __unused__,
+-		const regexCallback callback __unused__)
++		const langType language UNUSED,
++		const char* const regex UNUSED,
++		const char* const flags UNUSED,
++		const regexCallback callback UNUSED)
+ {
+ #ifdef HAVE_REGEX
+ 	Assert (regex != NULL);
+@@ -581,7 +581,7 @@
+ }
+ 
+ extern void addLanguageRegex (
+-		const langType language __unused__, const char* const regex __unused__)
++		const langType language UNUSED, const char* const regex UNUSED)
+ {
+ #ifdef HAVE_REGEX
+ 	if (! regexBroken)
+@@ -602,7 +602,7 @@
+ */
+ 
+ extern boolean processRegexOption (const char *const option,
+-								   const char *const parameter __unused__)
++								   const char *const parameter UNUSED)
+ {
+ 	boolean handled = FALSE;
+ 	const char* const dash = strchr (option, '-');
+@@ -624,7 +624,7 @@
+ 	return handled;
+ }
+ 
+-extern void disableRegexKinds (const langType language __unused__)
++extern void disableRegexKinds (const langType language UNUSED)
+ {
+ #ifdef HAVE_REGEX
+ 	if (language <= SetUpper  &&  Sets [language].count > 0)
+@@ -639,8 +639,8 @@
+ }
+ 
+ extern boolean enableRegexKind (
+-		const langType language __unused__,
+-		const int kind __unused__, const boolean mode __unused__)
++		const langType language UNUSED,
++		const int kind UNUSED, const boolean mode UNUSED)
+ {
+ 	boolean result = FALSE;
+ #ifdef HAVE_REGEX
+@@ -660,7 +660,7 @@
+ 	return result;
+ }
+ 
+-extern void printRegexKinds (const langType language __unused__, boolean indent __unused__)
++extern void printRegexKinds (const langType language UNUSED, boolean indent UNUSED)
+ {
+ #ifdef HAVE_REGEX
+ 	if (language <= SetUpper  &&  Sets [language].count > 0)
+--- a/lua.c	(revision 816)
++++ b/lua.c	(working copy)
+@@ -37,7 +37,7 @@
+ */
+ 
+ /* for debugging purposes */
+-static void __unused__ print_string (char *p, char *q)
++static void UNUSED print_string (char *p, char *q)
+ {
+ 	for ( ; p != q; p++)
+ 		fprintf (errout, "%c", *p);
+--- a/main.c	(revision 816)
++++ b/main.c	(working copy)
+@@ -522,7 +522,7 @@
+  *		Start up code
+  */
+ 
+-extern int main (int __unused__ argc, char **argv)
++extern int main (int UNUSED argc, char **argv)
+ {
+ 	cookedArgs *args;
+ #ifdef VMS
+--- a/options.c	(revision 816)
++++ b/options.c	(working copy)
+@@ -730,7 +730,7 @@
+ }
+ 
+ static void processExcludeOption (
+-		const char *const option __unused__, const char *const parameter)
++		const char *const option UNUSED, const char *const parameter)
+ {
+ 	const char *const fileName = parameter + 1;
+ 	if (parameter [0] == '\0')
+@@ -867,7 +867,7 @@
+ }
+ 
+ static void processFilterTerminatorOption (
+-		const char *const option __unused__, const char *const parameter)
++		const char *const option UNUSED, const char *const parameter)
+ {
+ 	freeString (&Option.filterTerminator);
+ 	Option.filterTerminator = stringCopy (parameter);
+@@ -930,8 +930,8 @@
+ }
+ 
+ static void processHelpOption (
+-		const char *const option __unused__,
+-		const char *const parameter __unused__)
++		const char *const option UNUSED,
++		const char *const parameter UNUSED)
+ {
+ 	printProgramIdentification ();
+ 	putchar ('\n');
+@@ -1139,8 +1139,8 @@
+ }
+ 
+ static void processLicenseOption (
+-		const char *const option __unused__,
+-		const char *const parameter __unused__)
++		const char *const option UNUSED,
++		const char *const parameter UNUSED)
+ {
+ 	printProgramIdentification ();
+ 	puts ("");
+@@ -1166,8 +1166,8 @@
+ }
+ 
+ static void processListMapsOption (
+-		const char *const __unused__ option,
+-		const char *const __unused__ parameter)
++		const char *const UNUSED option,
++		const char *const UNUSED parameter)
+ {
+ 	if (parameter [0] == '\0' || strcasecmp (parameter, "all") == 0)
+ 	    printLanguageMaps (LANG_AUTO);
+@@ -1183,8 +1183,8 @@
+ }
+ 
+ static void processListLanguagesOption (
+-		const char *const option __unused__,
+-		const char *const parameter __unused__)
++		const char *const option UNUSED,
++		const char *const parameter UNUSED)
+ {
+ 	printLanguageList ();
+ 	exit (0);
+@@ -1358,8 +1358,8 @@
+ }
+ 
+ static void processVersionOption (
+-		const char *const option __unused__,
+-		const char *const parameter __unused__)
++		const char *const option UNUSED,
++		const char *const parameter UNUSED)
+ {
+ 	printProgramIdentification ();
+ 	exit (0);
+--- a/parse.c	(revision 816)
++++ b/parse.c	(working copy)
+@@ -376,7 +376,7 @@
+ */
+ 
+ extern void processLanguageDefineOption (
+-		const char *const option, const char *const parameter __unused__)
++		const char *const option, const char *const parameter UNUSED)
+ {
+ #ifdef HAVE_REGEX
+ 	if (parameter [0] == '\0')
+--- a/routines.c	(revision 816)
++++ b/routines.c	(working copy)
+@@ -526,7 +526,7 @@
+ 
+ #if ! defined (HAVE_STAT_ST_INO)
+ 
+-static void canonicalizePath (char *const path __unused__)
++static void canonicalizePath (char *const path UNUSED)
+ {
+ #if defined (MSDOS_STYLE_PATH)
+ 	char *p;
diff --git a/nixpkgs/pkgs/development/tools/misc/ctags/wrapped.nix b/nixpkgs/pkgs/development/tools/misc/ctags/wrapped.nix
new file mode 100644
index 000000000000..f658e78d5db0
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ctags/wrapped.nix
@@ -0,0 +1,78 @@
+{ pkgs, ctags }:
+
+with pkgs.lib;
+
+# define some ctags wrappers adding support for some not that common languages
+# customization:
+# a) add stuff here
+# b) override asLang, phpLang, ... using packageOverrides
+# c) use ctagsWrapped.override {args = [ your liste ];}
+
+# install using -iA ctagsWrapped.ctagsWrapped
+
+{
+
+  # the derivation. use language extensions specified by args
+  ctagsWrapped = makeOverridable ( {args, name} :  pkgs.writeScriptBin name ''
+  #!${pkgs.runtimeShell}
+  exec ${pkgs.ctags}/bin/ctags ${concatStringsSep " " (map escapeShellArg args)} "$@"
+  '') {
+    args = let x = pkgs.ctagsWrapped; in concatLists [
+      x.defaultArgs x.phpLang x.jsLang x.nixLang x.asLang x.rubyLang
+    ];
+    name = "${ctags.name}-wrapped";
+  };
+
+  ### language arguments
+
+  # don't scan version control directories
+  defaultArgs = [
+    "--exclude=.svn"
+    "--exclude=.hg"
+    "--exclude=.git"
+    "--exclude=_darcs"
+    "--sort=yes"
+  ];
+
+  # actionscript
+  asLang = [
+    "--langdef=ActionScript"
+    "--langmap=ActionScript:.as"
+    "--regex-ActionScript=/function[ \\t]+([A-Za-z0-9_]+)[ \\t]*\\(/\\1/f,function,functions/"
+    "--regex-ActionScript=/function[ \\t]+(set|get)[ \\t]+([A-Za-z0-9_]+)[ \\t]*\\(/\\2/p,property,properties/"
+    "--regex-ActionScript=/interface[ \\t]+[a-z0-9_.]*([A-Z][A-Za-z0-9_]+)/\\1/i,interface,interfaces/"
+    "--regex-ActionScript=/package[ \\t]+([^ \\t]*)/\\1/p/"
+    "--regex-ActionScript=/class[ \\t]+[a-z0-9_.]*([A-Z][A-Za-z0-9_]+)/\\1/c,class,classes/"
+  ];
+
+  # PHP
+  phpLang = [
+    "--langmap=PHP:.php"
+    "--regex-PHP=/abstract class ([^ ]*)/\\1/c/"
+    "--regex-PHP=/interface ([^ ]*)/\\1/i/"
+    "--regex-PHP=/function[ \\t]+([^ (]*)/\\1/f/"
+  ];
+
+  # Javascript: also find unnamed functions and funtions beeing passed within a dict.
+  # the dict properties is used to implement duck typing in frameworks
+  # var foo = function () { ... }
+  # {
+  # a : function () {}
+  # only recognize names up 100 characters. Else you'll be in trouble scanning compressed .js files.
+  jsLang = [
+    "--regex-JavaScript=/([^ \\t]{1,100})[ \\t]*:[ \\t]*function[ \\t]*\\(/\\1/f/"
+  ];
+
+  # find foo in "foo =", don't think we can do a lot better
+  nixLang = [
+    "--langdef=NIX"
+    "--langmap=NIX:.nix"
+    "--regex-NIX=/([^ \\t*]*)[ \\t]*=/\\1/f/"
+  ];
+
+  rubyLang = [
+    "--langmap=RUBY:.rb"
+    "--regex-RUBY=/class ([^ ]*)/\\1/c/"
+    "--regex-RUBY=/^[ ]*module[ ]*([^ ]*)/\\1/m/"
+  ];
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cvise/default.nix b/nixpkgs/pkgs/development/tools/misc/cvise/default.nix
new file mode 100644
index 000000000000..e24c133e8b90
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cvise/default.nix
@@ -0,0 +1,46 @@
+{ lib, buildPythonApplication, fetchFromGitHub, cmake, flex
+, libclang, llvm, unifdef
+, pebble, psutil, pytestCheckHook, pytest-flake8
+}:
+
+buildPythonApplication rec {
+  pname = "cvise";
+  version = "2.3.0";
+
+  src = fetchFromGitHub {
+    owner = "marxin";
+    repo = "cvise";
+    rev = "v${version}";
+    sha256 = "1x2i8nv0nncgvr07znhh2slngbrg8qcsz2zqx76bcyq9hssn6yal";
+  };
+
+  patches = [
+    # Refer to unifdef by absolute path.
+    ./unifdef.patch
+  ];
+
+  nativeBuildInputs = [ cmake flex llvm.dev ];
+  buildInputs = [ libclang llvm llvm.dev unifdef ];
+  propagatedBuildInputs = [ pebble psutil ];
+  checkInputs = [ pytestCheckHook pytest-flake8 unifdef ];
+
+  preCheck = ''
+    patchShebangs cvise.py
+  '';
+  disabledTests = [
+    # Needs gcc, fails when run noninteractively (without tty).
+    "test_simple_reduction"
+  ];
+
+  dontUsePipInstall = true;
+  dontUseSetuptoolsBuild = true;
+  dontUseSetuptoolsCheck = true;
+
+  meta = with lib; {
+    homepage = "https://github.com/marxin/cvise";
+    description = "Super-parallel Python port of C-Reduce";
+    license = licenses.ncsa;
+    maintainers = with maintainers; [ orivej ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/cvise/unifdef.patch b/nixpkgs/pkgs/development/tools/misc/cvise/unifdef.patch
new file mode 100644
index 000000000000..d15ca6dce0bd
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cvise/unifdef.patch
@@ -0,0 +1,8 @@
+--- a/cvise.py
++++ b/cvise.py
+@@ -93,4 +93,5 @@ def find_external_programs():
+     # Special case for clang-format
+     programs['clang-format'] = '@CLANG_FORMAT_PATH@'
++    programs['unifdef'] = '@UNIFDEF@'
+ 
+     return programs
diff --git a/nixpkgs/pkgs/development/tools/misc/cwebbin/default.nix b/nixpkgs/pkgs/development/tools/misc/cwebbin/default.nix
new file mode 100644
index 000000000000..055a24f3fe0a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/cwebbin/default.nix
@@ -0,0 +1,59 @@
+{ lib, stdenv, fetchFromGitHub, fetchurl, tie }:
+
+stdenv.mkDerivation rec {
+  pname = "cwebbin";
+  version = "22p";
+
+  src = fetchFromGitHub {
+    owner = "ascherer";
+    repo = "cwebbin";
+    rev = "2016-05-20-22p";
+    sha256 = "0zf93016hm9i74i2v384rwzcw16y3hg5vc2mibzkx1rzvqa50yfr";
+  };
+
+  cweb = fetchurl {
+    url = "https://www.ctan.org/tex-archive/web/c_cpp/cweb/cweb-3.64ah.tgz";
+    sha256 = "1hdzxfzaibnjxjzgp6d2zay8nsarnfy9hfq55hz1bxzzl23n35aj";
+  };
+
+  # Remove references to __DATE__ and __TIME__
+  postPatch = ''
+    substituteInPlace wmerg-patch.ch --replace ' ("__DATE__", "__TIME__")' ""
+    substituteInPlace ctang-patch.ch --replace ' ("__DATE__", "__TIME__")' ""
+    substituteInPlace ctangle.cxx --replace ' ("__DATE__", "__TIME__")' ""
+    substituteInPlace cweav-patch.ch --replace ' ("__DATE__", "__TIME__")' ""
+  '';
+
+  nativeBuildInputs = [ tie ];
+
+  makeFlags = [
+    "MACROSDIR=$(out)/share/texmf/tex/generic/cweb"
+    "CWEBINPUTS=$(out)/lib/cweb"
+    "DESTDIR=$(out)/bin/"
+    "MANDIR=$(out)/share/man/man1"
+    "EMACSDIR=$(out)/share/emacs/site-lisp"
+    "CP=cp"
+    "RM=rm"
+    "PDFTEX=echo"
+    "CC=${stdenv.cc.targetPrefix}c++"
+  ];
+
+  buildPhase = ''
+    zcat ${cweb} | tar -xvpf -
+    make -f Makefile.unix boot $makeFlags
+    make -f Makefile.unix cautiously $makeFlags
+  '';
+
+  installPhase = ''
+    mkdir -p $out/share/man/man1 $out/share/texmf/tex/generic $out/share/emacs $out/lib
+    make -f Makefile.unix install $makeFlags
+  '';
+
+  meta = with lib; {
+    inherit (src.meta) homepage;
+    description = "Literate Programming in C/C++";
+    platforms = with platforms; unix;
+    maintainers = with maintainers; [ vrthra ];
+    license = licenses.abstyles;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/d-feet/default.nix b/nixpkgs/pkgs/development/tools/misc/d-feet/default.nix
new file mode 100644
index 000000000000..3db895f4de01
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/d-feet/default.nix
@@ -0,0 +1,82 @@
+{ lib
+, pkg-config
+, fetchurl
+, meson
+, ninja
+, glib
+, gtk3
+, python3
+, wrapGAppsHook
+, gnome
+, libwnck
+, gobject-introspection
+, gettext
+, itstool
+}:
+
+python3.pkgs.buildPythonApplication rec {
+  pname = "d-feet";
+  version = "0.3.16";
+
+  format = "other";
+
+  src = fetchurl {
+    url = "mirror://gnome/sources/d-feet/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
+    sha256 = "hzPOS5qaVOwYWx2Fv02p2dEQUogqiAdg/2D5d5stHMs=";
+  };
+
+  nativeBuildInputs = [
+    gettext
+    gobject-introspection
+    itstool
+    meson
+    ninja
+    pkg-config
+    python3
+    wrapGAppsHook
+  ];
+
+  buildInputs = [
+    glib
+    gnome.adwaita-icon-theme
+    gtk3
+    libwnck
+  ];
+
+  propagatedBuildInputs = with python3.pkgs; [
+    pygobject3
+  ];
+
+  mesonFlags = [
+    "-Dtests=false" # needs dbus
+  ];
+
+  # Temporary fix
+  # See https://github.com/NixOS/nixpkgs/issues/56943
+  strictDeps = false;
+
+  postPatch = ''
+    chmod +x meson_post_install.py
+    patchShebangs meson_post_install.py
+  '';
+
+  passthru = {
+    updateScript = gnome.updateScript {
+      packageName = pname;
+      attrPath = "dfeet";
+      versionPolicy = "none";
+    };
+  };
+
+  meta = with lib; {
+    description = "D-Feet is an easy to use D-Bus debugger";
+    longDescription = ''
+      D-Feet can be used to inspect D-Bus interfaces of running programs
+      and invoke methods on those interfaces.
+    '';
+    homepage = "https://wiki.gnome.org/Apps/DFeet";
+    platforms = platforms.linux;
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ ktosiek ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/dbench/default.nix b/nixpkgs/pkgs/development/tools/misc/dbench/default.nix
new file mode 100644
index 000000000000..9565eaa36262
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/dbench/default.nix
@@ -0,0 +1,45 @@
+{ lib, stdenv, fetchgit, autoconf, popt, zlib, rpcsvc-proto, libtirpc }:
+
+stdenv.mkDerivation {
+  name = "dbench-2013-01-01";
+
+  src = fetchgit {
+    url = "git://git.samba.org/sahlberg/dbench.git";
+    rev = "65b19870ed8d25bff14cafa1c30beb33f1fb6597";
+    sha256 = "16lcbwmmx8z5i73k3dnf54yffrpx7ql3y9k3cpkss9dcyxb1p83i";
+  };
+
+  nativeBuildInputs = [ autoconf rpcsvc-proto ];
+  buildInputs = [ popt zlib libtirpc ];
+  NIX_CFLAGS_COMPILE = [ "-I${libtirpc.dev}/include/tirpc" ];
+  NIX_LDFLAGS = [ "-ltirpc" ];
+
+  patches = [
+    # patch has been also sent upstream and might be included in future versions
+    ./fix-missing-stdint.patch
+  ];
+
+  preConfigure = ''
+    ./autogen.sh
+    configureFlagsArray+=("--datadir=$out/share/dbench")
+  '';
+
+  postInstall = ''
+    cp -R loadfiles/* $out/share/dbench/doc/dbench/loadfiles
+
+    # dbench looks here for the file
+    ln -s doc/dbench/loadfiles/client.txt $out/share/dbench/client.txt
+
+    # backwards compatible to older nixpkgs packaging introduced by
+    # 3f27be8e5d5861cd4b9487d6c5212d88bf24316d
+    ln -s dbench/doc/dbench/loadfiles $out/share/loadfiles
+  '';
+
+  meta = with lib; {
+    description = "Filesystem benchmark tool based on load patterns";
+    homepage = "https://dbench.samba.org/";
+    license = licenses.gpl3;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/dbench/fix-missing-stdint.patch b/nixpkgs/pkgs/development/tools/misc/dbench/fix-missing-stdint.patch
new file mode 100644
index 000000000000..96cb28e9e55a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/dbench/fix-missing-stdint.patch
@@ -0,0 +1,10 @@
+--- dbench-65b1987.org/libnfs.c	2017-11-08 12:25:39.652147989 +0000
++++ dbench-65b1987/libnfs.c	2017-11-08 12:26:20.269897054 +0000
+@@ -23,6 +23,7 @@
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <fcntl.h>
++#include <stdint.h>
+ 
+ #define discard_const(ptr) ((void *)((intptr_t)(ptr)))
+ 
diff --git a/nixpkgs/pkgs/development/tools/misc/ddd/default.nix b/nixpkgs/pkgs/development/tools/misc/ddd/default.nix
new file mode 100644
index 000000000000..74eb9fcb2936
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ddd/default.nix
@@ -0,0 +1,22 @@
+{lib, stdenv, fetchurl, motif, ncurses, libX11, libXt}:
+
+stdenv.mkDerivation rec {
+  name = "ddd-3.3.12";
+  src = fetchurl {
+    url = "mirror://gnu/ddd/${name}.tar.gz";
+    sha256 = "0p5nx387857w3v2jbgvps2p6mlm0chajcdw5sfrddcglsxkwvmis";
+  };
+  buildInputs = [motif ncurses libX11 libXt];
+  configureFlags = [ "--with-x" ];
+
+  patches = [ ./gcc44.patch ];
+
+  NIX_CFLAGS_COMPILE = "-fpermissive";
+
+  meta = {
+    homepage = "https://www.gnu.org/software/ddd";
+    description = "Graphical front-end for command-line debuggers";
+    license = lib.licenses.gpl2;
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/ddd/gcc44.patch b/nixpkgs/pkgs/development/tools/misc/ddd/gcc44.patch
new file mode 100644
index 000000000000..c4e4004b12e0
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ddd/gcc44.patch
@@ -0,0 +1,11 @@
+http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=504868
+--- a/ddd/strclass.C~ 2008-11-07 17:57:13.000000000 +0000
++++ b/ddd/strclass.C  2008-11-07 17:57:27.000000000 +0000
+@@ -39,6 +39,7 @@
+ #include <ctype.h>
+ #include <limits.h>
+ #include <new>
++#include <cstdio>
+ #include <stdlib.h>
+ 
+ void string::error(const char* msg) const
diff --git a/nixpkgs/pkgs/development/tools/misc/dejagnu/default.nix b/nixpkgs/pkgs/development/tools/misc/dejagnu/default.nix
new file mode 100644
index 000000000000..612514345785
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/dejagnu/default.nix
@@ -0,0 +1,54 @@
+{ fetchurl, lib, stdenv, expect, makeWrapper }:
+
+stdenv.mkDerivation rec {
+  name = "dejagnu-1.6.2";
+
+  src = fetchurl {
+    url = "mirror://gnu/dejagnu/${name}.tar.gz";
+    sha256 = "0qfj2wd4qk1yn9yzam6g8nmyxfazcc0knjyyibycb2ainkhp21hd";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+  buildInputs = [ expect ];
+
+  doCheck = true;
+
+  # Note: The test-suite *requires* /dev/pts among the `build-chroot-dirs' of
+  # the build daemon when building in a chroot.  See
+  # <https://www.mail-archive.com/nix-dev@cs.uu.nl/msg01056.html> for
+  # details.
+
+  # The test-suite needs to have a non-empty stdin:
+  #   https://lists.gnu.org/archive/html/bug-dejagnu/2003-06/msg00002.html
+  checkPhase = ''
+    # Provide `runtest' with a log name, otherwise it tries to run
+    # `whoami', which fails when in a chroot.
+    LOGNAME="nix-build-daemon" make check < /dev/zero
+  '';
+
+  postInstall = ''
+    wrapProgram "$out/bin/runtest" \
+      --prefix PATH ":" "${expect}/bin"
+  '';
+
+  meta = with lib; {
+    description = "Framework for testing other programs";
+
+    longDescription = ''
+      DejaGnu is a framework for testing other programs.  Its purpose
+      is to provide a single front end for all tests.  Think of it as a
+      custom library of Tcl procedures crafted to support writing a
+      test harness.  A test harness is the testing infrastructure that
+      is created to support a specific program or tool.  Each program
+      can have multiple testsuites, all supported by a single test
+      harness.  DejaGnu is written in Expect, which in turn uses Tcl --
+      Tool command language.
+    '';
+
+    homepage = "https://www.gnu.org/software/dejagnu/";
+    license = licenses.gpl2Plus;
+
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ vrthra ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/dfu-programmer/default.nix b/nixpkgs/pkgs/development/tools/misc/dfu-programmer/default.nix
new file mode 100644
index 000000000000..f0a3a9b76006
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/dfu-programmer/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchurl, libusb-compat-0_1 }:
+let
+  version = "0.7.2";
+in
+stdenv.mkDerivation rec {
+  pname = "dfu-programmer";
+  inherit version;
+
+  buildInputs = [ libusb-compat-0_1 ];
+
+  src = fetchurl {
+    url = "mirror://sourceforge/dfu-programmer/${pname}-${version}.tar.gz";
+    sha256 = "15gr99y1z9vbvhrkd25zqhnzhg6zjmaam3vfjzf2mazd39mx7d0x";
+  };
+
+  configureFlags = [ "--disable-libusb_1_0" ];
+
+  meta = with lib; {
+    license = licenses.gpl2;
+    description = "A Device Firmware Update based USB programmer for Atmel chips with a USB bootloader";
+    homepage = "http://dfu-programmer.sourceforge.net/";
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/dfu-util/default.nix b/nixpkgs/pkgs/development/tools/misc/dfu-util/default.nix
new file mode 100644
index 000000000000..85917a114c0f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/dfu-util/default.nix
@@ -0,0 +1,31 @@
+{ lib, stdenv, fetchurl, pkg-config, libusb1 }:
+
+stdenv.mkDerivation rec {
+  pname = "dfu-util";
+  version = "0.10";
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ libusb1 ];
+
+  src = fetchurl {
+    url = "http://dfu-util.sourceforge.net/releases/${pname}-${version}.tar.gz";
+    sha256 = "0hlvc47ccf5hry13saqhc1j5cdq5jyjv4i05kj0mdh3rzj6wagd0";
+  };
+
+  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
+      DFU 1.0 and 1.1 (Universal Serial Bus Device Firmware Upgrade) protocol.
+
+      DFU is intended to download and upload firmware to devices connected over
+      USB. It ranges from small devices like micro-controller boards up to mobile
+      phones. With dfu-util you are able to download firmware to your device or
+      upload firmware from it.
+    '';
+    homepage = "http://dfu-util.sourceforge.net";
+    license = licenses.gpl2Plus;
+    platforms = platforms.unix;
+    maintainers = [ maintainers.fpletz ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/direvent/default.nix b/nixpkgs/pkgs/development/tools/misc/direvent/default.nix
new file mode 100644
index 000000000000..cf2a52276038
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/direvent/default.nix
@@ -0,0 +1,21 @@
+{ lib, stdenv
+, fetchurl
+}:
+
+stdenv.mkDerivation rec {
+  name = "direvent-${version}";
+  version = "5.2";
+
+  src = fetchurl {
+    url = "mirror://gnu/direvent/${name}.tar.gz";
+    sha256 = "0m9vi01b1km0cpknflyzsjnknbava0s1n6393b2bpjwyvb6j5613";
+  };
+
+  meta = with lib; {
+    description = "Directory event monitoring daemon";
+    homepage = "https://www.gnu.org.ua/software/direvent/";
+    license = licenses.gpl3Plus;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ puffnfresh ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/distcc/default.nix b/nixpkgs/pkgs/development/tools/misc/distcc/default.nix
new file mode 100644
index 000000000000..6de12a84522e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/distcc/default.nix
@@ -0,0 +1,84 @@
+{ lib, stdenv, fetchFromGitHub, popt, avahi, pkg-config, python3, gtk3, runCommand
+, gcc, autoconf, automake, which, procps, libiberty_static
+, runtimeShell
+, sysconfDir ? ""   # set this parameter to override the default value $out/etc
+, static ? false
+}:
+
+let
+  name    = "distcc";
+  version = "2021-03-11";
+  distcc = stdenv.mkDerivation {
+    name = "${name}-${version}";
+    src = fetchFromGitHub {
+      owner = "distcc";
+      repo = "distcc";
+      rev = "de21b1a43737fbcf47967a706dab4c60521dbbb1";
+      sha256 = "0zjba1090awxkmgifr9jnjkxf41zhzc4f6mrnbayn3v6s77ca9x4";
+    };
+
+  nativeBuildInputs = [ pkg-config ];
+    buildInputs = [popt avahi pkg-config python3 gtk3 autoconf automake which procps libiberty_static];
+    preConfigure =
+    ''
+      export CPATH=$(ls -d ${gcc.cc}/lib/gcc/*/${gcc.cc.version}/plugin/include)
+
+      configureFlagsArray=( CFLAGS="-O2 -fno-strict-aliasing"
+                            CXXFLAGS="-O2 -fno-strict-aliasing"
+          --mandir=$out/share/man
+                            ${if sysconfDir == "" then "" else "--sysconfdir=${sysconfDir}"}
+                            ${if static then "LDFLAGS=-static" else ""}
+                            --with${if static == true || popt == null then "" else "out"}-included-popt
+                            --with${if avahi != null then "" else "out"}-avahi
+                            --with${if gtk3 != null then "" else "out"}-gtk
+                            --without-gnome
+                            --enable-rfc2553
+                            --disable-Werror   # a must on gcc 4.6
+                           )
+      installFlags="sysconfdir=$out/etc";
+
+      ./autogen.sh
+    '';
+
+    # The test suite fails because it uses hard-coded paths, i.e. /usr/bin/gcc.
+    doCheck = false;
+
+    passthru = {
+      # A derivation that provides gcc and g++ commands, but that
+      # will end up calling distcc for the given cacheDir
+      #
+      # extraConfig is meant to be sh lines exporting environment
+      # variables like DISTCC_HOSTS, DISTCC_DIR, ...
+      links = extraConfig: (runCommand "distcc-links" { passthru.gcc = gcc.cc; }
+        ''
+          mkdir -p $out/bin
+          if [ -x "${gcc.cc}/bin/gcc" ]; then
+            cat > $out/bin/gcc << EOF
+            #!${runtimeShell}
+            ${extraConfig}
+            exec ${distcc}/bin/distcc gcc "\$@"
+          EOF
+            chmod +x $out/bin/gcc
+          fi
+          if [ -x "${gcc.cc}/bin/g++" ]; then
+            cat > $out/bin/g++ << EOF
+            #!${runtimeShell}
+            ${extraConfig}
+            exec ${distcc}/bin/distcc g++ "\$@"
+          EOF
+            chmod +x $out/bin/g++
+          fi
+        '');
+    };
+
+    meta = {
+      description = "A fast, free distributed C/C++ compiler";
+      homepage = "http://distcc.org";
+      license = "GPL";
+
+      platforms = lib.platforms.linux;
+      maintainers = with lib.maintainers; [ anderspapitto ];
+    };
+  };
+in
+  distcc
diff --git a/nixpkgs/pkgs/development/tools/misc/distcc/masq.nix b/nixpkgs/pkgs/development/tools/misc/distcc/masq.nix
new file mode 100644
index 000000000000..2387ab1bd418
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/distcc/masq.nix
@@ -0,0 +1,44 @@
+{ lib, stdenv, gccRaw, binutils }:
+
+stdenv.mkDerivation {
+  name = "distcc-masq-${gccRaw.name}";
+
+  phases = [ "installPhase" ];
+  installPhase = ''
+    mkdir -p $out/bin
+
+    bin=${gccRaw}/bin
+
+    shopt -s nullglob
+    if [ -f $bin/gcc ]; then
+      ln -s $bin/gcc $out/bin
+    else
+      for a in $bin/*-gcc; do
+        ln -s $bin/*-gcc $out/bin/gcc
+        ln -s $bin/*-gcc $out/bin/cc
+      done
+    fi
+
+    if [ -f $bin/g++ ]; then
+      ln -s $bin/g++ $out/bin
+    else
+      for a in $bin/*-g++; do
+        ln -sf $bin/*-g++ $out/bin/g++
+        ln -sf $bin/*-g++ $out/bin/c++
+      done
+    fi
+
+    bbin=${binutils}/bin
+    if [ -f $bbin/as ]; then
+      ln -s $bbin/as $out/bin
+    else
+      for a in $bbin/*-as; do
+        ln -sf $bbin/*-as $out/bin/as
+      done
+    fi
+  '';
+
+  meta = {
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/doclifter/default.nix b/nixpkgs/pkgs/development/tools/misc/doclifter/default.nix
new file mode 100644
index 000000000000..0692d84b4544
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/doclifter/default.nix
@@ -0,0 +1,28 @@
+{lib, stdenv, fetchurl, python3}:
+
+stdenv.mkDerivation {
+  name = "doclifter-2.19";
+  src = fetchurl {
+    url = "http://www.catb.org/~esr/doclifter/doclifter-2.19.tar.gz";
+    sha256 = "1as6z7mdjrrkw2kism41q5ybvyzvwcmj9qzla2fz98v9f4jbj2s2";
+  };
+  buildInputs = [ python3 ];
+
+  strictDeps = true;
+
+  makeFlags = [ "PREFIX=$(out)" ];
+
+  preInstall = ''
+    mkdir -p $out/bin
+    mkdir -p $out/share/man/man1
+    cp manlifter $out/bin
+    cp manlifter.1 $out/share/man/man1
+  '';
+
+  meta = {
+    description = "Lift documents in nroff markups to XML-DocBook";
+    homepage = "http://www.catb.org/esr/doclifter";
+    license = "BSD";
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/docopts/default.nix b/nixpkgs/pkgs/development/tools/misc/docopts/default.nix
new file mode 100644
index 000000000000..74450bdfe737
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/docopts/default.nix
@@ -0,0 +1,31 @@
+{ lib, buildGoPackage, fetchFromGitHub }:
+
+buildGoPackage rec {
+  pname = "docopts";
+  version = "0.6.3-rc2";
+
+  src = fetchFromGitHub {
+    owner = "docopt";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-PmsTkPT/sf70MKYLhHvjCDb2o3VQ1k7d++RUW7rcoAg=";
+  };
+
+  goPackagePath = "github.com/docopt/${pname}";
+
+  goDeps = ./deps.nix;
+
+  subPackages = [ "./" ];
+
+  postInstall = ''
+    install -D -m 755 ./go/src/$goPackagePath/docopts.sh $out/bin/docopts.sh
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/docopt/${pname}";
+    description = "docopt CLI tool for shell scripting";
+    license = licenses.mit;
+    maintainers = [ maintainers.confus ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/docopts/deps.nix b/nixpkgs/pkgs/development/tools/misc/docopts/deps.nix
new file mode 100644
index 000000000000..8cc1686de7d6
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/docopts/deps.nix
@@ -0,0 +1,11 @@
+[
+  {
+    goPackagePath = "github.com/docopt/docopt-go";
+    fetch = {
+      type = "git";
+      url = "https://github.com/docopt/docopt.go";
+      rev = "ee0de3bc6815ee19d4a46c7eb90f829db0e014b1"; # "0.6.2";
+      sha256 = "sha256-0mCKIC5x7aauBL8ahXB9ExMfoTJl55HaafWWWPNRmUI=";
+    };
+  }
+]
diff --git a/nixpkgs/pkgs/development/tools/misc/drush/default.nix b/nixpkgs/pkgs/development/tools/misc/drush/default.nix
new file mode 100644
index 000000000000..70e7f42c5c22
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/drush/default.nix
@@ -0,0 +1,38 @@
+{ lib, stdenv, fetchurl, php, which, makeWrapper, bash, coreutils, ncurses }:
+
+stdenv.mkDerivation rec {
+  name = "drush-6.1.0";
+
+  meta = with lib; {
+    description = "Command-line shell and Unix scripting interface for Drupal";
+    homepage    = "https://github.com/drush-ops/drush";
+    license     = licenses.gpl2;
+    maintainers = with maintainers; [ lovek323 ];
+    platforms   = platforms.all;
+  };
+
+  src = fetchurl {
+    url    = "https://github.com/drush-ops/drush/archive/6.1.0.tar.gz";
+    sha256 = "1jgnc4jjyapyn04iczvcz92ic0vq8d1w8xi55ismqyy5cxhqj6bp";
+  };
+
+  consoleTable = fetchurl {
+    url    = "http://download.pear.php.net/package/Console_Table-1.1.3.tgz";
+    sha256 = "07gbjd7m1fj5dmavr0z20vkqwx1cz2522sj9022p257jifj1yl76";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  installPhase = ''
+    # install libraries
+    cd lib
+    tar -xf ${consoleTable}
+    cd ..
+
+    mkdir -p "$out"
+    cp -r . "$out/src"
+    mkdir "$out/bin"
+    wrapProgram "$out/src/drush" --prefix PATH : "${lib.makeBinPath [ which php bash coreutils ncurses ]}"
+    ln -s "$out/src/drush" "$out/bin/drush"
+  '';
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/easypdkprog/default.nix b/nixpkgs/pkgs/development/tools/misc/easypdkprog/default.nix
new file mode 100644
index 000000000000..92d1a550ea80
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/easypdkprog/default.nix
@@ -0,0 +1,27 @@
+{ stdenv, lib, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  pname = "easypdkprog";
+  version = "1.3";
+
+  src = fetchFromGitHub {
+    owner = "free-pdk";
+    repo = "easy-pdk-programmer-software";
+    rev = version;
+    sha256 = "0hc3gdmn6l01z63hzzwdhbdyy288gh5v219bsfm8fb1498vpnd6f";
+  };
+
+  installPhase = ''
+    install -Dm755 -t $out/bin easypdkprog
+  '' + lib.optionalString stdenv.isLinux ''
+    install -Dm644 -t $out/etc/udev/rules.d Linux_udevrules/70-stm32vcp.rules
+  '';
+
+  meta = with lib; {
+    description = "Read, write and execute programs on PADAUK microcontroller";
+    homepage = "https://github.com/free-pdk/easy-pdk-programmer-software";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ david-sawatzke ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/edb/default.nix b/nixpkgs/pkgs/development/tools/misc/edb/default.nix
new file mode 100644
index 000000000000..ec65ca62fa30
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/edb/default.nix
@@ -0,0 +1,42 @@
+{ lib, mkDerivation, fetchFromGitHub, cmake, pkg-config, boost, capstone
+, double-conversion, graphviz, qtxmlpatterns }:
+
+mkDerivation rec {
+  pname = "edb";
+  version = "1.3.0";
+
+  src = fetchFromGitHub {
+    owner = "eteran";
+    repo = "edb-debugger";
+    rev = "1.3.0";
+    fetchSubmodules = true;
+    sha256 = "fFUau8XnsRFjC83HEsqyhrwCCBOfDmV6oACf3txm7O8=";
+  };
+
+  nativeBuildInputs = [ cmake pkg-config ];
+
+  buildInputs = [ boost.dev capstone double-conversion graphviz qtxmlpatterns ];
+
+  postPatch = ''
+    # Remove CMAKE_INSTALL_PREFIX from DEFAULT_PLUGIN_PATH otherwise the nix store path will appear twice.
+    substituteInPlace ./src/CMakeLists.txt --replace \
+        '-DDEFAULT_PLUGIN_PATH=\"''${CMAKE_INSTALL_PREFIX}/''${CMAKE_INSTALL_LIBDIR}/edb\"' \
+        '-DDEFAULT_PLUGIN_PATH=\"''${CMAKE_INSTALL_LIBDIR}/edb\"'
+
+    # The build script checks for the presence of .git to determine whether
+    # submodules were fetched and will throw an error if it's not there.
+    # Avoid using leaveDotGit in the fetchFromGitHub options as it is non-deterministic.
+    mkdir -p src/qhexview/.git
+
+    # Change default optional terminal program path to one that is more likely to work on NixOS.
+    substituteInPlace ./src/Configuration.cpp --replace "/usr/bin/xterm" "xterm";
+  '';
+
+  meta = with lib; {
+    description = "Cross platform AArch32/x86/x86-64 debugger";
+    homepage = "https://github.com/eteran/edb-debugger";
+    license = licenses.gpl2Plus;
+    maintainers = with maintainers; [ lihop maxxk ];
+    platforms = [ "x86_64-linux" ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/editorconfig-checker/default.nix b/nixpkgs/pkgs/development/tools/misc/editorconfig-checker/default.nix
new file mode 100644
index 000000000000..b4359bb18601
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/editorconfig-checker/default.nix
@@ -0,0 +1,32 @@
+{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
+
+buildGoModule rec {
+  pname = "editorconfig-checker";
+  version = "2.3.5";
+
+  src = fetchFromGitHub {
+    owner = "editorconfig-checker";
+    repo = "editorconfig-checker";
+    rev = version;
+    sha256 = "sha256-t1qvmTs6hOrAnq5hjU2Qjt33vdW9MuSOvWCCY82db+g=";
+  };
+
+  vendorSha256 = "sha256-Rs7u/ZepnMNg5EZ/HWqSdO428KOkxpSbo7rl0treqUY=";
+
+  doCheck = false;
+
+  nativeBuildInputs = [ installShellFiles ];
+
+  buildFlagsArray = [ "-ldflags=-X main.version=${version}" ];
+
+  postInstall = ''
+    installManPage docs/editorconfig-checker.1
+  '';
+
+  meta = with lib; {
+    description = "A tool to verify that your files are in harmony with your .editorconfig";
+    homepage = "https://editorconfig-checker.github.io/";
+    license = licenses.mit;
+    maintainers = with maintainers; [ uri-canva zowoq ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/editorconfig-core-c/default.nix b/nixpkgs/pkgs/development/tools/misc/editorconfig-core-c/default.nix
new file mode 100644
index 000000000000..de5c1e070fdb
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/editorconfig-core-c/default.nix
@@ -0,0 +1,38 @@
+{ lib, stdenv, fetchgit, cmake, pcre, doxygen }:
+
+stdenv.mkDerivation rec {
+  name = "editorconfig-core-c-${meta.version}";
+
+  src = fetchgit {
+    url = "https://github.com/editorconfig/editorconfig-core-c.git";
+    rev = "v${meta.version}";
+    sha256 = "0awpb63ci85kal3pnlj2b54bay8igj1rbc13d8gqkvidlb51nnx4";
+    fetchSubmodules = true;
+    inherit name;
+  };
+
+  buildInputs = [ pcre ];
+  nativeBuildInputs = [ cmake doxygen ];
+
+  # Multiple doxygen can not generate man pages in the same base directory in
+  # parallel: https://bugzilla.gnome.org/show_bug.cgi?id=791153
+  enableParallelBuilding = false;
+
+  meta = with lib; {
+    homepage = "https://editorconfig.org/";
+    description = "EditorConfig core library written in C";
+    longDescription = ''
+      EditorConfig makes it easy to maintain the correct coding style when
+      switching between different text editors and between different
+      projects. The EditorConfig project maintains a file format and plugins
+      for various text editors which allow this file format to be read and used
+      by those editors. For information on the file format and supported text
+      editors, see the EditorConfig website.
+    '';
+    downloadPage = "https://github.com/editorconfig/editorconfig-core-c";
+    license = with licenses; [ bsd2 bsd3 ];
+    version = "0.12.1";
+    maintainers = with maintainers; [ dochang ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/eggdbus/default.nix b/nixpkgs/pkgs/development/tools/misc/eggdbus/default.nix
new file mode 100644
index 000000000000..5a5267510d7d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/eggdbus/default.nix
@@ -0,0 +1,20 @@
+{ lib, stdenv, fetchurl, pkg-config, glib, dbus, dbus-glib }:
+
+stdenv.mkDerivation rec {
+  name = "eggdbus-0.6";
+
+  src = fetchurl {
+    url = "https://hal.freedesktop.org/releases/${name}.tar.gz";
+    sha256 = "118hj63ac65zlg71kydv4607qcg1qpdlql4kvhnwnnhar421jnq4";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ glib dbus dbus-glib ];
+
+  meta = with lib; {
+    homepage = "https://hal.freedesktop.org/releases/";
+    description = "D-Bus bindings for GObject";
+    platforms = platforms.linux;
+    license = licenses.lgpl2;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/elfinfo/default.nix b/nixpkgs/pkgs/development/tools/misc/elfinfo/default.nix
new file mode 100644
index 000000000000..e3ee51c58fdc
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/elfinfo/default.nix
@@ -0,0 +1,21 @@
+{ lib, buildGoPackage, fetchFromGitHub }:
+
+buildGoPackage rec {
+  pname = "elfinfo";
+  version = "1.1.0";
+
+  goPackagePath = "github.com/xyproto/elfinfo";
+  src = fetchFromGitHub {
+    rev = version;
+    owner = "xyproto";
+    repo = "elfinfo";
+    sha256 = "1n8bg0rcq9fqa6rdnk6x9ngvm59hcayblkpjv9j5myn2vmm6fv8m";
+  };
+
+  meta = with lib; {
+    description = "Small utility for showing information about ELF files";
+    homepage = "https://elfinfo.roboticoverlords.org/";
+    license = licenses.mit;
+    maintainers = with maintainers; [ dtzWill ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/elfkickers/default.nix b/nixpkgs/pkgs/development/tools/misc/elfkickers/default.nix
new file mode 100644
index 000000000000..775ad6937dc4
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/elfkickers/default.nix
@@ -0,0 +1,23 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  pname = "elfkickers";
+  version = "3.1a";
+
+  src = fetchurl {
+    url = "http://www.muppetlabs.com/~breadbox/pub/software/ELFkickers-${version}.tar.gz";
+    sha256 = "02354yn1lh1dxny35ky2d0b44iq302krsqpwk5grr4glma00hhq6";
+  };
+
+  makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc prefix=$(out)" ];
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    homepage = "http://www.muppetlabs.com/~breadbox/software/elfkickers.html";
+    description = "A collection of programs that access and manipulate ELF files";
+    platforms = platforms.linux;
+    license = licenses.gpl2;
+    maintainers = [ maintainers.dtzWill ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/elfutils/debug-info-from-env.patch b/nixpkgs/pkgs/development/tools/misc/elfutils/debug-info-from-env.patch
new file mode 100644
index 000000000000..409f1311c315
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/elfutils/debug-info-from-env.patch
@@ -0,0 +1,27 @@
+Look up .build-id files relative to the directories in the
+colon-separated environment variable NIX_DEBUG_INFO_DIRS, unless
+overriden by --debuginfo-path.
+
+diff -ru elfutils-0.169-orig/libdwfl/argp-std.c elfutils-0.169/libdwfl/argp-std.c
+--- elfutils-0.169-orig/libdwfl/argp-std.c	2017-05-02 23:05:52.000000000 +0200
++++ elfutils-0.169/libdwfl/argp-std.c	2017-07-28 16:08:06.739558106 +0200
+@@ -376,5 +376,7 @@
+ const struct argp *
+ dwfl_standard_argp (void)
+ {
++  debuginfo_path = getenv("NIX_DEBUG_INFO_DIRS");
++
+   return &libdwfl_argp;
+ }
+diff -ru elfutils-0.169-orig/src/stack.c elfutils-0.169/src/stack.c
+--- elfutils-0.169-orig/src/stack.c	2017-02-24 11:55:28.000000000 +0100
++++ elfutils-0.169/src/stack.c	2017-07-28 15:50:06.743196696 +0200
+@@ -631,6 +631,8 @@
+   /* Set locale.  */
+   (void) setlocale (LC_ALL, "");
+ 
++  debuginfo_path = getenv("NIX_DEBUG_INFO_DIRS");
++
+   const struct argp_option options[] =
+     {
+       { NULL, 0, NULL, 0, N_("Input selection options:"), 0 },
diff --git a/nixpkgs/pkgs/development/tools/misc/elfutils/default.nix b/nixpkgs/pkgs/development/tools/misc/elfutils/default.nix
new file mode 100644
index 000000000000..c1227775785a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/elfutils/default.nix
@@ -0,0 +1,106 @@
+{ lib, stdenv, fetchurl, fetchpatch, pkg-config, autoreconfHook, musl-fts
+, musl-obstack, m4, zlib, bzip2, bison, flex, gettext, xz, setupDebugInfoDirs
+, argp-standalone
+, enableDebuginfod ? false, sqlite, curl, libmicrohttpd_0_9_70, libarchive
+}:
+
+# TODO: Look at the hardcoded paths to kernel, modules etc.
+stdenv.mkDerivation rec {
+  pname = "elfutils";
+  version = "0.182";
+
+  src = fetchurl {
+    url = "https://sourceware.org/elfutils/ftp/${version}/${pname}-${version}.tar.bz2";
+    sha256 = "7MQGkU7fM18Lf8CE6+bEYMTW1Rdb/dZojBx42RRriFg=";
+  };
+
+  patches = [
+    ./debug-info-from-env.patch
+    ./musl-cdefs_h.patch
+    (fetchpatch {
+      name = "fix-aarch64_fregs.patch";
+      url = "https://git.alpinelinux.org/aports/plain/main/elfutils/fix-aarch64_fregs.patch?id=2e3d4976eeffb4704cf83e2cc3306293b7c7b2e9";
+      sha256 = "zvncoRkQx3AwPx52ehjA2vcFroF+yDC2MQR5uS6DATs=";
+    })
+    (fetchpatch {
+      name = "musl-asm-ptrace-h.patch";
+      url = "https://git.alpinelinux.org/aports/plain/main/elfutils/musl-asm-ptrace-h.patch?id=2e3d4976eeffb4704cf83e2cc3306293b7c7b2e9";
+      sha256 = "8D1wPcdgAkE/TNBOgsHaeTZYhd9l+9TrZg8d5C7kG6k=";
+    })
+    (fetchpatch {
+      name = "musl-fts-obstack.patch";
+      url = "https://git.alpinelinux.org/aports/plain/main/elfutils/musl-fts-obstack.patch?id=2e3d4976eeffb4704cf83e2cc3306293b7c7b2e9";
+      sha256 = "3lbC0UtscTIJgT7kOXnnjWrpPAVt2PYMbW+uJK6K350=";
+    })
+    (fetchpatch {
+      name = "musl-macros.patch";
+      url = "https://git.alpinelinux.org/aports/plain/main/elfutils/musl-macros.patch?id=2e3d4976eeffb4704cf83e2cc3306293b7c7b2e9";
+      sha256 = "tp6O1TRsTAMsFe8vw3LMENT/vAu6OmyA8+pzgThHeA8=";
+    })
+    (fetchpatch {
+      name = "musl-qsort_r.patch";
+      url = "https://git.alpinelinux.org/aports/plain/main/elfutils/musl-qsort_r.patch?id=2e3d4976eeffb4704cf83e2cc3306293b7c7b2e9";
+      sha256 = "FPWCkdtFT3zw8aNnz0Jz5Vmu8B/mRfNgfhbM/ej7d8M=";
+    })
+    (fetchpatch {
+      name = "musl-strerror_r.patch";
+      url = "https://git.alpinelinux.org/aports/plain/main/elfutils/musl-strerror_r.patch?id=2e3d4976eeffb4704cf83e2cc3306293b7c7b2e9";
+      sha256 = "QF6YwWkcT12dZHKzfqFgxy/1fkIllo0AAosbV0sM5PU=";
+    })
+    (fetchpatch {
+      name = "musl-strndupa.patch";
+      url = "https://git.alpinelinux.org/aports/plain/main/elfutils/musl-strndupa.patch?id=2e3d4976eeffb4704cf83e2cc3306293b7c7b2e9";
+      sha256 = "sha256-7daehJj1t0wPtQzTv+/Rpuqqs5Ng/EYnZzrcf2o/Lb0=";
+    })
+  ] ++ lib.optional stdenv.hostPlatform.isMusl [ ./musl-error_h.patch ];
+
+  outputs = [ "bin" "dev" "out" "man" ];
+
+  hardeningDisable = [ "format" ];
+
+  # We need bzip2 in NativeInputs because otherwise we can't unpack the src,
+  # as the host-bzip2 will be in the path.
+  nativeBuildInputs = [ m4 bison flex gettext bzip2 ]
+    ++ lib.optional stdenv.hostPlatform.isMusl autoreconfHook
+    ++ lib.optional (enableDebuginfod || stdenv.hostPlatform.isMusl) pkg-config;
+  buildInputs = [ zlib bzip2 xz ]
+    ++ lib.optionals stdenv.hostPlatform.isMusl [
+    argp-standalone
+    musl-fts
+    musl-obstack
+  ] ++ lib.optionals enableDebuginfod [
+    sqlite
+    curl
+    libmicrohttpd_0_9_70
+    libarchive
+  ];
+
+  propagatedNativeBuildInputs = [ setupDebugInfoDirs ];
+
+  preConfigure = lib.optionalString stdenv.hostPlatform.isMusl ''
+    NIX_CFLAGS_COMPILE+=" -Wno-null-dereference"
+  '';
+
+  configureFlags = [
+    "--program-prefix=eu-" # prevent collisions with binutils
+    "--enable-deterministic-archives"
+  ] ++ lib.optionals (!enableDebuginfod) [
+    "--disable-libdebuginfod"
+    "--disable-debuginfod"
+  ];
+
+  enableParallelBuilding = true;
+
+  doCheck = false; # fails 3 out of 174 tests
+  doInstallCheck = false; # fails 70 out of 174 tests
+
+  meta = with lib; {
+    homepage = "https://sourceware.org/elfutils/";
+    description = "A set of utilities to handle ELF objects";
+    platforms = platforms.linux;
+    # licenses are GPL2 or LGPL3+ for libraries, GPL3+ for bins,
+    # but since this package isn't split that way, all three are listed.
+    license = with licenses; [ gpl2Only lgpl3Plus gpl3Plus ];
+    maintainers = [ maintainers.eelco ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/elfutils/musl-cdefs_h.patch b/nixpkgs/pkgs/development/tools/misc/elfutils/musl-cdefs_h.patch
new file mode 100644
index 000000000000..1b5bf466217b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/elfutils/musl-cdefs_h.patch
@@ -0,0 +1,15 @@
+# avoids a warning about including an internal header when
+# compiling with musl-libc
+diff -crb --new-file a/lib/fixedsizehash.h b/lib/fixedsizehash.h
+*** a/lib/fixedsizehash.h	2020-06-11 11:37:46.000000000 -0400
+--- b/lib/fixedsizehash.h	2021-01-21 05:52:59.000000000 -0500
+***************
+*** 30,36 ****
+  #include <errno.h>
+  #include <stdlib.h>
+  #include <string.h>
+- #include <sys/cdefs.h>
+  
+  #include <system.h>
+  
+--- 30,35 ----
diff --git a/nixpkgs/pkgs/development/tools/misc/elfutils/musl-error_h.patch b/nixpkgs/pkgs/development/tools/misc/elfutils/musl-error_h.patch
new file mode 100644
index 000000000000..711928078d35
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/elfutils/musl-error_h.patch
@@ -0,0 +1,66 @@
+diff -crb --new-file a/lib/error.h b/lib/error.h
+*** a/lib/error.h	1969-12-31 19:00:00.000000000 -0500
+--- b/lib/error.h	2021-01-21 04:38:25.000000000 -0500
+***************
+*** 0 ****
+--- 1,27 ----
++ #ifndef _ERROR_H_
++ #define _ERROR_H_
++ 
++ #include <stdarg.h>
++ #include <stdio.h>
++ #include <stdlib.h>
++ #include <string.h>
++ #include <errno.h>
++ 
++ static unsigned int error_message_count = 0;
++ 
++ static inline void error(int status, int errnum, const char* format, ...)
++ {
++ 	va_list ap;
++ 	fprintf(stderr, "%s: ", program_invocation_name);
++ 	va_start(ap, format);
++ 	vfprintf(stderr, format, ap);
++ 	va_end(ap);
++ 	if (errnum)
++ 		fprintf(stderr, ": %s", strerror(errnum));
++ 	fprintf(stderr, "\n");
++ 	error_message_count++;
++ 	if (status)
++ 		exit(status);
++ }
++ 
++ #endif	/* _ERROR_H_ */
+diff -crb --new-file a/src/error.h b/src/error.h
+*** a/src/error.h	1969-12-31 19:00:00.000000000 -0500
+--- b/src/error.h	2021-01-21 04:38:29.000000000 -0500
+***************
+*** 0 ****
+--- 1,27 ----
++ #ifndef _ERROR_H_
++ #define _ERROR_H_
++ 
++ #include <stdarg.h>
++ #include <stdio.h>
++ #include <stdlib.h>
++ #include <string.h>
++ #include <errno.h>
++ 
++ static unsigned int error_message_count = 0;
++ 
++ static inline void error(int status, int errnum, const char* format, ...)
++ {
++ 	va_list ap;
++ 	fprintf(stderr, "%s: ", program_invocation_name);
++ 	va_start(ap, format);
++ 	vfprintf(stderr, format, ap);
++ 	va_end(ap);
++ 	if (errnum)
++ 		fprintf(stderr, ": %s", strerror(errnum));
++ 	fprintf(stderr, "\n");
++ 	error_message_count++;
++ 	if (status)
++ 		exit(status);
++ }
++ 
++ #endif	/* _ERROR_H_ */
diff --git a/nixpkgs/pkgs/development/tools/misc/epm/default.nix b/nixpkgs/pkgs/development/tools/misc/epm/default.nix
new file mode 100644
index 000000000000..8f5921783e24
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/epm/default.nix
@@ -0,0 +1,27 @@
+{lib, stdenv, fetchFromGitHub, rpm}:
+
+stdenv.mkDerivation rec {
+  pname = "epm";
+  version = "4.4";
+
+  src = fetchFromGitHub {
+    repo = "epm";
+    owner = "michaelrsweet";
+    rev = "v${version}";
+    sha256 = "0kaw7v2m20qirapkps4dna6nf9xibnwljvvv0l9vpvi920kw7j7p";
+  };
+
+  buildInputs = [ rpm ];
+
+  preInstall = ''
+    sed -i 's/README/README.md/' Makefile
+  '';
+
+  meta = with lib; {
+    description = "The ESP Package Manager generates distribution archives for a variety of platforms";
+    homepage = "https://www.msweet.org/projects.php?Z2";
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ pSub ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/findnewest/default.nix b/nixpkgs/pkgs/development/tools/misc/findnewest/default.nix
new file mode 100644
index 000000000000..6773e9bc0bd4
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/findnewest/default.nix
@@ -0,0 +1,22 @@
+{ lib, stdenv, fetchFromGitHub, autoreconfHook }:
+
+stdenv.mkDerivation rec {
+  pname = "findnewest";
+  version = "0.3";
+
+  src = fetchFromGitHub {
+    owner = "0-wiz-0";
+    repo = pname;
+    rev = "${pname}-${version}";
+    sha256 = "1x1cbn2b27h5r0ah5xc06fkalfdci2ngrgd4wibxjw0h88h0nvgq";
+  };
+
+  nativeBuildInputs = [ autoreconfHook ];
+
+  meta = with lib; {
+    homepage = "https://github.com/0-wiz-0/findnewest";
+    description = "Recursively find newest file in a hierarchy and print its timestamp";
+    license = licenses.bsd2;
+    maintainers = with maintainers; [ bhipple ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/fsatrace/default.nix b/nixpkgs/pkgs/development/tools/misc/fsatrace/default.nix
new file mode 100644
index 000000000000..132ddf2eacfd
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/fsatrace/default.nix
@@ -0,0 +1,34 @@
+{ lib, stdenv, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  pname = "fsatrace";
+  version = "0.0.1-324";
+
+  src = fetchFromGitHub {
+    owner = "jacereda";
+    repo = "fsatrace";
+    rev = "41fbba17da580f81ababb32ec7e6e5fd49f11473";
+    sha256 = "1ihm2v723idd6m0kc1z9v73hmfvh2v0vjs8wvx5w54jaxh3lmj1y";
+  };
+
+  installDir = "libexec/${pname}-${version}";
+
+  makeFlags = [ "INSTALLDIR=$(out)/$(installDir)" ];
+
+  preInstall = ''
+    mkdir -p $out/$installDir
+  '';
+
+  postInstall = ''
+    mkdir -p $out/bin
+    ln -s $out/$installDir/fsatrace $out/bin/fsatrace
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/jacereda/fsatrace";
+    description = "filesystem access tracer";
+    license = licenses.isc;
+    maintainers = [ maintainers.peti ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/fswatch/default.nix b/nixpkgs/pkgs/development/tools/misc/fswatch/default.nix
new file mode 100644
index 000000000000..5eb252a9c0e4
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/fswatch/default.nix
@@ -0,0 +1,35 @@
+{ lib, stdenv
+, fetchFromGitHub
+, autoreconfHook
+                     # for xargs
+, gettext
+, libtool
+, makeWrapper
+, texinfo
+, CoreServices
+}:
+
+stdenv.mkDerivation rec {
+  pname = "fswatch";
+  version = "1.16.0";
+
+  src = fetchFromGitHub {
+    owner = "emcrisostomo";
+    repo = "fswatch";
+    rev = version;
+    sha256 = "sha256-EKbo5gkrWuijLJgYsNBDtxy0ioXu/yHxnPPeOpk620g=";
+  };
+
+  nativeBuildInputs = [ autoreconfHook makeWrapper ] ++ lib.optionals stdenv.isDarwin [ CoreServices ];
+  buildInputs = [ gettext libtool texinfo ];
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    description = "A cross-platform file change monitor with multiple backends";
+    homepage = "https://github.com/emcrisostomo/fswatch";
+    license = licenses.gpl3Plus;
+    platforms = platforms.all;
+    maintainers = with maintainers; [ pSub ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/fujprog/default.nix b/nixpkgs/pkgs/development/tools/misc/fujprog/default.nix
new file mode 100644
index 000000000000..db1f42e3a266
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/fujprog/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv
+, fetchFromGitHub
+, cmake
+, pkg-config
+, IOKit
+, libftdi1
+, libusb-compat-0_1
+}:
+
+stdenv.mkDerivation rec {
+  pname = "fujprog";
+  version = "4.8";
+
+  src = fetchFromGitHub {
+    owner = "kost";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "08kzkzd5a1wfd1aycywdynxh3qy6n7z9i8lihkahmb4xac3chmz5";
+  };
+
+  nativeBuildInputs = [
+    cmake
+    pkg-config
+  ];
+
+  buildInputs = [
+    libftdi1
+    libusb-compat-0_1
+  ] ++ lib.optionals stdenv.isDarwin [ IOKit ];
+
+  meta = with lib; {
+    description = "JTAG programmer for the ULX3S and ULX2S open hardware FPGA development boards";
+    homepage = "https://github.com/kost/fujprog";
+    license = licenses.bsd2;
+    maintainers = with maintainers; [ trepetti ];
+    platforms = platforms.all;
+    changelog = "https://github.com/kost/fujprog/releases/tag/v${version}";
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gdb/darwin-target-match.patch b/nixpkgs/pkgs/development/tools/misc/gdb/darwin-target-match.patch
new file mode 100644
index 000000000000..978a67950569
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gdb/darwin-target-match.patch
@@ -0,0 +1,11 @@
+--- a/configure	2017-06-05 00:51:26.000000000 +0900
++++ b/configure	2018-03-06 23:12:58.000000000 +0900
+@@ -3644,7 +3644,7 @@
+     noconfigdirs="$noconfigdirs ld gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
+-  x86_64-*-darwin[912]*)
++  x86_64-*-darwin*)
+     noconfigdirs="$noconfigdirs ld gas gprof"
+     noconfigdirs="$noconfigdirs sim target-rda"
+     ;;
diff --git a/nixpkgs/pkgs/development/tools/misc/gdb/debug-info-from-env.patch b/nixpkgs/pkgs/development/tools/misc/gdb/debug-info-from-env.patch
new file mode 100644
index 000000000000..de59bd2d17bb
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gdb/debug-info-from-env.patch
@@ -0,0 +1,24 @@
+diff -ur a/gdb/main.c b/gdb/main.c
+--- a/gdb/main.c	2020-02-08 13:50:14.000000000 +0100
++++ b/gdb/main.c	2020-02-24 10:02:07.731806739 +0100
+@@ -567,9 +567,17 @@
+       gdb_sysroot = xstrdup (TARGET_SYSROOT_PREFIX);
+     }
+ 
+-  debug_file_directory
+-    = xstrdup (relocate_gdb_directory (DEBUGDIR,
+-				     DEBUGDIR_RELOCATABLE).c_str ());
++  debug_file_directory = getenv ("NIX_DEBUG_INFO_DIRS");
++  if (debug_file_directory != NULL)
++    // This might be updated later using
++    // $ set debug-file-directory /to/some/path
++    // which will use xfree. We must then have a xmallocated
++    // copy of the string that can be xfeed later.
++    debug_file_directory = xstrdup (debug_file_directory);
++  else
++    debug_file_directory
++      = xstrdup (relocate_gdb_directory (DEBUGDIR,
++                                         DEBUGDIR_RELOCATABLE).c_str ());
+ 
+   gdb_datadir = relocate_gdb_directory (GDB_DATADIR,
+ 					GDB_DATADIR_RELOCATABLE);
diff --git a/nixpkgs/pkgs/development/tools/misc/gdb/default.nix b/nixpkgs/pkgs/development/tools/misc/gdb/default.nix
new file mode 100644
index 000000000000..ffe1fa3662f8
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gdb/default.nix
@@ -0,0 +1,118 @@
+{ lib, stdenv, targetPackages
+
+# Build time
+, fetchurl, pkg-config, perl, texinfo, setupDebugInfoDirs, buildPackages
+
+# Run time
+, ncurses, readline, gmp, mpfr, expat, libipt, zlib, dejagnu
+
+, pythonSupport ? stdenv.hostPlatform == stdenv.buildPlatform && !stdenv.hostPlatform.isCygwin, python3 ? null
+, guile ? null
+, safePaths ? [
+   # $debugdir:$datadir/auto-load are whitelisted by default by GDB
+   "$debugdir" "$datadir/auto-load"
+   # targetPackages so we get the right libc when cross-compiling and using buildPackages.gdb
+   targetPackages.stdenv.cc.cc.lib
+  ]
+}:
+
+let
+  basename = "gdb";
+  targetPrefix = lib.optionalString (stdenv.targetPlatform != stdenv.hostPlatform)
+                 "${stdenv.targetPlatform.config}-";
+in
+
+assert pythonSupport -> python3 != null;
+
+stdenv.mkDerivation rec {
+  pname = targetPrefix + basename;
+  version = "10.2";
+
+  src = fetchurl {
+    url = "mirror://gnu/gdb/${basename}-${version}.tar.xz";
+    sha256 = "0aag1c0fw875pvhjg1qp7x8pf6gf92bjv5gcic5716scacyj58da";
+  };
+
+  postPatch = if stdenv.isDarwin then ''
+    substituteInPlace gdb/darwin-nat.c \
+      --replace '#include "bfd/mach-o.h"' '#include "mach-o.h"'
+  '' else null;
+
+  patches = [
+    ./debug-info-from-env.patch
+  ] ++ lib.optionals stdenv.isDarwin [
+    ./darwin-target-match.patch
+  ];
+
+  nativeBuildInputs = [ pkg-config texinfo perl setupDebugInfoDirs ];
+
+  buildInputs = [ ncurses readline gmp mpfr expat libipt zlib guile ]
+    ++ lib.optional pythonSupport python3
+    ++ lib.optional doCheck dejagnu;
+
+  propagatedNativeBuildInputs = [ setupDebugInfoDirs ];
+
+  depsBuildBuild = [ buildPackages.stdenv.cc ];
+
+  enableParallelBuilding = true;
+
+  # darwin build fails with format hardening since v7.12
+  hardeningDisable = lib.optionals stdenv.isDarwin [ "format" ];
+
+  NIX_CFLAGS_COMPILE = "-Wno-format-nonliteral";
+
+  configurePlatforms = [ "build" "host" "target" ];
+
+  # GDB have to be built out of tree.
+  preConfigure = ''
+    mkdir _build
+    cd _build
+  '';
+  configureScript = "../configure";
+
+  configureFlags = with lib; [
+    # Set the program prefix to the current targetPrefix.
+    # This ensures that the prefix always conforms to
+    # nixpkgs' expectations instead of relying on the build
+    # system which only receives `config` which is merely a
+    # subset of the platform description.
+    "--program-prefix=${targetPrefix}"
+
+    "--enable-targets=all" "--enable-64-bit-bfd"
+    "--disable-install-libbfd"
+    "--disable-shared" "--enable-static"
+    "--with-system-zlib"
+    "--with-system-readline"
+
+    "--with-gmp=${gmp.dev}"
+    "--with-mpfr=${mpfr.dev}"
+    "--with-expat" "--with-libexpat-prefix=${expat.dev}"
+    "--with-auto-load-safe-path=${builtins.concatStringsSep ":" safePaths}"
+  ] ++ lib.optional (!pythonSupport) "--without-python"
+    ++ lib.optional stdenv.hostPlatform.isMusl "--disable-nls";
+
+  postInstall =
+    '' # Remove Info files already provided by Binutils and other packages.
+       rm -v $out/share/info/bfd.info
+    '';
+
+  # TODO: Investigate & fix the test failures.
+  doCheck = false;
+
+  meta = with lib; {
+    description = "The GNU Project debugger";
+
+    longDescription = ''
+      GDB, the GNU Project debugger, allows you to see what is going
+      on `inside' another program while it executes -- or what another
+      program was doing at the moment it crashed.
+    '';
+
+    homepage = "https://www.gnu.org/software/gdb/";
+
+    license = lib.licenses.gpl3Plus;
+
+    platforms = with platforms; linux ++ cygwin ++ darwin;
+    maintainers = with maintainers; [ pierron globin lsix ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gdbgui/default.nix b/nixpkgs/pkgs/development/tools/misc/gdbgui/default.nix
new file mode 100644
index 000000000000..a82ff178c9eb
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gdbgui/default.nix
@@ -0,0 +1,96 @@
+{ lib
+, buildPythonApplication
+, fetchPypi
+, gdb
+, flask
+, six
+, bidict
+, python-engineio
+, python-socketio
+, flask-socketio
+, flask-compress
+, pygdbmi
+, pygments
+, gevent
+, gevent-websocket
+, eventlet
+, }:
+
+let
+  # gdbgui only works with the latest previous major version of flask-socketio,
+  # which depends itself on the latest previous major versions of dependencies.
+  python-engineio' = python-engineio.overridePythonAttrs (old: rec {
+    version = "3.14.2";
+    src = fetchPypi {
+      inherit (old) pname;
+      inherit version;
+      sha256 = "119halljynqsgswlhlh750qv56js1p7j52sc0nbwxh8450zmbd7a";
+    };
+    propagatedBuildInputs = [ six ];
+    doCheck = false;
+  });
+  python-socketio' = python-socketio.overridePythonAttrs (old: rec {
+    version = "4.6.1";
+    src = fetchPypi {
+      inherit (old) pname;
+      inherit version;
+      sha256 = "047syhrrxh327p0fnab0d1zy25zijnj3gs1qg3kjpsy1jaj5l7yd";
+    };
+    propagatedBuildInputs = [ bidict python-engineio' ];
+    doCheck = false;
+  });
+  flask-socketio' = flask-socketio.overridePythonAttrs (old: rec {
+    version = "4.3.2";
+    src = fetchPypi {
+      inherit (old) pname;
+      inherit version;
+      sha256 = "0s2xs9kv9cbwy8bcxszhdwlcb9ldv0fj33lwilf5vypj0wsin01p";
+    };
+    propagatedBuildInputs = [ flask python-socketio' ];
+    doCheck = false;
+  });
+in
+buildPythonApplication rec {
+  pname = "gdbgui";
+  version = "0.14.0.2";
+
+  buildInputs = [ gdb ];
+  propagatedBuildInputs = [
+    flask
+    flask-socketio'
+    flask-compress
+    pygdbmi
+    pygments
+    gevent
+    gevent-websocket
+    eventlet
+  ];
+
+  src = fetchPypi {
+    inherit pname version;
+    sha256 = "1v6wwsncgnhlg5c7gsmzcp52hfblfnz5kf5pk4d0zybflsxak02d";
+  };
+
+  postPatch = ''
+    echo ${version} > gdbgui/VERSION.txt
+    # remove upper version bound
+    sed -ie 's!, <.*"!"!' setup.py
+    sed -i 's/greenlet==/greenlet>=/' setup.py
+  '';
+
+  postInstall = ''
+    wrapProgram $out/bin/gdbgui \
+      --prefix PATH : ${lib.makeBinPath [ gdb ]}
+  '';
+
+  # tests do not work without stdout/stdin
+  doCheck = false;
+
+  meta = with lib; {
+    description = "A browser-based frontend for GDB";
+    homepage = "https://www.gdbgui.com/";
+    license = licenses.gpl3;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ yrashk dump_stack ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gede/default.nix b/nixpkgs/pkgs/development/tools/misc/gede/default.nix
new file mode 100644
index 000000000000..00ce9958b1f9
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gede/default.nix
@@ -0,0 +1,35 @@
+{ mkDerivation, lib, fetchurl, makeWrapper, python3, qmake, ctags, gdb }:
+
+mkDerivation rec {
+  pname = "gede";
+  version = "2.17.1";
+
+  src = fetchurl {
+    url = "http://gede.dexar.se/uploads/source/${pname}-${version}.tar.xz";
+    sha256 = "0hbsy2ymzgl8xd9mnh43gxdfncy7g6czxfvfyh7zp3ij8yiwf8x3";
+  };
+
+  nativeBuildInputs = [ qmake makeWrapper python3 ];
+
+  buildInputs = [ ctags ];
+
+  strictDeps = true;
+
+  dontUseQmakeConfigure = true;
+
+  buildPhase = ":";
+
+  installPhase = ''
+    python build.py install --verbose --prefix="$out"
+    wrapProgram $out/bin/gede \
+      --prefix PATH : ${lib.makeBinPath [ ctags gdb ]}
+  '';
+
+  meta = with lib; {
+    description = "Graphical frontend (GUI) to GDB";
+    homepage = "http://gede.dexar.se";
+    license = licenses.bsd2;
+    platforms = platforms.linux;
+    maintainers = with maintainers; [ juliendehos ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gengetopt/default.nix b/nixpkgs/pkgs/development/tools/misc/gengetopt/default.nix
new file mode 100644
index 000000000000..2c09f925d3d8
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gengetopt/default.nix
@@ -0,0 +1,45 @@
+{ fetchurl, lib, stdenv, texinfo, help2man }:
+
+stdenv.mkDerivation rec {
+  pname = "gengetopt";
+  version = "2.23";
+
+  src = fetchurl {
+    url = "mirror://gnu/${pname}/${pname}-${version}.tar.xz";
+    sha256 = "1b44fn0apsgawyqa4alx2qj5hls334mhbszxsy6rfr0q074swhdr";
+  };
+
+  doCheck = true;
+  # attempts to open non-existent file
+  preCheck = ''
+    rm tests/test_conf_parser_save.sh
+  '';
+
+  enableParallelBuilding = true;
+
+  nativeBuildInputs = [ texinfo help2man ];
+
+  #Fix, see #28255
+  postPatch = ''
+    substituteInPlace configure --replace \
+      'set -o posix' \
+      'set +o posix'
+  '';
+
+  meta = {
+    description = "Command-line option parser generator";
+
+    longDescription =
+      '' GNU Gengetopt program generates a C function that uses getopt_long
+         function to parse the command line options, to validate them and
+         fills a struct
+      '';
+
+    homepage = "https://www.gnu.org/software/gengetopt/";
+
+    license = lib.licenses.gpl3Plus;
+
+    maintainers = [ ];
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/global/default.nix b/nixpkgs/pkgs/development/tools/misc/global/default.nix
new file mode 100644
index 000000000000..739615a841c7
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/global/default.nix
@@ -0,0 +1,61 @@
+{ fetchurl, lib, stdenv, libtool, makeWrapper
+, coreutils, ctags, ncurses, python3Packages, sqlite, universal-ctags
+}:
+
+let
+  pygments = python3Packages.pygments;
+in stdenv.mkDerivation rec {
+  pname = "global";
+  version = "6.6.6";
+
+  src = fetchurl {
+    url = "mirror://gnu/global/${pname}-${version}.tar.gz";
+    sha256 = "sha256-dYB4r/+Y1MBRxYeFx62j7Rl3+rt3+Il/9le3HMYtTV0=";
+  };
+
+  nativeBuildInputs = [ libtool makeWrapper ];
+
+  buildInputs = [ ncurses ];
+
+  propagatedBuildInputs = [ pygments ];
+
+  configureFlags = [
+    "--with-ltdl-include=${libtool}/include"
+    "--with-ltdl-lib=${libtool.lib}/lib"
+    "--with-ncurses=${ncurses.dev}"
+    "--with-sqlite3=${sqlite.dev}"
+    "--with-exuberant-ctags=${ctags}/bin/ctags"
+    "--with-universal-ctags=${universal-ctags}/bin/ctags"
+    "--with-posix-sort=${coreutils}/bin/sort"
+  ];
+
+  doCheck = true;
+
+  postInstall = ''
+    mkdir -p "$out/share/emacs/site-lisp"
+    cp -v *.el "$out/share/emacs/site-lisp"
+
+    wrapProgram $out/bin/gtags \
+      --prefix PYTHONPATH : "$(toPythonPath ${pygments})"
+    wrapProgram $out/bin/global \
+      --prefix PYTHONPATH : "$(toPythonPath ${pygments})"
+  '';
+
+  meta = with lib; {
+    description = "Source code tag system";
+    longDescription = ''
+      GNU GLOBAL is a source code tagging system that works the same way
+      across diverse environments (Emacs, vi, less, Bash, web browser, etc).
+      You can locate specified objects in source files and move there easily.
+      It is useful for hacking a large project containing many
+      subdirectories, many #ifdef and many main() functions.  It is similar
+      to ctags or etags but is different from them at the point of
+      independence of any editor.  It runs on a UNIX (POSIX) compatible
+      operating system like GNU and BSD.
+    '';
+    homepage = "https://www.gnu.org/software/global/";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ pSub peterhoeg ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gnum4/darwin-secure-format.patch b/nixpkgs/pkgs/development/tools/misc/gnum4/darwin-secure-format.patch
new file mode 100644
index 000000000000..b14d8be6ef16
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gnum4/darwin-secure-format.patch
@@ -0,0 +1,15 @@
+With format string strictness, High Sierra also enforces that %n isn't used
+in dynamic format strings, but we should just disable its use on darwin in
+general.
+
+--- a/lib/vasnprintf.c	2017-06-22 15:19:15.000000000 -0700
++++ b/lib/vasnprintf.c	2017-06-22 15:20:20.000000000 -0700
+@@ -4869,7 +4869,7 @@ VASNPRINTF (DCHAR_T *resultbuf, size_t *
+ #endif
+                   *fbp = dp->conversion;
+ #if USE_SNPRINTF
+-# if !(((__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 3)) && !defined __UCLIBC__) || ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__))
++# if !defined(__APPLE__) && !(((__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 3)) && !defined __UCLIBC__) || ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__))
+                 fbp[1] = '%';
+                 fbp[2] = 'n';
+                 fbp[3] = '\0';
diff --git a/nixpkgs/pkgs/development/tools/misc/gnum4/default.nix b/nixpkgs/pkgs/development/tools/misc/gnum4/default.nix
new file mode 100644
index 000000000000..512989a14462
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gnum4/default.nix
@@ -0,0 +1,56 @@
+{ lib, stdenv, fetchurl }:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+stdenv.mkDerivation {
+  name = "gnum4-1.4.18";
+
+  src = fetchurl {
+    url = "mirror://gnu/m4/m4-1.4.18.tar.bz2";
+    sha256 = "1xkwwq0sgv05cla0g0a01yzhk0wpsn9y40w9kh9miiiv0imxfh36";
+  };
+
+  doCheck = false;
+
+  configureFlags = [ "--with-syscmd-shell=${stdenv.shell}" ];
+
+  # Upstream is aware of it; it may be in the next release.
+  patches =
+    [
+      ./s_isdir.patch
+      (fetchurl {
+        url = "https://sources.debian.org/data/main/m/m4/1.4.18-2/debian/patches/01-fix-ftbfs-with-glibc-2.28.patch";
+        sha256 = "12lmdnbml9lfvy0khpjc42riicddaz7li8wmbnsam7zsw6al11qk";
+      })
+    ]
+    ++ lib.optional stdenv.isDarwin ./darwin-secure-format.patch;
+
+  meta = {
+    homepage = "https://www.gnu.org/software/m4/";
+    description = "GNU M4, a macro processor";
+
+    longDescription = ''
+      GNU M4 is an implementation of the traditional Unix macro
+      processor.  It is mostly SVR4 compatible although it has some
+      extensions (for example, handling more than 9 positional
+      parameters to macros).  GNU M4 also has built-in functions for
+      including files, running shell commands, doing arithmetic, etc.
+
+      GNU M4 is a macro processor in the sense that it copies its
+      input to the output expanding macros as it goes.  Macros are
+      either builtin or user-defined and can take any number of
+      arguments.  Besides just doing macro expansion, m4 has builtin
+      functions for including named files, running UNIX commands,
+      doing integer arithmetic, manipulating text in various ways,
+      recursion etc...  m4 can be used either as a front-end to a
+      compiler or as a macro processor in its own right.
+    '';
+
+    license = lib.licenses.gpl3Plus;
+    platforms = lib.platforms.unix ++ lib.platforms.windows;
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gnum4/s_isdir.patch b/nixpkgs/pkgs/development/tools/misc/gnum4/s_isdir.patch
new file mode 100644
index 000000000000..a009a4ba4465
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gnum4/s_isdir.patch
@@ -0,0 +1,14 @@
+Fails to build with glibc 2.12.1 without this patch.
+
+http://lists.gnu.org/archive/html/bug-m4/2010-05/msg00002.html
+
+--- a/src/path.c
++++ b/src/path.c
+@@ -22,6 +22,7 @@
+ /* Handling of path search of included files via the builtins "include"
+    and "sinclude".  */
+ 
+ #include "m4.h"
++#include "sys/stat.h"
+ 
+ struct includes
diff --git a/nixpkgs/pkgs/development/tools/misc/go-license-detector/default.nix b/nixpkgs/pkgs/development/tools/misc/go-license-detector/default.nix
new file mode 100644
index 000000000000..91c6518bc26d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/go-license-detector/default.nix
@@ -0,0 +1,24 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "go-license-detector";
+  version = "3.1.0";
+
+  src = fetchFromGitHub {
+    owner = "src-d";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "0ln1z3y9q5igf9djkxw05ql2hb1ijcvvz0mrbwz11cdv9xrsa4z4";
+  };
+
+  vendorSha256 = "0gan5l7vsq0hixxcymhhs8p07v92w60r0lhgvrr9a99nic12vmia";
+
+  doCheck = false;
+
+  meta = with lib; {
+    description = "Reliable project licenses detector";
+    homepage = "https://github.com/src-d/go-license-detector";
+    license = licenses.asl20;
+    maintainers = with maintainers; [ dtzWill ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/go-md2man/default.nix b/nixpkgs/pkgs/development/tools/misc/go-md2man/default.nix
new file mode 100644
index 000000000000..fe43da91b54b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/go-md2man/default.nix
@@ -0,0 +1,23 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "go-md2man";
+  version = "2.0.0";
+
+  vendorSha256 = null;
+
+  src = fetchFromGitHub {
+    rev = "v${version}";
+    owner = "cpuguy83";
+    repo = "go-md2man";
+    sha256 = "0r1f7v475dxxgzqci1mxfliwadcrk86ippflx9n411325l4g3ghv";
+  };
+
+  meta = with lib; {
+    description = "Go tool to convert markdown to man pages";
+    license = licenses.mit;
+    homepage = "https://github.com/cpuguy83/go-md2man";
+    maintainers = with maintainers; [offline];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gob2/default.nix b/nixpkgs/pkgs/development/tools/misc/gob2/default.nix
new file mode 100644
index 000000000000..06487845fb3d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gob2/default.nix
@@ -0,0 +1,29 @@
+{ lib, stdenv, fetchurl, pkg-config, glib, bison, flex, gnome }:
+
+stdenv.mkDerivation rec {
+  pname = "gob2";
+  version = "2.0.20";
+
+  src = fetchurl {
+    url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
+    sha256 = "5fe5d7990fd65b0d4b617ba894408ebaa6df453f2781c15a1cfdf2956c0c5428";
+  };
+
+  # configure script looks for d-bus but it is only needed for tests
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ glib bison flex ];
+
+  passthru = {
+    updateScript = gnome.updateScript {
+      packageName = pname;
+      versionPolicy = "none";
+    };
+  };
+
+  meta = {
+    description = "Preprocessor for making GObjects with inline C code";
+    homepage = "https://www.jirka.org/gob.html";
+    license = lib.licenses.gpl2Plus;
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gperf/3.0.x.nix b/nixpkgs/pkgs/development/tools/misc/gperf/3.0.x.nix
new file mode 100644
index 000000000000..339511f2cc02
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gperf/3.0.x.nix
@@ -0,0 +1,35 @@
+{lib, stdenv, fetchurl, autoreconfHook }:
+
+stdenv.mkDerivation rec {
+  name = "gperf-3.0.4";
+
+  src = fetchurl {
+    url = "mirror://gnu/gperf/${name}.tar.gz";
+    sha256 = "0gnnm8iqcl52m8iha3sxrzrl9mcyhg7lfrhhqgdn4zj00ji14wbn";
+  };
+
+  nativeBuildInputs = [ autoreconfHook ];
+  patches = [ ./gperf-ar-fix.patch ];
+  meta = {
+    description = "Perfect hash function generator";
+
+    longDescription = ''
+      GNU gperf is a perfect hash function generator.  For a given
+      list of strings, it produces a hash function and hash table, in
+      form of C or C++ code, for looking up a value depending on the
+      input string.  The hash function is perfect, which means that
+      the hash table has no collisions, and the hash table lookup
+      needs a single string comparison only.
+
+      GNU gperf is highly customizable.  There are options for
+      generating C or C++ code, for emitting switch statements or
+      nested ifs instead of a hash table, and for tuning the algorithm
+      employed by gperf.
+    '';
+
+    license = lib.licenses.gpl3Plus;
+
+    homepage = "https://www.gnu.org/software/gperf/";
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gperf/default.nix b/nixpkgs/pkgs/development/tools/misc/gperf/default.nix
new file mode 100644
index 000000000000..e998f09683ae
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gperf/default.nix
@@ -0,0 +1,33 @@
+{lib, stdenv, fetchurl}:
+
+stdenv.mkDerivation rec {
+  name = "gperf-3.1";
+
+  src = fetchurl {
+    url = "mirror://gnu/gperf/${name}.tar.gz";
+    sha256 = "1qispg6i508rq8pkajh26cznwimbnj06wq9sd85vg95v8nwld1aq";
+  };
+
+  meta = {
+    description = "Perfect hash function generator";
+
+    longDescription = ''
+      GNU gperf is a perfect hash function generator.  For a given
+      list of strings, it produces a hash function and hash table, in
+      form of C or C++ code, for looking up a value depending on the
+      input string.  The hash function is perfect, which means that
+      the hash table has no collisions, and the hash table lookup
+      needs a single string comparison only.
+
+      GNU gperf is highly customizable.  There are options for
+      generating C or C++ code, for emitting switch statements or
+      nested ifs instead of a hash table, and for tuning the algorithm
+      employed by gperf.
+    '';
+
+    license = lib.licenses.gpl3Plus;
+
+    homepage = "https://www.gnu.org/software/gperf/";
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gperf/gperf-ar-fix.patch b/nixpkgs/pkgs/development/tools/misc/gperf/gperf-ar-fix.patch
new file mode 100644
index 000000000000..942d726d76ea
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gperf/gperf-ar-fix.patch
@@ -0,0 +1,46 @@
+--- gperf-3.0.4/lib/configure.ac	2009-01-15 02:24:31.000000000 +0200
++++ gperf-3.0.4.patched/lib/configure.ac	2018-11-29 06:37:20.968627533 +0300
+@@ -21,10 +21,12 @@
+ 
+ AC_PREREQ([2.60])
+ AC_INIT([hash.cc])
++m4_include([../aclocal.m4])
+ AC_PROG_MAKE_SET
+ dnl
+ dnl           checks for programs
+ dnl
++AC_SUBST([AR])
+ AC_PROG_CC
+                       dnl sets variable CC
+ AC_PROG_CPP
+--- gperf-3.0.4/lib/Makefile.in	2008-08-23 21:52:48.000000000 +0300
++++ gperf-3.0.4.patched/lib/Makefile.in	2018-11-29 06:36:43.161998888 +0300
+@@ -41,7 +41,7 @@
+ # Both C and C++ compiler
+ OBJEXT = @OBJEXT@
+ # Other
+-AR = ar
++AR = @AR@
+ AR_FLAGS = rc
+ RANLIB = @RANLIB@
+ MV = mv
+--- gperf-3.0.4/doc/configure.ac	2009-01-15 02:24:31.000000000 +0200
++++ gperf-3.0.4.patched/doc/configure.ac	2018-11-29 06:36:00.961288421 +0300
+@@ -21,6 +21,7 @@
+ 
+ AC_PREREQ([2.60])
+ AC_INIT([gperf.1])
++m4_include([../aclocal.m4])
+ PACKAGE=gperf
+ AC_SUBST([PACKAGE])
+ AC_PROG_MAKE_SET
+--- gperf-3.0.4/src/configure.ac	2009-01-15 02:24:30.000000000 +0200
++++ gperf-3.0.4.patched/src/configure.ac	2018-11-29 06:34:21.718576658 +0300
+@@ -21,6 +21,7 @@
+ 
+ AC_PREREQ([2.60])
+ AC_INIT([main.cc])
++m4_include([../aclocal.m4])
+ AC_CONFIG_HEADER([config.h])
+ AC_PROG_MAKE_SET
+ dnl
diff --git a/nixpkgs/pkgs/development/tools/misc/gpshell/default.nix b/nixpkgs/pkgs/development/tools/misc/gpshell/default.nix
new file mode 100644
index 000000000000..f5298d685eba
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gpshell/default.nix
@@ -0,0 +1,27 @@
+{ lib, stdenv, fetchurl, pkg-config, globalplatform, pcsclite, gppcscconnectionplugin
+, makeWrapper
+}:
+
+stdenv.mkDerivation rec {
+  pname = "gpshell";
+  version = "1.4.4";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/globalplatform/gpshell-${version}.tar.gz";
+    sha256 = "19a77zvyf2vazbv17185s4pynhylk2ky8vhl4i8pg9zww29sicqi";
+  };
+
+  nativeBuildInputs = [ pkg-config makeWrapper ];
+  buildInputs = [ globalplatform pcsclite ];
+
+  postFixup = ''
+    wrapProgram "$out/bin/gpshell" --prefix LD_LIBRARY_PATH : "${gppcscconnectionplugin}/lib"
+  '';
+
+  meta = with lib; {
+    homepage = "https://sourceforge.net/p/globalplatform/wiki/Home/";
+    description = "Smartcard management application";
+    license = licenses.gpl3;
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gputils/default.nix b/nixpkgs/pkgs/development/tools/misc/gputils/default.nix
new file mode 100644
index 000000000000..c07949e80968
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gputils/default.nix
@@ -0,0 +1,19 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  pname = "gputils";
+  version = "1.5.0-1";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/gputils/${pname}-${version}.tar.bz2";
+    sha256 = "055v83fdgqljprapf7rmh8x66mr13fj0qypj49xba5spx0ca123g";
+  };
+
+  meta = with lib; {
+    homepage = "https://gputils.sourceforge.io";
+    description = "A collection of tools for the Microchip (TM) PIC microcontrollers. It includes gpasm, gplink, and gplib";
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ yorickvp ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gpuvis/default.nix b/nixpkgs/pkgs/development/tools/misc/gpuvis/default.nix
new file mode 100644
index 000000000000..5e0f54b2feef
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gpuvis/default.nix
@@ -0,0 +1,42 @@
+{ fetchFromGitHub
+, freetype
+, gtk3
+, lib
+, meson
+, ninja
+, pkg-config
+, SDL2
+, stdenv
+, wrapGAppsHook
+}:
+
+stdenv.mkDerivation rec {
+  pname = "gpuvis";
+  version = "20210220";
+
+  src = fetchFromGitHub {
+    owner = "mikesart";
+    repo = pname;
+    rev = "216f7d810e182a89fd96ab9fad2a5c2b1e425ea9";
+    sha256 = "15pj7gy0irlp849a85z68n184jksjri0xhihgh56rs15kq333mwz";
+  };
+
+  # patch dlopen path for gtk3
+  # python2 is wrongly added in the meson file, upstream PR: https://github.com/mikesart/gpuvis/pull/62
+  postPatch = ''
+    substituteInPlace src/hook_gtk3.h \
+      --replace "libgtk-3.so" "${lib.getLib gtk3}/lib/libgtk-3.so"
+  '';
+
+  nativeBuildInputs = [ pkg-config meson ninja wrapGAppsHook ];
+
+  buildInputs = [ SDL2 gtk3 freetype ];
+
+  meta = with lib; {
+    description = "GPU Trace Visualizer";
+    homepage = "https://github.com/mikesart/gpuvis";
+    license = licenses.mit;
+    maintainers = with maintainers; [ emantor ];
+    platforms = with platforms; linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/grpc-tools/default.nix b/nixpkgs/pkgs/development/tools/misc/grpc-tools/default.nix
new file mode 100644
index 000000000000..3e06f10cbf1e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/grpc-tools/default.nix
@@ -0,0 +1,40 @@
+{ lib
+, stdenv
+, cmake
+, fetchFromGitHub
+}:
+
+stdenv.mkDerivation rec {
+  pname = "grpc-tools";
+  version = "1.10.0";
+
+  src = fetchFromGitHub {
+    owner = "grpc";
+    repo = "grpc-node";
+    rev = "3a094f01711942f79abd8a536c45a91b574d626f"; # version 1.10.0 was not tagged
+    sha256 = "1a7l91kxc3g7mqfqvhc3nb7zy0n21ifs5ck0qqg09qh3f44q04xm";
+    fetchSubmodules = true;
+  };
+
+  sourceRoot = "source/packages/grpc-tools";
+
+  nativeBuildInputs = [ cmake ];
+
+  installPhase = ''
+    install -Dm755 -t $out/bin grpc_node_plugin
+    install -Dm755 -t $out/bin deps/protobuf/protoc
+  '';
+
+  meta = with lib; {
+    description = "Distribution of protoc and the gRPC Node protoc plugin for ease of installation with npm";
+    longDescription = ''
+      This package distributes the Protocol Buffers compiler protoc along with
+      the plugin for generating client and service objects for use with the Node
+      gRPC libraries.
+    '';
+    homepage = "https://github.com/grpc/grpc-node/tree/master/packages/grpc-tools";
+    license = licenses.asl20;
+    platforms = platforms.all;
+    maintainers = [ maintainers.nzhang-zh ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gtkdialog/default.nix b/nixpkgs/pkgs/development/tools/misc/gtkdialog/default.nix
new file mode 100644
index 000000000000..6651bbb03845
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gtkdialog/default.nix
@@ -0,0 +1,21 @@
+{lib, stdenv, fetchurl, gtk2, pkg-config }:
+
+stdenv.mkDerivation {
+  name = "gtkdialog-0.8.3";
+
+  src = fetchurl {
+    url = "https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/gtkdialog/gtkdialog-0.8.3.tar.gz";
+    sha256 = "ff89d2d7f1e6488e5df5f895716ac1d4198c2467a2a5dc1f51ab408a2faec38e";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ gtk2 ];
+
+  meta = {
+    homepage = "https://code.google.com/archive/p/gtkdialog/";
+    # community links: http://murga-linux.com/puppy/viewtopic.php?t=111923 -> https://github.com/01micko/gtkdialog
+    description = "Small utility for fast and easy GUI building from many scripted and compiled languages";
+    license = lib.licenses.gpl2Plus;
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/gtkperf/bench.patch b/nixpkgs/pkgs/development/tools/misc/gtkperf/bench.patch
new file mode 100644
index 000000000000..3d00a03e9a58
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gtkperf/bench.patch
@@ -0,0 +1,60 @@
+--- gtkperf/src/callbacks.c	2005-10-30 11:33:42.000000000 +0000
++++ gtkperf-patched/src/callbacks.c	2008-05-23 23:41:17.000000000 +0100
+@@ -219,6 +219,13 @@
+ }
+
+
++void
++on_cmdline_test(char *optarg)
++{
++	appdata->test_type = atoi(optarg);
++}
++
++
+ /* Initialize appdata */
+ void
+ setup_appdata(AppData * appdata_in)
+@@ -398,7 +405,7 @@
+ 	appdata->pixbuf_drawing = gdk_pixbuf_new_from_file (filename, NULL);
+
+ 	gtk_combo_box_set_active (GTK_COMBO_BOX (appdata->combobox_testtype),
+-				  0);
++				  appdata->test_type);
+
+ 	/* create end mark to info textview */
+ 	GtkTextIter iter;
+--- gtkperf/src/callbacks.h	2005-10-30 10:21:23.000000000 +0000
++++ gtkperf-patched/src/callbacks.h	2008-05-23 23:22:30.000000000 +0100
+@@ -13,6 +13,7 @@
+ void on_cmdline_run_all ();
+ void on_cmdline_help () ;
+ void on_cmdline_count (char *optarg) ;
++void on_cmdline_test (char *optarg) ;
+ void on_window_main_show (AppData * data);
+
+ gboolean
+--- gtkperf/src/main.c	2005-10-30 11:26:42.000000000 +0000
++++ gtkperf-patched/src/main.c	2008-05-23 23:44:02.000000000 +0100
+@@ -65,9 +65,10 @@
+ 			{"help", 0, 0, 0},
+ 			{"automatic", 0, 0, 0},
+ 			{"count", 1, 0, 0},
++			{"test", 1, 0, 0},
+ 			{0, 0, 0, 0}
+ 		};
+-		c = getopt_long (argc, argv, "hac:",
++		c = getopt_long (argc, argv, "hac:t:",
+ 			long_options, &option_index);
+ 		if (c == -1)
+ 			break;
+@@ -104,6 +105,10 @@
+ 				on_cmdline_count(optarg);
+ 				break;
+
++			case 't':
++				on_cmdline_test(optarg);
++				break;
++
+ 			default:
+ 			case 'h':
+ 				on_cmdline_help ();
diff --git a/nixpkgs/pkgs/development/tools/misc/gtkperf/default.nix b/nixpkgs/pkgs/development/tools/misc/gtkperf/default.nix
new file mode 100644
index 000000000000..4b7f7985a673
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/gtkperf/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchurl, gtk2, pkg-config, libintl }:
+
+stdenv.mkDerivation {
+  name = "gtkperf-0.40.0";
+  src = fetchurl {
+    url = "mirror://sourceforge//gtkperf/gtkperf_0.40.tar.gz";
+    sha256 = "0yxj3ap3yfi76vqg6xjvgc16nfi9arm9kp87s35ywf10fd73814p";
+  };
+
+  hardeningDisable = [ "format" ];
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ gtk2 libintl ];
+
+  # https://openbenchmarking.org/innhold/7e9780c11550d09aa67bdba71248facbe2d781db
+  patches = [ ./bench.patch ];
+
+  meta = with lib; {
+    description = "Application designed to test GTK performance";
+    homepage = "http://gtkperf.sourceforge.net/";
+    license = with licenses; [ gpl2 ];
+    maintainers = with maintainers; [ dtzWill ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/help2man/1.40.4-cygwin-nls.patch b/nixpkgs/pkgs/development/tools/misc/help2man/1.40.4-cygwin-nls.patch
new file mode 100644
index 000000000000..82f8cf1cb37b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/help2man/1.40.4-cygwin-nls.patch
@@ -0,0 +1,165 @@
+LD_PRELOAD by itself only works with Cygwin builtin functions, but
+textdomain() and friends come from libintl.  In order to override
+those functions, we have to "replace" cygintl-?.dll since functions are
+bound to a DLL name at link time.  Our replacement will be used since
+it is loaded first by LD_PRELOAD.
+
+But as we are making this *the* libintl, we need to provide 
+pass-throughs for the other functions which we're not overriding,
+otherwise Locale::gettext won't load (not to mention the program
+that we're trying to help2man).
+
+--- help2man-1.46.5/Makefile.in	2014-10-09 13:03:01.000000000 +0200
++++ help2man-1.46.5/Makefile.in	2015-05-12 14:46:52.995521900 +0200
+@@ -76,7 +76,8 @@
+        fi
+
+ install_preload: install_dirs preload
+-	$(INSTALL_PROGRAM) $(preload).so $(DESTDIR)$(pkglibdir)
++	$(INSTALL_PROGRAM) lib/cygintl-9.dll $(DESTDIR)$(pkglibdir)
++	ln -sf cygintl-9.dll $(DESTDIR)$(pkglibdir)/$(preload).so
+
+ install_l10n: install_dirs msg_l10n man_l10n info_l10n
+        set -e; \
+@@ -144,7 +146,9 @@
+
+ preload: $(preload).so
+ $(preload).so: $(srcdir)/$(preload).c
+-	$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $@ -fPIC -shared $? $(LIBS)
++	mkdir -p lib
++	$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o lib/cygintl-9.dll -shared $? $(LIBS)
++	ln -sf lib/cygintl-9.dll $@
+
+ man: $(target).1
+ $(target).1: $(srcdir)/$(target).PL $(srcdir)/$(target).h2m.PL
+--- help2man-1.46.5/bindtextdomain.c	2009-11-13 00:01:34.000000000 -0600
++++ help2man-1.46.5/bindtextdomain.c	2011-12-29 00:24:33.608078600 -0600
+@@ -27,12 +27,34 @@ static char *(*r_textdomain)(char const
+ static char *(*r_bindtextdomain)(char const *, char const *) = 0;
+ static char *(*r_bind_textdomain_codeset)(char const *, char const *) = 0;
+ 
++#ifdef __CYGWIN__
++static void *RTLD_NEXT = 0;
++static char *(*r_gettext)(const char *) = 0;
++static char *(*r_dgettext)(const char *, const char *) = 0;
++static char *(*r_dcgettext)(const char *, const char *, int) = 0;
++static char *(*r_ngettext)(const char *, const char *, unsigned long int) = 0;
++static char *(*r_dngettext)(const char *, const char *, const char *,
++                            unsigned long int) = 0;
++static char *(*r_dcngettext)(const char *, const char *, const char *,
++                             unsigned long int, int) = 0;
++static char *(*r_setlocale)(int, const char *) = 0;
++
++#define SYM(sym) libintl_ ## sym
++#else
++#define SYM(sym) sym
++#endif
++
+ void setup()
+ {
+     static int done = 0;
+     if (done++)
+         return;
+ 
++#ifdef __CYGWIN__
++    if (!(RTLD_NEXT = dlopen("/usr/bin/cygintl-9.dll", RTLD_LAZY)))
++        die("libintl8 not found");
++#endif
++
+     if (!(e_textdomain = getenv("TEXTDOMAIN")))
+ 	die("TEXTDOMAIN not set");
+ 
+@@ -48,9 +70,19 @@ void setup()
+     if (!(r_bind_textdomain_codeset = dlsym(RTLD_NEXT,
+     					    "bind_textdomain_codeset")))
+ 	die("can't find symbol \"bind_textdomain_codeset\"");
++
++#ifdef __CYGWIN__
++    r_gettext = dlsym(RTLD_NEXT, "libintl_gettext");
++    r_dgettext = dlsym(RTLD_NEXT, "libintl_dgettext");
++    r_dcgettext = dlsym(RTLD_NEXT, "libintl_dcgettext");
++    r_ngettext = dlsym(RTLD_NEXT, "libintl_ngettext");
++    r_dngettext = dlsym(RTLD_NEXT, "libintl_dngettext");
++    r_dcngettext = dlsym(RTLD_NEXT, "libintl_dcngettext");
++    r_setlocale = dlsym(RTLD_NEXT, "libintl_setlocale");
++#endif
+ }
+ 
+-char *textdomain(char const *domainname)
++char *SYM(textdomain)(char const *domainname)
+ {
+     char *r;
+     setup();
+@@ -61,7 +93,7 @@ char *textdomain(char const *domainname)
+     return r;
+ }
+ 
+-char *bindtextdomain(char const *domainname, char const *dirname)
++char *SYM(bindtextdomain)(char const *domainname, char const *dirname)
+ {
+     char const *dir = dirname;
+     setup();
+@@ -71,7 +103,7 @@ char *bindtextdomain(char const *domainn
+     return r_bindtextdomain(domainname, dir);
+ }
+ 
+-char *bind_textdomain_codeset(char const *domainname, char const *codeset)
++char *SYM(bind_textdomain_codeset)(char const *domainname, char const *codeset)
+ {
+     char *r;
+     setup();
+@@ -81,3 +113,54 @@ char *bind_textdomain_codeset(char const
+ 
+     return r;
+ }
++
++#ifdef __CYGWIN__
++
++char *libintl_gettext(const char *msgid)
++{
++    setup();
++    return r_gettext(msgid);
++}
++
++char *libintl_dgettext (const char *domainname, const char *msgid)
++{
++    setup();
++    return r_dgettext(domainname, msgid);
++}
++
++char *libintl_dcgettext (const char *domainname, const char *msgid,
++                         int category)
++{
++    setup();
++    return r_dcgettext (domainname, msgid, category);
++}
++
++char *libintl_ngettext (const char *msgid1, const char *msgid2,
++                        unsigned long int n)
++{
++    setup();
++    return r_ngettext (msgid1, msgid2, n);
++}
++
++char *libintl_dngettext (const char *domainname, const char *msgid1,
++                         const char *msgid2, unsigned long int n)
++{
++    setup();
++    return r_dngettext (domainname, msgid1, msgid2, n);
++}
++
++char *libintl_dcngettext (const char *domainname,
++                          const char *msgid1, const char *msgid2,
++                          unsigned long int n, int category)
++{
++    setup();
++    return r_dcngettext (domainname, msgid1, msgid2, n, category);
++}
++
++char *libintl_setlocale (int i, const char *s)
++{
++    setup();
++    return r_setlocale (i, s);
++}
++
++#endif
diff --git a/nixpkgs/pkgs/development/tools/misc/help2man/default.nix b/nixpkgs/pkgs/development/tools/misc/help2man/default.nix
new file mode 100644
index 000000000000..4a205268c269
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/help2man/default.nix
@@ -0,0 +1,51 @@
+{ lib, stdenv, fetchurl, perlPackages, gettext }:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+stdenv.mkDerivation rec {
+  name = "help2man-1.48.1";
+
+  src = fetchurl {
+    url = "mirror://gnu/help2man/${name}.tar.xz";
+    sha256 = "sha256-3op0dAvQWGRlZ7kqtOzeudqfGgfMfE9gejwU3TjRB5k=";
+  };
+
+  nativeBuildInputs = [ gettext perlPackages.LocaleGettext ];
+  buildInputs = [ perlPackages.perl perlPackages.LocaleGettext ];
+
+  doCheck = false;                                # target `check' is missing
+
+  patches = if stdenv.hostPlatform.isCygwin then [ ./1.40.4-cygwin-nls.patch ] else null;
+
+  # We don't use makeWrapper here because it uses substitutions our
+  # bootstrap shell can't handle.
+  postInstall = ''
+    mv $out/bin/help2man $out/bin/.help2man-wrapped
+    cat > $out/bin/help2man <<EOF
+    #! $SHELL -e
+    export PERL5LIB=\''${PERL5LIB:+:}${perlPackages.LocaleGettext}/${perlPackages.perl.libPrefix}
+    ${lib.optionalString stdenv.hostPlatform.isCygwin
+        ''export PATH=\''${PATH:+:}${gettext}/bin''}
+    exec -a \$0 $out/bin/.help2man-wrapped "\$@"
+    EOF
+    chmod +x $out/bin/help2man
+  '';
+
+  meta = with lib; {
+    description = "Generate man pages from `--help' output";
+
+    longDescription =
+      '' help2man produces simple manual pages from the ‘--help’ and
+         ‘--version’ output of other commands.
+      '';
+
+    homepage = "https://www.gnu.org/software/help2man/";
+
+    license = licenses.gpl3Plus;
+    platforms = platforms.all;
+    maintainers = with maintainers; [ pSub ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/hound/default.nix b/nixpkgs/pkgs/development/tools/misc/hound/default.nix
new file mode 100644
index 000000000000..e5bf07089861
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/hound/default.nix
@@ -0,0 +1,38 @@
+{ lib
+, buildGoModule
+, fetchFromGitHub
+, makeWrapper
+, mercurial
+, git
+}:
+
+buildGoModule rec {
+  pname = "hound";
+  version = "0.4.0";
+
+  src = fetchFromGitHub {
+    owner = "hound-search";
+    repo = "hound";
+    rev = "v${version}";
+    sha256 = "0p5w54fr5xz19ff8k5xkyq3iqhjki8wc0hj2x1pnmk6hzrz6hf65";
+  };
+
+  vendorSha256 = "0x1nhhhvqmz3qssd2d44zaxbahj8lh9r4m5jxdvzqk6m3ly7y0b6";
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  # requires network access
+  doCheck = false;
+
+  postInstall = ''
+    wrapProgram $out/bin/houndd --prefix PATH : ${lib.makeBinPath [ mercurial git ]}
+  '';
+
+  meta = with lib; {
+    inherit (src.meta) homepage;
+    description = "Lightning fast code searching made easy";
+    license = licenses.mit;
+    maintainers = with maintainers; [ grahamc SuperSandro2000 ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/hydra-cli/default.nix b/nixpkgs/pkgs/development/tools/misc/hydra-cli/default.nix
new file mode 100644
index 000000000000..1332885bbdbe
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/hydra-cli/default.nix
@@ -0,0 +1,29 @@
+{ stdenv, lib, pkg-config, openssl, fetchFromGitHub, rustPlatform, darwin }:
+
+rustPlatform.buildRustPackage rec {
+  pname = "hydra-cli";
+  version = "0.3.0";
+
+  src = fetchFromGitHub {
+    owner = "nlewo";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "1fd3swdjx249971ak1bgndm5kh6rlzbfywmydn122lhfi6ry6a03";
+  };
+  cargoSha256 = "16446ppkvc6l8087x5m5kyy5gk4f7inyj7rzrfysriw4fvqxjsf3";
+
+  buildInputs = [ openssl ]
+                ++ lib.optionals stdenv.isDarwin [ darwin.apple_sdk.frameworks.Security ];
+
+  nativeBuildInputs = [
+    pkg-config
+  ];
+
+  meta = with lib; {
+    description = "A client for the Hydra CI";
+    homepage = "https://github.com/nlewo/hydra-cli";
+    license = with licenses; [ mit ];
+    maintainers = with maintainers; [ gilligan lewo ];
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/hydra/common.nix b/nixpkgs/pkgs/development/tools/misc/hydra/common.nix
new file mode 100644
index 000000000000..5b1973c2b9e0
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/hydra/common.nix
@@ -0,0 +1,140 @@
+{ stdenv, nix, perlPackages, buildEnv
+, makeWrapper, autoconf, automake, libtool, unzip, pkg-config, sqlite, libpqxx_6
+, top-git, mercurial, darcs, subversion, breezy, openssl, bzip2, libxslt
+, perl, postgresql, nukeReferences, git, boehmgc, nlohmann_json
+, docbook_xsl, openssh, gnused, coreutils, findutils, gzip, xz, gnutar
+, rpm, dpkg, cdrkit, pixz, lib, boost, autoreconfHook, src ? null, version ? null
+, migration ? false, patches ? []
+, tests ? {}, mdbook
+}:
+
+with stdenv;
+
+if lib.versions.major nix.version == "1"
+  then throw "This Hydra version doesn't support Nix 1.x"
+else
+
+let
+  perlDeps = buildEnv {
+    name = "hydra-perl-deps";
+    paths = with perlPackages; lib.closePropagation
+      [ ModulePluggable
+        CatalystActionREST
+        CatalystAuthenticationStoreDBIxClass
+        CatalystDevel
+        CatalystDispatchTypeRegex
+        CatalystPluginAccessLog
+        CatalystPluginAuthorizationRoles
+        CatalystPluginCaptcha
+        CatalystPluginSessionStateCookie
+        CatalystPluginSessionStoreFastMmap
+        CatalystPluginSmartURI
+        CatalystPluginStackTrace
+        CatalystRuntime
+        CatalystTraitForRequestProxyBase
+        CatalystViewDownload
+        CatalystViewJSON
+        CatalystViewTT
+        CatalystXScriptServerStarman
+        CatalystXRoleApplicator
+        CryptPassphrase
+        CryptPassphraseArgon2
+        CryptRandPasswd
+        DBDPg
+        DBDSQLite
+        DataDump
+        DateTime
+        DigestSHA1
+        EmailMIME
+        EmailSender
+        FileSlurp
+        IOCompress
+        IPCRun
+        JSON
+        JSONAny
+        JSONXS
+        LWP
+        LWPProtocolHttps
+        NetAmazonS3
+        NetPrometheus
+        NetStatsd
+        PadWalker
+        Readonly
+        SQLSplitStatement
+        SetScalar
+        Starman
+        StringCompareConstantTime
+        SysHostnameLong
+        TermSizeAny
+        TextDiff
+        TextTable
+        XMLSimple
+        YAML
+        nix
+        nix.perl-bindings
+        git
+        boehmgc
+      ];
+  };
+in stdenv.mkDerivation rec {
+  pname = "hydra";
+
+  inherit stdenv src version patches;
+
+  buildInputs =
+    [ makeWrapper autoconf automake libtool unzip nukeReferences sqlite libpqxx_6
+      top-git mercurial /*darcs*/ subversion breezy openssl bzip2 libxslt
+      perlDeps perl nix
+      postgresql # for running the tests
+      nlohmann_json
+      boost
+    ];
+
+  hydraPath = lib.makeBinPath (
+    [ sqlite subversion openssh nix coreutils findutils pixz
+      gzip bzip2 xz gnutar unzip git top-git mercurial /*darcs*/ gnused breezy
+    ] ++ lib.optionals stdenv.isLinux [ rpm dpkg cdrkit ] );
+
+  nativeBuildInputs = [ autoreconfHook pkg-config mdbook ];
+
+  configureFlags = [ "--with-docbook-xsl=${docbook_xsl}/xml/xsl/docbook" ];
+
+  NIX_CFLAGS_COMPILE = "-pthread";
+
+  shellHook = ''
+    PATH=$(pwd)/src/script:$(pwd)/src/hydra-eval-jobs:$(pwd)/src/hydra-queue-runner:$(pwd)/src/hydra-evaluator:$PATH
+    PERL5LIB=$(pwd)/src/lib:$PERL5LIB;
+  '';
+
+  enableParallelBuilding = true;
+
+  preCheck = ''
+    patchShebangs .
+    export LOGNAME=''${LOGNAME:-foo}
+  '';
+
+  postInstall = ''
+    mkdir -p $out/nix-support
+    for i in $out/bin/*; do
+        read -n 4 chars < $i
+        if [[ $chars =~ ELF ]]; then continue; fi
+        wrapProgram $i \
+            --prefix PERL5LIB ':' $out/libexec/hydra/lib:$PERL5LIB \
+            --prefix PATH ':' $out/bin:$hydraPath \
+            --set HYDRA_RELEASE ${version} \
+            --set HYDRA_HOME $out/libexec/hydra \
+            --set NIX_RELEASE ${nix.name or "unknown"}
+    done
+  ''; # */
+
+  dontStrip = true;
+
+  passthru = { inherit perlDeps migration tests; };
+
+  meta = with lib; {
+    description = "Nix-based continuous build system";
+    license = licenses.gpl3;
+    platforms = platforms.linux;
+    maintainers = with maintainers; [ ma27 ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/hydra/default.nix b/nixpkgs/pkgs/development/tools/misc/hydra/default.nix
new file mode 100644
index 000000000000..a124b4a5c6e2
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/hydra/default.nix
@@ -0,0 +1,18 @@
+{ fetchFromGitHub, nixStable, callPackage, nixUnstable, nixosTests }:
+
+{
+  hydra-unstable = callPackage ./common.nix {
+    version = "2021-05-03";
+    src = fetchFromGitHub {
+      owner = "NixOS";
+      repo = "hydra";
+      rev = "886e6f85e45a1f757e9b77d2a9e4539fbde29468";
+      sha256 = "t7Qb57Xjc0Ou+VDGC1N5u9AmeODW6MVOwKSrYRJq5f0=";
+    };
+    nix = nixUnstable;
+
+    tests = {
+      basic = nixosTests.hydra.hydra-unstable;
+    };
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/icon-naming-utils/default.nix b/nixpkgs/pkgs/development/tools/misc/icon-naming-utils/default.nix
new file mode 100644
index 000000000000..478c0a61f865
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/icon-naming-utils/default.nix
@@ -0,0 +1,18 @@
+{lib, stdenv, fetchurl, perl, librsvg}:
+
+stdenv.mkDerivation rec {
+  name = "icon-naming-utils-0.8.90";
+
+  src = fetchurl {
+    url = "http://tango.freedesktop.org/releases/${name}.tar.gz";
+    sha256 = "071fj2jm5kydlz02ic5sylhmw6h2p3cgrm3gwdfabinqkqcv4jh4";
+  };
+
+  buildInputs = [ librsvg (perl.withPackages (p: [ p.XMLSimple ])) ];
+
+  meta = with lib; {
+    homepage = "http://tango.freedesktop.org/Standard_Icon_Naming_Specification";
+    platforms = with platforms; linux ++ darwin;
+    license = licenses.gpl2;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/igprof/default.nix b/nixpkgs/pkgs/development/tools/misc/igprof/default.nix
new file mode 100644
index 000000000000..47f41f130bef
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/igprof/default.nix
@@ -0,0 +1,43 @@
+{lib, stdenv, fetchFromGitHub, libunwind, cmake, pcre, gdb}:
+
+stdenv.mkDerivation rec {
+  version = "5.9.16";
+  pname = "igprof";
+
+  src = fetchFromGitHub {
+    owner = "igprof";
+    repo = "igprof";
+    rev = "v${version}";
+    sha256 = "0rx3mv8zdh9bmcpfbzkib3d52skzfr8600gh5gv21wcsh50jnifx";
+  };
+
+  postPatch = ''
+    substituteInPlace src/igprof --replace libigprof.so $out/lib/libigprof.so
+    '';
+
+  buildInputs = [libunwind gdb pcre];
+  nativeBuildInputs = [cmake];
+  CXXFLAGS = ["-fPIC" "-O2" "-w" "-fpermissive"];
+
+  meta = {
+    description = "The Ignominous Profiler";
+
+    longDescription = ''
+      IgProf is a fast and light weight profiler. It correctly handles
+      dynamically loaded shared libraries, threads and sub-processes started by
+      the application.  We have used it routinely with large C++ applications
+      consisting of many hundreds of shared libraries and thousands of symbols
+      from millions of source lines of code. It requires no special privileges
+      to run. The performance reports provide full navigable call stacks and
+      can be customised by applying filters. Results from any number of
+      profiling runs can be included. This means you can both dig into the
+      details and see the big picture from combined workloads.
+    '';
+
+    license = lib.licenses.gpl2;
+
+    homepage = "https://igprof.org/";
+    platforms = lib.platforms.linux;
+    maintainers = with lib.maintainers; [ ktf ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/indent/darwin.patch b/nixpkgs/pkgs/development/tools/misc/indent/darwin.patch
new file mode 100644
index 000000000000..5458a0d93bff
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/indent/darwin.patch
@@ -0,0 +1,15 @@
+diff --git a/config.h.in b/config.h.in
+index 07e6fce..0c57e2a 100644
+--- a/config.h.in
++++ b/config.h.in
+@@ -432,8 +432,8 @@
+ # endif
+ # define _GL_EXTERN_INLINE extern
+ #else
+-# define _GL_INLINE static _GL_UNUSED
+-# define _GL_EXTERN_INLINE static _GL_UNUSED
++# define _GL_INLINE static
++# define _GL_EXTERN_INLINE static
+ #endif
+ 
+ #if 4 < __GNUC__ + (6 <= __GNUC_MINOR__)
diff --git a/nixpkgs/pkgs/development/tools/misc/indent/default.nix b/nixpkgs/pkgs/development/tools/misc/indent/default.nix
new file mode 100644
index 000000000000..8c5ec6af1c7f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/indent/default.nix
@@ -0,0 +1,27 @@
+{ lib, stdenv, fetchurl, texinfo }:
+
+stdenv.mkDerivation rec {
+  name = "indent-2.2.12";
+
+  src = fetchurl {
+    url = "mirror://gnu/indent/${name}.tar.gz";
+    sha256 = "12xvcd16cwilzglv9h7sgh4h1qqjd1h8s48ji2dla58m4706hzg7";
+  };
+
+  patches = [ ./darwin.patch ];
+
+  buildInputs = [ texinfo ];
+
+  NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang
+    "-Wno-implicit-function-declaration";
+
+  hardeningDisable = [ "format" ];
+
+  meta = {
+    homepage = "https://www.gnu.org/software/indent/";
+    description = "A source code reformatter";
+    license = lib.licenses.gpl3Plus;
+    maintainers = [ lib.maintainers.mmahut ];
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/inotify-tools/default.nix b/nixpkgs/pkgs/development/tools/misc/inotify-tools/default.nix
new file mode 100644
index 000000000000..48e2139b74dc
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/inotify-tools/default.nix
@@ -0,0 +1,22 @@
+{ lib, stdenv, autoreconfHook, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  pname = "inotify-tools";
+  version = "3.20.11.0";
+
+  src = fetchFromGitHub {
+    repo = "inotify-tools";
+    owner = "rvoicilas";
+    rev = version;
+    sha256 = "1m8avqccrhm38krlhp88a7v949f3hrzx060bbrr5dp5qw2nmw9j2";
+  };
+
+  nativeBuildInputs = [ autoreconfHook ];
+
+  meta = with lib; {
+    homepage = "https://github.com/rvoicilas/inotify-tools/wiki";
+    license = licenses.gpl2Plus;
+    maintainers = with maintainers; [ marcweber pSub shamilton ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/intel-gpu-tools/default.nix b/nixpkgs/pkgs/development/tools/misc/intel-gpu-tools/default.nix
new file mode 100644
index 000000000000..62d350593b16
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/intel-gpu-tools/default.nix
@@ -0,0 +1,43 @@
+{ lib, stdenv, fetchurl, pkg-config, libdrm, libpciaccess, cairo, xorgproto, udev
+, libX11, libXext, libXv, libXrandr, glib, bison, libunwind, python3, kmod
+, procps, utilmacros, gtk-doc, openssl, peg, elfutils
+}:
+
+stdenv.mkDerivation rec {
+  pname = "intel-gpu-tools";
+  version = "1.25";
+
+  src = fetchurl {
+    url = "https://xorg.freedesktop.org/archive/individual/app/igt-gpu-tools-${version}.tar.xz";
+    sha256 = "04fx7xclhick3k7fyk9c4mn8mxzf1253j1r0hrvj9sl40j7lsia0";
+  };
+
+  nativeBuildInputs = [ pkg-config utilmacros ];
+  buildInputs = [ libdrm libpciaccess cairo xorgproto udev libX11 kmod
+    libXext libXv libXrandr glib bison libunwind python3 procps
+    gtk-doc openssl peg elfutils ];
+
+  NIX_CFLAGS_COMPILE = [ "-Wno-error=array-bounds" ];
+
+  preConfigure = ''
+    ./autogen.sh
+  '';
+
+  preBuild = ''
+    patchShebangs tests
+
+    patchShebangs debugger/system_routine/pre_cpp.py
+    substituteInPlace tools/Makefile.am --replace '$(CAIRO_CFLAGS)' '$(CAIRO_CFLAGS) $(GLIB_CFLAGS)'
+    substituteInPlace tests/Makefile.am --replace '$(CAIRO_CFLAGS)' '$(CAIRO_CFLAGS) $(GLIB_CFLAGS)'
+  '';
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    homepage = "https://01.org/linuxgraphics/";
+    description = "Tools for development and testing of the Intel DRM driver";
+    license = licenses.mit;
+    platforms = [ "x86_64-linux" "i686-linux" ];
+    maintainers = with maintainers; [ pSub ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/intltool/default.nix b/nixpkgs/pkgs/development/tools/misc/intltool/default.nix
new file mode 100644
index 000000000000..967fc442a73d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/intltool/default.nix
@@ -0,0 +1,37 @@
+{ lib, stdenv, fetchurl, fetchpatch, gettext, perlPackages, buildPackages }:
+
+stdenv.mkDerivation rec {
+  pname = "intltool";
+  version = "0.51.0";
+
+  src = fetchurl {
+    url = "https://launchpad.net/intltool/trunk/${version}/+download/${pname}-${version}.tar.gz";
+    sha256 = "1karx4sb7bnm2j67q0q74hspkfn6lqprpy5r99vkn5bb36a4viv7";
+  };
+
+  # fix "unescaped left brace" errors when using intltool in some cases
+  patches = [(fetchpatch {
+    name = "perl5.26-regex-fixes.patch";
+    urls = [
+      "https://sources.debian.org/data/main/i/intltool/0.51.0-5/debian/patches/perl5.26-regex-fixes.patch"
+      "https://src.fedoraproject.org/rpms/intltool/raw/d8d2ef29fb122a42a6b6678eb1ec97ae56902af2/f/intltool-perl5.26-regex-fixes.patch"
+    ];
+    sha256 = "12q2140867r5d0dysly72khi7b0mm2gd7nlm1k81iyg7fxgnyz45";
+  })];
+
+  nativeBuildInputs = with perlPackages; [ perl XMLParser ];
+  propagatedBuildInputs = [ gettext ] ++ (with perlPackages; [ perl XMLParser ]);
+
+  postInstall = lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) ''
+    for f in $out/bin/*; do
+      substituteInPlace $f --replace "${buildPackages.perl}" "${perlPackages.perl}"
+    done
+  '';
+  meta = with lib; {
+    description = "Translation helper tool";
+    homepage = "https://launchpad.net/intltool/";
+    license = licenses.gpl2Plus;
+    maintainers = with maintainers; [ raskin ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/iozone/default.nix b/nixpkgs/pkgs/development/tools/misc/iozone/default.nix
new file mode 100644
index 000000000000..ad62d1048732
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/iozone/default.nix
@@ -0,0 +1,62 @@
+{ stdenv, lib, fetchurl, gnuplot }:
+
+let
+  target = if stdenv.hostPlatform.system == "i686-linux" then
+    "linux"
+  else if stdenv.hostPlatform.system == "x86_64-linux" then
+    "linux-AMD64"
+  else if stdenv.hostPlatform.system == "x86_64-darwin" then
+    "macosx"
+  else if stdenv.hostPlatform.system == "aarch64-linux" then
+    "linux-arm"
+  else throw "Platform ${stdenv.hostPlatform.system} not yet supported.";
+in
+
+stdenv.mkDerivation rec {
+  pname = "iozone";
+  version = "3.490";
+
+  src = fetchurl {
+    url = "http://www.iozone.org/src/current/iozone${lib.replaceStrings ["."] ["_"] version}.tar";
+    sha256 = "1vagmm2k2bzlpahl2a2arpfmk3cd5nzhxi842a8mdag2b8iv9bay";
+  };
+
+  license = fetchurl {
+    url = "http://www.iozone.org/docs/Iozone_License.txt";
+    sha256 = "1309sl1rqm8p9gll3z8zfygr2pmbcvzw5byf5ba8y12avk735zrv";
+  };
+
+  preBuild = "pushd src/current";
+  postBuild = "popd";
+
+  buildFlags = target;
+
+  enableParallelBuilding = true;
+
+  installPhase = ''
+    mkdir -p $out/{bin,share/doc,libexec,share/man/man1}
+    install docs/iozone.1 $out/share/man/man1/
+    install docs/Iozone_ps.gz $out/share/doc/
+    install -s src/current/{iozone,fileop,pit_server} $out/bin/
+    install src/current/{gnu3d.dem,Generate_Graphs,gengnuplot.sh} $out/libexec/
+    ln -s $out/libexec/Generate_Graphs $out/bin/iozone_generate_graphs
+    # License copy is mandated by the license, but it's not in the tarball.
+    install ${license} $out/share/doc/Iozone_License.txt
+  '';
+
+  preFixup = ''
+    sed -i "1i#! $shell" $out/libexec/Generate_Graphs
+    substituteInPlace $out/libexec/Generate_Graphs \
+      --replace ./gengnuplot.sh $out/libexec/gengnuplot.sh \
+      --replace 'gnuplot ' "${gnuplot}/bin/gnuplot " \
+      --replace gnu3d.dem $out/libexec/gnu3d.dem
+  '';
+
+  meta = {
+    description = "IOzone Filesystem Benchmark";
+    homepage    = "http://www.iozone.org/";
+    license     = lib.licenses.unfreeRedistributable;
+    platforms   = ["i686-linux" "x86_64-linux" "x86_64-darwin" "aarch64-linux" ];
+    maintainers = with lib.maintainers; [ Baughn makefu ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/itm-tools/cargo-lock.patch b/nixpkgs/pkgs/development/tools/misc/itm-tools/cargo-lock.patch
new file mode 100644
index 000000000000..1559510cd9f1
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/itm-tools/cargo-lock.patch
@@ -0,0 +1,321 @@
+diff --git a/Cargo.lock b/Cargo.lock
+new file mode 100644
+index 0000000..d9d39e5
+--- /dev/null
++++ b/Cargo.lock
+@@ -0,0 +1,315 @@
++# This file is automatically @generated by Cargo.
++# It is not intended for manual editing.
++[[package]]
++name = "addr2line"
++version = "0.12.2"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "602d785912f476e480434627e8732e6766b760c045bbf897d9dfaa9f4fbd399c"
++dependencies = [
++ "gimli",
++]
++
++[[package]]
++name = "adler32"
++version = "1.1.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "567b077b825e468cc974f0020d4082ee6e03132512f207ef1a02fd5d00d1f32d"
++
++[[package]]
++name = "ansi_term"
++version = "0.11.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "ee49baf6cb617b853aa8d93bf420db2383fab46d314482ca2803b40d5fde979b"
++dependencies = [
++ "winapi",
++]
++
++[[package]]
++name = "atty"
++version = "0.2.14"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8"
++dependencies = [
++ "hermit-abi",
++ "libc",
++ "winapi",
++]
++
++[[package]]
++name = "backtrace"
++version = "0.3.49"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "05100821de9e028f12ae3d189176b41ee198341eb8f369956407fea2f5cc666c"
++dependencies = [
++ "addr2line",
++ "cfg-if",
++ "libc",
++ "miniz_oxide",
++ "object",
++ "rustc-demangle",
++]
++
++[[package]]
++name = "bitflags"
++version = "1.2.1"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "cf1de2fe8c75bc145a2f577add951f8134889b4795d47466a54a5c846d691693"
++
++[[package]]
++name = "byteorder"
++version = "1.3.4"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "08c48aae112d48ed9f069b33538ea9e3e90aa263cfa3d1c24309612b1f7472de"
++
++[[package]]
++name = "cfg-if"
++version = "0.1.10"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822"
++
++[[package]]
++name = "clap"
++version = "2.33.1"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "bdfa80d47f954d53a35a64987ca1422f495b8d6483c0fe9f7117b36c2a792129"
++dependencies = [
++ "ansi_term",
++ "atty",
++ "bitflags",
++ "strsim",
++ "textwrap",
++ "unicode-width",
++ "vec_map",
++]
++
++[[package]]
++name = "either"
++version = "1.5.3"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "bb1f6b1ce1c140482ea30ddd3335fc0024ac7ee112895426e0a629a6c20adfe3"
++
++[[package]]
++name = "exitfailure"
++version = "0.5.1"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "2ff5bd832af37f366c6c194d813a11cd90ac484f124f079294f28e357ae40515"
++dependencies = [
++ "failure",
++]
++
++[[package]]
++name = "failure"
++version = "0.1.8"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "d32e9bd16cc02eae7db7ef620b392808b89f6a5e16bb3497d159c6b92a0f4f86"
++dependencies = [
++ "backtrace",
++ "failure_derive",
++]
++
++[[package]]
++name = "failure_derive"
++version = "0.1.8"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "aa4da3c766cd7a0db8242e326e9e4e081edd567072893ed320008189715366a4"
++dependencies = [
++ "proc-macro2",
++ "quote",
++ "syn",
++ "synstructure",
++]
++
++[[package]]
++name = "gimli"
++version = "0.21.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "bcc8e0c9bce37868955864dbecd2b1ab2bdf967e6f28066d65aaac620444b65c"
++
++[[package]]
++name = "hermit-abi"
++version = "0.1.15"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "3deed196b6e7f9e44a2ae8d94225d80302d81208b1bb673fd21fe634645c85a9"
++dependencies = [
++ "libc",
++]
++
++[[package]]
++name = "itm"
++version = "0.4.0"
++source = "git+https://github.com/rust-embedded/itm#5dd476d03de0738062a876fd3845900ab04833a4"
++dependencies = [
++ "byteorder",
++ "either",
++ "thiserror",
++]
++
++[[package]]
++name = "itm-tools"
++version = "0.1.0"
++dependencies = [
++ "clap",
++ "exitfailure",
++ "failure",
++ "itm",
++ "rustc-demangle",
++ "xmas-elf",
++]
++
++[[package]]
++name = "libc"
++version = "0.2.71"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "9457b06509d27052635f90d6466700c65095fdf75409b3fbdd903e988b886f49"
++
++[[package]]
++name = "miniz_oxide"
++version = "0.3.7"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "791daaae1ed6889560f8c4359194f56648355540573244a5448a83ba1ecc7435"
++dependencies = [
++ "adler32",
++]
++
++[[package]]
++name = "object"
++version = "0.20.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "1ab52be62400ca80aa00285d25253d7f7c437b7375c4de678f5405d3afe82ca5"
++
++[[package]]
++name = "proc-macro2"
++version = "1.0.18"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "beae6331a816b1f65d04c45b078fd8e6c93e8071771f41b8163255bbd8d7c8fa"
++dependencies = [
++ "unicode-xid",
++]
++
++[[package]]
++name = "quote"
++version = "1.0.7"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "aa563d17ecb180e500da1cfd2b028310ac758de548efdd203e18f283af693f37"
++dependencies = [
++ "proc-macro2",
++]
++
++[[package]]
++name = "rustc-demangle"
++version = "0.1.16"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "4c691c0e608126e00913e33f0ccf3727d5fc84573623b8d65b2df340b5201783"
++
++[[package]]
++name = "strsim"
++version = "0.8.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a"
++
++[[package]]
++name = "syn"
++version = "1.0.33"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "e8d5d96e8cbb005d6959f119f773bfaebb5684296108fb32600c00cde305b2cd"
++dependencies = [
++ "proc-macro2",
++ "quote",
++ "unicode-xid",
++]
++
++[[package]]
++name = "synstructure"
++version = "0.12.4"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "b834f2d66f734cb897113e34aaff2f1ab4719ca946f9a7358dba8f8064148701"
++dependencies = [
++ "proc-macro2",
++ "quote",
++ "syn",
++ "unicode-xid",
++]
++
++[[package]]
++name = "textwrap"
++version = "0.11.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060"
++dependencies = [
++ "unicode-width",
++]
++
++[[package]]
++name = "thiserror"
++version = "1.0.20"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "7dfdd070ccd8ccb78f4ad66bf1982dc37f620ef696c6b5028fe2ed83dd3d0d08"
++dependencies = [
++ "thiserror-impl",
++]
++
++[[package]]
++name = "thiserror-impl"
++version = "1.0.20"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "bd80fc12f73063ac132ac92aceea36734f04a1d93c1240c6944e23a3b8841793"
++dependencies = [
++ "proc-macro2",
++ "quote",
++ "syn",
++]
++
++[[package]]
++name = "unicode-width"
++version = "0.1.8"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "9337591893a19b88d8d87f2cec1e73fad5cdfd10e5a6f349f498ad6ea2ffb1e3"
++
++[[package]]
++name = "unicode-xid"
++version = "0.2.1"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "f7fe0bb3479651439c9112f72b6c505038574c9fbb575ed1bf3b797fa39dd564"
++
++[[package]]
++name = "vec_map"
++version = "0.8.2"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "f1bddf1187be692e79c5ffeab891132dfb0f236ed36a43c7ed39f1165ee20191"
++
++[[package]]
++name = "winapi"
++version = "0.3.9"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419"
++dependencies = [
++ "winapi-i686-pc-windows-gnu",
++ "winapi-x86_64-pc-windows-gnu",
++]
++
++[[package]]
++name = "winapi-i686-pc-windows-gnu"
++version = "0.4.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"
++
++[[package]]
++name = "winapi-x86_64-pc-windows-gnu"
++version = "0.4.0"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
++
++[[package]]
++name = "xmas-elf"
++version = "0.6.2"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "22678df5df766e8d1e5d609da69f0c3132d794edf6ab5e75e7abcd2270d4cf58"
++dependencies = [
++ "zero",
++]
++
++[[package]]
++name = "zero"
++version = "0.1.2"
++source = "registry+https://github.com/rust-lang/crates.io-index"
++checksum = "5f1bc8a6b2005884962297587045002d8cfb8dcec9db332f4ca216ddc5de82c5"
diff --git a/nixpkgs/pkgs/development/tools/misc/itm-tools/default.nix b/nixpkgs/pkgs/development/tools/misc/itm-tools/default.nix
new file mode 100644
index 000000000000..0abdd0179013
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/itm-tools/default.nix
@@ -0,0 +1,28 @@
+{ lib, fetchFromGitHub, rustPlatform, pkg-config }:
+
+rustPlatform.buildRustPackage rec {
+  pname = "itm-tools";
+  version = "unstable-2019-11-15";
+
+  src = fetchFromGitHub {
+    owner = "japaric";
+    repo = pname;
+    rev = "e94155e44019d893ac8e6dab51cc282d344ab700";
+    sha256 = "19xkjym0i7y52cfhvis49c59nzvgw4906cd8bkz8ka38mbgfqgiy";
+  };
+
+  cargoPatches = [ ./cargo-lock.patch ];
+
+  cargoSha256 = "1hqv530x8k4rf9zzyl5p5z58bymk1p4qwrcxs21gr0zm2hqjlxy4";
+
+  nativeBuildInputs = [ pkg-config ];
+
+  doCheck = false;
+
+  meta = with lib; {
+    description = "Tools for analyzing ITM traces";
+    homepage = "https://github.com/japaric/itm-tools";
+    license = with licenses; [ asl20 mit ];
+    maintainers = with maintainers; [ hh sb0 ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/itstool/default.nix b/nixpkgs/pkgs/development/tools/misc/itstool/default.nix
new file mode 100644
index 000000000000..55e62a2dcaee
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/itstool/default.nix
@@ -0,0 +1,26 @@
+{ stdenv, lib, fetchurl, python3 }:
+
+stdenv.mkDerivation rec {
+  name = "itstool-2.0.6";
+
+  src = fetchurl {
+    url = "http://files.itstool.org/itstool/${name}.tar.bz2";
+    sha256 = "1acjgf8zlyk7qckdk19iqaca4jcmywd7vxjbcs1mm6kaf8icqcv2";
+  };
+
+  pythonPath = [ python3.pkgs.libxml2 ];
+  buildInputs = [ python3 python3.pkgs.libxml2 ];
+  nativeBuildInputs = [ python3.pkgs.wrapPython ];
+
+  postFixup = ''
+    wrapPythonPrograms
+  '';
+
+  meta = {
+    homepage = "http://itstool.org/";
+    description = "XML to PO and back again";
+    license = lib.licenses.gpl3Plus;
+    platforms = lib.platforms.all;
+    maintainers = [ ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/jiq/default.nix b/nixpkgs/pkgs/development/tools/misc/jiq/default.nix
new file mode 100644
index 000000000000..c52a9ae4c030
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/jiq/default.nix
@@ -0,0 +1,31 @@
+{ lib, buildGoModule, fetchFromGitHub, jq, makeWrapper }:
+
+buildGoModule rec {
+  pname = "jiq";
+  version = "0.7.1";
+
+  src = fetchFromGitHub {
+    owner = "fiatjaf";
+    repo = pname;
+    rev = version;
+    sha256 = "sha256-EPhnfgmn0AufuxwcwRrEEQk+RD97akFJSzngkTl4LmY=";
+  };
+
+  vendorSha256 = "sha256-ZUmOhPGy+24AuxdeRVF0Vnu8zDGFrHoUlYiDdfIV5lc=";
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  checkInputs = [ jq ];
+
+  postInstall = ''
+    wrapProgram $out/bin/jiq \
+      --prefix PATH : ${lib.makeBinPath [ jq ]}
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/fiatjaf/jiq";
+    license = licenses.mit;
+    description = "jid on jq - interactive JSON query tool using jq expressions";
+    maintainers = with maintainers; [ ma27 ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/jscoverage/default.nix b/nixpkgs/pkgs/development/tools/misc/jscoverage/default.nix
new file mode 100644
index 000000000000..dbcb8d52f1b7
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/jscoverage/default.nix
@@ -0,0 +1,54 @@
+{ autoconf, fetchurl, makedepend, perl, python3, lib, stdenv, zip }:
+
+stdenv.mkDerivation rec {
+  name = "jscoverage-0.5.1";
+
+  src = fetchurl {
+    url = "https://siliconforks.com/jscoverage/download/${name}.tar.bz2";
+    sha256 = "c45f051cec18c10352f15f9844f47e37e8d121d5fd16680e2dd0f3b4420eb7f4";
+  };
+
+  patches = [
+    ./jsfalse_to_null.patch
+  ];
+
+  nativeBuildInputs = [ perl python3 zip ];
+
+  strictDeps = true;
+
+  # It works without MOZ_FIX_LINK_PATHS, circumventing an impurity
+  # issue.  Maybe we could kick js/ (spidermonkey) completely and
+  # instead use our spidermonkey via nix.
+  preConfigure = ''
+  sed -i 's/^MOZ_FIX_LINK_PATHS=.*$/MOZ_FIX_LINK_PATHS=""/' ./js/configure
+  '';
+
+  meta = {
+    description = "Code coverage for JavaScript";
+
+    longDescription = ''
+    JSCoverage is a tool that measures code coverage for JavaScript
+    programs.
+
+    Code coverage statistics show which lines of a program have been
+    executed (and which have been missed). This information is useful
+    for constructing comprehensive test suites (hence, it is often
+    called test coverage).
+
+    JSCoverage works by instrumenting the JavaScript code used in web
+    pages. Code coverage statistics are collected while the
+    instrumented JavaScript code is executed in a web browser.
+
+    JSCoverage supports the complete language syntax described in the
+    ECMAScript Language Specification (ECMA-262, 3rd
+    edition). JSCoverage works with any modern standards-compliant web
+    browser - including Internet Explorer (IE 6, 7, and 8), Firefox,
+    Opera, Safari, and Google Chrome - on Microsoft Windows and
+    GNU/Linux.
+    '';
+
+    homepage = "http://siliconforks.com/jscoverage/";
+    license = lib.licenses.gpl2;
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/jscoverage/jsfalse_to_null.patch b/nixpkgs/pkgs/development/tools/misc/jscoverage/jsfalse_to_null.patch
new file mode 100644
index 000000000000..b49594964e1f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/jscoverage/jsfalse_to_null.patch
@@ -0,0 +1,26 @@
+diff --git i/js/jsstr.cpp w/js/jsstr.cpp
+index e662bf1..b18597e 100644
+--- i/js/jsstr.cpp
++++ w/js/jsstr.cpp
+@@ -3040,7 +3040,7 @@ js_InitStringClass(JSContext *cx, JSObject *obj)
+                                  JSVAL_VOID, NULL, NULL,
+                                  JSPROP_READONLY | JSPROP_PERMANENT | JSPROP_SHARED, 0, 0,
+                                  NULL)) {
+-        return JS_FALSE;
++        return NULL;
+     }
+ 
+     return proto;
+diff --git i/js/jsxml.cpp w/js/jsxml.cpp
+index 5621ede..e00c97d 100644
+--- i/js/jsxml.cpp
++++ w/js/jsxml.cpp
+@@ -303,7 +303,7 @@ NewXMLNamespace(JSContext *cx, JSString *prefix, JSString *uri, JSBool declared)
+ 
+     obj = js_NewObject(cx, &js_NamespaceClass.base, NULL, NULL);
+     if (!obj)
+-        return JS_FALSE;
++        return NULL;
+     JS_ASSERT(JSVAL_IS_VOID(obj->fslots[JSSLOT_PREFIX]));
+     JS_ASSERT(JSVAL_IS_VOID(obj->fslots[JSSLOT_URI]));
+     JS_ASSERT(JSVAL_IS_VOID(obj->fslots[JSSLOT_DECLARED]));
diff --git a/nixpkgs/pkgs/development/tools/misc/k2tf/default.nix b/nixpkgs/pkgs/development/tools/misc/k2tf/default.nix
new file mode 100644
index 000000000000..904256ee66a9
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/k2tf/default.nix
@@ -0,0 +1,24 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "k2tf";
+  version = "0.5.0";
+
+  src = fetchFromGitHub {
+    owner = "sl1pm4t";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "0i1bhn0sccvnqbd4kv2xgng5r68adhcc61im2mn8hxmds5nf6in2";
+  };
+
+  vendorSha256 = "1c2mwhrj0xapc661z1nb6am4qq3rd1pvbvjaxikjyx95n0gs8gjk";
+
+  buildFlagsArray = [ "-ldflags=-s -w -X main.version=${version} -X main.commit=v${version}" ];
+
+  meta = with lib; {
+    description = "Kubernetes YAML to Terraform HCL converter";
+    homepage = "https://github.com/sl1pm4t/k2tf";
+    license = licenses.mpl20;
+    maintainers = [ maintainers.flokli ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/kconfig-frontends/default.nix b/nixpkgs/pkgs/development/tools/misc/kconfig-frontends/default.nix
new file mode 100644
index 000000000000..ae757f0d80d6
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/kconfig-frontends/default.nix
@@ -0,0 +1,37 @@
+{ lib, stdenv, fetchurl, pkg-config, bison, flex, gperf, ncurses, python3, bash }:
+
+stdenv.mkDerivation rec {
+  basename = "kconfig-frontends";
+  version = "4.11.0.1";
+  name = "${basename}-${version}";
+
+  src = fetchurl {
+    sha256 = "1xircdw3k7aaz29snf96q2fby1cs48bidz5l1kkj0a5gbivw31i3";
+    url = "http://ymorin.is-a-geek.org/download/${basename}/${name}.tar.xz";
+  };
+
+  nativeBuildInputs = [ bison flex gperf pkg-config ];
+  buildInputs = [ bash ncurses python3 ];
+
+  strictDeps = true;
+
+  configureFlags = [
+    "--enable-frontends=conf,mconf,nconf"
+  ];
+
+  NIX_CFLAGS_COMPILE = lib.optionalString stdenv.cc.isClang "-Wno-error=format-security";
+
+  meta = with lib; {
+    description = "Out of Linux tree packaging of the kconfig infrastructure";
+    longDescription = ''
+      Configuration language and system for the Linux kernel and other
+      projects. Features simple syntax and grammar, limited yet adequate option
+      types, simple organization of options, and direct and reverse
+      dependencies.
+    '';
+    homepage = "http://ymorin.is-a-geek.org/projects/kconfig-frontends";
+    license = licenses.gpl2;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ mbe ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/kdbg/default.nix b/nixpkgs/pkgs/development/tools/misc/kdbg/default.nix
new file mode 100644
index 000000000000..35e0a52865fa
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/kdbg/default.nix
@@ -0,0 +1,33 @@
+{ lib, stdenv, fetchurl, cmake, extra-cmake-modules, qt5,
+  ki18n, kconfig, kiconthemes, kxmlgui, kwindowsystem,
+  qtbase, makeWrapper,
+}:
+
+stdenv.mkDerivation rec {
+  pname = "kdbg";
+  version = "3.0.1";
+  src = fetchurl {
+    url = "mirror://sourceforge/kdbg/${version}/${pname}-${version}.tar.gz";
+    sha256 = "1gax6xll8svmngw0z1rzhd77xysv01zp0i68x4n5pq0xgh7gi7a4";
+  };
+
+  nativeBuildInputs = [ cmake extra-cmake-modules makeWrapper ];
+  buildInputs = [ qt5.qtbase ki18n kconfig kiconthemes kxmlgui kwindowsystem ];
+
+  postInstall = ''
+    wrapProgram $out/bin/kdbg --prefix QT_PLUGIN_PATH : ${qtbase}/${qtbase.qtPluginPrefix}
+  '';
+
+  dontWrapQtApps = true;
+
+  meta = with lib; {
+    homepage = "https://www.kdbg.org/";
+    description = ''
+      A graphical user interface to gdb, the GNU debugger. It provides an
+      intuitive interface for setting breakpoints, inspecting variables, and
+      stepping through code.
+    '';
+    license = licenses.gpl2;
+    maintainers = [ maintainers.catern ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/kibana/6.x.nix b/nixpkgs/pkgs/development/tools/misc/kibana/6.x.nix
new file mode 100644
index 000000000000..9ba19c836b59
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/kibana/6.x.nix
@@ -0,0 +1,63 @@
+{ elk6Version
+, enableUnfree ? true
+, lib, stdenv
+, makeWrapper
+, fetchurl
+, nodejs-10_x
+, coreutils
+, which
+}:
+
+with lib;
+let
+  nodejs = nodejs-10_x;
+  inherit (builtins) elemAt;
+  info = splitString "-" stdenv.hostPlatform.system;
+  arch = elemAt info 0;
+  plat = elemAt info 1;
+  shas =
+    if enableUnfree
+    then {
+      x86_64-linux  = "1xwklhqxk5rmdrgy2simwvijzq29kyq5w2w3hy53xh2i1zlnyvq3";
+      x86_64-darwin = "1qpdn28mrpggd55khzqqld6r89l0hb870rigxcw2i8p2yx3jv106";
+    }
+    else {
+      x86_64-linux  = "1wpnwal2rq5v2bsp5qil9j6dplif7ql5394sy4ia5ghp2fzifxmf";
+      x86_64-darwin = "12z8i0wbw10c097glbpdy350p0h3957433f51qfx2p0ghgkzkhzv";
+    };
+
+in stdenv.mkDerivation rec {
+  name = "kibana-${optionalString (!enableUnfree) "oss-"}${version}";
+  version = elk6Version;
+
+  src = fetchurl {
+    url = "https://artifacts.elastic.co/downloads/kibana/${name}-${plat}-${arch}.tar.gz";
+    sha256 = shas.${stdenv.hostPlatform.system} or (throw "Unknown architecture");
+  };
+
+  patches = [
+    # Kibana specifies it specifically needs nodejs 10.15.2 but nodejs in nixpkgs is at 10.15.3.
+    # The <nixpkgs/nixos/tests/elk.nix> test succeeds with this newer version so lets just
+    # disable the version check.
+    ./disable-nodejs-version-check.patch
+  ];
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  installPhase = ''
+    mkdir -p $out/libexec/kibana $out/bin
+    mv * $out/libexec/kibana/
+    rm -r $out/libexec/kibana/node
+    makeWrapper $out/libexec/kibana/bin/kibana $out/bin/kibana \
+      --prefix PATH : "${lib.makeBinPath [ nodejs coreutils which ]}"
+    sed -i 's@NODE=.*@NODE=${nodejs}/bin/node@' $out/libexec/kibana/bin/kibana
+  '';
+
+  meta = {
+    description = "Visualize logs and time-stamped data";
+    homepage = "http://www.elasticsearch.org/overview/kibana";
+    license = if enableUnfree then licenses.elastic else licenses.asl20;
+    maintainers = with maintainers; [ offline basvandijk ];
+    platforms = with platforms; unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/kibana/7.x.nix b/nixpkgs/pkgs/development/tools/misc/kibana/7.x.nix
new file mode 100644
index 000000000000..754559969d50
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/kibana/7.x.nix
@@ -0,0 +1,63 @@
+{ elk7Version
+, enableUnfree ? true
+, lib, stdenv
+, makeWrapper
+, fetchurl
+, nodejs-10_x
+, coreutils
+, which
+}:
+
+with lib;
+let
+  nodejs = nodejs-10_x;
+  inherit (builtins) elemAt;
+  info = splitString "-" stdenv.hostPlatform.system;
+  arch = elemAt info 0;
+  plat = elemAt info 1;
+  shas =
+    if enableUnfree
+    then {
+      x86_64-linux  = "1wq4fc2fifkg1qz7nxdfb4yi2biay8cgdz7kl5k0p37sxn0sbkja";
+      x86_64-darwin = "06346kj7bv49py49pmmnmh8m24322m88v1af19909pj9cxgd0p6v";
+    }
+    else {
+      x86_64-linux  = "0ygpmcm6wdcnvw8azwqc5257lyic7yw31rqvm2pw3afhpha62lpj";
+      x86_64-darwin = "0xy81g0bhxp47p29kkkh5llfzqkzqzr5dk50ap2hy0hjw33ld6g1";
+    };
+
+in stdenv.mkDerivation rec {
+  name = "kibana-${optionalString (!enableUnfree) "oss-"}${version}";
+  version = elk7Version;
+
+  src = fetchurl {
+    url = "https://artifacts.elastic.co/downloads/kibana/${name}-${plat}-${arch}.tar.gz";
+    sha256 = shas.${stdenv.hostPlatform.system} or (throw "Unknown architecture");
+  };
+
+  patches = [
+    # Kibana specifies it specifically needs nodejs 10.15.2 but nodejs in nixpkgs is at 10.15.3.
+    # The <nixpkgs/nixos/tests/elk.nix> test succeeds with this newer version so lets just
+    # disable the version check.
+    ./disable-nodejs-version-check-7.patch
+  ];
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  installPhase = ''
+    mkdir -p $out/libexec/kibana $out/bin
+    mv * $out/libexec/kibana/
+    rm -r $out/libexec/kibana/node
+    makeWrapper $out/libexec/kibana/bin/kibana $out/bin/kibana \
+      --prefix PATH : "${lib.makeBinPath [ nodejs coreutils which ]}"
+    sed -i 's@NODE=.*@NODE=${nodejs}/bin/node@' $out/libexec/kibana/bin/kibana
+  '';
+
+  meta = {
+    description = "Visualize logs and time-stamped data";
+    homepage = "http://www.elasticsearch.org/overview/kibana";
+    license = if enableUnfree then licenses.elastic else licenses.asl20;
+    maintainers = with maintainers; [ offline basvandijk ];
+    platforms = with platforms; unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check-7.patch b/nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check-7.patch
new file mode 100644
index 000000000000..ef4c207764c1
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check-7.patch
@@ -0,0 +1,19 @@
+diff --git a/src/setup_node_env/node_version_validator.js b/src/setup_node_env/node_version_validator.js
+index 3f611e5a..f5c60c85 100644
+--- a/src/setup_node_env/node_version_validator.js
++++ b/src/setup_node_env/node_version_validator.js
+@@ -25,11 +25,11 @@ var pkg = require('../../package.json'); // Note: This is written in ES5 so we c
+ var currentVersion = process && process.version || null;
+ var rawRequiredVersion = pkg && pkg.engines && pkg.engines.node || null;
+ var requiredVersion = rawRequiredVersion ? 'v' + rawRequiredVersion : rawRequiredVersion;
+-var isVersionValid = !!currentVersion && !!requiredVersion && currentVersion === requiredVersion; // Validates current the NodeJS version compatibility when Kibana starts.
++var isVersionValid = !!currentVersion && !!requiredVersion; // Validates current the NodeJS version compatibility when Kibana starts.
+ 
+ if (!isVersionValid) {
+   var errorMessage = 'Kibana does not support the current Node.js version ' + currentVersion + '. Please use Node.js ' + requiredVersion + '.'; // Actions to apply when validation fails: error report + exit.
+ 
+   console.error(errorMessage);
+   process.exit(1);
+-}
+\ No newline at end of file
++}
diff --git a/nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check.patch b/nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check.patch
new file mode 100644
index 000000000000..12a81566a72c
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/kibana/disable-nodejs-version-check.patch
@@ -0,0 +1,19 @@
+diff -Naur a/src/setup_node_env/node_version_validator.js b/src/setup_node_env/node_version_validator.js
+--- a/src/setup_node_env/node_version_validator.js	2018-11-16 03:28:42.000000000 +0100
++++ b/src/setup_node_env/node_version_validator.js	2018-12-01 12:19:48.238337176 +0100
+@@ -26,7 +26,7 @@
+ var currentVersion = process && process.version || null;
+ var rawRequiredVersion = pkg && pkg.engines && pkg.engines.node || null;
+ var requiredVersion = rawRequiredVersion ? 'v' + rawRequiredVersion : rawRequiredVersion;
+-var isVersionValid = !!currentVersion && !!requiredVersion && currentVersion === requiredVersion;
++var isVersionValid = !!currentVersion && !!requiredVersion;
+ 
+ // Validates current the NodeJS version compatibility when Kibana starts.
+ if (!isVersionValid) {
+@@ -35,4 +35,4 @@
+   // Actions to apply when validation fails: error report + exit.
+   console.error(errorMessage);
+   process.exit(1);
+-}
+\ No newline at end of file
++}
diff --git a/nixpkgs/pkgs/development/tools/misc/libtool/default.nix b/nixpkgs/pkgs/development/tools/misc/libtool/default.nix
new file mode 100644
index 000000000000..2b0089e89f64
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/libtool/default.nix
@@ -0,0 +1,41 @@
+{lib, stdenv, fetchurl, m4, perl}:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+stdenv.mkDerivation rec {
+  name = "libtool-1.5.26";
+
+  src = fetchurl {
+    url = "mirror://gnu/libtool/${name}.tar.gz";
+    sha256 = "029ggq5kri1gjn6nfqmgw4w920gyfzscjjxbsxxidal5zqsawd8w";
+  };
+
+  nativeBuildInputs = [m4];
+  buildInputs = [perl];
+
+  # Don't fixup "#! /bin/sh" in Libtool, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  meta = {
+    description = "Generic library support script";
+
+    longDescription = ''
+      GNU libtool is a generic library support script.  Libtool hides
+      the complexity of using shared libraries behind a consistent,
+      portable interface.
+
+      To use libtool, add the new generic library building commands to
+      your Makefile, Makefile.in, or Makefile.am.  See the
+      documentation for details.
+    '';
+
+    homepage = "https://www.gnu.org/software/libtool/";
+
+    license = lib.licenses.gpl2Plus;
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/libtool/libtool2-macos11.patch b/nixpkgs/pkgs/development/tools/misc/libtool/libtool2-macos11.patch
new file mode 100644
index 000000000000..1552ae7a949f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/libtool/libtool2-macos11.patch
@@ -0,0 +1,32 @@
+Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
+---
+ m4/libtool.m4 | 13 ++++---------
+ 1 file changed, 4 insertions(+), 9 deletions(-)
+
+diff --git a/m4/libtool.m4 b/m4/libtool.m4
+index f2d1f398..b971e8e7 100644
+--- a/m4/libtool.m4
++++ b/m4/libtool.m4
+@@ -1067,16 +1067,11 @@ _LT_EOF
+       _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
+     darwin1.*)
+       _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
+-    darwin*) # darwin 5.x on
+-      # if running on 10.5 or later, the deployment target defaults
+-      # to the OS version, if on x86, and 10.4, the deployment
+-      # target defaults to 10.4. Don't you love it?
+-      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
+-	10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
+-	  _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
+-	10.[[012]][[,.]]*)
++    darwin*)
++      case ${MACOSX_DEPLOYMENT_TARGET},$host in
++	10.[[012]],*|,*powerpc*)
+ 	  _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
+-	10.*)
++	*)
+ 	  _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
+       esac
+     ;;
+-- 
+2.24.3 (Apple Git-128)
diff --git a/nixpkgs/pkgs/development/tools/misc/libtool/libtool2.nix b/nixpkgs/pkgs/development/tools/misc/libtool/libtool2.nix
new file mode 100644
index 000000000000..44e4c8665c83
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/libtool/libtool2.nix
@@ -0,0 +1,69 @@
+{ lib, stdenv, fetchurl, fetchpatch, autoconf, automake, m4, perl, help2man
+}:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+stdenv.mkDerivation rec {
+  pname = "libtool";
+  version = "2.4.6";
+
+  src = fetchurl {
+    url = "mirror://gnu/libtool/${pname}-${version}.tar.gz";
+    sha256 = "1qq61k6lp1fp75xs398yzi6wvbx232l7xbyn3p13cnh27mflvgg3";
+  };
+
+  outputs = [ "out" "lib" ];
+
+  patches = [
+    # Suport macOS version 11.0
+    # https://lists.gnu.org/archive/html/libtool-patches/2020-06/msg00001.html
+    ./libtool2-macos11.patch
+  ];
+
+  # Normally we'd use autoreconfHook, but that includes libtoolize.
+  postPatch = ''
+    aclocal -I m4
+    automake
+    autoconf
+
+    pushd libltdl
+    aclocal -I ../m4
+    automake
+    autoconf
+    popd
+  '';
+
+  nativeBuildInputs = [ perl help2man m4 ] ++ [ autoconf automake ];
+  propagatedBuildInputs = [ m4 ];
+
+  # Don't fixup "#! /bin/sh" in Libtool, otherwise it will use the
+  # "fixed" path in generated files!
+  dontPatchShebangs = true;
+
+  # XXX: The GNU ld wrapper does all sorts of nasty things wrt. RPATH, which
+  # leads to the failure of a number of tests.
+  doCheck = false;
+  doInstallCheck = false;
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    description = "GNU Libtool, a generic library support script";
+    longDescription = ''
+      GNU libtool is a generic library support script.  Libtool hides
+      the complexity of using shared libraries behind a consistent,
+      portable interface.
+
+      To use libtool, add the new generic library building commands to
+      your Makefile, Makefile.in, or Makefile.am.  See the
+      documentation for details.
+    '';
+    homepage = "https://www.gnu.org/software/libtool/";
+    license = licenses.gpl2Plus;
+    maintainers = [ ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/libwhich/default.nix b/nixpkgs/pkgs/development/tools/misc/libwhich/default.nix
new file mode 100644
index 000000000000..aeda5271142a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/libwhich/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  pname = "libwhich";
+  version = "1.1.0";
+
+  src = fetchFromGitHub {
+    owner = "vtjnash";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "0s0pqai61jszmi495k621rdlf288ij67adkz72hwqqarqp54idhb";
+  };
+
+  installPhase = ''
+    install -Dm755 -t $out/bin libwhich
+  '';
+
+  meta = with lib; {
+    description = "Like `which`, for dynamic libraries";
+    homepage = "https://github.com/vtjnash/libwhich";
+    license = licenses.mit;
+    maintainers = with maintainers; [ dtzWill ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/linuxkit/default.nix b/nixpkgs/pkgs/development/tools/misc/linuxkit/default.nix
new file mode 100644
index 000000000000..eeb2102bdf0c
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/linuxkit/default.nix
@@ -0,0 +1,27 @@
+{ lib, buildGoPackage, fetchFromGitHub }:
+
+buildGoPackage rec {
+  pname   = "linuxkit";
+  version = "0.8";
+
+  goPackagePath = "github.com/linuxkit/linuxkit";
+
+  src = fetchFromGitHub {
+    owner = "linuxkit";
+    repo = "linuxkit";
+    rev = "v${version}";
+    sha256 = "15jj60k8wz9cahjbdscnwyyfb1k1grjh7yrilb1cj4r8mby4sp2g";
+  };
+
+  subPackages = [ "src/cmd/linuxkit" ];
+
+  buildFlagsArray = [ "-ldflags=-s -w -X ${goPackagePath}/src/cmd/linuxkit/version.GitCommit=${src.rev} -X ${goPackagePath}/src/cmd/linuxkit/version.Version=${version}" ];
+
+  meta = with lib; {
+    description = "A toolkit for building secure, portable and lean operating systems for containers";
+    license = licenses.asl20;
+    homepage = "https://github.com/linuxkit/linuxkit";
+    maintainers = [ maintainers.nicknovitski ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/lit/default.nix b/nixpkgs/pkgs/development/tools/misc/lit/default.nix
new file mode 100644
index 000000000000..7c7549e3844c
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/lit/default.nix
@@ -0,0 +1,25 @@
+{ lib, python3 }:
+
+python3.pkgs.buildPythonApplication rec {
+  pname = "lit";
+  version = "0.10.0";
+
+  src = python3.pkgs.fetchPypi {
+    inherit pname version;
+    sha256 = "13s8v9s2f284fnh47xdyc75gq2i9pndl39q8v4wl7v7lwri2hv8r";
+  };
+
+  passthru = {
+    python = python3;
+  };
+
+  # Non-standard test suite. Needs custom checkPhase.
+  doCheck = false;
+
+  meta = {
+    description = "Portable tool for executing LLVM and Clang style test suites";
+    homepage = "http://llvm.org/docs/CommandGuide/lit.html";
+    license = lib.licenses.ncsa;
+    maintainers = with lib.maintainers; [ dtzWill ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/loccount/default.nix b/nixpkgs/pkgs/development/tools/misc/loccount/default.nix
new file mode 100644
index 000000000000..32a14404c606
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/loccount/default.nix
@@ -0,0 +1,35 @@
+{ lib, buildGoPackage, fetchFromGitLab }:
+buildGoPackage rec {
+  pname = "loccount";
+  version = "1.2";
+
+  goPackagePath = "gitlab.com/esr/loccount";
+  excludedPackages = "tests";
+
+  src = fetchFromGitLab {
+    owner = "esr";
+    repo = "loccount";
+    rev = version;
+    sha256 = "18z7ai7wy2k9yd3w65d37apfqs3h9bc2c15y7v1bydppi44zfsdk";
+  };
+
+  meta = with lib; {
+    description = "Re-implementation of sloccount in Go";
+    longDescription = ''
+      loccount is a re-implementation of David A. Wheeler's sloccount tool
+      in Go.  It is faster and handles more different languages. Because
+      it's one source file in Go, it is easier to maintain and extend than the
+      multi-file, multi-language implementation of the original.
+
+      The algorithms are largely unchanged and can be expected to produce
+      identical numbers for languages supported by both tools.  Python is
+      an exception; loccount corrects buggy counting of single-quote multiline
+      literals in sloccount 2.26.
+    '';
+    homepage="https://gitlab.com/esr/loccount";
+    downloadPage="https://gitlab.com/esr/loccount/tree/master";
+    license = licenses.bsd2;
+    maintainers = with maintainers; [ calvertvl ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/lsof/default.nix b/nixpkgs/pkgs/development/tools/misc/lsof/default.nix
new file mode 100644
index 000000000000..94e3722598b0
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/lsof/default.nix
@@ -0,0 +1,58 @@
+{ lib, stdenv, fetchFromGitHub, buildPackages, ncurses }:
+
+let dialect = with lib; last (splitString "-" stdenv.hostPlatform.system); in
+
+stdenv.mkDerivation rec {
+  pname = "lsof";
+  version = "4.94.0";
+
+  depsBuildBuild = [ buildPackages.stdenv.cc ];
+  buildInputs = [ ncurses ];
+
+  src = fetchFromGitHub {
+    owner = "lsof-org";
+    repo = "lsof";
+    rev = version;
+    sha256 = "0yxv2jg6rnzys49lyrz9yjb4knamah4xvlqj596y6ix3vm4k3chp";
+  };
+
+  patches = [ ./no-build-info.patch ];
+
+  postPatch = lib.optionalString stdenv.hostPlatform.isMusl ''
+    substituteInPlace dialects/linux/dlsof.h --replace "defined(__UCLIBC__)" 1
+  '' + lib.optionalString stdenv.isDarwin ''
+    sed -i 's|lcurses|lncurses|g' Configure
+  '';
+
+  # Stop build scripts from searching global include paths
+  LSOF_INCLUDE = "${lib.getDev stdenv.cc.libc}/include";
+  configurePhase = "LINUX_CONF_CC=$CC_FOR_BUILD LSOF_CC=$CC LSOF_AR=\"$AR cr\" LSOF_RANLIB=$RANLIB ./Configure -n ${dialect}";
+  preBuild = ''
+    for filepath in $(find dialects/${dialect} -type f); do
+      sed -i "s,/usr/include,$LSOF_INCLUDE,g" $filepath
+    done
+  '';
+
+  installPhase = ''
+    # Fix references from man page https://github.com/lsof-org/lsof/issues/66
+    substituteInPlace Lsof.8 \
+      --replace ".so ./00DIALECTS" "" \
+      --replace ".so ./version" ".ds VN ${version}"
+    mkdir -p $out/bin $out/man/man8
+    cp Lsof.8 $out/man/man8/lsof.8
+    cp lsof $out/bin
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/lsof-org/lsof";
+    description = "A tool to list open files";
+    longDescription = ''
+      List open files. Can show what process has opened some file,
+      socket (IPv6/IPv4/UNIX local), or partition (by opening a file
+      from it).
+    '';
+    maintainers = [ maintainers.dezgeg ];
+    platforms = platforms.unix;
+    license = licenses.purdueBsd;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/lsof/no-build-info.patch b/nixpkgs/pkgs/development/tools/misc/lsof/no-build-info.patch
new file mode 100644
index 000000000000..cf785e248f2a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/lsof/no-build-info.patch
@@ -0,0 +1,43 @@
+diff -ru -x '*~' lsof_4.91_src-orig/usage.c lsof_4.91_src/usage.c
+--- lsof_4.91_src-orig/usage.c	2018-02-14 15:20:32.000000000 +0100
++++ lsof_4.91_src/usage.c	2018-10-08 21:57:45.718560869 +0200
+@@ -930,26 +930,6 @@
+ 		(void) fprintf(stderr, "    configuration info: %s\n", cp);
+ #endif	/* defined(LSOF_CINFO) */
+ 
+-	    if ((cp = isnullstr(LSOF_CCDATE)))
+-		(void) fprintf(stderr, "    constructed: %s\n", cp);
+-	    cp = isnullstr(LSOF_HOST);
+-	    if (!(cp1 = isnullstr(LSOF_LOGNAME)))
+-		cp1 = isnullstr(LSOF_USER);
+-	    if (cp || cp1) {
+-		if (cp && cp1)
+-		    cp2 = "by and on";
+-		else if (cp)
+-		    cp2 = "on";
+-		else
+-		    cp2 = "by";
+-		(void) fprintf(stderr, "    constructed %s: %s%s%s\n",
+-		    cp2,
+-		    cp1 ? cp1 : "",
+-		    (cp && cp1) ? "@" : "",
+-		    cp  ? cp  : ""
+-		);
+-	    }
+-
+ #if	defined(LSOF_BLDCMT)
+ 	    if ((cp = isnullstr(LSOF_BLDCMT)))
+ 		(void) fprintf(stderr, "    builder's comment: %s\n", cp);
+@@ -959,12 +939,8 @@
+ 		(void) fprintf(stderr, "    compiler: %s\n", cp);
+ 	    if ((cp = isnullstr(LSOF_CCV)))
+ 		(void) fprintf(stderr, "    compiler version: %s\n", cp);
+-	    if ((cp = isnullstr(LSOF_CCFLAGS)))
+-		(void) fprintf(stderr, "    compiler flags: %s\n", cp);
+ 	    if ((cp = isnullstr(LSOF_LDFLAGS)))
+ 		(void) fprintf(stderr, "    loader flags: %s\n", cp);
+-	    if ((cp = isnullstr(LSOF_SYSINFO)))
+-		(void) fprintf(stderr, "    system info: %s\n", cp);
+ 	    (void) report_SECURITY("    ", ".\n");
+ 	    (void) report_WARNDEVACCESS("    ", "are", ".\n");
+ 	    (void) report_HASKERNIDCK("    K", "is");
diff --git a/nixpkgs/pkgs/development/tools/misc/ltrace/default.nix b/nixpkgs/pkgs/development/tools/misc/ltrace/default.nix
new file mode 100644
index 000000000000..e1d9ae6b5513
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ltrace/default.nix
@@ -0,0 +1,29 @@
+{ lib, stdenv, fetchurl, elfutils, libunwind }:
+
+stdenv.mkDerivation {
+  name = "ltrace-0.7.3";
+
+  src = fetchurl {
+    url = "mirror://debian/pool/main/l/ltrace/ltrace_0.7.3.orig.tar.bz2";
+    sha256 = "00wmbdghqbz6x95m1mcdd3wd46l6hgcr4wggdp049dbifh3qqvqf";
+  };
+
+  buildInputs = [ elfutils libunwind ];
+
+  prePatch = let
+      debian = fetchurl {
+        url = "mirror://debian/pool/main/l/ltrace/ltrace_0.7.3-6.debian.tar.xz";
+        sha256 = "0xc4pfd8qw53crvdxr29iwl8na53zmknca082kziwpvlzsick4kp";
+      };
+    in ''
+      tar xf '${debian}'
+      patches="$patches $(cat debian/patches/series | sed 's|^|debian/patches/|')"
+    '';
+
+  meta = with lib; {
+    description = "Library call tracer";
+    homepage = "https://www.ltrace.org/";
+    platforms = [ "i686-linux" "x86_64-linux" ];
+    license = licenses.gpl2;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/lttng-tools/default.nix b/nixpkgs/pkgs/development/tools/misc/lttng-tools/default.nix
new file mode 100644
index 000000000000..223e10d04ab5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/lttng-tools/default.nix
@@ -0,0 +1,23 @@
+{ lib, stdenv, fetchurl, pkg-config, popt, libuuid, liburcu, lttng-ust, kmod, libxml2 }:
+
+stdenv.mkDerivation rec {
+  pname = "lttng-tools";
+  version = "2.11.0";
+
+  src = fetchurl {
+    url = "https://lttng.org/files/lttng-tools/${pname}-${version}.tar.bz2";
+    sha256 = "1g0g7ypxvc7wd5x4d4ixmfgl9yk0lxax3ymm95hcjwxn5p497r6w";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ popt libuuid liburcu lttng-ust libxml2 kmod ];
+
+  meta = with lib; {
+    description = "Tracing tools (kernel + user space) for Linux";
+    homepage = "https://lttng.org/";
+    license = licenses.lgpl21;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/lttng-ust/default.nix b/nixpkgs/pkgs/development/tools/misc/lttng-ust/default.nix
new file mode 100644
index 000000000000..94d2e4a33f29
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/lttng-ust/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv, fetchurl, liburcu, python3 }:
+
+# NOTE:
+#   ./configure ...
+#   [...]
+#   LTTng-UST will be built with the following options:
+#
+#   Java support (JNI): Disabled
+#   sdt.h integration:  Disabled
+#   [...]
+#
+# Debian builds with std.h (systemtap).
+
+stdenv.mkDerivation rec {
+  pname = "lttng-ust";
+  version = "2.10.5";
+
+  src = fetchurl {
+    url = "https://lttng.org/files/lttng-ust/${pname}-${version}.tar.bz2";
+    sha256 = "0ddwk0nl28bkv2xb78gz16a2bvlpfbjmzwfbgwf5p1cq46dyvy86";
+  };
+
+  buildInputs = [ python3 ];
+
+  preConfigure = ''
+    patchShebangs .
+  '';
+
+  propagatedBuildInputs = [ liburcu ];
+
+  meta = with lib; {
+    description = "LTTng Userspace Tracer libraries";
+    homepage = "https://lttng.org/";
+    license = licenses.lgpl21Plus;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/lttv/default.nix b/nixpkgs/pkgs/development/tools/misc/lttv/default.nix
new file mode 100644
index 000000000000..a196c5f45288
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/lttv/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchurl, pkg-config, glib, gtk2, popt, babeltrace }:
+
+stdenv.mkDerivation rec {
+  name = "lttv-1.5";
+
+  src = fetchurl {
+    url = "https://lttng.org/files/packages/${name}.tar.bz2";
+    sha256 = "1faldxnh9dld5k0vxckwpqw241ya1r2zv286l6rpgqr500zqw7r1";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ glib gtk2 popt babeltrace ];
+
+  meta = with lib; {
+    description = "Graphical trace viewer for LTTng trace files";
+    homepage = "https://lttng.org/";
+    # liblttvtraceread (ltt/ directory) is distributed under the GNU LGPL v2.1.
+    # The rest of the LTTV package is distributed under the GNU GPL v2.
+    license = with licenses; [ gpl2 lgpl21 ];
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/luarocks/darwin-3.1.3.patch b/nixpkgs/pkgs/development/tools/misc/luarocks/darwin-3.1.3.patch
new file mode 100644
index 000000000000..8070af173aaf
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/luarocks/darwin-3.1.3.patch
@@ -0,0 +1,24 @@
+diff --git a/src/luarocks/core/cfg.lua b/src/luarocks/core/cfg.lua
+index c5af5a2..1949fdc 100644
+--- a/src/luarocks/core/cfg.lua
++++ b/src/luarocks/core/cfg.lua
+@@ -425,7 +425,7 @@ local function make_defaults(lua_version, target_cpu, platforms, home)
+       defaults.external_lib_extension = "dylib"
+       defaults.arch = "macosx-"..target_cpu
+       defaults.variables.LIBFLAG = "-bundle -undefined dynamic_lookup -all_load"
+-      local version = util.popen_read("sw_vers -productVersion")
++      local version = os.getenv("MACOSX_DEPLOYMENT_TARGET") or "@darwinMinVersion@"
+       version = tonumber(version and version:match("^[^.]+%.([^.]+)")) or 3
+       if version >= 10 then
+          version = 8
+@@ -434,8 +434,8 @@ local function make_defaults(lua_version, target_cpu, platforms, home)
+       else
+          defaults.gcc_rpath = false
+       end
+-      defaults.variables.CC = "env MACOSX_DEPLOYMENT_TARGET=10."..version.." gcc"
+-      defaults.variables.LD = "env MACOSX_DEPLOYMENT_TARGET=10."..version.." gcc"
++      defaults.variables.CC = "env MACOSX_DEPLOYMENT_TARGET=10."..version.." clang"
++      defaults.variables.LD = "env MACOSX_DEPLOYMENT_TARGET=10."..version.." clang"
+       defaults.web_browser = "open"
+    end
+ 
diff --git a/nixpkgs/pkgs/development/tools/misc/luarocks/default.nix b/nixpkgs/pkgs/development/tools/misc/luarocks/default.nix
new file mode 100644
index 000000000000..d4f2ec4ded98
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/luarocks/default.nix
@@ -0,0 +1,79 @@
+{lib, stdenv, fetchFromGitHub
+, curl, makeWrapper, which, unzip
+, lua
+# for 'luarocks pack'
+, zip
+# some packages need to be compiled with cmake
+, cmake
+}:
+
+stdenv.mkDerivation rec {
+  pname = "luarocks";
+  version = "3.2.1";
+
+  src = fetchFromGitHub {
+    owner = "luarocks";
+    repo = "luarocks";
+    rev = "v${version}";
+    sha256 = "0viiafmb8binksda79ah828q1dfnb6jsqlk7vyndl2xvx9yfn4y2";
+  };
+
+  patches = [ ./darwin-3.1.3.patch ];
+
+  postPatch = lib.optionalString stdenv.targetPlatform.isDarwin ''
+    substituteInPlace src/luarocks/core/cfg.lua --subst-var-by 'darwinMinVersion' '${stdenv.targetPlatform.darwinMinVersion}'
+  '';
+
+  preConfigure = ''
+    lua -e "" || {
+        luajit -e "" && {
+            export LUA_SUFFIX=jit
+            configureFlags="$configureFlags --lua-suffix=$LUA_SUFFIX"
+        }
+    }
+    lua_inc="$(echo "${lua}/include"/*/)"
+    if test -n "$lua_inc"; then
+        configureFlags="$configureFlags --with-lua-include=$lua_inc"
+    fi
+  '';
+
+  buildInputs = [
+    lua curl makeWrapper which
+  ];
+
+  postInstall = ''
+    sed -e "1s@.*@#! ${lua}/bin/lua$LUA_SUFFIX@" -i "$out"/bin/*
+    for i in "$out"/bin/*; do
+        test -L "$i" || {
+            wrapProgram "$i" \
+              --suffix LUA_PATH ";" "$(echo "$out"/share/lua/*/)?.lua" \
+              --suffix LUA_PATH ";" "$(echo "$out"/share/lua/*/)?/init.lua" \
+              --suffix LUA_CPATH ";" "$(echo "$out"/lib/lua/*/)?.so" \
+              --suffix LUA_CPATH ";" "$(echo "$out"/share/lua/*/)?/init.lua"
+        }
+    done
+  '';
+
+  propagatedBuildInputs = [ zip unzip cmake ];
+
+  # unpack hook for src.rock and rockspec files
+  setupHook = ./setup-hook.sh;
+
+  # cmake is just to compile packages with "cmake" buildType, not luarocks itself
+  dontUseCmakeConfigure = true;
+
+  shellHook = ''
+    export PATH="src/bin:''${PATH:-}"
+    export LUA_PATH="src/?.lua;''${LUA_PATH:-}"
+  '';
+
+  meta = with lib; {
+    inherit version;
+    description = "A package manager for Lua";
+    license = licenses.mit ;
+    maintainers = with maintainers; [raskin teto];
+    platforms = platforms.linux ++ platforms.darwin;
+    downloadPage = "http://luarocks.org/releases/";
+    updateWalker = true;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/luarocks/default.upstream b/nixpkgs/pkgs/development/tools/misc/luarocks/default.upstream
new file mode 100644
index 000000000000..e69de1fe8895
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/luarocks/default.upstream
@@ -0,0 +1 @@
+url http://luarocks.org/releases/
diff --git a/nixpkgs/pkgs/development/tools/misc/luarocks/luarocks-nix.nix b/nixpkgs/pkgs/development/tools/misc/luarocks/luarocks-nix.nix
new file mode 100644
index 000000000000..30e02a3623fa
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/luarocks/luarocks-nix.nix
@@ -0,0 +1,11 @@
+{ luarocks, fetchFromGitHub }:
+luarocks.overrideAttrs(old: {
+  pname = "luarocks-nix";
+  version = "2021-01-22";
+  src = fetchFromGitHub {
+    owner = "nix-community";
+    repo = "luarocks-nix";
+    rev = "v3.5.0_nix";
+    sha256 = "sha256-Ea3PVkCaUPO/mvVZtHtD1G9T/Yom28M9oN6duY4ovHk=";
+  };
+})
diff --git a/nixpkgs/pkgs/development/tools/misc/luarocks/setup-hook.sh b/nixpkgs/pkgs/development/tools/misc/luarocks/setup-hook.sh
new file mode 100644
index 000000000000..587d5413c3ed
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/luarocks/setup-hook.sh
@@ -0,0 +1,16 @@
+unpackCmdHooks+=(_trySourceRock)
+unpackCmdHooks+=(_tryRockSpec)
+
+_tryRockSpec() {
+    if ! [[ "$curSrc" =~ \.rockspec$ ]]; then return 1; fi
+}
+
+_trySourceRock() {
+    if ! [[ "$curSrc" =~ \.src.rock$ ]]; then return 1; fi
+
+    # luarocks expects a clean <name>.rock.spec name to be the package name
+    # so we have to strip the hash
+    renamed="$(stripHash $curSrc)"
+    cp "$curSrc" "$renamed"
+    luarocks unpack --force "$renamed"
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/macdylibbundler/default.nix b/nixpkgs/pkgs/development/tools/misc/macdylibbundler/default.nix
new file mode 100644
index 000000000000..f37815081ee4
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/macdylibbundler/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv, makeWrapper, fetchFromGitHub, cctools }:
+
+stdenv.mkDerivation {
+  pname = "macdylibbundler";
+  version = "20180825";
+
+  src = fetchFromGitHub {
+    owner = "auriamg";
+    repo = "macdylibbundler";
+    rev = "ce13cb585ead5237813b85e68fe530f085fc0a9e";
+    sha256 = "149p3dcnap4hs3nhq5rfvr3m70rrb5hbr5xkj1h0gsfp0d7gvxnj";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  makeFlags = [ "PREFIX=$(out)" ];
+
+  postInstall = ''
+    wrapProgram $out/bin/dylibbundler \
+      --prefix PATH ":" "${cctools}/bin"
+  '';
+
+  meta = with lib; {
+    description = "Utility to ease bundling libraries into executables for OSX";
+    longDescription = ''
+      dylibbundler is a small command-line programs that aims to make bundling
+      .dylibs as easy as possible. It automatically determines which dylibs are
+      needed by your program, copies these libraries inside the app bundle, and
+      fixes both them and the executable to be ready for distribution... all
+      this with a single command on the teminal! It will also work if your
+      program uses plug-ins that have dependencies too.
+    '';
+    homepage = "https://github.com/auriamg/macdylibbundler";
+    license = licenses.mit;
+    platforms = platforms.all;
+    maintainers = [ maintainers.nomeata ];
+
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/mdctags/default.nix b/nixpkgs/pkgs/development/tools/misc/mdctags/default.nix
new file mode 100644
index 000000000000..7d8992b4e201
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/mdctags/default.nix
@@ -0,0 +1,22 @@
+{ lib, rustPlatform, fetchFromGitHub }:
+
+rustPlatform.buildRustPackage {
+  pname = "mdctags";
+  version = "unstable-2020-06-11"; # v0.1.0 does not build with our rust version
+
+  src = fetchFromGitHub {
+    owner = "wsdjeg";
+    repo = "mdctags.rs";
+    rev = "0ed9736ea0c77e6ff5b560dda46f5ed0a983ed82";
+    sha256 = "14gryhgh9czlkfk75ml0620c6v8r74i6h3ykkkmc7gx2z8h1jxrb";
+  };
+
+  cargoSha256 = "1kdbrcpvxiq91m5vq33vzjhsp4j3flzrpbj5hmxf0k3al1a7qk1g";
+
+  meta = {
+    description = "tags for markdown file";
+    homepage = "https://github.com/wsdjeg/mdctags.rs";
+    license = lib.licenses.mit;
+    maintainers = with lib.maintainers; [ pacien ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/mdl/Gemfile b/nixpkgs/pkgs/development/tools/misc/mdl/Gemfile
new file mode 100644
index 000000000000..15b33c53a653
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/mdl/Gemfile
@@ -0,0 +1,3 @@
+source "https://rubygems.org"
+
+gem "mdl"
diff --git a/nixpkgs/pkgs/development/tools/misc/mdl/Gemfile.lock b/nixpkgs/pkgs/development/tools/misc/mdl/Gemfile.lock
new file mode 100644
index 000000000000..0e5b7b016722
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/mdl/Gemfile.lock
@@ -0,0 +1,30 @@
+GEM
+  remote: https://rubygems.org/
+  specs:
+    chef-utils (16.7.61)
+    kramdown (2.3.0)
+      rexml
+    kramdown-parser-gfm (1.1.0)
+      kramdown (~> 2.0)
+    mdl (0.11.0)
+      kramdown (~> 2.3)
+      kramdown-parser-gfm (~> 1.1)
+      mixlib-cli (~> 2.1, >= 2.1.1)
+      mixlib-config (>= 2.2.1, < 4)
+      mixlib-shellout
+    mixlib-cli (2.1.8)
+    mixlib-config (3.0.9)
+      tomlrb
+    mixlib-shellout (3.2.2)
+      chef-utils
+    rexml (3.2.4)
+    tomlrb (2.0.0)
+
+PLATFORMS
+  ruby
+
+DEPENDENCIES
+  mdl
+
+BUNDLED WITH
+   2.1.4
diff --git a/nixpkgs/pkgs/development/tools/misc/mdl/default.nix b/nixpkgs/pkgs/development/tools/misc/mdl/default.nix
new file mode 100644
index 000000000000..ada686f2498a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/mdl/default.nix
@@ -0,0 +1,17 @@
+{ lib, bundlerApp, bundlerUpdateScript }:
+
+bundlerApp {
+  pname = "mdl";
+  gemdir = ./.;
+  exes = [ "mdl" ];
+
+  passthru.updateScript = bundlerUpdateScript "mdl";
+
+  meta = with lib; {
+    description = "A tool to check markdown files and flag style issues";
+    homepage = "https://github.com/markdownlint/markdownlint";
+    license = licenses.mit;
+    maintainers = with maintainers; [ gerschtli manveru nicknovitski ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/mdl/gemset.nix b/nixpkgs/pkgs/development/tools/misc/mdl/gemset.nix
new file mode 100644
index 000000000000..eaaa7bed5a5e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/mdl/gemset.nix
@@ -0,0 +1,97 @@
+{
+  chef-utils = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "14xd2md3cda42afl28hr5q4ng195zmqfn04w2bxr4s2fb0gglbrz";
+      type = "gem";
+    };
+    version = "16.7.61";
+  };
+  kramdown = {
+    dependencies = ["rexml"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1vmw752c26ny2jwl0npn0gbyqwgz4hdmlpxnsld9qi9xhk5b1qh7";
+      type = "gem";
+    };
+    version = "2.3.0";
+  };
+  kramdown-parser-gfm = {
+    dependencies = ["kramdown"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0a8pb3v951f4x7h968rqfsa19c8arz21zw1vaj42jza22rap8fgv";
+      type = "gem";
+    };
+    version = "1.1.0";
+  };
+  mdl = {
+    dependencies = ["kramdown" "kramdown-parser-gfm" "mixlib-cli" "mixlib-config" "mixlib-shellout"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0vgzq6v2scd8n4cmx8rrypqmchnhg4wccrhiakg2i8fzv7wxplqq";
+      type = "gem";
+    };
+    version = "0.11.0";
+  };
+  mixlib-cli = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1ydxlfgd7nnj3rp1y70k4yk96xz5cywldjii2zbnw3sq9pippwp6";
+      type = "gem";
+    };
+    version = "2.1.8";
+  };
+  mixlib-config = {
+    dependencies = ["tomlrb"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1askip583sfnz25gywd508l3vj5wnvx9vp7gm1sfnixm7amssrwq";
+      type = "gem";
+    };
+    version = "3.0.9";
+  };
+  mixlib-shellout = {
+    dependencies = ["chef-utils"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0y1z0phkdhpbsn8vz7a86nhkr7ra619j86z5p75amz61kfpw42z9";
+      type = "gem";
+    };
+    version = "3.2.2";
+  };
+  rexml = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1mkvkcw9fhpaizrhca0pdgjcrbns48rlz4g6lavl5gjjq3rk2sq3";
+      type = "gem";
+    };
+    version = "3.2.4";
+  };
+  tomlrb = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0ssyvjcvaisv70f21arlmnw5a1ryzmxzz4538vdwfslz9xxl27sr";
+      type = "gem";
+    };
+    version = "2.0.0";
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/micronucleus/default.nix b/nixpkgs/pkgs/development/tools/misc/micronucleus/default.nix
new file mode 100644
index 000000000000..d3bca0b684c7
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/micronucleus/default.nix
@@ -0,0 +1,35 @@
+{ stdenv
+, libusb-compat-0_1
+, fetchFromGitHub
+, lib
+}:
+stdenv.mkDerivation rec {
+  pname = "micronucleus";
+  version = "2.04";
+
+  sourceRoot = "source/commandline";
+
+  src = fetchFromGitHub {
+    owner = "micronucleus";
+    repo = "micronucleus";
+    rev = version;
+    sha256 = "14msy9amlbflw5mqrbs57b7bby3nsgx43srr7215zyhfdgsla0in";
+  };
+
+  buildInputs = [ libusb-compat-0_1 ];
+  makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
+
+  installPhase = ''
+    mkdir -p $out/bin
+    mkdir -p $out/lib/udev
+    cp micronucleus $out/bin
+    cp 49-micronucleus.rules $out/lib/udev
+  '';
+
+  meta = with lib; {
+    description = "Upload tool for micronucleus";
+    homepage = "https://github.com/micronucleus/micronucleus";
+    license = licenses.gpl3;
+    maintainers = [ maintainers.cab404 ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/mkcert/default.nix b/nixpkgs/pkgs/development/tools/misc/mkcert/default.nix
new file mode 100644
index 000000000000..0f110ae0b082
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/mkcert/default.nix
@@ -0,0 +1,28 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "mkcert";
+  version = "1.4.3";
+
+  src = fetchFromGitHub {
+    owner = "FiloSottile";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "0q0069ripnpb027krc4yk47552xl5rp0ymxf1j2mln9wdmfq65ba";
+  };
+
+  vendorSha256 = "133vlx825g4zay88ppylsz93q4gnd9ari12x1h57qvk45rwxqx95";
+
+  doCheck = false;
+
+  buildFlagsArray = ''
+    -ldflags=-s -w -X main.Version=v${version}
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/FiloSottile/mkcert";
+    description = "A simple tool for making locally-trusted development certificates";
+    license = licenses.bsd3;
+    maintainers = [ maintainers.marsam ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/msitools/default.nix b/nixpkgs/pkgs/development/tools/misc/msitools/default.nix
new file mode 100644
index 000000000000..ab196ebc5b34
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/msitools/default.nix
@@ -0,0 +1,87 @@
+{ lib
+, stdenv
+, fetchurl
+, fetchpatch
+, meson
+, ninja
+, vala
+, gobject-introspection
+, perl
+, bison
+, gettext
+, glib
+, pkg-config
+, libgsf
+, gcab
+, bzip2
+, gnome
+}:
+
+stdenv.mkDerivation rec {
+  pname = "msitools";
+  version = "0.101";
+
+  src = fetchurl {
+    url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
+    sha256 = "DMTS4NEI+m8rQIW5qX3VvG2fyt7N2TPyCU+Guv2+hf4=";
+  };
+
+  patches = [
+    # Fix executable bit on tools (regression in Meson migration).
+    (fetchpatch {
+      url = "https://gitlab.gnome.org/GNOME/msitools/commit/25c4353cf173cddeb76c0a2dd6621bcb753cabf8.patch";
+      sha256 = "VknfZCCn4jxwn9l9noXdGczv2kV+IbOsw9cNBE67P1U=";
+    })
+
+    # Fix failure on big-endian platforms.
+    # https://gitlab.gnome.org/GNOME/msitools/issues/31
+    (fetchpatch {
+      url = "https://gitlab.gnome.org/skitt/msitools/commit/3668c8288085d5beefae7c1387330ce9599b8365.patch";
+      sha256 = "x3Mp+9TRqBAJIdzVn68HyYt0lujyMk5h5xSBUQHe9Oo=";
+    })
+  ];
+
+  nativeBuildInputs = [
+    meson
+    ninja
+    vala
+    gobject-introspection
+    perl
+    bison
+    gettext
+    pkg-config
+  ];
+
+  buildInputs = [
+    glib
+    libgsf
+    gcab
+    bzip2
+  ];
+
+  doCheck = true;
+
+  postPatch = ''
+    patchShebangs subprojects/bats-core/{bin,libexec}
+  '';
+
+  passthru = {
+    updateScript = gnome.updateScript {
+      packageName = pname;
+      versionPolicy = "none";
+    };
+  };
+
+  meta = with lib; {
+    description = "Set of programs to inspect and build Windows Installer (.MSI) files";
+    homepage = "https://wiki.gnome.org/msitools";
+    license = with licenses; [
+      # Library
+      lgpl21Plus
+      # Tools
+      gpl2Plus
+    ];
+    maintainers = with maintainers; [ PlushBeaver ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/nimlsp/default.nix b/nixpkgs/pkgs/development/tools/misc/nimlsp/default.nix
new file mode 100644
index 000000000000..b1d59c9450ac
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/nimlsp/default.nix
@@ -0,0 +1,48 @@
+{ lib, stdenv, fetchFromGitHub, srcOnly, nim }:
+let
+  astpatternmatching = fetchFromGitHub {
+    owner = "krux02";
+    repo = "ast-pattern-matching";
+    rev = "87f7d163421af5a4f5e5cb6da7b93278e6897e96";
+    sha256 = "19mb5bb6riia8380p5dpc3q0vwgrj958dd6p7vw8vkvwiqrzg6zq";
+  };
+
+  jsonschema = fetchFromGitHub {
+    owner = "PMunch";
+    repo = "jsonschema";
+    rev = "7b41c03e3e1a487d5a8f6b940ca8e764dc2cbabf";
+    sha256 = "1js64jqd854yjladxvnylij4rsz7212k31ks541pqrdzm6hpblbz";
+  };
+in
+stdenv.mkDerivation rec {
+  pname = "nimlsp";
+  version = "0.3.2";
+
+  src = fetchFromGitHub {
+    owner = "PMunch";
+    repo = "nimlsp";
+    rev = "v${version}";
+    sha256 = "1lm823nvpp3bj9527jd8n1jxh6y8p8ngkfkj91p94m7ffai6jazq";
+  };
+
+  nativeBuildInputs = [ nim ];
+
+  buildPhase = ''
+    export HOME=$TMPDIR
+    nim -d:release -p:${astpatternmatching}/src -p:${jsonschema}/src \
+      c --threads:on -d:nimcore -d:nimsuggest -d:debugCommunication \
+      -d:debugLogging -d:explicitSourcePath=${srcOnly nim.passthru.nim} -d:tempDir=/tmp src/nimlsp
+  '';
+
+  installPhase = ''
+    install -Dt $out/bin src/nimlsp
+  '';
+
+  meta = with lib; {
+    description = "Language Server Protocol implementation for Nim";
+    homepage = "https://github.com/PMunch/nimlsp";
+    license = licenses.mit;
+    platforms = nim.meta.platforms;
+    maintainers = [ maintainers.marsam ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/ninka/default.nix b/nixpkgs/pkgs/development/tools/misc/ninka/default.nix
new file mode 100644
index 000000000000..8e8fb6bb5972
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ninka/default.nix
@@ -0,0 +1,36 @@
+{ lib, stdenv, fetchFromGitHub, perl, perlPackages }:
+
+assert stdenv ? glibc;
+
+perlPackages.buildPerlPackage {
+  pname = "ninka";
+  version = "2.0-pre";
+
+  src = fetchFromGitHub {
+    owner = "dmgerman";
+    repo = "ninka";
+    rev = "b89b59ecd057dfc939d0c75acaddebb58fcd8cba";
+    sha256 = "1grlis1kycbcjvjgqvn7aw81q1qx49ahvxg2k7cgyr79mvgpgi9m";
+  };
+
+  buildInputs = with perlPackages; [ perl TestOutput DBDSQLite DBI TestPod TestPodCoverage SpreadsheetParseExcel ];
+
+  doCheck = false;    # hangs
+
+  preConfigure = ''
+    sed -i.bak -e 's;#!/usr/bin/perl;#!${perl}/bin/perl;g' \
+        ./bin/ninka-excel ./bin/ninka ./bin/ninka-sqlite \
+        ./scripts/unify.pl ./scripts/parseLicense.pl \
+        ./scripts/license_matcher_modified.pl \
+        ./scripts/sort_package_license_list.pl
+    perl Makefile.PL
+  '';
+
+  meta = with lib; {
+    description = "A sentence based license detector";
+    homepage = "http://ninka.turingmachine.org/";
+    license = licenses.gpl2;
+    maintainers = [ maintainers.vrthra ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/nix-build-uncached/default.nix b/nixpkgs/pkgs/development/tools/misc/nix-build-uncached/default.nix
new file mode 100644
index 000000000000..7886c7c450ac
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/nix-build-uncached/default.nix
@@ -0,0 +1,27 @@
+{ lib, buildGoModule, fetchFromGitHub, makeWrapper }:
+
+buildGoModule rec {
+  pname = "nix-build-uncached";
+  version = "1.1.0";
+
+  src = fetchFromGitHub {
+    owner = "Mic92";
+    repo = "nix-build-uncached";
+    rev = "v${version}";
+    sha256 = "1v9xyv0hhvfw61k4pbgzrlgy7igl619cangi40fkh7gdvs01dxz4";
+  };
+
+  vendorSha256 = null;
+
+  doCheck = false;
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  meta = with lib; {
+    description = "A CI friendly wrapper around nix-build";
+    license = licenses.mit;
+    homepage = "https://github.com/Mic92/nix-build-uncached";
+    maintainers = [ maintainers.mic92 ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/nixbang/default.nix b/nixpkgs/pkgs/development/tools/misc/nixbang/default.nix
new file mode 100644
index 000000000000..468623241bfd
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/nixbang/default.nix
@@ -0,0 +1,22 @@
+{ lib, pythonPackages, fetchFromGitHub }:
+
+let version = "0.1.2"; in
+pythonPackages.buildPythonApplication {
+  pname = "nixbang";
+  inherit version;
+  namePrefix = "";
+
+  src = fetchFromGitHub {
+    owner = "madjar";
+    repo = "nixbang";
+    rev = version;
+    sha256 = "1kzk53ry60i814wa6n9y2ni0bcxhbi9p8gdv10b974gf23mhi8vc";
+  };
+
+  meta = {
+    homepage = "https://github.com/madjar/nixbang";
+    description = "A special shebang to run scripts in a nix-shell";
+    maintainers = [ lib.maintainers.madjar ];
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/nrfutil/default.nix b/nixpkgs/pkgs/development/tools/misc/nrfutil/default.nix
new file mode 100644
index 000000000000..acc8490b7c20
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/nrfutil/default.nix
@@ -0,0 +1,30 @@
+{ lib, python3Packages, fetchFromGitHub }:
+
+with python3Packages; buildPythonApplication rec {
+  pname = "nrfutil";
+  version = "6.1";
+
+  src = fetchFromGitHub {
+    owner = "NordicSemiconductor";
+    repo = "pc-nrfutil";
+    rev = "v${version}";
+    sha256 = "0g43lf5jmk0qxb7r4h68wr38fli6pjjk67w8l2cpdm9rd8jz4lpn";
+  };
+
+  propagatedBuildInputs = [ pc-ble-driver-py six pyserial enum34  click ecdsa
+    protobuf tqdm piccata pyspinel intelhex pyyaml crcmod libusb1 ipaddress ];
+
+  checkInputs = [ nose behave ];
+
+  postPatch = ''
+    mkdir test-reports
+  '';
+
+  meta = with lib; {
+    description = "Device Firmware Update tool for nRF chips";
+    homepage = "https://github.com/NordicSemiconductor/pc-nrfutil";
+    license = licenses.unfreeRedistributable;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ gebner ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/nxpmicro-mfgtools/default.nix b/nixpkgs/pkgs/development/tools/misc/nxpmicro-mfgtools/default.nix
new file mode 100644
index 000000000000..8b603fbc5ce5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/nxpmicro-mfgtools/default.nix
@@ -0,0 +1,54 @@
+{ lib, stdenv
+, fetchFromGitHub
+, cmake
+, pkg-config
+, bzip2
+, libusb1
+, libzip
+, openssl
+}:
+
+stdenv.mkDerivation rec {
+  pname = "nxpmicro-mfgtools";
+  version = "1.4.72";
+
+  src = fetchFromGitHub {
+    owner = "NXPmicro";
+    repo = "mfgtools";
+    rev = "uuu_${version}";
+    sha256 = "1s3wlz4yb2p8by5p66vr0z72n84mxkrmda63x9yr6pinqinsyrvv";
+  };
+
+  nativeBuildInputs = [ cmake pkg-config ];
+
+  buildInputs = [ bzip2 libusb1 libzip openssl ];
+
+  preConfigure = "echo ${version} > .tarball-version";
+
+  postInstall = ''
+    # rules printed by the following invocation are static,
+    # they come from hardcoded configs in libuuu/config.cpp:48
+    $out/bin/uuu -udev > udev-rules 2>stderr.txt
+    rules_file="$(cat stderr.txt|grep '1: put above udev run into'|sed 's|^.*/||')"
+    install -D udev-rules "$out/lib/udev/rules.d/$rules_file"
+  '';
+
+  meta = with lib; {
+    description = "Freescale/NXP I.MX chip image deploy tools";
+    longDescription = ''
+      UUU (Universal Update Utility) is a command line tool, evolved out of
+      MFGTools (aka MFGTools v3).
+
+      One of the main purposes is to upload images to I.MX SoC's using at least
+      their boot ROM.
+
+      With time, the need for an update utility portable to Linux and Windows
+      increased. UUU has the same usage on both Windows and Linux. It means the same
+      script works on both OS.
+    '';
+    homepage = "https://github.com/NXPmicro/mfgtools";
+    license = licenses.bsd3;
+    maintainers = [ maintainers.bmilanov ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/objconv/default.nix b/nixpkgs/pkgs/development/tools/misc/objconv/default.nix
new file mode 100644
index 000000000000..55147e9a16db
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/objconv/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv, fetchurl, unzip }:
+
+stdenv.mkDerivation rec {
+  pname = "objconv";
+  version = "2.52";
+
+  src = fetchurl {
+    # Versioned archive of objconv sources maintained by orivej.
+    url = "https://archive.org/download/objconv/${pname}-${version}.zip";
+    sha256 = "0r117r7yvqvvdgwgwxpkyzi6p5nm0xb6p67wvkmvggm9fdyl3z8v";
+  };
+
+  nativeBuildInputs = [ unzip ];
+
+  outputs = [ "out" "doc" ];
+
+  unpackPhase = ''
+    mkdir -p "$name"
+    cd "$name"
+    unpackFile "$src"
+    unpackFile source.zip
+  '';
+
+  buildPhase = "c++ -o objconv -O2 *.cpp";
+
+  installPhase = ''
+    mkdir -p $out/bin $out/doc/objconv
+    mv objconv $out/bin
+    mv objconv-instructions.pdf $out/doc/objconv
+  '';
+
+  meta = with lib; {
+    description = "Object and executable file converter, modifier and disassembler";
+    homepage = "https://www.agner.org/optimize/";
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ orivej vrthra ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile b/nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile
new file mode 100644
index 000000000000..bf4378d58ce2
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile
@@ -0,0 +1,2 @@
+source 'https://rubygems.org'
+gem 'one_gadget'
diff --git a/nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile.lock b/nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile.lock
new file mode 100644
index 000000000000..db20c8b0ffdc
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/one_gadget/Gemfile.lock
@@ -0,0 +1,17 @@
+GEM
+  remote: https://rubygems.org/
+  specs:
+    bindata (2.4.4)
+    elftools (1.1.0)
+      bindata (~> 2)
+    one_gadget (1.7.2)
+      elftools (>= 1.0.2, < 1.2.0)
+
+PLATFORMS
+  ruby
+
+DEPENDENCIES
+  one_gadget
+
+BUNDLED WITH
+   2.1.4
diff --git a/nixpkgs/pkgs/development/tools/misc/one_gadget/default.nix b/nixpkgs/pkgs/development/tools/misc/one_gadget/default.nix
new file mode 100644
index 000000000000..c3d0a6b57b45
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/one_gadget/default.nix
@@ -0,0 +1,17 @@
+{ lib, bundlerApp, bundlerUpdateScript }:
+
+bundlerApp {
+  pname = "one_gadget";
+  gemdir = ./.;
+  exes = [ "one_gadget" ];
+
+  passthru.updateScript = bundlerUpdateScript "one_gadget";
+
+  meta = with lib; {
+    description = "The best tool for finding one gadget RCE in libc.so.6";
+    homepage    = "https://github.com/david942j/one_gadget";
+    license     = licenses.mit;
+    maintainers = with maintainers; [ artemist nicknovitski ];
+    platforms   = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/one_gadget/gemset.nix b/nixpkgs/pkgs/development/tools/misc/one_gadget/gemset.nix
new file mode 100644
index 000000000000..89425f805b43
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/one_gadget/gemset.nix
@@ -0,0 +1,34 @@
+{
+  bindata = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0kz42nvxnk1j9cj0i8lcnhprcgdqsqska92g6l19ziadydfk2gqy";
+      type = "gem";
+    };
+    version = "2.4.4";
+  };
+  elftools = {
+    dependencies = ["bindata"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0kdf0ck4rzxpd006y09rfwppdrqb3sxww4gzfpv2053yq4mkimbn";
+      type = "gem";
+    };
+    version = "1.1.0";
+  };
+  one_gadget = {
+    dependencies = ["elftools"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "07s2nigjw1yik895gliz3a7ps0m9j5nccq82zwdd30sv740jmf5b";
+      type = "gem";
+    };
+    version = "1.7.2";
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/openfpgaloader/default.nix b/nixpkgs/pkgs/development/tools/misc/openfpgaloader/default.nix
new file mode 100644
index 000000000000..1e3b3469dca3
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/openfpgaloader/default.nix
@@ -0,0 +1,36 @@
+{ stdenv
+, lib
+, fetchFromGitHub
+, cmake
+, pkg-config
+, libftdi1
+, libusb1
+, udev
+}:
+
+stdenv.mkDerivation rec {
+  pname = "openfpgaloader";
+  version = "0.2.6";
+
+  src = fetchFromGitHub {
+    owner = "trabucayre";
+    repo = "openFPGALoader";
+    rev = "v${version}";
+    sha256 = "sha256-OWRMWNOPm6flgeTKYWYE+LcG3HW6i8s2NQ1dr/oeOEw=";
+  };
+
+  nativeBuildInputs = [ cmake pkg-config ];
+
+  buildInputs = [
+    libftdi1
+    libusb1
+    udev
+  ];
+
+  meta = with lib; {
+    description = "Universal utility for programming FPGAs";
+    homepage = "https://github.com/trabucayre/openFPGALoader";
+    license = licenses.agpl3Only;
+    maintainers = with maintainers; [ danderson ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/opengrok/default.nix b/nixpkgs/pkgs/development/tools/misc/opengrok/default.nix
new file mode 100644
index 000000000000..0a2bbc30fb52
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/opengrok/default.nix
@@ -0,0 +1,32 @@
+{ lib, stdenv, fetchurl, jre, ctags, makeWrapper, coreutils, git, runtimeShell }:
+
+stdenv.mkDerivation rec {
+  pname = "opengrok";
+  version = "1.0";
+
+  # binary distribution
+  src = fetchurl {
+    url = "https://github.com/oracle/opengrok/releases/download/${version}/${pname}-${version}.tar.gz";
+    sha256 = "0h4rwfh8m41b7ij931gcbmkihri25m48373qf6ig0714s66xwc4i";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  installPhase = ''
+    mkdir -p $out
+    cp -a * $out/
+    substituteInPlace $out/bin/OpenGrok --replace "/bin/uname" "${coreutils}/bin/uname"
+    substituteInPlace $out/bin/Messages --replace "#!/bin/ksh" "#!${runtimeShell}"
+    wrapProgram $out/bin/OpenGrok \
+      --prefix PATH : "${lib.makeBinPath [ ctags git ]}" \
+      --set JAVA_HOME "${jre}" \
+      --set OPENGROK_TOMCAT_BASE "/var/tomcat"
+  '';
+
+  meta = with lib; {
+    description = "Source code search and cross reference engine";
+    homepage = "https://opengrok.github.io/OpenGrok/";
+    license = licenses.cddl;
+    maintainers = [ ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/openocd/default.nix b/nixpkgs/pkgs/development/tools/misc/openocd/default.nix
new file mode 100644
index 000000000000..7b3a16fb75e4
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/openocd/default.nix
@@ -0,0 +1,66 @@
+{ stdenv
+, lib
+, fetchurl
+, pkg-config
+, hidapi
+, libftdi1
+, libusb1
+}:
+
+stdenv.mkDerivation rec {
+  pname = "openocd";
+  version = "0.11.0";
+  src = fetchurl {
+    url = "mirror://sourceforge/project/${pname}/${pname}/${version}/${pname}-${version}.tar.bz2";
+    sha256 = "0z8y7mmv0mhn2l5gs3vz6l7cnwak7agklyc7ml33f7gz99rwx8s3";
+  };
+
+  nativeBuildInputs = [ pkg-config ];
+
+  buildInputs = [ hidapi libftdi1 libusb1 ];
+
+  configureFlags = [
+    "--enable-jtag_vpi"
+    "--enable-usb_blaster_libftdi"
+    (lib.enableFeature (! stdenv.isDarwin) "amtjtagaccel")
+    (lib.enableFeature (! stdenv.isDarwin) "gw16012")
+    "--enable-presto_libftdi"
+    "--enable-openjtag_ftdi"
+    (lib.enableFeature (! stdenv.isDarwin) "oocd_trace")
+    "--enable-buspirate"
+    (lib.enableFeature stdenv.isLinux "sysfsgpio")
+    "--enable-remote-bitbang"
+  ];
+
+  NIX_CFLAGS_COMPILE = lib.optionals stdenv.cc.isGNU [
+    "-Wno-error=cpp"
+    "-Wno-error=strict-prototypes" # fixes build failure with hidapi 0.10.0
+  ];
+
+  postInstall = lib.optionalString stdenv.isLinux ''
+    mkdir -p "$out/etc/udev/rules.d"
+    rules="$out/share/openocd/contrib/60-openocd.rules"
+    if [ ! -f "$rules" ]; then
+        echo "$rules is missing, must update the Nix file."
+        exit 1
+    fi
+    ln -s "$rules" "$out/etc/udev/rules.d/"
+  '';
+
+  meta = with lib; {
+    description = "Free and Open On-Chip Debugging, In-System Programming and Boundary-Scan Testing";
+    longDescription = ''
+      OpenOCD provides on-chip programming and debugging support with a layered
+      architecture of JTAG interface and TAP support, debug target support
+      (e.g. ARM, MIPS), and flash chip drivers (e.g. CFI, NAND, etc.).  Several
+      network interfaces are available for interactiving with OpenOCD: HTTP,
+      telnet, TCL, and GDB.  The GDB server enables OpenOCD to function as a
+      "remote target" for source-level debugging of embedded systems using the
+      GNU GDB program.
+    '';
+    homepage = "https://openocd.sourceforge.net/";
+    license = licenses.gpl2Plus;
+    maintainers = with maintainers; [ bjornfor prusnak ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/pahole/default.nix b/nixpkgs/pkgs/development/tools/misc/pahole/default.nix
new file mode 100644
index 000000000000..86e1dac021c2
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pahole/default.nix
@@ -0,0 +1,27 @@
+{ lib, stdenv, fetchgit, cmake, elfutils, zlib }:
+
+stdenv.mkDerivation rec {
+  pname = "pahole";
+  version = "1.20";
+  src = fetchgit {
+    url = "https://git.kernel.org/pub/scm/devel/pahole/pahole.git";
+    rev = "v${version}";
+    sha256 = "11q9dpfi4qj2v8z0nlf8c0079mlv10ljhh0d1yr0j4ds3saacd15";
+    fetchSubmodules = true;
+  };
+
+  nativeBuildInputs = [ cmake ];
+  buildInputs = [ elfutils zlib ];
+
+  # Put libraries in "lib" subdirectory, not top level of $out
+  cmakeFlags = [ "-D__LIB=lib" ];
+
+  meta = with lib; {
+    homepage = "https://git.kernel.org/cgit/devel/pahole/pahole.git/";
+    description = "Pahole and other DWARF utils";
+    license = licenses.gpl2Only;
+
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bosu ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/patchelf/0.9.nix b/nixpkgs/pkgs/development/tools/misc/patchelf/0.9.nix
new file mode 100644
index 000000000000..c64d722ca711
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/patchelf/0.9.nix
@@ -0,0 +1,16 @@
+{ stdenv, fetchurl, patchelf }:
+
+stdenv.mkDerivation rec {
+  name = "patchelf-0.9";
+
+  src = fetchurl {
+    url = "https://nixos.org/releases/patchelf/${name}/${name}.tar.bz2";
+    sha256 = "a0f65c1ba148890e9f2f7823f4bedf7ecad5417772f64f994004f59a39014f83";
+  };
+
+  setupHook = [ ./setup-hook.sh ];
+
+  doCheck = false; # fails 8 out of 24 tests, problems when loading libc.so.6
+
+  inherit (patchelf) meta;
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/patchelf/default.nix b/nixpkgs/pkgs/development/tools/misc/patchelf/default.nix
new file mode 100644
index 000000000000..a0c002d8a8c5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/patchelf/default.nix
@@ -0,0 +1,29 @@
+{ lib, stdenv, fetchurl }:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+stdenv.mkDerivation rec {
+  pname = "patchelf";
+  version = "0.12";
+
+  src = fetchurl {
+    url = "https://github.com/NixOS/${pname}/releases/download/${version}/${pname}-${version}.tar.bz2";
+    sha256 = "14npmdxppmh0ci140w8i8cy7zg1pnqg81a1mdsnza711ab7k36k9";
+  };
+
+  setupHook = [ ./setup-hook.sh ];
+
+  # fails 8 out of 24 tests, problems when loading libc.so.6
+  doCheck = stdenv.name == "stdenv-linux";
+
+  meta = with lib; {
+    homepage = "https://github.com/NixOS/patchelf/blob/master/README";
+    license = licenses.gpl3;
+    description = "A small utility to modify the dynamic linker and RPATH of ELF executables";
+    maintainers = [ maintainers.eelco ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/patchelf/setup-hook.sh b/nixpkgs/pkgs/development/tools/misc/patchelf/setup-hook.sh
new file mode 100644
index 000000000000..576b9ca2103e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/patchelf/setup-hook.sh
@@ -0,0 +1,22 @@
+# This setup hook calls patchelf to automatically remove unneeded
+# directories from the RPATH of every library or executable in every
+# output.
+
+fixupOutputHooks+=('if [ -z "${dontPatchELF-}" ]; then patchELF "$prefix"; fi')
+
+patchELF() {
+    local dir="$1"
+    [ -e "$dir" ] || return 0
+
+    header "shrinking RPATHs of ELF executables and libraries in $dir"
+
+    local i
+    while IFS= read -r -d $'\0' i; do
+        if [[ "$i" =~ .build-id ]]; then continue; fi
+        if ! isELF "$i"; then continue; fi
+        echo "shrinking $i"
+        patchelf --shrink-rpath "$i" || true
+    done < <(find "$dir" -type f -print0)
+
+    stopNest
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/patchelf/unstable.nix b/nixpkgs/pkgs/development/tools/misc/patchelf/unstable.nix
new file mode 100644
index 000000000000..1d790740e697
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/patchelf/unstable.nix
@@ -0,0 +1,34 @@
+{ lib, stdenv, fetchurl, autoreconfHook, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  name = "patchelf-${version}";
+  version = "2020-07-11";
+
+  src = fetchFromGitHub {
+    owner = "NixOS";
+    repo = "patchelf";
+    rev = "126372b636733b160e693c9913e871f6755c02e";
+    sha256 = "07cn40ypys5pyc3jfgxvqj7qk5v6m2rr5brnpmxdsl1557ryx226";
+  };
+
+  # Drop test that fails on musl (?)
+  postPatch = lib.optionalString stdenv.hostPlatform.isMusl ''
+    substituteInPlace tests/Makefile.am \
+      --replace "set-rpath-library.sh" ""
+  '';
+
+  setupHook = [ ./setup-hook.sh ];
+
+  nativeBuildInputs = [ autoreconfHook ];
+  buildInputs = [ ];
+
+  doCheck = !stdenv.isDarwin;
+
+  meta = with lib; {
+    homepage = "https://github.com/NixOS/patchelf/blob/master/README";
+    license = licenses.gpl3;
+    description = "A small utility to modify the dynamic linker and RPATH of ELF executables";
+    maintainers = [ maintainers.eelco ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/perfect-hash/default.nix b/nixpkgs/pkgs/development/tools/misc/perfect-hash/default.nix
new file mode 100644
index 000000000000..71747f0d1172
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/perfect-hash/default.nix
@@ -0,0 +1,35 @@
+{ lib, python3, fetchFromGitHub }:
+python3.pkgs.buildPythonApplication rec {
+  pname = "perfect-hash";
+  version = "0.4.1";
+
+  # Archive on pypi does not contain examples, which are very helpful to
+  # understand how to use this program, so we use git source.
+  src = fetchFromGitHub {
+    owner = "ilanschnell";
+    repo = "perfect-hash";
+    rev = version;
+    sha256 = "0gkc3n613hl0q4jknrh2nm1n96j97p36q9jjgarb9d8yii9q7792";
+  };
+
+  postInstall = ''
+    mkdir -p $out/share/doc/perfect-hash
+    cp README.md $out/share/doc/perfect-hash
+    cp -r examples $out/share/doc/perfect-hash
+  '';
+
+  meta = with lib; {
+    description = "Minimal perfect hash function generator";
+    longDescription = ''
+      Generate a minimal perfect hash function for a given set of keys.
+      A given code template is filled with parameters, such that the
+      output is code which implements the hash function. Templates can
+      easily be constructed for any programming language.
+    '';
+    license = licenses.bsd3;
+    maintainers = [ maintainers.kaction ];
+
+    homepage = "https://github.com/ilanschnell/perfect-hash";
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/pkg-config/2.36.3-not-win32.patch b/nixpkgs/pkgs/development/tools/misc/pkg-config/2.36.3-not-win32.patch
new file mode 100644
index 000000000000..c1dd808e6008
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pkg-config/2.36.3-not-win32.patch
@@ -0,0 +1,324 @@
+--- a/glib/configure.ac	2013-08-04 20:21:20.808722600 -0500
++++ b/glib/configure.ac	2013-08-04 18:30:21.852852200 -0500
+@@ -1880,7 +1880,7 @@ dnl ************************************
+ 
+ AC_MSG_CHECKING(for platform-dependent source)
+ case "$host" in
+-  *-*-cygwin*|*-*-mingw*)
++  *-*-mingw*)
+     PLATFORMDEP=gwin32.lo
+     ;;
+   *)
+@@ -2594,9 +2594,6 @@ dnl *** Win32 API libs ***
+ dnl **********************
+ 
+ case $host in
+-  *-*-cygwin*)
+-	G_LIBS_EXTRA="-luser32 -lkernel32"
+-    ;;
+   *-*-mingw*)
+ 	G_LIBS_EXTRA="-lws2_32 -lole32 -lwinmm -lshlwapi"
+     ;;
+--- a/glib/glib/gatomic.c	2013-08-04 20:21:20.907728300 -0500
++++ b/glib/glib/gatomic.c	2013-08-04 18:11:14.000000000 -0500
+@@ -464,7 +464,7 @@ gsize
+   return g_atomic_pointer_xor ((volatile gpointer *) atomic, val);
+ }
+ 
+-#elif defined (G_PLATFORM_WIN32)
++#elif defined (G_OS_WIN32)
+ 
+ #include <windows.h>
+ #if !defined(_M_AMD64) && !defined (_M_IA64) && !defined(_M_X64) && !(defined _MSC_VER && _MSC_VER <= 1200)
+--- a/glib/glib/gcharset.c	2013-08-04 20:21:20.925729300 -0500
++++ b/glib/glib/gcharset.c	2013-08-04 18:11:14.000000000 -0500
+@@ -496,7 +496,7 @@ guess_category_value (const gchar *categ
+   if ((retval != NULL) && (retval[0] != '\0'))
+     return retval;
+ 
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+   /* g_win32_getlocale() first checks for LC_ALL, LC_MESSAGES and
+    * LANG, which we already did above. Oh well. The main point of
+    * calling g_win32_getlocale() is to get the thread's locale as used
+--- a/glib/glib/gconvert.c	2013-08-04 20:21:20.933729800 -0500
++++ b/glib/glib/gconvert.c	2013-08-04 18:11:14.000000000 -0500
+@@ -33,9 +33,6 @@
+ 
+ #ifdef G_OS_WIN32
+ #include "win_iconv.c"
+-#endif
+-
+-#ifdef G_PLATFORM_WIN32
+ #define STRICT
+ #include <windows.h>
+ #undef STRICT
+@@ -1258,7 +1255,7 @@ g_locale_from_utf8 (const gchar *utf8str
+ 		      charset, "UTF-8", bytes_read, bytes_written, error);
+ }
+ 
+-#ifndef G_PLATFORM_WIN32
++#ifndef G_OS_WIN32
+ 
+ typedef struct _GFilenameCharsetCache GFilenameCharsetCache;
+ 
+@@ -1374,7 +1371,7 @@ g_get_filename_charsets (const gchar ***
+   return cache->is_utf8;
+ }
+ 
+-#else /* G_PLATFORM_WIN32 */
++#else /* G_OS_WIN32 */
+ 
+ gboolean
+ g_get_filename_charsets (const gchar ***filename_charsets) 
+@@ -1403,7 +1400,7 @@ g_get_filename_charsets (const gchar ***
+ #endif
+ }
+ 
+-#endif /* G_PLATFORM_WIN32 */
++#endif /* G_OS_WIN32 */
+ 
+ static gboolean
+ get_filename_charset (const gchar **filename_charset)
+--- a/glib/glib/gfileutils.c	2013-08-04 20:21:20.942730300 -0500
++++ b/glib/glib/gfileutils.c	2013-08-04 18:11:14.000000000 -0500
+@@ -2153,7 +2153,7 @@ g_path_skip_root (const gchar *file_name
+ {
+   g_return_val_if_fail (file_name != NULL, NULL);
+ 
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+   /* Skip \\server\share or //server/share */
+   if (G_IS_DIR_SEPARATOR (file_name[0]) &&
+       G_IS_DIR_SEPARATOR (file_name[1]) &&
+@@ -2163,7 +2163,6 @@ g_path_skip_root (const gchar *file_name
+       gchar *p;
+       p = strchr (file_name + 2, G_DIR_SEPARATOR);
+ 
+-#ifdef G_OS_WIN32
+       {
+         gchar *q;
+ 
+@@ -2171,7 +2170,6 @@ g_path_skip_root (const gchar *file_name
+         if (p == NULL || (q != NULL && q < p))
+         p = q;
+       }
+-#endif
+ 
+       if (p && p > file_name + 2 && p[1])
+         {
+--- a/glib/glib/glib.h	2013-08-04 20:21:20.949730700 -0500
++++ b/glib/glib/glib.h	2013-08-04 18:11:14.000000000 -0500
+@@ -96,7 +96,7 @@
+ #include <glib/gvariant.h>
+ #include <glib/gversion.h>
+ #include <glib/gversionmacros.h>
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+ #include <glib/gwin32.h>
+ #endif
+ 
+--- a/glib/glib/gutf8.c	2013-08-04 20:21:20.984732700 -0500
++++ b/glib/glib/gutf8.c	2013-08-04 18:11:14.000000000 -0500
+@@ -27,7 +27,7 @@
+ #endif
+ #include <string.h>
+ 
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+ #include <stdio.h>
+ #define STRICT
+ #include <windows.h>
+--- a/glib/glib/gutils.c	2013-08-04 20:21:21.015734500 -0500
++++ b/glib/glib/gutils.c	2013-08-04 18:11:14.000000000 -0500
+@@ -72,7 +72,7 @@
+ #include "garray.h"
+ #include "glibintl.h"
+ 
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+ #include "gconvert.h"
+ #include "gwin32.h"
+ #endif
+@@ -86,16 +86,13 @@
+  * These are portable utility functions.
+  */
+ 
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+ #  include <windows.h>
+ #  ifndef GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS
+ #    define GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT 2
+ #    define GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS 4
+ #  endif
+ #  include <lmcons.h>		/* For UNLEN */
+-#endif /* G_PLATFORM_WIN32 */
+-
+-#ifdef G_OS_WIN32
+ #  include <direct.h>
+ #  include <shlobj.h>
+    /* older SDK (e.g. msvc 5.0) does not have these*/
+@@ -131,7 +128,7 @@
+ #include <langinfo.h>
+ #endif
+ 
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+ 
+ gchar *
+ _glib_get_dll_directory (void)
+--- a/glib/glib/gutils.h	2013-08-04 20:21:21.067737500 -0500
++++ b/glib/glib/gutils.h	2013-08-04 18:11:14.000000000 -0500
+@@ -350,7 +350,7 @@ g_bit_storage (gulong number)
+  * On non-Windows platforms, expands to nothing.
+  */
+ 
+-#ifndef G_PLATFORM_WIN32
++#ifndef G_OS_WIN32
+ # define G_WIN32_DLLMAIN_FOR_DLL_NAME(static, dll_name)
+ #else
+ # define G_WIN32_DLLMAIN_FOR_DLL_NAME(static, dll_name)			\
+@@ -378,7 +378,7 @@ DllMain (HINSTANCE hinstDLL,						\
+ 
+ #endif	/* !G_DISABLE_DEPRECATED */
+ 
+-#endif /* G_PLATFORM_WIN32 */
++#endif /* G_OS_WIN32 */
+ 
+ G_END_DECLS
+ 
+--- a/glib/glib/gwin32.h	2013-08-04 20:21:21.081738300 -0500
++++ b/glib/glib/gwin32.h	2013-08-04 18:11:14.000000000 -0500
+@@ -33,7 +33,7 @@
+ 
+ #include <glib/gtypes.h>
+ 
+-#ifdef G_PLATFORM_WIN32
++#ifdef G_OS_WIN32
+ 
+ G_BEGIN_DECLS
+ 
+@@ -41,8 +41,6 @@ G_BEGIN_DECLS
+ #define MAXPATHLEN 1024
+ #endif
+ 
+-#ifdef G_OS_WIN32
+-
+ /*
+  * To get prototypes for the following POSIXish functions, you have to
+  * include the indicated non-POSIX headers. The functions are defined
+@@ -68,7 +66,6 @@ G_BEGIN_DECLS
+ GLIB_AVAILABLE_IN_ALL
+ gint		g_win32_ftruncate	(gint		 f,
+ 					 guint		 size);
+-#endif /* G_OS_WIN32 */
+ 
+ /* The MS setlocale uses locale names of the form "English_United
+  * States.1252" etc. We want the Unixish standard form "en", "zh_TW"
+@@ -112,7 +109,7 @@ gchar*          g_win32_locale_filename_
+ 
+ G_END_DECLS
+ 
+-#endif	 /* G_PLATFORM_WIN32 */
++#endif	 /* G_OS_WIN32 */
+ 
+ #ifdef G_OS_WIN32
+ #ifdef _WIN64
+--- a/glib/glib/libcharset/localcharset.c	2013-08-04 20:21:21.095739100 -0500
++++ b/glib/glib/libcharset/localcharset.c	2013-08-04 18:11:14.000000000 -0500
+@@ -46,10 +46,6 @@
+ #   include <locale.h>
+ #  endif
+ # endif
+-# ifdef __CYGWIN__
+-#  define WIN32_LEAN_AND_MEAN
+-#  include <windows.h>
+-# endif
+ #elif defined WIN32_NATIVE
+ # define WIN32_LEAN_AND_MEAN
+ # include <windows.h>
+@@ -111,7 +107,7 @@ _g_locale_get_charset_aliases (void)
+   cp = charset_aliases;
+   if (cp == NULL)
+     {
+-#if !(defined VMS || defined WIN32_NATIVE || defined __CYGWIN__)
++#if !(defined VMS || defined WIN32_NATIVE)
+       FILE *fp;
+       const char *dir;
+       const char *base = "charset.alias";
+@@ -237,7 +233,7 @@ _g_locale_get_charset_aliases (void)
+ 	   "DECKOREAN" "\0" "EUC-KR" "\0";
+ # endif
+ 
+-# if defined WIN32_NATIVE || defined __CYGWIN__
++# if defined WIN32_NATIVE
+       /* To avoid the troubles of installing a separate file in the same
+ 	 directory as the DLL and of retrieving the DLL's directory at
+ 	 runtime, simply inline the aliases here.  */
+@@ -292,53 +288,6 @@ _g_locale_charset_raw (void)
+   /* Most systems support nl_langinfo (CODESET) nowadays.  */
+   codeset = nl_langinfo (CODESET);
+ 
+-#  ifdef __CYGWIN__
+-  /* Cygwin 2006 does not have locales.  nl_langinfo (CODESET) always
+-     returns "US-ASCII".  As long as this is not fixed, return the suffix
+-     of the locale name from the environment variables (if present) or
+-     the codepage as a number.  */
+-  if (codeset != NULL && strcmp (codeset, "US-ASCII") == 0)
+-    {
+-      const char *locale;
+-      static char buf[2 + 10 + 1];
+-
+-      locale = getenv ("LC_ALL");
+-      if (locale == NULL || locale[0] == '\0')
+-	{
+-	  locale = getenv ("LC_CTYPE");
+-	  if (locale == NULL || locale[0] == '\0')
+-	    locale = getenv ("LANG");
+-	}
+-      if (locale != NULL && locale[0] != '\0')
+-	{
+-	  /* If the locale name contains an encoding after the dot, return
+-	     it.  */
+-	  const char *dot = strchr (locale, '.');
+-
+-	  if (dot != NULL)
+-	    {
+-	      const char *modifier;
+-
+-	      dot++;
+-	      /* Look for the possible @... trailer and remove it, if any.  */
+-	      modifier = strchr (dot, '@');
+-	      if (modifier == NULL)
+-		return dot;
+-	      if (modifier - dot < sizeof (buf))
+-		{
+-		  memcpy (buf, dot, modifier - dot);
+-		  buf [modifier - dot] = '\0';
+-		  return buf;
+-		}
+-	    }
+-	}
+-
+-      /* Woe32 has a function returning the locale's codepage as a number.  */
+-      sprintf (buf, "CP%u", GetACP ());
+-      codeset = buf;
+-    }
+-#  endif
+-
+ # else
+ 
+   /* On old systems which lack it, use setlocale or getenv.  */
+diff --git a/glib/gtypes.h b/glib/gtypes.h
+index c18e0bf..816685a 100644
+--- a/glib/glib/gtypes.h
++++ b/glib/glib/gtypes.h
+@@ -462,7 +462,7 @@ G_END_DECLS
+  * properly get exported in Windows DLLs.
+  */
+ #ifndef GLIB_VAR
+-#  ifdef G_PLATFORM_WIN32
++#  ifdef G_OS_WIN32
+ #    ifdef GLIB_STATIC_COMPILATION
+ #      define GLIB_VAR extern
+ #    else /* !GLIB_STATIC_COMPILATION */
diff --git a/nixpkgs/pkgs/development/tools/misc/pkg-config/default.nix b/nixpkgs/pkgs/development/tools/misc/pkg-config/default.nix
new file mode 100644
index 000000000000..b0b3115700fb
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pkg-config/default.nix
@@ -0,0 +1,50 @@
+{ lib, stdenv, fetchurl, libiconv, vanilla ? false }:
+
+with lib;
+
+stdenv.mkDerivation rec {
+  pname = "pkg-config";
+  version = "0.29.2";
+
+  src = fetchurl {
+    url = "https://pkg-config.freedesktop.org/releases/${pname}-${version}.tar.gz";
+    sha256 = "14fmwzki1rlz8bs2p810lk6jqdxsk966d8drgsjmi54cd00rrikg";
+  };
+
+  outputs = [ "out" "man" "doc" ];
+
+  # Process Requires.private properly, see
+  # http://bugs.freedesktop.org/show_bug.cgi?id=4738, migrated to
+  # https://gitlab.freedesktop.org/pkg-config/pkg-config/issues/28
+  patches = optional (!vanilla) ./requires-private.patch
+    ++ optional stdenv.isCygwin ./2.36.3-not-win32.patch;
+
+  # These three tests fail due to a (desired) behavior change from our ./requires-private.patch
+  postPatch = if vanilla then null else ''
+    rm -f check/check-requires-private check/check-gtk check/missing
+  '';
+
+  buildInputs = optional (stdenv.isCygwin || stdenv.isDarwin || stdenv.isSunOS) libiconv;
+
+  configureFlags = [ "--with-internal-glib" ]
+    ++ optional (stdenv.isSunOS) [ "--with-libiconv=gnu" "--with-system-library-path" "--with-system-include-path" "CFLAGS=-DENABLE_NLS" ]
+       # Can't run these tests while cross-compiling
+    ++ optional (stdenv.hostPlatform != stdenv.buildPlatform)
+       [ "glib_cv_stack_grows=no"
+         "glib_cv_uscore=no"
+         "ac_cv_func_posix_getpwuid_r=yes"
+         "ac_cv_func_posix_getgrgid_r=yes"
+       ];
+
+  enableParallelBuilding = true;
+  doCheck = true;
+
+  postInstall = ''rm -f "$out"/bin/*-pkg-config''; # clean the duplicate file
+
+  meta = {
+    description = "A tool that allows packages to find out information about other packages";
+    homepage = "http://pkg-config.freedesktop.org/wiki/";
+    platforms = platforms.all;
+    license = licenses.gpl2Plus;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/pkg-config/requires-private.patch b/nixpkgs/pkgs/development/tools/misc/pkg-config/requires-private.patch
new file mode 100644
index 000000000000..d40aa9801379
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pkg-config/requires-private.patch
@@ -0,0 +1,17 @@
+diff --git a/main.c b/main.c
+index b61ca34..5a420c2 100644
+--- a/main.c
++++ b/main.c
+@@ -602,10 +602,10 @@ main (int argc, char **argv)
+   else
+     disable_private_libs();
+ 
+-  /* honor Requires.private if any Cflags are requested or any static
++  /* honor Requires.private if any any static
+    * libs are requested */
+ 
+-  if (pkg_flags & CFLAGS_ANY || want_requires_private || want_exists ||
++  if (want_requires_private ||
+       (want_static_lib_list && (pkg_flags & LIBS_ANY)))
+     enable_requires_private();
+ 
diff --git a/nixpkgs/pkgs/development/tools/misc/pkgconf/default.nix b/nixpkgs/pkgs/development/tools/misc/pkgconf/default.nix
new file mode 100644
index 000000000000..2c55a6f03a7f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pkgconf/default.nix
@@ -0,0 +1,46 @@
+{ lib, stdenv, fetchurl, removeReferencesTo }:
+
+stdenv.mkDerivation rec {
+  pname = "pkgconf";
+  version = "1.7.4";
+
+  nativeBuildInputs = [ removeReferencesTo ];
+
+  outputs = [ "out" "lib" "dev" "man" "doc" ];
+
+  enableParallelBuilding = true;
+
+  src = fetchurl {
+    url = "https://distfiles.dereferenced.org/${pname}/${pname}-${version}.tar.xz";
+    sha256 = "sha256-1z8ywkikWRE5prF3d8gNTeq2tBTsKz0h0KJL40jEdqs=";
+  };
+
+  # Debian has outputs like these too:
+  # https://packages.debian.org/source/buster/pkgconf, so take it this
+  # reference removing is safe.
+  postFixup = ''
+    remove-references-to \
+      -t "${placeholder "dev"}" \
+      "${placeholder "lib"}"/lib/* \
+      "${placeholder "out"}"/bin/*
+    remove-references-to \
+      -t "${placeholder "out"}" \
+      "${placeholder "lib"}"/lib/*
+  ''
+  # Move back share/aclocal. Yes, this normally goes in the dev output for good
+  # reason, but in this case the dev output is for the `libpkgconf` library,
+  # while the aclocal stuff is for the tool. The tool is already for use during
+  # development, so there is no reason to have separate "dev-bin" and "dev-lib"
+  # outputs or someting.
+  + ''
+    mv ${placeholder "dev"}/share ${placeholder "out"}
+  '';
+
+  meta = with lib; {
+    description = "Package compiler and linker metadata toolkit";
+    homepage = "https://git.dereferenced.org/pkgconf/pkgconf";
+    platforms = platforms.all;
+    license = licenses.isc;
+    maintainers = with maintainers; [ zaninime ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/pmccabe/default.nix b/nixpkgs/pkgs/development/tools/misc/pmccabe/default.nix
new file mode 100644
index 000000000000..1fd58fd14a2f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pmccabe/default.nix
@@ -0,0 +1,48 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  pname = "pmccabe";
+  version = "2.6";
+
+  src = fetchurl {
+    url = "http://http.debian.net/debian/pool/main/p/pmccabe/pmccabe_${version}.tar.gz";
+    sha256 = "0a3h1b9fb87c82d5fbql5lc4gp338pa5s9i66dhw7zk8jdygx474";
+  };
+
+  patches = [
+    ./getopt_on_darwin.patch
+  ];
+
+  configurePhase = ''
+    sed -i -r Makefile \
+      -e 's,/usr/,/,g' \
+      -e "s,^DESTDIR =.*$,DESTDIR = $out," \
+      -e "s,^INSTALL = install.*$,INSTALL = install," \
+      -e "s,^all:.*$,all: \$(PROGS),"
+    '';
+
+  checkPhase = "make test";
+
+  doCheck = true;
+
+  meta = with lib; {
+    description = "McCabe-style function complexity and line counting for C and C++";
+    homepage = "https://people.debian.org/~bame/pmccabe/";
+    license = licenses.gpl2Plus;
+
+    longDescription = ''
+      pmccabe calculates McCabe-style cyclomatic complexity for C and
+      C++ source code.  Per-function complexity may be used for
+      spotting likely trouble spots and for estimating testing
+      effort.
+
+      pmccabe also includes a non-commented line counter, decomment which
+      only removes comments from source code; codechanges, a program to
+      calculate the amount of change which has occurred between two source
+      trees or files; and vifn, to invoke vi given a function name rather
+      than a file name.
+    '';
+    maintainers = with maintainers; [ peterhoeg ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/pmccabe/getopt_on_darwin.patch b/nixpkgs/pkgs/development/tools/misc/pmccabe/getopt_on_darwin.patch
new file mode 100644
index 000000000000..534d6c1d6ef7
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pmccabe/getopt_on_darwin.patch
@@ -0,0 +1,15 @@
+diff --git a/decomment.c b/decomment.c
+index 400707a..aea29fd 100644
+--- a/decomment.c
++++ b/decomment.c
+@@ -11,6 +11,10 @@
+ #include "getopt.h"
+ #endif
+ 
++#ifdef __APPLE__
++#include "getopt.h"
++#endif
++
+ #ifdef NEED_OPTIND
+ extern int optind;
+ #endif
diff --git a/nixpkgs/pkgs/development/tools/misc/polylith/default.nix b/nixpkgs/pkgs/development/tools/misc/polylith/default.nix
new file mode 100644
index 000000000000..b29b2521d170
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/polylith/default.nix
@@ -0,0 +1,49 @@
+{ lib, stdenv, fetchurl, jre, runtimeShell }:
+
+stdenv.mkDerivation rec {
+  pname = "polylith";
+  version = "0.1.0-alpha9";
+
+  src = fetchurl {
+    url = "https://github.com/polyfy/polylith/releases/download/v${version}/poly-${version}.jar";
+    sha256 = "0mjn0fibj7z8wihk5frhyd5ai2bmzm909701sphjs7j9lgg0gc4k";
+  };
+
+  dontUnpack = true;
+
+  installPhase = ''
+    runHook preInstall
+
+    mkdir -p $out/bin
+
+    cat > "$out/bin/poly" <<EOF
+    #!${runtimeShell}
+    ARGS=""
+    while [ "\$1" != "" ] ; do
+      ARGS="\$ARGS \$1"
+      shift
+    done
+    exec "${jre}/bin/java" "-jar" "${src}" \$ARGS
+    EOF
+    chmod a+x $out/bin/poly
+
+    runHook postInstall
+  '';
+
+  doInstallCheck = true;
+  installCheckPhase = ''
+    runHook preInstallCheck
+
+    $out/bin/poly help | fgrep -q '${version}'
+
+    runHook postInstallCheck
+  '';
+
+  meta = with lib; {
+    description = "A tool used to develop Polylith based architectures in Clojure";
+    homepage = "https://github.com/polyfy/polylith";
+    license = licenses.epl10;
+    maintainers = [ maintainers.ericdallo ];
+    platforms = jre.meta.platforms;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/prelink/default.nix b/nixpkgs/pkgs/development/tools/misc/prelink/default.nix
new file mode 100644
index 000000000000..63fc7c8e64a5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/prelink/default.nix
@@ -0,0 +1,25 @@
+{ lib, stdenv, fetchurl, libelf }:
+
+let
+  version = "20130503";
+in
+stdenv.mkDerivation {
+  pname = "prelink";
+  inherit version;
+
+  buildInputs = [
+    libelf stdenv.cc.libc (lib.getOutput "static" stdenv.cc.libc)
+  ];
+
+  src = fetchurl {
+    url = "https://people.redhat.com/jakub/prelink/prelink-${version}.tar.bz2";
+    sha256 = "1w20f6ilqrz8ca51qhrn1n13h7q1r34k09g33d6l2vwvbrhcffb3";
+  };
+
+  meta = {
+    homepage = "https://people.redhat.com/jakub/prelink/";
+    license = "GPL";
+    description = "ELF prelinking utility to speed up dynamic linking";
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/premake/3.nix b/nixpkgs/pkgs/development/tools/misc/premake/3.nix
new file mode 100644
index 000000000000..d72cca0e785b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/premake/3.nix
@@ -0,0 +1,30 @@
+{lib, stdenv, fetchurl, unzip}:
+
+let baseName = "premake";
+  version  = "3.7";
+in
+
+stdenv.mkDerivation {
+  name = "${baseName}-${version}";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/sourceforge/premake/${baseName}-src-${version}.zip";
+    sha256 = "b59841a519e75d5b6566848a2c5be2f91455bf0cc6ae4d688fcbd4c40db934d5";
+  };
+
+  nativeBuildInputs = [ unzip ];
+
+  installPhase = ''
+    install -Dm755 bin/premake $out/bin/premake
+  '';
+
+  premake_cmd = "premake";
+  setupHook = ./setup-hook.sh;
+
+  meta = {
+    homepage = "http://industriousone.com/premake";
+    description = "A simple build configuration and project generation tool using lua";
+    license = lib.licenses.bsd3;
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/premake/5.nix b/nixpkgs/pkgs/development/tools/misc/premake/5.nix
new file mode 100644
index 000000000000..bb0269d0cc3b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/premake/5.nix
@@ -0,0 +1,43 @@
+{ lib, stdenv, fetchFromGitHub, Foundation, readline }:
+
+with lib;
+
+stdenv.mkDerivation rec {
+  pname = "premake5";
+  version = "5.0.0-alpha12";
+
+  src = fetchFromGitHub {
+    owner = "premake";
+    repo = "premake-core";
+    rev = "v${version}";
+    sha256 = "1h3hr96pdz94njn4bg02ldcz0k5j1x017d8svc7fdyvl2b77nqzf";
+  };
+
+  buildInputs = optionals stdenv.isDarwin [ Foundation readline ];
+
+  patchPhase = optional stdenv.isDarwin ''
+    substituteInPlace premake5.lua \
+      --replace -mmacosx-version-min=10.4 -mmacosx-version-min=10.5
+  '';
+
+  buildPhase =
+    if stdenv.isDarwin then ''
+       make -f Bootstrap.mak osx
+    '' else ''
+       make -f Bootstrap.mak linux
+    '';
+
+  installPhase = ''
+    install -Dm755 bin/release/premake5 $out/bin/premake5
+  '';
+
+  premake_cmd = "premake5";
+  setupHook = ./setup-hook.sh;
+
+  meta = {
+    homepage = "https://premake.github.io";
+    description = "A simple build configuration and project generation tool using lua";
+    license = lib.licenses.bsd3;
+    platforms = platforms.darwin ++ platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/premake/default.nix b/nixpkgs/pkgs/development/tools/misc/premake/default.nix
new file mode 100644
index 000000000000..ccd8a4574a1f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/premake/default.nix
@@ -0,0 +1,35 @@
+{ lib, stdenv, fetchurl, unzip }:
+
+let baseName = "premake";
+  version  = "4.3";
+in
+
+stdenv.mkDerivation {
+  name = "${baseName}-${version}";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/${baseName}/${baseName}-${version}-src.zip";
+    sha256 = "1017rd0wsjfyq2jvpjjhpszaa7kmig6q1nimw76qx3cjz2868lrn";
+  };
+
+  nativeBuildInputs = [ unzip ];
+
+  buildPhase = ''
+    make -C build/gmake.unix/
+  '';
+
+  installPhase = ''
+    install -Dm755 bin/release/premake4 $out/bin/premake4
+  '';
+
+  premake_cmd = "premake4";
+  setupHook = ./setup-hook.sh;
+
+  meta = with lib; {
+    homepage = "http://industriousone.com/premake";
+    description = "A simple build configuration and project generation tool using lua";
+    license = lib.licenses.bsd3;
+    platforms = platforms.unix;
+    maintainers = [ maintainers.bjornfor ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/premake/setup-hook.sh b/nixpkgs/pkgs/development/tools/misc/premake/setup-hook.sh
new file mode 100644
index 000000000000..6e65e9e8c73f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/premake/setup-hook.sh
@@ -0,0 +1,19 @@
+premakeConfigurePhase() {
+    runHook preConfigure
+
+    local flagsArray=(
+        ${premakefile:+--file=$premakefile}
+        $premakeFlags ${premakeFlagsArray[@]}
+        ${premakeBackend:-gmake}
+    )
+
+    echoCmd 'configure flags' "${flagsArray[@]}"
+
+    @premake_cmd@ "${flagsArray[@]}"
+
+    runHook postConfigure
+}
+
+if [ -z "${configurePhase-}" ]; then
+    configurePhase=premakeConfigurePhase
+fi
diff --git a/nixpkgs/pkgs/development/tools/misc/ptags/default.nix b/nixpkgs/pkgs/development/tools/misc/ptags/default.nix
new file mode 100644
index 000000000000..b8be0ee3dc6d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ptags/default.nix
@@ -0,0 +1,41 @@
+{ fetchFromGitHub
+, cargo
+, ctags
+, lib
+, makeWrapper
+, rustPlatform
+}:
+
+rustPlatform.buildRustPackage rec {
+  pname = "ptags";
+  version = "0.3.2";
+
+  src = fetchFromGitHub {
+    owner = "dalance";
+    repo = "ptags";
+    rev = "v${version}";
+    sha256 = "1xr1szh4dfrcmi6s6dj791k1ix2zbv75rqkqbyb1lmh5548kywkg";
+  };
+
+  cargoSha256 = "1pz5hvn1iq26i8c2cmqavhnri8h0sn40khrxvcdkj9q47nsj5wcx";
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  postInstall = ''
+    # `ctags` must be accessible in `PATH` for `ptags` to work.
+    wrapProgram "$out/bin/ptags" \
+      --prefix PATH : "${lib.makeBinPath [ ctags ]}"
+  '';
+
+  # Sanity check.
+  checkPhase = ''
+    $releaseDir/ptags --help > /dev/null
+  '';
+
+  meta = with lib; {
+    description = "A parallel universal-ctags wrapper for git repository";
+    homepage = "https://github.com/dalance/ptags";
+    maintainers = with maintainers; [ pamplemousse ];
+    license = licenses.mit;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/pwndbg/default.nix b/nixpkgs/pkgs/development/tools/misc/pwndbg/default.nix
new file mode 100644
index 000000000000..764fa6677345
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/pwndbg/default.nix
@@ -0,0 +1,52 @@
+{ lib, stdenv
+, python3
+, fetchFromGitHub
+, makeWrapper
+, gdb
+}:
+
+let
+  pythonPath = with python3.pkgs; makePythonPath [
+    future
+    isort
+    psutil
+    pycparser
+    pyelftools
+    python-ptrace
+    ROPGadget
+    six
+    unicorn
+    pygments
+  ];
+
+in stdenv.mkDerivation rec {
+  pname = "pwndbg";
+  version = "2020.07.23";
+  format = "other";
+
+  src = fetchFromGitHub {
+    owner = "pwndbg";
+    repo = "pwndbg";
+    rev = version;
+    sha256 = "0w1dmjy8ii12367wza8c35a9q9x204fppf6x328q75bhb3gd845c";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  installPhase = ''
+    mkdir -p $out/share/pwndbg
+    cp -r *.py pwndbg $out/share/pwndbg
+    chmod +x $out/share/pwndbg/gdbinit.py
+    makeWrapper ${gdb}/bin/gdb $out/bin/pwndbg \
+      --add-flags "-q -x $out/share/pwndbg/gdbinit.py" \
+      --set NIX_PYTHONPATH ${pythonPath}
+  '';
+
+  meta = with lib; {
+    description = "Exploit Development and Reverse Engineering with GDB Made Easy";
+    homepage = "https://github.com/pwndbg/pwndbg";
+    license = licenses.mit;
+    platforms = platforms.all;
+    maintainers = with maintainers; [ mic92 ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/remarkable/remarkable-toolchain/default.nix b/nixpkgs/pkgs/development/tools/misc/remarkable/remarkable-toolchain/default.nix
new file mode 100644
index 000000000000..643e28e82b27
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/remarkable/remarkable-toolchain/default.nix
@@ -0,0 +1,35 @@
+{ lib, stdenv, fetchurl, libarchive, python, file, which }:
+
+stdenv.mkDerivation rec {
+  pname = "remarkable-toolchain";
+  version = "1.8-23.9.2019";
+
+  src = fetchurl {
+    url = "https://remarkable.engineering/oecore-x86_64-cortexa9hf-neon-toolchain-zero-gravitas-${version}.sh";
+    sha256 = "1rk1r80m5d18sw6hrybj6f78s8pna0wrsa40ax6j8jzfwahgzmfb";
+    executable = true;
+  };
+
+  nativeBuildInputs = [
+    libarchive
+    python
+    file
+    which
+  ];
+
+  dontUnpack = true;
+  dontBuild = true;
+
+  installPhase = ''
+    mkdir -p $out
+    ENVCLEANED=1 $src -y -d $out
+  '';
+
+  meta = with lib; {
+    description = "A toolchain for cross-compiling to reMarkable tablets";
+    homepage = "https://remarkable.engineering/";
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ nickhu siraben ];
+    platforms = [ "x86_64-linux" ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/remarkable/remarkable2-toolchain/default.nix b/nixpkgs/pkgs/development/tools/misc/remarkable/remarkable2-toolchain/default.nix
new file mode 100644
index 000000000000..7b4df5df1647
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/remarkable/remarkable2-toolchain/default.nix
@@ -0,0 +1,39 @@
+{ lib, stdenv, fetchurl, libarchive, python3, file }:
+
+stdenv.mkDerivation rec {
+  pname = "remarkable2-toolchain";
+  version = "2.5.2";
+
+  src = fetchurl {
+    url = "https://storage.googleapis.com/codex-public-bucket/codex-x86_64-cortexa7hf-neon-rm11x-toolchain-${version}.sh";
+    sha256 = "1v410q1jn8flisdpkrymxd4pa1ylawd0rh3rljjpkqw1bp8a5vw1";
+  };
+
+  nativeBuildInputs = [
+    libarchive
+    python3
+    file
+  ];
+
+  unpackCmd = ''
+    mkdir src
+    install $curSrc src/install-toolchain.sh
+  '';
+
+  dontBuild = true;
+
+  installPhase = ''
+    patchShebangs install-toolchain.sh
+    sed -i -e '3,9d' install-toolchain.sh # breaks PATH
+    sed -i 's|PYTHON=.*$|PYTHON=${python3}/bin/python|' install-toolchain.sh
+    ./install-toolchain.sh -D -y -d $out
+  '';
+
+  meta = with lib; {
+    description = "A toolchain for cross-compiling to reMarkable 2 tablets";
+    homepage = "https://remarkable.engineering/";
+    license = licenses.gpl2Plus;
+    maintainers = with maintainers; [ tadfisher ];
+    platforms = platforms.x86_64;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/replacement/default.nix b/nixpkgs/pkgs/development/tools/misc/replacement/default.nix
new file mode 100644
index 000000000000..3d0218ffab23
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/replacement/default.nix
@@ -0,0 +1,46 @@
+{ lib
+, fetchFromGitHub
+, python3Packages
+}:
+
+python3Packages.buildPythonApplication rec {
+  pname = "replacement";
+  version = "0.4.4";
+
+  disabled = python3Packages.isPy27;
+
+  src = fetchFromGitHub {
+    owner = "siriobalmelli";
+    repo = "replacement";
+    rev = "v${version}";
+    sha256 = "0j4lvn3rx1kqvxcsd8nhc2lgk48jyyl7qffhlkvakhy60f9lymj3";
+  };
+
+  propagatedBuildInputs = with python3Packages; [
+    ruamel_yaml
+  ];
+
+  checkInputs = with python3Packages; [
+    pytestCheckHook
+    sh
+  ];
+
+  meta = with lib; {
+    homepage = "https://github.com/siriobalmelli/replacement";
+    description = "A tool to execute yaml templates and output text";
+    longDescription = ''
+        Replacement is a python utility
+        that parses a yaml template and outputs text.
+
+        A 'template' is a YAML file containing a 'replacement' object.
+
+        A 'replacement' object contains a list of blocks,
+        each of which is executed in sequence.
+
+        This tool is useful in generating configuration files,
+        static websites and the like.
+    '';
+    license = licenses.asl20;
+    maintainers = with maintainers; [ siriobalmelli ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/reviewdog/default.nix b/nixpkgs/pkgs/development/tools/misc/reviewdog/default.nix
new file mode 100644
index 000000000000..fccee0ede2b6
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/reviewdog/default.nix
@@ -0,0 +1,29 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "reviewdog";
+  version = "0.11.0";
+
+  src = fetchFromGitHub {
+    owner = pname;
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "0n7hk3va25ym8sb900i1s1hjszgwrfl7gfsjbj1m330fidh3q6jc";
+  };
+
+  vendorSha256 = "0xscirzi0gqww33ngwh29jiylarj0w5snn9kvv43wfrphb6c79s5";
+
+  doCheck = false;
+
+  subPackages = [ "cmd/reviewdog" ];
+
+  buildFlagsArray = [ "-ldflags=-s -w -X github.com/reviewdog/reviewdog/commands.Version=${version}" ];
+
+  meta = with lib; {
+    description = "Automated code review tool integrated with any code analysis tools regardless of programming language";
+    homepage = "https://github.com/reviewdog/reviewdog";
+    changelog = "https://github.com/reviewdog/reviewdog/releases/tag/v${version}";
+    maintainers = [ maintainers.marsam ];
+    license = licenses.mit;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/rman/default.nix b/nixpkgs/pkgs/development/tools/misc/rman/default.nix
new file mode 100644
index 000000000000..bf71b619e5aa
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/rman/default.nix
@@ -0,0 +1,33 @@
+{lib, stdenv, fetchurl}:
+
+stdenv.mkDerivation {
+  name = "rman-3.2";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/polyglotman/3.2/rman-3.2.tar.gz";
+    sha256 = "0prdld6nbkdlkcgc2r1zp13h2fh8r0mlwxx423dnc695ddlk18b8";
+  };
+
+  postPatch = ''
+    substituteInPlace Makefile \
+      --replace ginstall install \
+      --replace gcc '${stdenv.cc.targetPrefix}cc'
+  '';
+
+  makeFlags = [ "BINDIR=$(out)/bin" "MANDIR=$(out)/share/man" ];
+
+  preInstall = ''
+    mkdir -p $out/bin
+    mkdir -p $out/share/man
+  '';
+
+  hardeningDisable = [ "format" ];
+
+  doCheck = false; # "check" target is probably meant to do "installcheck" or something
+
+  meta = {
+    description = "Parse formatted man pages and man page source from most flavors of UNIX and converts them to HTML, ASCII, TkMan, DocBook, and other formats";
+    license = "artistic";
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/rolespec/default.nix b/nixpkgs/pkgs/development/tools/misc/rolespec/default.nix
new file mode 100644
index 000000000000..b26fbf75031d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/rolespec/default.nix
@@ -0,0 +1,49 @@
+{ lib, stdenv, fetchFromGitHub, makeWrapper }:
+
+stdenv.mkDerivation rec {
+
+  name = "rolespec-${meta.version}";
+
+  src = fetchFromGitHub {
+    owner = "nickjj";
+    repo = "rolespec";
+    rev = "d9ee530cd709168882059776c482fc37f46cb743";
+    sha256 = "1jkidw6aqr0zfqwmcvlpi9qa140z2pxcfsd43xm5ikx6jcwjdrzl";
+    inherit name;
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  # The default build phase (`make`) runs the test code. It's difficult to do
+  # the test in the build environment because it depends on the system package
+  # managers (apt/yum/pacman). We simply skip this phase since RoleSpec is
+  # shell based.
+  dontBuild = true;
+
+  # Wrap the program because `ROLESPEC_LIB` defaults to
+  # `/usr/local/lib/rolespec`.
+  installPhase = ''
+    make install PREFIX=$out
+    wrapProgram $out/bin/rolespec --set ROLESPEC_LIB $out/lib/rolespec
+  '';
+
+  # Since RoleSpec installs the shell script files in `lib` directory, the
+  # fixup phase shows some warnings. Disable these actions.
+  dontPatchELF = true;
+  dontStrip = true;
+
+  meta = with lib; {
+    homepage = "https://github.com/nickjj/rolespec";
+    description = "A test library for testing Ansible roles";
+    longDescription = ''
+      A shell based test library for Ansible that works both locally and over
+      Travis-CI.
+    '';
+    downloadPage = "https://github.com/nickjj/rolespec";
+    license = licenses.gpl3;
+    version = "20161104";
+    maintainers = [ maintainers.dochang ];
+    platforms = platforms.unix;
+  };
+
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/rtss/default.nix b/nixpkgs/pkgs/development/tools/misc/rtss/default.nix
new file mode 100644
index 000000000000..36ef4c349e9e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/rtss/default.nix
@@ -0,0 +1,22 @@
+{ lib, fetchFromGitHub, rustPlatform }:
+
+rustPlatform.buildRustPackage rec {
+  pname = "rtss";
+  version = "0.6.1";
+
+  src = fetchFromGitHub {
+    owner = "Freaky";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "1936w161mkbcwicrxn51b42pgir5yjiw85s74lbfq70nddw18nyn";
+  };
+
+  cargoSha256 = "1b1xiaaxbw6y80pkzd594dikm372l1mmymf1wn2acmlz979nmas8";
+
+  meta = with lib; {
+    description = "Annotate output with relative durations between lines";
+    homepage = "https://github.com/Freaky/rtss";
+    license = licenses.mit;
+    maintainers = with maintainers; [ djanatyn ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/saleae-logic/default.nix b/nixpkgs/pkgs/development/tools/misc/saleae-logic/default.nix
new file mode 100644
index 000000000000..5943b57d8088
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/saleae-logic/default.nix
@@ -0,0 +1,97 @@
+# Saleae logic analyzer software
+#
+# Suggested udev rules to be able to access the Logic device without being root:
+#   SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{idVendor}=="0925", ATTR{idProduct}=="3881", MODE="0666"
+#   SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{idVendor}=="21a9", ATTR{idProduct}=="1001", MODE="0666"
+#
+# In NixOS, simply add this package to services.udev.packages.
+
+{ lib, stdenv, fetchurl, unzip, glib, libSM, libICE, gtk2, libXext, libXft
+, fontconfig, libXrender, libXfixes, libX11, libXi, libXrandr, libXcursor
+, freetype, libXinerama, libxcb, zlib, pciutils
+, makeDesktopItem, xkeyboardconfig, dbus, runtimeShell, libGL
+}:
+
+let
+
+  libPath = lib.makeLibraryPath [
+    glib libSM libICE gtk2 libXext libXft fontconfig libXrender libXfixes libX11
+    libXi libXrandr libXcursor freetype libXinerama libxcb zlib stdenv.cc.cc.lib
+    dbus libGL
+  ];
+
+in
+
+assert stdenv.hostPlatform.system == "x86_64-linux";
+
+stdenv.mkDerivation rec {
+  pname = "saleae-logic";
+  version = "1.2.18";
+
+  src = fetchurl {
+    name = "saleae-logic-${version}-64bit.zip";
+    url = "http://downloads.saleae.com/logic/${version}/Logic%20${version}%20(64-bit).zip";
+    sha256 = "0lhair2vsg8sjvzicvfcjfmvy30q7i01xj4z02iqh7pgzpb025h8";
+  };
+
+  desktopItem = makeDesktopItem {
+    name = "saleae-logic";
+    exec = "saleae-logic";
+    icon = ""; # the package contains no icon
+    comment = "Software for Saleae logic analyzers";
+    desktopName = "Saleae Logic";
+    genericName = "Logic analyzer";
+    categories = "Development";
+  };
+
+  nativeBuildInputs = [ unzip ];
+
+  installPhase = ''
+    # Copy prebuilt app to $out
+    mkdir "$out"
+    cp -r * "$out"
+
+    # Patch it
+    patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" "$out/Logic"
+    for bin in "$out/Logic"              \
+               "$out/libQt5Widgets.so.5" \
+               "$out/libQt5Gui.so.5"     \
+               "$out/libQt5Core.so.5"    \
+               "$out/libQt5Network.so.5" ; do
+        patchelf --set-rpath "${stdenv.cc.cc.lib}/lib:${stdenv.cc.cc.lib}/lib64:${libPath}:\$ORIGIN/Analyzers:\$ORIGIN" "$bin"
+    done
+
+    patchelf --set-rpath "${stdenv.cc.cc.lib}/lib:${stdenv.cc.cc.lib}/lib64:${libPath}:\$ORIGIN/../" "$out/platforms/libqxcb.so"
+
+    # Build the LD_PRELOAD library that makes Logic work from a read-only directory
+    mkdir -p "$out/lib"
+    gcc -shared -fPIC -DOUT=\"$out\" "${./preload.c}" -o "$out/lib/preload.so" -ldl
+
+    # Make wrapper script that uses the LD_PRELOAD library
+    mkdir -p "$out/bin"
+    cat > "$out/bin/saleae-logic" << EOF
+    #!${runtimeShell}
+    export LD_PRELOAD="$out/lib/preload.so"
+    export QT_XKB_CONFIG_ROOT="${xkeyboardconfig}/share/X11/xkb"
+    export PATH="${pciutils}/bin:\$PATH"
+    exec "$out/Logic" "\$@"
+    EOF
+    chmod a+x "$out"/bin/saleae-logic
+
+    # Copy the generated .desktop file
+    mkdir -p "$out/share/applications"
+    cp "$desktopItem"/share/applications/* "$out/share/applications/"
+
+    # Install provided udev rules
+    mkdir -p "$out/etc/udev/rules.d"
+    cp Drivers/99-SaleaeLogic.rules "$out/etc/udev/rules.d/"
+  '';
+
+  meta = with lib; {
+    description = "Software for Saleae logic analyzers";
+    homepage = "https://www.saleae.com/";
+    license = licenses.unfree;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/saleae-logic/preload.c b/nixpkgs/pkgs/development/tools/misc/saleae-logic/preload.c
new file mode 100644
index 000000000000..b4451e4d99f7
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/saleae-logic/preload.c
@@ -0,0 +1,341 @@
+/*
+ * LD_PRELOAD trick to make Saleae Logic work from a read-only installation
+ * directory.
+ *
+ * Saleae Logic tries to write to a few directories inside its installation
+ * directory. Because the Nix store is read-only, we have to redirect access to
+ * this file somewhere else. Here's the map:
+ *
+ *   $out/Settings/    => $HOME/.saleae-logic/Settings/
+ *   $out/Databases/   => $HOME/.saleae-logic/Databases/
+ *   $out/Errors/      => $HOME/.saleae-logic/Errors/
+ *   $out/Calibration/ => $HOME/.saleae-logic/Calibration/
+ *
+ * This also makes the software multi-user aware :-)
+ *
+ * NOTE: AFAIK (Bjørn Forsman), Logic version 1.2+ was supposed to have a
+ * command line parameter for redirecting these write operations, but
+ * apparently that feature got postponed.
+ *
+ * Usage:
+ *   gcc -shared -fPIC -DOUT="$out" preload.c -o preload.so -ldl
+ *   LD_PRELOAD=$PWD/preload.so ./result/Logic
+ *
+ * To see the paths that are modified at runtime, set the environment variable
+ * PRELOAD_DEBUG to 1 (or anything really; debugging is on as long as the
+ * variable exists).
+ */
+
+#define _GNU_SOURCE
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <unistd.h>
+#include <fcntl.h>
+#include <dlfcn.h>
+#include <limits.h>
+#include <sys/stat.h>
+#include <sys/types.h>
+#include <errno.h>
+
+#ifndef OUT
+#error Missing OUT define - path to the installation directory.
+#endif
+
+/*
+ * TODO: How to properly wrap "open", which is declared as a variadic function
+ * in glibc? The man page lists these signatures:
+ *
+ *   int open(const char *pathname, int flags);
+ *   int open(const char *pathname, int flags, mode_t mode);
+ *
+ * But using either signature in this code cause a compile error, because
+ * glibc has declared the function as "int open(const char *, int, ...)".
+ * Same thing with "openat".
+ *
+ * For now we discard the variadic args. It seems to work.
+ *
+ * Relevant:
+ * http://stackoverflow.com/questions/28462523/how-to-wrap-ioctlint-d-unsigned-long-request-using-ld-preload
+ */
+typedef FILE *(*fopen_func_t)(const char *path, const char *mode);
+typedef FILE *(*fopen64_func_t)(const char *path, const char *mode);
+typedef int (*open_func_t)(const char *pathname, int flags, ...);
+typedef int (*open64_func_t)(const char *pathname, int flags, ...);
+typedef int (*openat_func_t)(int dirfd, const char *pathname, int flags, ...);
+typedef int (*openat64_func_t)(int dirfd, const char *pathname, int flags, ...);
+typedef int (*xstat_func_t)(int vers, const char *pathname, struct stat *buf);
+typedef int (*xstat64_func_t)(int vers, const char *pathname, struct stat64 *buf);
+typedef int (*access_func_t)(const char *pathname, int mode);
+typedef int (*faccessat_func_t)(int dirfd, const char *pathname, int mode, int flags);
+typedef int (*unlink_func_t)(const char *pathname);
+
+/*
+ * Redirect $out/{Settings,Databases,Errors,Calibration}/ => $HOME/.saleae-logic/.
+ * Path is truncated if bigger than PATH_MAX.
+ *
+ * @param pathname Original file path.
+ * @param buffer Pointer to a buffer of size PATH_MAX bytes that this function
+ * will write the new redirected path to (if needed).
+ *
+ * @return Pointer to the resulting path. It will either be equal to the
+ * pathname (no redirect) or buffer argument (was redirected).
+ */
+static const char *redirect(const char *pathname, char *buffer)
+{
+	const char *homepath;
+	const char *new_path;
+	static char have_warned;
+	const char *remainder;
+	static char have_initialized;
+	static size_t out_strlen;
+	static size_t settings_strlen;
+	static size_t databases_strlen;
+	static size_t errors_strlen;
+	static size_t calibration_strlen;
+	int ret;
+	int i;
+
+	homepath = getenv("HOME");
+	if (!homepath) {
+		homepath = "/";
+		if (!have_warned && getenv("PRELOAD_DEBUG")) {
+			fprintf(stderr, "preload_debug: WARNING: HOME is unset, using \"/\" (root) instead.\n");
+			have_warned = 1;
+		}
+	}
+
+	if (!have_initialized) {
+		/*
+		 * The directories that Saleae Logic expects to find.
+		 * The first element is intentionally empty (create base dir).
+		 */
+		char *dirs[] = {"", "/Settings", "/Databases", "/Errors", "/Calibration"};
+		char old_settings_path[PATH_MAX];
+		access_func_t orig_access;
+
+		out_strlen = strlen(OUT);
+		settings_strlen = out_strlen + strlen("/Settings");
+		databases_strlen = out_strlen + strlen("/Databases");
+		errors_strlen = out_strlen + strlen("/Errors");
+		calibration_strlen = out_strlen + strlen("/Calibration");
+		for (i = 0; i < sizeof dirs / sizeof dirs[0]; i++) {
+			snprintf(buffer, PATH_MAX, "%s/.saleae-logic%s", homepath, dirs[i]);
+			buffer[PATH_MAX-1] = '\0';
+			ret = mkdir(buffer, 0755);
+			if (0 != ret && errno != EEXIST) {
+				fprintf(stderr, "ERROR: Failed to create directory \"%s\": %s\n",
+						buffer, strerror(errno));
+				return NULL;
+			}
+		}
+
+		/*
+		 * Automatic migration of the settings file:
+		 * ~/.saleae-logic-settings.xml => ~/.saleae-logic/Settings/settings.xml
+		 */
+		snprintf(old_settings_path, PATH_MAX, "%s/.saleae-logic-settings.xml", homepath);
+		old_settings_path[PATH_MAX-1] = '\0';
+		orig_access = (access_func_t)dlsym(RTLD_NEXT, "access");
+		if (orig_access(old_settings_path, F_OK) == 0) {
+			snprintf(buffer, PATH_MAX, "%s/.saleae-logic/Settings/settings.xml", homepath);
+			buffer[PATH_MAX-1] = '\0';
+			ret = rename(old_settings_path, buffer);
+			if (ret != 0) {
+				fprintf(stderr, "WARN: Failed to move %s to %s",
+						old_settings_path, buffer);
+			}
+		}
+
+		have_initialized = 1;
+	}
+
+	new_path = pathname;
+	remainder = pathname + out_strlen;
+
+	if ((strncmp(OUT "/Settings", pathname, settings_strlen) == 0) ||
+	    (strncmp(OUT "/Databases", pathname, databases_strlen) == 0) ||
+	    (strncmp(OUT "/Errors", pathname, errors_strlen) == 0) ||
+	    (strncmp(OUT "/Calibration", pathname, calibration_strlen) == 0)) {
+		snprintf(buffer, PATH_MAX, "%s/.saleae-logic%s", homepath, remainder);
+		buffer[PATH_MAX-1] = '\0';
+		new_path = buffer;
+	}
+
+	return new_path;
+}
+
+FILE *fopen(const char *pathname, const char *mode)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	fopen_func_t orig_fopen;
+
+	orig_fopen = (fopen_func_t)dlsym(RTLD_NEXT, "fopen");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: fopen(\"%s\", \"%s\") => \"%s\"\n", pathname, mode, path);
+	}
+
+	return orig_fopen(path, mode);
+}
+
+FILE *fopen64(const char *pathname, const char *mode)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	fopen64_func_t orig_fopen64;
+
+	orig_fopen64 = (fopen64_func_t)dlsym(RTLD_NEXT, "fopen64");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: fopen64(\"%s\", \"%s\") => \"%s\"\n", pathname, mode, path);
+	}
+
+	return orig_fopen64(path, mode);
+}
+
+int open(const char *pathname, int flags, ...)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	open_func_t orig_open;
+
+	orig_open = (open_func_t)dlsym(RTLD_NEXT, "open");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: open(\"%s\", ...) => \"%s\"\n", pathname, path);
+	}
+
+	return orig_open(path, flags);
+}
+
+int open64(const char *pathname, int flags, ...)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	open64_func_t orig_open64;
+
+	orig_open64 = (open64_func_t)dlsym(RTLD_NEXT, "open64");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: open64(\"%s\", ...) => \"%s\"\n", pathname, path);
+	}
+
+	return orig_open64(path, flags);
+}
+
+int openat(int dirfd, const char *pathname, int flags, ...)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	openat_func_t orig_openat;
+
+	orig_openat = (openat_func_t)dlsym(RTLD_NEXT, "openat");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: openat(%d, \"%s\", %#x) => \"%s\"\n", dirfd, pathname, flags, path);
+	}
+
+	return orig_openat(dirfd, path, flags);
+}
+
+int openat64(int dirfd, const char *pathname, int flags, ...)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	openat64_func_t orig_openat64;
+
+	orig_openat64 = (openat64_func_t)dlsym(RTLD_NEXT, "openat64");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: openat64(%d, \"%s\", %#x) => \"%s\"\n", dirfd, pathname, flags, path);
+	}
+
+	return orig_openat64(dirfd, path, flags);
+}
+
+/*
+ * Notes about "stat".
+ *
+ * The stat function is special, at least in glibc, in that it cannot be
+ * directly overridden by LD_PRELOAD, due to it being inline wrapper around
+ * __xstat. The __xstat functions take one extra parameter, a version number,
+ * to indicate what "struct stat" should look like. This trick allows changing
+ * the contents of mode_t without changing the shared library major number. See
+ * sys/stat.h header for more info.
+ */
+int __xstat(int vers, const char *pathname, struct stat *buf)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	xstat_func_t orig_xstat;
+
+	orig_xstat = (xstat_func_t)dlsym(RTLD_NEXT, "__xstat");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: (__x)stat(\"%s\", ...) => \"%s\"\n", pathname, path);
+	}
+
+	return orig_xstat(vers, path, buf);
+}
+
+int __xstat64(int vers, const char *pathname, struct stat64 *buf)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	xstat64_func_t orig_xstat64;
+
+	orig_xstat64 = (xstat64_func_t)dlsym(RTLD_NEXT, "__xstat64");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: (__x)stat64(\"%s\", ...) => \"%s\"\n", pathname, path);
+	}
+
+	return orig_xstat64(vers, path, buf);
+}
+
+int access(const char *pathname, int mode)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	access_func_t orig_access;
+
+	orig_access = (access_func_t)dlsym(RTLD_NEXT, "access");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: access(\"%s\", ...) => \"%s\"\n", pathname, path);
+	}
+
+	return orig_access(path, mode);
+}
+
+int faccessat(int dirfd, const char *pathname, int mode, int flags)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	faccessat_func_t orig_faccessat;
+
+	orig_faccessat = (faccessat_func_t)dlsym(RTLD_NEXT, "faccessat");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: faccessat(\"%s\", ...) => \"%s\"\n", pathname, path);
+	}
+
+	return orig_faccessat(dirfd, path, mode, flags);
+}
+
+int unlink(const char *pathname)
+{
+	const char *path;
+	char buffer[PATH_MAX];
+	unlink_func_t orig_unlink;
+
+	orig_unlink = (unlink_func_t)dlsym(RTLD_NEXT, "unlink");
+	path = redirect(pathname, buffer);
+	if (path != pathname && getenv("PRELOAD_DEBUG")) {
+		fprintf(stderr, "preload_debug: unlink(\"%s\") => \"%s\"\n", pathname, path);
+	}
+
+	return orig_unlink(path);
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/scc/default.nix b/nixpkgs/pkgs/development/tools/misc/scc/default.nix
new file mode 100644
index 000000000000..9dfa5955f5c9
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/scc/default.nix
@@ -0,0 +1,26 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "scc";
+  version = "3.0.0";
+
+  src = fetchFromGitHub {
+    owner = "boyter";
+    repo = "scc";
+    rev = "v${version}";
+    sha256 = "sha256-G5LYOtAUnu82cgDdtYzcfVx/WFg9/HvFQAlQtd6GaDE=";
+  };
+
+  vendorSha256 = null;
+
+  # scc has a scripts/ sub-package that's for testing.
+  excludedPackages = [ "scripts" ];
+
+  meta = with lib; {
+    homepage = "https://github.com/boyter/scc";
+    description = "A very fast accurate code counter with complexity calculations and COCOMO estimates written in pure Go";
+    maintainers = with maintainers; [ sigma Br1ght0ne ];
+    license = with licenses; [ unlicense /* or */ mit ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/sccache/default.nix b/nixpkgs/pkgs/development/tools/misc/sccache/default.nix
new file mode 100644
index 000000000000..cbdee69ce2ce
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/sccache/default.nix
@@ -0,0 +1,31 @@
+{ stdenv, lib, fetchFromGitHub, rustPlatform, pkg-config, openssl, Security }:
+
+rustPlatform.buildRustPackage rec {
+  version = "0.2.15";
+  pname = "sccache";
+
+  src = fetchFromGitHub {
+    owner = "mozilla";
+    repo = "sccache";
+    rev = "v${version}";
+    sha256 = "1kygk7ilv7la36kv4jdn1ird7f3896wgr88kyqf0iagfqkzb2vsb";
+  };
+
+  cargoSha256 = "1f42cqaqnjwi9k4ihqil6z2dqh5dnf76x54gk7mndzkrfg3rl573";
+
+  cargoBuildFlags = lib.optionals (!stdenv.isDarwin) [ "--features=dist-client,dist-server" ];
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ openssl ] ++ lib.optional stdenv.isDarwin Security;
+
+  # Tests fail because of client server setup which is not possible inside the pure environment,
+  # see https://github.com/mozilla/sccache/issues/460
+  doCheck = false;
+
+  meta = with lib; {
+    description = "Ccache with Cloud Storage";
+    homepage = "https://github.com/mozilla/sccache";
+    maintainers = with maintainers; [ doronbehar ];
+    license = licenses.asl20;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/segger-ozone/default.nix b/nixpkgs/pkgs/development/tools/misc/segger-ozone/default.nix
new file mode 100644
index 000000000000..5e1c6888b8e5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/segger-ozone/default.nix
@@ -0,0 +1,84 @@
+{ stdenv
+, fetchurl
+, fontconfig
+, freetype
+, lib
+, libICE
+, libSM
+, udev
+, libX11
+, libXcursor
+, libXext
+, libXfixes
+, libXrandr
+, libXrender
+}:
+
+stdenv.mkDerivation rec {
+  pname = "segger-ozone";
+  version = "3.22a";
+
+  src = fetchurl {
+    url = "https://www.segger.com/downloads/jlink/Ozone_Linux_V${(lib.replaceChars ["."] [""] version)}_x86_64.tgz";
+    sha256 = "0v1r8qvp1w2f3yip9fys004pa0smlmq69p7w77lfvghs1rmg1649";
+  };
+
+  rpath = lib.makeLibraryPath [
+    fontconfig
+    freetype
+    libICE
+    libSM
+    udev
+    libX11
+    libXcursor
+    libXext
+    libXfixes
+    libXrandr
+    libXrender
+  ]
+  + ":${stdenv.cc.cc.lib}/lib64";
+
+  installPhase = ''
+    mkdir -p $out/bin
+    mv Lib lib
+    mv * $out
+    ln -s $out/Ozone $out/bin
+  '';
+
+  postFixup = ''
+    patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" "$out/Ozone" \
+      --set-rpath ${rpath}:$out/lib "$out/Ozone"
+
+    for file in $(find $out/lib -maxdepth 1 -type f -and -name \*.so\*); do
+      patchelf --set-rpath ${rpath}:$out/lib $file
+    done
+  '';
+
+  meta = with lib; {
+    description = "J-Link Debugger and Performance Analyzer";
+    longDescription = ''
+      Ozone is a cross-platform debugger and performance analyzer for J-Link
+      and J-Trace.
+
+        - Stand-alone graphical debugger
+        - Debug output of any tool chain and IDE 1
+        - C/C++ source level debugging and assembly instruction debugging
+        - Debug information windows for any purpose: disassembly, memory,
+          globals and locals, (live) watches, CPU and peripheral registers
+        - Source editor to fix bugs immediately
+        - High-speed programming of the application into the target
+        - Direct use of J-Link built-in features (Unlimited Flash
+          Breakpoints, Flash Download, Real Time Terminal, Instruction Trace)
+        - Scriptable project files to set up everything automatically
+          - New project wizard to ease the basic configuration of new projects
+
+      1 Ozone has been tested with the output of the following compilers:
+      GCC, Clang, ARM, IAR. Output of other compilers may be supported but is
+      not guaranteed to be.
+    '';
+    homepage = "https://www.segger.com/products/development-tools/ozone-j-link-debugger";
+    license = licenses.unfree;
+    maintainers = [ maintainers.bmilanov ];
+    platforms = [ "x86_64-linux" ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/semver-tool/default.nix b/nixpkgs/pkgs/development/tools/misc/semver-tool/default.nix
new file mode 100644
index 000000000000..0cfbd0680ba6
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/semver-tool/default.nix
@@ -0,0 +1,32 @@
+{ stdenv, lib, fetchFromGitHub }:
+
+stdenv.mkDerivation rec {
+  pname = "semver-tool";
+  version = "3.2.0";
+
+  src = fetchFromGitHub {
+    owner = "fsaintjacques";
+    repo = pname;
+    rev = version;
+    sha256 = "sha256-coy/g4nEvSN+0/aqK2r3EEIaoUcnsZhzX66H1qsK9ac=";
+  };
+
+  dontBuild = true; # otherwise we try to 'make' which fails.
+
+  installPhase = ''
+    runHook preInstall
+
+    mkdir -p $out/bin
+    install src/semver $out/bin
+
+    runHook postInstall
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/fsaintjacques/semver-tool";
+    description = "semver bash implementation";
+    license = licenses.gpl3Plus;
+    platforms = platforms.unix;
+    maintainers = [ maintainers.qyliss ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/sipp/default.nix b/nixpkgs/pkgs/development/tools/misc/sipp/default.nix
new file mode 100644
index 000000000000..22bf244662b3
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/sipp/default.nix
@@ -0,0 +1,35 @@
+{lib, stdenv, fetchurl, ncurses, libpcap }:
+
+stdenv.mkDerivation rec {
+  version = "3.6.0";
+
+  pname = "sipp";
+
+  src = fetchurl {
+    url = "https://github.com/SIPp/${pname}/releases/download/v${version}/${pname}-${version}.tar.gz";
+    sha256 = "1fx1iy2n0m2kr91n1ii30frbscq375k3lqihdgvrqxn0zq8pnzp4";
+  };
+
+  postPatch = ''
+    sed -i "s@pcap/\(.*\).pcap@$out/share/pcap/\1.pcap@g" src/scenario.cpp
+  '';
+
+  configureFlags = [
+    "--with-pcap"
+  ];
+
+  postInstall = ''
+    mkdir -pv $out/share/pcap
+    cp pcap/* $out/share/pcap
+  '';
+
+  buildInputs = [ncurses libpcap];
+
+  meta = with lib; {
+    homepage = "http://sipp.sf.net";
+    description = "The SIPp testing tool";
+    license = licenses.gpl3;
+    platforms = platforms.unix;
+  };
+}
+
diff --git a/nixpkgs/pkgs/development/tools/misc/sloccount/default.nix b/nixpkgs/pkgs/development/tools/misc/sloccount/default.nix
new file mode 100644
index 000000000000..2fd984902875
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/sloccount/default.nix
@@ -0,0 +1,72 @@
+{ fetchurl, lib, stdenv, perl, makeWrapper }:
+
+stdenv.mkDerivation rec {
+  name = "sloccount-2.26";
+
+  src = fetchurl {
+    url = "https://www.dwheeler.com/sloccount/${name}.tar.gz";
+    sha256 = "0ayiwfjdh1946asah861ah9269s5xkc8p5fv1wnxs9znyaxs4zzs";
+  };
+
+  nativeBuildInputs = [ makeWrapper ];
+  buildInputs = [ perl ];
+
+  # Make sure the Flex-generated files are newer than the `.l' files, so that
+  # Flex isn't needed to recompile them.
+  patchPhase = ''
+    for file in *
+    do
+      if grep -q /usr/bin/perl "$file"
+      then
+          echo "patching \`$file'..."
+          substituteInPlace "$file" --replace \
+            "/usr/bin/perl" "${perl}/bin/perl"
+      fi
+    done
+
+    for file in *.l
+    do
+      touch "$(echo $file | sed -es'/\.l$/.c/g')"
+    done
+  '';
+
+  makeFlags = [ "PREFIX=$(out)" "CC=${stdenv.cc.targetPrefix}cc" ];
+
+  doCheck = true;
+  checkPhase = ''HOME="$TMPDIR" PATH="$PWD:$PATH" make test'';
+
+  preInstall = ''
+    mkdir -p "$out/bin"
+    mkdir -p "$out/share/man/man1"
+    mkdir -p "$out/share/doc"
+  '';
+
+  postInstall = ''
+    for w in "$out/bin"/*; do
+      isScript "$w" || continue
+      wrapProgram "$w" --prefix PATH : "$out/bin"
+    done
+    '';
+
+  meta = {
+    description = "Set of tools for counting physical Source Lines of Code (SLOC)";
+
+    longDescription = ''
+      This is the home page of "SLOCCount", a set of tools for
+      counting physical Source Lines of Code (SLOC) in a large number
+      of languages of a potentially large set of programs.  This suite
+      of tools was used in my papers More than a Gigabuck: Estimating
+      GNU/Linux's Size and Estimating Linux's Size to measure the SLOC
+      of entire GNU/Linux distributions, and my essay Linux Kernel
+      2.6: It's Worth More!  Others have measured Debian GNU/Linux and
+      the Perl CPAN library using this tool suite.
+    '';
+
+    license = lib.licenses.gpl2Plus;
+
+    homepage = "https://www.dwheeler.com/sloccount/";
+
+    maintainers = [ ];
+    platforms = lib.platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/sqitch/default.nix b/nixpkgs/pkgs/development/tools/misc/sqitch/default.nix
new file mode 100644
index 000000000000..5e3c3bc37c64
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/sqitch/default.nix
@@ -0,0 +1,46 @@
+{ stdenv
+, lib
+, perlPackages
+, makeWrapper
+, shortenPerlShebang
+, mysqlSupport ? false
+, postgresqlSupport ? false
+}:
+
+let
+  sqitch = perlPackages.AppSqitch;
+  modules = with perlPackages; [ ]
+    ++ lib.optional mysqlSupport DBDmysql
+    ++ lib.optional postgresqlSupport DBDPg;
+in
+
+stdenv.mkDerivation {
+  pname = "sqitch";
+  version = sqitch.version;
+
+  nativeBuildInputs = [ makeWrapper ] ++ lib.optional stdenv.isDarwin shortenPerlShebang;
+
+  src = sqitch;
+  dontBuild = true;
+
+  installPhase = ''
+    mkdir -p $out/bin
+    for d in bin/sqitch etc lib share ; do
+      # make sure dest alreay exists before symlink
+      # this prevents installing a broken link into the path
+      if [ -e ${sqitch}/$d ]; then
+        ln -s ${sqitch}/$d $out/$d
+      fi
+    done
+  '' + lib.optionalString stdenv.isDarwin ''
+    shortenPerlShebang $out/bin/sqitch
+  '';
+  dontStrip = true;
+  postFixup = ''
+    wrapProgram $out/bin/sqitch --prefix PERL5LIB : ${perlPackages.makeFullPerlPath modules}
+  '';
+
+  meta = {
+    inherit (sqitch.meta) description homepage license platforms;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/srecord/default.nix b/nixpkgs/pkgs/development/tools/misc/srecord/default.nix
new file mode 100644
index 000000000000..a18dcd85255a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/srecord/default.nix
@@ -0,0 +1,22 @@
+{ lib, stdenv, fetchurl, boost, libtool, groff, ghostscript, libgcrypt ? null }:
+
+stdenv.mkDerivation rec {
+  name = "srecord-1.64";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/srecord/${name}.tar.gz";
+    sha256 = "1qk75q0k5vzmm3932q9hqz2gp8n9rrdfjacsswxc02656f3l3929";
+  };
+
+  buildInputs = [ boost libtool groff ghostscript libgcrypt ];
+
+  configureFlags = lib.optional (libgcrypt == null) "--without-gcrypt";
+
+  meta = with lib; {
+    description = "Collection of powerful tools for manipulating EPROM load files";
+    homepage = "http://srecord.sourceforge.net/";
+    license = licenses.gpl3Plus;
+    maintainers = [ maintainers.bjornfor ];
+    platforms = lib.platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/stlink/default.nix b/nixpkgs/pkgs/development/tools/misc/stlink/default.nix
new file mode 100644
index 000000000000..2fbb60a0ddcc
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/stlink/default.nix
@@ -0,0 +1,53 @@
+{ lib
+, stdenv
+, fetchFromGitHub
+, cmake
+, libusb1
+, gtk3
+, pkg-config
+, wrapGAppsHook
+, withGUI ? false
+}:
+
+let
+  # The Darwin build of stlink explicitly refers to static libusb.
+  libusb1' = if stdenv.isDarwin then libusb1.override { withStatic = true; } else libusb1;
+
+# IMPORTANT: You need permissions to access the stlink usb devices.
+# Add services.udev.packages = [ pkgs.stlink ] to your configuration.nix
+
+in stdenv.mkDerivation rec {
+  pname = "stlink";
+  version = "1.7.0";
+
+  src = fetchFromGitHub {
+    owner = "stlink-org";
+    repo = "stlink";
+    rev = "v${version}";
+    sha256 = "03xypffpbp4imrczbxmq69vgkr7mbp0ps9dk815br5wwlz6vgygl";
+  };
+
+  buildInputs = [
+    libusb1'
+  ] ++ lib.optionals withGUI [
+    gtk3
+  ];
+  nativeBuildInputs = [
+    cmake
+  ] ++ lib.optionals withGUI [
+    pkg-config
+    wrapGAppsHook
+  ];
+
+  cmakeFlags = [
+    "-DSTLINK_MODPROBED_DIR=${placeholder "out"}/etc/modprobe.d"
+    "-DSTLINK_UDEV_RULES_DIR=${placeholder "out"}/lib/udev/rules.d"
+  ];
+
+  meta = with lib; {
+    description = "In-circuit debug and programming for ST-Link devices";
+    license = licenses.bsd3;
+    platforms = platforms.unix;
+    maintainers = [ maintainers.bjornfor maintainers.rongcuid ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/stm32cubemx/default.nix b/nixpkgs/pkgs/development/tools/misc/stm32cubemx/default.nix
new file mode 100644
index 000000000000..bca4f87f9a55
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/stm32cubemx/default.nix
@@ -0,0 +1,71 @@
+{ lib, stdenv, makeDesktopItem, copyDesktopItems, icoutils, fdupes, imagemagick, jdk11, fetchzip }:
+# TODO: JDK16 causes STM32CubeMX to crash right now, so we fixed the version to JDK11
+# This may be fixed in a future version of STM32CubeMX. This issue has been reported to ST:
+# https://community.st.com/s/question/0D53W00000jnOzPSAU/stm32cubemx-crashes-on-launch-with-openjdk16
+# If you're updating this derivation, check the link above to see if it's been fixed upstream
+# and try replacing all occurrences of jdk11 with jre and test whether it works.
+let
+  iconame = "STM32CubeMX";
+in
+stdenv.mkDerivation rec {
+  pname = "stm32cubemx";
+  version = "6.2.1";
+
+  src = fetchzip {
+    url = "https://sw-center.st.com/packs/resource/library/stm32cube_mx_v${builtins.replaceStrings ["."] [""] version}-lin.zip";
+    sha256 = "0m5h01iq0mgrr9svj4gmykfi9lsyjpqzrkvlizff26c8dqad59c5";
+    stripRoot = false;
+  };
+
+  nativeBuildInputs = [ icoutils fdupes imagemagick copyDesktopItems];
+  desktopItems = [
+    (makeDesktopItem {
+      name = "stm32CubeMX";
+      exec = "stm32cubemx";
+      desktopName = "STM32CubeMX";
+      categories = "Development;";
+      comment = "STM32Cube initialization code generator";
+      icon = "stm32cubemx";
+    })
+  ];
+
+  buildCommand = ''
+    mkdir -p $out/{bin,opt/STM32CubeMX}
+    cp -r $src/MX/. $out/opt/STM32CubeMX/
+    chmod +rx $out/opt/STM32CubeMX/STM32CubeMX
+    cat << EOF > $out/bin/${pname}
+    #!${stdenv.shell}
+    ${jdk11}/bin/java -jar $out/opt/STM32CubeMX/STM32CubeMX
+    EOF
+    chmod +x $out/bin/${pname}
+
+    icotool --extract $out/opt/STM32CubeMX/help/${iconame}.ico
+    fdupes -dN . > /dev/null
+    ls
+    for size in 16 24 32 48 64 128 256; do
+      mkdir -pv $out/share/icons/hicolor/"$size"x"$size"/apps
+      if [ $size -eq 256 ]; then
+        mv ${iconame}_*_"$size"x"$size"x32.png \
+          $out/share/icons/hicolor/"$size"x"$size"/apps/${pname}.png
+      else
+        convert -resize "$size"x"$size" ${iconame}_*_256x256x32.png \
+          $out/share/icons/hicolor/"$size"x"$size"/apps/${pname}.png
+      fi
+    done;
+  '';
+
+  meta = with lib; {
+    description = "A graphical tool for configuring STM32 microcontrollers and microprocessors";
+    longDescription = ''
+      A graphical tool that allows a very easy configuration of STM32
+      microcontrollers and microprocessors, as well as the generation of the
+      corresponding initialization C code for the Arm® Cortex®-M core or a
+      partial Linux® Device Tree for Arm® Cortex®-A core), through a
+      step-by-step process.
+    '';
+    homepage = "https://www.st.com/en/development-tools/stm32cubemx.html";
+    license = licenses.unfree;
+    maintainers = with maintainers; [ wucke13 ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/stm32flash/default.nix b/nixpkgs/pkgs/development/tools/misc/stm32flash/default.nix
new file mode 100644
index 000000000000..8b9646713e88
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/stm32flash/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  name = "stm32flash-0.5";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/stm32flash/${name}.tar.gz";
+    sha256 = "01p396daqw3zh6nijffbfbwyqza33bi2k4q3m5yjzs02xwi99alp";
+  };
+
+  buildFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
+
+  installPhase = ''
+    # Manually copy, make install copies to /usr/local/bin
+    mkdir -pv $out/bin/
+    cp stm32flash $out/bin/
+  '';
+
+  meta = with lib; {
+    description = "Open source flash program for the STM32 ARM processors using the ST bootloader";
+    homepage = "https://sourceforge.net/projects/stm32flash/";
+    license = lib.licenses.gpl2;
+    platforms = platforms.all; # Should work on all platforms
+    maintainers = with maintainers; [ elitak ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/strace/default.nix b/nixpkgs/pkgs/development/tools/misc/strace/default.nix
new file mode 100644
index 000000000000..4da1a2cba09b
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/strace/default.nix
@@ -0,0 +1,30 @@
+{ lib, stdenv, fetchurl, perl, libunwind, buildPackages }:
+
+stdenv.mkDerivation rec {
+  pname = "strace";
+  version = "5.12";
+
+  src = fetchurl {
+    url = "https://strace.io/files/${version}/${pname}-${version}.tar.xz";
+    sha256 = "sha256-KRce350lL4nJiKTDQN/exmL0WMuMY9hUMdZLq1kR58Q=";
+  };
+
+  depsBuildBuild = [ buildPackages.stdenv.cc ];
+  nativeBuildInputs = [ perl ];
+
+  # On RISC-V platforms, LLVM's libunwind implementation is unsupported by strace.
+  # The build will silently fall back and -k will not work on RISC-V.
+  buildInputs = [ perl.out libunwind ]; # support -k
+
+  postPatch = "patchShebangs --host strace-graph";
+
+  configureFlags = [ "--enable-mpers=check" ];
+
+  meta = with lib; {
+    homepage = "https://strace.io/";
+    description = "A system call tracer for Linux";
+    license =  with licenses; [ lgpl21Plus gpl2Plus ]; # gpl2Plus is for the test suite
+    platforms = platforms.linux;
+    maintainers = with maintainers; [ globin ma27 qyliss ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/svls/default.nix b/nixpkgs/pkgs/development/tools/misc/svls/default.nix
new file mode 100644
index 000000000000..13b529147995
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/svls/default.nix
@@ -0,0 +1,25 @@
+{ lib
+, rustPlatform
+, fetchFromGitHub
+}:
+
+rustPlatform.buildRustPackage rec {
+  pname = "svls";
+  version = "0.1.27";
+
+  src = fetchFromGitHub {
+    owner = "dalance";
+    repo = "svls";
+    rev = "v${version}";
+    sha256 = "sha256-+/4D0pRZs1Gy6DJnsDZA8wWi1FKhr7gRS0oq1TyWpuE=";
+  };
+
+  cargoSha256 = "sha256-xkRlUXlkXQwvzIuhExf+tSSBi+8BZv58btvln05UI+k=";
+
+  meta = with lib; {
+    description = "SystemVerilog language server";
+    homepage = "https://github.com/dalance/svls";
+    license = licenses.mit;
+    maintainers = with maintainers; [ trepetti ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/swig/2.x.nix b/nixpkgs/pkgs/development/tools/misc/swig/2.x.nix
new file mode 100644
index 000000000000..1068b3e2ad9d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/swig/2.x.nix
@@ -0,0 +1,35 @@
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, bison, pcre }:
+
+stdenv.mkDerivation rec {
+  pname = "swig";
+  version = "2.0.12";
+
+  src = fetchFromGitHub {
+    owner = "swig";
+    repo = "swig";
+    rev = "rel-${version}";
+    sha256 = "0khm9gh5pczfcihr0pbicaicc4v9kjm5ip2alvkhmbb3ga6njkcm";
+  };
+
+  nativeBuildInputs = [ autoconf automake libtool bison ];
+  buildInputs = [ pcre ];
+
+  configureFlags = [ "--without-tcl" ];
+
+  # Disable ccache documentation as it needs yodl
+  postPatch = ''
+    sed -i '/man1/d' CCache/Makefile.in
+  '';
+
+  preConfigure = ''
+    ./autogen.sh
+  '';
+
+  meta = with lib; {
+    description = "SWIG, an interface compiler that connects C/C++ code to higher-level languages";
+    homepage = "http://swig.org/";
+    # Different types of licenses available: http://www.swig.org/Release/LICENSE .
+    license = licenses.gpl3Plus;
+    platforms = with platforms; linux ++ darwin;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/swig/3.x.nix b/nixpkgs/pkgs/development/tools/misc/swig/3.x.nix
new file mode 100644
index 000000000000..109243b54ba1
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/swig/3.x.nix
@@ -0,0 +1,36 @@
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, bison, pcre }:
+
+stdenv.mkDerivation rec {
+  pname = "swig";
+  version = "3.0.12";
+
+  src = fetchFromGitHub {
+    owner = "swig";
+    repo = "swig";
+    rev = "rel-${version}";
+    sha256 = "1wyffskbkzj5zyhjnnpip80xzsjcr3p0q5486z3wdwabnysnhn8n";
+  };
+
+  PCRE_CONFIG = "${pcre.dev}/bin/pcre-config";
+  nativeBuildInputs = [ autoconf automake libtool bison ];
+  buildInputs = [ pcre ];
+
+  configureFlags = [ "--without-tcl" ];
+
+  # Disable ccache documentation as it needs yodl
+  postPatch = ''
+    sed -i '/man1/d' CCache/Makefile.in
+  '';
+
+  preConfigure = ''
+    ./autogen.sh
+  '';
+
+  meta = with lib; {
+    description = "An interface compiler that connects C/C++ code to higher-level languages";
+    homepage = "http://swig.org/";
+    # Different types of licenses available: http://www.swig.org/Release/LICENSE .
+    license = licenses.gpl3Plus;
+    platforms = with platforms; linux ++ darwin;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/swig/4.nix b/nixpkgs/pkgs/development/tools/misc/swig/4.nix
new file mode 100644
index 000000000000..56106143027f
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/swig/4.nix
@@ -0,0 +1,37 @@
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, bison, pcre }:
+
+stdenv.mkDerivation rec {
+  pname = "swig";
+  version = "4.0.2";
+
+  src = fetchFromGitHub {
+    owner = "swig";
+    repo = "swig";
+    rev = "rel-${version}";
+    sha256 = "12vlps766xvwck8q0i280s8yx21qm2dxl34710ybpmz3c1cfdjsc";
+  };
+
+  PCRE_CONFIG = "${pcre.dev}/bin/pcre-config";
+  nativeBuildInputs = [ autoconf automake libtool bison ];
+  buildInputs = [ pcre ];
+
+  configureFlags = [ "--without-tcl" ];
+
+  # Disable ccache documentation as it needs yodl
+  postPatch = ''
+    sed -i '/man1/d' CCache/Makefile.in
+  '';
+
+  preConfigure = ''
+    ./autogen.sh
+  '';
+
+  meta = with lib; {
+    description = "SWIG, an interface compiler that connects C/C++ code to higher-level languages";
+    homepage = "http://swig.org/";
+    # Different types of licenses available: http://www.swig.org/Release/LICENSE .
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ orivej ];
+    platforms = with platforms; linux ++ darwin;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/swig/default.nix b/nixpkgs/pkgs/development/tools/misc/swig/default.nix
new file mode 100644
index 000000000000..3c1a5b82dc2a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/swig/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchurl, boost, tcl }:
+
+stdenv.mkDerivation rec {
+  pname = "swig";
+  version = "1.3.40";
+
+  src = fetchurl {
+    url = "mirror://sourceforge/swig/${pname}-${version}.tar.gz";
+    sha256 = "02dc8g8wy75nd2is1974rl24c6mdl0ai1vszs1xpg9nd7dlv6i8r";
+  };
+
+  doCheck = !stdenv.isCygwin;
+  # 'make check' uses boost and tcl
+  buildInputs = lib.optionals doCheck [ boost tcl ];
+
+  configureFlags = [ "--disable-ccache" ];
+
+
+  meta = with lib; {
+    description = "SWIG, an interface compiler that connects C/C++ code to higher-level languages";
+    homepage = "http://swig.org/";
+    # Different types of licenses available: http://www.swig.org/Release/LICENSE .
+    license = licenses.gpl3Plus;
+    platforms = with platforms; linux ++ darwin;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/sysbench/default.nix b/nixpkgs/pkgs/development/tools/misc/sysbench/default.nix
new file mode 100644
index 000000000000..2cf8c91d3bf9
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/sysbench/default.nix
@@ -0,0 +1,27 @@
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, pkg-config
+, libmysqlclient, libaio
+}:
+
+stdenv.mkDerivation rec {
+  pname = "sysbench";
+  version = "1.0.20";
+
+  nativeBuildInputs = [ autoreconfHook pkg-config ];
+  buildInputs = [ libmysqlclient libaio ];
+
+  src = fetchFromGitHub {
+    owner = "akopytov";
+    repo = pname;
+    rev = version;
+    sha256 = "1sanvl2a52ff4shj62nw395zzgdgywplqvwip74ky8q7s6qjf5qy";
+  };
+
+  enableParallelBuilding = true;
+
+  meta = {
+    description = "Modular, cross-platform and multi-threaded benchmark tool";
+    homepage = "https://github.com/akopytov/sysbench";
+    license = lib.licenses.gpl2;
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/tcptrack/default.nix b/nixpkgs/pkgs/development/tools/misc/tcptrack/default.nix
new file mode 100644
index 000000000000..5b1fd72a7f51
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/tcptrack/default.nix
@@ -0,0 +1,25 @@
+{ lib, stdenv, fetchFromGitHub, ncurses, libpcap }:
+
+stdenv.mkDerivation rec {
+  pname = "tcptrack";
+  version = "1.4.3";
+
+  src = fetchFromGitHub {
+    owner = "bchretien";
+    repo = "tcptrack";
+    rev = "d05fe08154ff1e46578e92be49e4cfa2c6543283";
+    sha256 = "08lh3l67wn4kq9q0nfspc7rj0jvp9dzwjgxpvqliwcif8cy5mi45";
+  };
+
+  buildInputs = [ ncurses libpcap ];
+
+  NIX_CFLAGS_COMPILE = "-Wno-error=cpp";
+
+  meta = with lib; {
+    inherit (src.meta) homepage;
+    description = "libpcap based program for live TCP connection monitoring";
+    license = licenses.lgpl21;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor maintainers.vrthra ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/teensy-loader-cli/default.nix b/nixpkgs/pkgs/development/tools/misc/teensy-loader-cli/default.nix
new file mode 100644
index 000000000000..156e3f7f895d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/teensy-loader-cli/default.nix
@@ -0,0 +1,31 @@
+{ lib, stdenv, fetchFromGitHub, go-md2man, installShellFiles, libusb-compat-0_1 }:
+
+stdenv.mkDerivation rec {
+  pname = "teensy-loader-cli";
+  version = "2.1.20191110";
+
+  src = fetchFromGitHub {
+    owner = "PaulStoffregen";
+    repo = "teensy_loader_cli";
+    rev = "e98b5065cdb9f04aa4dde3f2e6e6e6f12dd97592";
+    sha256 = "1yx8vsh6b29pqr4zb6sx47429i9x51hj9psn8zksfz75j5ivfd5i";
+  };
+
+  buildInputs = [ libusb-compat-0_1 ];
+
+  nativeBuildInputs = [ go-md2man installShellFiles ];
+
+  installPhase = ''
+    install -Dm555 teensy_loader_cli $out/bin/teensy-loader-cli
+    install -Dm444 -t $out/share/doc/${pname} *.md *.txt
+    go-md2man -in README.md -out ${pname}.1
+    installManPage *.1
+  '';
+
+  meta = with lib; {
+    description = "Firmware uploader for the Teensy microcontroller boards";
+    homepage = "https://www.pjrc.com/teensy/";
+    license = licenses.gpl3;
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/terracognita/default.nix b/nixpkgs/pkgs/development/tools/misc/terracognita/default.nix
new file mode 100644
index 000000000000..6f02e934394a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/terracognita/default.nix
@@ -0,0 +1,29 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "terracognita";
+  version = "0.6.3";
+
+  src = fetchFromGitHub {
+    owner = "cycloidio";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-rRSBPnvv4941IUGN/6+8/hzgYDqgPErNkd7tFrslPiQ=";
+  };
+
+  vendorSha256 = "sha256-sN9GTcG5cZxvMaLqNjY2jfLkf8a3lugM2aV3bBdT5Ww=";
+
+  doCheck = false;
+
+  subPackages = [ "." ];
+
+  buildFlagsArray = [ "-ldflags=-s -w -X github.com/cycloidio/terracognita/cmd.Version=${version}" ];
+
+  meta = with lib; {
+    description = "Reads from existing Cloud Providers (reverse Terraform) and generates your infrastructure as code on Terraform configuration";
+    homepage = "https://github.com/cycloidio/terracognita";
+    changelog = "https://github.com/cycloidio/terracognita/blob/v${version}/CHANGELOG.md";
+    license = licenses.mit;
+    maintainers = [ maintainers.marsam ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/terraform-ls/default.nix b/nixpkgs/pkgs/development/tools/misc/terraform-ls/default.nix
new file mode 100644
index 000000000000..e189c563e86e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/terraform-ls/default.nix
@@ -0,0 +1,46 @@
+{ lib, buildGoModule, fetchFromGitHub, stdenv }:
+
+buildGoModule rec {
+  pname = "terraform-ls";
+  version = "0.18.1";
+
+  src = fetchFromGitHub {
+    owner = "hashicorp";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-68Hs9kwv7GTGnYtoJh61ubaggPKbxFwz7qDwYaJ74c8=";
+  };
+  vendorSha256 = "sha256-NgOpnCe0uGQVDVKYUIULqPTfvfkDtxIUQiCVwiE7nuc=";
+
+  preBuild = ''
+    buildFlagsArray+=("-ldflags" "-s -w -X main.version=v${version} -X main.prerelease=")
+  '';
+
+  preCheck = ''
+    # Remove tests that requires networking
+    rm internal/terraform/exec/exec_test.go
+  '' + lib.optionalString stdenv.isAarch64 ''
+    # Not all test failures have tracking issues as HashiCorp do not have
+    # aarch64 testing infra easily available, see issue 549 below.
+
+    # Remove file that contains `TestLangServer_workspaceExecuteCommand_modules_multiple`
+    # which fails on aarch64: https://github.com/hashicorp/terraform-ls/issues/549
+    rm internal/langserver/handlers/execute_command_modules_test.go
+
+    # `TestModuleManager_ModuleCandidatesByPath` variants fail
+    rm internal/terraform/module/module_manager_test.go
+
+    # internal/terraform/module/module_ops_queue_test.go:17:15: undefined: testLogger
+    # internal/terraform/module/watcher_test.go:39:11: undefined: testLogger
+    # internal/terraform/module/watcher_test.go:79:14: undefined: testLogger
+    rm internal/terraform/module/{watcher_test,module_ops_queue_test}.go
+  '';
+
+  meta = with lib; {
+    description = "Terraform Language Server (official)";
+    homepage = "https://github.com/hashicorp/terraform-ls";
+    changelog = "https://github.com/hashicorp/terraform-ls/blob/v${version}/CHANGELOG.md";
+    license = licenses.mpl20;
+    maintainers = with maintainers; [ mbaillie jk ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/terraform-lsp/default.nix b/nixpkgs/pkgs/development/tools/misc/terraform-lsp/default.nix
new file mode 100644
index 000000000000..0cfd63ffa283
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/terraform-lsp/default.nix
@@ -0,0 +1,24 @@
+{ lib, buildGoPackage, fetchFromGitHub }:
+
+buildGoPackage rec {
+  pname = "terraform-lsp";
+  version = "0.0.12";
+
+  src = fetchFromGitHub {
+    owner = "juliosueiras";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "111350jbq0dp0qhk48j12hrlisd1fwzqpcv357igrbqf6ki7r78q";
+  };
+
+  goPackagePath = "github.com/juliosueiras/terraform-lsp";
+
+  buildFlagsArray = [ "-ldflags=-s -w -X main.Version=${version} -X main.GitCommit=${src.rev}" ];
+
+  meta = with lib; {
+    description = "Language Server Protocol for Terraform";
+    homepage = "https://github.com/juliosueiras/terraform-lsp";
+    license = licenses.mit;
+    maintainers = [ maintainers.marsam ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/terraformer/default.nix b/nixpkgs/pkgs/development/tools/misc/terraformer/default.nix
new file mode 100644
index 000000000000..60124ef44c93
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/terraformer/default.nix
@@ -0,0 +1,24 @@
+{ lib, buildGoModule, fetchFromGitHub }:
+
+buildGoModule rec {
+  pname = "terraformer";
+  version = "0.8.11";
+
+  src = fetchFromGitHub {
+    owner = "GoogleCloudPlatform";
+    repo = pname;
+    rev = version;
+    sha256 = "sha256-y6cgBYiqy+M8dfcNS6iDohqyip6xAs222MJHJFhloiI=";
+  };
+
+  vendorSha256 = "sha256-PQj3+qcmN/raDrAbufAcVT+vSumGuOY47i7ZYfvx3yk=";
+
+  subPackages = [ "." ];
+
+  meta = with lib; {
+    description = "CLI tool to generate terraform files from existing infrastructure (reverse Terraform). Infrastructure to Code";
+    homepage = "https://github.com/GoogleCloudPlatform/terraformer";
+    license = licenses.asl20;
+    maintainers = [ maintainers.marsam ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/tet/default.nix b/nixpkgs/pkgs/development/tools/misc/tet/default.nix
new file mode 100644
index 000000000000..6bfcb3129236
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/tet/default.nix
@@ -0,0 +1,29 @@
+{ fetchurl, lib, stdenv }:
+
+stdenv.mkDerivation ({
+  version = "3.8";
+  pname = "tet";
+
+  src = fetchurl {
+    url = "http://tetworks.opengroup.org/downloads/38/software/Sources/3.8/tet3.8-src.tar.gz";
+    sha256 = "1j57hv56df38w249l595b8rsgmsyvjkbysai03a9724gax5jl9av" ;
+  };
+
+  buildInputs = [ ];
+
+  patchPhase = "chmod +x configure";
+
+  configurePhase = "./configure -t lite";
+
+  buildPhase = "cd src; make; cd -";
+
+  installPhase = "cd src; make install; cd -; cp -vr $PWD $out";
+
+  meta = {
+    description = "The Test Environment Toolkit is used in test applications like The Open Group's UNIX Certification program and the Free Standards Group's LSB Certification program";
+    homepage = "http://tetworks.opengroup.org/Products/tet.htm";
+    license = lib.licenses.artistic1;
+    platforms = lib.platforms.unix;
+    maintainers = [ ];
+  };
+})
diff --git a/nixpkgs/pkgs/development/tools/misc/texi2html/default.nix b/nixpkgs/pkgs/development/tools/misc/texi2html/default.nix
new file mode 100644
index 000000000000..98f846b7c2f7
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texi2html/default.nix
@@ -0,0 +1,34 @@
+{ lib, stdenv, fetchurl, perl, gettext, buildPackages }:
+
+stdenv.mkDerivation rec {
+  pname = "texi2html";
+  version = "5.0";
+
+  src = fetchurl {
+    url = "mirror://savannah/texi2html/${pname}-${version}.tar.bz2";
+    sha256 = "1yprv64vrlcbksqv25asplnjg07mbq38lfclp1m5lj8cw878pag8";
+  };
+
+  strictDeps = true;
+
+  nativeBuildInputs = [ gettext perl ];
+  buildInputs = [ perl ];
+
+  postPatch = ''
+    patchShebangs separated_to_hash.pl
+  '';
+
+  postInstall = lib.optionalString (stdenv.buildPlatform != stdenv.hostPlatform) ''
+    for f in $out/bin/*; do
+      substituteInPlace $f --replace "${buildPackages.perl}" "${perl}"
+    done
+  '';
+
+  meta = with lib; {
+    description = "Perl script which converts Texinfo source files to HTML output";
+    homepage = "https://www.nongnu.org/texi2html/";
+    license = licenses.gpl2;
+    maintainers = [ maintainers.marcweber ];
+    platforms = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/texinfo/4.13a.nix b/nixpkgs/pkgs/development/tools/misc/texinfo/4.13a.nix
new file mode 100644
index 000000000000..b8da38ace6fb
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texinfo/4.13a.nix
@@ -0,0 +1,19 @@
+{ stdenv, fetchurl, texinfo, ncurses, xz }:
+
+stdenv.mkDerivation rec {
+  pname = "texinfo";
+  version = "4.13a";
+
+  src = fetchurl {
+    url = "mirror://gnu/texinfo/${pname}-${version}.tar.lzma";
+    sha256 = "1rf9ckpqwixj65bw469i634897xwlgkm5i9g2hv3avl6mv7b0a3d";
+  };
+
+  buildInputs = [ ncurses ];
+  nativeBuildInputs = [ xz ];
+
+  # Disabled because we don't have zdiff in the stdenv bootstrap.
+  #doCheck = true;
+
+  meta = texinfo.meta // { branch = version; };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/texinfo/5.2.nix b/nixpkgs/pkgs/development/tools/misc/texinfo/5.2.nix
new file mode 100644
index 000000000000..d395494984d5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texinfo/5.2.nix
@@ -0,0 +1,4 @@
+import ./common.nix {
+  version = "5.2";
+  sha256 = "1njfwh2z34r2c4r0iqa7v24wmjzvsfyz4vplzry8ln3479lfywal";
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/texinfo/6.5.nix b/nixpkgs/pkgs/development/tools/misc/texinfo/6.5.nix
new file mode 100644
index 000000000000..34596f306581
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texinfo/6.5.nix
@@ -0,0 +1,4 @@
+import ./common.nix {
+  version = "6.5";
+  sha256 = "0qjzvbvnv9003xdrcpi3jp7y68j4hq2ciw9frh2hghh698zlnxvp";
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/texinfo/6.7.nix b/nixpkgs/pkgs/development/tools/misc/texinfo/6.7.nix
new file mode 100644
index 000000000000..7915d6e3c6be
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texinfo/6.7.nix
@@ -0,0 +1,4 @@
+import ./common.nix {
+  version = "6.7";
+  sha256 = "1aicn1v3czqii08wc91jw089n1x3gfchkf808q2as59dak0h714q";
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/texinfo/common.nix b/nixpkgs/pkgs/development/tools/misc/texinfo/common.nix
new file mode 100644
index 000000000000..1c5de083bc0d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texinfo/common.nix
@@ -0,0 +1,81 @@
+{ version, sha256 }:
+
+{ lib, stdenv, buildPackages, fetchurl, perl, xz, gettext
+
+# we are a dependency of gcc, this simplifies bootstraping
+, interactive ? false, ncurses, procps
+}:
+
+# Note: this package is used for bootstrapping fetchurl, and thus
+# cannot use fetchpatch! All mutable patches (generated by GitHub or
+# cgit) that are needed here should be included directly in Nixpkgs as
+# files.
+
+let
+  crossBuildTools = stdenv.hostPlatform != stdenv.buildPlatform;
+in
+
+with lib;
+
+stdenv.mkDerivation {
+  name = "texinfo-${optionalString interactive "interactive-"}${version}";
+  inherit version;
+
+  src = fetchurl {
+    url = "mirror://gnu/texinfo/texinfo-${version}.tar.xz";
+    inherit sha256;
+  };
+
+  patches = optional crossBuildTools ./cross-tools-flags.patch;
+
+  # ncurses is required to build `makedoc'
+  # this feature is introduced by the ./cross-tools-flags.patch
+  NATIVE_TOOLS_CFLAGS = if crossBuildTools then "-I${getDev buildPackages.ncurses}/include" else null;
+  NATIVE_TOOLS_LDFLAGS = if crossBuildTools then "-L${getLib buildPackages.ncurses}/lib" else null;
+
+  # We need a native compiler to build perl XS extensions
+  # when cross-compiling.
+  depsBuildBuild = [ buildPackages.stdenv.cc perl ];
+
+  buildInputs = [ xz.bin ]
+    ++ optionals stdenv.isSunOS [ libiconv gawk ]
+    ++ optionals stdenv.isDarwin [ gettext ]
+    ++ optional interactive ncurses;
+
+  configureFlags = [ "PERL=${buildPackages.perl}/bin/perl" ]
+    ++ lib.optional stdenv.isSunOS "AWK=${gawk}/bin/awk";
+
+  installFlags = [ "TEXMF=$(out)/texmf-dist" ];
+  installTargets = [ "install" "install-tex" ];
+
+  checkInputs = [ procps ];
+
+  doCheck = interactive
+    && !stdenv.isDarwin
+    && !stdenv.isSunOS; # flaky
+
+  meta = {
+    homepage = "https://www.gnu.org/software/texinfo/";
+    description = "The GNU documentation system";
+    license = licenses.gpl3Plus;
+    platforms = platforms.all;
+    maintainers = with maintainers; [ vrthra oxij ];
+
+    longDescription = ''
+      Texinfo is the official documentation format of the GNU project.
+      It was invented by Richard Stallman and Bob Chassell many years
+      ago, loosely based on Brian Reid's Scribe and other formatting
+      languages of the time.  It is used by many non-GNU projects as
+      well.
+
+      Texinfo uses a single source file to produce output in a number
+      of formats, both online and printed (dvi, html, info, pdf, xml,
+      etc.).  This means that instead of writing different documents
+      for online information and another for a printed manual, you
+      need write only one document.  And when the work is revised, you
+      need revise only that one document.  The Texinfo system is
+      well-integrated with GNU Emacs.
+    '';
+    branch = version;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/texinfo/cross-tools-flags.patch b/nixpkgs/pkgs/development/tools/misc/texinfo/cross-tools-flags.patch
new file mode 100644
index 000000000000..f0a8c4dfdc1e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texinfo/cross-tools-flags.patch
@@ -0,0 +1,13 @@
+diff -ur texinfo-6.5/configure texinfo-6.5-patched/configure
+--- texinfo-6.5/configure	2017-09-13 03:50:18.000000000 +0900
++++ texinfo-6.5-patched/configure	2019-12-28 17:39:06.692818866 +0900
+@@ -23281,7 +23281,7 @@
+   # env -i gives this build host configure a clean environment;
+   # consequently, we have to re-initialize $PATH.
+-  env -i CC="$BUILD_CC" AR="$BUILD_AR" RANLIB="$BUILD_RANLIB" \
+-      PATH="$PATH" \
++  env -i CC="$CC_FOR_BUILD" AR="$AR_FOR_BUILD" RANLIB="$RANLIB_FOR_BUILD" \
++      PATH="$PATH" CFLAGS="$NATIVE_TOOLS_CFLAGS" LDFLAGS="$NATIVE_TOOLS_LDFLAGS" \
+       tools_only=1 \
+     ${confdir}/configure --build=${build} --host=${build} \
+                          --disable-rpath --disable-nls
diff --git a/nixpkgs/pkgs/development/tools/misc/texlab/default.nix b/nixpkgs/pkgs/development/tools/misc/texlab/default.nix
new file mode 100644
index 000000000000..42a30cce8eb9
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/texlab/default.nix
@@ -0,0 +1,48 @@
+{ lib
+, stdenv
+, rustPlatform
+, fetchFromGitHub
+, installShellFiles
+, libiconv
+, Security
+, CoreServices
+}:
+
+rustPlatform.buildRustPackage rec {
+  pname = "texlab";
+  version = "3.2.0";
+
+  src = fetchFromGitHub {
+    owner = "latex-lsp";
+    repo = pname;
+    rev = "v${version}";
+    hash = "sha256-iXsV7zt190GH0kTMpdmf8xHk4cqtCVwq6LDICmhe5qU=";
+  };
+
+  cargoHash = "sha256-Yqn6VpAKw93QvkxuwNcYvrQm0C4TfisRDcmFy95/yw8=";
+
+  outputs = [ "out" "man" ];
+
+  nativeBuildInputs = [ installShellFiles ];
+
+  buildInputs = lib.optionals stdenv.isDarwin [ libiconv Security CoreServices ];
+
+  postInstall = ''
+    installManPage texlab.1
+
+    # Remove generated dylib of html2md dependency. TexLab statically
+    # links to the generated rlib and doesn't reference the dylib. I
+    # couldn't find any way to prevent building this by passing cargo flags.
+    # See https://gitlab.com/Kanedias/html2md/-/blob/0.2.10/Cargo.toml#L20
+    rm "$out/lib/libhtml2md${stdenv.hostPlatform.extensions.sharedLibrary}"
+    rmdir "$out/lib"
+  '';
+
+  meta = with lib; {
+    description = "An implementation of the Language Server Protocol for LaTeX";
+    homepage = "https://texlab.netlify.app";
+    license = licenses.mit;
+    maintainers = with maintainers; [ doronbehar kira-bruneau ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/tie/default.nix b/nixpkgs/pkgs/development/tools/misc/tie/default.nix
new file mode 100644
index 000000000000..52a740ed1c8c
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/tie/default.nix
@@ -0,0 +1,28 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  pname = "tie";
+  version = "2.4";
+
+  src = fetchurl {
+    url = "http://mirrors.ctan.org/web/tie/${pname}-${version}.tar.gz";
+    sha256 = "1m5952kdfffiz33p1jw0wv7dh272mmw28mpxw9v7lkb352zv4xsj";
+  };
+
+  buildPhase = ''
+    ${stdenv.cc.targetPrefix}cc tie.c -o tie
+  '';
+
+  installPhase = ''
+    mkdir -p $out/bin
+    cp tie $out/bin
+  '';
+
+  meta = with lib; {
+    homepage = "https://www.ctan.org/tex-archive/web/tie";
+    description = "Allow multiple web change files";
+    platforms = platforms.all;
+    maintainers = with maintainers; [ vrthra ];
+    license = licenses.abstyles;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/tinyprog/default.nix b/nixpkgs/pkgs/development/tools/misc/tinyprog/default.nix
new file mode 100644
index 000000000000..06a8c3e98712
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/tinyprog/default.nix
@@ -0,0 +1,43 @@
+{ lib
+, python3Packages
+, fetchFromGitHub
+}:
+
+with python3Packages; buildPythonApplication rec {
+  pname = "tinyprog";
+  # `python setup.py --version` from repo checkout
+  version = "1.0.24.dev114+g${lib.substring 0 7 src.rev}";
+
+  src = fetchFromGitHub {
+    owner = "tinyfpga";
+    repo = "TinyFPGA-Bootloader";
+    rev = "97f6353540bf7c0d27f5612f202b48f41da75299";
+    sha256 = "0zbrvvb957z2lwbfd39ixqdsnd2w4wfjirwkqdrqm27bjz308731";
+  };
+
+  sourceRoot = "source/programmer";
+
+  propagatedBuildInputs = [
+    pyserial
+    jsonmerge
+    intelhex
+    tqdm
+    six
+    packaging
+    setuptools
+    pyusb
+  ];
+
+  nativeBuildInputs = [ setuptools-scm ];
+
+  preBuild = ''
+    export SETUPTOOLS_SCM_PRETEND_VERSION="${version}"
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/tinyfpga/TinyFPGA-Bootloader/tree/master/programmer";
+    description = "Programmer for FPGA boards using the TinyFPGA USB Bootloader";
+    maintainers = with maintainers; [ emily ];
+    license = licenses.asl20;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/tockloader/default.nix b/nixpkgs/pkgs/development/tools/misc/tockloader/default.nix
new file mode 100644
index 000000000000..8924cbf2fae5
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/tockloader/default.nix
@@ -0,0 +1,37 @@
+{ lib
+, python3Packages
+}:
+
+python3Packages.buildPythonApplication rec {
+  pname = "tockloader";
+  version = "1.6.0";
+
+  src = python3Packages.fetchPypi {
+    inherit pname version;
+    sha256 = "1aqkj1nplcw3gmklrhq6vxy6v9ad5mqiw4y1svasak2zkqdk1wyc";
+  };
+
+  propagatedBuildInputs = with python3Packages; [
+    argcomplete
+    colorama
+    crcmod
+    pyserial
+    pytoml
+    tqdm
+  ];
+
+  # has no test suite
+  checkPhase = ''
+    runHook preCheck
+    $out/bin/tockloader --version | grep -q ${version}
+    runHook postCheck
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/tock/tockloader";
+    license = licenses.mit;
+    description = "Tool for programming Tock onto hardware boards";
+    maintainers = with maintainers; [ ];
+  };
+}
+
diff --git a/nixpkgs/pkgs/development/tools/misc/tokei/default.nix b/nixpkgs/pkgs/development/tools/misc/tokei/default.nix
new file mode 100644
index 000000000000..e87f07067561
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/tokei/default.nix
@@ -0,0 +1,32 @@
+{ lib, stdenv, fetchFromGitHub, rustPlatform, libiconv, Security }:
+
+rustPlatform.buildRustPackage rec {
+  pname = "tokei";
+  version = "12.1.2";
+
+  src = fetchFromGitHub {
+    owner = "XAMPPRocky";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "sha256-jqDsxUAMD/MCCI0hamkGuCYa8rEXNZIR8S+84S8FbgI=";
+  };
+
+  cargoSha256 = "sha256-U7Bode8qwDsNf4FVppfEHA9uiOFz74CtKgXG6xyYlT8=";
+
+  buildInputs = lib.optionals stdenv.isDarwin [
+    libiconv Security
+  ];
+
+  # enable all output formats
+  cargoBuildFlags = [ "--features" "all" ];
+
+  meta = with lib; {
+    description = "A program that allows you to count your code, quickly";
+    longDescription = ''
+      Tokei is a program that displays statistics about your code. Tokei will show number of files, total lines within those files and code, comments, and blanks grouped by language.
+    '';
+    homepage = "https://github.com/XAMPPRocky/tokei";
+    license = with licenses; [ asl20 /* or */ mit ];
+    maintainers = with maintainers; [ gebner lilyball ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/travis/Gemfile b/nixpkgs/pkgs/development/tools/misc/travis/Gemfile
new file mode 100644
index 000000000000..3da9975913e8
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/travis/Gemfile
@@ -0,0 +1,4 @@
+source "https://rubygems.org"
+
+gem "travis"
+gem "pry", "~> 0.11.0"
diff --git a/nixpkgs/pkgs/development/tools/misc/travis/Gemfile.lock b/nixpkgs/pkgs/development/tools/misc/travis/Gemfile.lock
new file mode 100644
index 000000000000..91df15a9bb65
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/travis/Gemfile.lock
@@ -0,0 +1,71 @@
+GEM
+  remote: https://rubygems.org/
+  specs:
+    activesupport (5.2.4.3)
+      concurrent-ruby (~> 1.0, >= 1.0.2)
+      i18n (>= 0.7, < 2)
+      minitest (~> 5.1)
+      tzinfo (~> 1.1)
+    addressable (2.7.0)
+      public_suffix (>= 2.0.2, < 5.0)
+    coderay (1.1.3)
+    concurrent-ruby (1.1.6)
+    ethon (0.12.0)
+      ffi (>= 1.3.0)
+    faraday (1.0.1)
+      multipart-post (>= 1.2, < 3)
+    faraday_middleware (1.0.0)
+      faraday (~> 1.0)
+    ffi (1.13.1)
+    gh (0.17.0)
+      activesupport (~> 5.0)
+      addressable (~> 2.4)
+      faraday (~> 1.0)
+      faraday_middleware (~> 1.0)
+      multi_json (~> 1.0)
+      net-http-persistent (~> 2.9)
+      net-http-pipeline
+    highline (2.0.3)
+    i18n (1.8.3)
+      concurrent-ruby (~> 1.0)
+    json (2.3.0)
+    launchy (2.4.3)
+      addressable (~> 2.3)
+    method_source (0.9.2)
+    minitest (5.14.1)
+    multi_json (1.14.1)
+    multipart-post (2.1.1)
+    net-http-persistent (2.9.4)
+    net-http-pipeline (1.0.1)
+    pry (0.11.3)
+      coderay (~> 1.1.0)
+      method_source (~> 0.9.0)
+    public_suffix (4.0.5)
+    pusher-client (0.6.2)
+      json
+      websocket (~> 1.0)
+    thread_safe (0.3.6)
+    travis (1.9.1)
+      faraday (~> 1.0)
+      faraday_middleware (~> 1.0)
+      gh (~> 0.13)
+      highline (~> 2.0)
+      json (~> 2.3)
+      launchy (~> 2.1, < 2.5.0)
+      pusher-client (~> 0.4)
+      typhoeus (~> 0.6, >= 0.6.8)
+    typhoeus (0.8.0)
+      ethon (>= 0.8.0)
+    tzinfo (1.2.7)
+      thread_safe (~> 0.1)
+    websocket (1.2.8)
+
+PLATFORMS
+  ruby
+
+DEPENDENCIES
+  pry (~> 0.11.0)
+  travis
+
+BUNDLED WITH
+   2.1.4
diff --git a/nixpkgs/pkgs/development/tools/misc/travis/default.nix b/nixpkgs/pkgs/development/tools/misc/travis/default.nix
new file mode 100644
index 000000000000..0be7721fe080
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/travis/default.nix
@@ -0,0 +1,16 @@
+{ lib, bundlerEnv, ruby, bundlerUpdateScript }:
+
+bundlerEnv {
+  inherit ruby;
+  pname = "travis";
+  gemdir = ./.;
+
+  passthru.updateScript = bundlerUpdateScript "travis";
+
+  meta = with lib; {
+    description = "CLI and Ruby client library for Travis CI";
+    homepage    = "https://github.com/travis-ci/travis.rb";
+    license     = licenses.mit;
+    maintainers = with maintainers; [ zimbatm nicknovitski ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/travis/gemset.nix b/nixpkgs/pkgs/development/tools/misc/travis/gemset.nix
new file mode 100644
index 000000000000..02b39bfca947
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/travis/gemset.nix
@@ -0,0 +1,269 @@
+{
+  activesupport = {
+    dependencies = ["concurrent-ruby" "i18n" "minitest" "tzinfo"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "02fdawr3wyvpzpja3r7mvb8lmn2mm5jdw502bx3ncr2sy2nw1kx6";
+      type = "gem";
+    };
+    version = "5.2.4.3";
+  };
+  addressable = {
+    dependencies = ["public_suffix"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy";
+      type = "gem";
+    };
+    version = "2.7.0";
+  };
+  coderay = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0jvxqxzply1lwp7ysn94zjhh57vc14mcshw1ygw14ib8lhc00lyw";
+      type = "gem";
+    };
+    version = "1.1.3";
+  };
+  concurrent-ruby = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "094387x4yasb797mv07cs3g6f08y56virc2rjcpb1k79rzaj3nhl";
+      type = "gem";
+    };
+    version = "1.1.6";
+  };
+  ethon = {
+    dependencies = ["ffi"];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0gggrgkcq839mamx7a8jbnp2h7x2ykfn34ixwskwb0lzx2ak17g9";
+      type = "gem";
+    };
+    version = "0.12.0";
+  };
+  faraday = {
+    dependencies = ["multipart-post"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0wwks9652xwgjm7yszcq5xr960pjypc07ivwzbjzpvy9zh2fw6iq";
+      type = "gem";
+    };
+    version = "1.0.1";
+  };
+  faraday_middleware = {
+    dependencies = ["faraday"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0jik2kgfinwnfi6fpp512vlvs0mlggign3gkbpkg5fw1jr9his0r";
+      type = "gem";
+    };
+    version = "1.0.0";
+  };
+  ffi = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "12lpwaw82bb0rm9f52v1498bpba8aj2l2q359mkwbxsswhpga5af";
+      type = "gem";
+    };
+    version = "1.13.1";
+  };
+  gh = {
+    dependencies = ["activesupport" "addressable" "faraday" "faraday_middleware" "multi_json" "net-http-persistent" "net-http-pipeline"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1nj2dm2pahfa4d39y8csvjv5l3hpsm6yjq2y96vj2bqgg0qs26bj";
+      type = "gem";
+    };
+    version = "0.17.0";
+  };
+  highline = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0yclf57n2j3cw8144ania99h1zinf8q3f5zrhqa754j6gl95rp9d";
+      type = "gem";
+    };
+    version = "2.0.3";
+  };
+  i18n = {
+    dependencies = ["concurrent-ruby"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "10nq1xjqvkhngiygji831qx9bryjwws95r4vrnlq9142bzkg670s";
+      type = "gem";
+    };
+    version = "1.8.3";
+  };
+  json = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0nrmw2r4nfxlfgprfgki3hjifgrcrs3l5zvm3ca3gb4743yr25mn";
+      type = "gem";
+    };
+    version = "2.3.0";
+  };
+  launchy = {
+    dependencies = ["addressable"];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "190lfbiy1vwxhbgn4nl4dcbzxvm049jwc158r2x7kq3g5khjrxa2";
+      type = "gem";
+    };
+    version = "2.4.3";
+  };
+  method_source = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1pviwzvdqd90gn6y7illcdd9adapw8fczml933p5vl739dkvl3lq";
+      type = "gem";
+    };
+    version = "0.9.2";
+  };
+  minitest = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "09bz9nsznxgaf06cx3b5z71glgl0hdw469gqx3w7bqijgrb55p5g";
+      type = "gem";
+    };
+    version = "5.14.1";
+  };
+  multi_json = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0xy54mjf7xg41l8qrg1bqri75agdqmxap9z466fjismc1rn2jwfr";
+      type = "gem";
+    };
+    version = "1.14.1";
+  };
+  multipart-post = {
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1zgw9zlwh2a6i1yvhhc4a84ry1hv824d6g2iw2chs3k5aylpmpfj";
+      type = "gem";
+    };
+    version = "2.1.1";
+  };
+  net-http-persistent = {
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1y9fhaax0d9kkslyiqi1zys6cvpaqx9a0y0cywp24rpygwh4s9r4";
+      type = "gem";
+    };
+    version = "2.9.4";
+  };
+  net-http-pipeline = {
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0bxjy33yhxwsbnld8xj3zv64ibgfjn9rjpiqkyd5ipmz50pww8v9";
+      type = "gem";
+    };
+    version = "1.0.1";
+  };
+  pry = {
+    dependencies = ["coderay" "method_source"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1mh312k3y94sj0pi160wpia0ps8f4kmzvm505i6bvwynfdh7v30g";
+      type = "gem";
+    };
+    version = "0.11.3";
+  };
+  public_suffix = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0vywld400fzi17cszwrchrzcqys4qm6sshbv73wy5mwcixmrgg7g";
+      type = "gem";
+    };
+    version = "4.0.5";
+  };
+  pusher-client = {
+    dependencies = ["json" "websocket"];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "18ymxz34gmg7jff3h0nyzp5vdg5i06dbdxlrdl2nq4hf14qwj1f4";
+      type = "gem";
+    };
+    version = "0.6.2";
+  };
+  thread_safe = {
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0nmhcgq6cgz44srylra07bmaw99f5271l0dpsvl5f75m44l0gmwy";
+      type = "gem";
+    };
+    version = "0.3.6";
+  };
+  travis = {
+    dependencies = ["faraday" "faraday_middleware" "gh" "highline" "json" "launchy" "pusher-client" "typhoeus"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1yizj5nqvyrfbyiv1kfwc33dylhsmk5l007z06djj152v04z63i3";
+      type = "gem";
+    };
+    version = "1.9.1";
+  };
+  typhoeus = {
+    dependencies = ["ethon"];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "03x3fxjsnhgayl4s96h0a9975awlvx2v9nmx2ba0cnliglyczdr8";
+      type = "gem";
+    };
+    version = "0.8.0";
+  };
+  tzinfo = {
+    dependencies = ["thread_safe"];
+    groups = ["default"];
+    platforms = [];
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1i3jh086w1kbdj3k5l60lc3nwbanmzdf8yjj3mlrx9b2gjjxhi9r";
+      type = "gem";
+    };
+    version = "1.2.7";
+  };
+  websocket = {
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "0f11rcn4qgffb1rq4kjfwi7di79w8840x9l74pkyif5arp0mb08x";
+      type = "gem";
+    };
+    version = "1.2.8";
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/travis/shell.nix b/nixpkgs/pkgs/development/tools/misc/travis/shell.nix
new file mode 100644
index 000000000000..ddcf493bb468
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/travis/shell.nix
@@ -0,0 +1,11 @@
+# Env to update Gemfile.lock / gemset.nix
+
+with import <nixpkgs> {};
+stdenv.mkDerivation {
+  name = "env";
+  buildInputs = [
+    ruby.devEnv
+    gnumake
+    bundix
+  ];
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/uisp/default.nix b/nixpkgs/pkgs/development/tools/misc/uisp/default.nix
new file mode 100644
index 000000000000..1fb255073ed8
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/uisp/default.nix
@@ -0,0 +1,19 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation {
+  name = "uisp-20050207";
+
+  src = fetchurl {
+    url = "http://mirror.switch.ch/mirror/gentoo/distfiles/uisp-20050207.tar.gz";
+    sha256 = "1bncxp5yxh9r1yrp04vvhfiva8livi1pwic7v8xj99q09zrwahvw";
+  };
+
+  NIX_CFLAGS_COMPILE = "-Wno-error";
+
+  meta = {
+    description = "Tool for AVR microcontrollers which can interface to many hardware in-system programmers";
+    license = lib.licenses.gpl2;
+    homepage = "https://savannah.nongnu.org/projects/uisp";
+    platforms = lib.platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/uncrustify/default.nix b/nixpkgs/pkgs/development/tools/misc/uncrustify/default.nix
new file mode 100644
index 000000000000..759c83e81c8a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/uncrustify/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchFromGitHub, cmake, python }:
+
+stdenv.mkDerivation rec {
+  name = "${product}-${version}";
+  product = "uncrustify";
+  version = "0.72.0";
+
+  src = fetchFromGitHub {
+    owner = product;
+    repo = product;
+    rev = name;
+    sha256 = "sha256-ZVC5tsn2m1uB7EPNJFPLWLZpLSk4WrFOgJvy1KFYqBY=";
+  };
+
+  nativeBuildInputs = [ cmake python ];
+
+  meta = with lib; {
+    description = "Source code beautifier for C, C++, C#, ObjectiveC, D, Java, Pawn and VALA";
+    homepage = "http://uncrustify.sourceforge.net/";
+    license = licenses.gpl2Plus;
+    platforms = platforms.unix;
+    maintainers = [ maintainers.bjornfor ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/unifdef/default.nix b/nixpkgs/pkgs/development/tools/misc/unifdef/default.nix
new file mode 100644
index 000000000000..ebb034a92e72
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/unifdef/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchurl }:
+
+stdenv.mkDerivation rec {
+  pname = "unifdef";
+  version = "2.12";
+
+  src = fetchurl {
+    url = "https://dotat.at/prog/unifdef/unifdef-${version}.tar.xz";
+    sha256 = "00647bp3m9n01ck6ilw6r24fk4mivmimamvm4hxp5p6wxh10zkj3";
+  };
+
+  makeFlags = [
+    "prefix=$(out)"
+    "DESTDIR="
+  ];
+
+  meta = with lib; {
+    homepage = "https://dotat.at/prog/unifdef/";
+    description = "Selectively remove C preprocessor conditionals";
+    license = licenses.bsd2;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ orivej vrthra ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/universal-ctags/default.nix b/nixpkgs/pkgs/development/tools/misc/universal-ctags/default.nix
new file mode 100644
index 000000000000..6c1a9009993d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/universal-ctags/default.nix
@@ -0,0 +1,50 @@
+{ lib, stdenv, fetchFromGitHub, autoreconfHook, coreutils, pkg-config, perl, python3Packages, libiconv, jansson }:
+
+stdenv.mkDerivation rec {
+  pname = "universal-ctags";
+  version = "5.9.20210411.0";
+
+  src = fetchFromGitHub {
+    owner = "universal-ctags";
+    repo = "ctags";
+    rev = "p${version}";
+    sha256 = "0c031y0dl2b70pd0mqfbylplf8f27x11b0ch7ljka3rqav0zb1zr";
+  };
+
+  nativeBuildInputs = [ autoreconfHook coreutils pkg-config python3Packages.docutils ];
+  buildInputs = [ jansson ] ++ lib.optional stdenv.isDarwin libiconv;
+
+  # to generate makefile.in
+  autoreconfPhase = ''
+    ./autogen.sh
+  '';
+
+  configureFlags = [ "--enable-tmpdir=/tmp" ];
+
+  postPatch = ''
+    # Remove source of non-determinism
+    substituteInPlace main/options.c \
+      --replace "printf (\"  Compiled: %s, %s\n\", __DATE__, __TIME__);" ""
+
+    substituteInPlace Tmain/utils.sh \
+      --replace /bin/echo ${coreutils}/bin/echo
+  '';
+
+  postConfigure = ''
+    sed -i 's|/usr/bin/env perl|${perl}/bin/perl|' misc/optlib2c
+  '';
+
+  doCheck = true;
+
+  checkFlags = [ "units" ];
+
+  meta = with lib; {
+    description = "A maintained ctags implementation";
+    homepage = "https://ctags.io/";
+    license = licenses.gpl2Plus;
+    platforms = platforms.unix;
+    # universal-ctags is preferred over emacs's ctags
+    priority = 1;
+    maintainers = [ maintainers.mimame ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/universal-ctags/sed-test.patch b/nixpkgs/pkgs/development/tools/misc/universal-ctags/sed-test.patch
new file mode 100644
index 000000000000..7c44d699d79a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/universal-ctags/sed-test.patch
@@ -0,0 +1,12 @@
+--- a/Tmain/sorted-help-message.d/run.sh	2017-01-10 11:20:51.515093465 +0100
++++ b/Tmain/sorted-help-message.d/run.sh	2017-01-10 11:17:56.639213720 +0100
+@@ -27,7 +27,7 @@
+ extract_long_options()
+ {
+     sed -n '/Usage:/,$p'  | \
+-    sed -n 's/\(^  --[:alnum:][<>[:alnum:]_-]*\).*/\1/p'
++    sed -n 's/\(^  --[[:alnum:]][<>[:alnum:]_-]*\).*/\1/p'
+ }
+
+ extract_debug_options()
+
diff --git a/nixpkgs/pkgs/development/tools/misc/unused/default.nix b/nixpkgs/pkgs/development/tools/misc/unused/default.nix
new file mode 100644
index 000000000000..ee89df5d8391
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/unused/default.nix
@@ -0,0 +1,23 @@
+{ lib, fetchFromGitHub, rustPlatform, cmake }:
+rustPlatform.buildRustPackage rec {
+  pname = "unused";
+  version = "0.2.2";
+
+  src = fetchFromGitHub {
+    owner = "unused-code";
+    repo = pname;
+    rev = version;
+    sha256 = "0igpf0y45rrdrwq8bznq0d5nnph0vijvn6fw96mqxhbffz0csbi9";
+  };
+
+  nativeBuildInputs = [ cmake ];
+
+  cargoSha256 = "1fngn9mmvx7jw8305w465z0nf9acc2cdl7314p77c2rz25z6rlin";
+
+  meta = with lib; {
+    description = "A tool to identify potentially unused code";
+    homepage = "https://unused.codes";
+    license = licenses.mit;
+    maintainers = [ maintainers.lrworth ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/configurable-usb-modeswitch.patch b/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/configurable-usb-modeswitch.patch
new file mode 100644
index 000000000000..d55caab22e69
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/configurable-usb-modeswitch.patch
@@ -0,0 +1,283 @@
+Index: usb-modeswitch-2.6.0/Makefile
+===================================================================
+--- usb-modeswitch-2.6.0.orig/Makefile
++++ usb-modeswitch-2.6.0/Makefile
+@@ -5,17 +5,24 @@ CFLAGS      += -Wall -Wno-deprecated-dec
+ LIBS        = `pkg-config --libs --cflags libusb-1.0`
+ RM          = /bin/rm -f
+ OBJS        = usb_modeswitch.c
+-PREFIX      = $(DESTDIR)/usr
+-ETCDIR      = $(DESTDIR)/etc
++PREFIX      = /usr/local
++ETCDIR      = $(PREFIX)/etc
+ SYSDIR      = $(ETCDIR)/systemd/system
+ UPSDIR      = $(ETCDIR)/init
+-UDEVDIR     = $(DESTDIR)/lib/udev
++UDEVDIR     = $(PREFIX)/lib/udev
+ SBINDIR     = $(PREFIX)/sbin
+ MANDIR      = $(PREFIX)/share/man/man1
+ 
++USE_UPSTART=$(shell if command -v initctl > /dev/null; then echo "true"; fi)
++USE_SYSTEMD=$(shell if command -v systemctl > /dev/null; then echo "true"; fi)
++
+ .PHONY: clean install install-common uninstall \
+ 	dispatcher-script dispatcher-dynlink dispatcher-statlink \
+-	install-script install-dynlink install-statlink
++	install-script install-dynlink install-statlink \
++	install-upstart install-systemd \
++	configure-dispatcher configure-script \
++	configure-upstart configure-systemd \
++	configure
+ 
+ all: all-with-script-dispatcher
+ 
+@@ -28,7 +35,25 @@ all-with-statlink-dispatcher: $(PROG) di
+ $(PROG): $(OBJS) usb_modeswitch.h
+ 	$(CC) -o $(PROG) $(OBJS) $(CFLAGS) $(LIBS) $(LDFLAGS)
+ 
+-dispatcher-script: usb_modeswitch_dispatcher.tcl
++configure-dispatcher:
++	sed -i \
++	  -e 's,^\(set setup(sbindir) \).*$$,\1$(SBINDIR),' \
++	  -e 's,^\(set setup(etcdir) \).*$$,\1$(ETCDIR),' \
++	  usb_modeswitch_dispatcher.tcl
++
++configure-script:
++	sed -i -e 's,^\(SBINDIR=\).*$$,\1$(SBINDIR),' usb_modeswitch.sh
++
++configure-systemd:
++	sed -i -e 's,@sbindir@,$(SBINDIR),' usb_modeswitch@.service
++
++configure-upstart:
++	sed -i -e 's,@sbindir@,$(SBINDIR),' usb-modeswitch-upstart.conf
++
++configure: configure-dispatcher configure-script \
++	configure-systemd configure-upstart
++
++dispatcher-script: configure-dispatcher usb_modeswitch_dispatcher.tcl
+ 	DISPATCH=dispatcher-script
+ 	cp -f usb_modeswitch_dispatcher.tcl usb_modeswitch_dispatcher
+ 
+@@ -53,16 +78,28 @@ distclean: clean
+ # If the systemd folder is present, install the service for starting the dispatcher
+ # If not, use the dispatcher directly from the udev rule as in previous versions
+ 
+-install-common: $(PROG) $(DISPATCH)
+-	install -D --mode=755 usb_modeswitch $(SBINDIR)/usb_modeswitch
+-	install -D --mode=755 usb_modeswitch.sh $(UDEVDIR)/usb_modeswitch
+-	install -D --mode=644 usb_modeswitch.conf $(ETCDIR)/usb_modeswitch.conf
+-	install -D --mode=644 usb_modeswitch.1 $(MANDIR)/usb_modeswitch.1
+-	install -D --mode=644 usb_modeswitch_dispatcher.1 $(MANDIR)/usb_modeswitch_dispatcher.1
+-	install -D --mode=755 usb_modeswitch_dispatcher $(SBINDIR)/usb_modeswitch_dispatcher
++install-common: $(PROG) configure $(DISPATCH)
++	install -D --mode=755 usb_modeswitch $(DESTDIR)$(SBINDIR)/usb_modeswitch
++	install -D --mode=755 usb_modeswitch.sh $(DESTDIR)$(UDEVDIR)/usb_modeswitch
++	install -D --mode=644 usb_modeswitch.conf $(DESTDIR)$(ETCDIR)/usb_modeswitch.conf
++	install -D --mode=644 usb_modeswitch.1 $(DESTDIR)$(MANDIR)/usb_modeswitch.1
++	install -D --mode=644 usb_modeswitch_dispatcher.1 $(DESTDIR)$(MANDIR)/usb_modeswitch_dispatcher.1
++	install -D --mode=755 usb_modeswitch_dispatcher $(DESTDIR)$(SBINDIR)/usb_modeswitch_dispatcher
+ 	install -d $(DESTDIR)/var/lib/usb_modeswitch
+-	test -d $(UPSDIR) -a -e /sbin/initctl && install --mode=644 usb-modeswitch-upstart.conf $(UPSDIR) || test 1
+-	test -d $(SYSDIR) -a \( -e /usr/bin/systemctl -o -e /bin/systemctl \) && install --mode=644 usb_modeswitch@.service $(SYSDIR) || test 1
++
++install-upstart:
++	install -D --mode=644 usb-modeswitch-upstart.conf $(DESTDIR)$(UPSDIR)/usb-modeswitch-upstart.conf
++
++install-systemd:
++	install -D --mode=644 usb_modeswitch@.service $(DESTDIR)$(SYSDIR)/usb_modeswitch@.service
++
++ifeq ($(USE_UPSTART),true)
++install-common: install-upstart
++endif
++
++ifeq ($(USE_SYSTEMD),true)
++install-common: install-systemd
++endif
+ 
+ install: install-script
+ 
+@@ -73,10 +110,10 @@ install-dynlink: dispatcher-dynlink inst
+ install-statlink: dispatcher-statlink install-common
+ 
+ uninstall:
+-	$(RM) $(SBINDIR)/usb_modeswitch
+-	$(RM) $(SBINDIR)/usb_modeswitch_dispatcher
+-	$(RM) $(UDEVDIR)/usb_modeswitch
+-	$(RM) $(ETCDIR)/usb_modeswitch.conf
+-	$(RM) $(MANDIR)/usb_modeswitch.1
++	$(RM) $(DESTDIR)$(SBINDIR)/usb_modeswitch
++	$(RM) $(DESTDIR)$(SBINDIR)/usb_modeswitch_dispatcher
++	$(RM) $(DESTDIR)$(UDEVDIR)/usb_modeswitch
++	$(RM) $(DESTDIR)$(ETCDIR)/usb_modeswitch.conf
++	$(RM) $(DESTDIR)$(MANDIR)/usb_modeswitch.1
+ 	$(RM) -R $(DESTDIR)/var/lib/usb_modeswitch
+-	$(RM) $(SYSDIR)/usb_modeswitch@.service
++	$(RM) $(DESTDIR)$(SYSDIR)/usb_modeswitch@.service
+Index: usb-modeswitch-2.6.0/usb-modeswitch-upstart.conf
+===================================================================
+--- usb-modeswitch-2.6.0.orig/usb-modeswitch-upstart.conf
++++ usb-modeswitch-2.6.0/usb-modeswitch-upstart.conf
+@@ -1,5 +1,5 @@
+ start on usb-modeswitch-upstart
+ task
+ script
+-	exec /usr/sbin/usb_modeswitch_dispatcher --switch-mode $UMS_PARAM
++	exec @sbindir@/usb_modeswitch_dispatcher --switch-mode $UMS_PARAM
+ end script
+Index: usb-modeswitch-2.6.0/usb_modeswitch.sh
+===================================================================
+--- usb-modeswitch-2.6.0.orig/usb_modeswitch.sh
++++ usb-modeswitch-2.6.0/usb_modeswitch.sh
+@@ -1,5 +1,9 @@
+ #!/bin/sh
+ # part of usb_modeswitch 2.6.0
++
++# Compile time configuration, injected by the Makefile
++SBINDIR=/usr/sbin
++
+ device_in()
+ {
+ 	if [ ! -e /var/lib/usb_modeswitch/$1 ]; then
+@@ -37,7 +41,7 @@ if [ $(expr "$1" : "--.*") ]; then
+ 		v_id=$3
+ 	fi
+ fi
+-PATH=/sbin:/usr/sbin:$PATH
++
+ case "$1" in
+ 	--driver-bind)
+ 		# driver binding code removed
+@@ -46,9 +50,7 @@ case "$1" in
+ 	--symlink-name)
+ 		device_in "link_list" $v_id $p_id
+ 		if [ "$?" = "1" ]; then
+-			if [ -e "/usr/sbin/usb_modeswitch_dispatcher" ]; then
+-				exec usb_modeswitch_dispatcher $1 $2 2>>/dev/null
+-			fi
++			exec $SBINDIR/usb_modeswitch_dispatcher $1 $2 2>>/dev/null
+ 		fi
+ 		exit 0
+ 		;;
+@@ -61,15 +63,13 @@ if [ "$p2" = "" -a "$p1" != "" ]; then
+ 	p2=$p1
+ fi
+ 
+-PATH=/bin:/sbin:/usr/bin:/usr/sbin
+-init_path=`readlink -f /sbin/init`
+-if [ `basename $init_path` = "systemd" ]; then
++if command -v systemctl > /dev/null; then
+ 	systemctl --no-block restart usb_modeswitch@$p2.service
+-elif [ -e "/etc/init/usb-modeswitch-upstart.conf" ]; then
++elif command -v initctl > /dev/null; then
+ 	initctl emit --no-wait usb-modeswitch-upstart UMS_PARAM=$p2
+ else
+ 	# only old distros, new udev will kill all subprocesses
+ 	exec 1<&- 2<&- 5<&- 7<&-
+-	exec usb_modeswitch_dispatcher --switch-mode $p2 &
++	exec $SBINDIR/usb_modeswitch_dispatcher --switch-mode $p2 &
+ fi
+ exit 0
+Index: usb-modeswitch-2.6.0/usb_modeswitch@.service
+===================================================================
+--- usb-modeswitch-2.6.0.orig/usb_modeswitch@.service
++++ usb-modeswitch-2.6.0/usb_modeswitch@.service
+@@ -3,6 +3,6 @@ Description=USB_ModeSwitch_%i
+ 
+ [Service]
+ Type=oneshot
+-ExecStart=/usr/sbin/usb_modeswitch_dispatcher --switch-mode %i
++ExecStart=@sbindir@/usb_modeswitch_dispatcher --switch-mode %i
+ #ExecStart=/bin/echo %i
+ 
+Index: usb-modeswitch-2.6.0/usb_modeswitch_dispatcher.tcl
+===================================================================
+--- usb-modeswitch-2.6.0.orig/usb_modeswitch_dispatcher.tcl
++++ usb-modeswitch-2.6.0/usb_modeswitch_dispatcher.tcl
+@@ -12,6 +12,16 @@
+ # Part of usb-modeswitch-2.6.0 package
+ # (C) Josua Dietze 2009-2019
+ 
++# Compile-time configuration, injected by the Makefile.
++set setup(sbindir) /usr/sbin
++set setup(etcdir) /etc
++
++# External dependency default location
++set setup(dbdir) /usr/share/usb_modeswitch
++
++# Derived configuration
++set setup(dbdir_etc) $setup(etcdir)/usb_modeswitch.d
++
+ set arg0 [lindex $argv 0]
+ if [regexp {\.tcl$} $arg0] {
+ 	if [file exists $arg0] {
+@@ -115,10 +125,8 @@ if {![regexp {(.*?):.*$} $arg1 d device]
+ 	}
+ }
+ 
+-set setup(dbdir) /usr/share/usb_modeswitch
+-set setup(dbdir_etc) /etc/usb_modeswitch.d
+ if {![file exists $setup(dbdir)] && ![file exists $setup(dbdir_etc)]} {
+-	Log "\nError: no config database found in /usr/share or /etc. Exit"
++	Log "\nError: no config database found in $setup(dbdir) or $setup(dbdir_etc). Exit"
+ 	SafeExit
+ }
+ 
+@@ -285,7 +293,7 @@ if {$config(NoMBIMCheck)==0 && $usb(bNum
+ 	if [CheckMBIM] {
+ 		Log " driver for MBIM devices is available"
+ 		Log "Find MBIM configuration number ..."
+-		if [catch {set cfgno [exec /usr/sbin/usb_modeswitch -j -Q $busParam $devParam -v $usb(idVendor) -p $usb(idProduct)]} err] {
++		if [catch {set cfgno [exec $setup(sbindir)/usb_modeswitch -j -Q $busParam $devParam -v $usb(idVendor) -p $usb(idProduct)]} err] {
+ 			Log "Error when trying to find MBIM configuration, switch to legacy modem mode"
+ 		} else {
+ 			set cfgno [string trim $cfgno]
+@@ -321,7 +329,7 @@ if {$report == ""} {
+ 	# Now we are actually switching
+ 	if $flags(logging) {
+ 		Log "Command line:\nusb_modeswitch -W -D $configParam $busParam $devParam -v $usb(idVendor) -p $usb(idProduct) -f \$flags(config)"
+-		catch {set report [exec /usr/sbin/usb_modeswitch -W -D $configParam $busParam $devParam -v $usb(idVendor) -p $usb(idProduct) -f "$flags(config)" 2>@1]} report
++		catch {set report [exec $setup(sbindir)/usb_modeswitch -W -D $configParam $busParam $devParam -v $usb(idVendor) -p $usb(idProduct) -f "$flags(config)" 2>@1]} report
+ 		Log "\nVerbose debug output of usb_modeswitch and libusb follows"
+ 		Log "(Note that some USB errors are to be expected in the process)"
+ 		Log "--------------------------------"
+@@ -329,7 +337,7 @@ if {$report == ""} {
+ 		Log "--------------------------------"
+ 		Log "(end of usb_modeswitch output)\n"
+ 	} else {
+-		catch {set report [exec /usr/sbin/usb_modeswitch -Q -D $configParam $busParam $devParam -v $usb(idVendor) -p $usb(idProduct) -f "$flags(config)" 2>@1]} report
++		catch {set report [exec $setup(sbindir)/usb_modeswitch -Q -D $configParam $busParam $devParam -v $usb(idVendor) -p $usb(idProduct) -f "$flags(config)" 2>@1]} report
+ 	}
+ }
+ 
+@@ -522,12 +530,12 @@ return 1
+ 
+ proc {ParseGlobalConfig} {path} {
+ 
+-global flags
++global flags setup
+ set configFile ""
+ if [string length $path] {
+ 	set places [list $path]
+ } else {
+-	set places [list /etc/usb_modeswitch.conf /etc/sysconfig/usb_modeswitch /etc/default/usb_modeswitch]
++	set places [list $setup(etcdir)/usb_modeswitch.conf $setup(etcdir)/sysconfig/usb_modeswitch $setup(etcdir)/default/usb_modeswitch]
+ }
+ foreach cfg $places {
+ 	if [file exists $cfg] {
+@@ -923,10 +931,12 @@ proc {SysLog} {msg} {
+ 
+ global flags
+ if {![info exists flags(logger)]} {
+-	set flags(logger) ""
+-	foreach fn {/bin/logger /usr/bin/logger} {
+-		if [file exists $fn] {
+-			set flags(logger) $fn
++	set flags(logger) [exec sh -c "command -v logger || true"]
++	if {$flags(logger) == ""} {
++		foreach fn {/bin/logger /usr/bin/logger} {
++			if [file exists $fn] {
++				set flags(logger) $fn
++			}
+ 		}
+ 	}
+ 	Log "Logger is $flags(logger)"
diff --git a/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/data.nix b/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/data.nix
new file mode 100644
index 000000000000..7bb9fc69c58a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/data.nix
@@ -0,0 +1,29 @@
+{ lib, stdenv, fetchurl, tcl, usb-modeswitch }:
+
+stdenv.mkDerivation rec {
+  pname = "usb-modeswitch-data";
+  version = "20191128";
+
+  src = fetchurl {
+    url    = "http://www.draisberghof.de/usb_modeswitch/${pname}-${version}.tar.bz2";
+    sha256 = "1ygahl3r26r38ai8yyblq9nhf3v5i6n6r6672p5wf88wg5h9n0rz";
+  };
+
+  makeFlags = [
+    "PREFIX=$(out)"
+    "DESTDIR=$(out)"
+  ];
+
+  prePatch = ''
+    sed -i 's@usb_modeswitch@${usb-modeswitch}/lib/udev/usb_modeswitch@g' 40-usb_modeswitch.rules
+  '';
+
+  # we add tcl here so we can patch in support for new devices by dropping config into
+  # the usb_modeswitch.d directory
+  nativeBuildInputs = [ tcl ];
+
+  meta = with lib; {
+    description = "Device database and the rules file for 'multi-mode' USB devices";
+    inherit (usb-modeswitch.meta) license maintainers platforms;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/default.nix b/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/default.nix
new file mode 100644
index 000000000000..4f9dbe92d2b7
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/usb-modeswitch/default.nix
@@ -0,0 +1,46 @@
+{ stdenv, lib, fetchurl, pkg-config, makeWrapper
+, libusb1, tcl, util-linux, coreutils, bash }:
+
+stdenv.mkDerivation rec {
+  pname = "usb-modeswitch";
+  version = "2.6.0";
+
+  src = fetchurl {
+    url    = "http://www.draisberghof.de/usb_modeswitch/${pname}-${version}.tar.bz2";
+    sha256 = "18wbbxc5cfsmikba0msdvd5qlaga27b32nhrzicyd9mdddp265f2";
+  };
+
+  patches = [ ./configurable-usb-modeswitch.patch ];
+
+  # Remove attempts to write to /etc and /var/lib.
+  postPatch = ''
+    sed -i \
+      -e '/^\tinstall .* usb_modeswitch.conf/s,$(ETCDIR),$(out)/etc,' \
+      -e '\,^\tinstall -d .*/var/lib/usb_modeswitch,d' \
+      Makefile
+  '';
+
+  makeFlags = [
+    "PREFIX=$(out)"
+    "ETCDIR=/etc"
+    "USE_UPSTART=false"
+    "USE_SYSTEMD=true"
+    "SYSDIR=$(out)/lib/systemd/system"
+    "UDEVDIR=$(out)/lib/udev"
+  ];
+
+  postFixup = ''
+    wrapProgram $out/bin/usb_modeswitch_dispatcher \
+      --set PATH ${lib.makeBinPath [ util-linux coreutils bash ]}
+  '';
+
+  buildInputs = [ libusb1 tcl ];
+  nativeBuildInputs = [ pkg-config makeWrapper ];
+
+  meta = with lib; {
+    description = "A mode switching tool for controlling 'multi-mode' USB devices";
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ marcweber peterhoeg ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/usbsdmux/default.nix b/nixpkgs/pkgs/development/tools/misc/usbsdmux/default.nix
new file mode 100644
index 000000000000..ed7a6d8a2201
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/usbsdmux/default.nix
@@ -0,0 +1,22 @@
+{ lib, python3Packages }:
+
+python3Packages.buildPythonApplication rec {
+  pname = "usbsdmux";
+  version = "0.2.0";
+
+  src = python3Packages.fetchPypi {
+    inherit pname version;
+    sha256 = "sha256-ydDUSqBTY62iOtWdgrFh2qrO9LMi+OCYIw5reh6uoIA=";
+  };
+
+  # usbsdmux is not meant to be used as an importable module and has no tests
+  doCheck = false;
+
+  meta = with lib; {
+    description = "Control software for the LXA USB-SD-Mux";
+    homepage = "https://github.com/linux-automation/usbsdmux";
+    license = licenses.lgpl21;
+    maintainers = with maintainers; [ emantor ];
+    platforms = with platforms; linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/vtable-dumper/default.nix b/nixpkgs/pkgs/development/tools/misc/vtable-dumper/default.nix
new file mode 100644
index 000000000000..1bd59aa9944a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/vtable-dumper/default.nix
@@ -0,0 +1,24 @@
+{ lib, stdenv, fetchFromGitHub, libelf }:
+
+stdenv.mkDerivation rec {
+  pname = "vtable-dumper";
+  version = "1.2";
+
+  src = fetchFromGitHub {
+    owner = "lvc";
+    repo = "vtable-dumper";
+    rev = version;
+    sha256 = "0sl7lnjr2l4c2f7qaazvpwpzsp4gckkvccfam88wcq9f7j9xxbyp";
+  };
+
+  buildInputs = [ libelf ];
+  makeFlags = [ "prefix=$(out)" ];
+
+  meta = with lib; {
+    homepage = "https://github.com/lvc/vtable-dumper";
+    description = "A tool to list content of virtual tables in a C++ shared library";
+    license = licenses.lgpl21;
+    maintainers = [ maintainers.bhipple ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile b/nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile
new file mode 100644
index 000000000000..fc739389e84e
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile
@@ -0,0 +1,2 @@
+source 'https://rubygems.org'
+gem 'watson-ruby'
diff --git a/nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile.lock b/nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile.lock
new file mode 100644
index 000000000000..9e3c166400f3
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/watson-ruby/Gemfile.lock
@@ -0,0 +1,15 @@
+GEM
+  remote: https://rubygems.org/
+  specs:
+    json (2.1.0)
+    watson-ruby (1.6.3)
+      json
+
+PLATFORMS
+  ruby
+
+DEPENDENCIES
+  watson-ruby
+
+BUNDLED WITH
+   2.1.4
diff --git a/nixpkgs/pkgs/development/tools/misc/watson-ruby/default.nix b/nixpkgs/pkgs/development/tools/misc/watson-ruby/default.nix
new file mode 100644
index 000000000000..23ec0643d77d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/watson-ruby/default.nix
@@ -0,0 +1,30 @@
+{ lib, stdenv, bundlerEnv, ruby, bundlerUpdateScript }:
+
+stdenv.mkDerivation rec {
+  pname = "watson-ruby";
+  version = (import ./gemset.nix).watson-ruby.version;
+
+  phases = [ "installPhase" ];
+
+  installPhase = let
+    env = bundlerEnv {
+      name = "watson-ruby-gems-${version}";
+      inherit ruby;
+      # expects Gemfile, Gemfile.lock and gemset.nix in the same directory
+      gemdir = ./.;
+    };
+  in ''
+    mkdir -p $out/bin
+    ln -s ${env}/bin/watson $out/bin/watson
+  '';
+
+  passthru.updateScript = bundlerUpdateScript "watson-ruby";
+
+  meta = with lib; {
+    description = "An inline issue manager";
+    homepage    = "https://goosecode.com/watson/";
+    license     = with licenses; mit;
+    maintainers = with maintainers; [ robertodr nicknovitski ];
+    platforms   = platforms.unix;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/watson-ruby/gemset.nix b/nixpkgs/pkgs/development/tools/misc/watson-ruby/gemset.nix
new file mode 100644
index 000000000000..2f865820f5aa
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/watson-ruby/gemset.nix
@@ -0,0 +1,18 @@
+{
+  json = {
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp";
+      type = "gem";
+    };
+    version = "2.1.0";
+  };
+  watson-ruby = {
+    source = {
+      remotes = ["https://rubygems.org"];
+      sha256 = "1d5m29nr0i030q8ygmbapwri5ndcg2q6lf8a15bk79lfcp9xyj9w";
+      type = "gem";
+    };
+    version = "1.6.3";
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/whatstyle/default.nix b/nixpkgs/pkgs/development/tools/misc/whatstyle/default.nix
new file mode 100644
index 000000000000..d448251bf13d
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/whatstyle/default.nix
@@ -0,0 +1,30 @@
+{ lib, python3, fetchFromGitHub, clang-unwrapped }:
+
+python3.pkgs.buildPythonApplication rec {
+  pname = "whatstyle";
+  version = "0.1.8";
+  src = fetchFromGitHub {
+    owner = "mikr";
+    repo = pname;
+    rev = "v${version}";
+    sha256 = "08lfd8h5fnvy5gci4f3an411cypad7p2yiahvbmlp51r9xwpaiwr";
+  };
+
+  # Fix references to previous version, to avoid confusion:
+  postPatch = ''
+    substituteInPlace setup.py --replace 0.1.6 ${version}
+    substituteInPlace ${pname}.py --replace 0.1.6 ${version}
+  '';
+
+  checkInputs = [ clang-unwrapped /* clang-format */ ];
+
+  doCheck = false; # 3 or 4 failures depending on version, haven't investigated.
+
+  meta = with lib; {
+    description = "Find a code format style that fits given source files";
+    homepage = "https://github.com/mikr/whatstyle";
+    license = licenses.mit;
+    maintainers = with maintainers; [ dtzWill ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/wishbone-tool/default.nix b/nixpkgs/pkgs/development/tools/misc/wishbone-tool/default.nix
new file mode 100644
index 000000000000..0465fb74aa1a
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/wishbone-tool/default.nix
@@ -0,0 +1,33 @@
+{ lib, fetchFromGitHub, rustPlatform, libusb-compat-0_1 }:
+
+let
+  version = "0.6.9";
+  src = fetchFromGitHub {
+    owner = "litex-hub";
+    repo = "wishbone-utils";
+    rev = "v${version}";
+    sha256 = "0gq359ybxnqvcp93cn154bs9kwlai62gnm71yvl2nhzjdlcr3fhp";
+  };
+in
+rustPlatform.buildRustPackage {
+  pname = "wishbone-tool";
+  inherit version;
+
+  src = "${src}/wishbone-tool";
+
+  # N.B. The cargo vendor consistency checker searches in "source" for lockfile
+  cargoDepsHook = ''
+    ln -s wishbone-tool source
+  '';
+  cargoSha256 = "1b12wpmzv7wxidc4hd8hmp8iwqhqlycxh8bdv3rf701sqsazkc5x";
+
+  buildInputs = [ libusb-compat-0_1 ];
+
+  meta = with lib; {
+    description = "Manipulate a Wishbone device over some sort of bridge";
+    homepage = "https://github.com/litex-hub/wishbone-utils";
+    license = licenses.bsd2;
+    maintainers = with maintainers; [ edef ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/xc3sprog/default.nix b/nixpkgs/pkgs/development/tools/misc/xc3sprog/default.nix
new file mode 100644
index 000000000000..b9785bac7c5c
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/xc3sprog/default.nix
@@ -0,0 +1,26 @@
+{ lib, stdenv, fetchsvn, cmake, libusb-compat-0_1, libftdi }:
+
+# The xc3sprog project doesn't seem to make proper releases, they only put out
+# prebuilt binary subversion snapshots on sourceforge.
+
+stdenv.mkDerivation rec {
+  version = "787";
+  pname = "xc3sprog";
+
+  src = fetchsvn {
+    url = "https://svn.code.sf.net/p/xc3sprog/code/trunk";
+    sha256 = "1rfhms3i7375kdlg0sdg5k52ix3xv5llj2dr30vamyg7pk74y8rx";
+    rev = version;
+  };
+
+  nativeBuildInputs = [ cmake ];
+  buildInputs = [ libusb-compat-0_1 libftdi ];
+
+  meta = with lib; {
+    description = "Command-line tools for programming FPGAs, microcontrollers and PROMs via JTAG";
+    homepage = "http://xc3sprog.sourceforge.net/";
+    license = licenses.gpl2Plus;
+    platforms = platforms.linux;
+    maintainers = [ maintainers.bjornfor ];
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/xxdiff/default.nix b/nixpkgs/pkgs/development/tools/misc/xxdiff/default.nix
new file mode 100644
index 000000000000..c187ad42c0e9
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/xxdiff/default.nix
@@ -0,0 +1,51 @@
+{ lib, mkDerivation, fetchFromBitbucket, docutils, bison, flex, qmake
+, qtbase
+}:
+
+mkDerivation rec {
+  pname = "xxdiff";
+  version = "5.0b1";
+
+  src = fetchFromBitbucket {
+    owner = "blais";
+    repo = pname;
+    rev = "5e5f885dfc43559549a81c59e9e8c9525306356a";
+    sha256 = "0gbvxrkwkbvag3298j89smszghpr8ilxxfb0cvsknfqdf15b296w";
+  };
+
+  nativeBuildInputs = [ bison docutils flex qmake ];
+
+  buildInputs = [ qtbase ];
+
+  dontUseQmakeConfigure = true;
+
+  # c++11 and above is needed for building with Qt 5.9+
+  NIX_CFLAGS_COMPILE = [ "-std=c++14" ];
+
+  sourceRoot = "source/src";
+
+  postPatch = ''
+    substituteInPlace xxdiff.pro --replace ../bin ./bin
+  '';
+
+  preConfigure = ''
+    make -f Makefile.bootstrap
+  '';
+
+  installPhase = ''
+    runHook preInstall
+
+    install -Dm555 -t $out/bin                ./bin/xxdiff
+    install -Dm444 -t $out/share/doc/${pname} ${src}/README
+
+    runHook postInstall
+  '';
+
+  meta = with lib; {
+    description = "Graphical file and directories comparator and merge tool";
+    homepage = "http://furius.ca/xxdiff/";
+    license = licenses.gpl2;
+    maintainers = with maintainers; [ pSub raskin ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/ycmd/default.nix b/nixpkgs/pkgs/development/tools/misc/ycmd/default.nix
new file mode 100644
index 000000000000..cf4fe39754fc
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/ycmd/default.nix
@@ -0,0 +1,100 @@
+{ stdenv, lib, fetchgit, cmake, llvmPackages, boost, python
+, gocode ? null
+, godef ? null
+, gotools ? null
+, nodePackages ? null
+, rustracerd ? null
+, fixDarwinDylibNames, Cocoa ? null
+}:
+
+stdenv.mkDerivation {
+  pname = "ycmd";
+  version = "2020-02-22";
+  disabled = !python.isPy3k;
+
+  src = fetchgit {
+    url = "https://github.com/Valloric/ycmd.git";
+    rev = "9a6b86e3a156066335b678c328f226229746bae5";
+    sha256 = "1c5axdngxaxj5vc6lr8sxb99mr5adsm1dnjckaxc23kq78pc8cn7";
+  };
+
+  nativeBuildInputs = [ cmake ]
+    ++ lib.optional stdenv.hostPlatform.isDarwin fixDarwinDylibNames;
+  buildInputs = [ boost llvmPackages.libclang ]
+    ++ lib.optional stdenv.hostPlatform.isDarwin Cocoa;
+
+  buildPhase = ''
+    export EXTRA_CMAKE_ARGS=-DPATH_TO_LLVM_ROOT=${llvmPackages.clang-unwrapped}
+    ${python.interpreter} build.py --system-libclang --clang-completer --system-boost
+  '';
+
+  dontConfigure = true;
+
+  # remove the tests
+  #
+  # make __main__.py executable and add shebang
+  #
+  # copy over third-party libs
+  # note: if we switch to using our packaged libs, we'll need to symlink them
+  # into the same spots, as YouCompleteMe (the vim plugin) expects those paths
+  # to be available
+  #
+  # symlink completion backends where ycmd expects them
+  installPhase = ''
+    rm -rf ycmd/tests
+
+    chmod +x ycmd/__main__.py
+    sed -i "1i #!${python.interpreter}\
+    " ycmd/__main__.py
+
+    mkdir -p $out/lib/ycmd
+    cp -r ycmd/ CORE_VERSION libclang.so.* libclang.dylib* ycm_core.so $out/lib/ycmd/
+
+    mkdir -p $out/bin
+    ln -s $out/lib/ycmd/ycmd/__main__.py $out/bin/ycmd
+
+    # Copy everything: the structure of third_party has been known to change.
+    # When linking our own libraries below, do so with '-f'
+    # to clobber anything we may have copied here.
+    mkdir -p $out/lib/ycmd/third_party
+    cp -r third_party/* $out/lib/ycmd/third_party/
+
+  '' + lib.optionalString (gocode != null) ''
+    TARGET=$out/lib/ycmd/third_party/gocode
+    mkdir -p $TARGET
+    ln -sf ${gocode}/bin/gocode $TARGET
+  '' + lib.optionalString (godef != null) ''
+    TARGET=$out/lib/ycmd/third_party/godef
+    mkdir -p $TARGET
+    ln -sf ${godef}/bin/godef $TARGET
+  '' + lib.optionalString (gotools != null) ''
+    TARGET=$out/lib/ycmd/third_party/go/src/golang.org/x/tools/cmd/gopls
+    mkdir -p $TARGET
+    ln -sf ${gotools}/bin/gopls $TARGET
+  '' + lib.optionalString (nodePackages != null) ''
+    TARGET=$out/lib/ycmd/third_party/tsserver
+    ln -sf ${nodePackages.typescript} $TARGET
+  '' + lib.optionalString (rustracerd != null) ''
+    TARGET=$out/lib/ycmd/third_party/racerd/target/release
+    mkdir -p $TARGET
+    ln -sf ${rustracerd}/bin/racerd $TARGET
+  '';
+
+  # fixup the argv[0] and replace __file__ with the corresponding path so
+  # python won't be thrown off by argv[0]
+  postFixup = ''
+    substituteInPlace $out/lib/ycmd/ycmd/__main__.py \
+      --replace $out/lib/ycmd/ycmd/__main__.py \
+                $out/bin/ycmd \
+      --replace __file__ \
+                "'$out/lib/ycmd/ycmd/__main__.py'"
+  '';
+
+  meta = with lib; {
+    description = "A code-completion and comprehension server";
+    homepage = "https://github.com/Valloric/ycmd";
+    license = licenses.gpl3;
+    maintainers = with maintainers; [ rasendubi cstrahan lnl7 ];
+    platforms = platforms.all;
+  };
+}
diff --git a/nixpkgs/pkgs/development/tools/misc/yodl/default.nix b/nixpkgs/pkgs/development/tools/misc/yodl/default.nix
new file mode 100644
index 000000000000..4f4dddbc9453
--- /dev/null
+++ b/nixpkgs/pkgs/development/tools/misc/yodl/default.nix
@@ -0,0 +1,52 @@
+{ lib, stdenv, fetchFromGitLab, perl, icmake, util-linux }:
+
+stdenv.mkDerivation rec {
+  pname = "yodl";
+  version = "4.03.02";
+
+  nativeBuildInputs = [ icmake ];
+
+  buildInputs = [ perl ];
+
+  src = fetchFromGitLab {
+    sha256 = "sha256-ZxiF9He0JgqhbnQS2pE7Y85sED8avbdwGuVmFN8/XgE=";
+    rev = version;
+    repo = "yodl";
+    owner = "fbb-git";
+  };
+
+  setSourceRoot = ''
+    sourceRoot=$(echo */yodl)
+  '';
+
+  preConfigure = ''
+    patchShebangs ./build
+    patchShebangs scripts/
+    substituteInPlace INSTALL.im --replace /usr $out
+    substituteInPlace macros/rawmacros/startdoc.pl --replace /usr/bin/perl ${perl}/bin/perl
+    substituteInPlace scripts/yodl2whatever.in --replace getopt ${util-linux}/bin/getopt
+  '';
+
+  # Set TERM because icmbuild calls tput.
+  TERM = "xterm";
+
+  buildPhase = ''
+    ./build programs
+    ./build macros
+    ./build man
+  '';
+
+  installPhase = ''
+    ./build install programs
+    ./build install macros
+    ./build install man
+  '';
+
+  meta = with lib; {
+    description = "A package that implements a pre-document language and tools to process it";
+    homepage = "https://fbb-git.gitlab.io/yodl/";
+    license = licenses.gpl3;
+    maintainers = with maintainers; [ pSub ];
+    platforms = platforms.linux;
+  };
+}